mirror of
				https://github.com/strapi/strapi.git
				synced 2025-10-31 01:47:13 +00:00 
			
		
		
		
	test: delete
This commit is contained in:
		
							parent
							
								
									266ff0b5b1
								
							
						
					
					
						commit
						fee4af7e16
					
				| @ -84,11 +84,13 @@ const populate = { | |||||||
|   }, |   }, | ||||||
| }; | }; | ||||||
| 
 | 
 | ||||||
| const mockProvider = (signUrl = true) => ({ | const isPrivate = true; | ||||||
|  | 
 | ||||||
|  | const mockProvider = () => ({ | ||||||
|   init() { |   init() { | ||||||
|     return { |     return { | ||||||
|       isPrivate() { |       isPrivate() { | ||||||
|         return signUrl; |         return isPrivate; | ||||||
|       }, |       }, | ||||||
|       getSignedUrl() { |       getSignedUrl() { | ||||||
|         return { url: 'signedUrl' }; |         return { url: 'signedUrl' }; | ||||||
| @ -227,38 +229,23 @@ describe('Upload Plugin url signing', () => { | |||||||
| 
 | 
 | ||||||
|     test('entityService.update', async () => { |     test('entityService.update', async () => { | ||||||
|       const model = await createModel(); |       const model = await createModel(); | ||||||
|       const en = await strapi.entityService.update(modelUID, model.id, { |       const entity = await strapi.entityService.update(modelUID, model.id, { | ||||||
|         data: { |         data: { | ||||||
|           name: 'model_updated', |           name: 'model_updated', | ||||||
|         }, |         }, | ||||||
|         populate, |         populate, | ||||||
|       }); |       }); | ||||||
| 
 | 
 | ||||||
|       responseExpectations(en); |       responseExpectations(entity); | ||||||
|     }); |     }); | ||||||
| 
 | 
 | ||||||
|     //   test('entityService.delete', async () => {
 |     test('entityService.delete', async () => { | ||||||
|     //     const en = await strapi.entityService.findMany(modelUID, entity, {
 |       const model = await createModel(); | ||||||
|     //       populate,
 |       const entity = await strapi.entityService.delete(modelUID, model.id, { | ||||||
|     //     });
 |         populate, | ||||||
|  |       }); | ||||||
| 
 | 
 | ||||||
|     //     responseExpectations(en);
 |       responseExpectations(entity); | ||||||
|     //   });
 |     }); | ||||||
|     // });
 |  | ||||||
| 
 |  | ||||||
|     // test('entityService.load', async () => {
 |  | ||||||
|     //   const en = await strapi.entityService.findMany(modelUID, entity, {
 |  | ||||||
|     //     populate,
 |  | ||||||
|     //   });
 |  | ||||||
| 
 |  | ||||||
|     //   responseExpectations(en);
 |  | ||||||
|     // });
 |  | ||||||
| 
 |  | ||||||
|     // test('entityService.loadPages', async () => {
 |  | ||||||
|     //   const en = await strapi.entityService.findMany(modelUID, entity, {
 |  | ||||||
|     //     populate,
 |  | ||||||
|     //   });
 |  | ||||||
| 
 |  | ||||||
|     //   responseExpectations(en);
 |  | ||||||
|   }); |   }); | ||||||
| }); | }); | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Marc-Roig
						Marc-Roig