GitLab SonarQube Integration - Scan Maven Based Java Codebase

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ก.ย. 2024
  • Demonstrate Pipeline to integrate GitLab hosted Runner with SonarQube CE Version 10.4 for static analysis of Java codebase.
    Repo URL referenced in this Demo : gitlab.com/ana...

ความคิดเห็น • 6

  • @pukayurac1
    @pukayurac1 หลายเดือนก่อน

    It's perfect. I'm using SonarQube 9.9, and so far, I'm getting an error when the pipeline says "Not authorized. Please check the properties sonar.login and sonar.password." It's strange because I followed all the steps to set it up with a TOKEN.

    • @crudsinfotechng8127
      @crudsinfotechng8127  หลายเดือนก่อน

      There should not be much difference with the pipeline syntax for the older version of SonarQube and unless any of the variable config is different (visibility, hidden etc), can not think of anything that could be amiss.

  • @tarunpatel05
    @tarunpatel05 2 หลายเดือนก่อน

    Hi Chidanand,
    I have one scenario,
    I want to get the code coverage from the selenium test cases which are functional test cases,
    The application has 2 different repo one is for back end and other one is for front end together when built they form the application, which runs on on endpoint, using the same endpoint we test that application,
    our selenium test cases are in different repository(3rd repo, btw all repos are in gitlab),
    can it be possible, when i run the selenium test cases , then code coverage is recorded somewhere like in 2 dev repos and i get the result after this regression e2e suite?
    do you have any example or use case, Please suggest,
    edited : sonarqube and jacoco is implemented in project but it ran only for Junit test cases
    Thanks,

    • @crudsinfotechng8127
      @crudsinfotechng8127  2 หลายเดือนก่อน +1

      Hello Tarun,
      I am not sure if I understood your question correctly. Code Coverage % is typically associated with static analysis of the code & is calculated when the code is at rest (not even deployed). Jacoco, SonarQube, PMD, FindBugs etc are used for this purpose.
      If you have deployed the code and running Selenium test cases to check functionality, unless you have used some BDD specs that outline your functional business case, I am not sure if there are any ready tools that can possibly create Feature Coverage report that outlines which business case passed v/s failed, that too for Selenium.
      Hope this helps.

    • @tarunpatel05
      @tarunpatel05 2 หลายเดือนก่อน

      @@crudsinfotechng8127
      Hi Sir,
      My question was - basically we perform code coverage by writing unit test cases either of junit and testng and in the same repo/folder structure, where developer codes resides, so it gives the result in the same repo or same folder structure,
      but when we perform end to end testing or say black box testing, can we record code coverage while performing it? because automation test repo is at different place, and it perform black box testing,
      so i am running automated test case to the running application, which is built on java spring and front end is in angular,
      so can we perform code coverage when automated test case runs?

    • @tarunpatel05
      @tarunpatel05 2 หลายเดือนก่อน

      @@crudsinfotechng8127
      Hi Chidanand,
      Thanks for reply, i was asking can we perform code coverage from selenium end to end test cases?