Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 311172 - Javascript GCTest fails in Firefox 3.0
Summary: Javascript GCTest fails in Firefox 3.0
Status: RESOLVED FIXED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 1.3   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 1.3 RC1   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-30 09:36 EDT by Ralf Sternberg CLA
Modified: 2010-05-07 10:13 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ralf Sternberg CLA 2010-04-30 09:36:03 EDT
Firefox 3.0.19 on Ubuntu:

+ org.eclipse.rwt.test.tests.GCTest
testCreateAndDisposeGC - OK
testCreateGCBeforeControl - OK
testCanvasWithChildren - OK
testSetAndResetFields - OK
testSaveAndRestoreFields failed:
Assert "14", type "assertEquals" failed : Expected "italic bold 16px Arial" but found "10px Arial"
13 asserts succeeded.
Tests aborted!
Comment 1 Ivan Furnadjiev CLA 2010-04-30 10:34:16 EDT
In Firefox, the <canvas> context "font" attribute requires Gecko 1.9.1 ( Firefox 3.5+ ). As we don't use canvas for drawing the text (for the same reason - Firefox 3.5+ is needed ) we can introduce "font" property in GC.js instead of canvas context.
Comment 2 Ivan Furnadjiev CLA 2010-05-05 03:39:09 EDT
Looking more deeply into the issue I found that the problem is not in the "font" attribute itself, but in context save() and restore() function. As canvas context "font" attribute is not supported in FF < 3.5, save/restore do not respect it. We don't use save/restore of "font" attribute in our code, thus - no broken functionality. Need to fix only the test somehow.
Comment 3 Ivan Furnadjiev CLA 2010-05-07 10:13:00 EDT
Fixed in CVS HEAD.