Commit Graph
100 Commits
Author SHA1 Message Date
Gustavo Henrique Miranda 4b82bdd7df Merge pull request #77 from gmbrax/staging
Staging
2025-07-25 01:15:48 -03:00
Gustavo Henrique Miranda fad21863c7 Merge pull request #86 from gmbrax/test/backup-service-unit-test
Add fixture and tests for the backup service
2025-07-25 00:20:51 -03:00
Gustavo Henrique Miranda 9a5d112a26 Merge branch 'staging' into test/backup-service-unit-test 2025-07-25 00:20:35 -03:00
Gustavo Henrique Miranda 4af2a47606 Merge pull request #85 from gmbrax/test/traveldiaryservice-unit-test
Add the tests for the new methods of deleting
2025-07-25 00:17:47 -03:00
Gustavo Henrique Santos Souza de Miranda 3d926993e8 Add the tests for the new methods of deleting 2025-07-25 00:13:08 -03:00
Gustavo Henrique Miranda ed55d33bc6 Merge pull request #84 from gmbrax/test/entryservice-unit-test
Add the tests for the new methods of deleting
2025-07-25 00:01:00 -03:00
Gustavo Henrique Santos Souza de Miranda 819a2c7b6b Add the tests for the new methods of deleting 2025-07-24 23:36:02 -03:00
Gustavo Henrique Miranda 92ee47cff3 Merge pull request #83 from gmbrax/fix/add-photos-list-to-entry-model
Fix to add a photo list to the constructor of the entry model
2025-07-24 23:20:01 -03:00
Gustavo Henrique Mirandaandcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> 8d45b4361e Update src/pilgrim/models/entry.py
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-07-24 23:18:34 -03:00
Gustavo Henrique Santos Souza de Miranda 3db39eac71 Fix to add a photo list to the constructor of the entry model 2025-07-24 23:13:01 -03:00
Gustavo Henrique Santos Souza de Miranda 53e8b36a42 Add fixture and tests for the backup service 2025-07-24 22:56:43 -03:00
Gustavo Henrique Miranda 7faab93dfe Update CHANGELOG.md
Add the 0.0.5 changes into the changelog
2025-07-24 21:52:28 -03:00
Gustavo Henrique Miranda 34821bfedb Merge pull request #82 from gmbrax/refactor/remove-mocks
Remove the unused mock services
2025-07-24 21:12:32 -03:00
Gustavo Henrique Santos Souza de Miranda b32a068fb9 Remove the unused mock services 2025-07-24 21:08:28 -03:00
Gustavo Henrique Miranda 447dffd7df Merge pull request #81 from gmbrax/refactor/clean-the-ruff-errors
Fix all the Ruff errors
2025-07-24 20:26:17 -03:00
Gustavo Henrique Santos Souza de Miranda 2b79b08df0 Fix all the Ruff errors 2025-07-24 20:19:09 -03:00
Gustavo Henrique Miranda 48b3ec5fd1 Merge pull request #80 from gmbrax/feat/backup-database
add the backup feature
2025-07-24 19:59:15 -03:00
Gustavo Henrique Santos Souza de Miranda c3397ab982 Remove the wrong error message and made the program exit if no session is found 2025-07-24 19:36:12 -03:00
Gustavo Henrique Mirandaandcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> bb9457978c Update src/pilgrim/service/backup_service.py
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-07-24 19:31:13 -03:00
Gustavo Henrique Santos Souza de Miranda c09425cd48 Merge remote-tracking branch 'origin/feat/backup-database' into feat/backup-database 2025-07-24 19:23:59 -03:00
Gustavo Henrique Mirandaandcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> 7c950b93ab Update src/pilgrim/ui/screens/diary_list_screen.py
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-07-24 19:23:40 -03:00
Gustavo Henrique Santos Souza de Miranda 17371088da Changed the way it uses the database connection to be more robust 2025-07-24 19:21:47 -03:00
Gustavo Henrique Santos Souza de Miranda 209099cc5e Add a error handling on backup operation 2025-07-24 19:05:55 -03:00
Gustavo Henrique Santos Souza de Miranda 890fc470bb Change the filename variable to conform to the proper pathlike use 2025-07-24 19:00:04 -03:00
Gustavo Henrique Santos Souza de Miranda 8cf5f7e465 Fix moved the backup service initialization inside the check for the session 2025-07-24 18:39:08 -03:00
Gustavo Henrique Santos Souza de Miranda f62ecc18f7 add the backup feature 2025-07-24 18:15:26 -03:00
Gustavo Henrique Miranda 4aca171ce3 Merge pull request #79 from gmbrax/fix/remove-the-remaining-backup-feature
Remove the backup container in the diary settings screen
2025-07-24 17:10:33 -03:00
Gustavo Henrique Santos Souza de Miranda 49b6917291 Remove the backup container in the diary settings screen 2025-07-24 17:05:33 -03:00
Gustavo Henrique Santos Souza de Miranda 1c986d7627 Add the unidecode license on about screen 2025-07-24 14:49:09 -03:00
Gustavo Henrique Miranda 43f346d49b Bump version on pyproject.toml 2025-07-24 13:24:28 -03:00
Gustavo Henrique Miranda 48e2c1c934 Merge pull request #78 from gmbrax/feat/settings-screen
Feat/settings screen
2025-07-24 02:11:09 -03:00
Gustavo Henrique Santos Souza de Miranda 7274d670ec Remove the backup diary option on the diary settings screen 2025-07-24 02:03:52 -03:00
Gustavo Henrique Santos Souza de Miranda 62e084efb3 Add the feature to delete all the photos from a travel diary and also remove all the references of photos inside the entry 2025-07-24 01:54:24 -03:00
Gustavo Henrique Santos Souza de Miranda c5edb835b6 Add the feature to delete all the entries from a travel diary 2025-07-23 08:45:50 -03:00
Gustavo Henrique Santos Souza de Miranda ed89669431 Fix a circular import and passed the proper travel diary id 2025-07-23 08:44:32 -03:00
Gustavo Henrique Santos Souza de Miranda 8efda52d15 Add the delete all entries method the travel diary service 2025-07-23 08:42:00 -03:00
Gustavo Henrique Santos Souza de Miranda 4d6c92b4d0 Add the feature to delete the whole diary 2025-07-23 07:56:42 -03:00
Gustavo Henrique Santos Souza de Miranda 83fdb885a9 Add the feature to set the auto-open diary in the toml file 2025-07-23 07:27:35 -03:00
Gustavo Henrique Santos Souza de Miranda 0c6de1ea2e Add the call to the diary settings screen 2025-07-23 07:26:23 -03:00
Gustavo Henrique Santos Souza de Miranda ed8619fbf9 Add the get auto open diary method to the config manager 2025-07-23 07:18:50 -03:00
Gustavo Henrique Santos Souza de Miranda d9753a375f Add the Diary Settings screen and the CSS for it 2025-07-23 04:52:22 -03:00
Gustavo Henrique Santos Souza de Miranda d1afd3a7ef Add the css for the new modals 2025-07-23 04:22:51 -03:00
Gustavo Henrique Santos Souza de Miranda 40a2e727f8 Add the modals to delete the diary and the diary contents 2025-07-23 03:00:49 -03:00
Gustavo Henrique Miranda 08a5030846 Merge pull request #75 from gmbrax/test/application-test
Add the tests for the application class
2025-07-21 19:41:05 -03:00
Gustavo Henrique Miranda 050939b4b8 Merge pull request #76 from gmbrax/test/command-tests
Add the tests to the command file
2025-07-21 19:40:40 -03:00
Gustavo Henrique Santos Souza de Miranda 8bd03bcaca Add the tests to the command file 2025-07-21 19:36:37 -03:00
Gustavo Henrique Santos Souza de Miranda bcb76fbb7d Add the tests for the application class 2025-07-21 19:30:52 -03:00
Gustavo Henrique Miranda 0ab1e38726 Merge pull request #74 from gmbrax/test/photoservice-unit-tests
Add the tests for the update on photo service
2025-07-21 19:01:23 -03:00
Gustavo Henrique Santos Souza de Miranda 668e2825d9 Add the tests for the update on photo service 2025-07-21 18:55:28 -03:00
Gustavo Henrique Miranda 5c50cad207 Merge pull request #73 from gmbrax/test/directory-manager-unit-tests
Add the tests for the directory manager
2025-07-21 18:07:18 -03:00
Gustavo Henrique Miranda 3212607f70 Merge pull request #72 from gmbrax/test/config-manager-unit-tests
Add the tests for the config manager
2025-07-21 18:07:01 -03:00
Gustavo Henrique Miranda eafd9b9522 Merge pull request #71 from gmbrax/test/service-manager-unit-tests
Add the tests for the service manager
2025-07-21 18:06:36 -03:00
Gustavo Henrique Miranda 3e644a415f Merge pull request #70 from gmbrax/test/photoservice-unit-tests
Test/photoservice unit tests
2025-07-21 18:05:52 -03:00
Gustavo Henrique Santos Souza de Miranda 27ff615d4a Add the tests for the directory manager 2025-07-21 18:03:01 -03:00
Gustavo Henrique Santos Souza de Miranda ec0c8a6f71 Add the tests for the config manager 2025-07-21 17:43:39 -03:00
Gustavo Henrique Santos Souza de Miranda bf64255fe2 Add the tests for the service manager 2025-07-21 16:58:27 -03:00
Gustavo Henrique Santos Souza de Miranda 32f363f15a Add the tests for the delete photo service and also fixed the missing import 2025-07-21 16:48:09 -03:00
Gustavo Henrique Santos Souza de Miranda 65cf7b04f3 Merge remote-tracking branch 'origin/test/photoservice-unit-tests' into test/photoservice-unit-tests
# Conflicts:
#	tests/conftest.py
#	tests/service/test_photo_service.py
2025-07-21 16:31:59 -03:00
Gustavo Henrique Santos Souza de Miranda 44824cd690 Add the tests for the update photo service and also improved the fixture 2025-07-21 16:30:54 -03:00
Gustavo Henrique Santos Souza de Miranda 32b1c24846 Add the tests for the read methods for the photo service 2025-07-21 16:19:10 -03:00
Gustavo Henrique Santos Souza de Miranda 5d0d4fc5ac Add the tests for the hash methods and the create methods 2025-07-21 16:19:09 -03:00
Gustavo Henrique Miranda 9d0bc50350 Merge pull request #69 from gmbrax/fix/traveldiary-model-back-relantioship
Fix the photo and travel diary relationship to properly work
2025-07-21 15:44:24 -03:00
Gustavo Henrique Santos Souza de Miranda 83e7db9ce1 Fix the photo and travel diary relationship to properly work 2025-07-21 15:27:51 -03:00
Gustavo Henrique Santos Souza de Miranda 5f20bd3624 Add the tests for the read methods for the photo service 2025-07-21 02:48:04 -03:00
Gustavo Henrique Santos Souza de Miranda 2f81e4ff06 Add the tests for the hash methods and the create methods 2025-07-21 02:28:04 -03:00
Gustavo Henrique Miranda d840299398 Merge pull request #68 from gmbrax/test/database-unit-test
Change the import to avoid importing by the folder
2025-07-21 01:23:10 -03:00
Gustavo Henrique Santos Souza de Miranda ca0b8c554c Change the import to avoid importing by the folder 2025-07-21 01:22:05 -03:00
Gustavo Henrique Miranda ed2dbee1a3 Merge pull request #67 from gmbrax/test/traveldiaryservice-unit-test
Test/traveldiaryservice unit test
2025-07-21 01:18:08 -03:00
Gustavo Henrique Miranda 6e17064ce6 Merge pull request #66 from gmbrax/test/entryservice-unit-test
Test/entryservice unit test
2025-07-21 01:08:46 -03:00
Gustavo Henrique Santos Souza de Miranda a18c621d5c Add the tests for delete the entries method 2025-07-21 01:07:11 -03:00
Gustavo Henrique Miranda 998fa3ce2f Merge pull request #65 from gmbrax/test/database-unit-test
Create the test for the database class
2025-07-21 00:58:04 -03:00
Gustavo Henrique Santos Souza de Miranda 66879b5a7d Add the tests for update the entries method 2025-07-21 00:53:04 -03:00
Gustavo Henrique Santos Souza de Miranda 240e4ae6c7 fix the sanitization directory method to remove accents and diacritics 2025-07-21 00:53:04 -03:00
Gustavo Henrique Santos Souza de Miranda df9101ccac Add unidecode dependency on pyproject.toml 2025-07-21 00:53:04 -03:00
Gustavo Henrique Miranda 2454f929c9 Merge pull request #64 from gmbrax/fix/sanitize-accent-bug
Fix/sanitize accent bug
2025-07-21 00:23:35 -03:00
Gustavo Henrique Santos Souza de Miranda 736c0f160f fix the sanitization directory method to remove accents and diacritics 2025-07-21 00:14:17 -03:00
Gustavo Henrique Santos Souza de Miranda de27485c98 Add unidecode dependency on pyproject.toml 2025-07-21 00:13:26 -03:00
Gustavo Henrique Santos Souza de Miranda 152bff85e5 Add the read entries unit tests 2025-07-20 23:53:53 -03:00
Gustavo Henrique Santos Souza de Miranda f374285e2a Add the fixture for the read entry tests 2025-07-20 23:52:45 -03:00
Gustavo Henrique Santos Souza de Miranda b020f8500b Add The tests for the filename sanitization function and the create travel diary 2025-07-20 23:38:36 -03:00
Gustavo Henrique Santos Souza de Miranda cc95ce669f Merge remote-tracking branch 'origin/test/entryservice-unit-test' into test/entryservice-unit-test
# Conflicts:
#	tests/service/test_entry_service.py
2025-07-20 23:16:48 -03:00
Gustavo Henrique Santos Souza de Miranda d36ff829db Remove the shared fixtures that are available on conftest.py 2025-07-20 23:15:08 -03:00
Gustavo Henrique Santos Souza de Miranda 0173465943 Add all tests to test the delete of entries 2025-07-20 23:13:46 -03:00
Gustavo Henrique Santos Souza de Miranda 5b9a5bfe24 Add all tests to test the read of entries 2025-07-20 23:13:46 -03:00
Gustavo Henrique Santos Souza de Miranda 95a3a13ee2 Add all tests to test the update of entries 2025-07-20 23:13:46 -03:00
Gustavo Henrique Santos Souza de Miranda f9fb660d7c Add a test to test the creation of entries with null on nullable fields 2025-07-20 23:13:45 -03:00
Gustavo Henrique Santos Souza de Miranda f7a7289b5e test(entry_service): add test for creating an entry without photos
This commit adds a unit test to ensure that the EntryService's
`create` method correctly handles cases where an empty list of photos
is provided.

It verifies that the entry is created successfully and that the
`photos` relationship is an empty list, confirming the feature's
flexibility.
2025-07-20 23:13:45 -03:00
Gustavo Henrique Santos Souza de Miranda 0227879bb3 test(entry_service): add a failure case test for create method
This commit adds a unit test for an important "unhappy path" in the
EntryService's `create` method.

It specifically verifies that the method gracefully returns `None`
when provided with a `travel_diary_id` that does not exist in the
database, ensuring the initial guard clause works as expected.
2025-07-20 23:13:45 -03:00
Gustavo Henrique Santos Souza de Miranda e46f02cc39 test(entry_service): add unit test for creating a new entry
This commit introduces the first unit test for the EntryService,
covering the "happy path" for the `create` method.

It verifies that a new entry is correctly persisted to the database,
including its relationship with associated Photo objects. The test
leverages fixtures to create an isolated, in-memory database
populated with the necessary dependencies.
2025-07-20 23:13:45 -03:00
Gustavo Henrique Miranda e9162ab25c Merge pull request #63 from gmbrax/refactor/shared-test-fixtures
Refactor to add conftest.py to share fixtures
2025-07-20 23:12:32 -03:00
Gustavo Henrique Santos Souza de Miranda 88a0b9cf80 Refactor to add conftest.py to share fixtures 2025-07-20 23:07:04 -03:00
Gustavo Henrique Santos Souza de Miranda 1629b9d52c Add all tests to test the delete of entries 2025-07-20 22:38:55 -03:00
Gustavo Henrique Santos Souza de Miranda 790a9ea3f0 Add all tests to test the read of entries 2025-07-20 22:26:40 -03:00
Gustavo Henrique Santos Souza de Miranda cec1827635 Add all tests to test the update of entries 2025-07-20 22:12:09 -03:00
Gustavo Henrique Santos Souza de Miranda 1c8026620c Add a test to test the creation of entries with null on nullable fields 2025-07-20 20:47:12 -03:00
Gustavo Henrique Santos Souza de Miranda fcbf465c43 Merge branch 'staging' into test/entryservice-unit-test 2025-07-20 18:08:11 -03:00
Gustavo Henrique Miranda 4dda85d8a3 Merge pull request #62 from gmbrax/fix/model-entry-nullable-fields
fix the entry model to not allow the title nor the date to be null
2025-07-20 17:53:27 -03:00
Gustavo Henrique Santos Souza de Miranda 5a28afc540 fix the entry model to not allow the title nor the date to be null 2025-07-20 17:34:57 -03:00
Gustavo Henrique Santos Souza de Miranda 77e191f480 test(entry_service): add test for creating an entry without photos
This commit adds a unit test to ensure that the EntryService's
`create` method correctly handles cases where an empty list of photos
is provided.

It verifies that the entry is created successfully and that the
`photos` relationship is an empty list, confirming the feature's
flexibility.
2025-07-20 16:03:45 -03:00
Gustavo Henrique Santos Souza de Miranda 3c7925cb1c test(entry_service): add a failure case test for create method
This commit adds a unit test for an important "unhappy path" in the
EntryService's `create` method.

It specifically verifies that the method gracefully returns `None`
when provided with a `travel_diary_id` that does not exist in the
database, ensuring the initial guard clause works as expected.
2025-07-20 15:21:49 -03:00