harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ilya Okomin (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-2635) [classlib][swing] DirectColorModel(,,Integer.MIN_VALUE,) does not throw unspecified IAE
Date Tue, 19 Dec 2006 15:50:22 GMT
    [ http://issues.apache.org/jira/browse/HARMONY-2635?page=comments#action_12459676 ] 
            
Ilya Okomin commented on HARMONY-2635:
--------------------------------------

Output from the example is not correct. I received next outputs:

Output on Harmony r483393: 
=======================
.
Time: 0.03

OK (1 test)

Output on RI: 
==========
.E
Time: 0,06
There was 1 error:
1) testRun(test)java.lang.IllegalArgumentException: green mask 80000000 overflows pixel (expecting
6 bits
	at java.awt.image.PackedColorModel.DecomposeMask(PackedColorModel.java:262)
	at java.awt.image.PackedColorModel.<init>(PackedColorModel.java:194)
	at java.awt.image.DirectColorModel.<init>(DirectColorModel.java:165)
	at java.awt.image.DirectColorModel.<init>(DirectColorModel.java:135)
	at test.testRun(test.java:13)
	at jrockit.reflect.VirtualNativeMethodInvoker.invoke(Ljava.lang.Object;[Ljava.lang.Object;)Ljava.lang.Object;(Unknown
Source)
	at test.main(test.java:9)

FAILURES!!!
Tests run: 1,  Failures: 0,  Errors: 1

> [classlib][swing] DirectColorModel(,,Integer.MIN_VALUE,) does not throw unspecified IAE
> ---------------------------------------------------------------------------------------
>
>                 Key: HARMONY-2635
>                 URL: http://issues.apache.org/jira/browse/HARMONY-2635
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>
> There is no mention of any exception in the specification for  DirectColorModel(int bits,int
rmask,int gmask,int bmask).
> RI throws IllegalArgumentException if some argument=Integer.MIN_VALUE while Harmony does
not.
> Compatibility issue.
> Test for reproducing:
> import java.awt.*;
> import java.awt.image.*;
> public class test extends TestCase {      
>     public void test1 () {         
>         new DirectColorModel(6,2,Integer.MIN_VALUE,512);           
>     }      
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .F
> Time: 0.016
> There was 1 failure:
> 1) test1(test)junit.framework.AssertionFailedError: IllegalArgumentException
> sho
> uld be thrown
>         at test.test1(test.java:8)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> FAILURES!!!
> Tests run: 1,  Failures: 1,  Errors: 0

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message