From 806eb1e108a62784a595f611abc4864888dcc64b Mon Sep 17 00:00:00 2001 From: James Falcon Date: Tue, 11 May 2021 11:36:56 -0500 Subject: [PATCH] Add integration test for #868 Ensure no Traceback when 'chef_license' is set --- tests/integration_tests/bugs/test_gh868.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 tests/integration_tests/bugs/test_gh868.py diff --git a/tests/integration_tests/bugs/test_gh868.py b/tests/integration_tests/bugs/test_gh868.py new file mode 100644 index 00000000000..31052dcb4dd --- /dev/null +++ b/tests/integration_tests/bugs/test_gh868.py @@ -0,0 +1,19 @@ +"""Ensure no Traceback when 'chef_license' is set""" +import pytest +from tests.integration_tests.instances import IntegrationInstance + + +USERDATA = """\ +#cloud-config +chef: + install_type: omnibus + chef_license: accept + server_url: https://chef.yourorg.invalid + validation_name: some-validator +""" + + +@pytest.mark.user_data(USERDATA) +def test_chef_license(client: IntegrationInstance): + log = client.read_from_file('/var/log/cloud-init.log') + assert 'Traceback' not in log