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

Unifying ShareFile and SaveFile Operations Across Different Platforms #209

Merged
merged 5 commits into from
Jan 2, 2025

doc: update third-party package license

be876d4
Select commit
Loading
Failed to load commit list.
Sign in for the full log view
Merged

Unifying ShareFile and SaveFile Operations Across Different Platforms #209

doc: update third-party package license
be876d4
Select commit
Loading
Failed to load commit list.
GitHub Actions / flutter test succeeded Jan 2, 2025 in 0s

99 passed, 0 failed and 0 skipped

Tests passed successfully

✅ test_report.log

99 tests were completed in 19s with 99 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
test/common_test/math_test.dart 5✅ 49ms
test/common_test/utils_test.dart 7✅ 66ms
test/model_test/contributor_test.dart 8✅ 53ms
test/model_test/custom_date_format_test.dart 5✅ 55ms
test/model_test/habit_reminder_test.dart 21✅ 87ms
test/model_test/habits_test.dart 3✅ 46ms
test/model_test/records_test.dart 2✅ 59ms
test/model_test/score_test.dart 24✅ 114ms
test/viewmodel_test/app_theme_test.dart 2✅ 43ms
test/viewmodel_test/habit_form_test.dart 22✅ 158ms

✅ test/common_test/math_test.dart

test intervalTrans
  ✅ intervalTrans 01
  ✅ intervalTrans 02
test habitGrowCurve
  ✅ baisc 10
  ✅ baisc 66
test habitCrowCurveInverse
  ✅ basic 10

✅ test/common_test/utils_test.dart

test combineIterables
  ✅ test normal combine
test clamp
  ✅ clamp should return value within range
  ✅ clamp should return min when value is less than min
  ✅ clamp should return max when value is greater than max
test clampInt
  ✅ clampInt should return value within range
  ✅ clampInt should return min when value is less than min
  ✅ clampInt should return max when value is greater than max

✅ test/model_test/contributor_test.dart

test ContributorInfo
  ✅ init
  ✅ fromJson
test ContributorCollectionConverter
  ✅ fromJson
  ✅ fromJson with _contributor
test Contributors
  ✅ locales
  ✅ getTranslations
  ✅ getTranslations not found
  ✅ getContributors

✅ test/model_test/custom_date_format_test.dart

CustomDateYmdHmsConfig
  ✅ Test constructor
  ✅ Test getFormatter with system format
  ✅ Test getFormatter with custom format
  ✅ Test getFormatter with custom format
  ✅ Test getFormatter with custom format and month with name

✅ test/model_test/habit_reminder_test.dart

Test HabitReminder getNextRemindDate Per Month
  ✅ Next remind date after current date with 5th, 10th, and 20th extra
  ✅ Next remind date after current date with 20th extra only
  ✅ Next remind date after current date with no extra
  ✅ Next remind date after current date is the same day as current date
  ✅ Creating HabitReminder with invalid extra day should throw assertion error [<=0]
  ✅ Creating HabitReminder with invalid extra day should throw assertion error [>31]
Test HabitReminder getNextRemindDate Per Week
  ✅ weekly reminder without extra days
  ✅ weekly reminder with extra days
  ✅ weekly reminder with extra days, time passed
  ✅ weekly reminder with extra days, same day
  ✅ weekly reminder with extra days, same day after time
  ✅ weekly reminder with invalid extra day [<=0]
  ✅ weekly reminder with invalid extra day [>7]
Test HabitReminder getNextRemindDate Daily
  ✅ daily reminder should return next date
  ✅ daily reminder should return next date with extra field
  ✅ daily reminder should return today date if time has not passed
  ✅ daily reminder should return tomorrow date if time has passed
Test HabitReminder getNextRemindDate when Needed
  ✅ getNextRemindDateWithNeeded should return the correct date
  ✅ whenNeeded reminder should have correct type and extra data
  ✅ getNextRemindDateWithNeeded should return null when lastUntrackDate is null
  ✅ getNextRemindDateWithNeeded should handle lastUntrackDate and current date with different timezones

✅ test/model_test/habits_test.dart

HabitDBCell
  ✅ Constructor::fromMap
  ✅ toMap
  ✅ toString

✅ test/model_test/records_test.dart

RecordDBCell
  ✅ toMap
  ✅ toString

✅ test/model_test/score_test.dart

test HabitScore factory
  ✅ getImp returns instance of NormalHabitScore
test NormalHabitScore
  ✅ NormalHabitScore::init
  ✅ NormalHabitScore::calcRealScoreExtra
  ✅ NormalHabitScore::calcRealScoreExtra with extendedVal
  ✅ NormalHabitScore::calcDecreasedPrt:noAutoComplete
  ✅ NormalHabitScore::calcDecreasedPrt:autoComplete
  ✅ NormalHabitScore::calcIncreasedDay:noAutoComplete
  ✅ NormalHabitScore::calcIncreasedDay:autoComplete
  ✅ NormalHabitScore::calcHabitGrowCurveValue
test NegativeHabitScore
  ✅ NormalHabitScore::init
  ✅ NormalHabitScore::calcRealScoreExtra
  ✅ NormalHabitScore::calcRealScoreExtra with extendedVal
test HabitScoreCalculator calc total score
  ✅ HabitScoreCalculator calc normal
  ✅ HabitScoreCalculator calc with some failed
  ✅ HabitScoreCalculator calc with automarked
test HabitScoreCalculator sub methods
  ✅ calcEachScoreBetweenRecordDate
  ✅ calcScoreAfterLastRecordToEnd
  ✅ calcIncreaseDaysBetweenRecordDate, no record
  ✅ calcIncreaseDaysBetweenRecordDate, with record
  ✅ calcDecreasePrtBetweenRecordDate, no record
  ✅ calcDecreasePrtBetweenRecordDate, with record
  ✅ triggerScoreChangedEvent
test ArchivedHabitScoreCalculator calc total score
  ✅ ArchivedHabitScoreCalculator calc normal
test ArchivedHabitScoreCalculator sub methods
  ✅ calcScoreAfterLastRecordToEnd

✅ test/viewmodel_test/app_theme_test.dart

AppThemeViewModel
  ✅ getThemeType
  ✅ getMatertialThemeType

✅ test/viewmodel_test/habit_form_test.dart

HabitFormViewModel:API
  ✅ name
  ✅ colorType
  ✅ dailyGoal
  ✅ dailyGoalUnit
  ✅ dailyFrequency
  ✅ dailyStartDate
  ✅ dailyTargetDays
  ✅ dailyDescribtion
HabitFrequency
  ✅ Constructor
  ✅ Constructor.daily
  ✅ Constructor.weekly
  ✅ Constructor.monthly
  ✅ ==override
  ✅ toString
  ✅ toMap:monthly
  ✅ toMap:weekly
  ✅ toMap:daily
  ✅ toMapError
  ✅ fromMap:monthly
  ✅ fromMap:weekly
  ✅ fromMap:custom
  ✅ fromMap:error