@@ -43,16 +43,16 @@ func TestListDomain(t *testing.T) {
4343 Name : "capacity" ,
4444 Unit : limes .UnitBytes ,
4545 },
46- DomainQuota : p2ui64 ( 10 ),
47- ProjectsQuota : p2ui64 ( 5 ),
46+ DomainQuota : new ( uint64 ( 10 ) ),
47+ ProjectsQuota : new ( uint64 ( 5 ) ),
4848 Usage : 2 ,
4949 },
5050 "things" : & limesresources.DomainResourceReport {
5151 ResourceInfo : limesresources.ResourceInfo {
5252 Name : "things" ,
5353 },
54- DomainQuota : p2ui64 ( 10 ),
55- ProjectsQuota : p2ui64 ( 5 ),
54+ DomainQuota : new ( uint64 ( 10 ) ),
55+ ProjectsQuota : new ( uint64 ( 5 ) ),
5656 Usage : 2 ,
5757 },
5858 },
@@ -70,16 +70,16 @@ func TestListDomain(t *testing.T) {
7070 Name : "capacity" ,
7171 Unit : limes .UnitBytes ,
7272 },
73- DomainQuota : p2ui64 ( 55 ),
74- ProjectsQuota : p2ui64 ( 25 ),
73+ DomainQuota : new ( uint64 ( 55 ) ),
74+ ProjectsQuota : new ( uint64 ( 25 ) ),
7575 Usage : 10 ,
7676 },
7777 "things" : & limesresources.DomainResourceReport {
7878 ResourceInfo : limesresources.ResourceInfo {
7979 Name : "things" ,
8080 },
81- DomainQuota : p2ui64 ( 55 ),
82- ProjectsQuota : p2ui64 ( 25 ),
81+ DomainQuota : new ( uint64 ( 55 ) ),
82+ ProjectsQuota : new ( uint64 ( 25 ) ),
8383 Usage : 10 ,
8484 },
8585 },
@@ -105,16 +105,16 @@ func TestListDomain(t *testing.T) {
105105 Name : "capacity" ,
106106 Unit : limes .UnitBytes ,
107107 },
108- DomainQuota : p2ui64 ( 10 ),
109- ProjectsQuota : p2ui64 ( 5 ),
108+ DomainQuota : new ( uint64 ( 10 ) ),
109+ ProjectsQuota : new ( uint64 ( 5 ) ),
110110 Usage : 2 ,
111111 },
112112 "things" : & limesresources.DomainResourceReport {
113113 ResourceInfo : limesresources.ResourceInfo {
114114 Name : "things" ,
115115 },
116- DomainQuota : p2ui64 ( 10 ),
117- ProjectsQuota : p2ui64 ( 5 ),
116+ DomainQuota : new ( uint64 ( 10 ) ),
117+ ProjectsQuota : new ( uint64 ( 5 ) ),
118118 Usage : 2 ,
119119 },
120120 },
@@ -132,8 +132,8 @@ func TestListDomain(t *testing.T) {
132132 Name : "capacity" ,
133133 Unit : limes .UnitBytes ,
134134 },
135- DomainQuota : p2ui64 ( 55 ),
136- ProjectsQuota : p2ui64 ( 25 ),
135+ DomainQuota : new ( uint64 ( 55 ) ),
136+ ProjectsQuota : new ( uint64 ( 25 ) ),
137137 Usage : 10 ,
138138 BackendQuota : & backendQ ,
139139 InfiniteBackendQuota : & infiniteBackendQ ,
@@ -142,8 +142,8 @@ func TestListDomain(t *testing.T) {
142142 ResourceInfo : limesresources.ResourceInfo {
143143 Name : "things" ,
144144 },
145- DomainQuota : p2ui64 ( 55 ),
146- ProjectsQuota : p2ui64 ( 25 ),
145+ DomainQuota : new ( uint64 ( 55 ) ),
146+ ProjectsQuota : new ( uint64 ( 25 ) ),
147147 Usage : 10 ,
148148 },
149149 },
@@ -184,8 +184,8 @@ func TestListFilteredDomain(t *testing.T) {
184184 ResourceInfo : limesresources.ResourceInfo {
185185 Name : "things" ,
186186 },
187- DomainQuota : p2ui64 ( 10 ),
188- ProjectsQuota : p2ui64 ( 5 ),
187+ DomainQuota : new ( uint64 ( 10 ) ),
188+ ProjectsQuota : new ( uint64 ( 5 ) ),
189189 Usage : 2 ,
190190 },
191191 },
@@ -210,8 +210,8 @@ func TestListFilteredDomain(t *testing.T) {
210210 ResourceInfo : limesresources.ResourceInfo {
211211 Name : "things" ,
212212 },
213- DomainQuota : p2ui64 ( 10 ),
214- ProjectsQuota : p2ui64 ( 5 ),
213+ DomainQuota : new ( uint64 ( 10 ) ),
214+ ProjectsQuota : new ( uint64 ( 5 ) ),
215215 Usage : 2 ,
216216 },
217217 },
@@ -249,16 +249,16 @@ func TestGetDomain(t *testing.T) {
249249 Name : "capacity" ,
250250 Unit : limes .UnitBytes ,
251251 },
252- DomainQuota : p2ui64 ( 10 ),
253- ProjectsQuota : p2ui64 ( 5 ),
252+ DomainQuota : new ( uint64 ( 10 ) ),
253+ ProjectsQuota : new ( uint64 ( 5 ) ),
254254 Usage : 2 ,
255255 },
256256 "things" : & limesresources.DomainResourceReport {
257257 ResourceInfo : limesresources.ResourceInfo {
258258 Name : "things" ,
259259 },
260- DomainQuota : p2ui64 ( 10 ),
261- ProjectsQuota : p2ui64 ( 5 ),
260+ DomainQuota : new ( uint64 ( 10 ) ),
261+ ProjectsQuota : new ( uint64 ( 5 ) ),
262262 Usage : 2 ,
263263 },
264264 },
@@ -276,16 +276,16 @@ func TestGetDomain(t *testing.T) {
276276 Name : "capacity" ,
277277 Unit : limes .UnitBytes ,
278278 },
279- DomainQuota : p2ui64 ( 55 ),
280- ProjectsQuota : p2ui64 ( 25 ),
279+ DomainQuota : new ( uint64 ( 55 ) ),
280+ ProjectsQuota : new ( uint64 ( 25 ) ),
281281 Usage : 10 ,
282282 },
283283 "things" : & limesresources.DomainResourceReport {
284284 ResourceInfo : limesresources.ResourceInfo {
285285 Name : "things" ,
286286 },
287- DomainQuota : p2ui64 ( 55 ),
288- ProjectsQuota : p2ui64 ( 25 ),
287+ DomainQuota : new ( uint64 ( 55 ) ),
288+ ProjectsQuota : new ( uint64 ( 25 ) ),
289289 Usage : 10 ,
290290 },
291291 },
@@ -324,8 +324,8 @@ func TestGetDomainFiltered(t *testing.T) {
324324 ResourceInfo : limesresources.ResourceInfo {
325325 Name : "things" ,
326326 },
327- DomainQuota : p2ui64 ( 10 ),
328- ProjectsQuota : p2ui64 ( 5 ),
327+ DomainQuota : new ( uint64 ( 10 ) ),
328+ ProjectsQuota : new ( uint64 ( 5 ) ),
329329 Usage : 2 ,
330330 },
331331 },
@@ -341,7 +341,3 @@ func p2time(timestamp int64) *limes.UnixEncodedTime {
341341 t := limes.UnixEncodedTime {Time : time .Unix (timestamp , 0 ).UTC ()}
342342 return & t
343343}
344-
345- func p2ui64 (x uint64 ) * uint64 {
346- return & x
347- }
0 commit comments