Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 103614

Summary: build tests can not run due to blocking XML Validation Tests
Product: [WebTools] WTP Source Editing Reporter: David Williams <david_williams>
Component: wst.xmlAssignee: Lawrence Mandel <lmandel>
Status: CLOSED FIXED QA Contact:
Severity: blocker    
Priority: P3 CC: jeffliu, naci.dai, ryman, thatnitind
Version: unspecified   
Target Milestone: 1.0 M6   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Patch for org.eclipse.wst.xml.validation.tests
none
Patch for releng.builder
none
Patch for releng.builder to support wtp.autotest.noninteractive property none

Description David Williams CLA 2005-07-13 03:22:02 EDT
As on mailing list, AllXMLTests hang build machine, presumably because the
dialog to prompt user for license it being "poped up" on un-attended (near
headless) machine.
Comment 1 Jeffrey Liu CLA 2005-07-13 11:25:27 EDT
Created attachment 24667 [details]
Patch for org.eclipse.wst.xml.validation.tests

This patch will set the wtp.quiet system property when AllXMLTest is run.
Comment 2 Jeffrey Liu CLA 2005-07-13 11:47:22 EDT
Just to update everyone on this. Reason why the fix was not done on the master 
test script level is because passing in the "extraVMArgs" properties from the 
master script will override other VM args specified in the individual scripts 
(for example, Tomcat install location). So if we want to pass in this property 
from the master script, we need to rework some of the individual scripts, and 
that will be dangerous at this point. So the safest approach (at least for now) 
is to pass in the property from the XML validation test script.
Comment 3 David Williams CLA 2005-07-13 12:08:48 EDT
Thanks for the patch and the conceptual explaination, Jeffrey. 

BTW, I had tried "forcefully" removing the XMLValidator test causing the
problem, but the hang just occurred later .... at least in J2EE tests, if not
else where, so there is a lot to work through. 

BTW, is it possible to take advantage of Ant's -noinput property in this regard? 
Seems that should be set anyway, right? And maybe could be done globally and
wouldn't require "wtp.quiet" to be set?


Comment 4 Jeffrey Liu CLA 2005-07-13 12:30:01 EDT
We should probably pass in -noinput regardless. However, I don't think this 
option will help the current hang because our hang has to do with a user click.

Since the scope of this problem is more than just XML validation, I'll look 
into the "pass in property from the master script" approach... Stay tunned.
Comment 5 Lawrence Mandel CLA 2005-07-13 12:38:09 EDT
From http://codefeed.com/blog/?p=68:
"For unattended builds, you can use the -noinput flag whereupon any attempt to
read input in Ant will cause an end-of-file result to be given to the read."
Comment 6 Jeffrey Liu CLA 2005-07-13 13:53:50 EDT
Created attachment 24683 [details]
Patch for releng.builder

This patch will pass in the wtp.quiet property from the master test script
level without overriding the custom VM args defined in the individual test
scripts. However, I wasn't able to test it on my local build because something
else failed... not sure what it is. Anyways, are we brave enough to try it?
Comment 7 David Williams CLA 2005-07-13 14:21:27 EDT
Thanks Jeffrey, it looks like this patch would work transparently, to me. 

Naci, can you please review too? 

Lawrence, 

1. I would like the wtp.quiet property renamed, though ... "quiet" usually refers
to output ... I think wtp.noninteractive would be better. (And, please, if you
find that value set 'true' in your "product" code, please log it to console log
... it might be a source of reports during non-test use of something "not
working" if some user were to innocently set it, not knowing fully what it was
for ... perhaps a name of wpt.internal.testonly.noninteractive would be better?
-- in addition to logging it. 

2. I would like Bug 103611 addressed before the cache license re-released. 

3. I would also like to be sure there is a "practice build" done before the
cache license is re-released. 

So ... I'm assuming this will all be done post RC1. If you feel we should not
declare RC1 without the license code in place, then please have Arthur review
issures and work items, for his help in getting the corrective actions in place,
and make a decision if further delays warrented. 
Comment 8 Lawrence Mandel CLA 2005-07-13 17:08:27 EDT
David,

1. Good idea. Do you think wtp.internal.testonly.noninteractive is necessary?
Will wtp.noninteractive be fine? How about wtp.autotest.noninteractive? (The
name just needs to be clear, the exact name is not very important to me.) I have
a fix ready that will log the use of this property to the log now we just need
to decide on the var name.

2. I'm working on bug 103611 but so far have been unable to reproduce.

3. Agreed. 

I want to make it clear that the license code is already in place. The
significant change was to enable the cache by default. With the cache off by
default a user can still choose to enable the cache and will then be prompted
for a license and may run into the same problem as you have.
Comment 9 Naci Dai CLA 2005-07-13 17:15:26 EDT
Jeff thanks,   the patch seems ok.
Comment 10 David Williams CLA 2005-07-13 17:50:40 EDT
Lawrence, I think "wtp.autotest.noninteractive" would be good. 
The name isn't *real* important to me .. but "wtp.quiet" sounds like 
something I'd just try out for fun just because its sounds like it must 
be something really good. :)

I'll check my browser versions and setup later tonight.

I guess technically, we don't need to do a "practice build" ... just to 
set up an "ant test environment" and run the built, packaged JUnits, with just 
that one prefernce or jar changed ... if that's any easier for you or others. 
Comment 11 Lawrence Mandel CLA 2005-07-14 04:56:32 EDT
I've changed the system property to wtp.autotest.noninteractive.
Comment 12 Lawrence Mandel CLA 2005-07-14 04:58:55 EDT
Created attachment 24744 [details]
Patch for releng.builder to support wtp.autotest.noninteractive property

The patch above is similar to Jeff's patch. Two differences.
1. The property name is updated to reflect the change.
2. Instead of creating a second library xml file the extraVMargs property is
passed directly to the test script.

I am running unit tests on the 0713 build now. So far so good. I'll report the
complete status once they finish.
Comment 13 Lawrence Mandel CLA 2005-07-14 05:20:50 EDT
The test results look good on my machine. The tests ran unattended and completed
successfully. I ran the tests on a WindowsXP box after downloading the 0713 build. 

1. As stated, the rename of the system property is complete.

2. In progress.

3. Success in running the ant test environment.
Comment 14 David Williams CLA 2005-07-15 11:26:46 EDT
I have reviewed and approve this fix and moving forward on getting this change
into the builds. 
Comment 15 Lawrence Mandel CLA 2005-07-15 13:37:03 EDT
Fix committed. Test build ran to completion. 
Comment 16 David Williams CLA 2005-07-15 13:45:27 EDT
How's this for my fastest verification :)
Comment 17 Lawrence Mandel CLA 2005-07-15 15:44:55 EDT
Thanks David. Closing bug.