fixes for e2e test cases (#5451)

This commit is contained in:
Midhun G S 2023-01-31 17:13:04 +05:30 committed by GitHub
parent 263a14db1c
commit 699f28f318
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1129,7 +1129,7 @@ describe('apps controller', () => {
.delete(`/api/apps/${application.id}/versions/${version2.id}`)
.set('Authorization', authHeaderForUser(developerUserData.user));
expect(response.statusCode).toBe(200);
expect(response.statusCode).toBe(403);
});
it('should not be able to delete app versions if user does not have app update permission group', async () => {
@ -1165,6 +1165,8 @@ describe('apps controller', () => {
user: adminUserData.user,
});
const version = await createApplicationVersion(app, application);
await createApplicationVersion(app, application, { name: 'v2', definition: null });
await getManager().update(App, { id: application.id }, { currentVersionId: version.id });
const response = await request(app.getHttpServer())