Hi, we're trying to use VSO for xcode builds, where we are using a tool called OCJunit2JUnit that generates JUnit test reports (XML) from xcode builds.
However, there are two problems with the vso-test-publisher. First of all, it doesn't handle the <testsuites>
-tag, which is in the JUnit specification. We've created a way around that though.
The problem we're facing now, are that we are getting 400 from the API when it tries to publish the test results. (Still using the built in JUnit test reporter)
I logged the payload, but I can't find any specification from the API on the keys that are mandatory.
Here are a gist of what we are sending:
{ state: 'Completed',
computerName: '',
resolutionState: null,
testCasePriority: 1,
failureType: null,
automatedTestName: 'testDecompressData_WhenEmptyData_SomeDataIsReturned',
automatedTestStorage: 'EncodingUtilsTests',
automatedTestType: 'JUnit',
automatedTestTypeId: null,
automatedTestId: null,
area: null,
owner: 'Martin Jensen',
runBy: 'Martin Jensen',
testCaseTitle: 'testDecompressData_WhenEmptyData_SomeDataIsReturned',
revision: 0,
dataRowCount: 0,
testCaseRevision: 0,
outcome: 'Passed',
errorMessage: '',
durationInMs: 0.4 },
{ state: 'Completed',
computerName: '',
resolutionState: null,
testCasePriority: 1,
failureType: null,
automatedTestName: 'testDecompressData_WhenNilData_NilAndErrorIsReturned',
automatedTestStorage: 'EncodingUtilsTests',
automatedTestType: 'JUnit',
automatedTestTypeId: null,
automatedTestId: null,
area: null,
owner: 'Martin Jensen',
runBy: 'Martin Jensen',
testCaseTitle: 'testDecompressData_WhenNilData_NilAndErrorIsReturned',
revision: 0,
dataRowCount: 0,
testCaseRevision: 0,
outcome: 'Passed',
errorMessage: '',
durationInMs: 0.077 },
{ state: 'Completed',
computerName: '',
resolutionState: null,
testCasePriority: 1,
failureType: null,
automatedTestName: 'testEncodeDataWithBase64_WhenDataInitializedEmpty_ReturnsEmptyString',
automatedTestStorage: 'EncodingUtilsTests',
automatedTestType: 'JUnit',
automatedTestTypeId: null,
automatedTestId: null,
area: null,
owner: 'Martin Jensen',
runBy: 'Martin Jensen',
testCaseTitle: 'testEncodeDataWithBase64_WhenDataInitializedEmpty_ReturnsEmptyString',
revision: 0,
dataRowCount: 0,
testCaseRevision: 0,
outcome: 'Passed',
errorMessage: '',
durationInMs: 0.075 },
{ state: 'Completed',
computerName: '',
resolutionState: null,
testCasePriority: 1,
failureType: null,
automatedTestName: 'testEncodeDataWithBase64_WhenNilData_ReturnsNil',
automatedTestStorage: 'EncodingUtilsTests',
automatedTestType: 'JUnit',
automatedTestTypeId: null,
automatedTestId: null,
area: null,
owner: 'Martin Jensen',
runBy: 'Martin Jensen',
testCaseTitle: 'testEncodeDataWithBase64_WhenNilData_ReturnsNil',
revision: 0,
dataRowCount: 0,
testCaseRevision: 0,
outcome: 'Passed',
errorMessage: '',
durationInMs: 0.063 },
{ state: 'Completed',
computerName: '',
resolutionState: null,
testCasePriority: 1,
failureType: null,
automatedTestName: 'testEncodeDataWithBase64_WhenNonEmptyData_ReturnsEncodedString',
automatedTestStorage: 'EncodingUtilsTests',
automatedTestType: 'JUnit',
automatedTestTypeId: null,
automatedTestId: null,
area: null,
owner: 'Martin Jensen',
runBy: 'Martin Jensen',
testCaseTitle: 'testEncodeDataWithBase64_WhenNonEmptyData_ReturnsEncodedString',
revision: 0,
dataRowCount: 0,
testCaseRevision: 0,
outcome: 'Passed',
errorMessage: '',
durationInMs: 0.081 },