Example #1
0
 public function testStruct_Read()
 {
     $this->transport->write(TestTJSONProtocol_Fixtures::$testArgsJSON['testStruct']);
     $args = new \ThriftTest\ThriftTest_testStruct_args();
     $args->read($this->protocol);
     $actual = $args->thing;
     $expected = Fixtures::$testArgs['testStruct'];
     $this->assertEquals($expected, $actual);
 }
 public function testStruct_Write()
 {
     $args = new \ThriftTest\ThriftTest_testStruct_args();
     $args->thing = Fixtures::$testArgs['testStruct'];
     $args->write($this->protocol);
     $actual = $this->transport->read(BUFSIZ);
     $expected = TestTSimpleJSONProtocol_Fixtures::$testArgsJSON['testStruct'];
     $this->assertEquals($expected, $actual);
 }