RFR: 8295298: Automate javax/swing/JFileChooser/FileViewNPETest.java [v2]
Alexey Ivanov
aivanov at openjdk.org
Fri Oct 21 16:10:17 UTC 2022
> The automated test follows the instructions of the manual test that was added in #10485.
>
> Instead of selecting the parent folder from the **Look in** combo box, it calls `setCurrentDirectory` directly with the parent of the path which is not traversable. Thus, the current directory of the file chooser is set to `null`.
>
> As the second step, the test finds the combo box and re-selects the currently selected element. Without the fix for [JDK-6616245](https://bugs.openjdk.org/browse/JDK-6616245), `NullPointerException` is thrown and the test fails; with the fix applied, the original folder is selected and the test passes.
>
> @mrserb and @TejeshR13, please, take a look.
Alexey Ivanov has updated the pull request incrementally with one additional commit since the last revision:
Convert asserts to explicit checks
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/10801/files
- new: https://git.openjdk.org/jdk/pull/10801/files/c878454b..478f2070
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=10801&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=10801&range=00-01
Stats: 8 lines in 1 file changed: 3 ins; 0 del; 5 mod
Patch: https://git.openjdk.org/jdk/pull/10801.diff
Fetch: git fetch https://git.openjdk.org/jdk pull/10801/head:pull/10801
PR: https://git.openjdk.org/jdk/pull/10801
More information about the client-libs-dev
mailing list