You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/09/18 05:31:15 UTC

[GitHub] [shardingsphere] linghengqian opened a new pull request, #21046: Update CODE_OF_CONDUCT about assertThat

linghengqian opened a new pull request, #21046:
URL: https://github.com/apache/shardingsphere/pull/21046

   Fixes #19845.
   
   Changes proposed in this pull request:
     - Update CODE_OF_CONDUCT about `assertThat`.
   
   ---
   
   Before committing this PR, I'm sure that I have checked the following options:
   - [x] My code follows the [code of conduct](https://shardingsphere.apache.org/community/en/involved/conduct/code/) of this project.
   - [x] I have self-reviewed the commit code.
   - [x] I have triggered maven check: `mvn clean install -B -T2C -DskipTests -Dmaven.javadoc.skip=true -e`.
   - [x] I have made corresponding changes to the documentation.
   - [x] I have added corresponding unit tests for my changes.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] sandynz commented on a diff in pull request #21046: Update CODE_OF_CONDUCT about assertThat

Posted by GitBox <gi...@apache.org>.
sandynz commented on code in PR #21046:
URL: https://github.com/apache/shardingsphere/pull/21046#discussion_r973828946


##########
CODE_OF_CONDUCT.md:
##########
@@ -63,7 +63,7 @@ The following code of conduct is based on full compliance with [ASF CODE OF COND
  - Environment preparation codes should be separate from test codes.
  - Only those that relate to junit `Assert`, hamcrest `CoreMatchers` and `Mockito` can use static import.
  - For single parameter asserts, `assertTrue`, `assertFalse`, `assertNull` and `assertNotNull` should be used.
- - For multiple parameter asserts, `assertThat` should be used.
+ - For multiple parameter asserts, `org.hamcrest.MatcherAssert.assertThat` should be used.

Review Comment:
   1, It might be better to put `MatcherAssert` in `Only those that relate to junit Assert, hamcrest CoreMatchers and Mockito can use static import.`, and keep `assertThat` simple. `org.junit.Assert.assertThat` is deprecated now, contributors will notice it in IDE.
   
   2, Looks there's another `code.en.md` could be updated.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] linghengqian commented on a diff in pull request #21046: Update CODE_OF_CONDUCT about assertThat

Posted by GitBox <gi...@apache.org>.
linghengqian commented on code in PR #21046:
URL: https://github.com/apache/shardingsphere/pull/21046#discussion_r974275924


##########
CODE_OF_CONDUCT.md:
##########
@@ -63,7 +63,7 @@ The following code of conduct is based on full compliance with [ASF CODE OF COND
  - Environment preparation codes should be separate from test codes.
  - Only those that relate to junit `Assert`, hamcrest `CoreMatchers` and `Mockito` can use static import.
  - For single parameter asserts, `assertTrue`, `assertFalse`, `assertNull` and `assertNotNull` should be used.
- - For multiple parameter asserts, `assertThat` should be used.
+ - For multiple parameter asserts, `org.hamcrest.MatcherAssert.assertThat` should be used.

Review Comment:
   I tweaked the word order to make it readable.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] sandynz merged pull request #21046: Update CODE_OF_CONDUCT about assertThat

Posted by GitBox <gi...@apache.org>.
sandynz merged PR #21046:
URL: https://github.com/apache/shardingsphere/pull/21046


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] sandynz commented on a diff in pull request #21046: Update CODE_OF_CONDUCT about assertThat

Posted by GitBox <gi...@apache.org>.
sandynz commented on code in PR #21046:
URL: https://github.com/apache/shardingsphere/pull/21046#discussion_r974816320


##########
CODE_OF_CONDUCT.md:
##########
@@ -63,7 +63,7 @@ The following code of conduct is based on full compliance with [ASF CODE OF COND
  - Environment preparation codes should be separate from test codes.
  - Only those that relate to junit `Assert`, hamcrest `CoreMatchers` and `Mockito` can use static import.
  - For single parameter asserts, `assertTrue`, `assertFalse`, `assertNull` and `assertNotNull` should be used.
- - For multiple parameter asserts, `assertThat` should be used.
+ - For multiple parameter asserts, `org.hamcrest.MatcherAssert.assertThat` should be used.

Review Comment:
   Nice



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org