Skip to content

Commit

Permalink
Suppress removal warnings in Ansible utility tests (#1120)
Browse files Browse the repository at this point in the history
  • Loading branch information
sleberknight authored Apr 25, 2024
1 parent 7174ab1 commit f435fa8
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ void setUp() {
class ShouldBuildCommand {

@Test
@SuppressWarnings("removal")
void whenGivenNoOutputFile() {
var encryptedFilePath = "/data/secret/MySecret.txt";
var command = VaultDecryptCommand.from(configuration, encryptedFilePath);
Expand All @@ -42,6 +43,7 @@ void whenGivenNoOutputFile() {
}

@Test
@SuppressWarnings("removal")
void whenGivenOutputFile() {
var encryptedFilePath = "/data/secret/MySecret.txt";
var outputFilePath = "/data/temp/Plain.txt";
Expand All @@ -62,6 +64,7 @@ void whenGivenOutputFile() {
}

@Test
@SuppressWarnings("removal")
void whenGivenStdOutAsOutputFile() {
var encryptedFilePath = "/data/secret/MySecret.txt";
var command = VaultDecryptCommand.toStdoutFrom(configuration, encryptedFilePath);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ void setUp() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand() {
var plainTextFileName = "/data/etc/secrets/passwords.txt";

Expand All @@ -38,6 +39,7 @@ void shouldBuildCommand() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand_WithVaultId() {
var vaultIdLabel = "test";
var plainTextFileName = "/data/etc/secrets/passwords.txt";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ void setUp() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand() {
var plainText = "the plain text";
var variableName = "MySecret";
Expand All @@ -40,6 +41,7 @@ void shouldBuildCommand() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand_WithVaultId() {
var vaultIdLabel = "test";
var plainText = "the plain text";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ void setUp() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand() {
var encryptedFileName = "/data/crypt/passwords.txt";
var newVaultPasswordFilePath = "/~.ansible/new_vault_pass";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ void setUp() {
}

@Test
@SuppressWarnings("removal")
void shouldBuildCommand() {
var encryptedFileName = "/data/crypt/passwords.txt";

Expand Down

0 comments on commit f435fa8

Please sign in to comment.