0.0.17 • Published 3 months ago

@kablamo/kerosene-test v0.0.17

Weekly downloads
119
License
MIT
Repository
github
Last release
3 months ago

🔥 Kerosene-test

yarn add --dev @kablamo/kerosene-test

npm install --save-dev @kablamo/kerosene-test

Available Functions

React

createStubComponent(displayName, functional?, getRenderProps?, transformRenderProps?)

Creates a StubComponent for unit testing.

createStubContext(displayName, getter?)

Creates a stub React Context for unit testing.

Stubs

createStubStyles(classNames, values?)

Returns an object mapping local classNames to faked global equivalents along with any exported values.

stubProperties(target, properties)

Stubs properties on the target object, and returns a function which restores them to their original values.

Available TypeScript Types

Jest

JestMock<T>

Shorthand for jest.Mock<OverloadedReturnType<T>, OverloadedParameters<T>> & T;.

JestSpied<T>

Shorthand for jest.SpyInstance<OverloadedReturnType<T>, OverloadedParameters<T>> & T;.

Sinon

SinonSpied<T>

Shorthand for sinon.SinonSpy<OverloadedParameters<T>, OverloadedReturnType<T>> & T;.

SinonStubbed<T>

Shorthand for sinon.SinonStub<OverloadedParameters<T>, OverloadedReturnType<T>> & T;.


kablamo.com.au

0.0.17

3 months ago

0.0.16

3 months ago

0.0.14

4 months ago

0.0.15

4 months ago

0.0.13

9 months ago

0.0.12

1 year ago

0.0.11

2 years ago

0.0.10

2 years ago

0.0.9

3 years ago

0.0.8

4 years ago

0.0.7

4 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago