[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master d45aeac 3/3: Remove tests that have been made
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master d45aeac 3/3: Remove tests that have been made redundant |
Date: |
Mon, 27 Feb 2017 20:28:51 -0500 (EST) |
branch: master
commit d45aeac5054f6c175d7a1dfc6a045df02895bb2f
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Remove tests that have been made redundant
InputSequenceEntry no longer needs to assert InputSequence's
invariants: InputSequence now asserts them itself on the last line
of every ctor.
nonempty: ensured by assert_sane_and_ordered_partition()
begin duration 0: ditto
end mode "maturity": "
contiguous, noncrossing: "
not insane: ditto, via assert_not_insane_or_disordered()
---
input_sequence_entry.cpp | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/input_sequence_entry.cpp b/input_sequence_entry.cpp
index f9684f4..c462b75 100644
--- a/input_sequence_entry.cpp
+++ b/input_sequence_entry.cpp
@@ -428,20 +428,9 @@ void InputSequenceEditor::sequence(InputSequence const& s)
std::vector<ValueInterval> const& intervals = s.intervals();
int const num_intervals = intervals.size();
- // Reaffirm InputSequence invariants that are relied upon here:
- LMI_ASSERT(!intervals.empty());
- LMI_ASSERT(0 == intervals.front().begin_duration);
- LMI_ASSERT(e_maturity == intervals.back().end_mode);
-
- for(int i = 1; i < num_intervals; ++i)
- {
- LMI_ASSERT(intervals[i].begin_duration == intervals[i -
1].end_duration);
- }
-
for(int i = 0; i < num_intervals; ++i)
{
ValueInterval const& data = intervals[i];
- LMI_ASSERT(!data.insane);
add_row();