Beispiel #1
0
def test_openshift_node():
    openshift_node_service = config.SystemdOpenshiftNode(
        context_wrap(SYSTEMD_OPENSHIFT_NODE))
    assert openshift_node_service.data["Unit"]["Wants"] == "docker.service"
    assert openshift_node_service.data["Unit"]["After"] == [
        'docker.service', 'openvswitch.service'
    ]
Beispiel #2
0
def test_doc_examples():
    env = {
            'docker_service': config.SystemdDocker(context_wrap(SYSTEMD_DOCKER)),
            'system_conf': config.SystemdSystemConf(context_wrap(SYSTEMD_SYSTEM_CONF)),
            'system_origin_accounting': config.SystemdOriginAccounting(context_wrap(SYSTEMD_SYSTEM_ORIGIN_ACCOUNTING)),
            'openshift_node_service': config.SystemdOpenshiftNode(context_wrap(SYSTEMD_OPENSHIFT_NODE)),
            'logind_conf': config.SystemdLogindConf(context_wrap(SYSTEMD_LOGIND_CONF)),
            'rpcbind_socket': config.SystemdRpcbindSocketConf(context_wrap(SYSTEMD_RPCBIND_SOCKET))
          }
    failed, total = doctest.testmod(config, globs=env)
    assert failed == 0