From eecfebbd11ac6b36b991f0b0bf38a32a32ffc433 Mon Sep 17 00:00:00 2001 From: aviadl Date: Sun, 7 Apr 2024 15:37:36 +0300 Subject: [PATCH] Split test cases of project api calls --- .../Management/ProjectTests.cs | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/Descope.Test/IntegrationTests/Management/ProjectTests.cs b/Descope.Test/IntegrationTests/Management/ProjectTests.cs index 2bff7e7..27b9012 100644 --- a/Descope.Test/IntegrationTests/Management/ProjectTests.cs +++ b/Descope.Test/IntegrationTests/Management/ProjectTests.cs @@ -13,8 +13,19 @@ public async Task Project_ExportImport() await _descopeClient.Management.Project.Import(imported_project); } - [Fact(Skip = "Test fails due to theme import")] - public async Task Project_CloneRenameDelete() + public async Task Project_Rename() + { + var name = Guid.NewGuid().ToString().Split("-").First(); + // Rename + var new_name = Guid.NewGuid().ToString().Split("-").First(); + await _descopeClient.Management.Project.Rename(new_name); + + // Rename again so we will have original name + await _descopeClient.Management.Project.Rename("Dotnet SDK Testing"); + } + + [Fact(Skip = "Skipping due to lack of mgmt key permissions")] + public async Task Project_CloneAndDelete() { // Clone the current project var name = Guid.NewGuid().ToString().Split("-").First(); @@ -23,13 +34,6 @@ public async Task Project_CloneRenameDelete() // Delete cloned project await _descopeClient.Management.Project.Delete(result.ProjectId); - - // Rename - var new_name = Guid.NewGuid().ToString().Split("-").First(); - await _descopeClient.Management.Project.Rename(new_name); - - // Rename again so we will have original name - await _descopeClient.Management.Project.Rename("dotnet"); } }