Skip to content

[Neo Core UT] Test memory store#3336

Merged
shargon merged 3 commits intoneo-project:masterfrom
Jim8y:test-memorystore
Jun 20, 2024
Merged

[Neo Core UT] Test memory store#3336
shargon merged 3 commits intoneo-project:masterfrom
Jim8y:test-memorystore

Conversation

@Jim8y
Copy link
Contributor

@Jim8y Jim8y commented Jun 15, 2024

Description

Previously in #3288 i fixed the commit bug of datacache, and i though it was a problem of memorystore, but now i realized the real problem is NeoSystem.StoreView is actually a readonly store view and all stores are supposed not having a snapshot. Thus having this pr to further extend the test cases demonstrating how StoreView and GetSnapshot works.

There is another issue that discoverd but not sure if it is designed to be so, which is the seek method of memorystore and dadacache has different processing logic. Please check the updated StoreTest and NeoSystemStoreGetAndChange

Fixes #

Type of change

  • Optimization (the change is only an optimization)
  • Style (the change is only a code style for better maintenance or standard purpose)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

  • StoreTest
  • NeoSystemStoreViewTest
  • NeoSystemStoreAddTest
  • NeoSystemStoreGetAndChange

Test Configuration:

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@Jim8y Jim8y requested a review from a team June 15, 2024 04:25
cschuchardt88
cschuchardt88 previously approved these changes Jun 15, 2024
Co-authored-by: Shargon <shargon@gmail.com>
Copy link
Member

@vncoelho vncoelho left a comment

Choose a reason for hiding this comment

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

Great Jimmy, I will check on Monday.

@shargon shargon merged commit 60bb9c6 into neo-project:master Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants