Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default assert? #488

Closed
tarioch opened this issue Jul 3, 2023 · 4 comments
Closed

Default assert? #488

tarioch opened this issue Jul 3, 2023 · 4 comments

Comments

@tarioch
Copy link

tarioch commented Jul 3, 2023

It would be great if it were somehow possible to have a default assert (e.g. status == 200). So that this would be used for all requests, except for the ones where I explicitly specify a different assert.

@AnWeber
Copy link
Owner

AnWeber commented Jul 4, 2023

My thought would be to implement it similar to the global script blocks. This would mean that it is possible to define default asserts per file. But these are then always valid for all regions in this file.

?? status == 200
###
GET https://httpbin.org/status/200

GET https://httpbin.org/status/404

@tarioch
Copy link
Author

tarioch commented Jul 5, 2023

I think that sounds good, would those also work with an import or would they have to be specified in each file?

@AnWeber
Copy link
Owner

AnWeber commented Jul 14, 2023

@tarioch I will have to support the imports if you ask for them directly. I thought about whether I could get around it because it's more difficult, but it makes sense.

@AnWeber
Copy link
Owner

AnWeber commented Jul 16, 2023

Global Asserts and also the import will be delivered with the next version. Thanks for the improvement idea.

@AnWeber AnWeber closed this as completed Jul 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants