1

I am using rest-assured and allureRestAssured for testing api

given().header("Content-Type", "application/json")
                .header("key", key()).filter(new AllureRestAssured())
                .body(body.toString())
                .post(baseURI);

Problem here is its logged headers also , which contains auth key , which I dont want to be exposed in report generated , how can I ignore that .

1
2

You can blacklist the headers you don't want to see in the report:

given().config(config().logConfig(logConfig().blacklistHeader("Accept"))). ..

Documentation here.

1
  • Thanks for revert I already tried that , but no luck , its not working – Cod May 25 at 13:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.