Skip to content

Commit

Permalink
Create map.test.js
Browse files Browse the repository at this point in the history
  • Loading branch information
GreepTheSheep committed Mar 25, 2022
1 parent b98648c commit 6780d18
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions test/map.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
require('dotenv').config();
const assert = require('assert'),
TMIO = require('../'),
tmioClient = new TMIO.Client({dev: true});

describe("Maps", function(){
this.timeout(15*1000);

it("Map Info", async function(){
const map = await tmioClient.maps.get('1jEeZQTADlb9wIY2YzCjZ5Lpmxh');
const author = await map.author();
const exchange = await map.exchange();

assert.equal(author.login, "Jtmn3kBnSSadky_mLNhp_A");
assert.equal(map.medalTimes.author, 11216);
assert.equal(map.medalTimes.gold, 12000);
assert.equal(map.medalTimes.silver, 14000);
assert.equal(map.medalTimes.bronze, 17000);

assert.equal(exchange.id, 41427);
});
});

0 comments on commit 6780d18

Please sign in to comment.