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

Support optional step inputs #41

Open
brandonvin opened this issue Nov 18, 2019 · 0 comments
Open

Support optional step inputs #41

brandonvin opened this issue Nov 18, 2019 · 0 comments
Labels
good first issue Good for newcomers

Comments

@brandonvin
Copy link
Contributor

brandonvin commented Nov 18, 2019

greenlight.step/lookup does not allow any inputs to be omitted, so the typical workaround is to do something like the following, which hurts test understandability (step depends on more than just its :inputs) and increases test boilerplate.

#:greenlight.step
{:inputs {:some-required-data (step/lookup :some-required-data)}
 :test (fn [{:keys [some-required-data] :as ctx}]
         (let [some-optional-data (:some-optional-data ctx)]
		   ,,,))}
@brandonvin brandonvin added the good first issue Good for newcomers label Nov 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant