Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: uber-go/mock
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.3.0
Choose a base ref
...
head repository: uber-go/mock
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v0.4.0
Choose a head ref
  • 18 commits
  • 66 files changed
  • 14 contributors

Commits on Sep 18, 2023

  1. back to development (#92)

    sywhang authored Sep 18, 2023
    Configuration menu
    Copy the full SHA
    c8f6e38 View commit details
    Browse the repository at this point in the history
  2. add extract-changelog (#89)

    This adds a tool for extracting changelog from the CHANGELOG.md file to
    ease up release notes creation.
    sywhang authored Sep 18, 2023
    Configuration menu
    Copy the full SHA
    851bb6a View commit details
    Browse the repository at this point in the history
  3. goreleaser config - fix owner (#87)

    binary uploads are failing because we moved this repo from the `uber`
    GitHub org to `uber-go` GitHub org, so uploads are getting 307 response.
    sywhang authored Sep 18, 2023
    Configuration menu
    Copy the full SHA
    3377b02 View commit details
    Browse the repository at this point in the history

Commits on Sep 19, 2023

  1. Configuration menu
    Copy the full SHA
    fcaca4a View commit details
    Browse the repository at this point in the history

Commits on Sep 25, 2023

  1. proposal: ignore interfaces that contains type constraints (#93)

    This is a proposal PR to generate mocks without error for following
    cases:
    ```go
    type Water[R any, C UnsignedInteger] interface {
    	Fish(R) []C
    }
    
    type UnsignedInteger interface {
    	~uint | ~uint32 | ~uint64
    }
    ```
    
    Go `types` package seems to wrap interfaces that contain type
    constraints by checking a type set literal of the form `~T` and `A|B`.
    https://github.com/golang/go/blob/master/src/go/types/decl.go#L668
    
    So gomock can just ignore that pattern to generate mocks safely without
    `don't know how to mock method of type` errors. I think this can be a
    better solution for custom type constraints than [`-exclude`
    flag](#72).
    
    ---------
    
    Co-authored-by: Jacob Oaks <jacoboaks.8@gmail.com>
    hoonmin and JacobOaks authored Sep 25, 2023
    Configuration menu
    Copy the full SHA
    7842e1d View commit details
    Browse the repository at this point in the history

Commits on Oct 11, 2023

  1. Remove CONTRIBUTORS file (#107)

    While Uber has forked mock the CONTRIBUTRORS file still reflects
    Google's contents. Delete the file for now to prevent confusion.
    r-hang authored Oct 11, 2023
    Configuration menu
    Copy the full SHA
    ba1343d View commit details
    Browse the repository at this point in the history
  2. Add tip for signing Uber's CLA (#108)

    Now that we've removed the old CONTRIBUTORS file, update the
    CONTRIBUTING.md with a tip for signing Uber's CLA.
    
    This follows the CONTRIBUTING.md tip for Fx.
    ref: https://github.com/uber-go/fx/blob/master/CONTRIBUTING.md
    r-hang authored Oct 11, 2023
    Configuration menu
    Copy the full SHA
    5536487 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    bdd3140 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    892b665 View commit details
    Browse the repository at this point in the history

Commits on Oct 17, 2023

  1. Fix 111: Package comments are now split correctly from the rest of th…

    …e comments (#112)
    
    This allows package comments to be generated following the rules here:
    https://staticcheck.io/docs/checks#ST1000
    
    **Before:**
    ```go
    //	mockgen -destination demo/mock.go -package demo . Demoer
    //
    // Package demo is a generated GoMock package.
    package demo
    ```
    
    **After:**
    ```go
    //	mockgen -destination demo/mock.go -package demo . Demoer
    //
    
    // Package demo is a generated GoMock package.
    package demo
    ```
    dlsniper authored Oct 17, 2023
    Configuration menu
    Copy the full SHA
    b233940 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2023

  1. feat: add Regex() matcher (#114)

    Add a matcher for matching against regular expressions
    merrett010 authored Oct 30, 2023
    Configuration menu
    Copy the full SHA
    94a7ac3 View commit details
    Browse the repository at this point in the history

Commits on Nov 9, 2023

  1. Use path.Join for expected package paths (#121)

    To fix unit test on windows and address #120
    craig65535 authored Nov 9, 2023
    Configuration menu
    Copy the full SHA
    7fb6390 View commit details
    Browse the repository at this point in the history

Commits on Nov 17, 2023

  1. Update model.go (#115)

    fix misspell
    chemidy authored Nov 17, 2023
    Configuration menu
    Copy the full SHA
    857e269 View commit details
    Browse the repository at this point in the history
  2. MockGen header comment: trim .exe suffix on Windows (#119)

    To address #118
    
    ---------
    
    Co-authored-by: Marten Seemann <martenseemann@gmail.com>
    craig65535 and marten-seemann authored Nov 17, 2023
    Configuration menu
    Copy the full SHA
    5b48f95 View commit details
    Browse the repository at this point in the history
  3. added a description of the exclude_interfaces flag to the README (#123)

    I forgot to do this when I created the last PR
    #72
    tulzke authored Nov 17, 2023
    Configuration menu
    Copy the full SHA
    7bf3d91 View commit details
    Browse the repository at this point in the history

Commits on Dec 19, 2023

  1. Fixed -mockNames not propagating to Recorder and ReturnCall types (#127)

    When you are trying to mock multiple interfaces with the same name and
    similar methods (for example user.Service Create, post.Service Create,
    etc..) there is collision in Recorder and ReturnCall types, the
    -mockNames parameter only changes the main interface name, with the
    changes proposed in this PR the correct mockName will be applied to the
    Recorder and ReturnCall types.
    
    Addresses #117
    UnAfraid authored Dec 19, 2023
    Configuration menu
    Copy the full SHA
    6dd8fe5 View commit details
    Browse the repository at this point in the history

Commits on Dec 20, 2023

  1. mockgen: Sanitize the "any" package name (#132)

    When a package name is "any" mockgen will use that as a package name in
    the generated code which causes issues due to colliding with Go's "any"
    type. Update the sanitization logic to prevent this collision.
    r-hang authored Dec 20, 2023
    Configuration menu
    Copy the full SHA
    37f6db3 View commit details
    Browse the repository at this point in the history
  2. Release v0.4.0 (#131)

    r-hang authored Dec 20, 2023
    Configuration menu
    Copy the full SHA
    74a29c6 View commit details
    Browse the repository at this point in the history
Loading