summaryrefslogtreecommitdiff
path: root/rust/tests/worker_thread.rs
diff options
context:
space:
mode:
Diffstat (limited to 'rust/tests/worker_thread.rs')
-rw-r--r--rust/tests/worker_thread.rs17
1 files changed, 6 insertions, 11 deletions
diff --git a/rust/tests/worker_thread.rs b/rust/tests/worker_thread.rs
index 666e85ba..1d30c13a 100644
--- a/rust/tests/worker_thread.rs
+++ b/rust/tests/worker_thread.rs
@@ -1,15 +1,9 @@
use binaryninja::headless::Session;
-use rstest::*;
use std::sync::{Arc, Barrier};
-#[fixture]
-#[once]
-fn session() -> Session {
- Session::new().expect("Failed to initialize session")
-}
-
-#[rstest]
-fn test_setting_worker_thread(_session: &Session) {
+#[test]
+fn test_setting_worker_thread() {
+ let _session = Session::new().expect("Failed to initialize session");
let original_count = binaryninja::worker_thread::worker_thread_count();
binaryninja::worker_thread::set_worker_thread_count(original_count - 1);
assert_eq!(
@@ -23,8 +17,9 @@ fn test_setting_worker_thread(_session: &Session) {
);
}
-#[rstest]
-fn test_worker_thread_different(_session: &Session) {
+#[test]
+fn test_worker_thread_different() {
+ let _session = Session::new().expect("Failed to initialize session");
let calling_thread = std::thread::current();
// We need both (2) threads to synchronize