Bug 106271 - Fold.toString() resturns different strings on 1.5.0 and 6_01
Fold.toString() resturns different strings on 1.5.0 and 6_01
Product: editor
Classification: Unclassified
Component: Code folding
All All
: P4 (vote)
: 6.x
Assigned To: Svata Dedic
Depends on:
  Show dependency treegraph
Reported: 2007-06-11 14:22 UTC by Jiri Prox
Modified: 2016-07-07 07:29 UTC (History)
0 users

See Also:
Issue Type: DEFECT


Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Prox 2007-06-11 14:23:00 UTC
Product Version: NetBeans IDE Dev (Build 070611) 
Java: 1.6.0_02-ea; Java HotSpot(TM) Client VM 1.6.0_02-ea-b02 
System: Linux version 2.6.5-1.358 running on i386; UTF-8; en_US (nb) 
Userdir: /space/u6

toSting method in Fold class returns different string on JDK 1.5.0_12 and
1.6.0_01. The problem is that 
(FoldUtilitiesImpl line 378)
return 0 in one case and 1 in other case. This prevent using goldenfiles in tests. 
If it is as designed, feel free to close this issue and I'll update the test
infrastructure to handle it. Thanks.
Comment 1 Vitezslav Stejskal 2007-06-12 00:27:07 UTC
Are you sure that you have the same set of modules in both scenarios? The 0 or 1
looks like a priority of the fold, which is computed as an index of
FoldManagerFactory that created the fold. If there is a different number of
factories registered the priority of apparently the same fold will be different.
Comment 2 Jiri Prox 2007-06-12 10:41:49 UTC
I've tested it once more time  on latest daily build with jdk 1.5.0_11 and
1.6.0_02 and it it the same, the priority differs.
Comment 3 Vitezslav Stejskal 2007-06-14 00:17:20 UTC
Could you please point me to the test? I'll have a look and hopefuly will find out what the difference is between jdk5
and 6. Thanks.
Comment 4 Jiri Prox 2007-06-14 07:48:16 UTC
The failing test is qa-functional test in java/editor module, class name java_code_folding.JavaFoldsTest, to run from
xtest you can use attribute "folding"
Comment 5 Jiri Prox 2008-04-11 00:45:11 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 6 David Strupl 2009-06-08 14:13:06 UTC
Marek, these are yours now ...
Comment 7 Martin Balin 2016-07-07 07:29:07 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo