chore(version): update app version to 1.3.5+85 and improve test coverage reporting in CI

This commit is contained in:
mso7nueh
2025-12-08 11:19:08 +03:00
parent abe4985f0e
commit c2a506cdbf
148 changed files with 12395 additions and 1889 deletions

View File

@@ -3,30 +3,42 @@ import 'package:flutter_test/flutter_test.dart';
void main() {
group('CalendarModel', () {
test('создает CalendarModel с правильными значениями', () {
test('создает экземпляр с данными', () {
const model = CalendarModel(
date: '2024-01-01',
date: '2024-01-15',
isCurrentDayIncludedInTheChosenDietProgression: true,
diary: null,
);
expect(model.date, '2024-01-01');
expect(model.isCurrentDayIncludedInTheChosenDietProgression, isTrue);
expect(model.diary, isNull);
expect(model.date, '2024-01-15');
expect(model.isCurrentDayIncludedInTheChosenDietProgression, true);
expect(model.diary, null);
});
test('fromJson создает CalendarModel из JSON', () {
test('fromJson создает модель из JSON', () {
final json = {
'date': '2024-01-01',
'date': '2024-01-15',
'is_current_day_included_in_the_chosen_diet_progression': true,
'diary': null,
};
final model = CalendarModel.fromJson(json);
expect(model.date, '2024-01-01');
expect(model.isCurrentDayIncludedInTheChosenDietProgression, isTrue);
expect(model.date, '2024-01-15');
expect(model.isCurrentDayIncludedInTheChosenDietProgression, true);
});
test('toJson преобразует модель в JSON', () {
const model = CalendarModel(
date: '2024-01-15',
isCurrentDayIncludedInTheChosenDietProgression: true,
diary: null,
);
final json = model.toJson();
expect(json['date'], '2024-01-15');
expect(json['is_current_day_included_in_the_chosen_diet_progression'], true);
});
});
}