use of com.android.tools.build.bundletool.model.utils.DefaultSystemEnvironmentProvider in project bundletool by google.
the class BuildSdkApksCommandTest method keystoreProvidedDoesNotPrint.
@Test
public void keystoreProvidedDoesNotPrint() throws Exception {
try (ByteArrayOutputStream outputByteArrayStream = new ByteArrayOutputStream();
PrintStream outputPrintStream = new PrintStream(outputByteArrayStream)) {
BuildSdkApksCommand.fromFlags(getDefaultFlagsWithAdditionalFlags("--ks=" + keystorePath, "--ks-key-alias=" + KEY_ALIAS, "--ks-pass=pass:" + KEYSTORE_PASSWORD, "--key-pass=pass:" + KEY_PASSWORD), outputPrintStream, new DefaultSystemEnvironmentProvider());
assertThat(new String(outputByteArrayStream.toByteArray(), UTF_8)).isEmpty();
}
}
use of com.android.tools.build.bundletool.model.utils.DefaultSystemEnvironmentProvider in project bundletool by google.
the class BuildSdkApksCommandTest method noKeystoreProvidedPrintsWarning.
@Test
@Ignore("b/222682673")
public void noKeystoreProvidedPrintsWarning() throws Exception {
try (ByteArrayOutputStream outputByteArrayStream = new ByteArrayOutputStream();
PrintStream outputPrintStream = new PrintStream(outputByteArrayStream)) {
BuildSdkApksCommand.fromFlags(getDefaultFlagsWithAdditionalFlags(), outputPrintStream, new DefaultSystemEnvironmentProvider());
assertThat(new String(outputByteArrayStream.toByteArray(), UTF_8)).contains("WARNING: The APKs won't be signed");
}
}
Aggregations