Uploaded image for project: 'Xray for Jira'
  1. Xray for Jira
  2. XRAY-2060

Issue importing testcases with decimal point in name

    XporterXMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Done
    • R2.3.1
    • R2.3.2
    • None
    • OK

    Description

      Hi,

      I am trying to import a test execution via the Rest API and NUNIT report, i.e. this endpoint
      /rest/raven/1.0/import/execution/nunit?projectKey=XT

      I encounter an issue when the test case name contains a decimal place. If the test name has a decimal point it's cropping everything before the last occurrence of that decimal point e.g.

      test-case: Given Tote is rendered When totePlc is 2.9 Then the element with the class totePlc will contain the text 2.9
      Test name= "9" WRONG

      test-case: Given Tote is rendered When totePlc is 2.9 Then the element with the class totePlc will contain the text 2point9
      Test name= "9 Then the element with the class totePlc will contain the text 2point9" WRONG

      test-case: Given Tote is rendered When totePlc is 2point9 Then the element with the class totePlc will contain the text 2point9
      Test name= "Given Tote is rendered When totePlc is 2point9 Then the element with the class totePlc will contain the text 2point9" CORRECT

      These are mocha js unit tests originally and many test names have decimal places, it would be good for us if this character could be supported.

      Below is a sample NUnit report to reproduce the issue:

      <test-results
      	xmlns:xalan="http://xml.apache.org/xslt"
                    name="Root Suite"
                    total="43"
                    failures="0"
                    not-run="0"
                    time="0">
      	<test-suite name="Root Suite"
                     description=""
                     success="True"
                     time="0"
                     asserts="43">
      		<results/>
      	</test-suite>	
      	<test-suite name="When totePlc is 2.9"
                     description="C:\Workspace\git\spring-carnival-companion\src\components\Tote\tests\Tote.spec.js"
                     success="True"
                     time="0.002"
                     asserts="43">
      		<results>
      			<test-case name="Given Tote is rendered When totePlc is 2.9 Then the element with the class tote.Plc will contain the text 2.9"
                          description="Then the element with the the class totePlc will contain the text 2.9"
                          success="True"
                          time="0.002"
                          executed="True"
                          asserts="1"
                          result="Success">
      				<categories>
      					<category name="S"/>
      				</categories>
      			</test-case>
      		</results>
      	</test-suite>
      </test-results>	
      

      Attachments

        Activity

          People

            dpca Diamantino Campos
            stuart.parton@crownbet.com.au Stuart Parton
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 4 hours
                4h
                Remaining:
                Time Spent - 2 hours, 20 minutes Remaining Estimate - 1 hour, 40 minutes
                1h 40m
                Logged:
                Time Spent - 2 hours, 20 minutes Remaining Estimate - 1 hour, 40 minutes
                2h 20m