示例#1
0
 /**
  * @Given /^I manage registrations for the event "([^"]*)"$/
  */
 public function iManageRegistrationsForTheEvent($event)
 {
     $event_id = FeatureHelp::getNodeId($event);
     return array(new Step\When('I visit "john/node/' . $event_id . '/registrations"'));
 }
示例#2
0
 /**
  * @Given /^I try to post a "([^"]*)" as "([^"]*)" to "([^"]*)"$/
  */
 public function iTryToPostAAsTo($type, $account, $group)
 {
     $gid = FeatureHelp::getNodeId($group);
     $values = ['label' => 'Test', 'body' => 'Test ' . $type, 'vsite' => $gid];
     try {
         $this->invokeRestRequest('post', $this->locatePath($this->endpoints[$type]), ['access_token' => $this->restLogin($account)], $values);
         $this->meta['passed'] = TRUE;
     } catch (\Exception $e) {
         $this->meta['passed'] = FALSE;
     }
 }