Initial commit
This commit is contained in:
commit
b3a51a4115
10336 changed files with 2381973 additions and 0 deletions
22
node_modules/fast-check/lib/esm/arbitrary/context.js
generated
vendored
Normal file
22
node_modules/fast-check/lib/esm/arbitrary/context.js
generated
vendored
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import { cloneMethod } from '../check/symbols.js';
|
||||
import { constant } from './constant.js';
|
||||
class ContextImplem {
|
||||
constructor() {
|
||||
this.receivedLogs = [];
|
||||
}
|
||||
log(data) {
|
||||
this.receivedLogs.push(data);
|
||||
}
|
||||
size() {
|
||||
return this.receivedLogs.length;
|
||||
}
|
||||
toString() {
|
||||
return JSON.stringify({ logs: this.receivedLogs });
|
||||
}
|
||||
[cloneMethod]() {
|
||||
return new ContextImplem();
|
||||
}
|
||||
}
|
||||
export function context() {
|
||||
return constant(new ContextImplem());
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue