@@ -66,6 +66,8 @@ public void testToImmutableTableConflict() {
66
66
.collect (collector ));
67
67
}
68
68
69
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when rowFunction result (null) is unboxed
70
+ @ J2ktIncompatible
69
71
public void testToImmutableTableNullRowKey () {
70
72
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >> collector =
71
73
toImmutableTable (t -> null , Cell ::getColumnKey , Cell ::getValue );
@@ -74,6 +76,9 @@ public void testToImmutableTableNullRowKey() {
74
76
() -> Stream .of (immutableCell ("one" , "uno" , 1 )).collect (collector ));
75
77
}
76
78
79
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when columnFunction result (null) is
80
+ // unboxed
81
+ @ J2ktIncompatible
77
82
public void testToImmutableTableNullColumnKey () {
78
83
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >> collector =
79
84
toImmutableTable (Cell ::getRowKey , t -> null , Cell ::getValue );
@@ -82,6 +87,8 @@ public void testToImmutableTableNullColumnKey() {
82
87
() -> Stream .of (immutableCell ("one" , "uno" , 1 )).collect (collector ));
83
88
}
84
89
90
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when getValue result (null) is unboxed
91
+ @ J2ktIncompatible
85
92
public void testToImmutableTableNullValue () {
86
93
{
87
94
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >>
@@ -119,6 +126,8 @@ public void testToImmutableTableMerging() {
119
126
immutableCell ("two" , "dos" , 4 ));
120
127
}
121
128
129
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when rowFunction result (null) is unboxed
130
+ @ J2ktIncompatible
122
131
public void testToImmutableTableMergingNullRowKey () {
123
132
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >> collector =
124
133
toImmutableTable (t -> null , Cell ::getColumnKey , Cell ::getValue , Integer ::sum );
@@ -127,6 +136,9 @@ public void testToImmutableTableMergingNullRowKey() {
127
136
() -> Stream .of (immutableCell ("one" , "uno" , 1 )).collect (collector ));
128
137
}
129
138
139
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when columnFunction result (null) is
140
+ // unboxed
141
+ @ J2ktIncompatible
130
142
public void testToImmutableTableMergingNullColumnKey () {
131
143
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >> collector =
132
144
toImmutableTable (Cell ::getRowKey , t -> null , Cell ::getValue , Integer ::sum );
@@ -135,6 +147,9 @@ public void testToImmutableTableMergingNullColumnKey() {
135
147
() -> Stream .of (immutableCell ("one" , "uno" , 1 )).collect (collector ));
136
148
}
137
149
150
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when valueFunction result (null) is
151
+ // unboxed
152
+ @ J2ktIncompatible
138
153
public void testToImmutableTableMergingNullValue () {
139
154
{
140
155
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >>
@@ -160,6 +175,9 @@ public void testToImmutableTableMergingNullValue() {
160
175
}
161
176
}
162
177
178
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when mergeFunction result (null) is
179
+ // unboxed
180
+ @ J2ktIncompatible
163
181
public void testToImmutableTableMergingNullMerge () {
164
182
Collector <Cell <String , String , Integer >, ?, ImmutableTable <String , String , Integer >> collector =
165
183
toImmutableTable (Cell ::getRowKey , Cell ::getColumnKey , Cell ::getValue , (v1 , v2 ) -> null );
@@ -188,6 +206,9 @@ public void testToTable() {
188
206
immutableCell ("three" , "tres" , 3 ));
189
207
}
190
208
209
+ // https://youtrack.jetbrains.com/issue/KT-58242/. Crash when mergeFunction result (null) is
210
+ // unboxed
211
+ @ J2ktIncompatible
191
212
public void testToTableNullMerge () {
192
213
// TODO github.com/google/guava/issues/6824 - the null merge feature is not compatible with the
193
214
// current nullness annotation of the mergeFunction parameter. Work around with casts.
0 commit comments