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

introduce test block #9

Merged
merged 1 commit into from
Jun 5, 2018
Merged

introduce test block #9

merged 1 commit into from
Jun 5, 2018

Conversation

mikz
Copy link
Contributor

@mikz mikz commented Jun 5, 2018

A test block can nginx config for a location to be executed by the test request.
The test does not have to define request as it will be automatically
set to point to the test block.

See an example: https://github.com/3scale/apicast/blob/9288d0d1e9b059cb10ef81a99c475d8b817d449c/t/listen-https.t#L18-L39

Test::Nginx can't make HTTPS requests, so we need some workaround to
call APIcast with HTTPS. lua-nginx-module does the same: https://github.com/openresty/lua-nginx-module/blob/36f341e72858a6dfb861ceb3fbe548b690006acf/t/139-ssl-cert-by.t

A test block can nginx config for a location to be executed by the test request.
The test does not have to define request as it will be automatically
set to point to the test block.

See an example: https://github.com/3scale/apicast/blob/9288d0d1e9b059cb10ef81a99c475d8b817d449c/t/listen-https.t#L18-L39

Test::Nginx can't make HTTPS requests, so we need some workaround to
call APIcast with HTTPS. lua-nginx-module does the same: https://github.com/openresty/lua-nginx-module/blob/36f341e72858a6dfb861ceb3fbe548b690006acf/t/139-ssl-cert-by.t
@mikz mikz merged commit 228c48d into master Jun 5, 2018
@mikz mikz deleted the test-block branch June 5, 2018 13:31
mikz added a commit to 3scale/APIcast that referenced this pull request Jun 5, 2018
mikz added a commit to 3scale/APIcast that referenced this pull request Jun 6, 2018
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

Successfully merging this pull request may close these issues.

2 participants