This is an automated email from the ASF dual-hosted git repository.

jensg pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/thrift.git

commit 85d8162dcbfd17db3bb8232a2dbb870dd9908cc4
Author: Jens Geyer <[email protected]>
AuthorDate: Thu Oct 10 01:33:30 2019 +0200

    Revert "THRIFT-4951: Remove senum from tests"
    
    This reverts commit df8ef4b489e2b84ac6dbbf895be32d6fb2415c81.
    
    The contributor confuses "deprecated" with "unsupported". Unless the 
feature as a whole is also removed, so essentially nothing is left to be 
tested. Regardless whether a particular feature is deprecated or not, removing 
a working test for it is NOT helpful. The only "achievement" of such efforts 
would be that the test coverage goes down, which is clearly not in our 
intention and only opens room for bugs and issues.
---
 test/AnnotationTest.thrift | 8 ++++++++
 test/SmallTest.thrift      | 7 +++++++
 2 files changed, 15 insertions(+)

diff --git a/test/AnnotationTest.thrift b/test/AnnotationTest.thrift
index 6238395..7e24e1c 100644
--- a/test/AnnotationTest.thrift
+++ b/test/AnnotationTest.thrift
@@ -49,6 +49,14 @@ enum weekdays {
   SATURDAY ( weekend = "yes" )
 } (foo.bar="baz")
 
+/* Note that annotations on senum values are not supported. */
+senum seasons {
+  "Spring",
+  "Summer",
+  "Fall",
+  "Winter"
+} ( foo = "bar" )
+
 struct ostr_default {
   1: i32 bar;
 }
diff --git a/test/SmallTest.thrift b/test/SmallTest.thrift
index 891bd6a..d0821c7 100644
--- a/test/SmallTest.thrift
+++ b/test/SmallTest.thrift
@@ -24,6 +24,12 @@ struct Goodbyez {
   1: i32 val = 325;
 }
 
+senum Thinger {
+  "ASDFKJ",
+  "r32)*F#@",
+  "ASDFLJASDF"
+}
+
 struct BoolPasser {
   1: bool value = 1
 }
@@ -47,6 +53,7 @@ exception Goodbye {
 }
 
 service SmallService {
+  Thinger testThinger(1:Thinger bootz),
   Hello testMe(1:i32 hello=64, 2: Hello wonk) throws (1: Goodbye g),
   void testVoid() throws (1: Goodbye g),
   i32 testI32(1:i32 boo)

Reply via email to