<s> from __future__ import absolute_import <EOL> import os <EOL> import shutil <EOL> from salttesting import skipIf <EOL> from salttesting . helpers import ( ensure_in_syspath , destructiveTest ) <EOL> ensure_in_syspath ( '<STR_LIT>' ) <EOL> import integration <EOL> import salt . utils <EOL> import salt . ext . six as six <EOL> @ destructiveTest <EOL> @ skipIf ( salt . utils . is_windows ( ) , '<STR_LIT>' ) <EOL> @ skipIf ( salt . utils . is_darwin ( ) , '<STR_LIT>' ) <EOL> class DiskModuleVirtualizationTest ( integration . ModuleCase ) : <EOL> '''<STR_LIT>''' <EOL> def setUp ( self ) : <EOL> if os . path . isfile ( '<STR_LIT>' ) : <EOL> shutil . move ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> def test_no_mtab ( self ) : <EOL> ret = self . run_function ( '<STR_LIT>' ) <EOL> self . assertDictEqual ( ret , { } ) <EOL> def tearDown ( self ) : <EOL> if os . path . isfile ( '<STR_LIT>' ) : <EOL> shutil . move ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> class DiskModuleTest ( integration . ModuleCase ) : <EOL> '''<STR_LIT>''' <EOL> def test_usage ( self ) : <EOL> '''<STR_LIT>''' <EOL> ret = self . run_function ( '<STR_LIT>' ) <EOL> self . assertTrue ( isinstance ( ret , dict ) ) <EOL> if not isinstance ( ret , dict ) : <EOL> return <EOL> if salt . utils . is_darwin ( ) : <EOL> for key , val in six . iteritems ( ret ) : <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> else : <EOL> for key , val in six . iteritems ( ret ) : <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> def test_inodeusage ( self ) : <EOL> '''<STR_LIT>''' <EOL> ret = self . run_function ( '<STR_LIT>' ) <EOL> self . assertTrue ( isinstance ( ret , dict ) ) <EOL> if not isinstance ( ret , dict ) : <EOL> return <EOL> for key , val in six . iteritems ( ret ) : <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> self . assertTrue ( '<STR_LIT>' in val ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> from integration import run_tests <EOL> run_tests ( [ DiskModuleVirtualizationTest , DiskModuleTest ] ) </s>
