def test_generate_app_yaml(self):
    mock_dev_yaml_filepath = 'mock_app_dev.yaml'
    mock_yaml_filepath = 'mock_app.yaml'
    app_dev_yaml_filepath_swap = self.swap(build, 'APP_DEV_YAML_FILEPATH', mock_dev_yaml_filepath)
    app_yaml_filepath_swap = self.swap(build, 'APP_YAML_FILEPATH', mock_yaml_filepath)
    app_dev_yaml_temp_file = tempfile.NamedTemporaryFile()
    app_dev_yaml_temp_file.name = mock_dev_yaml_filepath
    with open(mock_dev_yaml_filepath, 'w') as tmp:
        tmp.write('Some content in mock_app_dev.yaml')
    app_yaml_temp_file = tempfile.NamedTemporaryFile()
    app_yaml_temp_file.name = mock_yaml_filepath
    with open(mock_yaml_filepath, 'w') as tmp:
        tmp.write('Initial content in mock_app.yaml')
    with app_dev_yaml_filepath_swap, app_yaml_filepath_swap:
        build.generate_app_yaml()
    with open(mock_yaml_filepath, 'r') as yaml_file:
        content = yaml_file.read()
    self.assertEqual(content, '# THIS FILE IS AUTOGENERATED, DO NOT MODIFY\nSome content in mock_app_dev.yaml')
    app_yaml_temp_file.close()
    app_dev_yaml_temp_file.close()
def test_generate_app_yaml(self):
    mock_dev_yaml_filepath = 'mock_app_dev.yaml'
    mock_yaml_filepath = 'mock_app.yaml'
    app_dev_yaml_filepath_swap = self.swap(build, 'APP_DEV_YAML_FILEPATH', mock_dev_yaml_filepath)
    app_yaml_filepath_swap = self.swap(build, 'APP_YAML_FILEPATH', mock_yaml_filepath)
    app_dev_yaml_temp_file = tempfile.NamedTemporaryFile()
    app_dev_yaml_temp_file.name = mock_dev_yaml_filepath
    with open(mock_dev_yaml_filepath, 'w') as tmp:
        tmp.write('Some content in mock_app_dev.yaml')
    app_yaml_temp_file = tempfile.NamedTemporaryFile()
    app_yaml_temp_file.name = mock_yaml_filepath
    with open(mock_yaml_filepath, 'w') as tmp:
        tmp.write('Initial content in mock_app.yaml')
    with app_dev_yaml_filepath_swap, app_yaml_filepath_swap:
        build.generate_app_yaml()
    with open(mock_yaml_filepath, 'r') as yaml_file:
        content = yaml_file.read()
    self.assertEqual(content, '# THIS FILE IS AUTOGENERATED, DO NOT MODIFY\nSome content in mock_app_dev.yaml')
    app_yaml_temp_file.close()
    app_dev_yaml_temp_file.close()