pinchbv / floor

The typesafe, reactive, and lightweight SQLite abstraction for your Flutter applications
https://pinchbv.github.io/floor/
Apache License 2.0
965 stars 191 forks source link

Warn when no definition is found for a specified primary key #790

Open Huluk opened 11 months ago

Huluk commented 11 months ago

Hopefully fixes #789

I'd like to add a test for this and make sure everything works, but I don't know how to run the tests^^

If I run them using flutter test out of the floor_generator directory, I get the following error:

Error: The class 'FileSystemEvent' can't be extended, implemented, or
mixed in outside of its library because it's a sealed class.
abstract class _ConstructableFileSystemEvent implements FileSystemEvent {
stephanmantel commented 7 months ago

Does running flutter pub run test work?

Huluk commented 7 months ago

Does running flutter pub run test work?

No, it returns the error I quoted in the first comment. This is, when I run flutter pub run test or dart run test from the floor_generator directory. If I run it from the project root, I get Error: No pubspec.yaml file found.

My Versions: macOS Sonoma 14.2.1 (23C71) Flutter 3.19.2 • channel stable • https://github.com/flutter/flutter.git Framework • revision 7482962148 (8 days ago) • 2024-02-27 16:51:22 -0500 Engine • revision 04817c99c9 Tools • Dart 3.3.0 • DevTools 2.31.1

stephanmantel commented 7 months ago

Hi,

It seems this is a remnant of old versions and dependencies. In other branches we have updated them and fixed the tests. It is my plan to get these merged soon and when that is done we can also merge this one.

codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 91.92%. Comparing base (4146037) to head (f4cf69f). Report is 1 commits behind head on develop.

:exclamation: Current head f4cf69f differs from pull request most recent head 0bfbefa. Consider uploading reports for the commit 0bfbefa to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #790 +/- ## =========================================== + Coverage 91.51% 91.92% +0.41% =========================================== Files 11 11 Lines 224 223 -1 =========================================== Hits 205 205 + Misses 19 18 -1 ``` | [Flag](https://app.codecov.io/gh/pinchbv/floor/pull/790/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pinchbv) | Coverage Δ | | |---|---|---| | [floor](https://app.codecov.io/gh/pinchbv/floor/pull/790/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pinchbv) | `91.92% <ø> (+0.41%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pinchbv#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

hendrikvdkaaden commented 7 months ago

I have merged the updated develop branch into this one. The tests are now functioning properly.

Huluk commented 7 months ago

Thank you!

stephanmantel commented 7 months ago

Could you add a test for this too?