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

Bug 314563

Summary: Inconsistency when test asset names contain spaces
Product: z_Archived Reporter: Ben Chen <chenbs>
Component: TPTPAssignee: Paul Slauenwhite <paulslau>
Status: CLOSED FIXED QA Contact: Kathy Chan <kathy>
Severity: normal    
Priority: P2 CC: jerome.bozier, paulslau
Version: unspecifiedFlags: paulslau: pmc_approved? (oec)
paulslau: pmc_approved? (ernest)
kathy: pmc_approved+
paulslau: pmc_approved? (paulslau)
paulslau: pmc_approved? (ewchan)
paulslau: pmc_approved? (jgwest)
jerome.bozier: review+
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Bug Depends on: 309165    
Bug Blocks: 314885    
Attachments:
Description Flags
Screen Shot
none
Patch. none

Description Ben Chen CLA 2010-05-26 15:57:49 EDT
Build Identifier: TPTP-4.7.0-201005251601

First: When renaming a test asset, same artifact, put a single "(space)" as the name, error message appears to be "The name is too long", see creen shot attachment

Secondly: When creating new test assets, names are allowed to have spaces in the end.

Lastly: When creating new test assets, put a single "(space)" as name, the error message tends to be: " The name cannot begin with a period (.). ", also, the error messages that appear while user specifies invalid characters as name in this fashion is different than those seen in a renaming scenario. For example: when creating new test asset and specify "(space)a" as name would prompt error message "The name is invalid.", where as setting the same name while renaming would show "The name contains invalid characters"

Reproducible: Always
Comment 1 Paul Slauenwhite CLA 2010-05-27 06:36:37 EDT
Did you have a screen shot?
Comment 2 Ben Chen CLA 2010-05-27 10:03:31 EDT
Created attachment 170182 [details]
Screen Shot

(In reply to comment #1)
> Did you have a screen shot?

Yes I do... (how did I manage to forget about it just after mentioning it :/)
Comment 3 Paul Slauenwhite CLA 2010-05-28 10:39:03 EDT
(In reply to comment #0)

> Lastly: When creating new test assets, put a single "(space)" as name, the
> error message tends to be: " The name cannot begin with a period (.). ", also,
> the error messages that appear while user specifies invalid characters as name
> in this fashion is different than those seen in a renaming scenario. For
> example: when creating new test asset and specify "(space)a" as name would
> prompt error message "The name is invalid.", where as setting the same name
> while renaming would show "The name contains invalid characters"

For the inconsistent error messages, please open a new defect.
Comment 4 Paul Slauenwhite CLA 2010-05-28 10:43:56 EDT
Created attachment 170353 [details]
Patch.
Comment 5 Paul Slauenwhite CLA 2010-05-28 10:44:18 EDT
Jerome, please review the attached patch.
Comment 6 Bozier jerome CLA 2010-05-28 10:47:06 EDT
elegant patch, i like it
Comment 7 Ben Chen CLA 2010-05-28 10:49:19 EDT
(In reply to comment #3)
> (In reply to comment #0)
> 
> > Lastly: When creating new test assets, put a single "(space)" as name, the
> > error message tends to be: " The name cannot begin with a period (.). ", also,
> > the error messages that appear while user specifies invalid characters as name
> > in this fashion is different than those seen in a renaming scenario. For
> > example: when creating new test asset and specify "(space)a" as name would
> > prompt error message "The name is invalid.", where as setting the same name
> > while renaming would show "The name contains invalid characters"
> 
> For the inconsistent error messages, please open a new defect.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=314885
Comment 8 Paul Slauenwhite CLA 2010-05-28 12:01:40 EDT
Requesting PMC approval for TPTP 4.7.0: 

  1.   Explain why you believe this is a stop-ship defect. How does the defect manifest itself, and how will users of TPTP / consuming products be affected if the defect is not fixed?

Incorrect error messages when naming test assets.

   2. Is there a work-around? If so, why do you believe the work-around is insufficient?

No.

   3. Is this a regression or API breakage? Explain.

Regressions from defects 309165 and 279090.

   4. Does this require new API?

No.

   5. Who performed the code review?

Jerome Bozier

   6. Is there a test case attached to the bugzilla record?

Updated the following test suites:

/org.eclipse.hyades.test.ui.navigator.tests/junit_plugin/Test.UI.TestUIUtilTest.testsuite
/org.eclipse.hyades.test.ui.navigator.tests/manual/Test.UI.TestNavigator_bugzilla_309165.testsuite
/org.eclipse.hyades.test.ui.navigator.tests/manual/Test.UI.TestNavigator_bugzilla_248413.testsuite

   7. What is the nature of the fix? What is the scope of the fix? What is the risk associated with this fix?

This is caused by test asset name validation not processing the entered name correctly.

   8. Is this fix related to any standards that TPTP adheres to? If so, who has validated that the fix continues to adhere to the standard?

No.
Comment 9 Paul Slauenwhite CLA 2010-05-28 12:56:53 EDT
The attached patch and test suites are checked in to CVS (HEAD).
Comment 10 Ben Chen CLA 2010-06-01 14:52:17 EDT
verified in TPTP-4.7.0-201006011014
Comment 11 Ben Chen CLA 2010-06-01 14:52:33 EDT
(In reply to comment #10)
> verified in TPTP-4.7.0-201006011014

Closing