mirror of
https://github.com/ivuorinen/gh-action-readme.git
synced 2026-02-08 19:47:15 +00:00
refactor: major codebase improvements and test framework overhaul
This commit represents a comprehensive refactoring of the codebase focused on improving code quality, testability, and maintainability. Key improvements: - Implement dependency injection and interface-based architecture - Add comprehensive test framework with fixtures and test suites - Fix all linting issues (errcheck, gosec, staticcheck, goconst, etc.) - Achieve full EditorConfig compliance across all files - Replace hardcoded test data with proper fixture files - Add configuration loader with hierarchical config support - Improve error handling with contextual information - Add progress indicators for better user feedback - Enhance Makefile with help system and improved editorconfig commands - Consolidate constants and remove deprecated code - Strengthen validation logic for GitHub Actions - Add focused consumer interfaces for better separation of concerns Testing improvements: - Add comprehensive integration tests - Implement test executor pattern for better test organization - Create extensive YAML fixture library for testing - Fix all failing tests and improve test coverage - Add validation test fixtures to avoid embedded YAML in Go files Build and tooling: - Update Makefile to show help by default - Fix editorconfig commands to use eclint properly - Add comprehensive help documentation to all make targets - Improve file selection patterns to avoid glob errors This refactoring maintains backward compatibility while significantly improving the internal architecture and developer experience.
This commit is contained in:
86
testdata/example-action/README.md
vendored
86
testdata/example-action/README.md
vendored
@@ -1,86 +0,0 @@
|
||||
# Example Action
|
||||
|
||||
  
|
||||
|
||||
> Test Action for gh-action-readme
|
||||
|
||||
## 🚀 Quick Start
|
||||
|
||||
```yaml
|
||||
name: My Workflow
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Example Action
|
||||
uses: ivuorinen/gh-action-readme/example-action@v1
|
||||
with:
|
||||
input1: "foo"
|
||||
input2: "value"
|
||||
```
|
||||
|
||||
|
||||
## 📥 Inputs
|
||||
|
||||
| Parameter | Description | Required | Default |
|
||||
|-----------|-------------|----------|---------|
|
||||
| `input1` | First input | ✅ | `foo` |
|
||||
| `input2` | Second input | ❌ | - |
|
||||
|
||||
|
||||
|
||||
## 📤 Outputs
|
||||
|
||||
| Parameter | Description |
|
||||
|-----------|-------------|
|
||||
| `result` | Result output |
|
||||
|
||||
|
||||
## 💡 Examples
|
||||
|
||||
<details>
|
||||
<summary>Basic Usage</summary>
|
||||
|
||||
```yaml
|
||||
- name: Example Action
|
||||
uses: ivuorinen/gh-action-readme/example-action@v1
|
||||
with:
|
||||
input1: "foo"
|
||||
input2: "example-value"
|
||||
```
|
||||
</details>
|
||||
|
||||
<details>
|
||||
<summary>Advanced Configuration</summary>
|
||||
|
||||
```yaml
|
||||
- name: Example Action with custom settings
|
||||
uses: ivuorinen/gh-action-readme/example-action@v1
|
||||
with:
|
||||
input1: "foo"
|
||||
input2: "custom-value"
|
||||
```
|
||||
</details>
|
||||
|
||||
|
||||
|
||||
## 🔧 Development
|
||||
|
||||
See the [action.yml](./action.yml) for the complete action specification.
|
||||
|
||||
## 📄 License
|
||||
|
||||
This action is distributed under the MIT License. See [LICENSE](LICENSE) for more information.
|
||||
|
||||
## 🤝 Contributing
|
||||
|
||||
Contributions are welcome! Please feel free to submit a Pull Request.
|
||||
|
||||
---
|
||||
|
||||
<div align="center">
|
||||
<sub>🚀 Generated with <a href="https://github.com/ivuorinen/gh-action-readme">gh-action-readme</a></sub>
|
||||
</div>
|
||||
Reference in New Issue
Block a user