Created
July 18, 2010 11:59
-
-
Save odino/480354 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
click('Save', array('qredd_content' => array( | |
'content_type_id' => 1, | |
'title' => 'Content sample', | |
'aggregator_id' => '0', | |
'is_active' => true, | |
)))-> | |
with('request')->begin()-> | |
isParameter('module', 'content')-> | |
isParameter('action', 'create')-> | |
end()-> | |
with('form')->begin()->info('form is good')-> | |
hasErrors(false)-> | |
end()-> | |
with('response')->isRedirected()-> | |
followRedirect()-> | |
with('request')->begin()->info('admin can edit the just inserted content')-> | |
isParameter('module', 'content')-> | |
isParameter('action', 'edit')-> | |
end()->info('now admin can fill the form elements for the content type, but he forgives to fill the required ones')-> | |
click('Save', array('qredd_content' => array( | |
'content_type_id' => 1, | |
'title' => 'Content sample', | |
'aggregator_id' => '0', | |
'is_active' => true, | |
)))-> | |
with('request')->begin()-> | |
isParameter('module', 'content')-> | |
isParameter('action', 'update')-> | |
end()-> | |
with('form')->begin()->info('form is good')-> | |
hasErrors(true)-> | |
isError('Sample link', 'value [required]')-> | |
isError('Sample text', 'value [required]')-> | |
isError('Sample textarea', 'value [required]')-> | |
isError('Sample fancytextarea', 'value [required]')-> | |
isError('Sample checkbox', 'value [required]')-> | |
isError('Sample tweet', 'value [required]')-> | |
end()-> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment