Skip to content

Commit

Permalink
guess test case
Browse files Browse the repository at this point in the history
  • Loading branch information
osalyk committed Jul 19, 2024
1 parent 5be3af9 commit 86f4218
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/tests/ras/utils/inject_manager/inject_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -145,18 +145,18 @@ InjectManager::InjectManager(std::string test_dir, std::string policy) {
test_dir_ = test_dir;
}

bool InjectManager::IsLastShutdownUnsafe(
const std::vector<DimmNamespace> &dimm_namespaces) const {
std::function<bool(int, int)> compare = [](int rec, int cur) -> bool {
return cur > rec;
};

if (!CheckUSCDiff(dimm_namespaces, compare)) {
std::cerr << "Unexpected safe shutdown of NVDIMM" << std::endl;
return false;
}
return true;
}
// bool InjectManager::IsLastShutdownUnsafe(
// const std::vector<DimmNamespace> &dimm_namespaces) const {
// std::function<bool(int, int)> compare = [](int rec, int cur) -> bool {
// return cur > rec;
// };

// if (!CheckUSCDiff(dimm_namespaces, compare)) {
// std::cerr << "Unexpected safe shutdown of NVDIMM" << std::endl;
// return false;
// }
// return true;
// }

bool InjectManager::IsLastShutdownSafe(
const std::vector<DimmNamespace> &dimm_namespaces) const {
Expand Down

0 comments on commit 86f4218

Please sign in to comment.