@@ -21,7 +21,7 @@ import (
21
21
"time"
22
22
23
23
"github.com/go-openapi/strfmt"
24
- "github.com/go-openapi/swag"
24
+ "github.com/go-openapi/swag/conv "
25
25
"github.com/sigstore/rekor/pkg/generated/models"
26
26
)
27
27
@@ -34,24 +34,24 @@ func TestRekorBundle(t *testing.T) {
34
34
name : "tlog entry without verification - nil bundle" ,
35
35
logEntry : & models.LogEntryAnon {
36
36
Body : base64 .StdEncoding .EncodeToString ([]byte ("TEST" )),
37
- IntegratedTime : swag . Int64 (time .Now ().Unix ()),
38
- LogIndex : swag . Int64 ( 0 ),
39
- LogID : swag . String ("c0d23d6ad406973f9559f3ba2d1ca01f84147d8ffc5b8445c224f98b9591801d" ),
37
+ IntegratedTime : conv . Pointer (time .Now ().Unix ()),
38
+ LogIndex : conv . Pointer ( int64 ( 0 ) ),
39
+ LogID : conv . Pointer ("c0d23d6ad406973f9559f3ba2d1ca01f84147d8ffc5b8445c224f98b9591801d" ),
40
40
},
41
41
expectedRekorBundle : nil ,
42
42
}, {
43
43
name : "tlog entry with verification" ,
44
44
logEntry : & models.LogEntryAnon {
45
45
Body : base64 .StdEncoding .EncodeToString ([]byte ("TEST" )),
46
- IntegratedTime : swag . Int64 (time .Now ().Unix ()),
47
- LogIndex : swag . Int64 ( 0 ),
48
- LogID : swag . String ("c0d23d6ad406973f9559f3ba2d1ca01f84147d8ffc5b8445c224f98b9591801d" ),
46
+ IntegratedTime : conv . Pointer (time .Now ().Unix ()),
47
+ LogIndex : conv . Pointer ( int64 ( 0 ) ),
48
+ LogID : conv . Pointer ("c0d23d6ad406973f9559f3ba2d1ca01f84147d8ffc5b8445c224f98b9591801d" ),
49
49
Verification : & models.LogEntryAnonVerification {
50
50
SignedEntryTimestamp : strfmt .Base64 ([]byte ("signature" )),
51
51
InclusionProof : & models.InclusionProof {
52
- LogIndex : swag . Int64 ( 0 ),
53
- TreeSize : swag . Int64 ( 1 ),
54
- RootHash : swag . String ("TEST" ),
52
+ LogIndex : conv . Pointer ( int64 ( 0 ) ),
53
+ TreeSize : conv . Pointer ( int64 ( 1 ) ),
54
+ RootHash : conv . Pointer ("TEST" ),
55
55
Hashes : []string {},
56
56
},
57
57
},
0 commit comments