+
Point of view
All features
class MOCK_TIMES_COUNTER
Summary
Direct parents
Inherit list: MOCK_TIMES
Insert list: COUNTER, EIFFELTEST_TOOLS
Class invariant
Overview
Creation features
{MOCK_EXPECTATION}
Features
{ANY}
{MOCK_EXPECTATION}
{MOCK_EXPECTATION}
{}
Action when an assert fails
{ANY}
Mock features
{ANY}
assert methods used by tests
{ANY}
timer features
{}
{}
{EIFFELTEST_TOOLS}
{}
{ANY}
{ANY}
out_in_tagged_out_memory
effective procedure
{ANY}
Append terse printable representation of current object in tagged_out_memory.
require
    • locked: tagged_out_locked
    • locked: tagged_out_locked
ensure
  • still_locked: tagged_out_locked
  • not_cleared: tagged_out_memory.count >= old tagged_out_memory.count
  • append_only: old tagged_out_memory.twin.is_equal(tagged_out_memory.substring(1, old tagged_out_memory.count))
can_call: BOOLEAN
effective function
call
effective procedure
require
  • can_call
all_called
effective procedure
all_done: BOOLEAN
effective function
set_item (i: INTEGER_32)
effective procedure
require
  • i >= 0
ensure
  • item = i
initial: INTEGER_32
writable attribute
{}
effective procedure
{ANY}
require
  • what_to_do /= Void
ensure
scenario: MOCK_SCENARIO
writable attribute
{ANY}
assert (test: BOOLEAN)
effective procedure
{ANY}
Check that test is actually True.
If test is True, nothing happens except that the assert_counter is incremented by one. When test is False, an error message is printed on std_output; a breakpoint allow you to find out what is going wrong (assuming you are using the -sedb debugger); and the program exits with a non-zero status.
Note: you may change that default behaviour by calling when_test_fails.
label_assert (label: ABSTRACT_STRING, test: BOOLEAN)
effective procedure
{ANY}
Check that test is actually True.
If test is True, nothing happens except that the assert_counter is incremented by one. When test is False, the label is printed on std_output; a breakpoint allow you to find out what is going wrong (assuming you are using the -sedb debugger); and the program exits with a non-zero status.
Note: you may change that default behaviour by calling when_test_fails.
require
  • not test implies label /= Void
message_assert (message_generator: FUNCTION[TUPLE, ABSTRACT_STRING], test: BOOLEAN)
effective procedure
{ANY}
Check that test is actually True.
If test is True, nothing happens except that the assert_counter is incremented by one. When test is False, the generated message is printed on std_output; a breakpoint allow you to find out what is going wrong (assuming you are using the -sedb debugger); and the program exits with a non-zero status.
Note: you may change that default behaviour by calling when_test_fails.
require
  • not test implies message_generator /= Void
start_timer: MICROSECOND_TIME
effective function
{}
stop_timer (start: MICROSECOND_TIME)
effective procedure
{}
timed (action: PROCEDURE[TUPLE])
effective procedure
{}
assert_counter: COUNTER
once function
{}
Unique once COUNTER used to count assert calls.
assertion_flag: STRING
effective function
{}
assertion_level: INTEGER_32
writable attribute
{}
assertion_level_none: INTEGER_32
is 0
constant attribute
{}
assertion_level_require: INTEGER_32
is 1
constant attribute
{}
assertion_level_ensure: INTEGER_32
is 2
constant attribute
{}
assertion_level_class_invariant: INTEGER_32
is 3
constant attribute
{}
assertion_level_loop_invariant: INTEGER_32
is 4
constant attribute
{}
assertion_level_check: INTEGER_32
is 5
constant attribute
{}
set_require: BOOLEAN
effective function
{}
set_loop_invariant: BOOLEAN
effective function
{}
set_check: BOOLEAN
effective function
{}
set_ensure: BOOLEAN
effective function
{}
set_class_invariant: BOOLEAN
effective function
{}
probe_assertion_level
effective procedure
require ensure
default_test_failed (id: INTEGER_32, lbl: ABSTRACT_STRING, gen: ABSTRACT_STRING, ass_flag: ABSTRACT_STRING)
effective procedure
{}
require
  • lbl /= Void
  • gen /= Void
  • ass_flag /= Void
counter_to_message: FUNCTION[TUPLE, ABSTRACT_STRING]
once function
{}
count_to_message: ABSTRACT_STRING
effective function
{}
label_to_message (label: ABSTRACT_STRING): ABSTRACT_STRING
effective function
{}
require
  • label /= Void
ensure
  • Result = label
increment
effective procedure
{ANY}
Increment the item of Current counter.
ensure
next
effective procedure
{ANY}
Increment the item of Current counter.
ensure
decrement
effective procedure
{ANY}
Decrement the item of Current counter.
ensure
previous
effective procedure
{ANY}
Decrement the item of Current counter.
ensure
reset
effective procedure
{ANY}
Reset the item of Current counter.
ensure
start
effective procedure
{ANY}
Reset the item of Current counter.
ensure
append_in (buffer: STRING)
effective procedure
{ANY}
Append the item of the Current counter in the buffer.
value: INTEGER_32
effective function
{ANY}
This feature is obsolete: Use `item' instead.
item: E_
writable attribute
{ANY}
clear
effective procedure
{ANY}
Reset item with the default value.