Skip to content

Conversation

@kotov-valery
Copy link
Collaborator

No description provided.

}

const auto result = transaction.iterate();
ASSERT_TRUE(result);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is a small bug in trivial_types_dup_iterate_by_key, iterate_by_key call should be used instead. I will look into that as a different PR.

@codecov-commenter
Copy link

codecov-commenter commented Nov 2, 2023

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 94.44444% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.44%. Comparing base (a63841b) to head (61e0b5b).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
include/cpp_lmdb/transactions.hpp 85.71% 1 Missing ⚠️
test/unit/test_transaction.cpp 95.83% 1 Missing ⚠️
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #23      +/-   ##
==========================================
+ Coverage   93.04%   93.44%   +0.39%     
==========================================
  Files          13       15       +2     
  Lines         446      519      +73     
==========================================
+ Hits          415      485      +70     
- Misses         31       34       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

using ro_view
= db_view<ro_iterator<key_trait, value_trait, LmdbApi>, LmdbApi>;
using ro_lo_view
= db_dup_view<ro_iterator<key_trait, value_trait, LmdbApi>, LmdbApi>;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it makes sense to rename db_dup_view into something like db_view_with_key as it is now used not only in key duplicate scenarios


auto const& db_view = *result;
auto const it = db_view.begin();
EXPECT_NE(it, db_view.end());
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use ASSERT_NE before iterator will be dereferenced.

auto *cursor{reinterpret_cast<MDB_cursor *>(0x84)};

{
InSequence const seq;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be great to have basic integration test as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants