New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

lastcall-nightcrawler

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lastcall-nightcrawler - npm Package Compare versions

Comparing version 2.0.0-beta1 to 2.0.0-beta2

dist/cli/__stubs__/broken.d.ts

2

dist/cli/index.js

@@ -48,5 +48,5 @@ "use strict";

concurrency: massageConcurrency(argv.concurrency, 5),
context: (0, _util.loadContext)(argv.config, cwd)
context: await (0, _util.loadContext)(argv.config, cwd)
}, stdout);
}
}

@@ -6,2 +6,2 @@ import TestContext, { TestResult, TestResultMap } from '../testing/TestContext';

export declare function hasFailure(result: TestResultMap): boolean;
export declare function loadContext(configFile: string, cwd: string): TestContext;
export declare function loadContext(configFile: string, cwd: string): Promise<TestContext>;

@@ -22,16 +22,16 @@ "use strict";

function loadContext(configFile, cwd) {
let context;
async function loadContext(configFile, cwd) {
let resolved;
try {
const resolved = require.resolve(configFile, {
resolved = require.resolve(configFile, {
paths: [cwd]
}); // eslint-disable-next-line @typescript-eslint/no-var-requires
context = require(resolved);
});
} catch (e) {
throw new Error(`Unable to find configuration file at ${configFile}.`);
}
} // eslint-disable-next-line @typescript-eslint/no-var-requires
const context = await require(resolved);
if (context instanceof _TestContext.default) {

@@ -38,0 +38,0 @@ return context;

/// <reference types="jest" />
declare const _default: jest.Mock<any, any>;
export default _default;
declare const MockedContext: jest.Mock<any, any>;
export default MockedContext;
import TestContext from './TestContext';
import Crawler from '../Crawler';
declare const crawl: (description: string, cb: () => Iterable<import("../types").CrawlerRequest> | AsyncIterable<import("../types").CrawlerRequest> | Crawler) => TestContext;
import { RequestIterable } from '../types';
declare type CrawlCB = () => RequestIterable | Crawler | Promise<RequestIterable> | Promise<Crawler>;
declare const crawl: (description: string, cb: CrawlCB) => Promise<TestContext>;
declare const test: (description: string, cb: (unit: import("../types").CrawlerUnit) => void) => TestContext;
declare const after: (description: string, cb: () => void) => TestContext;
export { crawl, test, after };

@@ -16,3 +16,3 @@ "use strict";

const crawl = function (description, cb) {
const crawl = async function (description, cb) {
const context = new _TestContext.default(description);

@@ -23,3 +23,3 @@ activeContext = context;

try {
result = cb();
result = await cb();

@@ -42,3 +42,3 @@ if (!result) {

if (activeContext === null) {
throw new Error(`You may not call ${name} outside of a crawler function.`);
throw new Error(`You may not call "${name}()" outside of a crawler function.`);
}

@@ -45,0 +45,0 @@

{
"name": "lastcall-nightcrawler",
"version": "2.0.0-beta1",
"version": "2.0.0-beta2",
"main": "dist/index.js",

@@ -49,3 +49,3 @@ "license": "MIT",

"build": "babel src/ --out-dir=dist --extensions '.ts' --ignore 'src/**/__tests__/**' --ignore 'src/**/__mocks__/**' --ignore 'src/**/__stubs__/**' && tsc --emitDeclarationOnly",
"lint": "eslint ./src/ --ext .js,.jsx,.ts,.tsx"
"lint": "eslint ./src/ --ext .ts"
},

@@ -52,0 +52,0 @@ "files": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc