text: begin_unit
  comment|'#    Copyright 2014 IBM Corp.'
  nl|'\n'
  comment|'#'
  nl|'\n'
  comment|'#    Licensed under the Apache License, Version 2.0 (the "License"); you may'
  nl|'\n'
  comment|'#    not use this file except in compliance with the License. You may obtain'
  nl|'\n'
  comment|'#    a copy of the License at'
  nl|'\n'
  comment|'#'
  nl|'\n'
  comment|'#         http://www.apache.org/licenses/LICENSE-2.0'
  nl|'\n'
  comment|'#'
  nl|'\n'
  comment|'#    Unless required by applicable law or agreed to in writing, software'
  nl|'\n'
  comment|'#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT'
  nl|'\n'
  comment|'#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the'
  nl|'\n'
  comment|'#    License for the specific language governing permissions and limitations'
  nl|'\n'
  comment|'#    under the License.'
  nl|'\n'
  nl|'\n'
  name|'from'
  name|'nova'
  name|'import'
  name|'objects'
  newline|'\n'
  name|'from'
  name|'nova'
  name|'import'
  name|'test'
  newline|'\n'
  name|'from'
  name|'nova'
  op|'.'
  name|'virt'
  name|'import'
  name|'configdrive'
  newline|'\n'
  nl|'\n'
  nl|'\n'
  DECL|class|ConfigDriveTestCase
  name|'class'
  name|'ConfigDriveTestCase'
  op|'('
  name|'test'
  op|'.'
  name|'NoDBTestCase'
  op|')'
  op|':'
  newline|'\n'
  DECL|member|test_instance_force
  indent|'    '
  name|'def'
  name|'test_instance_force'
  op|'('
  name|'self'
  op|')'
  op|':'
  newline|'\n'
  indent|'        '
  name|'self'
  op|'.'
  name|'flags'
  op|'('
  name|'force_config_drive'
  op|'='
  name|'False'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'instance'
  op|'='
  name|'objects'
  op|'.'
  name|'Instance'
  op|'('
  nl|'\n'
  name|'config_drive'
  op|'='
  string|'"yes"'
  op|','
  nl|'\n'
  name|'system_metadata'
  op|'='
  op|'{'
  nl|'\n'
  string|'"image_img_config_drive"'
  op|':'
  string|'"mandatory"'
  op|','
  nl|'\n'
  op|'}'
  nl|'\n'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'self'
  op|'.'
  name|'assertTrue'
  op|'('
  name|'configdrive'
  op|'.'
  name|'required_by'
  op|'('
  name|'instance'
  op|')'
  op|')'
  newline|'\n'
  nl|'\n'
  DECL|member|test_image_meta_force
  dedent|''
  name|'def'
  name|'test_image_meta_force'
  op|'('
  name|'self'
  op|')'
  op|':'
  newline|'\n'
  indent|'        '
  name|'self'
  op|'.'
  name|'flags'
  op|'('
  name|'force_config_drive'
  op|'='
  name|'False'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'instance'
  op|'='
  name|'objects'
  op|'.'
  name|'Instance'
  op|'('
  nl|'\n'
  name|'config_drive'
  op|'='
  name|'None'
  op|','
  nl|'\n'
  name|'system_metadata'
  op|'='
  op|'{'
  nl|'\n'
  string|'"image_img_config_drive"'
  op|':'
  string|'"mandatory"'
  op|','
  nl|'\n'
  op|'}'
  nl|'\n'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'self'
  op|'.'
  name|'assertTrue'
  op|'('
  name|'configdrive'
  op|'.'
  name|'required_by'
  op|'('
  name|'instance'
  op|')'
  op|')'
  newline|'\n'
  nl|'\n'
  DECL|member|test_config_flag_force
  dedent|''
  name|'def'
  name|'test_config_flag_force'
  op|'('
  name|'self'
  op|')'
  op|':'
  newline|'\n'
  indent|'        '
  name|'self'
  op|'.'
  name|'flags'
  op|'('
  name|'force_config_drive'
  op|'='
  name|'True'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'instance'
  op|'='
  name|'objects'
  op|'.'
  name|'Instance'
  op|'('
  nl|'\n'
  name|'config_drive'
  op|'='
  name|'None'
  op|','
  nl|'\n'
  name|'system_metadata'
  op|'='
  op|'{'
  nl|'\n'
  string|'"image_img_config_drive"'
  op|':'
  string|'"optional"'
  op|','
  nl|'\n'
  op|'}'
  nl|'\n'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'self'
  op|'.'
  name|'assertTrue'
  op|'('
  name|'configdrive'
  op|'.'
  name|'required_by'
  op|'('
  name|'instance'
  op|')'
  op|')'
  newline|'\n'
  nl|'\n'
  DECL|member|test_no_config_drive
  dedent|''
  name|'def'
  name|'test_no_config_drive'
  op|'('
  name|'self'
  op|')'
  op|':'
  newline|'\n'
  indent|'        '
  name|'self'
  op|'.'
  name|'flags'
  op|'('
  name|'force_config_drive'
  op|'='
  name|'False'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'instance'
  op|'='
  name|'objects'
  op|'.'
  name|'Instance'
  op|'('
  nl|'\n'
  name|'config_drive'
  op|'='
  name|'None'
  op|','
  nl|'\n'
  name|'system_metadata'
  op|'='
  op|'{'
  nl|'\n'
  string|'"image_img_config_drive"'
  op|':'
  string|'"optional"'
  op|','
  nl|'\n'
  op|'}'
  nl|'\n'
  op|')'
  newline|'\n'
  nl|'\n'
  name|'self'
  op|'.'
  name|'assertFalse'
  op|'('
  name|'configdrive'
  op|'.'
  name|'required_by'
  op|'('
  name|'instance'
  op|')'
  op|')'
  newline|'\n'
  dedent|''
  dedent|''
  endmarker|''
  end_unit
  