Skip to content

Commit

Permalink
updated test case
Browse files Browse the repository at this point in the history
Signed-off-by: Jeromy Cannon <[email protected]>
  • Loading branch information
jeromy-cannon committed Sep 12, 2023
1 parent 4e85392 commit 841e8c8
Showing 1 changed file with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,24 @@

import static org.junit.jupiter.api.Assertions.*;

import java.io.File;
import java.io.IOException;
import org.gradle.api.Project;
import org.gradle.testfixtures.ProjectBuilder;
import org.junit.jupiter.api.Test;

class HelmInstallChartTaskTest {
@Test
void testHelmInstallChartTask() {
void testHelmInstallChartTask() throws IOException {
Project project = ProjectBuilder.builder().build();
HelmInstallChartTask helmInstallChartTask = project.getTasks().create("helmInstallChart", HelmInstallChartTask.class, task -> {
task.getRelease().set("test-release");
task.getChart().set("test-chart");
});
assertEquals("test-release", helmInstallChartTask.getRelease().get());
final File hederaNetworkChart = new File("../charts/hedera-network");
final String hederaNetworkChartPath = hederaNetworkChart.getCanonicalPath();
HelmInstallChartTask helmInstallChartTask = project.getTasks()
.create("helmInstallChart", HelmInstallChartTask.class, task -> {
task.getRelease().set("fst");
task.getChart().set(hederaNetworkChartPath);
});
assertEquals("fst", helmInstallChartTask.getRelease().get());
helmInstallChartTask.installChart();
}

}

0 comments on commit 841e8c8

Please sign in to comment.