fix(ci): update
This commit is contained in:
39
test/test.ts
39
test/test.ts
@ -1,32 +1,31 @@
|
||||
import { tap, expect } from '@pushrocks/tapbundle'
|
||||
import projectinfo = require('../ts/index')
|
||||
import { tap, expect } from '@pushrocks/tapbundle';
|
||||
import projectinfo = require('../ts/index');
|
||||
|
||||
let path = require('path')
|
||||
let testBasePath = path.resolve(__dirname)
|
||||
let path = require('path');
|
||||
let testBasePath = path.resolve(__dirname);
|
||||
|
||||
let myNpm = new projectinfo.ProjectinfoNpm(testBasePath, { gitAccessToken: 'sometoken' })
|
||||
let myNpm = new projectinfo.ProjectinfoNpm(testBasePath, { gitAccessToken: 'sometoken' });
|
||||
tap.test('should have .packageJson', async () => {
|
||||
expect(myNpm.packageJson).have.property('version', '1.0.0')
|
||||
expect(myNpm.packageJson).have.property('name', 'testpackage')
|
||||
})
|
||||
expect(myNpm.packageJson).have.property('version', '1.0.0');
|
||||
expect(myNpm.packageJson).have.property('name', 'testpackage');
|
||||
});
|
||||
|
||||
tap.test('should have .version', async () => {
|
||||
expect(myNpm).have.property('version', '1.0.0')
|
||||
})
|
||||
expect(myNpm).have.property('version', '1.0.0');
|
||||
});
|
||||
|
||||
tap.test('should have .name', async () => {
|
||||
expect(myNpm).have.property('name', 'testpackage')
|
||||
})
|
||||
expect(myNpm).have.property('name', 'testpackage');
|
||||
});
|
||||
|
||||
tap.test('should have .license', async () => {
|
||||
expect(myNpm).have.property('license', 'MIT')
|
||||
})
|
||||
expect(myNpm).have.property('license', 'MIT');
|
||||
});
|
||||
tap.test('should have .git', async () => {
|
||||
expect(myNpm.git.httpsUrl).equal('https://sometoken@github.com/someuser/somerepo.git')
|
||||
})
|
||||
expect(myNpm.git.httpsUrl).equal('https://sometoken@github.com/someuser/somerepo.git');
|
||||
});
|
||||
tap.test('should return a name', async () => {
|
||||
expect(projectinfo.getNpmNameForDir(testBasePath)
|
||||
).equal('testpackage')
|
||||
})
|
||||
expect(projectinfo.getNpmNameForDir(testBasePath)).equal('testpackage');
|
||||
});
|
||||
|
||||
tap.start()
|
||||
tap.start();
|
||||
|
Reference in New Issue
Block a user