@naturalcycles/js-lib
Advanced tools
Comparing version 2.2.2 to 3.0.0
@@ -0,1 +1,13 @@ | ||
# [3.0.0](https://github.com/NaturalCycles/js-lib/compare/v2.2.2...v3.0.0) (2019-02-23) | ||
### Features | ||
* upgrade shared-module with jest24 ([4ae979a](https://github.com/NaturalCycles/js-lib/commit/4ae979a)) | ||
### BREAKING CHANGES | ||
* removed `silentConsoleIfRunAll()`, cause now it's supported by `shared-module` automatically (and because it stopped working with jest24) | ||
## [2.2.2](https://github.com/NaturalCycles/js-lib/compare/v2.2.1...v2.2.2) (2019-02-22) | ||
@@ -2,0 +14,0 @@ |
@@ -7,3 +7,3 @@ import { memo } from './decorators/memo.decorator'; | ||
import { LOG_LEVEL } from './log/log.shared.model'; | ||
import { deepFreeze, runAllTests, silentConsole, silentConsoleIfRunAll, } from './testing/test.shared.util'; | ||
import { deepFreeze, silentConsole } from './testing/test.shared.util'; | ||
import { objectUtil } from './util/object.util'; | ||
@@ -13,3 +13,3 @@ import { randomSharedUtil } from './util/random.shared.util'; | ||
import { stringSharedUtil } from './util/string.shared.util'; | ||
export { memo, memoCache, AppError, HttpError, deepFreeze, silentConsole, runAllTests, silentConsoleIfRunAll, errorSharedUtil, objectUtil, randomSharedUtil, scriptSharedUtil, stringSharedUtil, LOG_LEVEL, }; | ||
export { memo, memoCache, AppError, HttpError, deepFreeze, silentConsole, errorSharedUtil, objectUtil, randomSharedUtil, scriptSharedUtil, stringSharedUtil, LOG_LEVEL, }; | ||
//# sourceMappingURL=index.js.map |
@@ -23,12 +23,2 @@ // Source: https://github.com/substack/deep-freeze/blob/master/index.js | ||
} | ||
export function runAllTests() { | ||
const args = process.argv.slice(); | ||
const lastArg = args.filter(x => !x.startsWith('-')).pop(); | ||
return ((lastArg && (lastArg.endsWith('/jest') || lastArg.endsWith('/jest-worker/build/child.js'))) || | ||
false); | ||
} | ||
export function silentConsoleIfRunAll() { | ||
if (runAllTests()) | ||
silentConsole(); | ||
} | ||
//# sourceMappingURL=test.shared.util.js.map |
@@ -8,3 +8,3 @@ import { memo } from './decorators/memo.decorator'; | ||
import { BasicLogFunction, LOG_LEVEL, LogFunction } from './log/log.shared.model'; | ||
import { deepFreeze, runAllTests, silentConsole, silentConsoleIfRunAll } from './testing/test.shared.util'; | ||
import { deepFreeze, silentConsole } from './testing/test.shared.util'; | ||
import { ClassType, PromiseMap, StringMap } from './types'; | ||
@@ -15,2 +15,2 @@ import { objectUtil } from './util/object.util'; | ||
import { stringSharedUtil } from './util/string.shared.util'; | ||
export { memo, memoCache, ErrorData, ErrorObject, HttpErrorData, ErrorResponse, AppError, HttpError, deepFreeze, silentConsole, runAllTests, silentConsoleIfRunAll, errorSharedUtil, objectUtil, randomSharedUtil, scriptSharedUtil, stringSharedUtil, StringMap, PromiseMap, ClassType, LOG_LEVEL, BasicLogFunction, LogFunction, }; | ||
export { memo, memoCache, ErrorData, ErrorObject, HttpErrorData, ErrorResponse, AppError, HttpError, deepFreeze, silentConsole, errorSharedUtil, objectUtil, randomSharedUtil, scriptSharedUtil, stringSharedUtil, StringMap, PromiseMap, ClassType, LOG_LEVEL, BasicLogFunction, LogFunction, }; |
@@ -17,5 +17,3 @@ "use strict"; | ||
exports.deepFreeze = test_shared_util_1.deepFreeze; | ||
exports.runAllTests = test_shared_util_1.runAllTests; | ||
exports.silentConsole = test_shared_util_1.silentConsole; | ||
exports.silentConsoleIfRunAll = test_shared_util_1.silentConsoleIfRunAll; | ||
const object_util_1 = require("./util/object.util"); | ||
@@ -22,0 +20,0 @@ exports.objectUtil = object_util_1.objectUtil; |
export declare function deepFreeze(o: any): void; | ||
export declare function silentConsole(): void; | ||
export declare function runAllTests(): boolean; | ||
export declare function silentConsoleIfRunAll(): void; |
@@ -27,14 +27,2 @@ "use strict"; | ||
exports.silentConsole = silentConsole; | ||
function runAllTests() { | ||
const args = process.argv.slice(); | ||
const lastArg = args.filter(x => !x.startsWith('-')).pop(); | ||
return ((lastArg && (lastArg.endsWith('/jest') || lastArg.endsWith('/jest-worker/build/child.js'))) || | ||
false); | ||
} | ||
exports.runAllTests = runAllTests; | ||
function silentConsoleIfRunAll() { | ||
if (runAllTests()) | ||
silentConsole(); | ||
} | ||
exports.silentConsoleIfRunAll = silentConsoleIfRunAll; | ||
//# sourceMappingURL=test.shared.util.js.map |
{ | ||
"name": "@naturalcycles/js-lib", | ||
"version": "2.2.2", | ||
"version": "3.0.0", | ||
"scripts": { | ||
@@ -11,3 +11,3 @@ "build": "del ./dist && tsc", | ||
"dependencies": { | ||
"@types/lru-cache": "^4.1.1", | ||
"@types/lru-cache": "^5.1.0", | ||
"@types/luxon": "^1.4.0" | ||
@@ -20,6 +20,6 @@ }, | ||
"@naturalcycles/semantic-release": "^1.0.0", | ||
"@naturalcycles/shared-module": "^2.1.1", | ||
"@types/jest": "^23.3.5", | ||
"@naturalcycles/shared-module": "^3.0.0", | ||
"@types/jest": "^24.0.6", | ||
"@types/node": "^10.0.0", | ||
"jest": "^23.6.0", | ||
"jest": "^24.1.0", | ||
"jest-junit": "^6.2.1", | ||
@@ -29,3 +29,3 @@ "lru-cache": "^5.1.1", | ||
"prettier": "^1.14.3", | ||
"ts-jest": "^23.10.4", | ||
"ts-jest": "^24.0.0", | ||
"ts-node": "^8.0.2", | ||
@@ -32,0 +32,0 @@ "tslint": "^5.11.0", |
@@ -31,3 +31,3 @@ // Based on: | ||
const lruOpts: LRU.Options = { | ||
const lruOpts: LRU.Options<string, any> = { | ||
max: opts.maxSize || 100, | ||
@@ -34,0 +34,0 @@ maxAge: opts.ttl || Infinity, |
@@ -8,8 +8,3 @@ import { memo } from './decorators/memo.decorator' | ||
import { BasicLogFunction, LOG_LEVEL, LogFunction } from './log/log.shared.model' | ||
import { | ||
deepFreeze, | ||
runAllTests, | ||
silentConsole, | ||
silentConsoleIfRunAll, | ||
} from './testing/test.shared.util' | ||
import { deepFreeze, silentConsole } from './testing/test.shared.util' | ||
import { ClassType, PromiseMap, StringMap } from './types' | ||
@@ -32,4 +27,2 @@ import { objectUtil } from './util/object.util' | ||
silentConsole, | ||
runAllTests, | ||
silentConsoleIfRunAll, | ||
errorSharedUtil, | ||
@@ -36,0 +29,0 @@ objectUtil, |
@@ -28,14 +28,1 @@ // Source: https://github.com/substack/deep-freeze/blob/master/index.js | ||
} | ||
export function runAllTests (): boolean { | ||
const args = process.argv.slice() | ||
const lastArg = args.filter(x => !x.startsWith('-')).pop() | ||
return ( | ||
(lastArg && (lastArg.endsWith('/jest') || lastArg.endsWith('/jest-worker/build/child.js'))) || | ||
false | ||
) | ||
} | ||
export function silentConsoleIfRunAll (): void { | ||
if (runAllTests()) silentConsole() | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
101947
1806
+ Added@types/lru-cache@5.1.1(transitive)
- Removed@types/lru-cache@4.1.3(transitive)
Updated@types/lru-cache@^5.1.0