diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/cleaner_tests/report_disabled_parsers.py | 4 | ||||
-rw-r--r-- | tests/cleaner_tests/report_with_mask.py | 2 | ||||
-rw-r--r-- | tests/report_tests/encryption_tests.py | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/tests/cleaner_tests/report_disabled_parsers.py b/tests/cleaner_tests/report_disabled_parsers.py index 84af7893..286c6aa8 100644 --- a/tests/cleaner_tests/report_disabled_parsers.py +++ b/tests/cleaner_tests/report_disabled_parsers.py @@ -33,7 +33,7 @@ class ReportDisabledParsersTest(StageOneReportTest): # make sure that the other parsers remain functional def test_localhost_was_obfuscated(self): - self.assertFileHasContent('/etc/hostname', 'host0') + self.assertFileHasContent('hostname', 'host0') def test_mac_addrs_were_obfuscated(self): content = self.get_file_content('sos_commands/networking/ip_maddr_show') @@ -54,7 +54,7 @@ class NativeCleanDisabledParsersTest(StageTwoReportTest): sos_component = 'clean' def test_localhost_not_obfuscated(self): - self.assertFileNotHasContent('/etc/hostname', self.sysinfo['pre']['networking']['hostname']) + self.assertFileNotHasContent('hostname', self.sysinfo['pre']['networking']['hostname']) self.assertFileNotHasContent('uname', self.sysinfo['pre']['networking']['hostname']) def test_local_ip_was_obfuscated(self): diff --git a/tests/cleaner_tests/report_with_mask.py b/tests/cleaner_tests/report_with_mask.py index 08e873d4..9b1a9edb 100644 --- a/tests/cleaner_tests/report_with_mask.py +++ b/tests/cleaner_tests/report_with_mask.py @@ -35,7 +35,7 @@ class ReportWithMask(StageOneReportTest): self.assertSosLogContains('Loaded .* as type sos report directory') def test_localhost_was_obfuscated(self): - self.assertFileHasContent('/etc/hostname', 'host0') + self.assertFileHasContent('hostname', 'host0') def test_ip_address_was_obfuscated(self): # Note: do not test for starting with the 100.* block here, as test diff --git a/tests/report_tests/encryption_tests.py b/tests/report_tests/encryption_tests.py index 22c5669a..9ce401ec 100644 --- a/tests/report_tests/encryption_tests.py +++ b/tests/report_tests/encryption_tests.py @@ -42,7 +42,7 @@ class EncryptedCleanedReportTest(EncryptedReportTest): sos_cmd = "-o host,networking --clean --encrypt-pass %s" % encrypt_pass def test_hostname_obfuscated(self): - self.assertFileHasContent('/etc/hostname', 'host0') + self.assertFileHasContent('hostname', 'host0') def test_tarball_named_obfuscated(self): self.assertTrue('obfuscated' in self.archive) |