<s> import pytest <EOL> def test_custom_state ( base ) : <EOL> class App ( object ) : <EOL> name = '<STR_LIT>' <EOL> source = base . make_plugin_source ( searchpath = [ '<STR_LIT>' ] ) <EOL> source . app = App ( ) <EOL> plg = source . load_plugin ( '<STR_LIT>' ) <EOL> assert plg . get_app_name ( ) == '<STR_LIT>' <EOL> def test_plugin_resources ( source ) : <EOL> with source . open_resource ( '<STR_LIT>' , '<STR_LIT>' ) as f : <EOL> contents = f . read ( ) <EOL> assert contents == b'<STR_LIT>' <EOL> with pytest . raises ( IOError ) : <EOL> source . open_resource ( '<STR_LIT>' , '<STR_LIT>' ) </s>
