You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Ephemeris Lappis <ep...@gmail.com> on 2022/12/29 11:52:04 UTC
Camel 3.x and CamelBlueprintTestSupport+CamelTestSupport
Hello.
One more surprise with Camel 3.x. The class CamelTestSupport has been
deprecated, while CamelBlueprintTestSupport seems to use it with no
depreciation.
I can't find any valid replacement to test blueprint contexts. Did I
miss something ? Should we use deprecated code for tests ?
Thanks again !
Regards.
Re: Camel 3.x and CamelBlueprintTestSupport+CamelTestSupport
Posted by Santiago Acosta <sa...@intermodaltelematics.com>.
You are very welcome. Good thing that it looks like it is a simple upgrade
On Mon, Jan 2, 2023 at 2:45 PM Ephemeris Lappis <ep...@gmail.com>
wrote:
> Hello again !
>
> Well, it was quite easy to make a first simple test work again :) !
>
> Before, with Junit 4, overriding the setUp method was enough to add
> some startup code and then call the super method : overriding in junit
> 4 let the @Before as is... It seems that now the @BeforeEach of Junit
> 5 is required explicitly on overridden methods...
>
> At the same time I must learn Junit 5 by the way !
>
> Thanks.
>
> Regards.
>
> Le lun. 2 janv. 2023 à 14:10, Santiago Acosta
> <sa...@intermodaltelematics.com> a écrit :
> >
> > You made me worry so I went looking for
> >
> https://github.com/apache/camel/blob/main/components/camel-test/camel-test-junit5/src/main/java/org/apache/camel/test/junit5/CamelTestSupport.java
> > - on Branch main
> > - for Framework Junit5
> > and it does not have a deprecation notice.
> > What CamelTestSupport are you currently using?
> >
> > On Thu, Dec 29, 2022 at 11:52 AM Ephemeris Lappis <
> > ephemeris.lappis@gmail.com> wrote:
> >
> > > Hello.
> > >
> > > One more surprise with Camel 3.x. The class CamelTestSupport has been
> > > deprecated, while CamelBlueprintTestSupport seems to use it with no
> > > depreciation.
> > >
> > > I can't find any valid replacement to test blueprint contexts. Did I
> > > miss something ? Should we use deprecated code for tests ?
> > >
> > > Thanks again !
> > >
> > > Regards.
> > >
> >
> >
> > --
> > Best regards,
> > *Santiago Acosta Arreaza*
> >
> > Intermodal Telematics S.L.
> > Prisma building, 1st floor, Office 1.5
> > Fotógrafo José Norberto Rguez. Díaz st., 2
> > San Cristobal de La Laguna, SC de Tenerife
> > 38204, Spain
> >
> >
> > +34 922 31 56 05
> > www.intermodaltelematics.com
>
--
Best regards,
*Santiago Acosta Arreaza*
Intermodal Telematics S.L.
Prisma building, 1st floor, Office 1.5
Fotógrafo José Norberto Rguez. Díaz st., 2
San Cristobal de La Laguna, SC de Tenerife
38204, Spain
+34 922 31 56 05
www.intermodaltelematics.com
Re: Camel 3.x and CamelBlueprintTestSupport+CamelTestSupport
Posted by Ephemeris Lappis <ep...@gmail.com>.
Hello again !
Well, it was quite easy to make a first simple test work again :) !
Before, with Junit 4, overriding the setUp method was enough to add
some startup code and then call the super method : overriding in junit
4 let the @Before as is... It seems that now the @BeforeEach of Junit
5 is required explicitly on overridden methods...
At the same time I must learn Junit 5 by the way !
Thanks.
Regards.
Le lun. 2 janv. 2023 à 14:10, Santiago Acosta
<sa...@intermodaltelematics.com> a écrit :
>
> You made me worry so I went looking for
> https://github.com/apache/camel/blob/main/components/camel-test/camel-test-junit5/src/main/java/org/apache/camel/test/junit5/CamelTestSupport.java
> - on Branch main
> - for Framework Junit5
> and it does not have a deprecation notice.
> What CamelTestSupport are you currently using?
>
> On Thu, Dec 29, 2022 at 11:52 AM Ephemeris Lappis <
> ephemeris.lappis@gmail.com> wrote:
>
> > Hello.
> >
> > One more surprise with Camel 3.x. The class CamelTestSupport has been
> > deprecated, while CamelBlueprintTestSupport seems to use it with no
> > depreciation.
> >
> > I can't find any valid replacement to test blueprint contexts. Did I
> > miss something ? Should we use deprecated code for tests ?
> >
> > Thanks again !
> >
> > Regards.
> >
>
>
> --
> Best regards,
> *Santiago Acosta Arreaza*
>
> Intermodal Telematics S.L.
> Prisma building, 1st floor, Office 1.5
> Fotógrafo José Norberto Rguez. Díaz st., 2
> San Cristobal de La Laguna, SC de Tenerife
> 38204, Spain
>
>
> +34 922 31 56 05
> www.intermodaltelematics.com
Re: Camel 3.x and CamelBlueprintTestSupport+CamelTestSupport
Posted by Ephemeris Lappis <ep...@gmail.com>.
Hello !
Well, I understand from your answer that another module exists for
junit5 with classes that are not deprecated.
I've just changed my dependency to "camel-test-blueprint-junit5" and
indeed warnings disappeared.
I also had to make some changes for mockito, runner, etc., but now my
tests fail with exceptions that I had not before, as if the blueprint
test lifecycle had changed... I'm going to check that on my side...
I didn't guess that I had to search for renamed artifacts :(...
Thanks for your help.
Regards.
Le lun. 2 janv. 2023 à 14:10, Santiago Acosta
<sa...@intermodaltelematics.com> a écrit :
>
> You made me worry so I went looking for
> https://github.com/apache/camel/blob/main/components/camel-test/camel-test-junit5/src/main/java/org/apache/camel/test/junit5/CamelTestSupport.java
> - on Branch main
> - for Framework Junit5
> and it does not have a deprecation notice.
> What CamelTestSupport are you currently using?
>
> On Thu, Dec 29, 2022 at 11:52 AM Ephemeris Lappis <
> ephemeris.lappis@gmail.com> wrote:
>
> > Hello.
> >
> > One more surprise with Camel 3.x. The class CamelTestSupport has been
> > deprecated, while CamelBlueprintTestSupport seems to use it with no
> > depreciation.
> >
> > I can't find any valid replacement to test blueprint contexts. Did I
> > miss something ? Should we use deprecated code for tests ?
> >
> > Thanks again !
> >
> > Regards.
> >
>
>
> --
> Best regards,
> *Santiago Acosta Arreaza*
>
> Intermodal Telematics S.L.
> Prisma building, 1st floor, Office 1.5
> Fotógrafo José Norberto Rguez. Díaz st., 2
> San Cristobal de La Laguna, SC de Tenerife
> 38204, Spain
>
>
> +34 922 31 56 05
> www.intermodaltelematics.com
Re: Camel 3.x and CamelBlueprintTestSupport+CamelTestSupport
Posted by Santiago Acosta <sa...@intermodaltelematics.com>.
You made me worry so I went looking for
https://github.com/apache/camel/blob/main/components/camel-test/camel-test-junit5/src/main/java/org/apache/camel/test/junit5/CamelTestSupport.java
- on Branch main
- for Framework Junit5
and it does not have a deprecation notice.
What CamelTestSupport are you currently using?
On Thu, Dec 29, 2022 at 11:52 AM Ephemeris Lappis <
ephemeris.lappis@gmail.com> wrote:
> Hello.
>
> One more surprise with Camel 3.x. The class CamelTestSupport has been
> deprecated, while CamelBlueprintTestSupport seems to use it with no
> depreciation.
>
> I can't find any valid replacement to test blueprint contexts. Did I
> miss something ? Should we use deprecated code for tests ?
>
> Thanks again !
>
> Regards.
>
--
Best regards,
*Santiago Acosta Arreaza*
Intermodal Telematics S.L.
Prisma building, 1st floor, Office 1.5
Fotógrafo José Norberto Rguez. Díaz st., 2
San Cristobal de La Laguna, SC de Tenerife
38204, Spain
+34 922 31 56 05
www.intermodaltelematics.com