In test UTF-8 used, while server returns localized date time with local timezone name in ASCII, so they not match.
Supertest, used in fixture is not very smart (for my test) - it not allow to check header with custom function (it start to check response body and so on) - or may be i'm missed.
Suggest - change string ZERO_DATE to RegExp that will get just mean part of datetime (before GMT) because if it's correct - it's set well - we not require to test RFC encoder itself here - just that expire is set to really-past date.
Have pull request
In test UTF-8 used, while server returns localized date time with local timezone name in ASCII, so they not match.
Supertest, used in fixture is not very smart (for my test) - it not allow to check header with custom function (it start to check response body and so on) - or may be i'm missed.
Suggest - change string ZERO_DATE to RegExp that will get just mean part of datetime (before GMT) because if it's correct - it's set well - we not require to test RFC encoder itself here - just that expire is set to really-past date.
Have pull request