[tor-bugs] #8949 [Tor]: Add a way to do mocking for Tor unit tests (was: Add a robust way to do mocking for Tor unit tests)

Tor Bug Tracker & Wiki blackhole at torproject.org
Wed Jul 10 19:25:53 UTC 2013


#8949: Add a way to do mocking for Tor unit tests
--------------------------------+-------------------------------------------
 Reporter:  nickm               |          Owner:                    
     Type:  enhancement         |         Status:  needs_review      
 Priority:  major               |      Milestone:  Tor: 0.2.5.x-final
Component:  Tor                 |        Version:                    
 Keywords:  tor-client testing  |         Parent:                    
   Points:                      |   Actualpoints:                    
--------------------------------+-------------------------------------------
Changes (by nickm):

  * status:  new => needs_review


Comment:

 Please review branch "fancy_test_tricks".  It's got a very small amount of
 mocking support, and a great deal of infrastructure to make the mocking
 support usable.

 The mocking methodology here is "the simplest thing that could work" --
 it's one of the ones that festoon the code with macro salad, and uglifies
 the declarations of functions that are going to get mocked.  It has the
 advantage of being portable, robust, and comprehensible.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/8949#comment:1>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list