lib/pry-test/test_wrapper.rb
# A basic assert method to be used within tests.
#
# @param [Object] value The value to assert.
#
# @example
#   class SimpleTest < PryTest::Test
#     test "common sense" do
#       assert 1 > 0
#     end
#   end
A basic assert method to be used within tests.
A basic assert method to be used within tests .
def assert(value)
      info = assert_info(value, caller_locations(1..1).first)
      asserts << info.merge(value: value)
      unless value
        Pry.start unless @options[:disable_pry]
        PryTest::Runner.terminate if @options[:fail_fast]
      end
      value
    end
def assert ( value ) info = assert_info ( value , caller_locations ( 1 .. 1 ) . first ) asserts << info . merge ( value : value ) unless value Pry . start unless @options [ :disable_pry ] PryTest :: Runner . terminate if @options [ :fail_fast ] end value end
A basic assert method to be used within tests.
A basic assert method to be used within tests .
# TODO: I don't really like the coupling to the runner here
value
value The value to assert.
value The value to assert .
example
class SimpleTest < PryTest::Test test "common sense" do assert 1 > 0 end end
class SimpleTest < PryTest :: Test test " common sense " do assert 1 > 0 end end