Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#15431 closed enhancement (implemented)

Control Event Mask Unit Tests & Compile-Time Checks

Reported by: teor Owned by:
Priority: Medium Milestone: Tor: 0.2.7.x-final
Component: Core Tor/Tor Version: Tor: 0.2.7
Severity: Keywords: tor-relay, SponsorS, 027-triaged-1-in
Cc: nickm Actual Points:
Parent ID: Points: small
Reviewer: Sponsor: SponsorR

Description (last modified by teor)

I've created some unit tests for the control event mask, based on #13805.

They check that setting control_testing_set_global_event_mask and testing control_event_is_interesting the control event mask works as expected.

I've also added a compile-time check that the number of events doesn't exceed the capacity of control_event_t.event_mask.

I just need the bug number to put the git commit together.

Child Tickets

Change History (8)

comment:1 Changed 4 years ago by teor

Description: modified (diff)

comment:2 Changed 4 years ago by teor

Summary: Control Event Mask Unit TestsControl Event Mask Unit Tests & Compile-Time Checks

It's on github:

Repository:
https://github.com/teor2345/tor.git
Branch:
ticket15431-event-mask-tests
Commits:

  • Unit tests for control_event_is_interesting
  • Compile-time checks that control_event_t.event_mask is big enough

comment:3 Changed 4 years ago by nickm

Milestone: Tor: 0.2.8.x-finalTor: 0.2.7.x-final
Status: newneeds_review

comment:4 Changed 4 years ago by rl1987

Looks good to me.

comment:5 Changed 4 years ago by nickm

Resolution: implemented
Status: needs_reviewclosed

merged; thanks!

comment:6 Changed 4 years ago by isabela

Keywords: SponsorS added
Points: small
Version: Tor: 0.2.6.5-rcTor: 0.2.7

comment:7 Changed 4 years ago by isabela

Keywords: 027-triaged-1-in added

comment:8 Changed 4 years ago by dgoulet

Keywords: SponsorR removed
Sponsor: SponsorR
Note: See TracTickets for help on using tickets.