def test_valid_linux_create_options(self): some_runtime = 'TOMCAT|8.5-jre8' test_docker_image = 'lukasz/great-image:123' test_multi_container_config = 'some_config.yaml' test_multi_container_type = 'COMPOSE' self.assertTrue( validate_container_app_create_options(some_runtime, None, None, None)) self.assertTrue( validate_container_app_create_options(None, test_docker_image, None, None)) self.assertTrue( validate_container_app_create_options(None, None, test_multi_container_config, test_multi_container_type)) self.assertFalse( validate_container_app_create_options(some_runtime, None, test_multi_container_config, test_multi_container_type)) self.assertFalse( validate_container_app_create_options(some_runtime, None, test_multi_container_config, None)) self.assertFalse( validate_container_app_create_options(some_runtime, test_docker_image, test_multi_container_config, None)) self.assertFalse( validate_container_app_create_options(None, None, test_multi_container_config, None)) self.assertFalse( validate_container_app_create_options(None, None, None, None))
def test_valid_linux_create_options(self): some_runtime = 'TOMCAT|8.5-jre8' test_docker_image = 'lukasz/great-image:123' test_multi_container_config = 'some_config.yaml' test_multi_container_type = 'COMPOSE' self.assertTrue(validate_container_app_create_options(some_runtime, None, None, None)) self.assertTrue(validate_container_app_create_options(None, test_docker_image, None, None)) self.assertTrue(validate_container_app_create_options(None, None, test_multi_container_config, test_multi_container_type)) self.assertFalse(validate_container_app_create_options(some_runtime, None, test_multi_container_config, test_multi_container_type)) self.assertFalse(validate_container_app_create_options(some_runtime, None, test_multi_container_config, None)) self.assertFalse(validate_container_app_create_options(some_runtime, test_docker_image, test_multi_container_config, None)) self.assertFalse(validate_container_app_create_options(None, None, test_multi_container_config, None)) self.assertFalse(validate_container_app_create_options(None, None, None, None))