private TestDescription[] initTestsAndIndexes() { DynamicObject[] testObjects = getTestObjects(); TestDescription[] tests = new TestDescription[testObjects.length]; indeces = new HashMap<>(tests.length); Map<String, Object> properties = getProperties(); Integer precision = null; if (properties != null && properties.containsKey(PRECISION_PARAM)) { precision = Integer.parseInt(properties.get(PRECISION_PARAM).toString()); } IOpenMethod testedMethod = getTestedMethod(); ColumnDescriptor[] descriptors = getDescriptors(); List<IOpenField> fields = createFieldsToTest(testedMethod, descriptors, precision); for (int i = 0; i < tests.length; i++) { tests[i] = new TestDescription(testedMethod, testObjects[i], fields, descriptors, db); tests[i].setIndex(i); indeces.put(tests[i].getId(), i); } return tests; }
tasks.add(new WriteTask(new Cursor(rowNum, colNum++), description.getId(), styles.parameterValue, maxHeight));
private void writeTestcase(String testName, ITestUnit test) throws XMLStreamException { if (test.getResultStatus() == TR_OK) { empty("testcase"); } else { start("testcase"); } attr("name", test.getTest().getId()); attr("classname", testName); attr("time", getTime(test.getExecutionTime())); writeErrorOrFailureElement(test); if (test.getResultStatus() != TR_OK) { end(); } }
private void writeTestcase(String testName, ITestUnit test) throws XMLStreamException { if (test.getResultStatus() == TR_OK) { empty("testcase"); } else { start("testcase"); } attr("name", test.getTest().getId()); attr("classname", testName); attr("time", getTime(test.getExecutionTime())); writeErrorOrFailureElement(test); if (test.getResultStatus() != TR_OK) { end(); } }
createCell(row, colNum++, testUnit.getTest().getId(), ok ? styles.resultSuccessId : styles.resultFailureId);