make tribe-node-license validation assume snapshot context (elastic/x-pack-elasticsearch#2589)
Release tests were introduced that sets the `build.snapshot` system property to `false` to mimic release builds. This invalidates the hardcoded license signatures that were signed against the integration test pub/priv keys. This commit modifies the license-validation assertions to assume the test is running against those test keys, and will be skipped/ignored when these assertions fail (which should only occur with `build.snapshot=true`) Original commit: elastic/x-pack-elasticsearch@871704a3af
This commit is contained in:
parent
0c96db0a1c
commit
d9554955f2
|
@ -5,6 +5,7 @@
|
|||
*/
|
||||
package org.elasticsearch.test;
|
||||
|
||||
import org.elasticsearch.Build;
|
||||
import org.elasticsearch.common.bytes.BytesArray;
|
||||
import org.elasticsearch.common.settings.Settings;
|
||||
import org.elasticsearch.common.transport.TransportAddress;
|
||||
|
@ -101,6 +102,7 @@ public class LicensingTribeIT extends ESIntegTestCase {
|
|||
}
|
||||
|
||||
public void testLicensePropagateToTribeNode() throws Exception {
|
||||
assumeTrue("License is only valid when tested against snapshot/test keys", Build.CURRENT.isSnapshot());
|
||||
// test that auto-generated trial license propagates to tribe
|
||||
assertBusy(() -> {
|
||||
GetLicenseResponse getLicenseResponse = new LicensingClient(tribeNode.client()).prepareGetLicense().get();
|
||||
|
|
Loading…
Reference in New Issue