1.4.28 • Published 2 years ago
ku4es-testing v1.4.28
Classes
Functions
Performance
Kind: global class
new Performance(nowable)
Param | Type | Default | Description |
---|---|---|---|
nowable | Performance | DateConstructor | DateConstructor | Any object having method now that returns a time of type number. |
new Performance(func, iterations)
Param | Type | Default | Description |
---|---|---|---|
func | function | A function whose body defines the performance test case. | |
iterations | number | 10000 | The number of times to run func. |
Performance
Kind: global class
new Performance(nowable)
Param | Type | Default | Description |
---|---|---|---|
nowable | Performance | DateConstructor | DateConstructor | Any object having method now that returns a time of type number. |
new Performance(func, iterations)
Param | Type | Default | Description |
---|---|---|---|
func | function | A function whose body defines the performance test case. | |
iterations | number | 10000 | The number of times to run func. |
startServer()
Starts a mock server for Unit Tests that cover code sections
that include calls to a server. This must be called before
you can successfully use sendResponse
.
Kind: global function
stopServer()
Stops a mock server started with startServer
Kind: global function
sendResponse(response, index) ⇒ *
Kind: global function
Param | Type | Default | Description |
---|---|---|---|
response | Object | A response object | |
response.status | number | An HTTP status code. | |
response.response | Object | A mock response payload. | |
index | number | 0 | The index of the response that you want to send. This is useful for those instances where your codebase makes multiple service calls and you need to send responses back to some or all of them. |
1.4.28
2 years ago
1.4.27
2 years ago
1.4.24
3 years ago
1.4.25
3 years ago
1.4.22
3 years ago
1.4.21
3 years ago
1.4.23
3 years ago
1.4.5
3 years ago
1.4.4
3 years ago
1.4.20
3 years ago
1.4.9
3 years ago
1.4.11
3 years ago
1.4.8
3 years ago
1.4.10
3 years ago
1.4.7
3 years ago
1.4.13
3 years ago
1.4.12
3 years ago
1.4.15
3 years ago
1.4.14
3 years ago
1.4.17
3 years ago
1.4.16
3 years ago
1.4.19
3 years ago
1.4.18
3 years ago
1.4.3
4 years ago
1.4.2
5 years ago
1.4.0
5 years ago
1.3.1
5 years ago
1.3.0
6 years ago