Example #1
0
 public function testCannotUseNullTextForScoring()
 {
     // setup
     $client = new Client($this->_apiKey);
     $text = null;
     $caughtException = false;
     // do the test
     try {
         $score = $client->callScoreForText($text);
     } catch (\Exception $e) {
         $caughtException = true;
     }
     // evaluate result here
     $this->assertTrue($caughtException);
 }