I’m not sure if the package name matters because according to the docs it going to combine
sources with the filename fields.
So my file is called: cmd/echoServer/echoServer.go and I’m assuming since source is . this should render correctly?
Am I correct here? (because its not working )
Question 1: I’m on a ci branch - do I need to merge back into master for this to work?
Question 2: Is my <source> <filename> combo correct?
Question 3: Is there any way to view the gitlab logs to see if this is being processed correctly?
Question 4: If we are paid subscribers - is there a better way to get support?
Question 5: Is there a sample repo available to test out the coverage feature? This would be very helpful
It would be nice if you could in the future use the predefined template when posting a question E.g. it’s hard to tell anything because you didn’t post your .gitlab-ci.yml file (or relevant part of it).
Q1: Depends on your config in .gitlab-ci.yml and how you want it to work. It does not need to be on master.
Q2: GitLab does not care about this. You have to parse (regex) your result file anyways additionally as described here and in the YAML definition
Q3: Not sure.
Q4: Yes. You have Customer support according to your tier and you can reach out by opening a support ticket: https://support.gitlab.com/hc/en-us
Q5: There is an example of code coverage visualization: GitLab.org / ci-sample-projects / Coverage Report · GitLab , for collecting coverage number I didn’t find, but it’s really just parsing the number from the file correctly using regex.
Okay, so you are solving the “visualization problem”?
Note: It works (is visible) ONLY in MRs. Not when you push a file to a branch.
Generally, CI Config looks good to me. So I believe it’s just about your xml file.
In order to get visualization, you need to have information about all the lines in correct (cobertura) format. When this is correct, you should see visualization like on the sample project.
I just checked my coverage.xml (auto-generated by Python’s pytest), and it could be you should change your <source></source> path. What I have is:
So I believe it depends on project structure. builds/group_name/project_name is normally default build location in CI (CI_BUILDS_DIR variable), so you could try setting that one. Then all the other package names should be relative to that.
Can you also link to documentation pages that you’ve been researching so far?