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

Add unit tests for goal template types #3183

Merged
merged 4 commits into from
Aug 5, 2024

Conversation

ACWalker
Copy link
Contributor

@ACWalker ACWalker commented Aug 3, 2024

This PR adds unit tests for the various goal template types, which helps address this issue #1686. I hope this will help to improve the robustness of the templates going forward.

For each goal template type, I have created a file containing the unit tests for that template type. I've tried to cover as many of the potential scenarios as possible, but there will definitely be some scenarios I haven't covered, this is just to get the ball rolling.

While writing these tests I have found some areas in the goal templates that we can refactor and improve, which I can address in subsequent PRs.

Copy link

netlify bot commented Aug 3, 2024

Deploy Preview for actualbudget ready!

Name Link
🔨 Latest commit c761cd4
🔍 Latest deploy log https://app.netlify.com/sites/actualbudget/deploys/66afeb811d61f90008d9e8a2
😎 Deploy Preview https://deploy-preview-3183.demo.actualbudget.org
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

github-actions bot commented Aug 3, 2024

Bundle Stats — desktop-client

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
9 4.81 MB 0%

Changeset

No files were changed

View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

No assets were smaller

Unchanged

Asset File Size % Changed
static/js/indexeddb-main-thread-worker-e59fee74.js 13.5 kB 0%
static/js/resize-observer.js 18.37 kB 0%
static/js/BackgroundImage.js 122.29 kB 0%
static/js/AppliedFilters.js 27.56 kB 0%
static/js/usePreviewTransactions.js 790 B 0%
static/js/narrow.js 78.27 kB 0%
static/js/wide.js 277.35 kB 0%
static/js/ReportRouter.js 1.24 MB 0%
static/js/index.js 3.04 MB 0%

Copy link
Contributor

github-actions bot commented Aug 3, 2024

Bundle Stats — loot-core

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
1 1.14 MB 0%

Changeset

No files were changed

View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

No assets were smaller

Unchanged

Asset File Size % Changed
kcab.worker.js 1.14 MB 0%

@ACWalker ACWalker force-pushed the add_unit_tests_for_goals branch 7 times, most recently from 8c8255a to 15cb3f8 Compare August 4, 2024 12:40
@ACWalker ACWalker force-pushed the add_unit_tests_for_goals branch from 15cb3f8 to a1d0f93 Compare August 4, 2024 12:40
@ACWalker ACWalker changed the title DRAFT: Add tests for goals Add unit tests for goal template types Aug 4, 2024
@ACWalker ACWalker marked this pull request as ready for review August 4, 2024 12:43
@ACWalker ACWalker force-pushed the add_unit_tests_for_goals branch from 4a68a7e to 052b77c Compare August 4, 2024 20:53
@ACWalker ACWalker force-pushed the add_unit_tests_for_goals branch from 69fd40d to 62c77ae Compare August 4, 2024 20:55
Copy link
Contributor

@MikesGlitch MikesGlitch left a comment

Choose a reason for hiding this comment

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

Amazing work! :shipit:

@MikesGlitch MikesGlitch merged commit 81f59ff into actualbudget:master Aug 5, 2024
19 checks passed
@ACWalker ACWalker deleted the add_unit_tests_for_goals branch August 5, 2024 11:25
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.

2 participants