[pve-devel] [PATCH v2 proxmox 4/5] apt: tests: code cleanup to avoid useless vector

Fiona Ebner f.ebner at proxmox.com
Fri Jun 2 10:48:23 CEST 2023


Signed-off-by: Fiona Ebner <f.ebner at proxmox.com>
---

No changes in v2.

 proxmox-apt/tests/repositories.rs | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/proxmox-apt/tests/repositories.rs b/proxmox-apt/tests/repositories.rs
index 6319a62..2fb7ac8 100644
--- a/proxmox-apt/tests/repositories.rs
+++ b/proxmox-apt/tests/repositories.rs
@@ -389,13 +389,11 @@ fn test_standard_repositories() -> Result<(), Error> {
     let mut file = APTRepositoryFile::new(&pve_alt_list)?.unwrap();
     file.parse()?;
 
-    let file_vec = vec![file];
-
     expected[0].status = Some(true);
     expected[1].status = Some(true);
     expected[2].status = Some(false);
 
-    let std_repos = standard_repositories(&file_vec, "pve", DebianCodename::Bullseye);
+    let std_repos = standard_repositories(&[file], "pve", DebianCodename::Bullseye);
 
     assert_eq!(std_repos, expected);
 
-- 
2.39.2






More information about the pve-devel mailing list