Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix unix test compiling failed on MAC M1 #401

Closed
wants to merge 3 commits into from

Conversation

qdongxu
Copy link
Contributor

@qdongxu qdongxu commented Aug 16, 2023

No any unit test not be executed as the compiling failed with this issue :

https://stackoverflow.com/questions/74112738/underfined-function-error-in-go-jmptofunctionvalue
jenkins-x/jx#2081
https://github.com/procodr/monkey

the monkey patch unit tests still failed but the compile finished anyway and unit tests that are not related to the monkey patch can be executed.

@codecov-commenter
Copy link

codecov-commenter commented Aug 23, 2023

Codecov Report

Patch coverage: 92.42% and project coverage change: -0.26% ⚠️

Comparison is base (5b3a33c) 99.68% compared to head (18e8dda) 99.42%.
Report is 2 commits behind head on main.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #401      +/-   ##
==========================================
- Coverage   99.68%   99.42%   -0.26%     
==========================================
  Files          83       84       +1     
  Lines        5722     5769      +47     
==========================================
+ Hits         5704     5736      +32     
- Misses         12       25      +13     
- Partials        6        8       +2     
Files Changed Coverage Δ
metric/prometheus.go 90.35% <67.64%> (-9.65%) ⬇️
probe/base/base.go 98.02% <73.33%> (-1.98%) ⬇️
conf/constlables.go 100.00% <100.00%> (ø)
probe/base/metrics.go 100.00% <100.00%> (ø)
probe/host/basic.go 100.00% <100.00%> (ø)
probe/host/cpu.go 100.00% <100.00%> (ø)
probe/host/disk.go 100.00% <100.00%> (ø)
probe/host/load.go 100.00% <100.00%> (ø)
probe/host/mem.go 100.00% <100.00%> (ø)
probe/http/http.go 100.00% <100.00%> (ø)
... and 9 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@samanhappy
Copy link
Collaborator

samanhappy commented Aug 23, 2023

The original monkey repository has been archived by the owner, so we need to find a suitable alternative, the repository you are using seems just a temporary solution to me, how about this gomonkey repository? Could you help to test it on mac M1?

@qdongxu qdongxu changed the title fix unix test failed to run om MAC OS aarch64 cpu fix unix test compiling failed on MAC OS aarch64 cpu Aug 24, 2023
@qdongxu qdongxu changed the title fix unix test compiling failed on MAC OS aarch64 cpu fix unix test compiling failed on MAC M1 Aug 26, 2023
@qdongxu
Copy link
Contributor Author

qdongxu commented Sep 3, 2023

Testing gomonkey on MacOS M1, the issues https://github.com/agiledragon/gomonkey/issues?q=is%3Aissue++Macos+m1 still exists. and the interface and method of use changed in an incompatible way. It would only be worth doing the refactor until gomonkey is stable on MacOS M1/M2.

@samanhappy
Copy link
Collaborator

samanhappy commented Sep 3, 2023

You are right, gomonkey is not stable now, we should wait or find another library, thanks for your work.

@qdongxu qdongxu closed this Sep 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants