[TEST] Catch ISE instead of IAE for illegal array size

relates elastic/x-pack-elasticsearch#2493

Original commit: elastic/x-pack-elasticsearch@605dcebf0e
This commit is contained in:
Simon Willnauer 2017-12-20 09:48:54 +01:00
parent 08a35d44c6
commit 3dd9445f4b
1 changed files with 1 additions and 1 deletions

View File

@ -845,7 +845,7 @@ public class AuthenticationServiceTests extends ESTestCase {
success.set(true);
latch.countDown();
}, this::logAndFail));
} catch (IllegalArgumentException ex) {
} catch (IllegalStateException ex) {
assertThat(ex.getMessage(), containsString("array length must be <= to " + ArrayUtil.MAX_ARRAY_LENGTH + " but was: "));
latch.countDown();
} catch (NegativeArraySizeException ex) {