This document provides a comprehensive testing checklist to verify the upgrade is successful.
-
Install Flutter 3.38.3:
fvm install 3.38.3 fvm use 3.38.3
-
Verify Flutter version:
fvm flutter --version # Should show: Flutter 3.38.3
cd /path/to/calorie_diff
fvm flutter pub getExpected Result: All dependencies should resolve without conflicts.
Potential Issues:
- If you see version conflicts, check the UPGRADE_NOTES.md for guidance
- Ensure Dart SDK 3.10.0 or higher is being used
make flutter_generate
# or
fvm flutter packages pub run build_runner build --delete-conflicting-outputsExpected Result:
- All
*.g.dartand*.freezed.dartfiles should regenerate successfully - No errors or warnings
fvm flutter analyzeExpected Result:
- No errors
- Any warnings should be reviewed but may be acceptable
make flutter_test
# or
fvm flutter test test --no-pub --test-randomize-ordering-seed randomExpected Result: All tests should pass.
Key areas to verify:
- Provider tests (core_providers_test.dart)
- Widget tests
- Mock tests
make flutter_coverage
# or
fvm flutter test test --no-pub --coverage --test-randomize-ordering-seed randomExpected Result:
- Coverage should be >= 75% (as required by CI)
- No significant drop in coverage from previous version
fvm flutter build ios --debugExpected Result: Build should complete successfully.
fvm flutter build apk --debugExpected Result: Build should complete successfully.
Run the app on a physical device or emulator and verify:
- App requests health permissions on first launch
- Permissions are properly granted/denied
- No crashes related to health API
- Displays current day's calorie data
- Shows burned, consumed, and difference values
- Refreshes data on pull-down
- Displays macros correctly
- Displays historical data for selected days
- Range picker allows selecting 7, 14, 30 days
- Data loads correctly for all ranges
- Historical macros display correctly
- Settings are preserved across app launches
- All settings controls work correctly
- App launches without crashes
- Navigation between tabs works smoothly
- Fonts render correctly (google_fonts upgrade)
- No console errors or warnings
- Firebase analytics tracking works
- Crashlytics is properly initialized
Since Riverpod was upgraded from 2.6.1 to 3.2.1, verify:
- Providers refresh correctly when invalidated
- Provider state persists across widget rebuilds
- No memory leaks from provider disposal
- Providers work correctly when switching tabs
- No issues with provider state when navigating
- FutureProvider loading states work correctly
- Error states are handled properly
- Data refreshes work as expected
Verify Firebase integration:
- Firebase initializes without errors
- Analytics events are logged (check Firebase console)
- Crashlytics is capturing errors (if any occur)
- App startup time is reasonable
- No noticeable lag or stuttering
- Memory usage is stable
- Battery usage is acceptable
If you encounter errors related to the health package:
- Check the health package changelog
- Review any API changes between 13.1.1 and 14.0.1
- Update code as needed
If providers stop updating when widgets are not visible:
- This is expected behavior in Riverpod 3.0
- If this causes issues, consider using
ref.listeninstead ofref.watch - See Riverpod migration guide for details
If critical issues are found:
-
Revert the upgrade commits:
git revert HEAD~2..HEAD
-
Reinstall Flutter 3.35.1:
fvm use 3.35.1 fvm flutter pub get
-
Regenerate code:
make flutter_generate
-
Run tests to verify rollback:
make flutter_test
The upgrade is considered successful when:
- All dependencies resolve without conflicts
- Code generation completes successfully
- Linter passes with no errors
- All unit tests pass
- Coverage remains >= 75%
- App builds for both iOS and Android
- Manual testing shows no regressions
- CI/CD pipeline passes
If you encounter issues during testing:
- Document the exact error message
- Note which step in this checklist it occurred
- Include Flutter version output (
fvm flutter --version) - Include relevant logs or stack traces
- Create an issue on GitHub with the "upgrade" label