-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
check validity of invite before accepting
- Loading branch information
Showing
7 changed files
with
259 additions
and
186 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -30,7 +30,7 @@ func TestForgotResponds(t *testing.T) { | |
method: "PUT", | ||
url: "/accept/forgot", | ||
respCode: 200, | ||
body: jo{ | ||
body: testJSONObject{ | ||
"key": "1234_aK3yxxx123", | ||
"email": "[email protected]", | ||
"password": "myN3wpa55w0rd", | ||
|
@@ -48,7 +48,7 @@ func TestForgotResponds(t *testing.T) { | |
method: "PUT", | ||
url: "/accept/forgot", | ||
respCode: 404, | ||
body: jo{ | ||
body: testJSONObject{ | ||
"key": "1234_no_match", | ||
"email": "[email protected]", | ||
"password": "myN3wpa55w0rd", | ||
|
@@ -88,7 +88,7 @@ func TestForgotResponds(t *testing.T) { | |
|
||
if response.Body.Len() != 0 && len(test.response) != 0 { | ||
// compare bodies by comparing the unmarshalled JSON results | ||
var result = &jo{} | ||
var result = &testJSONObject{} | ||
|
||
if err := json.NewDecoder(response.Body).Decode(result); err != nil { | ||
t.Logf("Err decoding nonempty response body: [%v]\n [%v]\n", err, response.Body) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
378e504
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
378e504
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.