行覆盖率:类文件中覆盖的行百分比。
Line coverage: the percentage of lines covered in the class file.
行覆盖只是指出代码的哪些行被执行。
Line coverage simply indicates that a particular line of code was exercised.
这表明行覆盖的确不能很好地指示测试的有效性。
It turns out that line coverage isn't such a great indicator of test effectiveness.
请注意行覆盖和分支覆盖的百分比是以包计算的。
覆盖细节视图,只有当你收集了方法和行覆盖以后才有效。
Coverage Detail views, available only if you collect both method and line coverage.
作为响应,我可以编写一个测试,它将达到100%的行覆盖率。
In response, I can write one test, which achieves 100 percent line coverage.
存在不同类型的覆盖度量,但是绝大多数的工具会关注行覆盖,也叫做语句覆盖。
There are different types of coverage measurements, but most tools focus on line coverage, also known as statement coverage.
诸如评论之类的非执行行不会被注释,并不会对代码行覆盖率百分比的计算产生影响。
Non-executable lines such as comments are not annotated and do not contribute to the calculation of the line coverage percentage.
在图4的报告中显示我达到了 75% 的行覆盖率和 100% 的分支覆盖率。
The report in Figure 4 shows that I've achieved 75% line coverage and 100% branch coverage.
如果一个方法有10行代码,其中的8行在测试中被执行,那么这个方法的行覆盖率是80%。
If a method is 10 lines long and 8 lines of the method were exercised in a test run, then the method has a line coverage of 80%.
代码覆盖工具可报告测试覆盖率——以行覆盖或分支覆盖形式表示——它表示测试运行时所涉及的代码量。
A code coverage tool reports test coverage — either in the form of line or branch coverage — that represents the amount of code that is being touched when a test is run.
与行覆盖一样,如果在特定方法中有两个分支,并且两个分支在测试中都被覆盖,那么您可以说这个方法有100%的分支覆盖率。
Just like line coverage, if there are two branches in a particular method and both were covered through tests, then you could say the method has 100% branch coverage.
这个过程在总体层次上也工作得很好:如果一个类有100行代码,其中的45行被触及,那么这个类的行覆盖率就是45%。
The process works at the aggregate level as well: If a class has 100 lines and 45 of them were touched, then the class has a line coverage of 45%.
同样,如果一个代码库包含10000个非注释性的代码行,在特定的测试运行中有3500行被执行,那么这段代码的行覆盖率就是35%。
Likewise, if a code base comprises 10,000 non-commenting lines of code and 3,500 of them were exercised on a particular test run, then the code base's line coverage is 35%.
根据缺损面积大小常规行局部皮瓣,筋膜瓣及腓肠肌内侧头肌皮瓣转移修复术使创面彻底覆盖。
Be sure of the wound cleansed of all dead and foreign material, the wound was covered with local flap, musculocutaneous or gastrocnemius flaps depending on the size and localization of wound.
你可以浏览未覆盖的代码行(可能是在程序员的辅助下)以发现你忽略的某种测试。
You might glance at the uncovered lines of code (possibly assisted by the programmer) to discover the kinds of tests you omitted.
软件包的代码行增加了,但是没有为新代码编写相应的测试(或者是新增加的测试不能有效地覆盖新代码)。
The package grew in terms of lines of code, but no corresponding tests were written for the new code (or that newly added tests do not effectively cover the new code).
更妙的是,我可以在浏览器中打开一个覆盖率文件并查看测试用例所覆盖的代码行。
Better still, I can open a coverage file in my browser and see exactly which lines of code my test cases cover.
这个工具分析内核代码的覆盖率,并报告哪些行、函数和分支被覆盖以及它们被访问了多少次。
This tool analyzes the coverage of the kernel, and reports what lines, functions, and branches are covered and how many times they were hit.
公司为员工提供的11条班车线路覆盖闵行、徐汇、长宁、普陀、浦东等地。
The company offers 11 Shuttle bus in Shanghai which could cover Minhang, Xuhui, Changning, Putuo, Pudong and other places.
您可以通过许多方法来测量代码覆盖率:通过评估代码行或语句的覆盖面、条件覆盖面、分支覆盖面等等。
You can measure code coverage in several ways: by assessing line or statement coverage, condition coverage, branch coverage, and so on.
对于最后一行,可以使用 $表示文件的末尾。 可以在w 后面使用两个大于号(>>)表示希望把内容附加到文件中而不是覆盖文件。
You can use the $ notation for the last line to specify to the end of the file and double greater-than symbols (>>) after the w to indicate that you want to append to rather than overwrite the file.
每一行代码都应该被白盒测试覆盖。
Every line of code should be walked through in a "white box" testing manner.
当每个方法都有了至少一个测试,使用一个代码覆盖率工具如cobertura为每个分支编写一个测试,直到每一行代码都能够被测试。
Once every method has at least one test, use a code coverage tool, such as Cobertura, to write one test for every branch until each line of code is tested.
也就是,默认条件下,绿色的行是覆盖的而红色的则不是覆盖的。
That is, by default a green line was covered and a red line was not covered.
不过您可以在源代码中覆盖这一行为。
最基本的一种方式是覆盖此网格select编辑器的格式化程序来返回针对所选行的选项信息。
Minimally, you can override the formatter for the grid select editor to return option information for the selected row.
方法:转移扩张后的耳后皮瓣覆盖耳支架行全耳廓再造。
Methods: to transfer the expanded retroauricular flap to reconstruct auricles for those patients suffered with traumatic ear defects.
方法:转移扩张后的耳后皮瓣覆盖耳支架行全耳廓再造。
Methods: to transfer the expanded retroauricular flap to reconstruct auricles for those patients suffered with traumatic ear defects.
应用推荐