@@ -15,6 +15,8 @@ public struct AbtestingV3ABTest: Codable, JSONEncodable {
15
15
public var createdAt : String
16
16
/// End date and time of the A/B test, in RFC 3339 format.
17
17
public var endAt : String
18
+ /// Date and time when the A/B test was stopped, in RFC 3339 format.
19
+ public var stoppedAt : String ?
18
20
/// A/B test name.
19
21
public var name : String
20
22
public var status : AbtestingV3Status
@@ -30,6 +32,7 @@ public struct AbtestingV3ABTest: Codable, JSONEncodable {
30
32
updatedAt: String ,
31
33
createdAt: String ,
32
34
endAt: String ,
35
+ stoppedAt: String ? = nil ,
33
36
name: String ,
34
37
status: AbtestingV3Status ,
35
38
variants: [ AbtestingV3Variant ] ,
@@ -40,6 +43,7 @@ public struct AbtestingV3ABTest: Codable, JSONEncodable {
40
43
self . updatedAt = updatedAt
41
44
self . createdAt = createdAt
42
45
self . endAt = endAt
46
+ self . stoppedAt = stoppedAt
43
47
self . name = name
44
48
self . status = status
45
49
self . variants = variants
@@ -52,6 +56,7 @@ public struct AbtestingV3ABTest: Codable, JSONEncodable {
52
56
case updatedAt
53
57
case createdAt
54
58
case endAt
59
+ case stoppedAt
55
60
case name
56
61
case status
57
62
case variants
@@ -67,6 +72,7 @@ public struct AbtestingV3ABTest: Codable, JSONEncodable {
67
72
try container. encode ( self . updatedAt, forKey: . updatedAt)
68
73
try container. encode ( self . createdAt, forKey: . createdAt)
69
74
try container. encode ( self . endAt, forKey: . endAt)
75
+ try container. encodeIfPresent ( self . stoppedAt, forKey: . stoppedAt)
70
76
try container. encode ( self . name, forKey: . name)
71
77
try container. encode ( self . status, forKey: . status)
72
78
try container. encode ( self . variants, forKey: . variants)
@@ -81,6 +87,7 @@ extension AbtestingV3ABTest: Equatable {
81
87
lhs. updatedAt == rhs. updatedAt &&
82
88
lhs. createdAt == rhs. createdAt &&
83
89
lhs. endAt == rhs. endAt &&
90
+ lhs. stoppedAt == rhs. stoppedAt &&
84
91
lhs. name == rhs. name &&
85
92
lhs. status == rhs. status &&
86
93
lhs. variants == rhs. variants &&
@@ -95,6 +102,7 @@ extension AbtestingV3ABTest: Hashable {
95
102
hasher. combine ( self . updatedAt. hashValue)
96
103
hasher. combine ( self . createdAt. hashValue)
97
104
hasher. combine ( self . endAt. hashValue)
105
+ hasher. combine ( self . stoppedAt? . hashValue)
98
106
hasher. combine ( self . name. hashValue)
99
107
hasher. combine ( self . status. hashValue)
100
108
hasher. combine ( self . variants. hashValue)
0 commit comments