remove defunct test, add random bint ip test, and fix offline mode
This commit is contained in:
parent
ef25377e15
commit
a1fd5f2648
3 changed files with 24 additions and 23 deletions
|
@ -1,16 +0,0 @@
|
|||
import sys, os
|
||||
sys.path.append(".")
|
||||
sys.path.append("src/")
|
||||
import unittest, uuid, json
|
||||
TEST_DIR = 'testdata/%s-%s' % (uuid.uuid4(), os.path.basename(__file__)) + '/'
|
||||
print("Test directory:", TEST_DIR)
|
||||
os.environ["ONIONR_HOME"] = TEST_DIR
|
||||
import onionrblocks
|
||||
from utils import createdirs
|
||||
from utils import readstatic
|
||||
createdirs.create_dirs()
|
||||
class OnionrConfigTest(unittest.TestCase):
|
||||
def test_security_value(self):
|
||||
return
|
||||
|
||||
unittest.main()
|
16
tests/test_random_bind_ip_setting.py
Normal file
16
tests/test_random_bind_ip_setting.py
Normal file
|
@ -0,0 +1,16 @@
|
|||
import sys, os
|
||||
sys.path.append(".")
|
||||
sys.path.append("src/")
|
||||
import unittest, uuid
|
||||
TEST_DIR = 'testdata/%s-%s' % (uuid.uuid4(), os.path.basename(__file__)) + '/'
|
||||
print("Test directory:", TEST_DIR)
|
||||
os.environ["ONIONR_HOME"] = TEST_DIR
|
||||
from onionrsetup import setup_config
|
||||
setup_config()
|
||||
import config
|
||||
|
||||
class TestRandomBindIP(unittest.TestCase):
|
||||
def test_random_bind_ip_default_setting(self):
|
||||
self.assertTrue(config.get('general.random_bind_ip'))
|
||||
|
||||
unittest.main()
|
Loading…
Add table
Add a link
Reference in a new issue