원클릭으로
test-patterns
Generate tests following project conventions with proper patterns for unit, integration, and e2e testing
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Generate tests following project conventions with proper patterns for unit, integration, and e2e testing
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Create Architecture Decision Records using the Michael Nygard template with context, decision, alternatives, and consequences
Generate or validate OpenAPI and AsyncAPI specs from code or requirements with consistent naming, errors, and pagination
Generate CHANGELOG.md from git history in Keep a Changelog format with Added, Changed, Deprecated, Removed, Fixed, and Security categories
Generate CI/CD pipeline config for detected platform with lint, test, build, and deploy stages
Scan dependencies for CVEs, outdated packages, license issues, and unused deps to produce a prioritized remediation list
Guide deployment processes including CI/CD pipeline creation, environment setup, and rollback procedures
| name | test-patterns |
| description | Generate tests following project conventions with proper patterns for unit, integration, and e2e testing |
| license | MIT |
| compatibility | opencode |
| metadata | {"audience":"developers","workflow":"general"} |
Use this skill when you need to write tests for new or existing code. This skill first analyzes existing tests to match the project's style.
Discover: Find existing tests to understand patterns
*.test.*, *.spec.*, __tests__/ directoriesAnalyze: Read the code under test
Generate: Write tests following discovered patterns
describe("ModuleName", () => {
// Setup
beforeEach(() => { /* ... */ })
describe("methodName", () => {
it("should return expected value for valid input", () => {
// Arrange
const input = createTestInput()
// Act
const result = methodName(input)
// Assert
expect(result).toEqual(expectedValue)
})
it("should throw for invalid input", () => {
expect(() => methodName(null)).toThrow(ExpectedError)
})
})
})
class TestModuleName:
@pytest.fixture
def setup(self):
return create_test_fixture()
def test_method_returns_expected_for_valid_input(self, setup):
result = method_name(setup)
assert result == expected_value
def test_method_raises_for_invalid_input(self):
with pytest.raises(ExpectedError):
method_name(None)
@DisplayName("ModuleName Tests")
class ModuleNameTest {
@BeforeEach
void setUp() { /* ... */ }
@Test
@DisplayName("should return expected value for valid input")
void methodName_validInput_returnsExpected() {
var result = moduleName.methodName(validInput);
assertEquals(expected, result);
}
@Test
@DisplayName("should throw for invalid input")
void methodName_invalidInput_throws() {
assertThrows(ExpectedException.class,
() -> moduleName.methodName(null));
}
}