@@ -21,8 +21,8 @@ class TestEntry {
2121 private Entry entry ;
2222 private final String CONTENT_TYPE = Credentials .CONTENT_TYPE ;
2323 private final String VARIANT_UID = Credentials .VARIANT_UID ;
24- private static final String [] VARIANT_UIDS = Credentials .VARIANTS_UID ;
25-
24+ private static final String [] VARIANT_UIDS = Credentials .VARIANTS_UID ;
25+
2626 @ Test
2727 @ Order (1 )
2828 void entryCallingPrivateModifier () {
@@ -68,68 +68,22 @@ public void onCompletion(ResponseType responseType, Error error) {
6868 }
6969 @ Test
7070 void VariantsTestSingleUid (){
71- entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants (" cs672c33271558d8b0 " );
72- entry .fetch (new EntryResultCallBack () {
73- @ Override
74- public void onCompletion (ResponseType responseType , Error error ) {
75- assertEquals ("cs672c33271558d8b0" , entry .getHeaders ().get ("x-cs-variant-uid" ));
76- System .out .println (entry .toJSON ());
77- }
78- });
79- }
80- @ Test
81- void VariantsTestArray (){
82- entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants (new String []{" cs672c33271558d8b0" ," cs321fbc07ec71861b" ," cs321fbc07ec71861b " });
83- entry .fetch (new EntryResultCallBack () {
84- @ Override
85- public void onCompletion (ResponseType responseType , Error error ) {
86- System .out .println (entry .toJSON ());
87- }
88- });
89- }
90-
91- @ Test
92- void VariantsTestArrayWithMixedElements () {
93- entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants (new String []{"" , " cs672c33271558d8b0 " , null , " " });
94- entry .fetch (new EntryResultCallBack () {
95- @ Override
96- public void onCompletion (ResponseType responseType , Error error ) {
97- System .out .println (entry .toJSON ());
98- }
99- });
100- }
101-
102- @ Test
103- void VariantsTestNullString () {
104- entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants ((String ) null );
105- entry .fetch (new EntryResultCallBack () {
106- @ Override
107- public void onCompletion (ResponseType responseType , Error error ) {
108- assertNull (entry .getHeaders ().get ("x-cs-variant-uid" ));
109- System .out .println (entry .toJSON ());
110- }
111- });
112- }
113-
114- @ Test
115- void VariantsTestSingleUid () {
11671 entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants (VARIANT_UID );
11772 entry .fetch (new EntryResultCallBack () {
11873 @ Override
11974 public void onCompletion (ResponseType responseType , Error error ) {
12075 assertEquals (VARIANT_UID .trim (), entry .getHeaders ().get ("x-cs-variant-uid" ));
121- System .out .println (entry .toJSON ());
76+ System .out .println (entry .toJSON ());
12277 }
12378 });
12479 }
125-
12680 @ Test
127- void VariantsTestArray () {
81+ void VariantsTestArray (){
12882 entry = stack .contentType (CONTENT_TYPE ).entry (entryUid ).variants (VARIANT_UIDS );
12983 entry .fetch (new EntryResultCallBack () {
13084 @ Override
13185 public void onCompletion (ResponseType responseType , Error error ) {
132- System .out .println (entry .toJSON ());
86+ System .out .println (entry .toJSON ());
13387 }
13488 });
13589 }
0 commit comments