From 77751a2aa0a258dff4cd3bba492c657573fd3f50 Mon Sep 17 00:00:00 2001 From: CPunch Date: Wed, 6 Dec 2023 17:35:02 -0600 Subject: [PATCH] login_tests: annotate tests --- login/login_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/login/login_test.go b/login/login_test.go index 0c8d8fb..6611f92 100644 --- a/login/login_test.go +++ b/login/login_test.go @@ -115,6 +115,7 @@ func TestMain(m *testing.M) { os.Exit(ret) } +// This test tries a typical login sequence. func TestLoginSuccSequence(t *testing.T) { is := is.New(t) ctx, cancel := context.WithCancel(context.Background()) @@ -148,6 +149,7 @@ func TestLoginSuccSequence(t *testing.T) { is.NoErr(err) // TryLogin() should not return an error } +// This test tries a typical login sequence, but with an invalid password. func TestLoginFailSequence(t *testing.T) { is := is.New(t) ctx, cancel := context.WithCancel(context.Background()) @@ -177,6 +179,7 @@ func TestLoginFailSequence(t *testing.T) { is.Equal(resp.IErrorCode, int32(login.LOGIN_ID_AND_PASSWORD_DO_NOT_MATCH)) // should respond with LOGIN_ID_AND_PASSWORD_DO_NOT_MATCH } +// This test tries a typical login sequence, and creates a character func TestCharacterSequence(t *testing.T) { is := is.New(t) ctx, cancel := context.WithCancel(context.Background())