TS 71 JavaFX2

JavaFX2 Support Test Specification for NetBeans 7.1

Author: Štěpán Žebra
Version: 0.11
Last update: 5/10/2011
Introduction: JavaFX2 is the next step in the evolution of Java as a rich client platform. It is designed to provide a lightweight, hardware-accelerated Java UI platform for enterprise and business applications. This document describes how JavaFX2 support module should be tested in order to know whether all of its functionality works correctly.
Comments: The JavaFX2 support is currently under active development and some parts of functionality may not be implemented yet. Changes are tracked and included daily.

Contents


Compatibility Table

Table shows all possible combinations of JDK and JavaFX2 SDK and how they should run in NetBeans. They all should work the same regardless of which Java version is used to run NetBeans itself (any of Java 6 or 7, 32bit or 64bit). - issue 202165

JDK type JavaFX2 SDK type compatible runs manual setting autodetection
6u27 32bit 32bit yes yes possible possible
6u27 32bit 64bit no no possible possible
6u27 64bit 32bit no no possible possible
6u27 64bit 64bit yes yes possible possible
7 32bit 32bit yes yes possible possible
7 32bit 64bit no no possible possible
7 64bit 32bit no no possible possible
7 64bit 64bit yes yes possible possible


Test suite: Activating JavaFX2 support

Purpose: Test whether JavaFX2 support activation works correctly from various entry points.
Setup: Compatible JavaFX2 SDK installed.

  1. Activating by creating FX Project
    1. Start IDE with fresh userdir.
    2. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    3. In the first step of the wizard select "JavaFX" category and "JavaFX Application" project. Push Next > button.
    • EXPECTED RESULT: "Activating Java SE, JavaFX 2" progress bar shows up for a moment and then the wizard continues with it's second step. Verify in Plugins manager, that JavaSE and JavaFX2 are activated.
  2. Activating by creating FX Sample
    1. Start IDE with fresh userdir.
    2. On the "Start Page", in "Learn & Discover" tab, press Try a Sample Project button.
    3. "New Project" wizard shows up with "Samples" category opened. Select the "JavaFX" subcategory.
    4. Select some sample project and push Next > button.
    • EXPECTED RESULT: "Activating Java SE, JavaFX 2" progress bar shows up for a moment and then the wizard continues with it's second step. Verify in Plugins manager, that JavaSE and JavaFX2 are activated.
  3. Activating in Plugins manager - issue 202655
    1. Start IDE with fresh userdir.
    2. Invoke Tools | Plugins from main menu. "Plugins" manager shows up.
    3. Select "Installed" tab and check "Show details" checkbox.
    4. Find the "JavaFX 2 Support", check it and push Activate button.
    5. "NetBeans IDE Installer" wizard shows up with a list of plugins for activation. Push Activate.
    6. Wait for the task to finish and then press Finish.
    • EXPECTED RESULT: JavaFX and JavaSE are now marked as activated. In New Project wizard, project templates in "Java" and "JavaFX" categories and samples for those categories are not grayed out and no activation is invoked upon creation of these projects.
  4. Activating by opening FX Project - issue 202164
    1. Start IDE with fresh userdir.
    2. Invoke File | Open Project... from main menu. "Open Project" wizard shows up.
    3. Browse to some previously created JavaFX2 project, select it and push Open Project button.
    • EXPECTED RESULT: Project is opened and JavaSE with JavaFX support are activated. Verify in Plugins manager.


Test suite: Managing JavaFX2 Platform

Purpose: Test whether the JavaFX2 SDK can set up for a use in the IDE.
Setup: Compatible JavaFX2 SDK installed.

  1. Automatic JavaFX Platform detection I (Project)
    1. Start IDE with fresh userdir.
    2. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    3. In the first step of the wizard select "JavaFX" category and "JavaFX Application" project. Push Next > button.
    • EXPECTED RESULT: In the second step of the wizard, JavaFX2 SDK should be detected and added as "Default JavaFX Platform", then selected in the "JavaFX Platform" combobox. Press Manage Platforms... and check whether the "Default JavaFX Platform" was detected correctly as expected.
  2. Automatic JavaFX Platform detection II (Sample)
    1. Start IDE with fresh userdir.
    2. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    3. In the first step of the wizard select "Samples" category and "JavaFX" subcategory.
    4. Select some sample project and push Next > button.
    • EXPECTED RESULT: In the second step of the wizard, JavaFX2 SDK should be detected and added as "Default JavaFX Platform", then selected in the "JavaFX Platform" combobox. Press Manage Platforms... and check whether the "Default JavaFX Platform" was detected correctly as expected.
  3. Manually adding JavaFX Platform I (Project)
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard select "JavaFX" category and "JavaFX Application" project. Push Next > button.
    3. In the second step of the wizard, push Manage Platforms... button, next to the "JavaFX Platform" combobox.
    4. "Java Platform Manager" shows up. Press Add Platform... and select path for the JDK of your choice and push Next >.
    5. Enter desired "Platform Name" and press Finish
    6. Select the newly created platform in "Platforms" list. Select "JavaFX" tab and check "Enable JavaFX" checkbox.
    7. Use Browse... button next to "JavaFX SDK" textfield to find a compatible JavaFX SDK location. "Runtime" and "Javadoc" textfields should be filled automatically.
    8. Push Close button. Back in the wizard, select your newly created JavaFX platform in the "JavaFX Platform" combobox.
    • EXPECTED RESULT: Newly created JavaFX platform can be selected in the combobox. No warning message is shown after it's selection, Finish button is enabled. Press Manage Platforms... again and check whether all settings of your new platform were saved correctly.
  4. Manually adding JavaFX Platform II (Menu & Sample)
    1. If JavaFX support is not activated in your current run, activate it first.
    2. Invoke Tools | Java Platforms from main menu. "Java Platform Manager" shows up.
    3. Press Add Platform... and select path for the JDK of your choice and push Next >.
    4. Enter desired "Platform Name" and press Finish
    5. Select the newly created platform in "Platforms" list. Select "JavaFX" tab and check "Enable JavaFX" checkbox.
    6. Use Browse... button next to "JavaFX SDK" textfield to find a compatible JavaFX SDK location.
    7. "Runtime" and "Javadoc" textfields should be filled automatically. Push Close button.
    8. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    9. In the first step of the wizard select "Samples" category and "JavaFX" subcategory.
    10. Select some sample project and push Next > button.
    11. In the second step of the wizard, select your newly created JavaFX platform in the "JavaFX Platform" combobox.
    • EXPECTED RESULT: Newly created JavaFX platform can be selected in the combobox. No warning message is shown after it's selection, Finish button is enabled. Press Manage Platforms... and check whether all settings of your new platform were saved correctly.
  5. Changing configuration of JavaFX Platform - issue 202113
    1. Invoke Tools | Java Platforms from main menu. "Java Platform Manager" shows up.
    2. Select "Default JavaFX Platform". Go to "JavaFX" tab.
    3. Change the path to "JavaFX SDK" to a different valid location and press Close.
    • EXPECTED RESULT: Configuration is successfully changed. Open "Java Platform Manager" again and check whether the changes were saved correctly.


Test suite: JavaFX2 Projects

Purpose: Test basic JavaFX2 Project handling.
Setup: Compatible JavaFX2 SDK installed.

  1. Create New JavaFX2 Application
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard select "JavaFX" category and "JavaFX Application" project. Push Next > button.
    3. Keep all default settings and push Finish.
    • EXPECTED RESULT: A new JavaFX2 Project is created and opened. The project should be created without any errors and should be able to run.
  2. Close JavaFX2 Project
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Close.
    • EXPECTED RESULT: Project is successfully closed. All contents of the project disappears from all views.
  3. Open JavaFX2 Project
    1. Invoke File | Open Project... from main menu. "New Project" wizard shows up.
    2. Browse to the previously closed project, select it and push Open Project button.
    • EXPECTED RESULT: Project is opened and can run.


Test suite: JavaFX2 Preloaders

Purpose: Test JavaFX2 Preloaders support.
Setup: Compatible JavaFX2 SDK installed.

  1. Create FX Application with Preloader
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard select "JavaFX" category and "JavaFX Application" project. Push Next > button.
    3. In the second step of the wizard, tick "Create Custom Preloader" checkbox.
    4. Keep all other settings default and push Finish.
    • EXPECTED RESULT: New JavaFX2 Application project is successfully created along with Preloader project. The application is set to use the preloader. Application can run.
  2. Create New Preloader
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard select "JavaFX" category and "JavaFX Preloader" project. Push Next > button.
    3. Keep all default settings and push Finish.
    • EXPECTED RESULT: New Preloader project is successfully created.
  3. Set Preloader to FX Application I - issue 202968
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Properties.
    3. In the "Project Properties" manager, select "Run" category.
    4. Push Browse... next to "Use Preloader" field. "Choose Preloader Source" wizard shows up.
    5. In the first step of the wizard, keep "Choose Preloader from Project" selected and push Next >.
    6. In the second step, browse to the Preloader project created in previous test case, select it and push Finish.
    7. Back in the "Project Properties", verify correct "Preloader Class" is selected and press OK.
    • EXPECTED RESULT: New Preloader is successfully set to a JavaFX2 Application project. Application can run with it.
  4. Set Preloader to FX Application II - issue 202965
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Properties.
    3. In the "Project Properties" manager, select "Run" category.
    4. Push Browse... next to "Use Preloader" field. "Choose Preloader Source" wizard shows up.
    5. In the first step of the wizard, select "Choose Preloader from JAR" and push Next >.
    6. In the second step, browse to the "dist" directory of Preloader project created in the first test case, select the JAR file there and push Finish.
    7. Back in the "Project Properties", verify correct "Preloader Class" is selected and press OK.
    • EXPECTED RESULT: New Preloader is successfully set to a JavaFX2 Application project. Application can run with it.
  5. Unset Preloader - issue 202966
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Properties.
    3. In the "Project Properties" manager, select "Run" category.
    4. Uncheck the "Use Preloader" checkbox.
    5. Preloader fields should be gray, press OK.
    • EXPECTED RESULT: Preloader is successfully unset from the JavaFX2 Application project. Application can run.


Test suite: JavaFX2 FXML

Purpose: Test JavaFX2 FXML support.
Setup: Compatible JavaFX2 SDK installed.

  1. Create New FXML Application
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard select "JavaFX" category and "JavaFX FXML Application" project. Push Next > button.
    3. Keep all default settings and push Finish.
    • EXPECTED RESULT: A new JavaFX2 Project with "Sample.fxml" is created and opened. The project should be created without any errors and should be able to run.
  2. Add FXML File to Application
    1. In "Projects" view, select the main package of the previously created JavaFX2 project.
    2. Invoke File | New File... from main menu. "New File" wizard shows up.
    3. Select "JavaFX" category and "FXML Template" file type. Push Next > button.
    4. Keep all default settings and push Finish.
    • EXPECTED RESULT: New FXML file with controller class are created.


Test suite: Basic IDE Tasks

Purpose: Test whether basic IDE tasks for JavaFX2 Project works correctly.
Setup: Compatible JavaFX2 SDK installed.

  1. Run
    1. Create new JavaFX2 Application and set it as Main Project.
    2. Invoke Run | Run Main Project action from main menu.
    • EXPECTED RESULT: Project is successfully built and runs. In the "Files" view, check that "build" and "dist" folders were created in project's directory and that they contain compiled classes and deploy files.
  2. Clean
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Clean action.
    • EXPECTED RESULT: Project is successfully cleaned. In the "Files" view, verify that "build" and "dist" folders were removed.
  3. Build
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Build action.
    • EXPECTED RESULT: Project is successfully built. In the "Files" view, check that "build" and "dist" folders were created in project's directory and that they contain compiled classes and deploy files.
  4. Rebuild
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Build action.
    • EXPECTED RESULT: Project is successfully rebuilt. Verify in filesystem that previous "build" and "dist" folders and unchanged classes remained and all other content was replaced.
  5. Clean and Build
    1. In "Projects" view, select the root node of the previously created JavaFX2 project.
    2. Invoke pop-up menu and select Clean and Build action.
    • EXPECTED RESULT: Project is successfully cleaned and then built. Verify in filesystem that previous "build" and "dist" folders and all their contents were removed and replaced with new ones.


Test suite: Advanced IDE Tasks

Purpose: Test whether advanced IDE tasks for JavaFX2 Project works correctly.
Setup: Compatible JavaFX2 SDK installed.

  1. Debug - issue 202990
    1. Create new JavaFX2 Application and set it as Main Project.
    2. Invoke Debug | Debug Main Project action from main menu.
    • EXPECTED RESULT: Project is successfully started in debug mode.
  2. Profile
    1. Create new JavaFX2 Application and set it as Main Project.
    2. Invoke Profile | Profile Main Project... action from main menu.
    3. Keep default settings and push Run.
    • EXPECTED RESULT: Project is successfully started in profile mode.
  3. Test
    1. Create new JavaFX2 Application and set it as Main Project.
    2. Invoke Tools | Create JUnit Tests action from main menu.
    3. In the upcoming dialogs, keep default settings and push Select and then OK.
    4. Invoke Run | Test Project action from main menu.
    • EXPECTED RESULT: Project is successfully started in test mode.


Test suite: Run in Browser

Purpose: Test whether HTML page generated by IDE runs.
Setup: Compatible JavaFX2 SDK installed.

  1. Run in Browser from IDE
    1. Create new JavaFX2 Application and set it as Main Project.
    2. In "Projects" view, select the root node of the newly created JavaFX2 project and invoke Properties pop-up menu action.
    3. In the "Project Properties" dialog, select the "Run" category.
    4. Select "in Browser" option and push OK.
    5. Invoke Run | Run Main Project action from main menu.
    • EXPECTED RESULT: Project successfully runs in Browser.
  2. Run in Browser from filesystem
    1. Open system file manager.
    2. Locate the folder with the project created in the previous test case and open it.
    3. Open the "dist" subfolder.
    4. Execute the application HTML file.
    • EXPECTED RESULT: File is opened in the default system web browser and the webpage with FX application executes correctly.
  3. Run in Browser from web
    1. Upload the "dist" folder from previous test case on a webserver.
    2. Open system web browser and enter the address to the HTML file in the uploaded folder.
    • EXPECTED RESULT: The webpage with FX application executes correctly.


Test suite: Run as Webstart

Purpose: Test whether Webstart artifact generated by IDE runs.
Setup: Compatible JavaFX2 SDK installed.

  1. Run as Webstart from IDE
    1. Create new JavaFX2 Application and set it as Main Project.
    2. In "Projects" view, select the root node of the newly created JavaFX2 project and invoke Properties pop-up menu action.
    3. In the "Project Properties" dialog, select the "Run" category.
    4. Select "as Web Start" option and push OK.
    5. Invoke Run | Run Main Project action from main menu.
    • EXPECTED RESULT: Project successfully runs as Webstart.
  2. Run as Webstart from filesystem
    1. Open system file manager.
    2. Locate the folder with the project created in the previous test case and open it.
    3. Open the "dist" subfolder.
    4. Execute the application JNLP file.
    • EXPECTED RESULT: The FX application executes via Webstart correctly.
  3. Run as Webstart from web
    1. Upload the "dist" folder from previous test case on a webserver.
    2. Open system web browser and enter the address to the HTML file in the uploaded folder.
    3. Click the Webstart link on the HTML page.
    • EXPECTED RESULT: The FX application executes via Webstart correctly.


Test suite: Project Properties

Purpose: Test JavaFX2 Project specific properties.
Setup: Compatible JavaFX2 SDK installed.

  1. Changing JavaFX Platform
    1. Create a new JavaFX2 Project with "Default JavaFX Platform" and run it at least once.
    2. In the "Projects" view, right-click the root node of the project and select Properties.
    3. Select the "Libraries" category in the "Project Properties" dialog.
    4. Change platform in "Java Platform" combobox to a different one (create it if needed) and press OK.
    • EXPECTED RESULT: Project platform is successfully changed. Project should be able to run on the newly selected platform.
  2. Binary Encode JavaFX CSS Files
    1. TODO
    • EXPECTED RESULT: TODO
  3. Setup Application Class
    1. Create new JavaFX Main Class in the project created in previous test case.
    2. Select the project root node, invoke pop-up menu and select Properties.
    3. Select the "Run" category in the "Project Properties" dialog.
    4. Using the Browse..., change the "Application Class" to the newly created JavaFX Main Class.
    5. Push OK button.
    • EXPECTED RESULT: Project Application class is successfully changed. Verify by running the project.
  4. Using Parameters
    1. TODO
    • EXPECTED RESULT: TODO
  5. Using VM Options
    1. TODO
    • EXPECTED RESULT: TODO
  6. Setting applet size
    1. TODO
    • EXPECTED RESULT: TODO
  7. Choosing web browser
    1. TODO
    • EXPECTED RESULT: TODO


Test suite: Deploy Options

  1. Sign application by generated key
    1. TODO
    • EXPECTED RESULT: TODO
  2. Sign application by specified key
    1. TODO
    • EXPECTED RESULT: TODO


Test suite: Configurations

  1. Create configuration
    1. TODO
    • EXPECTED RESULT: TODO
  2. Use different configurations
    1. TODO
    • EXPECTED RESULT: TODO


Test suite: Samples

Purpose: Test functionality of JavaFX2 Samples.
Setup: Compatible JavaFX2 SDK installed.

Comments: 3D samples require modern hardware with latest drivers. Some samples require internet access, if you're behind proxy, set accordingly following VM Options
-Dhttp.proxyHost=proxy.mydomain.com -Dhttp.proxyPort=80
in Project Properties. Follow the Samples Table to test all included samples.

Samples Table:

Sample media 3d fxml swing proxy
AdvancedMedia X X
AudioVisualiser3D X X X
BrickBreaker
ColorfulCircles
CreateAdvancedStage
Cube3D X
CubeSystem3D X
DigitalClock
DisplayShelf
FXML-LoginDemo X
HTMLEditorApp
ChangeListener
ChartAdvancedArea
ChartAdvancedBar
ChartAdvancedPie
ChartAdvancedScatter
ChartAdvancedScatterLive
ChartAdvancedStockLine
ChartAudioArea X X
ChartAudioBar X X
ChartLine
KeyStrokeMotion
MouseEvents
PuzzlePieces
StopWatch
SwingIntrop X X
TimelineEvents
TimelineInterpolator
TransitionPath
TransitionRotate
WebViewBrowser X
Xylophone X

  1. Create Sample Project
    1. Invoke File | New Project... from main menu. "New Project" wizard shows up.
    2. In the first step of the wizard expand "Samples" category and select "JavaFX" subcategory.
    3. Select chosen project. Push Next > button.
    4. In the second step of the wizard, "Default JavaFX Platform" should be selected in the "JavaFX Platform" combobox.
    5. Keep all default settings and push Finish.
    • EXPECTED RESULT: A new JavaFX2 Sample Project is created and opened. The project should be created without any errors and should be able to run.


Not logged in. Log in, Register

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