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

Reusing @Table #235

Closed
nikowitt opened this issue Sep 27, 2016 · 5 comments
Closed

Reusing @Table #235

nikowitt opened this issue Sep 27, 2016 · 5 comments

Comments

@nikowitt
Copy link
Contributor

Good morning,

I'm currently encountering the situation that I want to reuse a @table

@Table(columnTitles = { ProjectPerformanceQuestionnaire.ON_TIME_DELIVERY,
                ProjectPerformanceQuestionnaire.PRODUCT_QUALITY,
                ProjectPerformanceQuestionnaire.SITE_CAPABILITY,
                ProjectPerformanceQuestionnaire.CLAIM_BEHAVIOUR }, includeNullColumns = true) 

I'd expected to be able to provide this as a meta annotation in my custom annotation as this is possible for other formatters, but this is not allowed. Is there an easy way of being able to do so?

Best regards,
Niko

@janschaefer
Copy link
Contributor

The meta-annotation should definitely be implemented!

@janschaefer
Copy link
Contributor

The fun fact is that it already worked, I only had to allow the @Table annotation to be applicable at annotations type.

@nikowitt
Copy link
Contributor Author

nikowitt commented Sep 28, 2016

Great. Too bad that the change was performed after the nightly build succeeded :)

@janschaefer janschaefer modified the milestones: v0.12.2, v0.13.0 Oct 9, 2016
@nikowitt
Copy link
Contributor Author

nikowitt commented Nov 2, 2016

FYI: Works fine with jgiven-core-0.12.2-20161101.222126-16.jar by using

    @Table(columnTitles = { ProjectPerformanceQuotationQuestionnaire.ON_TIME_DELIVERY,
                ProjectPerformanceQuotationQuestionnaire.PRODUCT_QUALITY,
                ProjectPerformanceQuotationQuestionnaire.SITE_CAPABILITY,
                ProjectPerformanceQuotationQuestionnaire.CLAIM_BEHAVIOUR }, includeNullColumns = true)
        @Retention(value = RetentionPolicy.RUNTIME)
        static @interface PPQTable {

        }

In this case, the annotation is a static inner class as it is only used in this test class.

@janschaefer
Copy link
Contributor

Ok, cool. Thanks for testing!

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

No branches or pull requests

2 participants