Class: Testem

Inherits:
MiniTest::Spec
  • Object
show all
Defined in:
lib/testem.rb

Overview

Aliases often used MiniTest::Spec hooks to Rails-like hooks.

  • context is aliased to describe

  • it is aliased to it

  • setup is aliased to before

  • teardown is aliased to after

Example

require 'minitest/autorun'
require 'testem'

class MyTest < Testem
  setup do
    # before
  end

  teardown do
    # after
  end

  context "some context" do
    test "me" do
      # assertions
    end
  end
end

Constant Summary collapse

VERSION =
"0.1.0"