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

Simplify configuration docs #608

Merged
merged 1 commit into from
Apr 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 10 additions & 13 deletions docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,11 @@ mockery will search upwards from your current-working-directory up to the root p
Parameter Descriptions
-----------------------

=== "non-`packages` config"
### non-`packages`

### non-`packages`
These are the configuration options available when using the legacy, non-`packages` configuration semantics.

These are the configuration options available when using the legacy, non-`packages` configuration semantics.


#### Config Variables
These are the configuration options when not using the [`packages`](/mockery/features/#packages-configuration) config
!!! info "non-`packages` config"

| name | description |
|------|-------------|
Expand All @@ -60,13 +56,11 @@ Parameter Descriptions
| `testonly` | Prepend every mock file with `_test.go`. This is useful in cases where you are generating mocks `inpackage` but don't want the mocks to be visible to code outside of tests. |
| `with-expecter` | Use `with-expecter: True` to generate `EXPECT()` methods for your mocks. This is the preferred way to setup your mocks. |

=== "`packages` config"
### [`packages` config](/mockery/features/#packages-configuration)

### [`packages` config](/mockery/features/#packages-configuration)
These are the config options when using the `packages` config option. Use of the `packages` config semantics puts mockery into a completely different code path. Config variables may have changed meanings or have been substracted entirely, compared to the non-`packages` config.

These are the config options when using the `packages` config option. Config variables may have changed meanings or have been substracted entirely, compared to the non-`packages` config.

#### Config Variables
!!! info "`packages` config"

| name | templated | default | description |
|------|-----------|---------|-------------|
Expand All @@ -88,7 +82,10 @@ Parameter Descriptions
| [`with-expecter`](/mockery/features/#expecter-structs) | :fontawesome-solid-x: | `#!yaml true` | Use `with-expecter: True` to generate `EXPECT()` methods for your mocks. This is the preferred way to setup your mocks. |
| [`replace-type`](/mockery/features/#replace-types) | :fontawesome-solid-x: | `#!yaml null` | Replaces aliases, packages and/or types during generation.|

#### Template variables
-------------

#### Template Variables


!!! note
Templated variables are only available when using the `packages` config feature.
Expand Down