summaryrefslogtreecommitdiffstats
path: root/ipatests/test_xmlrpc/test_host_plugin.py
Commit message (Collapse)AuthorAgeFilesLines
* generalize certificate creation during testingMartin Babinsky2015-06-231-2/+5
| | | | | | | | | | | With added support for multiple certificates for hosts, services, and even users, IPA testing framework will need a more flexible way to generate temporary testing certificates for these entities. This patch modifies the currently used `testcert` module to support these requirements. Related to work on http://www.freeipa.org/page/V4/User_Certificates Reviewed-By: Milan Kubík <mkubik@redhat.com>
* Abstract the HostTracker class from host plugin testMilan Kubík2015-06-051-150/+5
| | | | | | | | | | | Implements a base class to help test LDAP based plugins. The class has been decoupled from the original host plugin test and moved to separate module ipatests.test_xmlrpc.ldaptracker. https://fedorahosted.org/freeipa/ticket/5032 Reviewed-By: David Kupka <dkupka@redhat.com>
* test_host_plugin: Use HostTracker fixturesPetr Viktorin2015-01-141-1153/+803
| | | | | | | | | | | | The racker object "remembers" expected state across several tests, so only changes (rather than all expected state) need to be specified in each test. Also, the tracker fixture will make it easy to use hosts in other test modules. This change makes the tests independent; any permutation of any subset of these tests should now pass. Reviewed-By: Tomas Babej <tbabej@redhat.com>
* test_host_plugin: Split tests into independent classesPetr Viktorin2015-01-141-158/+220
| | | | | | | | Any of the classes may be run alone. In classes not marked @ordered, individual tests are independent. Reviewed-By: Tomas Babej <tbabej@redhat.com>
* test_host_plugin: Convert tests to imperative stylePetr Viktorin2015-01-141-1587/+1167
| | | | | | | | | | | This has several advantages: - Tests other than run-command/check-response can be added easily - Tracebacks are meaningful (which means we'll be able to remove a lot of test name/description/location tracking code) - Individual tests can be selected/deselected using normal pytest mechanisms (but for isolated tests, more changes will be needed) Reviewed-By: Tomas Babej <tbabej@redhat.com>
* Run pylint on testsPetr Viktorin2015-01-141-1/+1
| | | | | | | | | | | | | | | Drop support for pylint < 1.0 Enable ignoring unknown attributes on modules (both nose and pytest use advanced techniques, support for which only made it to pylint recently) Fix some bugs revealed by pylint Do minor refactoring or add pylint:disable directives where the linter complains. Reviewed-By: Tomas Babej <tbabej@redhat.com>
* add --hosts and --hostgroup options to allow/retrieve keytab methodsPetr Vobornik2014-12-031-5/+104
| | | | | | | | | | | | | | | | | | `--hosts` and `--hostgroup` options added to: * service-allow-create-keytab * service-allow-retrieve-keytab * service-disallow-create-keytab * service-disallow-retrieve-keytab * host-allow-create-keytab * host-allow-retrieve-keytab * host-disallow-create-keytab * host-disallow-retrieve-keytab in order to allow hosts to retrieve keytab of their services or related hosts as described on http://www.freeipa.org/page/V4/Keytab_Retrieval design page https://fedorahosted.org/freeipa/ticket/4777 Reviewed-By: Jan Cholasta <jcholast@redhat.com>
* tests: Use PEP8-compliant setup/teardown method namesPetr Viktorin2014-11-211-1/+1
| | | | | | | | | | | | The setUp/dearDown names are used in the unittest module, but there is no reason to use them in non-`unittest` test cases. Nose supports both styles (but mixing them can cause trouble when calling super()'s methods). Pytest only supports the new ones. https://fedorahosted.org/freeipa/ticket/4610 Reviewed-By: Tomas Babej <tbabej@redhat.com>
* tests: management of keytab permissionsPetr Vobornik2014-10-171-0/+362
| | | | | | https://fedorahosted.org/freeipa/ticket/4419 Reviewed-By: Jan Cholasta <jcholast@redhat.com>
* DNS tests: tests update to due to change in optionsMartin Basti2014-09-251-10/+9
| | | | | | | | Affected options --name-server, --ip-address Part of ticket: https://fedorahosted.org/freeipa/ticket/4149 Reviewed-By: Petr Spacek <pspacek@redhat.com>
* ipalib: host_del: Extend LDAPDelete's takes_options instead of overridingTomas Babej2014-09-171-4/+1
| | | | | | | | | | | The host-del command did not accept --continue option, since the takes_options was overriden and did not take the options from LDAPDelete. Fix the behaviour. https://fedorahosted.org/freeipa/ticket/4473 Reviewed-By: Jan Cholasta <jcholast@redhat.com>
* Tests: host tests with dnsMartin Basti2014-08-111-0/+448
| | | | | | Test for: https://fedorahosted.org/freeipa/ticket/4164 Reviewed-By: Petr Viktorin <pviktori@redhat.com>
* Allow to add host if AAAA record existsMartin Basti2014-08-111-1/+1
| | | | | | http://fedorahosted.org/freeipa/ticket/4164 Reviewed-By: Petr Viktorin <pviktori@redhat.com>
* Allow primary keys to use different type than unicode.Jan Cholasta2014-04-181-6/+6
| | | | | | | | | | Also return list of primary keys instead of a single unicode CSV value from LDAPDelete-based commands. This introduces a new capability 'primary_key_types' for backward compatibility with old clients. Reviewed-By: Tomas Babej <tbabej@redhat.com>
* tests: Create the testing service certificate on demandPetr Viktorin2014-03-061-14/+8
| | | | | | | | | Replace the make-testcert command with a module that creates the certificate when it is first needed. As a result the tests are more self-contained, and can be run from a read-only location (such as installed from a system package). Reviewed-By: Jan Cholasta <jcholast@redhat.com>
* Fix test_host_plugin for DNS Classless Reverse zonesMartin Basti2014-02-121-2/+2
| | | | | | Ticket: https://fedorahosted.org/freeipa/ticket/4143 Reviewed-by: Martin Kosek <mkosek@redhat.com>
* Change the way we determine if the host has a password set.Rob Crittenden2014-01-151-0/+27
| | | | | | | | | | When creating a host with a password we don't set a Kerberos principal or add the Kerberos objectclasses. Those get added when the host is enrolled. If one passed in --password= (so no password) then we incorrectly thought the user was in fact setting a password, so the principal and objectclasses weren't updated. https://fedorahosted.org/freeipa/ticket/4102
* Make an ipa-tests packagePetr Viktorin2013-06-171-0/+939
Rename the 'tests' directory to 'ipa-tests', and create an ipa-tests RPM containing the test suite Part of the work for: https://fedorahosted.org/freeipa/ticket/3654