elixir-testing-expert

Standardizes Elixir test organization with ExUnit, ExMachina, and Mox patterns.

2|1|Updated Feb 8, 2021
One-click install
npx skills add https://github.com/jstoobz/dotfiles --skill elixir-testing-expert
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: elixir-testing-expert
Source: https://github.com/jstoobz/dotfiles/tree/main/claude/skills/elixir/elixir-testing-expert
Command: npx skills add https://github.com/jstoobz/dotfiles --skill elixir-testing-expert

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill standardizes Elixir testing practices, providing a clear blueprint for organizing tests, creating consistent test data, and applying mocks to ensure deterministic outcomes.

Core Features & Use Cases

  • ExUnit-based test organization with shared setup patterns (DataCase, async handling, and integration test approaches)
  • ExMachina factories for structured and reusable test data
  • Mox for mock-driven testing across unit and integration layers
  • Property-based testing integration with ExUnit and StreamData for data-driven validation

Quick Start

Use the Elixir Testing Expert to wire up your testing strategy: adopt ExUnit patterns, define factories, configure Mox, and apply the provided examples to structure your test suite.

Frequently Asked Questions about elixir-testing-expert

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I organize ExUnit tests with shared setup patterns in Elixir?

Structure ExUnit tests by adopting DataCase for database setup, configuring async handling for concurrent execution, and applying shared integration test approaches to maintain deterministic outcomes.

What is the best way to generate consistent test data in Elixir?

The best way to generate consistent test data in Elixir is using ExMachina factories, which provide structured and reusable data generation patterns for unit, integration, and property-based testing scenarios.

How does Mox work for mock-driven testing in Elixir?

Mox works for mock-driven testing in Elixir by enforcing explicit mock definitions, allowing you to configure mock-driven workflows across unit and integration layers to ensure deterministic test outcomes without hitting real external dependencies.

Can I use StreamData for property-based testing with ExUnit?

Yes, you can use StreamData for property-based testing with ExUnit to perform data-driven validation, integrating seamlessly with your existing test structure to generate random test cases and validate system properties.

Do I need ExMachina and Mox to set up an Elixir testing strategy?

Yes, adopting a standardized Elixir testing strategy enforces dependencies on ExMachina for factory data generation and Mox for mock-driven workflows, along with ExUnit, to provide a clear blueprint for test organization and deterministic outcomes.