mirror of
https://github.com/jdalrymple/gitbeaker.git
synced 2026-01-25 16:04:01 +00:00
* chore: Introduce typescript * chore: Remove lodash.pick, use native js instead * chore: Add tslint and extend Airbnb ruleset * chore: Remove Babel Dependency, replace build steps with tsc * chore: change target for modern env from es2017 to es6 (async/await should be transpiled to downlevel js) * chore(package): Updating packages * fix: Fix error while throwing an error in RequestHelper (#156) * feat: Support rejectUnauthorized parameter (#164) * feat: Adding project archive abilities * fix(test): Application settings API updated (#177) * fix: Removing token requirement (#176) * chore: Removing npmignore and using files instead. * fix: obey rate limits for all request types correctly (#170) * fix: Camel casing broke the body params
18 lines
683 B
TypeScript
18 lines
683 B
TypeScript
import { UsersBundle } from '../../../src';
|
|
import * as Services from '../../../src/services';
|
|
|
|
test('All the correct service keys are included in the users bundle', async () => {
|
|
const bundle = new UsersBundle({ token: 'test' });
|
|
const services = ['Users', 'UserEmails', 'UserCustomAttributes', 'UserImpersonationTokens', 'UserKeys', 'UserGPGKeys'];
|
|
|
|
expect(Object.keys(bundle)).toEqual(expect.arrayContaining(services));
|
|
});
|
|
|
|
test('All the correct service instances are included in the users bundle', async () => {
|
|
const bundle = new UsersBundle({ token: 'test' });
|
|
|
|
Object.keys(bundle).forEach((key) => {
|
|
expect(bundle[key]).toBeInstanceOf(Services[key]);
|
|
});
|
|
});
|