summaryrefslogtreecommitdiff
path: root/tests/unittests/test_handler
AgeCommit message (Collapse)Author
2016-06-07harden mirrorfail tests for the fact that even good mirrors can failChristian Ehrhardt
This might happen e.g. in locked down build environments. In those cases this is detected and the test skipped while not giving up testing it in more capable environments.
2016-06-07drop gpg activity from aot-source key testsChristian Ehrhardt
While the unittest gets a bit less real by that change, it will work in protected environment (e.g. sbuild) and leave the developers .gpg keyring alone.
2016-06-06make unittests more readableChristian Ehrhardt
By moving the "what it does" into the first line of the docstrings output becomes much more useful.
2016-06-06capture output of gpg calls to avoid messing up stdout/stderrChristian Ehrhardt
2016-06-06remove check that fails if user has installed tested keysChristian Ehrhardt
The overall check for the expected key is a superset and would spot an issue.
2016-06-06apt_src_keyid_real: drop unused exception variableChristian Ehrhardt
2016-06-06fix alternate keyserver dnsChristian Ehrhardt
The intentionally false name was meant for testing of abug, now we can and should use a proper third party keyserver.
2016-06-06only test the apt feature in environments with aptChristian Ehrhardt
2016-06-06rename add_key / add_source to add_apt_key / add_apt_sourceChristian Ehrhardt
The functions clearly are apt specific so the name should reflect that.
2016-06-06fixup key tests for cases where network isn't availableChristian Ehrhardt
2016-06-06add_key_raw - make exceptions more specificChristian Ehrhardt
2016-06-06test alternate keyserverChristian Ehrhardt
2016-06-06make _get_default_params method staticChristian Ehrhardt
2016-06-06unify testing of real gpg key addsChristian Ehrhardt
2016-06-03tests: fix apt tests to run inside ubuntu build environmentScott Moser
This just mocks out use of lsb_release as it is not available in a build environment. Additionally mocks out use of getkeybyid. This admittedly makes the test for a long key fingerprint not useful as it was broken only inside getkeybyid. Also fix 'make yaml' for cloud-config.txt
2016-06-03fix tox -e flake8Scott Moser
2016-05-30add test for wrong apt_source formatChristian Ehrhardt
2016-05-30drop errorlist from convert_to_new_formatChristian Ehrhardt
2016-05-25fix inline doc of test_apt_src_longkeyid_realChristian Ehrhardt
2016-05-25make test_apt_srcl_custom independent to where it is executedChristian Ehrhardt
2016-05-24add test for the now isolated convert_to_new_format functionChristian Ehrhardt
2016-05-24rebased with upstream and reolved merge conflictsChristian Ehrhardt
2016-05-23final pep8 check fixupsChristian Ehrhardt
2016-05-23add test_apt_src_replace_dict_triChristian Ehrhardt
This includes a test for the weird but valid case in the new dictionary syntax that one sets a key (which is the filename) but overwrites the filename value inside of it.
2016-05-23shorten method names to follow python rulesChristian Ehrhardt
2016-05-23unify basic triple check and add test_apt_src_basic_dict_triple based on itChristian Ehrhardt
2016-05-23add test_apt_source_basic_dictChristian Ehrhardt
This is the basic testcase but in the new dictionary format
2016-05-23add triple test for ppa addingChristian Ehrhardt
2016-05-23make checkers happy about unused loop indexChristian Ehrhardt
2016-05-23add triple case for test_apt_source_keyid_triple incl triple key checkChristian Ehrhardt
2016-05-23testcases with multiple source list entriesChristian Ehrhardt
2016-05-23fix function names in inline docChristian Ehrhardt
2016-05-23extend test_apt_source_key by nofn caseChristian Ehrhardt
2016-05-23put fallbackfn to initChristian Ehrhardt
This was now used by multiple methods, no need to duplicate code.
2016-05-23extend test_apt_source_keyid by no filename caseChristian Ehrhardt
2016-05-23extend test_apt_source_replace by a no-filename caseChristian Ehrhardt
2016-05-23drop unused mockappsubpChristian Ehrhardt
2016-05-23test_apt_source_basic_nofn check for non-specified filenameChristian Ehrhardt
Cloud-inint uses a default fallback, we want to ensure no code change modfies this behaviour.
2016-05-23generalize test_apt_source_basic to be reusable across more testcasesChristian Ehrhardt
2016-05-12run flake8 instead of pyflakes in tox. expect tests/ to pass flake8.Scott Moser
2016-05-12make pep8 happy with a few spacesChristian Ehrhardt
2016-05-12streamline code and sanitize expected result string definitionChristian Ehrhardt
2016-05-12improve spacing in apt_source_list testChristian Ehrhardt
2016-05-12alphabetical order on importsChristian Ehrhardt
2016-05-12alphabetical import orderChristian Ehrhardt
2016-05-12remove superfluous importChristian Ehrhardt
2016-05-12Adding test_apt_source_keyid_real and test_apt_source_longkeyid_realChristian Ehrhardt
This now ensures that the stack of fetching IDs from keyservers and adding them really works by comparing against known good keys that are expected.
2016-05-12remove no more applicable "not supported" statementsChristian Ehrhardt
2016-05-12use old style nested context to make pep8 happyChristian Ehrhardt
2016-05-12Finalize test_apt_srcl_customChristian Ehrhardt
Adding: - known content after full templating - restore subp from mocking for proper execution - drop all kind of superfluous mocking of util and OS