Skip to content

Commit

Permalink
add more unit tests for improving coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
kaibocai committed Nov 3, 2023
1 parent e37225d commit 87f8d9c
Showing 1 changed file with 28 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package io.dapr.workflows.client;

import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

import java.time.Instant;

public class NewWorkflowOptionTest {

@Test
void testNewWorkflowOption() {
NewWorkflowOption workflowOption = new NewWorkflowOption();
String version = "v1";
String instanceId = "123";
Object input = new Object();
Instant startTime = Instant.now();

workflowOption.setVersion(version)
.setInstanceId(instanceId)
.setInput(input)
.setStartTime(startTime);

Assertions.assertEquals(version, workflowOption.getVersion());
Assertions.assertEquals(instanceId, workflowOption.getInstanceId());
Assertions.assertEquals(input, workflowOption.getInput());
Assertions.assertEquals(startTime, workflowOption.getStartTime());
}
}

0 comments on commit 87f8d9c

Please sign in to comment.