Skip to content

Commit

Permalink
Tweak tests
Browse files Browse the repository at this point in the history
  • Loading branch information
pronovic committed Mar 20, 2021
1 parent 6c018c3 commit 81bc638
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion tests/fixtures/test_writer/log.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<a name="id-2"></a><span class="tm">21:07:49</span> <span class="nk">&lt;unknown_lamer&gt;</span> <span><span>Yeah, let's do it</span></span>
<a name="id-3"></a><span class="tm">21:08:15</span> <span class="nk">&lt;pronovic&gt;</span> <span><span class="cmd">#link </span><span class="cmdline"><span><span>https://whatver/agenda.html</span></span></span></span>
<a name="id-4"></a><span class="tm">21:08:17</span> <span class="nk">&lt;pronovic&gt;</span> <span><span class="topic">#topic </span><span class="topicline"><span><span>Attendance</span></span></span></span>
<a name="id-5"></a><span class="tm">21:08:18</span> <span class="nk">&lt;pronovic&gt;</span> <span><span>if you are an hcoop member and present please write "#here $hcoop_username"</span></span>
<a name="id-5"></a><span class="tm">21:08:18</span> <span class="nk">&lt;pronovic&gt;</span> <span><span>If you are present please write "#here $hcoop_username"</span></span>
<a name="id-6"></a><span class="tm">21:08:19</span> <span class="nk">&lt;pronovic&gt;</span> <span><span class="cmd">#here </span><span class="cmdline"><span><span>Pronovic</span></span></span></span>
<a name="id-7"></a><span class="tm">21:08:20</span> <span class="nk">&lt;unknown_lamer&gt;</span> <span><span class="cmd">#here </span><span class="cmdline"><span><span>Clinton Alias</span></span></span></span>
<a name="id-8"></a><span class="tm">21:08:21</span> <span class="nk">&lt;keverets&gt;</span> <span><span class="cmd">#here </span><span class="cmdline"><span><span>keverets</span></span></span></span>
Expand Down
6 changes: 2 additions & 4 deletions tests/test_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,7 @@ def _meeting() -> Meeting:
# note that we track attendees manually since that's what would be done by the command interpreter
tracked = meeting.track_message(message=_message(4, "pronovic", "#topic Attendance", 125))
meeting.track_event(event_type=EventType.TOPIC, message=tracked, operand="Attendance")
tracked = meeting.track_message(
message=_message(5, "pronovic", 'if you are an hcoop member and present please write "#here $hcoop_username"', 126)
)
tracked = meeting.track_message(message=_message(5, "pronovic", 'If you are present please write "#here $hcoop_username"', 126))
tracked = meeting.track_message(message=_message(6, "pronovic", "#here Pronovic", 127)) # note: alias != nick
meeting.track_event(event_type=EventType.ATTENDEE, message=tracked, operand="Pronovic")
meeting.track_attendee(nick="pronovic", alias="Pronovic")
Expand Down Expand Up @@ -273,7 +271,7 @@ def test_write_meeting_wiring(self, derive_locations):
meeting = _meeting()
assert write_meeting(config, meeting) is locations
# print("\n" + _contents(log.path))
print("\n" + _contents(minutes.path))
# print("\n" + _contents(minutes.path))
derive_locations.assert_called_once_with(config, meeting)
assert _contents(log.path) == _contents(EXPECTED_LOG)
assert _contents(minutes.path) == _contents(EXPECTED_MINUTES)

0 comments on commit 81bc638

Please sign in to comment.