]> source.dussan.org Git - sonarqube.git/commit
SONAR-14175 Prevent using same password as before in api/users/change_password
authorJulien Lancelot <julien.lancelot@sonarsource.com>
Thu, 26 Nov 2020 07:56:50 +0000 (08:56 +0100)
committersonartech <sonartech@sonarsource.com>
Wed, 2 Dec 2020 20:06:57 +0000 (20:06 +0000)
commit344a9c94aaf3478f9c0362b5977fbda84352440a
treef74371f24b39b3c351bb73b85721d637b2da18a0
parent7925daf9d5b9978f5dcfbde74fe950091bd209fa
SONAR-14175 Prevent using same password as before in api/users/change_password

* Prevent using same password as before in api/users/change_password
* Improve UT
- Replace usage of ExpectedException by assertThatThrownBy
- Add expected message when exceptions are thrown (help me to detect that some UTs were not covering the correct use case)
- Use generated values as much as possible
server/sonar-webserver-webapi/src/main/java/org/sonar/server/user/ws/ChangePasswordAction.java
server/sonar-webserver-webapi/src/test/java/org/sonar/server/user/ws/ChangePasswordActionTest.java