-
Notifications
You must be signed in to change notification settings - Fork 24
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 ability to turn off SPI #79
Comments
DataSupplier has a feature, which allows you adding |
I'm aware of it. I still would like to be able to disable SPI mechanism |
But the feature you're asking for doesn't really depend on SPI. Even if we turn it off, how would you resolve 2 |
We have a separate mechanism which allows us use multiple annotation transformers, even from 3-rd party libraries. |
So maybe it's better to implement the same within DataSupplier instead of turning SPI off? :) |
Yes, I think we can implement it using your approach but it appeared to me that allowing to disable it is more flexible approach. |
Well, I was asking if we can implement your approach instead (a separate mechanism which allows you to use multiple annotation transformers, even from 3-rd party libraries). I just need to know implementation details. |
We extend DataProviderTransformer and also add marker interface to be able to add this annotation After that we add DataSupplierListener to |
@da-yaroslav-orel sorry for the delay, was busy these days... I'll check if I can easily implement your approach this weekend... or will take a look at SPI-off feature otherwise... |
@da-yaroslav-orel I've double-checked both options. Seems like your current implementation does exactly the same thing as |
Just double-checked on the latest Allure version. Seems like there was a bug in prev versions when spi-off jars weren't published. On a latest one it's present. So I guess we can proceed the same way. You'll just need to use classifiers to select required jar distribution. Will double check everything again and release a new version. |
@sskorol great news. Thanks. |
Should be fixed in 1.8.5. |
@da-yaroslav-orel did you have a chance to try it? |
@sskorol yes. tried it today. it works. many thanks!!! |
It might be better to factor services to a separate jar artifact, so
|
Makes sense. But as this feature was requested by only a single user for the past 4 years, I'd consider adding such an improvement with the next Java release, unless anyone wants to raise a PR before. Thanks for pointing it out. |
Just in case, I found this issue when exploring the way to support I have no explicit requests for test-data-supplier |
Hi. We would like to have an ability to disable SPI in test-data-supplier.
Motivation: In our project we already have SPI with AnnotationTransformer. Adding test-data-supplier will break our tests because TestNG doesn't allow more than one annotation transformer enabled.
Possible solution: I spotted an interesting feature in allure-testng library. It allows to disable SPI by specifying 'spi-off' classifier in dependencies.
https://github.com/allure-framework/allure-java/blob/master/allure-testng/build.gradle.kts
It would be great if test-data-supplier has something similar. We love this library but due to SPI conflict we are forced to use old version without SPI: 1.4.0
Note: We understand that without SPI test-data-supplier's annotation transformer would require manual handling but we're ok with that.
The text was updated successfully, but these errors were encountered: