Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Throws last core error when beginWriteAsync and commitWriteAsync #974

Merged
merged 14 commits into from
Dec 12, 2022

Conversation

desistefanova
Copy link
Contributor

@desistefanova desistefanova commented Oct 19, 2022

Add tests to check that write is not possible when:

  • Realm is closed,
  • Realm is read-only,
  • write and beginWrite are nested,
  • Realm is frozen.

Throw core errors as RealmExceptions.
Fixes #1047

@desistefanova desistefanova added the no-changelog Used to skip the changelog check label Oct 19, 2022
@coveralls
Copy link

coveralls commented Oct 19, 2022

Pull Request Test Coverage Report for Build 3675786185

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.02%) to 89.082%

Totals Coverage Status
Change from base Build 3614508838: -0.02%
Covered Lines: 2774
Relevant Lines: 3114

💛 - Coveralls

lib/src/native/realm_core.dart Outdated Show resolved Hide resolved
@desistefanova desistefanova marked this pull request as ready for review November 30, 2022 23:05
Copy link
Member

@nirinchev nirinchev left a comment

Choose a reason for hiding this comment

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

Looks good - just a few small questions from me.

CHANGELOG.md Outdated Show resolved Hide resolved
test/realm_test.dart Outdated Show resolved Hide resolved
test/realm_test.dart Outdated Show resolved Hide resolved
lib/src/realm_class.dart Show resolved Hide resolved
test/test.dart Outdated Show resolved Hide resolved
test/test.dart Outdated Show resolved Hide resolved
test/test.dart Outdated Show resolved Hide resolved
test/test.dart Outdated Show resolved Hide resolved
@desistefanova desistefanova removed the no-changelog Used to skip the changelog check label Dec 2, 2022
test/configuration_test.dart Show resolved Hide resolved
test/realm_test.dart Outdated Show resolved Hide resolved
test/realm_test.dart Outdated Show resolved Hide resolved
test/realm_test.dart Show resolved Hide resolved
Copy link
Contributor

@nielsenko nielsenko left a comment

Choose a reason for hiding this comment

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

LGTM - might have some changes regarding exceptions/errors later

@desistefanova desistefanova merged commit d9780e8 into main Dec 12, 2022
@desistefanova desistefanova deleted the ds/check_write_possible branch December 12, 2022 13:56
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Check if beginWriteAsync and commitWriteAsync rethrow core errors
5 participants