petergtz / pegomock

Pegomock is a powerful, yet simple mocking framework for the Go programming language
Apache License 2.0
252 stars 28 forks source link

I migrated to v3 but having trouble migrating to v4 #122

Closed nitrocode closed 11 months ago

nitrocode commented 1 year ago

Hi! Thank you for a great library. It's been very helpful in the runatlantis project.

I followed your notes on how to upgrade to v3 with success.

https://github.com/runatlantis/atlantis/pull/3515

I'm having issues now with upgrading to v4.

https://github.com/runatlantis/atlantis/pull/3525 https://github.com/runatlantis/atlantis/actions/runs/5263372208/jobs/9513456804?pr=3525

Since the Eq* functions are removed, what can I do to replace them?

undefined: EqString
undefined: EqInt
petergtz commented 1 year ago

Hi @nitrocode, thanks for opening this issue. You can replace both matchers (EqString and EqInt) with Eq. See also section https://github.com/petergtz/pegomock#argument-matchers.

But you're right, there's no migration manual for v4. I forgot this and will add it in the coming days.

nitrocode commented 11 months ago

Thank you!