@@ -45,7 +45,7 @@ class AssetQueryAPITest: XCTestCase {
4545 ( stack. urlSession as? DVR . Session) ? . endRecording ( )
4646 }
4747
48- func test01FindAll_AssetQuery( ) {
48+ func test01FindAll_AssetQuery( ) async {
4949 let networkExpectation = expectation ( description: " Fetch All Assets Test " )
5050 self . getAssetQuery ( ) . locale ( " en-us " ) . find { ( result: Result < ContentstackResponse < AssetModel > , Error > , response: ResponseType ) in
5151 switch result {
@@ -64,7 +64,7 @@ class AssetQueryAPITest: XCTestCase {
6464 wait ( for: [ networkExpectation] , timeout: 30 )
6565 }
6666
67- func test02Find_AssetQuery_whereUIDEquals( ) {
67+ func test02Find_AssetQuery_whereUIDEquals( ) async {
6868 let networkExpectation = expectation ( description: " Fetch where UID equals Assets Test " )
6969 self . queryWhere ( . uid, operation: . equals( AssetQueryAPITest . kAssetUID) ) { ( result: Result < ContentstackResponse < AssetModel > , Error > ) in
7070 switch result {
@@ -80,7 +80,7 @@ class AssetQueryAPITest: XCTestCase {
8080 wait ( for: [ networkExpectation] , timeout: 30 )
8181 }
8282
83- func test03Find_AssetQuery_whereTitleDNotEquals( ) {
83+ func test03Find_AssetQuery_whereTitleDNotEquals( ) async {
8484 let networkExpectation = expectation ( description: " Fetch where Title equals Assets Test " )
8585 self . queryWhere ( . title, operation: . notEquals( AssetQueryAPITest . kAssetTitle) ) { ( result: Result < ContentstackResponse < AssetModel > , Error > ) in
8686 switch result {
@@ -96,7 +96,7 @@ class AssetQueryAPITest: XCTestCase {
9696 wait ( for: [ networkExpectation] , timeout: 30 )
9797 }
9898
99- func test03Find_AssetQuery_whereFileNameEquals( ) {
99+ func test03Find_AssetQuery_whereFileNameEquals( ) async {
100100 let networkExpectation = expectation ( description: " Fetch where Title equals Assets Test " )
101101 self . queryWhere ( . fileName, operation: . notEquals( AssetQueryAPITest . kFileName) ) { ( result: Result < ContentstackResponse < AssetModel > , Error > ) in
102102 switch result {
@@ -112,7 +112,7 @@ class AssetQueryAPITest: XCTestCase {
112112 wait ( for: [ networkExpectation] , timeout: 30 )
113113 }
114114
115- func test04Find_AssetQuery_whereFileNameexists( ) {
115+ func test04Find_AssetQuery_whereFileNameexists( ) async {
116116 let networkExpectation = expectation ( description: " Fetch where fileName exists Assets Test " )
117117 self . queryWhere ( . fileName, operation: . exists( true ) ) { ( result: Result < ContentstackResponse < AssetModel > , Error > ) in
118118 switch result {
@@ -126,7 +126,7 @@ class AssetQueryAPITest: XCTestCase {
126126 wait ( for: [ networkExpectation] , timeout: 30 )
127127 }
128128
129- func test05Find_AssetQuery_whereTitleMatchRegex( ) {
129+ func test05Find_AssetQuery_whereTitleMatchRegex( ) async {
130130 let networkExpectation = expectation ( description: " Fetch where Title Match Regex Assets Test " )
131131 self . queryWhere ( . title, operation: . matches( " im " ) ) { ( result: Result < ContentstackResponse < AssetModel > , Error > ) in
132132 switch result {
@@ -140,7 +140,7 @@ class AssetQueryAPITest: XCTestCase {
140140 wait ( for: [ networkExpectation] , timeout: 30 )
141141 }
142142
143- func test06Fetch_Asset_fromUID( ) {
143+ func test06Fetch_Asset_fromUID( ) async {
144144 let networkExpectation = expectation ( description: " Fetch Assets from UID Test " )
145145 self . getAsset ( uid: AssetQueryAPITest . kAssetUID) . fetch { ( result: Result < AssetModel , Error > , response: ResponseType ) in
146146 switch result {
@@ -154,7 +154,7 @@ class AssetQueryAPITest: XCTestCase {
154154 wait ( for: [ networkExpectation] , timeout: 30 )
155155 }
156156
157- func test07Fetch_AssetQuery_WithDimentsions( ) {
157+ func test07Fetch_AssetQuery_WithDimentsions( ) async {
158158 let networkExpectation = expectation ( description: " Fetch Assets with GLobalFields Test " )
159159 self . getAssetQuery ( )
160160 . include ( params: . dimension)
@@ -173,7 +173,7 @@ class AssetQueryAPITest: XCTestCase {
173173
174174 }
175175
176- func test08Fetch_Asset_WithGlobalFields( ) {
176+ func test08Fetch_Asset_WithGlobalFields( ) async {
177177 let networkExpectation = expectation ( description: " Fetch Assets with GlobalFields Test " )
178178 self . getAsset ( uid: AssetQueryAPITest . kAssetUID)
179179 . includeDimension ( )
@@ -189,7 +189,7 @@ class AssetQueryAPITest: XCTestCase {
189189 wait ( for: [ networkExpectation] , timeout: 30 )
190190 }
191191
192- func test09Fetch_AssetQuery_WithCount( ) {
192+ func test09Fetch_AssetQuery_WithCount( ) async {
193193 let networkExpectation = expectation ( description: " Fetch Assets with Count Test " )
194194 self . getAssetQuery ( )
195195 . locale ( " en-us " )
@@ -207,7 +207,7 @@ class AssetQueryAPITest: XCTestCase {
207207
208208 }
209209
210- func test11Fetch_Asset_WithWrongUID_shouldFail( ) {
210+ func test11Fetch_Asset_WithWrongUID_shouldFail( ) async {
211211 let networkExpectation = expectation ( description: " Fetch Assets from wrong UID Test " )
212212 self . getAsset ( uid: " UID " ) . fetch { ( result: Result < AssetModel , Error > , response: ResponseType ) in
213213 switch result {
@@ -224,7 +224,7 @@ class AssetQueryAPITest: XCTestCase {
224224 wait ( for: [ networkExpectation] , timeout: 30 )
225225 }
226226
227- func test12Fetch_AssetQuery_WithoutFallback_Result( ) {
227+ func test12Fetch_AssetQuery_WithoutFallback_Result( ) async {
228228 let networkExpectation = expectation ( description: " Fetch Assets without Fallback Test " )
229229 self . getAssetQuery ( ) . locale ( AssetQueryAPITest . locale)
230230 . find { ( result: Result < ContentstackResponse < AssetModel > , Error > , response: ResponseType ) in
@@ -245,7 +245,7 @@ class AssetQueryAPITest: XCTestCase {
245245 wait ( for: [ networkExpectation] , timeout: 30 )
246246 }
247247
248- func test13Fetch_AssetQuery_Fallback_Result( ) {
248+ func test13Fetch_AssetQuery_Fallback_Result( ) async {
249249 let networkExpectation = expectation ( description: " Fetch Assets without Fallback Test " )
250250 self . getAssetQuery ( )
251251 . locale ( AssetQueryAPITest . locale)
@@ -278,7 +278,7 @@ class AssetQueryAPITest: XCTestCase {
278278 wait ( for: [ networkExpectation] , timeout: 30 )
279279 }
280280
281- func test14Fetch_Asset_UIDWithoutFallback_NoResult( ) {
281+ func test14Fetch_Asset_UIDWithoutFallback_NoResult( ) async {
282282 let networkExpectation = expectation ( description: " Fetch Asset from UID without Fallback Test " )
283283 self . getAsset ( uid: AssetQueryAPITest . kAssetLocaliseUID)
284284 . locale ( " en-gb " )
@@ -297,7 +297,7 @@ class AssetQueryAPITest: XCTestCase {
297297 wait ( for: [ networkExpectation] , timeout: 30 )
298298 }
299299
300- func test15Fetch_Asset_UIDWithFallback_NoResult( ) {
300+ func test15Fetch_Asset_UIDWithFallback_NoResult( ) async {
301301 let networkExpectation = expectation ( description: " Fetch Asset from UID without Fallback Test " )
302302 self . getAsset ( uid: AssetQueryAPITest . kAssetLocaliseUID)
303303 . locale ( AssetQueryAPITest . locale)
0 commit comments