Skip to content

Commit

Permalink
change error message
Browse files Browse the repository at this point in the history
Signed-off-by: jowg-amazon <jowg@amazon.com>
  • Loading branch information
jowg-amazon committed Apr 12, 2024
1 parent 5c8888f commit 6904220
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ data class DocLevelQuery(
}
private fun validateQueryName(stringVal: String) {
if (!stringVal.matches(QUERY_NAME_REGEX)) {
throw IllegalArgumentException("The query name, $stringVal, can be max 256 characters.")
throw IllegalArgumentException("The query name, $stringVal, should be between 1 - 256 characters.")
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class DocLevelMonitorInputTests {
Assertions.fail("Expecting an illegal argument exception")
} catch (e: IllegalArgumentException) {
Assertions.assertEquals(
"The query name, $emptyString, can be max 256 characters.",
"The query name, $emptyString, should be between 1 - 256 characters.",
e.message
)
}
Expand All @@ -68,7 +68,7 @@ class DocLevelMonitorInputTests {
Assertions.fail("Expecting an illegal argument exception")
} catch (e: IllegalArgumentException) {
Assertions.assertEquals(
"The query name, $badString, can be max 256 characters.",
"The query name, $badString, should be between 1 - 256 characters.",
e.message
)
}
Expand Down

0 comments on commit 6904220

Please sign in to comment.