Skip to content

Commit

Permalink
Update tsx snippet in README (#968)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jordan Pellizzari authored Oct 26, 2021
1 parent 3dffc20 commit c21522b
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,21 +67,27 @@ To set up a development environment for the CLI

### unit testing

We are using [Ginko](https://onsi.github.io/ginkgo/) for our unit tests. To exeucte the all the unit tests, run `make unit-tests`.
We are using [Ginko](https://onsi.github.io/ginkgo/) for our unit tests. To exeucte the all the unit tests, run `make unit-tests`.

To run a single test, you will need to set the KUBEBUILDER_ASSESTS environment variable to point to the directory containing our mock K8s objects.

To run a single test, you will need to set the KUBEBUILDER_ASSESTS environment variable to point to the directory containing our mock K8s objects.
```bash
export KUBEBUILDER_ASSETS=$(git rev-parse --show-toplevel)/tools/bin/envtest
go test github.com/weaveworks/weave-gitops/pkg/kube
```

or

```bash
export KUBEBUILDER_ASSETS=$(git rev-parse --show-toplevel)/tools/bin/envtest
cd pkg/kube
go test
```

#### Executing a subset of tests
Ginkgo allows you to run a subset of Describe/Context/It specs. See [Focused Specs](https://onsi.github.io/ginkgo/#focused-specs) for more information

Ginkgo allows you to run a subset of Describe/Context/It specs. See [Focused Specs](https://onsi.github.io/ginkgo/#focused-specs) for more information

### Setup golangci-lint in your editor

Link for golangci-lint editor integration: https://golangci-lint.run/usage/integrations/
Expand Down Expand Up @@ -135,7 +141,7 @@ To create a new styled React component (with typescript):
" );",
"}",
"",
"export default styled(${1:})``"
"export default styled(${1:}).attrs({ className: ${1:}.name })``"
],
"description": "Create a default-exported, styled React Component."
}
Expand Down

0 comments on commit c21522b

Please sign in to comment.