mirror of
https://github.com/ilya-zlobintsev/LACT.git
synced 2026-08-19 01:14:43 -05:00
Merge branch 'master' into ui-snapshot-tests
This commit is contained in:
@@ -1181,13 +1181,13 @@ async fn apply_config_to_controllers(
|
||||
|
||||
#[cfg(all(test, not(miri)))]
|
||||
pub(crate) fn read_pci_db() -> Database {
|
||||
let path = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("../tests/data/pci.ids");
|
||||
let path = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("../tests/snapshots/pci.ids");
|
||||
Database::read_from_file(&path).unwrap()
|
||||
}
|
||||
|
||||
#[cfg(all(test, miri))]
|
||||
pub(crate) fn read_pci_db() -> Database {
|
||||
let bytes = include_bytes!("../../../tests/data/pci.ids");
|
||||
let bytes = include_bytes!("../../../tests/snapshots/pci.ids");
|
||||
Database::parse_db(std::io::Cursor::new(bytes)).unwrap()
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@ fn init_tracing() {
|
||||
async fn snapshot_everything() {
|
||||
init_tracing();
|
||||
|
||||
let test_data_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("../tests/data");
|
||||
let test_data_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("../tests/snapshots");
|
||||
let pci_db = read_pci_db();
|
||||
|
||||
for vendor_dir in fs::read_dir(test_data_dir).unwrap().flatten() {
|
||||
@@ -62,7 +62,7 @@ async fn apply_settings() {
|
||||
|
||||
let local_set = LocalSet::new();
|
||||
local_set.spawn_local(async move {
|
||||
let test_data_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("src/tests/data");
|
||||
let test_data_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("../tests/snapshots");
|
||||
let pci_db = read_pci_db();
|
||||
|
||||
for vendor_dir in fs::read_dir(test_data_dir).unwrap().flatten() {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user