-
Notifications
You must be signed in to change notification settings - Fork 0
Feature/ff 106 #34
Feature/ff 106 #34
Conversation
Tests need to be fixed, Unit test to be written. @qvalentin @Gimleux can you write more scenarios that you want to test e.g. user groups, when an admin user wants to change a different user etc.. |
Codecov Report
@@ Coverage Diff @@
## master #34 +/- ##
============================================
+ Coverage 69.77% 72.10% +2.33%
- Complexity 210 234 +24
============================================
Files 57 59 +2
Lines 655 717 +62
Branches 38 52 +14
============================================
+ Hits 457 517 +60
Misses 189 189
- Partials 9 11 +2
Continue to review full report at Codecov.
|
String username = userToUpdate.getUsername(); | ||
if (null != username) { | ||
if (!stringIsValid(username)) | ||
throw new UserNotUpdatedException("Wanted to change username, but username was not valid."); |
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.
but new username..
|
||
Query query = new Query(); | ||
query.addCriteria(Criteria.where("userId").is(userId)); | ||
mongoTemplate.findAndModify(query, newUpdate, UserEntity.class); |
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.
+1
} | ||
if (password != null) { | ||
jsonString.append("\"password\": \"").append(password).append(username != null?"\",":""); | ||
jsonString.append("\"password\": \"").append(password).append(username != null ? "\"," : "\""); |
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.
ups
* fixed tests, added shallow logic. * updated feature files, and step def. * FF-106 Write Logic for User Edit * Tweaked Cucumber Steps. Fixed Serialization. * Added additional check, fixed some bugs. * FF-106 Wrote UnitTests for User Edit * Damn you password check. * Bumped Version to v0.0.5
No description provided.