@@ -51,14 +51,14 @@ func (r *RowSuite) TestWriteStruct(c *C) {
51
51
testStringerImpl {"Stringer" },
52
52
& testStringerImpl {"Pointer to Stringer" },
53
53
time .Unix (0 , 0 ),
54
- sql.NullString {`Smith` , true },
55
- sql.NullBool {false , true },
56
- sql.NullInt64 {100 , true },
57
- sql.NullFloat64 {0.123 , true },
58
- sql.NullString {`What ever` , false },
59
- sql.NullBool {true , false },
60
- sql.NullInt64 {100 , false },
61
- sql.NullFloat64 {0.123 , false },
54
+ sql.NullString {String : `Smith` , Valid : true },
55
+ sql.NullBool {Bool : false , Valid : true },
56
+ sql.NullInt64 {Int64 : 100 , Valid : true },
57
+ sql.NullFloat64 {Float64 : 0.123 , Valid : true },
58
+ sql.NullString {String : `What ever` , Valid : false },
59
+ sql.NullBool {Bool : true , Valid : false },
60
+ sql.NullInt64 {Int64 : 100 , Valid : false },
61
+ sql.NullFloat64 {Float64 : 0.123 , Valid : false },
62
62
}
63
63
cnt := row .WriteStruct (& testStruct , - 1 )
64
64
c .Assert (cnt , Equals , 15 )
@@ -234,7 +234,7 @@ func (r *RowSuite) TestWriteSlice(c *C) {
234
234
s7_ret = row7 .WriteSlice ([]string {s7 }, - 1 )
235
235
c .Assert (s7_ret , Equals , - 1 )
236
236
237
- s8 := nullStringA {sql.NullString {"Smith" , true }, sql.NullString {`What ever` , false }}
237
+ s8 := nullStringA {sql.NullString {String : "Smith" , Valid : true }, sql.NullString {String : `What ever` , Valid : false }}
238
238
row8 := sheet .AddRow ()
239
239
row8 .WriteSlice (& s8 , - 1 )
240
240
c .Assert (row8 , NotNil )
@@ -252,7 +252,7 @@ func (r *RowSuite) TestWriteSlice(c *C) {
252
252
c .Assert (val2 , Equals , "" )
253
253
}
254
254
255
- s9 := nullBoolA {sql.NullBool {false , true }, sql.NullBool {true , false }}
255
+ s9 := nullBoolA {sql.NullBool {Bool : false , Valid : true }, sql.NullBool {Bool : true , Valid : false }}
256
256
row9 := sheet .AddRow ()
257
257
row9 .WriteSlice (& s9 , - 1 )
258
258
c .Assert (row9 , NotNil )
@@ -261,7 +261,7 @@ func (r *RowSuite) TestWriteSlice(c *C) {
261
261
c .Assert (c9 , Equals , false )
262
262
c .Assert (c9Null , Equals , "" )
263
263
264
- s10 := nullIntA {sql.NullInt64 {100 , true }, sql.NullInt64 {100 , false }}
264
+ s10 := nullIntA {sql.NullInt64 {Int64 : 100 , Valid : true }, sql.NullInt64 {Int64 : 100 , Valid : false }}
265
265
row10 := sheet .AddRow ()
266
266
row10 .WriteSlice (& s10 , - 1 )
267
267
c .Assert (row10 , NotNil )
@@ -272,7 +272,7 @@ func (r *RowSuite) TestWriteSlice(c *C) {
272
272
c .Assert (e10Null , Equals , nil )
273
273
c .Assert (c10Null , Equals , "" )
274
274
275
- s11 := nullFloatA {sql.NullFloat64 {0.123 , true }, sql.NullFloat64 {0.123 , false }}
275
+ s11 := nullFloatA {sql.NullFloat64 {Float64 : 0.123 , Valid : true }, sql.NullFloat64 {Float64 : 0.123 , Valid : false }}
276
276
row11 := sheet .AddRow ()
277
277
row11 .WriteSlice (& s11 , - 1 )
278
278
c .Assert (row11 , NotNil )
0 commit comments