Codeclimate์ ๋ํ ์ฝ๋ ์ ์ฉ ๋ฒ์ ๋ณด๊ณ ๋ ํญ์ ์คํจํฉ๋๋ค. 0.18+ ํ์์ SimpleCov ์ถ๋ ฅ(๋ถ๊ธฐ ์ ์ฉ ๋ฒ์ ๋ฑ)์ ์ง์ํ์ง ์๊ธฐ ๋๋ฌธ์ ๋๋ค.
๋๋ codeclimate ๊ธฐ์์ ๋ ๋ฒ์งธ ๋จ๊ณ์์ ์ค๋ฅ ์ถ๋ ฅ์ ์ธ์ํ์ต๋๋ค. a Go๊ฐ ์ต์ SimpleCov ํ์์ ๊ตฌ๋ฌธ ๋ถ์ํ์ง ๋ชปํ์ต๋๋ค.
Error: json: cannot unmarshal object into Go struct field input.coverage of type []formatters.NullInt
Usage:
cc-test-reporter after-build [flags]
~ ์ ์ : simplecov๋ฅผ codeclimate ์ง์ ๋ฒ์ ์ผ๋ก ๋ค์ด๊ทธ๋ ์ด๋ํ๊ณ ๊ฑฐ๊ธฐ์ ์ฝ๋ ์ฃผ์์ ๋จ๊ฒจ๋์ธ์.~
์ ์, ์ ๋ฐ์ดํธ : Codeclimate๊ฐ ๋ชจ๋ SimpleCov๋ฅผ ์ง์ํ ๋๊น์ง ์ ์ฉ ๋ฒ์ ๋ณด๊ณ ๋ฐ ๋ฐฐ์ง๋ฅผ ๋นํ์ฑํํฉ๋๋ค. ์ด ๋ฌธ์ ๋ ์ด์ ๋ํ ์ถ์ ๋ฌธ์ ๋ก ๊ณ์ ์ด๋ ค ์์ ์ ์์ต๋๋ค.
์ด GH Actions ์คํจ๋ฅผ ์ฐธ์กฐํ์ญ์์ค. https://github.com/lostisland/faraday/runs/543272466?check_suite_focus=true#step :9:8
CI๊ฐ ํด๋น ๋จ๊ณ๋ฅผ ์ง๋ ์คํ๋๋ฉด Ruby 2.6์์๋ง ํด๋น ํ๋ก๊ทธ๋จ์ด ์คํ๋ฉ๋๋ค. ์คํจ ์ ์ข ๋ฃ ์ฝ๋๋ 255์ด๋ฉฐ ์ถ๋ ฅ์ ์์ ๊ฐ์ต๋๋ค.
์ด๊ฒ์ ๋ํด ๋ ๊น์ด ์๊ฐํด๋ณด๋ฉด, ๋๋ CodeClimate์ Go ํ๋ก๊ทธ๋จ์ด SimpleCov๋ฅผ ๋ค๋ก ๋ฏธ๋ฃจ๋ ๊ฒ์ ์ํ์ง ์์ต๋๋ค. ๋์ README์์ ์ปค๋ฒ๋ฆฌ์ง ๋ฐฐ์ง๋ฅผ ์ ๊ฑฐํ๋๋ก ์ ํํ๊ฒ ์ต๋๋ค. SimpleCov 0.18+๋ฅผ ์ง์ํ๋ฉด ๋ฐฐ์ง๋ฅผ ๋ค์ ๋ฃ์ ์ ์์ต๋๋ค.
๊ธฐ์ ๋ฌธ์ :
https://github.com/codeclimate/test-reporter/issues/413
https://github.com/colszowka/simplecov/releases ์์ ๋ง์ ์์ ์ด ์งํ ์ค์ ๋๋ค.
์ด๋ฌํ ์ ๊ฑฐ์ ํจ๊ป "์ปค๋ฒ๋ฆฌ์ง ๋ฐ์ดํฐ๋ฅผ ์ ์กํ๋ CI ํญ๋ชฉ๋ ์ญ์ "๋ฉ๋๋ค.
์ค์ ๋ก CodeClimate์ ํ ์คํธ ๋ณด๊ณ ์๊ฐ ์ง์ํ์ง ์๋๋ค๋ ์ด์ ๋ง์ผ๋ก SimpleCov๋ฅผ ๋ค์ด๊ทธ๋ ์ด๋ํด์๋ ์ ๋ฉ๋๋ค. ์์ ์ฌํญ์ด ํธ์๋ ๋๊น์ง ํ ์คํธ ๋ฆฌํฌํฐ ๋นํ์ฑํ์ ๋์ํฉ๋๋ค.
์ข์ ์์!
https://github.com/codeclimate/test-reporter/issues/413#issuecomment -749542129
์ฝ๋๊ธฐํ๋ฅผ ์ ๊ฑฐํ๊ณ ๋ซ์ต๋๋ค.