[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-12 Thread dmitriy.lapko
BTW, my last 2 problems are solved. First, with long running conversation, 
shows, that it is really not so intuitive - to test Seam... In my test I didn't 
get conversationId and didn't pass it to next created FacesRequest. With second 
- I just start tests in a new Thread with overwritten empty 
startJBossEmbededdedIfNecessary.

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4103679#4103679

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4103679
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-12 Thread _polly
[EMAIL PROTECTED] wrote : Are people actually using Seam's integration 
testing stuff?

We've been using it, but have had a few problems.

- If the domain model changes and the import-test.sql file isn't updated 
accordingly, there is no helpful SQLException to explain what went wrong. 
Instead you just have to painstakingly go through all the changes in source 
control to try and figure out what is wrong with the sql.

- Instead of using import-test.sql, it would be nice to be able to represent 
this data in xml, like with DBUnit, and re-initialise with this data set at the 
start of each test.

- Sometimes the tests randomly fail with a ConcurrentModificationException

- @Min hibernate validation doesn't appear to work (I started a separate thread 
about this one: http://www.jboss.com/index.html?module=bbop=viewtopict=123458)

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4103715#4103715

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4103715
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-12 Thread [EMAIL PROTECTED]
alanlynott wrote : (4) Seam's integration testing stuff has fundamental 
limitations like no decent error messages, integration with DBUnit, etc.

We have integration with DBUnit in Seam 2 (it's very nice IMO).  Please 
elaborate on your error message comment :) We can only make it better with 
feedback from users!

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4103716#4103716

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4103716
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-12 Thread [EMAIL PROTECTED]
dmitriy.lapko wrote : 1) If Seam is not bounded to JSF, why SeamTest should 
be bounded to JSF Phases? I just not really like for testing purposes use all 
these FacesRequest multiple implemnetations just to call a method of the 
component... And this doesn't add flexibility to my tests - e.g. if I want to 
pass any value from one call of FacesRequest to other I have to create a global 
field in class.

Have you tried using ComponentTest instead? This doesn't emulate the JSF 
lifecycle.

anonymous wrote : 2) If I use facinating Seam-features like EL in QL, I cannot 
unit test my application - I need all framework to be started to enable all 
these Interceptors for my code. What a pity... 

Do you have this working now (I got a bit lost in your posts ;)?

anonymous wrote : 3) If you would like to prepare some test data before 
executing FacesRequest or to check what was really done in database - you 
cannot use current configuration of database and have to add your own to make 
queries. Annoying...

The DBUnit SeamTest is perfect for this (see the Seamdiscs example).

anonymous wrote : Because of complexity of configuration of tests and of using 
them (to write integrational test you have to know Seam like half as Gavin 
knows it...) they are just unusable for normal team member. I'm sure that 
SeamTest using should be simplified, now it is too complex.

I know what you mean. However I don't see how we can make it simpler (yes, we 
can improve the library setup, but not the structure of the Test harness 
afaics). Have you got specific ideas to share? :)

anonymous wrote : 1) I have two consecutive FacesRequest calls to methods, 
first of which should start long running conversation and second should end it. 
First marked by @Begin and second - by @End annotations. 

You have to manually pass the conversation id around. Please file a JIRA issue 
to improve the docs for this - its not currently good!

anonymous wrote : 2) I run my unit tests inside the deployed and started 
application. I want to do it also with SeamTests. But disabling of starting 
embedd ejb container didn't help - anyway a new SeamPhaseListener is started 
and all other stuff which breaks the application inside which everything was 
started.

Don't understand this...

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4103719#4103719

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4103719
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-08 Thread joris77
Hi,

We would like to use the seamtest but, we use junit already and are not 
planning to switch test framework. Not because I like junit or testng better 
but I just like to stick with one testing framework. 

Joris wijlens

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4102877#4102877

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4102877
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-08 Thread trickyvail
Currently there is too much we need it now at my company for management to 
see the value in testing so I have not explored the seam testing functionality. 
However, I personally expect to utilize testing extensively in the near future 
and would strongly urge you to continue it's integration and development in 
seam.

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4102914#4102914

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4102914
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-08 Thread seamdev

 I have tried seam integration testing in past and have not been able to get it 
working. Support about it was also not strong on forums so we are using other 
tools to do integration test. 

 If there is some significant improvement in seam 2 ga, I am interested in 
using seam integration test. May be we should have a poll to see how many 
people have been able to successfully use integration test?

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4102982#4102982

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4102982
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-08 Thread alanlynott
[EMAIL PROTECTED] wrote : Are people actually using Seam's integration 
testing stuff? I've seen very few questions about this, which allows various 
possible explanations:
  | 
  | (1) Everyone is using it and it Just Works
  | (2) No-one understands it or no-one knows it exists
  | (3) No-one does integration testing
  | (4) There is some fundamental limitation which means people can't use it on 
their projects (eg. they are required to use JUnit instead of TestNG)
  | 
  | Any feedback on this would be very useful.
  | 
  | Thanks

(4) Seam's integration testing stuff has fundamental limitations like no decent 
error messages, integration with DBUnit, etc.

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4102995#4102995

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4102995
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [JBoss Seam] - Re: Question about SeamTest

2007-11-08 Thread dmitriy.lapko
I'm trying to use SeamTest and with some success. 

But I have some unclear questions: 

1) If Seam is not bounded to JSF, why SeamTest should be bounded to JSF Phases? 
I just not really like for testing purposes use all these FacesRequest multiple 
implemnetations just to call a method of the component... And this doesn't add 
flexibility to my tests - e.g. if I want to pass any value from one call of 
FacesRequest to other I have to create a global field in class. 

2) If I use facinating Seam-features like EL in QL, I cannot unit test my 
application - I need all framework to be started to enable all these 
Interceptors for my code. What a pity... 

3) If you would like to prepare some test data before executing FacesRequest or 
to check what was really done in database - you cannot use current 
configuration of database and have to add your own to make queries. Annoying...

Because of complexity of configuration of tests and of using them (to write 
integrational test you have to know Seam like half as Gavin knows it...) they 
are just unusable for normal team member. I'm sure that SeamTest using should 
be simplified, now it is too complex.

For now I have next problems which I cannot solve:

1) I have two consecutive FacesRequest calls to methods, first of which should 
start long running conversation and second should end it. First marked by 
@Begin and second - by @End annotations. The problem is that they don't work in 
the same conversation - in second call I have:

new FacesRequest() {
  | @Override
  | protected void invokeApplication() {
  | invokeMethod(#{basket.createBasket});
  | }
  | @Override
  | protected void renderResponse() throws Exception {
  | assert Manager.instance().isLongRunningConversation();
  | }
  | }.run();
  | 
  | new FacesRequest() {
  | @Override
  | protected void updateModelValues() throws Exception {
  | assert Manager.instance().isLongRunningConversation();
  | }   
  | @Override
  | protected void invokeApplication() {
  | invokeMethod(#{basket.saveBasket});
  | }
  | }.run();
  | 

So first assertion inside first request passed successfully. Second - fails. 
Why?

2) I run my unit tests inside the deployed and started application. I want to 
do it also with SeamTests. But disabling of starting embedd ejb container 
didn't help - anyway a new SeamPhaseListener is started and all other stuff 
which breaks the application inside which everything was started.

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=4103078#4103078

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4103078
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user