Skip to content

Commit ebef177

Browse files
authored
Fix for BUG: failing test_hierharchy_arraylist with jdk>=21 (#741)
* test JDK releases * less JDKs for now * make testcase pass? * no java 20 or newer for temurin on Windows * more explicit exclusions * lets test from 8 to 23
1 parent f91a3c2 commit ebef177

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

.github/workflows/push.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
java:
1818
- '8'
1919
- '11'
20-
- '20'
20+
- '23'
2121
os:
2222
# macos-latest (ATM macos-14) runs on Apple Silicon,
2323
# macos-13 runs on Intel
@@ -59,7 +59,16 @@ jobs:
5959
- os: windows-latest
6060
architecture: x86
6161
java: '20'
62-
62+
- os: windows-latest
63+
architecture: x86
64+
java: '21'
65+
- os: windows-latest
66+
architecture: x86
67+
java: '22'
68+
- os: windows-latest
69+
architecture: x86
70+
java: '23'
71+
6372
runs-on: ${{ matrix.os }}
6473
steps:
6574
- uses: actions/checkout@master

tests/test_reflect.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def test_hierharchy_arraylist(self):
3535
self.assertContains(d, "java.lang.Iterable")# interface
3636
self.assertContains(d, "java.lang.Object")# root
3737
maxLevel = max(d.values())
38-
self.assertEqual(d["java.lang.Object"], maxLevel)
38+
self.assertTrue(d["java.lang.Object"] in [maxLevel, maxLevel -1]) # Object should be pretty high up the hierarchy.
3939
self.assertEqual(d["java.util.ArrayList"], 0)
4040

4141
def test_class(self):

0 commit comments

Comments
 (0)