@serenity-js/rest
Advanced tools
Comparing version
@@ -6,2 +6,18 @@ # Change Log | ||
# [3.16.0](https://github.com/serenity-js/serenity-js/compare/v3.15.1...v3.16.0) (2024-02-01) | ||
### Bug Fixes | ||
* **deps:** update dependency lru-cache to v10.2.0 ([a580d1e](https://github.com/serenity-js/serenity-js/commit/a580d1e301b7901e78ea87b5a273438562880533)) | ||
### Features | ||
* **core:** added Masked.valueOf() Question ([e9ff5ab](https://github.com/serenity-js/serenity-js/commit/e9ff5ab62e8b305aa7ef2238f482be5369d890c1)), closes [#2165](https://github.com/serenity-js/serenity-js/issues/2165) | ||
## [3.15.1](https://github.com/serenity-js/serenity-js/compare/v3.15.0...v3.15.1) (2024-01-19) | ||
@@ -8,0 +24,0 @@ |
@@ -86,2 +86,23 @@ import type { Answerable } from '@serenity-js/core'; | ||
* | ||
* ## Handling sensitive information | ||
* | ||
* By design, any data handled by an actor appears in Serenity/JS reports. | ||
* To prevent the exposure of any sensitive information, such as passwords or tokens, you should use {@apilink Masked}. | ||
* | ||
* ```ts | ||
* import { actorCalled, Masked } from '@serenity-js/core' | ||
* import { CallAnApi, ChangeApiConfig, GetRequest, LastResponse, Send } from '@serenity-js/rest' | ||
* import { Ensure, equals } from '@serenity-js/assertions' | ||
* | ||
* await actorCalled('Apisitt') | ||
* .whoCan( | ||
* CallAnApi.at('http://localhost'), | ||
* ) | ||
* .attemptsTo( | ||
* ChangeApiConfig.setHeader('Authorization', Masked.valueOf('secret token')), | ||
* Send.a(GetRequest.to('/api')), | ||
* Ensure.that(LastResponse.status(), equals(200)), | ||
* ) | ||
* ``` | ||
* | ||
* @group Activities | ||
@@ -88,0 +109,0 @@ */ |
@@ -90,2 +90,23 @@ "use strict"; | ||
* | ||
* ## Handling sensitive information | ||
* | ||
* By design, any data handled by an actor appears in Serenity/JS reports. | ||
* To prevent the exposure of any sensitive information, such as passwords or tokens, you should use {@apilink Masked}. | ||
* | ||
* ```ts | ||
* import { actorCalled, Masked } from '@serenity-js/core' | ||
* import { CallAnApi, ChangeApiConfig, GetRequest, LastResponse, Send } from '@serenity-js/rest' | ||
* import { Ensure, equals } from '@serenity-js/assertions' | ||
* | ||
* await actorCalled('Apisitt') | ||
* .whoCan( | ||
* CallAnApi.at('http://localhost'), | ||
* ) | ||
* .attemptsTo( | ||
* ChangeApiConfig.setHeader('Authorization', Masked.valueOf('secret token')), | ||
* Send.a(GetRequest.to('/api')), | ||
* Ensure.that(LastResponse.status(), equals(200)), | ||
* ) | ||
* ``` | ||
* | ||
* @group Activities | ||
@@ -92,0 +113,0 @@ */ |
{ | ||
"name": "@serenity-js/rest", | ||
"version": "3.15.1", | ||
"version": "3.16.0", | ||
"description": "Test REST APIs with Serenity/JS", | ||
@@ -49,8 +49,8 @@ "author": { | ||
"dependencies": { | ||
"@serenity-js/core": "3.15.1", | ||
"@serenity-js/core": "3.16.0", | ||
"agent-base": "7.1.0", | ||
"axios": "1.6.5", | ||
"axios": "1.6.7", | ||
"http-proxy-agent": "7.0.0", | ||
"https-proxy-agent": "7.0.2", | ||
"lru-cache": "10.1.0", | ||
"lru-cache": "10.2.0", | ||
"proxy-from-env": "1.1.0" | ||
@@ -60,3 +60,3 @@ }, | ||
"@integration/testing-tools": "3.0.0", | ||
"@serenity-js/assertions": "3.15.1", | ||
"@serenity-js/assertions": "3.16.0", | ||
"@types/chai": "4.3.11", | ||
@@ -71,3 +71,3 @@ "@types/mocha": "10.0.6", | ||
}, | ||
"gitHead": "4df79de3820acd9fb18d76843feb0468c55c8e7f" | ||
"gitHead": "242771e55bd6becc5baeaac03edf945e4cdaf7a4" | ||
} |
@@ -90,2 +90,23 @@ import type { Answerable, AnswersQuestions, CollectsArtifacts, UsesAbilities } from '@serenity-js/core'; | ||
* | ||
* ## Handling sensitive information | ||
* | ||
* By design, any data handled by an actor appears in Serenity/JS reports. | ||
* To prevent the exposure of any sensitive information, such as passwords or tokens, you should use {@apilink Masked}. | ||
* | ||
* ```ts | ||
* import { actorCalled, Masked } from '@serenity-js/core' | ||
* import { CallAnApi, ChangeApiConfig, GetRequest, LastResponse, Send } from '@serenity-js/rest' | ||
* import { Ensure, equals } from '@serenity-js/assertions' | ||
* | ||
* await actorCalled('Apisitt') | ||
* .whoCan( | ||
* CallAnApi.at('http://localhost'), | ||
* ) | ||
* .attemptsTo( | ||
* ChangeApiConfig.setHeader('Authorization', Masked.valueOf('secret token')), | ||
* Send.a(GetRequest.to('/api')), | ||
* Ensure.that(LastResponse.status(), equals(200)), | ||
* ) | ||
* ``` | ||
* | ||
* @group Activities | ||
@@ -92,0 +113,0 @@ */ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
271413
1.07%5189
1.23%+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
- Removed
Updated
Updated
Updated