Created
June 27, 2018 11:20
-
-
Save Glutexo/d11ea0568e2ef60dad7d82eca682f5fd to your computer and use it in GitHub Desktop.
insights-core failing tests in master
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ________________________________ test_shadowing ________________________________ | |
| def test_shadowing(): | |
| httpd1 = HttpdConf(context_wrap(HTTPD_CONF_SHADOWTEST_1, path='/etc/httpd/conf/httpd.conf')) | |
| httpd2 = HttpdConf(context_wrap(HTTPD_CONF_SHADOWTEST_2, path='/etc/httpd/conf.d/00-z.conf')) | |
| httpd3 = HttpdConf(context_wrap(HTTPD_CONF_SHADOWTEST_3, path='/etc/httpd/conf.d/z-z.conf')) | |
| result = HttpdConfAll([httpd1, httpd2, httpd3]) | |
| # get_setting_list returns ALL matching data | |
| assert result.get_setting_list('Foo') == [ | |
| ParsedData('1A', 'Foo 1A', None, None, 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('1B', 'Foo 1B', None, None, 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('1C', 'Foo 1C', None, None, 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('2A', 'Foo 2A', None, None, '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ParsedData('2B', 'Foo 2B', None, None, '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ParsedData('2C', 'Foo 2C', None, None, '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ParsedData('3A', 'Foo 3A', None, None, 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ParsedData('3B', 'Foo 3B', None, None, 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ParsedData('3C', 'Foo 3C', None, None, 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ] | |
| > assert result.get_setting_list('Bar', section=('IfModule', 'prefork.c')) == [ | |
| {('IfModule', 'prefork.c'): [ | |
| ParsedData('1A', 'Bar 1A', 'IfModule', 'prefork.c', 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('1B', 'Bar 1B', 'IfModule', 'prefork.c', 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('1C', 'Bar 1C', 'IfModule', 'prefork.c', 'httpd.conf', '/etc/httpd/conf/httpd.conf'), | |
| ParsedData('3A', 'Bar 3A', 'IfModule', 'prefork.c', 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ParsedData('3B', 'Bar 3B', 'IfModule', 'prefork.c', 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ParsedData('3C', 'Bar 3C', 'IfModule', 'prefork.c', 'z-z.conf', '/etc/httpd/conf.d/z-z.conf'), | |
| ], | |
| }, | |
| {('IfModule', 'ASDF.prefork.c.ASDF'): [ | |
| ParsedData('2A', 'Bar 2A', 'IfModule', 'ASDF.prefork.c.ASDF', '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ParsedData('2B', 'Bar 2B', 'IfModule', 'ASDF.prefork.c.ASDF', '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ParsedData('2C', 'Bar 2C', 'IfModule', 'ASDF.prefork.c.ASDF', '00-z.conf', '/etc/httpd/conf.d/00-z.conf'), | |
| ], | |
| }, | |
| ] | |
| E AssertionError: assert [{('IfModule'.../z-z.conf')]}] == [{('IfModule',...00-z.conf')]}] | |
| E At index 0 diff: {('IfModule', 'ASDF.prefork.c.ASDF'): [ParsedData(value='2A', line='Bar 2A', section='IfModule', section_name='ASDF.prefork.c.ASDF', file_name='00-z.conf', file_path='/etc/httpd/conf.d/00-z.conf'), ParsedData(value='2B', line='Bar 2B', section='IfModule', section_name='ASDF.prefork.c.ASDF', file_name='00-z.conf', file_path='/etc/httpd/conf.d/00-z.conf'), ParsedData(value='2C', line='Bar 2C', section='IfModule', section_name='ASDF.prefork.c.ASDF', file_name='00-z.conf', file_path='/etc/httpd/conf.d/00-z.conf')]} != {('IfModule', 'prefork.c'): [ParsedDat... | |
| E | |
| E ...Full output truncated (2 lines hidden), use '-vv' to show | |
| insights/combiners/tests/test_httpd_conf.py:387: AssertionError | |
| ____________________________ test_command_not_found ____________________________ | |
| def test_command_not_found(): | |
| bad_line = "blah: Command not found" | |
| > assert not TextFileProvider.validate_lines([bad_line]) | |
| E AttributeError: type object 'TextFileProvider' has no attribute 'validate_lines' | |
| insights/tests/test_text_file_provider.py:6: AttributeError | |
| ______________________________ test_no_such_file _______________________________ | |
| def test_no_such_file(): | |
| bad_line = "timeout: failed to run command `/usr/sbin/brctl': No such file or directory" | |
| > assert not TextFileProvider.validate_lines([bad_line]) | |
| E AttributeError: type object 'TextFileProvider' has no attribute 'validate_lines' | |
| insights/tests/test_text_file_provider.py:11: AttributeError |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment