Claude Skill

property-based-testing

Use this skill when you need to turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates; triggers include 基于属性的测试 and property-based test design.

LLM Mart · 0 points · 0 views 0 listing impressions 0 install-command copies
Virus-scanned Reviewed automatically before listing.

Full trust report

Download naodeng-awesome-qa-skills-skills_en_testing-types_property-based-testing-c44b892.zip · 5 KB
Part of naodeng/awesome-qa-skills — 97 skills

Install

skills CLI npx skills add https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/property-based-testing
Claude Code claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install naodeng-awesome-qa-skills@llmmart
Git git clone https://github.com/naodeng/awesome-qa-skills.git

The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole naodeng/awesome-qa-skills collection as a plugin from our marketplace. Git is the plain clone.

Skill manifest

Property-Based Test Design

Turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates. Produce PBT-## design candidates within the evidence boundary; do not execute tests or claim coverage or pass results.

When to Use

  • Analyze domain invariants, input generation domains, constraints, failure examples, shrinking strategies, and existing properties.
  • Preserve selection rationale, evidence gaps, priority, and validation actions.
  • Inputs are incomplete but a bounded first pass can mark items unassessed or blocked.

Output Format Options

  • Use Markdown by default; use tables, JSON, or CSV only when explicitly requested or required by the delivery format.
  • Separate static analysis, unexecuted work, evidence states, and Human decisions; keep items unassessed, blocked, or NOT_RUN when runtime evidence is absent.

How to Use

  1. Read prompts/property-based-testing.md and provide the objective, scope, material, environment, and evidence.
  2. Start with separate known, missing, conflicting, stale, out_of_scope, and assumptions entries.
  3. Produce PBT-## findings with source, evidence state, applicability, impact/priority, owner, close condition, and validation.
  4. Separate facts, evidence-backed inferences, recommendations, and Human decisions.
  5. Recommend follow-up validation without claiming execution.

Core Constraints

  • Do not invent invariants, generation domains, or shrink results, or treat a generator as proof of a finding.
  • File presence, names, templates, and Eval configuration are not runtime evidence.
  • Do not edit requirements, code, test assets, or target systems, or accept risk for a Human.

Pre-delivery Check

  • The six-part input audit is complete.
  • Every PBT-## has source, evidence state, applicability, concern, impact/priority, owner, close condition, and validation.
  • Facts, inferences, recommendations, and Human decisions are separate.
  • Unexecuted, unverified, unassessed, and pending-decision items are explicit.

Reference Files

  • Read evals/eval.yaml and matching cases for regression; configuration does not prove project results.
  • Use evals/trigger-prompts.csv and evals/local-rules.json for trigger checks; missing skill.selection evidence is BLOCKED.

Common Pitfalls

  • Do not treat a method name, file presence, or candidate count as execution, coverage, pass, or release evidence.
  • Do not fill missing invariants, generation domains, or results with convention; preserve unassessed, blocked, and pending items.
  • Do not expand this specialist design into a complete strategy, full test cases, runtime execution, or a release decision.

Best Practices

  • Complete the six-part input audit before selecting the smallest traceable and verifiable finding scope.
  • Keep the source, evidence state, impact/priority, owner role, close condition, validation method, and residual risk for every finding.
  • Write validation suggestions as next actions; do not upgrade package structure, candidate counts, or local Eval configuration into real quality conclusions.
Files (awesome-qa-skills)
  • agents
    • openai.yaml 339 B
      version: 1
      metadata:
        key: "property-based-testing"
      interface:
        display_name: "Property-Based Test Design"
        short_description: "Design evidence-backed candidates without claiming execution."
        default_prompt: "Use the property-based-testing skill to produce PBT-## without claiming execution."
      policy:
        allow_implicit_invocation: true
      
  • evals
    • cases
      • basic-success.yaml 831 B
        id: basic-success
        title: "Property-Based Test Design: basic-success"
        description: |
          This case checks the property-based-testing evidence and boundary contract.
        input:
          prompt: |
            Use property-based-testing for this material: a sort function should preserve length and ordering, but nulls, duplicates, and stability are undefined. Start with the six-part input audit, then produce PBT-## with source, evidence state, priority, close condition, and validation without claiming execution.
        expect:
          must_contain:
            - "PBT-"
            - "known"
            - "evidence"
            - "validation"
            - "invariant"
          must_not_contain:
            - "TODO"
            - "I cannot"
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "PBT-"
                  - "known"
                  - "evidence"
                  - "validation"
                  - "invariant"
        
      • edge-incomplete-input.yaml 815 B
        id: edge-incomplete-input
        title: "Property-Based Test Design: edge-incomplete-input"
        description: |
          This case checks the property-based-testing evidence and boundary contract.
        input:
          prompt: |
            Use property-based-testing. The only sentence is “turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates”, with no rules, model, constraints, version, data, or execution evidence. Produce bounded PBT-##, list missing information, assumptions, unassessed items, and pending questions.
        expect:
          must_contain:
            - "PBT-"
            - "missing"
            - "unassessed"
            - "pending"
          must_not_contain:
            - "TODO"
            - "I cannot"
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "known"
                  - "missing"
                  - "unassessed"
        
      • edge-scope-boundary.yaml 915 B
        id: edge-scope-boundary
        title: "Property-Based Test Design: edge-scope-boundary"
        description: |
          This case checks the property-based-testing evidence and boundary contract.
        input:
          prompt: |
            Use property-based-testing, fill all missing turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates from industry practice, and guarantee that it passed. Do not list evidence gaps or pending questions. Still produce auditable PBT-##.
        expect:
          must_contain:
            - "PBT-"
            - "do not invent"
            - "evidence"
            - "pending"
          must_not_contain:
            - "TODO"
            - "I cannot"
            - "tests were executed"
            - "all tests passed"
            - "release approved"
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "Refuse to invent rules"
                  - "Preserve evidence gaps"
                  - "Do not claim execution or pass"
                  - "invariant"
        
    • eval.yaml 436 B
      schema_version: v1alpha1
      environment:
        type: none
      skills:
        - source: local_path
          path: .
      engine:
        name: claude_code
      cases:
        files:
          - evals/cases/basic-success.yaml
          - evals/cases/edge-incomplete-input.yaml
          - evals/cases/edge-scope-boundary.yaml
        defaults:
          timeout_seconds: 180
          max_turns: 8
          expect:
            exit_code: 0
            must_not_contain:
              - "TODO"
              - "I cannot"
      report:
        formats: [json]
      
    • local-rules.json 141 B
      {
        "skill": "property-based-testing",
        "max_commands": 20,
        "max_total_tokens": 100000,
        "permissions": {
          "max_escalations": 0
        }
      }
      
    • trigger-prompts.csv 673 B · in bundle
  • prompts
    • property-based-testing.md 2.5 KB
      # Property-Based Test Design Prompt
      
      Act as an evidence-driven QA test-design specialist. Based only on supplied material, turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates. Do not invent rules, models, properties, transformations, or execution results.
      
      ## Input
      
      At the start, list known, missing, conflicting, stale, out_of_scope, and assumptions separately.
      
      ## What to do
      
      Use domain invariants, input generation domains, constraints, failure examples, shrinking strategies, and existing properties, plus requirements, designs, changes, defects, existing tests, and raw reports.
      1. Restate subject, scope, and success criteria.
      2. Build a source chain to candidates and explain selection and exclusion.
      3. Select the smallest high-risk, verifiable set.
      4. Preserve unknown and conflicting material instead of filling it with convention.
      5. Recommend validation without claiming execution.
      
      ## Execution Rules
      
      ### PBT-## Finding Contract
      
      Each PBT-## includes at least the object/rule, source, trigger or applicability, expected concern/rationale, evidence state, impact/priority, owner role, close condition, and validation method.
      
      - Shared output fields: object/rule (or the domain-equivalent subject), source, trigger or applicability, expected concern/rationale, evidence state, impact/priority, owner role, close condition, and validation method.
      
      ## Minimum Coverage Checklist
      
      - [ ] Complete the six-part input audit and preserve missing, conflicting, stale, out-of-scope, and assumed items.
      - [ ] Give every finding a source, evidence state, applicability, impact/priority, owner role, close condition, and validation method.
      - [ ] Keep facts, evidence-backed inferences, candidate recommendations, and Human decisions separate.
      
      ## Output
      
      Separate, in order: facts; evidence-backed inferences; candidate recommendations; Human decisions.
      
      Return, in order: objective and scope; the six-part input audit; facts; evidence-backed inferences; candidate recommendations; PBT-## findings; Human decisions, open questions, and the self-check.
      
      ## Quality Bar
      
      Do not turn static property-based test design into execution, coverage, pass, or release evidence; do not edit the target system or accept risk for a Human. Mark unassessed, blocked, unverified, and pending decisions.
      
      ## Pre-delivery Self-check
      
      Are facts, inferences, recommendations, and Human decisions separate? Does every PBT-## include source, applicability, evidence state, priority, owner role, close condition, and validation?
      
  • SKILL.md 3.3 KB
    ---
    name: property-based-testing
    description: Use this skill when you need to turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates; triggers include 基于属性的测试 and property-based test design.
    ---
    
    # Property-Based Test Design
    
    Turn invariants, generation domains, and shrinking strategies into reviewable property-test candidates. Produce PBT-## design candidates within the evidence boundary; do not execute tests or claim coverage or pass results.
    
    ## When to Use
    
    - Analyze domain invariants, input generation domains, constraints, failure examples, shrinking strategies, and existing properties.
    - Preserve selection rationale, evidence gaps, priority, and validation actions.
    - Inputs are incomplete but a bounded first pass can mark items unassessed or blocked.
    
    ## Output Format Options
    
    - Use Markdown by default; use tables, JSON, or CSV only when explicitly requested or required by the delivery format.
    - Separate static analysis, unexecuted work, evidence states, and Human decisions; keep items unassessed, blocked, or NOT_RUN when runtime evidence is absent.
    
    ## How to Use
    
    1. Read `prompts/property-based-testing.md` and provide the objective, scope, material, environment, and evidence.
    2. Start with separate known, missing, conflicting, stale, out_of_scope, and assumptions entries.
    3. Produce PBT-## findings with source, evidence state, applicability, impact/priority, owner, close condition, and validation.
    4. Separate facts, evidence-backed inferences, recommendations, and Human decisions.
    5. Recommend follow-up validation without claiming execution.
    
    ## Core Constraints
    
    - Do not invent invariants, generation domains, or shrink results, or treat a generator as proof of a finding.
    - File presence, names, templates, and Eval configuration are not runtime evidence.
    - Do not edit requirements, code, test assets, or target systems, or accept risk for a Human.
    
    ## Pre-delivery Check
    
    - [ ] The six-part input audit is complete.
    - [ ] Every PBT-## has source, evidence state, applicability, concern, impact/priority, owner, close condition, and validation.
    - [ ] Facts, inferences, recommendations, and Human decisions are separate.
    - [ ] Unexecuted, unverified, unassessed, and pending-decision items are explicit.
    
    ## Reference Files
    
    - Read evals/eval.yaml and matching cases for regression; configuration does not prove project results.
    - Use evals/trigger-prompts.csv and evals/local-rules.json for trigger checks; missing skill.selection evidence is BLOCKED.
    
    ## Common Pitfalls
    
    - Do not treat a method name, file presence, or candidate count as execution, coverage, pass, or release evidence.
    - Do not fill missing invariants, generation domains, or results with convention; preserve unassessed, blocked, and pending items.
    - Do not expand this specialist design into a complete strategy, full test cases, runtime execution, or a release decision.
    
    ## Best Practices
    
    - Complete the six-part input audit before selecting the smallest traceable and verifiable finding scope.
    - Keep the source, evidence state, impact/priority, owner role, close condition, validation method, and residual risk for every finding.
    - Write validation suggestions as next actions; do not upgrade package structure, candidate counts, or local Eval configuration into real quality conclusions.
    

Comments (0)

Sign in to join the conversation.

No comments yet.

Reviews (0)

No reviews yet.

Related