cobinhood-rx
Version:
CobinhoodRx is a rxjs node wrapper for the CobinhoodRx Api.
45 lines (41 loc) • 910 B
text/typescript
import { CobinhoodRxClient } from '../../../Core/CobinhoodRxClient';
import { LogTypeValue } from '../../../Enum';
describe('System Methods', () => {
let cbrx: CobinhoodRxClient;
beforeAll(() => {
cbrx = new CobinhoodRxClient(
{
logType: LogTypeValue.None
}
);
});
describe('# getSystemTime', () => {
it('should return system time', done => {
cbrx.System.getSystemTime()
.subscribe(data => {
expect(data).toEqual(
expect.objectContaining({ Time: expect.any(Number) })
);
done();
},
done
);
}, 60000);
});
describe('# getSystemInfo', () => {
it('should return system info', done => {
cbrx.System.getSystemInfo()
.subscribe(data => {
expect(data).toEqual(
expect.objectContaining({
Phase: expect.any(String),
Revision: expect.any(String)
})
);
done();
},
done
);
}, 60000);
});
});