Skip to content

Instantly share code, notes, and snippets.

@jec006
Created July 3, 2012 21:48
Show Gist options
  • Save jec006/3043557 to your computer and use it in GitHub Desktop.
Save jec006/3043557 to your computer and use it in GitHub Desktop.
How do I test this
<?php
//Basic condition should construct the correct widget and properly get its form
$test_widget = new \Drupal\sps\Test\Widget(array(), $manager);
$state = array();
$widget = $test_widget->getPreviewForm(array(), $state);
$state = array();
$element = $condition->getElement(array(), $state);
$this->assertEqual($subelement, $widget,
'BasicCondition should construct the correct widget from the settings and properly return its form.');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment