[tor-bugs] #5493 [Stem]: run_tests.py fails on Windows

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Thu Apr 5 22:55:57 UTC 2012


#5493: run_tests.py fails on Windows
----------------------+-----------------------------------------------------
 Reporter:  reganeet  |          Owner:  atagar           
     Type:  defect    |         Status:  needs_information
 Priority:  normal    |      Milestone:                   
Component:  Stem      |        Version:                   
 Keywords:            |         Parent:                   
   Points:            |   Actualpoints:                   
----------------------+-----------------------------------------------------

Comment(by reganeet):

 It works. It is caused by file extension ".exe" in windows, so
 stem.util.system.is_available() cannot find "tor" even if the path to it
 is contained in $PATH. I've fixed this bug and pushed to my repo.

 Running "./run_tests.py --unit --integ --no-color" produces several
 failure in unit tests, and integration tests does not work at all.

 Failures in unit tests are caused by two errors. One is "AttributeError:
 'module' object has no attribute 'uname'", which is expected since those
 functions using os.uname() are not designed for windows. Another is in
 test_expend_path: "AssertionError: '/tmp' != '/tmp\\'", which seems to be
 caused by the different of paths in *nix systems and windows.

 I have no idea why integ tests fail. Here is the log:

 Setting up a test instance...
   making test directory (F:\Dropbox\tor\stem\test/data)... skipped
   configuring logger (F:\Dropbox\tor\stem\test/data/log)... Shutting down
 tor... done
 Shutting down tor... done
 TESTING FAILED (0.1 seconds)
   [UNIT TEST] test_expand_path (test.unit.util.system.TestSystem) ... FAIL
   [UNIT TEST] test_get_bsd_jail_id (test.unit.util.system.TestSystem) ...
 ERROR
   [UNIT TEST] test_get_pid_by_name_lsof (test.unit.util.system.TestSystem)
 ... ERROR
   [UNIT TEST] test_get_pid_by_name_pgrep
 (test.unit.util.system.TestSystem) ... ERROR
   [UNIT TEST] test_get_pid_by_name_pidof
 (test.unit.util.system.TestSystem) ... ERROR
   [UNIT TEST] test_is_running (test.unit.util.system.TestSystem) ... ERROR
   [UNIT TEST] test_relative_cookie
 (test.unit.connection.protocolinfo.TestProtocolInfoResponse) ... FAIL

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


More information about the tor-bugs mailing list