@@ -41,20 +41,20 @@ func TestVersion(t *testing.T) {
41
41
42
42
type testParser struct {}
43
43
44
- func (t * testParser ) Encode (ctx context.Context , input string ) (output string , outputIsError bool , err error ) {
44
+ func (t * testParser ) Encode (ctx context.Context , input string ) (pid int , output string , outputIsError bool , err error ) {
45
45
switch input {
46
46
case `a=1` :
47
- return `{"a": {"type":"integer","value":"1"}}` , false , nil
47
+ return 42 , `{"a": {"type":"integer","value":"1"}}` , false , nil
48
48
case `a=` , `c=` :
49
- return `oh noes: error one` , true , nil
49
+ return 42 , `oh noes: error one` , true , nil
50
50
case `b=` :
51
- return `error two` , true , nil
51
+ return 42 , `error two` , true , nil
52
52
default :
53
53
panic (fmt .Sprintf ("unreachable: %q" , input ))
54
54
}
55
55
}
56
56
57
- func (t testParser ) Decode (ctx context.Context , input string ) (string , bool , error ) {
57
+ func (t testParser ) Decode (ctx context.Context , input string ) (int , string , bool , error ) {
58
58
return t .Encode (ctx , input )
59
59
}
60
60
0 commit comments