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 support for validate_with [PRC] #8

Merged
merged 1 commit into from Jul 11, 2018
Merged

Conversation

@jjatria
Copy link
Contributor

@jjatria jjatria commented Jun 20, 2018

This adds an override for validate_with called with a single dependency as

# Will fail
validate_with(
    params       => [ foo => 'foo', bar => 'bar' ],
    spec         => { foo => 1, bar => 1, optional => 0 },
    dependencies => all_of(qw( foo optional )),
);

or with an array of them as

validate_with(
    params       => [ foo => 'foo', bar => 'bar' ],
    spec         => { foo => 1, bar => 1, optional => 0 },
    dependencies => [ one_of('foo'), one_of('bar') ],
);

This PR brought to you courtesy of the PRC.

@jjatria jjatria force-pushed the jjatria:validate-with branch from 755c862 to 7970f34 Jun 20, 2018
@coveralls
Copy link

@coveralls coveralls commented Jun 20, 2018

Coverage Status

Coverage remained the same at 100.0% when pulling e462cfc on jjatria:validate-with into b212057 on DrHyde:master.

@jjatria jjatria force-pushed the jjatria:validate-with branch from 7970f34 to e462cfc Jun 21, 2018
@DrHyde DrHyde merged commit f78a74b into DrHyde:master Jul 11, 2018
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 100.0%
Details
@DrHyde
Copy link
Owner

@DrHyde DrHyde commented Jul 11, 2018

Thanks, merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants