mirror of
https://github.com/hexedtech/codemp.git
synced 2024-11-21 23:04:49 +01:00
tests: cleanup redundant code
This commit is contained in:
parent
518143d5b9
commit
c08e209e06
2 changed files with 3 additions and 9 deletions
|
@ -253,17 +253,11 @@ impl
|
||||||
|
|
||||||
async fn cleanup(
|
async fn cleanup(
|
||||||
&mut self,
|
&mut self,
|
||||||
resource: Option<(
|
_resource: Option<(
|
||||||
(crate::Client, crate::Workspace, crate::buffer::Controller),
|
(crate::Client, crate::Workspace, crate::buffer::Controller),
|
||||||
(crate::Client, crate::Workspace, crate::buffer::Controller),
|
(crate::Client, crate::Workspace, crate::buffer::Controller),
|
||||||
)>,
|
)>,
|
||||||
) {
|
) {
|
||||||
if let Some(((client, _, _), (_, _, _))) = resource {
|
// buffer deletion is implied in workspace deletion
|
||||||
// buffer deletion is implied in workspace deletion
|
|
||||||
client.leave_workspace(&self.workspace);
|
|
||||||
if let Err(e) = client.delete_workspace(&self.workspace).await {
|
|
||||||
eprintln!("could not delete workspace: {e}");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -86,7 +86,7 @@ async fn test_workspace_interactions() {
|
||||||
let client_bob = ClientFixture::of("bob").setup().await?;
|
let client_bob = ClientFixture::of("bob").setup().await?;
|
||||||
let workspace_name = format!(
|
let workspace_name = format!(
|
||||||
"test-workspace-interactions-{}",
|
"test-workspace-interactions-{}",
|
||||||
uuid::Uuid::new_v4().to_string()
|
uuid::Uuid::new_v4()
|
||||||
);
|
);
|
||||||
|
|
||||||
client_alice.create_workspace(&workspace_name).await?;
|
client_alice.create_workspace(&workspace_name).await?;
|
||||||
|
|
Loading…
Reference in a new issue