[ 
https://issues.apache.org/jira/browse/THRIFT-2886?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jens Geyer updated THRIFT-2886:
-------------------------------
    Description: 
I propose to complete the half-hearted try to integrate the {{binary}} type 
into the test suite. We actually have a {{CrazyNesting}} struct defined, yet 
that structure is not used in any call. So we do test the code generation 
vis-á-vis compileability, but we do not test whether or not the impleemntation 
actually works. 

Background info: 
http://stackoverflow.com/questions/27408710/python-thrift-binary-type-requires-encoding

*Spec proposal:*

{code}
  /**
   * Prints 'testBinary("%s")' where '%s' is a hex-formatted string of thing's 
data
   * @param binary  thing - the binary data to print
   * @return binary  - returns the binary 'thing'
   */
  binary testBinary(1: binary thing),
{code}

*Test case proposal:*
The client sends a binary containing all 256 bytes (in arbitrary order) to the 
server and checks the returned binary data against the value sent to the 
server. If they do match exactly, the test counts as passed.




  was:
I propose to complete the half-hearted try to integrate the {{binary}} type 
into the test suite. We actually have a {{CrazyNesting}} struct defined, yet 
that structure is not used in any call. So we do test the code generation 
vis-á-vis compileability, but we do not test whether or not the impleemntation 
actually works. 

Background info: 
http://stackoverflow.com/questions/27408710/python-thrift-binary-type-requires-encoding



> Integrate binary type in standard Thrift cross test
> ---------------------------------------------------
>
>                 Key: THRIFT-2886
>                 URL: https://issues.apache.org/jira/browse/THRIFT-2886
>             Project: Thrift
>          Issue Type: Sub-task
>          Components: Test Suite
>            Reporter: Jens Geyer
>
> I propose to complete the half-hearted try to integrate the {{binary}} type 
> into the test suite. We actually have a {{CrazyNesting}} struct defined, yet 
> that structure is not used in any call. So we do test the code generation 
> vis-á-vis compileability, but we do not test whether or not the 
> impleemntation actually works. 
> Background info: 
> http://stackoverflow.com/questions/27408710/python-thrift-binary-type-requires-encoding
> *Spec proposal:*
> {code}
>   /**
>    * Prints 'testBinary("%s")' where '%s' is a hex-formatted string of 
> thing's data
>    * @param binary  thing - the binary data to print
>    * @return binary  - returns the binary 'thing'
>    */
>   binary testBinary(1: binary thing),
> {code}
> *Test case proposal:*
> The client sends a binary containing all 256 bytes (in arbitrary order) to 
> the server and checks the returned binary data against the value sent to the 
> server. If they do match exactly, the test counts as passed.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to