Ok, Tks, I get it.
------------------ ???????? ------------------ ??????: "Sion Yang"<[email protected]>; ????????: 2019??9??27??(??????) ????9:55 ??????: "dev"<[email protected]>; ????: Re:??????config rules to exclude some unnecessary code for unit codecoverage? Hi, sluk3r. For single method such as set/get method, we use Lombok to generate. These code can miss unit test. But other methods should be full covered, if no particular reasons. For the method you print out. I think it should have a unit test, even use Mockito backendDataSource. In community document[1], you can see the `Covenant Unit Test of Conduct` [1] https://shardingsphere.apache.org/community/en/contribute/code-conduct/ -- Yi Yang(Sion) Apache ShardingSphere ?? 2019-09-27 09:25:49??"??????" <[email protected]> ?????? >Hi, Sion Yang: > > >the method's whole implementation is: > > >public Map<String, YamlDataSourceParameter> getDataSources() { > return backendDataSource.getDataSourceParameters(); >} >there is just a single return statement, intuitively, I think there is little >necessary to unit test this method. Or this type of problem has been >discussed, and agreement has been achieved? give me a point, pls. >Tks > > > > >------------------ ???????? ------------------ >??????: "Sion Yang"<[email protected]>; >????????: 2019??9??27??(??????) ????8:51 >??????: "dev"<[email protected]>; > >????: Re:config rules to exclude some unnecessary code for unit codecoverage? > > > >Hi, sluk3r. > > >How to judge these codes are unnecessary or little necessary? > > > > >-- > >Yi Yang(Sion) >Apache ShardingSphere > > >At 2019-09-27 05:40:16, "??????" <[email protected]> wrote: > >Hi, for example, the code shown in the following pic, method of >getDataSources return "backendDataSource.getDataSourceParameters()" directly. >the full url is : >https://coveralls.io/builds/25937232/source?filename=sharding-proxy/sharding-proxy-backend/src/main/java/org/apache/shardingsphere/shardingproxy/backend/schema/LogicSchema.java > > > > >it seems that there is little necessary for some code. > > >So I'd like to know, is there some standard for unit code coverage rate? if >so, has this coverage rate been configured into some file? > > > > >Tks.
