Skip to content

Commit

Permalink
[Docs] add mockgen instructions to quickstart and makefile helper (#733)
Browse files Browse the repository at this point in the history
#534

---------

Co-authored-by: Daniel Olshansky <[email protected]>
  • Loading branch information
wtfsayo and Olshansk authored Aug 13, 2024
1 parent fb72cba commit a0ebd63
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,17 @@ check_ignite_version:
exit 1 ; \
fi

.PHONY: check_mockgen
# Internal helper target- Check if mockgen is installed
check_mockgen:
{ \
if ( ! ( command -v mockgen >/dev/null )); then \
echo "Seems like you don't have `mockgen` installed. Please visit https://github.com/golang/mock#installation and follow the instructions to install `mockgen` before continuing"; \
exit 1; \
fi; \
}


.PHONY: check_act
# Internal helper target - check if `act` is installed
check_act:
Expand Down
10 changes: 10 additions & 0 deletions docusaurus/docs/develop/developer_guide/quickstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,16 @@ available commands. Looking inside the Makefile is a great way to learn how to u

### 1.3 Prepare your development environment

Run the following command to install `golang` dependencies:
```bash
make install_ci_deps
```

If you encounter issues related to `mockgen` not being found or failing, try running the following command to verify its installation:
```bash
make check_mockgen
```

Compile protobufs, generate mocks and verify that all tests are passing by running:

```bash
Expand Down

0 comments on commit a0ebd63

Please sign in to comment.