@Test public void testSuitePerformanceDataUnknownData() throws Exception { BaseTest.assertRegExMatch( AbstractPerformanceDataBuilder.getTestSuitePerformanceData( new TestSuiteExampleBuilder().withState(TestSuiteState.ERRORS).buildExample() ), "suite__state=2;;;; suite_UnitTest_\\d*=U;;;;.*"); }
protected static String getTestSuitePerformanceData(TestSuite testSuite) { OutputState outputState = OutputState.lookupSakuliState(testSuite.getState()); String data = ""; data = addPerformanceDataRow(data, "suite__state", String.valueOf(outputState.getErrorCode()), null, null); data = addPerformanceDataRow4Threshold(data, "suite", testSuite.getWarningTime(), testSuite.getCriticalTime()); final String suiteName = "suite_" + testSuite.getId(); if (testSuite.getState() != null && testSuite.getState().isFinishedWithoutErrors()) { data = addPerformanceDataRow(data, suiteName, testSuite.getDuration(), testSuite.getWarningTime(), testSuite.getCriticalTime()); } else { data = addUnknownPerformanceDataRow(data, suiteName); } data = addTestCasePerformanceData(data, testSuite.getTestCasesAsSortedSet()); return data; }
AbstractPerformanceDataBuilder { protected static String getTestSuitePerformanceData(TestSuite testSuite) { OutputState outputState = OutputState.lookupSakuliState(testSuite.getState()); String data = ""; data = addPerformanceDataRow(data, "suite__state", String.valueOf(outputState.getErrorCode()), null, null); data = addPerformanceDataRow4Threshold(data, "suite", testSuite.getWarningTime(), testSuite.getCriticalTime()); final String suiteName = "suite_" + testSuite.getId(); if (testSuite.getState() != null && testSuite.getState().isFinishedWithoutErrors()) { data = addPerformanceDataRow(data, suiteName, testSuite.getDuration(), testSuite.getWarningTime(), testSuite.getCriticalTime()); } else { data = addUnknownPerformanceDataRow(data, suiteName); } data = addTestCasePerformanceData(data, testSuite.getTestCasesAsSortedSet()); return data; } }
AbstractPerformanceDataBuilder { protected static String getTestSuitePerformanceData(TestSuite testSuite) { OutputState outputState = OutputState.lookupSakuliState(testSuite.getState()); String data = ""; data = addPerformanceDataRow(data, "suite__state", String.valueOf(outputState.getErrorCode()), null, null); data = addPerformanceDataRow4Threshold(data, "suite", testSuite.getWarningTime(), testSuite.getCriticalTime()); final String suiteName = "suite_" + testSuite.getId(); if (testSuite.getState() != null && testSuite.getState().isFinishedWithoutErrors()) { data = addPerformanceDataRow(data, suiteName, testSuite.getDuration(), testSuite.getWarningTime(), testSuite.getCriticalTime()); } else { data = addUnknownPerformanceDataRow(data, suiteName); } data = addTestCasePerformanceData(data, testSuite.getTestCasesAsSortedSet()); return data; }  }
AbstractPerformanceDataBuilder { protected static String getTestSuitePerformanceData(TestSuite testSuite) { OutputState outputState = OutputState.lookupSakuliState(testSuite.getState()); String data = ""; data = addPerformanceDataRow(data, "suite__state", String.valueOf(outputState.getErrorCode()), null, null); data = addPerformanceDataRow4Threshold(data, "suite", testSuite.getWarningTime(), testSuite.getCriticalTime()); final String suiteName = "suite_" + testSuite.getId(); if (testSuite.getState() != null && testSuite.getState().isFinishedWithoutErrors()) { data = addPerformanceDataRow(data, suiteName, testSuite.getDuration(), testSuite.getWarningTime(), testSuite.getCriticalTime()); } else { data = addUnknownPerformanceDataRow(data, suiteName); } data = addTestCasePerformanceData(data, testSuite.getTestCasesAsSortedSet()); return data; }   }
AbstractPerformanceDataBuilder { protected static String getTestSuitePerformanceData(TestSuite testSuite) { OutputState outputState = OutputState.lookupSakuliState(testSuite.getState()); String data = ""; data = addPerformanceDataRow(data, "suite__state", String.valueOf(outputState.getErrorCode()), null, null); data = addPerformanceDataRow4Threshold(data, "suite", testSuite.getWarningTime(), testSuite.getCriticalTime()); final String suiteName = "suite_" + testSuite.getId(); if (testSuite.getState() != null && testSuite.getState().isFinishedWithoutErrors()) { data = addPerformanceDataRow(data, suiteName, testSuite.getDuration(), testSuite.getWarningTime(), testSuite.getCriticalTime()); } else { data = addUnknownPerformanceDataRow(data, suiteName); } data = addTestCasePerformanceData(data, testSuite.getTestCasesAsSortedSet()); return data; }    }