-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
If a user is banned, they are redirected to the ban page with all the information, but the appeal form doesn't work (yet) In the next couple commits I'm going to work on actually submitting bans
- Loading branch information
Joshua Merrell
committed
Oct 3, 2018
1 parent
0187793
commit ad9d098
Showing
14 changed files
with
210 additions
and
314 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package main | ||
|
||
import ( | ||
"fmt" | ||
"testing" | ||
) | ||
|
||
func TestDurationParse(t *testing.T) { | ||
duration, err := parseDurationString("7y6mo5w4d3h2m1s") | ||
if err != nil { | ||
t.Fatal(err.Error()) | ||
} | ||
fmt.Println(duration) | ||
|
||
duration, err = parseDurationString("7year6month5weeks4days3hours2minutes1second") | ||
if err != nil { | ||
t.Fatal(err.Error()) | ||
} | ||
fmt.Println(duration) | ||
|
||
duration, err = parseDurationString("7 years 6 months 5 weeks 4 days 3 hours 2 minutes 1 seconds") | ||
if err != nil { | ||
t.Fatal(err.Error()) | ||
} | ||
fmt.Println(duration) | ||
} |
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.