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

Bug 370094

Summary: incorrect result when using 'extend' function after the 29th of each month
Product: z_Archived Reporter: Tom B <tmbarans>
Component: EDTAssignee: Project Inbox <edt.javascriptgen-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: hjiyong, margolis, svihovec
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
See Also: https://bugs.eclipse.org/bugs/show_bug.cgi?id=365262
Whiteboard:

Description Tom B CLA 2012-01-30 02:54:21 EST
Build Identifier: EDT 0.8.0.v201201292103

EDT timestamp 'extend' function returns an incorrect result when using the function myTimestamp.extend("HHmmss") if myTimestamp represents February 29 and you are running the program after the 29th of each month. 

If you run the program before the 29th of each month, the timestamp will be
created correctly. This error only occurs for Javascript generation. 

Same problem occurs with extend("HHmm") and extend("mmss")

This problem is similar to https://bugs.eclipse.org/bugs/show_bug.cgi?id=365262

Reproducible: Always

Steps to Reproduce:
1. Set Windows clock to the 30th or 31st of the month
2. From org.eclipse.edt.eunit.test, generate ETimestamp009.egl to javascript
3. Run the generated egl rui file in a browser. 

The testcases runExtendFunction07,08,09 show an incorrect result being returned. The testcases runExtendFunction17,18,19 are the same but with variable timestamps instead of constant timestamps
Comment 1 Tom B CLA 2012-09-10 01:10:11 EDT
Fixed with patch provided for bug 372937