• Eric Chiang's avatar
    server: fix reset password test · 4da143ca
    Eric Chiang authored
    TestResetPasswordHandler depended on makeToken begin called twice
    during the initialization of a single test case and later assuming
    the result would match. Because the token has a timestamp accurate
    to the second, occasionally the timestamps would be slightly off
    within a single test case and cause the test to fail.
    
    Adding a sleep statement to makeToken would cause the test to fail
    reliably.
    
    Define a single token for each test case outside of the struct
    initializer so test cases compare the same token.
    
    Closes #274
    
    Additionally remove logging statements that dump entire HTML pages.
    4da143ca
password_test.go 15.6 KB