ex_unit_fixtures alternatives and similar packages
Based on the "Testing" category.
Alternatively, view ex_unit_fixtures alternatives based on common mentions on social networks and blogs.
-
hound
Elixir library for writing integration tests and browser automation -
proper
PropEr: a QuickCheck-inspired property-based testing tool for Erlang -
bypass
Bypass provides a quick way to create a custom plug that can be put in place instead of an actual HTTP server to return prebaked responses to client requests. -
ExVCR
HTTP request/response recording library for elixir, inspired by VCR. -
StreamData
Data generation and property-based testing for Elixir. ๐ฎ -
propcheck
Property based Testing for Elixir (based upon PropEr) -
excheck
Property-based testing library for Elixir (QuickCheck style). -
amrita
A polite, well mannered and thoroughly upstanding testing framework for Elixir -
ponos
ponos is a simple yet powerful load generator written in erlang -
power_assert
Power Assert in Elixir. Shows evaluation results each expression. -
FakerElixir
[unmaintained] FakerElixir generates fake data for you. -
shouldi
Elixir testing libraries with nested contexts, superior readability, and ease of use -
katt
KATT (Klarna API Testing Tool) is an HTTP-based API testing tool for Erlang. -
FakeServer
FakeServer integrates with ExUnit to make external APIs testing simpler -
Stubr
Stubr is a set of functions helping people to create stubs and spies in Elixir. -
Mockery
Simple mocking library for asynchronous testing in Elixir. -
mecks_unit
A simple Elixir package to elegantly mock module functions within (asynchronous) ExUnit tests using Erlang's :meck library -
mix_test_interactive
Interactive watch mode for Elixir's mix test. https://hexdocs.pm/mix_test_interactive/ -
Walkman
Isolate tests from the real world, inspired by Ruby's VCR. -
test_selector
Elixir library to help selecting the right elements in your tests. -
factory_girl_elixir
Minimal implementation of Ruby's factory_girl in Elixir. -
toxiproxy_ex
ToxiproxyEx is an Elixir API client for the resilience testing tool Toxiproxy. -
ex_parameterized
This library support parameterized test with test_with_params macro. -
mix_erlang_tasks
Common tasks for Erlang projects that use Mix -
cobertura_cover
Output test coverage information in Cobertura-compatible format -
hypermock
HTTP request stubbing and expectation Elixir library -
ElixirMock
Creates clean, concurrent, inspectable mocks from elixir modules -
apocryphal
Swagger based document driven development for ExUnit
Learn Elixir in as little as 12 Weeks
Do you think we are missing an alternative of ex_unit_fixtures or a related project?
README
ExUnitFixtures
A library for defining modular dependencies (fixtures) for ExUnit tests.
What are Fixtures?
Fixtures in ExUnitFixtures are just functions that are run before a test.
They can be used to setup the tests environment somehow, or provide the test
with some data that it requires. Similar in purpose to setup
& setup_all
but
more powerful:
- Tests explicitly list what fixtures they require, ensuring that no un-neccesary setup work is done.
- Fixtures may be shared across many tests in a project.
- Fixtures may depend on or override other fixtures, allowing core fixtures to be used & customised as each subsystem or test module requires.
Installation
- Add ex_unit_fixtures to your list of dependencies in
mix.exs
:
def deps do
[{:ex_unit_fixtures, "~> 0.3.1", only: [:test]}]
end
Documentation
The documentation can be found on hexdocs.pm: http://hexdocs.pm/ex_unit_fixtures/ExUnitFixtures.html
Example
Say some of your tests required a model named my_model
. You should define a
fixture fixture using deffixture
, then tag your test to say it requires this
fixture:
defmodule MyTests do
use ExUnitFixtures
use ExUnit.Case
ExUnit.Case.register_attribute __MODULE__, :fixtures
deffixture my_model do
# Create a model somehow...
%{test: 1}
end
@fixtures: :my_model
test "that we have some fixtures", context do
assert context.my_model.test == 1
end
end
More details can be found in the documentation.