Skip to content

Commit

Permalink
💚 Work on CI warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ystade committed Mar 3, 2025
1 parent 878c01a commit d1efe8f
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions test/na/test_nacomputation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ TEST(NAComputation, General) {
qc.emplaceInitialLocation(atom1, 1, 0);
qc.emplaceInitialLocation(atom2, 2, 0);
qc.emplaceBack<LocalRZOp>(qc::PI_2, atom0);
qc.emplaceBack<LocalRZOp>(qc::PI_2, std::vector{atom1, atom2});
qc.emplaceBack<GlobalRYOp>(qc::PI_2, globalZone);
qc.emplaceBack<LoadOp>(std::vector{atom0, atom1},
std::vector{Location{0, 1}, Location{1, 1}});
Expand All @@ -45,6 +46,10 @@ TEST(NAComputation, General) {
"atom (1.000, 0.000) atom1\n"
"atom (2.000, 0.000) atom2\n"
"@+ rz 1.57080 atom0\n"
"@+ rz [\n"
" 1.57080 atom1\n"
" 1.57080 atom2\n"
"]\n"
"@+ ry 1.57080 global\n"
"@+ load [\n"
" (0.000, 1.000) atom0\n"
Expand Down Expand Up @@ -144,6 +149,17 @@ TEST(NAComputation, ValidateAODConstraints) {
// store unloaded atom
qc.emplaceBack<StoreOp>(std::vector{atom0});
EXPECT_FALSE(qc.validate());
qc.clear();
qc.emplaceBack<LoadOp>(std::vector{atom2, atom1});
// row order not preserved
qc.emplaceBack<StoreOp>(std::vector{atom2, atom1},
std::vector{Location{0, 1}, Location{2, 2}});
EXPECT_FALSE(qc.validate());
qc.clear();
qc.emplaceBack<LoadOp>(std::vector{atom1});
qc.emplaceBack<StoreOp>(std::vector{atom1});
qc.emplaceBack<StoreOp>(std::vector{atom1});
EXPECT_FALSE(qc.validate());
}

TEST(NAComputation, GetPositionOfAtomAfterOperation) {
Expand Down

0 comments on commit d1efe8f

Please sign in to comment.