Skip to content

Commit

Permalink
8234194: [TEST_BUG] Reenable few graphics unit tests
Browse files Browse the repository at this point in the history
Reviewed-by: kcr
  • Loading branch information
arapte committed Nov 16, 2019
1 parent 927fc8a commit 4f496d4
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 19 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand All @@ -26,14 +26,13 @@
package test.com.sun.javafx.scene.layout.region;

import javafx.scene.layout.BackgroundRepeat;
import org.junit.Ignore;
import org.junit.Test;
import javafx.css.ParsedValue;
import com.sun.javafx.css.ParsedValueImpl;
import com.sun.javafx.scene.layout.region.RepeatStruct;

import static org.junit.Assert.assertEquals;
import com.sun.javafx.scene.layout.region.RepeatStructConverter;
import static org.junit.Assert.fail;
import com.sun.javafx.scene.layout.region.RepeatStructConverter;

/**
Expand All @@ -54,8 +53,8 @@ public class BackgroundRepeatConverterTest {
/*
-fx-background-repeat: null
*/
@Ignore ("this doesn't work, but I'm not sure what would happen with a null background-repeat in reality")
@Test public void scenario2() {
@Test
public void scenario2() {
ParsedValue<String,BackgroundRepeat>[][] values = new ParsedValueImpl[][] {
{null}
};
Expand All @@ -64,8 +63,12 @@ public class BackgroundRepeatConverterTest {
new ParsedValueImpl<ParsedValue<String,BackgroundRepeat>[][], RepeatStruct[]>(
values, null
);
RepeatStruct[] results = RepeatStructConverter.getInstance().convert(value, null);
assertEquals(0, results.length, 0);
try {
RepeatStruct[] results = RepeatStructConverter.getInstance().convert(value, null);
fail("Expected NullPointerException");
} catch (NullPointerException expected) {
// Test Pass, NPE is expected
}
}

/*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -39,7 +39,6 @@
import javafx.util.Duration;

import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;

import java.io.IOException;
Expand Down Expand Up @@ -181,7 +180,6 @@ public void write(int i) throws IOException {
assertEquals(3, eventHandler.callCount);
}

@Ignore
@Test
public void testJumpTo() {
// jumpTo on stopped timeline
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -65,7 +65,6 @@
import org.junit.Ignore;
import org.junit.Test;

@Ignore
public class Node_cssStyleMap_Test {

public Node_cssStyleMap_Test() {
Expand Down Expand Up @@ -101,6 +100,7 @@ private void checkFoundStyle(Property<?> property, Map<StyleableProperty<?>, Lis

}

@Ignore("JDK-8234241")
@Test
public void testStyleMap() {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -34,7 +34,6 @@
import javafx.scene.shape.Rectangle;

import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameters;
Expand All @@ -49,7 +48,6 @@
import javafx.scene.ImageCursor;
import javafx.scene.Node;

@Ignore ("pending RT-35594")
@RunWith(Parameterized.class)
public final class Node_cssMethods_Test extends CssMethodsTestBase {
private static final Node TEST_NODE = new Rectangle();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -3375,7 +3375,6 @@ private static String dump(BackgroundPosition position) {
assertEquals(expected, image);
}

@Ignore("I am not certain that supporting auto makes sense for us, and if it does, is it anything other than 1?")
@Test public void borderImageWidth_auto() {
region.setStyle(
"-fx-border-image-source: url('test/javafx/scene/layout/center-btn.png');" +
Expand All @@ -3397,7 +3396,6 @@ private static String dump(BackgroundPosition position) {
assertEquals(expected, image);
}

@Ignore("I am not certain that supporting auto makes sense for us, and if it does, is it anything other than 1?")
@Test public void borderImageWidth_1_auto() {
region.setStyle(
"-fx-border-image-source: url('test/javafx/scene/layout/center-btn.png');" +
Expand All @@ -3418,7 +3416,6 @@ private static String dump(BackgroundPosition position) {
assertEquals(expected, image);
}

@Ignore("I am not certain that supporting auto makes sense for us, and if it does, is it anything other than 1?")
@Test public void borderImageWidth_1_2Percent_auto() {
region.setStyle(
"-fx-border-image-source: url('test/javafx/scene/layout/center-btn.png');" +
Expand Down

0 comments on commit 4f496d4

Please sign in to comment.