Skip to content

Commit

Permalink
fix coverage
Browse files Browse the repository at this point in the history
Signed-off-by: Lantao Jin <[email protected]>
  • Loading branch information
LantaoJin committed Nov 2, 2024
1 parent 2728f01 commit dc42cc6
Showing 1 changed file with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ void datetime_rounding_non_core_type_span() {
DSL.span(DSL.ref("timestamp", new MockTimestampExprType()), DSL.literal(1), "h");
rounding = Rounding.createRounding(timestampSpan);
assertInstanceOf(Rounding.TimestampRounding.class, rounding);
SpanExpression datetimeSpan =
DSL.span(DSL.ref("datetime", new MockDateTimeExprType()), DSL.literal(1), "h");
rounding = Rounding.createRounding(datetimeSpan);
assertInstanceOf(Rounding.DatetimeRounding.class, rounding);
}

@Test
Expand Down Expand Up @@ -95,4 +99,11 @@ public String typeName() {
return "TIMESTAMP";
}
}

static class MockDateTimeExprType implements ExprType {
@Override
public String typeName() {
return "DATETIME";
}
}
}

0 comments on commit dc42cc6

Please sign in to comment.