Skip to content
This repository was archived by the owner on Aug 30, 2021. It is now read-only.

Commit a871c92

Browse files
committed
Duplicate CRUD Test - Profile Picture
Removes a duplicate User CRUD test for Profile Picture. There are two reasons for this commit. 1) Duplicate of https://github.com/meanjs/mean/blob/master/modules/users/tests/server/user.server.routes.tests.js#L833-L848 2) This test is problematic in Windows environment. Related to: forwardemail/supertest#230 forwardemail/supertest#258 The latter may be an issue with the `.attach` method not completely loading the file into memory before the 400 status response is sent back due to no User logged in.
1 parent d7d1d64 commit a871c92

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

modules/users/tests/server/user.server.routes.tests.js

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -876,16 +876,6 @@ describe('User CRUD tests', function () {
876876
});
877877
});
878878

879-
it('should not be able to change profile picture if not signed in', function (done) {
880-
agent.post('/api/users/picture')
881-
.attach('newProfilePicture', './modules/users/client/img/profile/default.png')
882-
.send(credentials)
883-
.expect(400)
884-
.end(function (userInfoErr, userInfoRes) {
885-
done(userInfoErr);
886-
});
887-
});
888-
889879
it('should not be able to change profile picture if attach a picture with a different field name', function (done) {
890880
agent.post('/api/auth/signin')
891881
.send(credentials)

0 commit comments

Comments
 (0)