Skip to content

Conversation

@mokagio
Copy link
Contributor

@mokagio mokagio commented Jun 6, 2023

This builds on top of the work done by @HelioMesquita in #83. Many thanks! πŸ™‡β€β™‚οΈ

@mokagio mokagio marked this pull request as ready for review June 6, 2023 07:02
mokagio added 4 commits June 6, 2023 17:03
The assertions are self explanatory and this makes the code cleaner
while also removing the chance that the error messages will be out of
sync with the expectation contents.
@mokagio mokagio force-pushed the mokagio/remove-video-force-unwrapping branch from 657e2cd to a704373 Compare June 6, 2023 07:03
@mokagio mokagio requested a review from crazytonyli June 6, 2023 07:03
)
parselyTracker.track.event(event: event)
os_log("Sent vheartbeat for video %s", log: OSLog.tracker, type:.debug, data.key)
curVideo._heartbeatsSent += 1
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This mutation is why we need curVideo to be a var.

Comment on lines +184 to +185
// ...and verify that no crash has occurred by performing a simple assertion on the tracker state
expect(self.parselyTestTracker.eventQueue.list).to(beEmpty())
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't write it in the comment (can add it if you think it would be useful) but of course if there's a crash this code won't run. The assertion is there just so that we can have something in the test.

"A call to trackPause should not remove an accumulator from videoManager.accumulators")
let videoManager = VideoManager(trackerInstance: parselyTestTracker)

videoManager.trackPlay(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line doesn't have the right indentation. Move one more level to the right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

πŸ€¦β€β™‚οΈ there's something clashing between my VS Code and .vimrc and it's breaking formatting 😞

@mokagio mokagio requested a review from crazytonyli June 8, 2023 10:59
Copy link
Contributor

@crazytonyli crazytonyli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@mokagio mokagio merged commit 8f17bb1 into master Jun 13, 2023
@mokagio mokagio deleted the mokagio/remove-video-force-unwrapping branch June 13, 2023 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants