Skip to content

Conversation

@marko-bekhta
Copy link
Member

added checks for parameters and corresponding test cases

This one is a part from changes made in HV-840 to complete what was started in HV-270

Copy link
Member

Choose a reason for hiding this comment

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

Looks like your formatter is doing weird things with annotations. The initial formatting is what our Eclipse formatter does (I fixed it when merging your previous PR).

Copy link
Member

Choose a reason for hiding this comment

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

Same here, it should be: @Digits(integer = -1, fraction = 3).

I would have fixed it when merging but as you are a regular contributor, we might as well have your formatters right ;). We provide IDE configuration here: https://github.com/hibernate/hibernate-ide-codestyles . I know for sure the Eclipse ones are OK but if you use Intellij and there are problems with the configuration file we provide, we might as well fix them! Thanks for your feedback on this!

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for the link on formatters - it worked just great! Also importing of formatter in Intellij can be done through the UI rather than copying files :)

One day I'll create a PR and you wouldn't need to clean up anything after me :)

Copy link
Member

Choose a reason for hiding this comment

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

We're nearly there! We have a space after { in the annotations and it looks like the Intellij formatter removes it.

It should be:

@Digits.List({ @Digits(integer = -5, fraction = -3), @Digits(integer = 5, fraction = -3) })

If it's an issue with the formatter we provide, could you fix it and open a PR for it?

Once this one is solved, I think we won't have any formatting issue left! :)

Copy link
Member Author

Choose a reason for hiding this comment

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

should be correct now :) I'll open a PR for formatter with corresponding update

* <p>
* Checks whether the given annotations are correctly specified at the given
* method parameter. The following checks are performed:
* </p>
Copy link
Member

Choose a reason for hiding this comment

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

OK, so everything looks good apart from this comment here. With this patch, we actually check the constraints validity on parameters. I think the comment is meant for the other patch. Could you fix it? Then I'll merge this one. Thanks!

Copy link
Member Author

Choose a reason for hiding this comment

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

Good catch :) this was copied over from HV-840. Thanks ! I've made a change.

@gsmet gsmet self-assigned this Oct 7, 2016
@gsmet
Copy link
Member

gsmet commented Oct 10, 2016

Merged! Thanks!

@gsmet gsmet closed this Oct 10, 2016
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