forked from TheOdd/gradespeed-hisd
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgs.test.js
29 lines (25 loc) · 820 Bytes
/
gs.test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
const gs = require('./index')
const username = "student\\s1535208"
const password = "03312001"
// test('Invalid username & pass', () => {
// expect.assertions(1)
// jest.setTimeout(20000)
// return gs('INVALIDUSERNAME', 'INVALIDPASSWORD')
// .catch(err => {
// expect(err.message).toBe('Invalid username or password.')
// })
// })
// test('Get back valid array of return objects', () => {
// expect.assertions(1)
// jest.setTimeout(20000)
// return gs(username, password)
// .then(returnArr => {
// let isArr = Array.isArray(returnArr)
// let isValid = isArr && returnArr
// expect(isValid).toBeTruthy()
// })
// })
gs(username, password)
// .then(returnArr => {
// console.log(returnArr);
// });