summary refs log tree commit diff homepage
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/server.cr5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/server.cr b/spec/server.cr
index 69bb543..d24fe1d 100644
--- a/spec/server.cr
+++ b/spec/server.cr
@@ -110,13 +110,14 @@ describe Server do
 
   it "rejects too long nick" do
     msg = "Must be within #{MAX_NICK_LENGTH} characters"
-    expect_errors url, {"nick" => "x" * (MAX_NICK_LENGTH + 1)}, {"nick" => msg}
+    expect_errors url, {"nick" => "x" * (MAX_NICK_LENGTH + 1)},
+                  {"nick" => "Must match #{NICK_PATTERN}"}
   end
 
   it "rejects nicks that are not lowercase alphanumeric" do
     %w(camelCase pun/tu?a#tion).each do |nick|
       expect_errors url, {"nick" => nick},
-                    {"nick" => "Must be ASCII lowercase alphanumeric"}
+                    {"nick" => "Must match #{NICK_PATTERN}"}
     end
   end