Ejemplo n.º 1
0
    def test_read_system_config_file_no_sections(self):

        with open(self.thefile, "w") as f:
            f.write("gap_limit = 5")  # The file has no sections at all

        result = read_system_config(self.thefile)
        self.assertEqual({}, result)
    def test_read_system_config_file_no_sections(self):

        with open(self.thefile, "w") as f:
            f.write("gap_limit = 5")  # The file has no sections at all

        result = read_system_config(self.thefile)
        self.assertEqual({}, result)
    def test_read_system_config_file_returns_file_options(self):
        with open(self.thefile, "w") as f:
            f.write(self.sample_conf)

        result = read_system_config(self.thefile)
        self.assertEqual({"gap_limit": "5"}, result)
 def test_read_system_config_file_does_not_exist(self):
     somefile = "/foo/I/do/not/exist/electrum-doged.conf"
     result = read_system_config(somefile)
     self.assertEqual({}, result)
Ejemplo n.º 5
0
    def test_read_system_config_file_returns_file_options(self):
        with open(self.thefile, "w") as f:
            f.write(self.sample_conf)

        result = read_system_config(self.thefile)
        self.assertEqual({"gap_limit": "5"}, result)
Ejemplo n.º 6
0
 def test_read_system_config_file_does_not_exist(self):
     somefile = "/foo/I/do/not/exist/electrum.conf"
     result = read_system_config(somefile)
     self.assertEqual({}, result)
Ejemplo n.º 7
0
 def test_read_system_config_file_does_not_exist(self):
     somefile = "/foo/I/do/not/exist/light-capricoin.conf"
     result = read_system_config(somefile)
     self.assertEqual({}, result)