RFR: 8319555: [TestBug] Utility for creating instruction window for manual tests [v2]

Andy Goryachev angorya at openjdk.org
Mon Apr 8 14:34:23 UTC 2024


> ## ManualTestWindow
> 
> This facility provides a framework for manual tests to display test instructions, test pane, and Pass/Fail buttons.
> 
> A simple test would look like this:
> 
> 
> public class SampleManualTest {
>      public static void main(String[] args) throws Exception {
>          ManualTestWindow.builder().
>              title("Sample Manual Test").
>              instructions(
>                  """
>                  Provide
>                  multi-line instructions here.
>                  """
>              ).
>              ui(() -> createTestUI()).
>              buildAndRun();
>      }
> 
>      private static Node createTestUI() {
>          return new Label("Test UI");
>      }
> }
> 
> 
> Resulting application window:
> 
> ![ManualTestWindow](https://github.com/openjdk/jfx/assets/107069028/15b34a8f-cb0d-4469-85bc-ec5962e448c7)
> 
> Readme:
> 
> https://github.com/openjdk/jfx/blob/1cc095049be3773e1211ad570eb2285f08f25cec/tests/manual/util/README.md
> 
> @prrace 's test EmojiTest has been converted to use the new test window as a demonstration (also fixed the Eclipse project and moved sources to src/, still using the default package).
> 
> Q: Do we want to avoid using the default package?
> 
> Q: What other features can be added to the test window?

Andy Goryachev has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:

 - Merge branch 'master' into 8319555.manual
 - whitespace
 - Merge branch 'master' into 8319555.manual
 - manual test window
 - fixed text manual test setup

-------------

Changes:
  - all: https://git.openjdk.org/jfx/pull/1413/files
  - new: https://git.openjdk.org/jfx/pull/1413/files/1cc09504..22da890b

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=1413&range=01
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=1413&range=00-01

  Stats: 15159 lines in 565 files changed: 9088 ins; 4321 del; 1750 mod
  Patch: https://git.openjdk.org/jfx/pull/1413.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/1413/head:pull/1413

PR: https://git.openjdk.org/jfx/pull/1413


More information about the openjfx-dev mailing list