Skip to content

Commit

Permalink
fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
leaves12138 committed May 27, 2024
1 parent 481e5fa commit a2cbcd5
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,15 @@ public void testTableOptionsParse() {
expected.put("cd", "c,d");
expected.put("ef", "e, f");
expected.put("中国人", "Chinese person");
Map<String, String> o = ParameterUtils.parseCommaSeparatedKeyValues(need);
Map<String, String> o = ParameterUtils.parseCommaSeparatedKeyValuesByStateMachine(need);
Assertions.assertThat(o).isEqualTo(expected);
}

@Test
public void testTableOptionsParse2() {
String need = "a=b, ab='a,b', cd = 'c,d', ef= 'e, f',";
Assertions.assertThatCode(() -> ParameterUtils.parseCommaSeparatedKeyValues(need))
Assertions.assertThatCode(
() -> ParameterUtils.parseCommaSeparatedKeyValuesByStateMachine(need))
.hasMessage(
"Can't resolve table option expression: a=b, ab='a,b', cd = 'c,d', ef= 'e, f',");
}
Expand All @@ -60,7 +61,7 @@ public void testTableOptionsParse3() {
expected.put("h", "k");
expected.put("wq", "wq");
expected.put("m", "j");
Map<String, String> o = ParameterUtils.parseCommaSeparatedKeyValues(need);
Map<String, String> o = ParameterUtils.parseCommaSeparatedKeyValuesByStateMachine(need);
Assertions.assertThat(o).isEqualTo(expected);
}
}

0 comments on commit a2cbcd5

Please sign in to comment.