-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathall-pages.spec.js
48 lines (37 loc) · 1.22 KB
/
all-pages.spec.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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
'use strict'
const chai = require('chai')
const chaiAsPromised = require('chai-as-promised')
chai.use(chaiAsPromised)
const { assert, should } = chai
should()
describe('All pages', function() {
describe('With a team with no _', function() {
this.timeout(5 * 1000)
const { getTeamPages, getTeamTemplates } = require('../index.js')({})
it('Should return a list of team pages', function() {
return getTeamPages().then((pages) => {
assert.isOk(pages.length >= 0)
})
})
it('Should return a list of team templates', function() {
return getTeamTemplates().then((templates) => {
assert.isOk(templates.length >= 0)
})
})
})
describe('With a team with _ in it', function() {
const { getTeamPages, getTeamTemplates } = require('../index.js')({ teamName: 'UrbanTundra_Edmonton' })
it('Should return a list of team pages', function() {
this.timeout(5 * 1000)
return getTeamPages().then((pages) => {
assert.isOk(pages.length >= 0)
})
})
it('Should return a list of team templates', function() {
this.timeout(5 * 1000)
return getTeamTemplates().then((templates) => {
assert.isOk(templates.length >= 0)
})
})
})
})