Package jfxtras.test

Examples of jfxtras.test.AssertNode


      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 55.98076211353316, 45.0);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(40.98076211353316, 29.999999999999996, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(15.0, 15.0, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
  }
View Full Code Here


      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 79.16875301294053, 84.85281374238573);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(42.9555495773441, 27.426406871192853, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(6.2132034355964265, 48.63961030678929, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(2)).assertXYWH(6.2132034355964265, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
  }
View Full Code Here

      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 144.85281374238568, 144.8528137423857);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(78.63961030678927, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(108.63961030678927, 36.213203435596405, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(2)).assertXYWH(108.63961030678927, 78.63961030678931, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(3)).assertXYWH(78.63961030678932, 108.63961030678928, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(4)).assertXYWH(36.21320343559643, 108.63961030678928, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(5)).assertXYWH(6.2132034355964265, 78.63961030678928, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(6)).assertXYWH(6.2132034355964265, 36.213203435596434, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(7)).assertXYWH(36.21320343559642, 6.213203435596434, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
  }
View Full Code Here

    setLabel("eightNodesAnimated");

    circularPane.setOnAnimateInFinished((event) -> {
      // these assertions must be identical to those in eightNodes
      assertWH(circularPane, 153.29, 153.29);
      new AssertNode(circularPane.getChildren().get(0)).assertXYWH(61.645975386273626, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(1)).assertXYWH(100.84286433256493, 22.44908643998233, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(2)).assertXYWH(117.07874733695084, 61.645975386273626, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(3)).assertXYWH(100.84286433256494, 100.84286433256491, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(4)).assertXYWH(61.64597538627363, 117.07874733695084, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(5)).assertXYWH(22.449086439982338, 100.84286433256494, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(6)).assertXYWH(6.2132034355964265, 61.64597538627363, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
      new AssertNode(circularPane.getChildren().get(7)).assertXYWH(22.44908643998233, 22.449086439982338, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    });
   
    // insert 8 circles
    TestUtil.runThenWaitForPaintPulse( () -> {
      for (int i = 0; i < 8; i++) {
View Full Code Here

      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 102.42640687119285, 102.42640687119285);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(66.21320343559643, 15.0, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(87.42640687119285, 36.213203435596405, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(2)).assertXYWH(87.42640687119285, 66.21320343559643, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(3)).assertXYWH(66.21320343559645, 87.42640687119285, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(4)).assertXYWH(36.21320343559643, 87.42640687119285, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(5)).assertXYWH(15.0, 66.21320343559643, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(6)).assertXYWH(15.0, 36.21320343559643, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
    new AssertNode(circularPane.getChildren().get(7)).assertXYWH(36.21320343559642, 15.0, 15.0, 15.0, 0.01).assertClass(javafx.scene.shape.Circle.class);
  }
View Full Code Here

      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 168.99494936611666, 168.99494936611666);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(95.71067811865473, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(132.7817459305202, 43.28427124746187, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(2)).assertXYWH(132.78174593052023, 95.71067811865477, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(3)).assertXYWH(95.71067811865478, 132.7817459305202, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(4)).assertXYWH(43.284271247461895, 132.78174593052023, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(5)).assertXYWH(6.2132034355964265, 95.71067811865476, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(6)).assertXYWH(6.2132034355964265, 43.2842712474619, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(7)).assertXYWH(43.28427124746189, 6.213203435596434, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
  }
View Full Code Here

      }
    });

    //generateSource(circularPane);
    assertWH(circularPane, 114.09506182625597, 114.09506182625597);
    new AssertNode(circularPane.getChildren().get(0)).assertXYWH(56.890595352840414, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(1)).assertXYWH(77.88185839065953, 27.204466473415533, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(2)).assertXYWH(77.88185839065954, 56.89059535284043, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(3)).assertXYWH(56.89059535284044, 77.88185839065953, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(4)).assertXYWH(27.204466473415554, 77.88185839065954, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(5)).assertXYWH(6.2132034355964265, 56.89059535284042, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(6)).assertXYWH(6.2132034355964265, 27.204466473415557, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
    new AssertNode(circularPane.getChildren().get(7)).assertXYWH(27.20446647341555, 6.2132034355964265, 30.0, 30.0, 0.01).assertClass(javafx.scene.shape.Rectangle.class);
  }
View Full Code Here

   */
  @Test
  public void checkPositions()
  {
    //AssertNode.generateSource("hbox", hbox.getChildren(), null, false, A.XYWH, A.CLASS);
    new AssertNode(hbox.getChildren().get(0)).assertXYWH(0.0, 0.0, 43.0, 65.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(hbox.getChildren().get(1)).assertXYWH(53.0, 5.0, 94.0, 55.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(hbox.getChildren().get(2)).assertXYWH(157.0, 0.0, 61.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(hbox.getChildren().get(3)).assertXYWH(243.0, 20.0, 114.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(hbox.getChildren().get(4)).assertXYWH(382.0, 0.0, 119.0, 50.0, 0.01).assertClass(javafx.scene.control.Button.class);
  }
View Full Code Here

   */
  @Test
  public void checkPositions()
  {
    //AssertNode.generateSource("vbox", vbox.getChildren(), null, false, A.XYWH, A.CLASS);
    new AssertNode(vbox.getChildren().get(0)).assertXYWH(0.0, 0.0, 240.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(1)).assertXYWH(0.0, 30.0, 240.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(2)).assertXYWH(0.0, 60.0, 240.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(3)).assertXYWH(5.0, 95.0, 230.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(4)).assertXYWH(0.0, 130.0, 61.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(5)).assertXYWH(20.0, 180.0, 114.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
    new AssertNode(vbox.getChildren().get(6)).assertXYWH(0.0, 230.0, 150.0, 25.0, 0.01).assertClass(javafx.scene.control.Button.class);
  }
View Full Code Here

    moveMouseToCenter();
    click(MouseButton.SECONDARY);
    Assert.assertTrue(circlePopupMenu.isShown());
    //generateSource();
    assertWH(findCircularPane(), 118.47869355660265, 114.89486277938934);
    new AssertNode(findCircularPane().getChildren().get(0)).assertXYWH(65.86676377627084, 6.627416997969522, 32.0, 32.0, 0.01).assertClassName("jfxtras.scene.menu.CirclePopupMenu$CirclePopupMenuNode");
    new AssertNode(findCircularPane().getChildren().get(1)).assertXYWH(79.85127655863312, 49.66732176366279, 32.0, 32.0, 0.01).assertClassName("jfxtras.scene.menu.CirclePopupMenu$CirclePopupMenuNode");
    new AssertNode(findCircularPane().getChildren().get(2)).assertXYWH(43.239346778301325, 76.26744578141981, 32.0, 32.0, 0.01).assertClassName("jfxtras.scene.menu.CirclePopupMenu$CirclePopupMenuNode");
    new AssertNode(findCircularPane().getChildren().get(3)).assertXYWH(6.627416997969522, 49.66732176366279, 32.0, 32.0, 0.01).assertClassName("jfxtras.scene.menu.CirclePopupMenu$CirclePopupMenuNode");
    new AssertNode(findCircularPane().getChildren().get(4)).assertXYWH(20.611929780331792, 6.627416997969526, 32.0, 32.0, 0.01).assertClassName("jfxtras.scene.menu.CirclePopupMenu$CirclePopupMenuNode");
   
    // move out of the menu
    moveMouseToLeftCorner();
    Assert.assertFalse(circlePopupMenu.isShown());
  }
View Full Code Here

TOP

Related Classes of jfxtras.test.AssertNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.