Skip to content

Commit 3745212

Browse files
committedOct 8, 2024··
refactor integration tests for a more modern look
1 parent 2b81e6c commit 3745212

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+10
-3
lines changed
 

‎gix/tests/gix-init.rs

+10-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,21 @@
1-
pub mod util;
2-
1+
#![allow(clippy::result_large_err)]
32
mod with_overrides {
43
use std::borrow::Cow;
54

5+
use gix::{Repository, ThreadSafeRepository};
66
use gix_object::bstr::BStr;
77
use gix_sec::Permission;
88
use gix_testtools::Env;
99
use serial_test::serial;
1010

11-
use crate::util::named_subrepo_opts;
11+
pub fn named_subrepo_opts(
12+
fixture: &str,
13+
name: &str,
14+
opts: gix::open::Options,
15+
) -> std::result::Result<Repository, gix::open::Error> {
16+
let repo_path = gix_testtools::scripted_fixture_read_only(fixture).unwrap().join(name);
17+
Ok(ThreadSafeRepository::open_opts(repo_path, opts)?.to_thread_local())
18+
}
1219

1320
#[test]
1421
#[serial]
File renamed without changes.

0 commit comments

Comments
 (0)
Please sign in to comment.