forked from tensorflow/tfjs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathversion_test.ts
29 lines (26 loc) · 978 Bytes
/
version_test.ts
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
/**
* @license
* Copyright 2018 Google LLC.
*
* Use of this source code is governed by an MIT-style
* license that can be found in the LICENSE file or at
* https://opensource.org/licenses/MIT.
* =============================================================================
*/
// tslint:disable-next-line:no-require-imports
const packageJSON = require('../package.json');
import {version_wasm} from './index';
describe('tfjs-core version consistency', () => {
it('dev-peer match', () => {
const tfjsCoreDevDepVersion =
packageJSON.devDependencies['@tensorflow/tfjs-core'];
const tfjsCorePeerDepVersion =
packageJSON.peerDependencies['@tensorflow/tfjs-core'];
expect(tfjsCoreDevDepVersion).toEqual(tfjsCorePeerDepVersion);
});
it('version.ts matches package version', () => {
// tslint:disable-next-line:no-require-imports
const expected = require('../package.json').version;
expect(version_wasm).toBe(expected);
});
});