Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-7351

Action tests/covered_files should not fail on unknown test ID

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: 5.6
    • Component/s: Web API
    • Labels:

      Description

      A 404 error should be send when the test is not found, not a 500 error.

      Here's the stacktrace :

      2016.02.16 11:56:42 ERROR web[o.s.s.w.WebServiceEngine] Fail to process request http://nemo.sonarqube.org/api/tests/covered_files?testId=f4100f1b-501d-47b1-8b23-9f3587c1fecf
      java.lang.IllegalStateException: Test id 'f4100f1b-501d-47b1-8b23-9f3587c1fecf' not found
      	at org.sonar.server.test.index.TestIndex.searchByTestUuid(TestIndex.java:100) ~[sonar-server-5.4-RC2.jar:na]
      	at org.sonar.server.test.ws.CoveredFilesAction.handle(CoveredFilesAction.java:78) ~[sonar-server-5.4-RC2.jar:na]
      	at org.sonar.server.ws.WebServiceEngine.execute(WebServiceEngine.java:85) ~[sonar-server-5.4-RC2.jar:na]
      	at sun.reflect.GeneratedMethodAccessor165.invoke(Unknown Source) ~[na:na]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_71]
      	at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_71]
      

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            julien.lancelot Julien Lancelot
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: