Skip to content

Commit

Permalink
Fix issue in det_manip_insert_k.cpp and det_manip_remove_k.cpp tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Thoemi09 committed Dec 10, 2024
1 parent a330ec7 commit ac1a252
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/c++/det_manip/det_manip_insert_k.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ template <typename T> void test_insert(int k) {
// generate random insert positions
std::ranges::sample(std::views::iota(0, n + k), row_idxs.begin(), k, gen);
std::ranges::sample(std::views::iota(0, n + k), col_idxs.begin(), k, gen);
std::ranges::sort(row_idxs);
std::ranges::sort(col_idxs);

// insert matrix builder arguments
std::vector<double> x_exp = x_base;
Expand Down
2 changes: 2 additions & 0 deletions test/c++/det_manip/det_manip_remove_k.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ template <typename T> void test_remove_k(int k) {
// generate random remove positions
std::ranges::sample(std::views::iota(0, n), row_idxs.begin(), k, gen);
std::ranges::sample(std::views::iota(0, n), col_idxs.begin(), k, gen);
std::ranges::sort(row_idxs);
std::ranges::sort(col_idxs);

// remove matrix builder arguments
std::vector<double> x_exp = dm_base.get_x();
Expand Down

0 comments on commit ac1a252

Please sign in to comment.