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

Add ENV var to configure dry run #274

Merged
merged 3 commits into from
Feb 9, 2021
Merged

Conversation

igas
Copy link
Contributor

@igas igas commented Jan 30, 2020

During integration with rswag, we noticed that we need to set dry run very early and suggestion is to put it in application.rb. We did not really want to add specs related code to production code. So we came up with this solution. What do you think?

Copy link
Contributor

@akabiru akabiru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this suggestion @igas I agree that having spec logic in application.rb seems a bit off the mark- I've had to do the same as well 😄 .

This looks like a very good improvement- I would only request that you update this section in the README to reflect the change. cc @BookOfGreg

rswag-specs/lib/rswag/specs/configuration.rb Show resolved Hide resolved
@igas
Copy link
Contributor Author

igas commented Mar 25, 2020

Hi @BookOfGreg, any chance you can take a look at this one?

@BookOfGreg
Copy link
Member

Code looks ok. I'd like to see a test related to the change. I'll probably merge either this or something similar after OA3 changes as that's the majority of the effort just now.

@igas
Copy link
Contributor Author

igas commented Mar 26, 2020

No worries, thanks a lot for work on OA3, we can't wait to test it out.

@flyfy1
Copy link

flyfy1 commented Jun 7, 2020

Looking forward for sth like this to be merged, cuz the current master's README section about DryRun doesn't work.

The issue with current master branch is that, when doing rails rswag, the task param is generated first. However, the file containing the dry-run setting (for example, environment/test.rb) haven't been loaded at that time

@BookOfGreg BookOfGreg self-assigned this Aug 17, 2020
@gerardo-navarro
Copy link

May I ask what the status of this feature is? It seems to be approved and ready to be merged?

@oblakeerickson oblakeerickson merged commit 5293987 into rswag:master Feb 9, 2021
@oblakeerickson
Copy link
Member

@gerardo-navarro thanks for the bump. This feature is now in the 2.4.0 release.

@igas igas deleted the dry-run-env branch February 10, 2021 06:06
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.

6 participants