Fork me on GitHub

Sorry @lee late response, I want to change the messag in Clojure CI / cloverage (pull_request) Successful in 4m to Clojure CI / cloverage (pull_request) Testing coverage is 80% , do you think is that possible?


@fabrao Oh I see. You want to see a summary of % coverage without digging into the workflow output. kinda sorta does this. I personally did not like this behaviour and disabled it, but by default it will add a comment to your PR. Here's


Ho, that´s nice, but I want something more simple, just a message. But I think it´s more like github integration stuff, thank you


Yeah, I hear ya, might be possible, but I also would not be surprised if GitHub would want to keep that top-level summary message standard/fixed. Let us know if you find a way!


I could use in other way, but could not in the same line as the checking, that I want to do. But it solve the issue in anyway.


Congrats! Is your project open source, can you share details on how you achieved this?


the project is private but I can share the way we did it for github action:

# Run tests
      - name: Run Coverage Tests
        run: clojure -M:cloverage > /tmp/cloverage.txt

      - name: Generate covarege Status
        run: |
          set -x
          total=`cat /tmp/cloverage.txt | grep "ALL FILES" | grep -Eo '[0-9]+\.[0-9]+' | head -1`
          echo "total coverage: $total"
          curl "https://${{ }}:${{ github.token }}${COMPANY}/${PROJECT}/statuses/${COMMIT_SHA}" -d "{\"state\": \"success\",\"target_url\": \"\",\"description\": \"${total}%\",\"context\": \"Resultado cobertura dos testes\"}"
		  COMPANY: "company_name"
		  PROJECT: "project_name"
          COMMIT_SHA: ${{ github.event.pull_request.head.sha }}
          PULL_NUMBER: ${{ github.event.pull_request.number }}
          RUN_ID: ${{ github.run_id }}


  {:extra-paths ["test"]
   :extra-deps {cloverage/cloverage {:mvn/version "1.2.2"}
                babashka/process {:mvn/version "0.0.2"}
                spec-provider/spec-provider {:mvn/version "0.4.14"}}
   :main-opts ["-m" "cloverage.coverage"
               "-p" "src"
               "-s" "test"
               "-t" "^(?!.*?(?:live|integration)).*$"
               "--fail-threshold" "30"]}


Interesting @fabrao, thank you for sharing!