コード例 #1
0
 private void addMethodLevelIssuesTo(Set<String> issues) {
   String issue = TestAnnotations.forClass(testCase).getAnnotatedIssueForMethod(getMethodName());
   if (issue != null) {
     issues.add(issue);
   }
   String[] multipleIssues =
       TestAnnotations.forClass(testCase).getAnnotatedIssuesForMethod(getMethodName());
   if (multipleIssues != null) {
     issues.addAll(Arrays.asList(multipleIssues));
   }
 }
コード例 #2
0
 private void addClassLevelIssuesTo(Set<String> issues) {
   String classIssue = TestAnnotations.forClass(testCase).getAnnotatedIssueForTestCase(testCase);
   if (classIssue != null) {
     issues.add(classIssue);
   }
   String[] classIssues =
       TestAnnotations.forClass(testCase).getAnnotatedIssuesForTestCase(testCase);
   if (classIssues != null) {
     issues.addAll(Arrays.asList(classIssues));
   }
 }
コード例 #3
0
 private void addMethodLevelIssuesTo(List<String> issues) {
   Optional<String> issue =
       TestAnnotations.forClass(testOutcome.getTestCase())
           .getAnnotatedIssueForMethod(testOutcome.getName());
   if (issue.isPresent()) {
     issues.add(issue.get());
   }
   String[] multipleIssues =
       TestAnnotations.forClass(testOutcome.getTestCase())
           .getAnnotatedIssuesForMethod(testOutcome.getName());
   issues.addAll(Arrays.asList(multipleIssues));
 }
コード例 #4
0
 private void addMethodLevelVersionsTo(List<String> versions) {
   Optional<String> version =
       TestAnnotations.forClass(testOutcome.getTestCase())
           .getAnnotatedVersionForMethod(testOutcome.getName());
   if (version.isPresent()) {
     versions.add(version.get());
   }
 }
コード例 #5
0
 private void addClassLevelVersionsTo(List<String> versions) {
   String classVersion =
       TestAnnotations.forClass(testOutcome.getTestCase())
           .getAnnotatedVersionForTestCase(testOutcome.getTestCase());
   if (classVersion != null) {
     versions.add(classVersion);
   }
 }
コード例 #6
0
 private String obtainTitleFromAnnotationOrMethodName() {
   String annotatedTitle =
       TestAnnotations.forClass(testCase).getAnnotatedTitleForMethod(methodName);
   if (annotatedTitle != null) {
     return annotatedTitle;
   }
   return NameConverter.humanize(withNoArguments(methodName));
 }
コード例 #7
0
 private boolean isIgnored(final Method method) {
   return TestAnnotations.isIgnored(method);
 }