Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,21 @@ Carefully read the issue and think hard about a plan to solve it before coding.
- Write additional tests if needed to capture important behaviors or edge cases.
- Ensure all tests pass before finalizing.

### 6.1 Acceptance Testing Requirements
When running acceptance tests (`make testacc`), ensure the following:


- **Environment Variables** - The following environment variables are required for acceptance tests:
- `ELASTICSEARCH_ENDPOINTS` (default: http://localhost:9200)
- `ELASTICSEARCH_USERNAME` (default: elastic)
- `ELASTICSEARCH_PASSWORD` (default: password)
- `KIBANA_ENDPOINT` (default: http://localhost:5601)
- `TF_ACC` (must be set to "1" to enable acceptance tests)
- **Ensure a valid environment if using `go test`** - Check if the required environment variables are set, if not use the defaults specified above.
- **Always finish with `make testacc`** - This will run all tests. Make sure all tests pass before considering a task complete.
- **Pre-set Environment Variables** - Default environment variables are configured in the Makefile. If these defaults are suitable for your testing environment, `make testacc` will work directly without additional setup
- **Docker Environment** - For isolated testing with guaranteed environment setup, use `make docker-testacc` which starts Elasticsearch and Kibana containers automatically

## 7. Final Verification
- Confirm the root cause is fixed.
- Review your solution for logic correctness and robustness.
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ docker-clean: ## Try to remove provisioned nodes and assigned network

.PHONY: docs-generate
docs-generate: tools ## Generate documentation for the provider
@ go tool github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs
@ go tool github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs generate --provider-name elasticstack
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This allows tfplugindocs to work when executed from a directory not named terraform-provider-elasticstack like you might have if you use Git worktrees... not that I'd do that sort of thing. Definitely wouldn't have multiple AI agents spinning away on different branches at once.



.PHONY: gen
Expand Down