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

Simplify validation on #source #14737

Merged
merged 1 commit into from
Apr 12, 2017

Conversation

bdunne
Copy link
Member

@bdunne bdunne commented Apr 11, 2017

Simple extraction from #12949 with additional cleanup. Source lines

Before:

irb(main):001:0> MiqProvisionRequest.create!
ActiveRecord::RecordInvalid: Validation failed: Source must have valid template, Vm template must have valid VM (must be in vmdb), Userid must have valid user

After:

irb(main):001:0> MiqProvisionRequest.create!
ActiveRecord::RecordInvalid: Validation failed: Source can't be blank, Userid must have valid user

Before:
```
irb(main):001:0> MiqProvisionRequest.create!
ActiveRecord::RecordInvalid: Validation failed: Source must have valid template, Vm template must have valid VM (must be in vmdb), Userid must have valid user
```

After:
```
irb(main):001:0> MiqProvisionRequest.create!
ActiveRecord::RecordInvalid: Validation failed: Source can't be blank, Userid must have valid user
```
@miq-bot
Copy link
Member

miq-bot commented Apr 11, 2017

Checked commit bdunne@1cab426 with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 0 offenses detected
Everything looks good. 👍

@gmcculloug gmcculloug merged commit a308c60 into ManageIQ:master Apr 12, 2017
@gmcculloug gmcculloug added this to the Sprint 59 Ending Apr 24, 2017 milestone Apr 12, 2017
@bdunne bdunne deleted the simplify_source_validation branch April 12, 2017 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants