setIdentifier('testIdentifier') ->setCardinality('single') ->setBaseType('testBaseType') ->setEpoch('testEpoch') ->setCorrectResponse('testCorrectResponse') ->setCandidateResponse('testCandidateResponse'); $this->assertSame(json_encode([ 'identifier' => 'testIdentifier', 'cardinality' => 'single', 'baseType' => 'testBaseType', 'epoch' => 'testEpoch', 'type' => \taoResultServer_models_classes_ResponseVariable::TYPE, 'correctResponse' => 'testCorrectResponse', 'candidateResponse' => base64_encode('testCandidateResponse'), ]), json_encode($subject)); } }