Esempio n. 1
0
 /**
  * Test if the ->getRelation function returns the same as the RelationQuery object.
  * 
  * @return void
  */
 public function testGetRelationReturnsRelationQueryValue()
 {
     $query = 'valid:relation';
     $this->assertEquals(RelationQuery::make($query), (new Inquiry('key', $query))->getRelation());
 }
Esempio n. 2
0
 /**
  * Test if the value is available.
  * 
  * @return void
  */
 public function testValueIsAvailable()
 {
     $query = RelationQuery::make('relation:value');
     $this->assertSame('value', $query->getValue());
 }
Esempio n. 3
0
 /**
  * Get the relation data from the query.
  * 
  * @return \Bycedric\Inquiry\Queries\RelationQuery
  */
 public function getRelation()
 {
     return RelationQuery::make($this->value);
 }