1 |
|
2 |
|
3 |
|
4 |
|
5 | 'use strict'
|
6 |
|
7 | const ApService = require('../lib/ap_service.js')
|
8 | const { createStore } = require('redux')
|
9 | const reducer = require('../lib/reducer')
|
10 | const assert = require('assert')
|
11 | const co = require('co')
|
12 |
|
13 | describe('ap-service', function () {
|
14 | this.timeout(3000)
|
15 |
|
16 | before(() => co(function * () {
|
17 |
|
18 | }))
|
19 |
|
20 | after(() => co(function * () {
|
21 |
|
22 | }))
|
23 |
|
24 | it('Demo service', () => co(function * () {
|
25 | let store = createStore(reducer)
|
26 | let service = new ApService(store)
|
27 | assert.ok(service)
|
28 | assert.ok(!service.get('foo'))
|
29 |
|
30 | }))
|
31 | })
|
32 |
|
33 |
|