mirror of
https://github.com/wger-project/flutter.git
synced 2026-02-18 00:17:48 +01:00
Upgrade dependencies and recreate generated files
This commit is contained in:
@@ -7,7 +7,10 @@ part of 'weight_entry.dart';
|
||||
// **************************************************************************
|
||||
|
||||
WeightEntry _$WeightEntryFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'weight', 'date']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'weight', 'date'],
|
||||
);
|
||||
return WeightEntry(
|
||||
id: json['id'] as int?,
|
||||
weight: stringToNum(json['weight'] as String?),
|
||||
@@ -15,7 +18,8 @@ WeightEntry _$WeightEntryFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$WeightEntryToJson(WeightEntry instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$WeightEntryToJson(WeightEntry instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'weight': numToString(instance.weight),
|
||||
'date': toDate(instance.date),
|
||||
|
||||
@@ -7,14 +7,18 @@ part of 'category.dart';
|
||||
// **************************************************************************
|
||||
|
||||
ExerciseCategory _$ExerciseCategoryFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name'],
|
||||
);
|
||||
return ExerciseCategory(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$ExerciseCategoryToJson(ExerciseCategory instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$ExerciseCategoryToJson(ExerciseCategory instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
};
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'comment.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Comment _$CommentFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'comment']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'comment'],
|
||||
);
|
||||
return Comment(
|
||||
id: json['id'] as int,
|
||||
comment: json['comment'] as String,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'equipment.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Equipment _$EquipmentFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name'],
|
||||
);
|
||||
return Equipment(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
|
||||
@@ -7,19 +7,22 @@ part of 'exercise.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Exercise _$ExerciseFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const [
|
||||
'id',
|
||||
'uuid',
|
||||
'creation_date',
|
||||
'name',
|
||||
'description',
|
||||
'category',
|
||||
'muscles',
|
||||
'muscles_secondary',
|
||||
'equipment',
|
||||
'images',
|
||||
'comments'
|
||||
]);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'uuid',
|
||||
'creation_date',
|
||||
'name',
|
||||
'description',
|
||||
'category',
|
||||
'muscles',
|
||||
'muscles_secondary',
|
||||
'equipment',
|
||||
'images',
|
||||
'comments'
|
||||
],
|
||||
);
|
||||
return Exercise(
|
||||
id: json['id'] as int,
|
||||
uuid: json['uuid'] as String,
|
||||
@@ -41,7 +44,8 @@ Exercise _$ExerciseFromJson(Map<String, dynamic> json) {
|
||||
tips: (json['comments'] as List<dynamic>?)
|
||||
?.map((e) => Comment.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
)..categoryObj = ExerciseCategory.fromJson(json['category'] as Map<String, dynamic>);
|
||||
)..categoryObj =
|
||||
ExerciseCategory.fromJson(json['category'] as Map<String, dynamic>);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$ExerciseToJson(Exercise instance) => <String, dynamic>{
|
||||
@@ -52,7 +56,8 @@ Map<String, dynamic> _$ExerciseToJson(Exercise instance) => <String, dynamic>{
|
||||
'description': instance.description,
|
||||
'category': instance.categoryObj.toJson(),
|
||||
'muscles': instance.muscles.map((e) => e.toJson()).toList(),
|
||||
'muscles_secondary': instance.musclesSecondary.map((e) => e.toJson()).toList(),
|
||||
'muscles_secondary':
|
||||
instance.musclesSecondary.map((e) => e.toJson()).toList(),
|
||||
'equipment': instance.equipment.map((e) => e.toJson()).toList(),
|
||||
'images': instance.images.map((e) => e.toJson()).toList(),
|
||||
'comments': instance.tips.map((e) => e.toJson()).toList(),
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'image.dart';
|
||||
// **************************************************************************
|
||||
|
||||
ExerciseImage _$ExerciseImageFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'uuid', 'exercise_base', 'image']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'uuid', 'exercise_base', 'image'],
|
||||
);
|
||||
return ExerciseImage(
|
||||
id: json['id'] as int,
|
||||
uuid: json['uuid'] as String,
|
||||
@@ -17,7 +20,8 @@ ExerciseImage _$ExerciseImageFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$ExerciseImageToJson(ExerciseImage instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$ExerciseImageToJson(ExerciseImage instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'uuid': instance.uuid,
|
||||
'exercise_base': instance.exerciseBaseId,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'muscle.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Muscle _$MuscleFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name', 'is_front']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name', 'is_front'],
|
||||
);
|
||||
return Muscle(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'image.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Image _$ImageFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'date', 'image']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'date', 'image'],
|
||||
);
|
||||
return Image(
|
||||
id: json['id'] as int?,
|
||||
date: DateTime.parse(json['date'] as String),
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'measurement_category.dart';
|
||||
// **************************************************************************
|
||||
|
||||
MeasurementCategory _$MeasurementCategoryFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name', 'unit']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name', 'unit'],
|
||||
);
|
||||
return MeasurementCategory(
|
||||
id: json['id'] as int?,
|
||||
name: json['name'] as String,
|
||||
@@ -19,7 +22,9 @@ MeasurementCategory _$MeasurementCategoryFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$MeasurementCategoryToJson(MeasurementCategory instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$MeasurementCategoryToJson(
|
||||
MeasurementCategory instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
'unit': instance.unit,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'measurement_entry.dart';
|
||||
// **************************************************************************
|
||||
|
||||
MeasurementEntry _$MeasurementEntryFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'category', 'date', 'value', 'notes']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'category', 'date', 'value', 'notes'],
|
||||
);
|
||||
return MeasurementEntry(
|
||||
id: json['id'] as int?,
|
||||
category: json['category'] as int,
|
||||
@@ -17,7 +20,8 @@ MeasurementEntry _$MeasurementEntryFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$MeasurementEntryToJson(MeasurementEntry instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$MeasurementEntryToJson(MeasurementEntry instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'category': instance.category,
|
||||
'date': toDate(instance.date),
|
||||
|
||||
@@ -7,19 +7,22 @@ part of 'ingredient.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Ingredient _$IngredientFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const [
|
||||
'id',
|
||||
'name',
|
||||
'creation_date',
|
||||
'energy',
|
||||
'carbohydrates',
|
||||
'carbohydrates_sugar',
|
||||
'protein',
|
||||
'fat',
|
||||
'fat_saturated',
|
||||
'fibres',
|
||||
'sodium'
|
||||
]);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'name',
|
||||
'creation_date',
|
||||
'energy',
|
||||
'carbohydrates',
|
||||
'carbohydrates_sugar',
|
||||
'protein',
|
||||
'fat',
|
||||
'fat_saturated',
|
||||
'fibres',
|
||||
'sodium'
|
||||
],
|
||||
);
|
||||
return Ingredient(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
@@ -35,7 +38,8 @@ Ingredient _$IngredientFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$IngredientToJson(Ingredient instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$IngredientToJson(Ingredient instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
'creation_date': toDate(instance.creationDate),
|
||||
|
||||
@@ -7,17 +7,22 @@ part of 'ingredient_weight_unit.dart';
|
||||
// **************************************************************************
|
||||
|
||||
IngredientWeightUnit _$IngredientWeightUnitFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'weight_unit', 'ingredient', 'grams', 'amount']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'weight_unit', 'ingredient', 'grams', 'amount'],
|
||||
);
|
||||
return IngredientWeightUnit(
|
||||
id: json['id'] as int,
|
||||
weightUnit: WeightUnit.fromJson(json['weight_unit'] as Map<String, dynamic>),
|
||||
weightUnit:
|
||||
WeightUnit.fromJson(json['weight_unit'] as Map<String, dynamic>),
|
||||
ingredient: Ingredient.fromJson(json['ingredient'] as Map<String, dynamic>),
|
||||
grams: json['grams'] as int,
|
||||
amount: (json['amount'] as num).toDouble(),
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$IngredientWeightUnitToJson(IngredientWeightUnit instance) =>
|
||||
Map<String, dynamic> _$IngredientWeightUnitToJson(
|
||||
IngredientWeightUnit instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'weight_unit': instance.weightUnit,
|
||||
|
||||
@@ -7,8 +7,17 @@ part of 'log.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Log _$LogFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json,
|
||||
requiredKeys: const ['id', 'plan', 'datetime', 'ingredient', 'weight_unit', 'amount']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'plan',
|
||||
'datetime',
|
||||
'ingredient',
|
||||
'weight_unit',
|
||||
'amount'
|
||||
],
|
||||
);
|
||||
return Log(
|
||||
id: json['id'] as int?,
|
||||
mealId: json['meal'] as int?,
|
||||
|
||||
@@ -6,13 +6,11 @@ part of 'meal.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
Meal _$MealFromJson(Map<String, dynamic> json) {
|
||||
return Meal(
|
||||
id: json['id'] as int?,
|
||||
time: stringToTime(json['time'] as String?),
|
||||
name: json['name'] as String?,
|
||||
)..planId = json['plan'] as int;
|
||||
}
|
||||
Meal _$MealFromJson(Map<String, dynamic> json) => Meal(
|
||||
id: json['id'] as int?,
|
||||
time: stringToTime(json['time'] as String?),
|
||||
name: json['name'] as String?,
|
||||
)..planId = json['plan'] as int;
|
||||
|
||||
Map<String, dynamic> _$MealToJson(Meal instance) => <String, dynamic>{
|
||||
'id': instance.id,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'meal_item.dart';
|
||||
// **************************************************************************
|
||||
|
||||
MealItem _$MealItemFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'amount']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'amount'],
|
||||
);
|
||||
return MealItem(
|
||||
id: json['id'] as int?,
|
||||
mealId: json['meal'] as int?,
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'nutritional_plan.dart';
|
||||
// **************************************************************************
|
||||
|
||||
NutritionalPlan _$NutritionalPlanFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'description', 'creation_date']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'description', 'creation_date'],
|
||||
);
|
||||
return NutritionalPlan(
|
||||
id: json['id'] as int?,
|
||||
description: json['description'] as String,
|
||||
@@ -15,7 +18,8 @@ NutritionalPlan _$NutritionalPlanFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$NutritionalPlanToJson(NutritionalPlan instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$NutritionalPlanToJson(NutritionalPlan instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'description': instance.description,
|
||||
'creation_date': toDate(instance.creationDate),
|
||||
|
||||
@@ -7,14 +7,18 @@ part of 'weight_unit.dart';
|
||||
// **************************************************************************
|
||||
|
||||
WeightUnit _$WeightUnitFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name'],
|
||||
);
|
||||
return WeightUnit(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$WeightUnitToJson(WeightUnit instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$WeightUnitToJson(WeightUnit instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
};
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'day.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Day _$DayFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'training', 'description', 'day']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'training', 'description', 'day'],
|
||||
);
|
||||
return Day()
|
||||
..id = json['id'] as int?
|
||||
..workoutId = json['training'] as int
|
||||
|
||||
@@ -7,16 +7,19 @@ part of 'log.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Log _$LogFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const [
|
||||
'id',
|
||||
'exercise',
|
||||
'workout',
|
||||
'reps',
|
||||
'repetition_unit',
|
||||
'weight',
|
||||
'weight_unit',
|
||||
'date'
|
||||
]);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'exercise',
|
||||
'workout',
|
||||
'reps',
|
||||
'repetition_unit',
|
||||
'weight',
|
||||
'weight_unit',
|
||||
'date'
|
||||
],
|
||||
);
|
||||
return Log(
|
||||
id: json['id'] as int?,
|
||||
exerciseId: json['exercise'] as int,
|
||||
|
||||
@@ -7,14 +7,18 @@ part of 'repetition_unit.dart';
|
||||
// **************************************************************************
|
||||
|
||||
RepetitionUnit _$RepetitionUnitFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name'],
|
||||
);
|
||||
return RepetitionUnit(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$RepetitionUnitToJson(RepetitionUnit instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$RepetitionUnitToJson(RepetitionUnit instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
};
|
||||
|
||||
@@ -7,8 +7,17 @@ part of 'session.dart';
|
||||
// **************************************************************************
|
||||
|
||||
WorkoutSession _$WorkoutSessionFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json,
|
||||
requiredKeys: const ['id', 'workout', 'date', 'impression', 'time_start', 'time_end']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'workout',
|
||||
'date',
|
||||
'impression',
|
||||
'time_start',
|
||||
'time_end'
|
||||
],
|
||||
);
|
||||
return WorkoutSession()
|
||||
..id = json['id'] as int?
|
||||
..workoutId = json['workout'] as int
|
||||
@@ -19,7 +28,8 @@ WorkoutSession _$WorkoutSessionFromJson(Map<String, dynamic> json) {
|
||||
..timeEnd = stringToTime(json['time_end'] as String?);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$WorkoutSessionToJson(WorkoutSession instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$WorkoutSessionToJson(WorkoutSession instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'workout': instance.workoutId,
|
||||
'date': toDate(instance.date),
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'set.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Set _$SetFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'sets', 'order', 'comment']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'sets', 'order', 'comment'],
|
||||
);
|
||||
return Set(
|
||||
day: json['exerciseday'] as int,
|
||||
sets: json['sets'] as int,
|
||||
|
||||
@@ -7,18 +7,21 @@ part of 'setting.dart';
|
||||
// **************************************************************************
|
||||
|
||||
Setting _$SettingFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const [
|
||||
'id',
|
||||
'set',
|
||||
'order',
|
||||
'exercise',
|
||||
'repetition_unit',
|
||||
'reps',
|
||||
'weight',
|
||||
'weight_unit',
|
||||
'comment',
|
||||
'rir'
|
||||
]);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'id',
|
||||
'set',
|
||||
'order',
|
||||
'exercise',
|
||||
'repetition_unit',
|
||||
'reps',
|
||||
'weight',
|
||||
'weight_unit',
|
||||
'comment',
|
||||
'rir'
|
||||
],
|
||||
);
|
||||
return Setting(
|
||||
id: json['id'] as int?,
|
||||
setId: json['set'] as int,
|
||||
|
||||
@@ -7,14 +7,18 @@ part of 'weight_unit.dart';
|
||||
// **************************************************************************
|
||||
|
||||
WeightUnit _$WeightUnitFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'name']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'name'],
|
||||
);
|
||||
return WeightUnit(
|
||||
id: json['id'] as int,
|
||||
name: json['name'] as String,
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$WeightUnitToJson(WeightUnit instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$WeightUnitToJson(WeightUnit instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'name': instance.name,
|
||||
};
|
||||
|
||||
@@ -7,7 +7,10 @@ part of 'workout_plan.dart';
|
||||
// **************************************************************************
|
||||
|
||||
WorkoutPlan _$WorkoutPlanFromJson(Map<String, dynamic> json) {
|
||||
$checkKeys(json, requiredKeys: const ['id', 'creation_date', 'name', 'description']);
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const ['id', 'creation_date', 'name', 'description'],
|
||||
);
|
||||
return WorkoutPlan(
|
||||
id: json['id'] as int?,
|
||||
creationDate: DateTime.parse(json['creation_date'] as String),
|
||||
@@ -16,7 +19,8 @@ WorkoutPlan _$WorkoutPlanFromJson(Map<String, dynamic> json) {
|
||||
);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$WorkoutPlanToJson(WorkoutPlan instance) => <String, dynamic>{
|
||||
Map<String, dynamic> _$WorkoutPlanToJson(WorkoutPlan instance) =>
|
||||
<String, dynamic>{
|
||||
'id': instance.id,
|
||||
'creation_date': instance.creationDate.toIso8601String(),
|
||||
'name': instance.name,
|
||||
|
||||
41
pubspec.lock
41
pubspec.lock
@@ -7,14 +7,14 @@ packages:
|
||||
name: _fe_analyzer_shared
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "22.0.0"
|
||||
version: "30.0.0"
|
||||
analyzer:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: analyzer
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.7.2"
|
||||
version: "2.7.0"
|
||||
android_metadata:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@@ -84,7 +84,7 @@ packages:
|
||||
name: build_runner
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.4"
|
||||
version: "2.1.5"
|
||||
build_runner_core:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -175,7 +175,7 @@ packages:
|
||||
name: chewie
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.2.2"
|
||||
version: "1.1.0"
|
||||
chewie_audio:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -252,14 +252,14 @@ packages:
|
||||
name: cupertino_icons
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.3"
|
||||
version: "1.0.4"
|
||||
dart_style:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: dart_style
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.1"
|
||||
version: "2.2.0"
|
||||
equatable:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@@ -367,7 +367,7 @@ packages:
|
||||
name: flutter_math_fork
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.3.3+1"
|
||||
version: "0.5.0"
|
||||
flutter_plugin_android_lifecycle:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -381,7 +381,7 @@ packages:
|
||||
name: flutter_svg
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.22.0"
|
||||
version: "0.23.0+1"
|
||||
flutter_test:
|
||||
dependency: "direct dev"
|
||||
description: flutter
|
||||
@@ -510,14 +510,14 @@ packages:
|
||||
name: json_annotation
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.1.0"
|
||||
version: "4.3.0"
|
||||
json_serializable:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
name: json_serializable
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.1.4"
|
||||
version: "6.0.1"
|
||||
klizma:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -580,7 +580,7 @@ packages:
|
||||
name: mockito
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "5.0.15"
|
||||
version: "5.0.16"
|
||||
nested:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -706,7 +706,7 @@ packages:
|
||||
name: provider
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "5.0.0"
|
||||
version: "6.0.1"
|
||||
pub_semver:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -816,7 +816,14 @@ packages:
|
||||
name: source_gen
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.3"
|
||||
version: "1.1.1"
|
||||
source_helper:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: source_helper
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.3.0"
|
||||
source_span:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -963,7 +970,7 @@ packages:
|
||||
name: video_player
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.2.6"
|
||||
version: "2.2.7"
|
||||
video_player_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -1033,21 +1040,21 @@ packages:
|
||||
name: webview_flutter
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.2"
|
||||
version: "2.3.0"
|
||||
webview_flutter_android:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: webview_flutter_android
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.2.0"
|
||||
version: "2.2.1"
|
||||
webview_flutter_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: webview_flutter_platform_interface
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.3.0"
|
||||
version: "1.4.0"
|
||||
webview_flutter_wkwebview:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
||||
@@ -44,10 +44,10 @@ dependencies:
|
||||
http: ^0.13.3
|
||||
image_picker: ^0.8.4+1
|
||||
intl: ^0.17.0
|
||||
json_annotation: ^4.0.1
|
||||
json_annotation: ^4.3.0
|
||||
version: ^2.0.0
|
||||
package_info: ^2.0.2
|
||||
provider: ^5.0.0
|
||||
provider: ^6.0.1
|
||||
rive: ^0.7.33
|
||||
shared_preferences: ^2.0.7
|
||||
table_calendar: ^3.0.2
|
||||
@@ -60,7 +60,7 @@ dev_dependencies:
|
||||
# sdk: flutter
|
||||
build_runner: ^2.1.2
|
||||
flutter_launcher_icons: ^0.9.1
|
||||
json_serializable: ^4.1.4
|
||||
json_serializable: ^6.0.1
|
||||
mockito: ^5.0.15
|
||||
network_image_mock: ^2.0.1
|
||||
flutter_lints: ^1.0.4
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// in wger/test/gallery_screen_test.dart.
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/gallery/gallery_screen_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
import 'dart:async' as _i6;
|
||||
@@ -19,6 +19,7 @@ import 'package:wger/providers/gallery.dart' as _i4;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeAuthProvider_0 extends _i1.Fake implements _i2.AuthProvider {}
|
||||
|
||||
@@ -37,31 +38,33 @@ class MockGalleryProvider extends _i1.Mock implements _i4.GalleryProvider {
|
||||
}
|
||||
|
||||
@override
|
||||
List<_i5.Image> get images =>
|
||||
(super.noSuchMethod(Invocation.getter(#images), returnValue: <_i5.Image>[])
|
||||
as List<_i5.Image>);
|
||||
List<_i5.Image> get images => (super.noSuchMethod(Invocation.getter(#images),
|
||||
returnValue: <_i5.Image>[]) as List<_i5.Image>);
|
||||
@override
|
||||
set images(List<_i5.Image>? _images) =>
|
||||
super.noSuchMethod(Invocation.setter(#images, _images), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#images, _images),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i2.AuthProvider get auth =>
|
||||
(super.noSuchMethod(Invocation.getter(#auth), returnValue: _FakeAuthProvider_0())
|
||||
as _i2.AuthProvider);
|
||||
_i2.AuthProvider get auth => (super.noSuchMethod(Invocation.getter(#auth),
|
||||
returnValue: _FakeAuthProvider_0()) as _i2.AuthProvider);
|
||||
@override
|
||||
set auth(_i2.AuthProvider? _auth) =>
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i3.Client get client =>
|
||||
(super.noSuchMethod(Invocation.getter(#client), returnValue: _FakeClient_1()) as _i3.Client);
|
||||
_i3.Client get client => (super.noSuchMethod(Invocation.getter(#client),
|
||||
returnValue: _FakeClient_1()) as _i3.Client);
|
||||
@override
|
||||
set client(_i3.Client? _client) =>
|
||||
super.noSuchMethod(Invocation.setter(#client, _client), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#client, _client),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
bool get hasListeners =>
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) as bool);
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false)
|
||||
as bool);
|
||||
@override
|
||||
void clear() =>
|
||||
super.noSuchMethod(Invocation.method(#clear, []), returnValueForMissingStub: null);
|
||||
void clear() => super.noSuchMethod(Invocation.method(#clear, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i6.Future<void> fetchAndSetGallery() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetGallery, []),
|
||||
@@ -83,43 +86,50 @@ class MockGalleryProvider extends _i1.Mock implements _i4.GalleryProvider {
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i6.Future<void>);
|
||||
@override
|
||||
Uri makeUrl(String? path, {int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
Uri makeUrl(String? path,
|
||||
{int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#makeUrl, [path], {#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
Invocation.method(#makeUrl, [path],
|
||||
{#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
returnValue: _FakeUri_2()) as Uri);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> fetch(Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
_i6.Future<Map<String, dynamic>> fetch(Uri? uri) => (super.noSuchMethod(
|
||||
Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> post(Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#post, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> patch(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i6.Future<Map<String, dynamic>> patch(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#patch, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<_i3.Response> deleteRequest(String? url, int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_3())) as _i6.Future<_i3.Response>);
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_3()))
|
||||
as _i6.Future<_i3.Response>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
@override
|
||||
void addListener(_i8.VoidCallback? listener) => super
|
||||
.noSuchMethod(Invocation.method(#addListener, [listener]), returnValueForMissingStub: null);
|
||||
void addListener(_i8.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#addListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void removeListener(_i8.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#removeListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void dispose() =>
|
||||
super.noSuchMethod(Invocation.method(#dispose, []), returnValueForMissingStub: null);
|
||||
void dispose() => super.noSuchMethod(Invocation.method(#dispose, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void notifyListeners() =>
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []),
|
||||
returnValueForMissingStub: null);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/measurements/measurement_categories_screen_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
@@ -18,37 +18,43 @@ import 'package:wger/providers/measurement.dart' as _i4;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeWgerBaseProvider_0 extends _i1.Fake implements _i2.WgerBaseProvider {}
|
||||
class _FakeWgerBaseProvider_0 extends _i1.Fake implements _i2.WgerBaseProvider {
|
||||
}
|
||||
|
||||
class _FakeMeasurementCategory_1 extends _i1.Fake implements _i3.MeasurementCategory {}
|
||||
class _FakeMeasurementCategory_1 extends _i1.Fake
|
||||
implements _i3.MeasurementCategory {}
|
||||
|
||||
/// A class which mocks [MeasurementProvider].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockMeasurementProvider extends _i1.Mock implements _i4.MeasurementProvider {
|
||||
class MockMeasurementProvider extends _i1.Mock
|
||||
implements _i4.MeasurementProvider {
|
||||
MockMeasurementProvider() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
_i2.WgerBaseProvider get baseProvider =>
|
||||
(super.noSuchMethod(Invocation.getter(#baseProvider), returnValue: _FakeWgerBaseProvider_0())
|
||||
as _i2.WgerBaseProvider);
|
||||
(super.noSuchMethod(Invocation.getter(#baseProvider),
|
||||
returnValue: _FakeWgerBaseProvider_0()) as _i2.WgerBaseProvider);
|
||||
@override
|
||||
List<_i3.MeasurementCategory> get categories =>
|
||||
(super.noSuchMethod(Invocation.getter(#categories), returnValue: <_i3.MeasurementCategory>[])
|
||||
(super.noSuchMethod(Invocation.getter(#categories),
|
||||
returnValue: <_i3.MeasurementCategory>[])
|
||||
as List<_i3.MeasurementCategory>);
|
||||
@override
|
||||
bool get hasListeners =>
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) as bool);
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false)
|
||||
as bool);
|
||||
@override
|
||||
void clear() =>
|
||||
super.noSuchMethod(Invocation.method(#clear, []), returnValueForMissingStub: null);
|
||||
void clear() => super.noSuchMethod(Invocation.method(#clear, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i3.MeasurementCategory findCategoryById(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#findCategoryById, [id]),
|
||||
returnValue: _FakeMeasurementCategory_1()) as _i3.MeasurementCategory);
|
||||
_i3.MeasurementCategory findCategoryById(int? id) => (super.noSuchMethod(
|
||||
Invocation.method(#findCategoryById, [id]),
|
||||
returnValue: _FakeMeasurementCategory_1()) as _i3.MeasurementCategory);
|
||||
@override
|
||||
_i5.Future<void> fetchAndSetCategories() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetCategories, []),
|
||||
@@ -60,10 +66,10 @@ class MockMeasurementProvider extends _i1.Mock implements _i4.MeasurementProvide
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
_i5.Future<void> fetchAndSetAllCategoriesAndEntries() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetAllCategoriesAndEntries, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
_i5.Future<void> fetchAndSetAllCategoriesAndEntries() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetAllCategoriesAndEntries, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
_i5.Future<void> addCategory(_i3.MeasurementCategory? category) =>
|
||||
(super.noSuchMethod(Invocation.method(#addCategory, [category]),
|
||||
@@ -76,7 +82,8 @@ class MockMeasurementProvider extends _i1.Mock implements _i4.MeasurementProvide
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
_i5.Future<void> editCategory(int? id, String? newName, String? newUnit) =>
|
||||
(super.noSuchMethod(Invocation.method(#editCategory, [id, newName, newUnit]),
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#editCategory, [id, newName, newUnit]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
@@ -90,25 +97,28 @@ class MockMeasurementProvider extends _i1.Mock implements _i4.MeasurementProvide
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
_i5.Future<void> editEntry(
|
||||
int? id, int? categoryId, num? newValue, String? newNotes, DateTime? newDate) =>
|
||||
_i5.Future<void> editEntry(int? id, int? categoryId, num? newValue,
|
||||
String? newNotes, DateTime? newDate) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#editEntry, [id, categoryId, newValue, newNotes, newDate]),
|
||||
Invocation.method(
|
||||
#editEntry, [id, categoryId, newValue, newNotes, newDate]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i5.Future<void>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
@override
|
||||
void addListener(_i7.VoidCallback? listener) => super
|
||||
.noSuchMethod(Invocation.method(#addListener, [listener]), returnValueForMissingStub: null);
|
||||
void addListener(_i7.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#addListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void removeListener(_i7.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#removeListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void dispose() =>
|
||||
super.noSuchMethod(Invocation.method(#dispose, []), returnValueForMissingStub: null);
|
||||
void dispose() => super.noSuchMethod(Invocation.method(#dispose, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void notifyListeners() =>
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []),
|
||||
returnValueForMissingStub: null);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/measurements/measurement_provider_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
@@ -16,6 +16,7 @@ import 'package:wger/providers/base_provider.dart' as _i4;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeAuthProvider_0 extends _i1.Fake implements _i2.AuthProvider {}
|
||||
|
||||
@@ -34,43 +35,49 @@ class MockWgerBaseProvider extends _i1.Mock implements _i4.WgerBaseProvider {
|
||||
}
|
||||
|
||||
@override
|
||||
_i2.AuthProvider get auth =>
|
||||
(super.noSuchMethod(Invocation.getter(#auth), returnValue: _FakeAuthProvider_0())
|
||||
as _i2.AuthProvider);
|
||||
_i2.AuthProvider get auth => (super.noSuchMethod(Invocation.getter(#auth),
|
||||
returnValue: _FakeAuthProvider_0()) as _i2.AuthProvider);
|
||||
@override
|
||||
set auth(_i2.AuthProvider? _auth) =>
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i3.Client get client =>
|
||||
(super.noSuchMethod(Invocation.getter(#client), returnValue: _FakeClient_1()) as _i3.Client);
|
||||
_i3.Client get client => (super.noSuchMethod(Invocation.getter(#client),
|
||||
returnValue: _FakeClient_1()) as _i3.Client);
|
||||
@override
|
||||
set client(_i3.Client? _client) =>
|
||||
super.noSuchMethod(Invocation.setter(#client, _client), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#client, _client),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
Uri makeUrl(String? path, {int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
Uri makeUrl(String? path,
|
||||
{int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#makeUrl, [path], {#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
Invocation.method(#makeUrl, [path],
|
||||
{#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
returnValue: _FakeUri_2()) as Uri);
|
||||
@override
|
||||
_i5.Future<Map<String, dynamic>> fetch(Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i5.Future<Map<String, dynamic>>);
|
||||
_i5.Future<Map<String, dynamic>> fetch(Uri? uri) => (super.noSuchMethod(
|
||||
Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i5.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i5.Future<Map<String, dynamic>> post(Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#post, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i5.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i5.Future<Map<String, dynamic>> patch(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i5.Future<Map<String, dynamic>> patch(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#patch, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i5.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i5.Future<_i3.Response> deleteRequest(String? url, int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_3())) as _i5.Future<_i3.Response>);
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_3()))
|
||||
as _i5.Future<_i3.Response>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// in wger/test/nutritional_plan_form_test.dart.
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/nutrition/nutritional_plan_form_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
import 'dart:async' as _i9;
|
||||
@@ -21,6 +21,7 @@ import 'package:wger/providers/nutrition.dart' as _i8;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeAuthProvider_0 extends _i1.Fake implements _i2.AuthProvider {}
|
||||
|
||||
@@ -41,38 +42,41 @@ class _FakeResponse_7 extends _i1.Fake implements _i3.Response {}
|
||||
/// A class which mocks [NutritionPlansProvider].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockNutritionPlansProvider extends _i1.Mock implements _i8.NutritionPlansProvider {
|
||||
class MockNutritionPlansProvider extends _i1.Mock
|
||||
implements _i8.NutritionPlansProvider {
|
||||
MockNutritionPlansProvider() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
List<_i4.NutritionalPlan> get items =>
|
||||
(super.noSuchMethod(Invocation.getter(#items), returnValue: <_i4.NutritionalPlan>[])
|
||||
as List<_i4.NutritionalPlan>);
|
||||
(super.noSuchMethod(Invocation.getter(#items),
|
||||
returnValue: <_i4.NutritionalPlan>[]) as List<_i4.NutritionalPlan>);
|
||||
@override
|
||||
_i2.AuthProvider get auth =>
|
||||
(super.noSuchMethod(Invocation.getter(#auth), returnValue: _FakeAuthProvider_0())
|
||||
as _i2.AuthProvider);
|
||||
_i2.AuthProvider get auth => (super.noSuchMethod(Invocation.getter(#auth),
|
||||
returnValue: _FakeAuthProvider_0()) as _i2.AuthProvider);
|
||||
@override
|
||||
set auth(_i2.AuthProvider? _auth) =>
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i3.Client get client =>
|
||||
(super.noSuchMethod(Invocation.getter(#client), returnValue: _FakeClient_1()) as _i3.Client);
|
||||
_i3.Client get client => (super.noSuchMethod(Invocation.getter(#client),
|
||||
returnValue: _FakeClient_1()) as _i3.Client);
|
||||
@override
|
||||
set client(_i3.Client? _client) =>
|
||||
super.noSuchMethod(Invocation.setter(#client, _client), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#client, _client),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
bool get hasListeners =>
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) as bool);
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false)
|
||||
as bool);
|
||||
@override
|
||||
void clear() =>
|
||||
super.noSuchMethod(Invocation.method(#clear, []), returnValueForMissingStub: null);
|
||||
void clear() => super.noSuchMethod(Invocation.method(#clear, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i4.NutritionalPlan findById(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#findById, [id]), returnValue: _FakeNutritionalPlan_2())
|
||||
as _i4.NutritionalPlan);
|
||||
(super.noSuchMethod(Invocation.method(#findById, [id]),
|
||||
returnValue: _FakeNutritionalPlan_2()) as _i4.NutritionalPlan);
|
||||
@override
|
||||
_i5.Meal? findMealById(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#findMealById, [id])) as _i5.Meal?);
|
||||
@@ -89,17 +93,20 @@ class MockNutritionPlansProvider extends _i1.Mock implements _i8.NutritionPlansP
|
||||
@override
|
||||
_i9.Future<_i4.NutritionalPlan> fetchAndSetPlanSparse(int? planId) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetPlanSparse, [planId]),
|
||||
returnValue: Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
returnValue:
|
||||
Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
as _i9.Future<_i4.NutritionalPlan>);
|
||||
@override
|
||||
_i9.Future<_i4.NutritionalPlan> fetchAndSetPlanFull(int? planId) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetPlanFull, [planId]),
|
||||
returnValue: Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
returnValue:
|
||||
Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
as _i9.Future<_i4.NutritionalPlan>);
|
||||
@override
|
||||
_i9.Future<_i4.NutritionalPlan> addPlan(_i4.NutritionalPlan? planData) =>
|
||||
(super.noSuchMethod(Invocation.method(#addPlan, [planData]),
|
||||
returnValue: Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
returnValue:
|
||||
Future<_i4.NutritionalPlan>.value(_FakeNutritionalPlan_2()))
|
||||
as _i9.Future<_i4.NutritionalPlan>);
|
||||
@override
|
||||
_i9.Future<void> editPlan(_i4.NutritionalPlan? plan) =>
|
||||
@@ -107,26 +114,31 @@ class MockNutritionPlansProvider extends _i1.Mock implements _i8.NutritionPlansP
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<void> deletePlan(int? id) => (super.noSuchMethod(Invocation.method(#deletePlan, [id]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
_i9.Future<void> deletePlan(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deletePlan, [id]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<_i5.Meal> addMeal(_i5.Meal? meal, int? planId) =>
|
||||
(super.noSuchMethod(Invocation.method(#addMeal, [meal, planId]),
|
||||
returnValue: Future<_i5.Meal>.value(_FakeMeal_3())) as _i9.Future<_i5.Meal>);
|
||||
returnValue: Future<_i5.Meal>.value(_FakeMeal_3()))
|
||||
as _i9.Future<_i5.Meal>);
|
||||
@override
|
||||
_i9.Future<_i5.Meal> editMeal(_i5.Meal? meal) =>
|
||||
(super.noSuchMethod(Invocation.method(#editMeal, [meal]),
|
||||
returnValue: Future<_i5.Meal>.value(_FakeMeal_3())) as _i9.Future<_i5.Meal>);
|
||||
returnValue: Future<_i5.Meal>.value(_FakeMeal_3()))
|
||||
as _i9.Future<_i5.Meal>);
|
||||
@override
|
||||
_i9.Future<void> deleteMeal(_i5.Meal? meal) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteMeal, [meal]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<_i6.MealItem> addMealItem(_i6.MealItem? mealItem, _i5.Meal? meal) =>
|
||||
_i9.Future<_i6.MealItem> addMealItem(
|
||||
_i6.MealItem? mealItem, _i5.Meal? meal) =>
|
||||
(super.noSuchMethod(Invocation.method(#addMealItem, [mealItem, meal]),
|
||||
returnValue: Future<_i6.MealItem>.value(_FakeMealItem_4())) as _i9.Future<_i6.MealItem>);
|
||||
returnValue: Future<_i6.MealItem>.value(_FakeMealItem_4()))
|
||||
as _i9.Future<_i6.MealItem>);
|
||||
@override
|
||||
_i9.Future<void> deleteMealItem(_i6.MealItem? mealItem) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteMealItem, [mealItem]),
|
||||
@@ -143,15 +155,25 @@ class MockNutritionPlansProvider extends _i1.Mock implements _i8.NutritionPlansP
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<List<dynamic>> searchIngredient(String? name, [String? languageCode = r'en']) =>
|
||||
(super.noSuchMethod(Invocation.method(#searchIngredient, [name, languageCode]),
|
||||
returnValue: Future<List<dynamic>>.value(<dynamic>[])) as _i9.Future<List<dynamic>>);
|
||||
_i9.Future<List<dynamic>> searchIngredient(String? name,
|
||||
[String? languageCode = r'en']) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#searchIngredient, [name, languageCode]),
|
||||
returnValue: Future<List<dynamic>>.value(<dynamic>[]))
|
||||
as _i9.Future<List<dynamic>>);
|
||||
@override
|
||||
_i9.Future<void> logMealToDiary(_i5.Meal? meal) =>
|
||||
(super.noSuchMethod(Invocation.method(#logMealToDiary, [meal]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<void> logIngredentToDiary(_i6.MealItem? mealItem, int? planId,
|
||||
[DateTime? dateTime]) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#logIngredentToDiary, [mealItem, planId, dateTime]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
_i9.Future<void> deleteLog(int? logId, int? planId) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteLog, [logId, planId]),
|
||||
returnValue: Future<void>.value(),
|
||||
@@ -162,43 +184,50 @@ class MockNutritionPlansProvider extends _i1.Mock implements _i8.NutritionPlansP
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i9.Future<void>);
|
||||
@override
|
||||
Uri makeUrl(String? path, {int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
Uri makeUrl(String? path,
|
||||
{int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#makeUrl, [path], {#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
Invocation.method(#makeUrl, [path],
|
||||
{#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
returnValue: _FakeUri_6()) as Uri);
|
||||
@override
|
||||
_i9.Future<Map<String, dynamic>> fetch(Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i9.Future<Map<String, dynamic>>);
|
||||
_i9.Future<Map<String, dynamic>> fetch(Uri? uri) => (super.noSuchMethod(
|
||||
Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i9.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i9.Future<Map<String, dynamic>> post(Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#post, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i9.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i9.Future<Map<String, dynamic>> patch(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i9.Future<Map<String, dynamic>> patch(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#patch, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i9.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i9.Future<_i3.Response> deleteRequest(String? url, int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_7())) as _i9.Future<_i3.Response>);
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_7()))
|
||||
as _i9.Future<_i3.Response>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
@override
|
||||
void addListener(_i10.VoidCallback? listener) => super
|
||||
.noSuchMethod(Invocation.method(#addListener, [listener]), returnValueForMissingStub: null);
|
||||
void addListener(_i10.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#addListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void removeListener(_i10.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#removeListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void dispose() =>
|
||||
super.noSuchMethod(Invocation.method(#dispose, []), returnValueForMissingStub: null);
|
||||
void dispose() => super.noSuchMethod(Invocation.method(#dispose, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void notifyListeners() =>
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []),
|
||||
returnValueForMissingStub: null);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// in wger/test/base_provider_test.dart.
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/other/base_provider_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
import 'dart:async' as _i5;
|
||||
@@ -19,10 +19,12 @@ import 'package:mockito/mockito.dart' as _i1;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeResponse_0 extends _i1.Fake implements _i2.Response {}
|
||||
|
||||
class _FakeStreamedResponse_1 extends _i1.Fake implements _i3.StreamedResponse {}
|
||||
class _FakeStreamedResponse_1 extends _i1.Fake implements _i3.StreamedResponse {
|
||||
}
|
||||
|
||||
/// A class which mocks [Client].
|
||||
///
|
||||
@@ -35,51 +37,73 @@ class MockClient extends _i1.Mock implements _i4.Client {
|
||||
@override
|
||||
_i5.Future<_i2.Response> head(Uri? url, {Map<String, String>? headers}) =>
|
||||
(super.noSuchMethod(Invocation.method(#head, [url], {#headers: headers}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<_i2.Response> get(Uri? url, {Map<String, String>? headers}) =>
|
||||
(super.noSuchMethod(Invocation.method(#get, [url], {#headers: headers}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<_i2.Response> post(Uri? url,
|
||||
{Map<String, String>? headers, Object? body, _i6.Encoding? encoding}) =>
|
||||
{Map<String, String>? headers,
|
||||
Object? body,
|
||||
_i6.Encoding? encoding}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#post, [url], {#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
Invocation.method(#post, [url],
|
||||
{#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<_i2.Response> put(Uri? url,
|
||||
{Map<String, String>? headers, Object? body, _i6.Encoding? encoding}) =>
|
||||
{Map<String, String>? headers,
|
||||
Object? body,
|
||||
_i6.Encoding? encoding}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#put, [url], {#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
Invocation.method(#put, [url],
|
||||
{#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<_i2.Response> patch(Uri? url,
|
||||
{Map<String, String>? headers, Object? body, _i6.Encoding? encoding}) =>
|
||||
{Map<String, String>? headers,
|
||||
Object? body,
|
||||
_i6.Encoding? encoding}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#patch, [url], {#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
Invocation.method(#patch, [url],
|
||||
{#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<_i2.Response> delete(Uri? url,
|
||||
{Map<String, String>? headers, Object? body, _i6.Encoding? encoding}) =>
|
||||
{Map<String, String>? headers,
|
||||
Object? body,
|
||||
_i6.Encoding? encoding}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#delete, [url], {#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0())) as _i5.Future<_i2.Response>);
|
||||
Invocation.method(#delete, [url],
|
||||
{#headers: headers, #body: body, #encoding: encoding}),
|
||||
returnValue: Future<_i2.Response>.value(_FakeResponse_0()))
|
||||
as _i5.Future<_i2.Response>);
|
||||
@override
|
||||
_i5.Future<String> read(Uri? url, {Map<String, String>? headers}) =>
|
||||
(super.noSuchMethod(Invocation.method(#read, [url], {#headers: headers}),
|
||||
returnValue: Future<String>.value('')) as _i5.Future<String>);
|
||||
@override
|
||||
_i5.Future<_i7.Uint8List> readBytes(Uri? url, {Map<String, String>? headers}) =>
|
||||
(super.noSuchMethod(Invocation.method(#readBytes, [url], {#headers: headers}),
|
||||
returnValue: Future<_i7.Uint8List>.value(_i7.Uint8List(0))) as _i5.Future<_i7.Uint8List>);
|
||||
_i5.Future<_i7.Uint8List> readBytes(Uri? url,
|
||||
{Map<String, String>? headers}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#readBytes, [url], {#headers: headers}),
|
||||
returnValue: Future<_i7.Uint8List>.value(_i7.Uint8List(0)))
|
||||
as _i5.Future<_i7.Uint8List>);
|
||||
@override
|
||||
_i5.Future<_i3.StreamedResponse> send(_i8.BaseRequest? request) =>
|
||||
(super.noSuchMethod(Invocation.method(#send, [request]),
|
||||
returnValue: Future<_i3.StreamedResponse>.value(_FakeStreamedResponse_1()))
|
||||
returnValue:
|
||||
Future<_i3.StreamedResponse>.value(_FakeStreamedResponse_1()))
|
||||
as _i5.Future<_i3.StreamedResponse>);
|
||||
@override
|
||||
void close() =>
|
||||
super.noSuchMethod(Invocation.method(#close, []), returnValueForMissingStub: null);
|
||||
void close() => super.noSuchMethod(Invocation.method(#close, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// in wger/test/workout_form_test.dart.
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/workout/workout_form_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
import 'dart:async' as _i13;
|
||||
@@ -26,6 +26,7 @@ import 'package:wger/providers/workout_plans.dart' as _i12;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeWeightUnit_0 extends _i1.Fake implements _i2.WeightUnit {}
|
||||
|
||||
@@ -54,73 +55,79 @@ class _FakeResponse_11 extends _i1.Fake implements _i5.Response {}
|
||||
/// A class which mocks [WorkoutPlansProvider].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWorkoutPlansProvider extends _i1.Mock implements _i12.WorkoutPlansProvider {
|
||||
class MockWorkoutPlansProvider extends _i1.Mock
|
||||
implements _i12.WorkoutPlansProvider {
|
||||
MockWorkoutPlansProvider() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
List<_i6.WorkoutPlan> get items =>
|
||||
(super.noSuchMethod(Invocation.getter(#items), returnValue: <_i6.WorkoutPlan>[])
|
||||
as List<_i6.WorkoutPlan>);
|
||||
(super.noSuchMethod(Invocation.getter(#items),
|
||||
returnValue: <_i6.WorkoutPlan>[]) as List<_i6.WorkoutPlan>);
|
||||
@override
|
||||
List<_i2.WeightUnit> get weightUnits =>
|
||||
(super.noSuchMethod(Invocation.getter(#weightUnits), returnValue: <_i2.WeightUnit>[])
|
||||
as List<_i2.WeightUnit>);
|
||||
(super.noSuchMethod(Invocation.getter(#weightUnits),
|
||||
returnValue: <_i2.WeightUnit>[]) as List<_i2.WeightUnit>);
|
||||
@override
|
||||
_i2.WeightUnit get defaultWeightUnit =>
|
||||
(super.noSuchMethod(Invocation.getter(#defaultWeightUnit), returnValue: _FakeWeightUnit_0())
|
||||
as _i2.WeightUnit);
|
||||
(super.noSuchMethod(Invocation.getter(#defaultWeightUnit),
|
||||
returnValue: _FakeWeightUnit_0()) as _i2.WeightUnit);
|
||||
@override
|
||||
List<_i3.RepetitionUnit> get repetitionUnits =>
|
||||
(super.noSuchMethod(Invocation.getter(#repetitionUnits), returnValue: <_i3.RepetitionUnit>[])
|
||||
as List<_i3.RepetitionUnit>);
|
||||
(super.noSuchMethod(Invocation.getter(#repetitionUnits),
|
||||
returnValue: <_i3.RepetitionUnit>[]) as List<_i3.RepetitionUnit>);
|
||||
@override
|
||||
_i3.RepetitionUnit get defaultRepetitionUnit =>
|
||||
(super.noSuchMethod(Invocation.getter(#defaultRepetitionUnit),
|
||||
returnValue: _FakeRepetitionUnit_1()) as _i3.RepetitionUnit);
|
||||
@override
|
||||
_i4.AuthProvider get auth =>
|
||||
(super.noSuchMethod(Invocation.getter(#auth), returnValue: _FakeAuthProvider_2())
|
||||
as _i4.AuthProvider);
|
||||
_i4.AuthProvider get auth => (super.noSuchMethod(Invocation.getter(#auth),
|
||||
returnValue: _FakeAuthProvider_2()) as _i4.AuthProvider);
|
||||
@override
|
||||
set auth(_i4.AuthProvider? _auth) =>
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i5.Client get client =>
|
||||
(super.noSuchMethod(Invocation.getter(#client), returnValue: _FakeClient_3()) as _i5.Client);
|
||||
_i5.Client get client => (super.noSuchMethod(Invocation.getter(#client),
|
||||
returnValue: _FakeClient_3()) as _i5.Client);
|
||||
@override
|
||||
set client(_i5.Client? _client) =>
|
||||
super.noSuchMethod(Invocation.setter(#client, _client), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#client, _client),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
bool get hasListeners =>
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) as bool);
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false)
|
||||
as bool);
|
||||
@override
|
||||
void clear() =>
|
||||
super.noSuchMethod(Invocation.method(#clear, []), returnValueForMissingStub: null);
|
||||
void clear() => super.noSuchMethod(Invocation.method(#clear, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i6.WorkoutPlan findById(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#findById, [id]), returnValue: _FakeWorkoutPlan_4())
|
||||
as _i6.WorkoutPlan);
|
||||
(super.noSuchMethod(Invocation.method(#findById, [id]),
|
||||
returnValue: _FakeWorkoutPlan_4()) as _i6.WorkoutPlan);
|
||||
@override
|
||||
int findIndexById(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#findIndexById, [id]), returnValue: 0) as int);
|
||||
int findIndexById(int? id) => (super
|
||||
.noSuchMethod(Invocation.method(#findIndexById, [id]), returnValue: 0)
|
||||
as int);
|
||||
@override
|
||||
void setCurrentPlan(int? id) =>
|
||||
super.noSuchMethod(Invocation.method(#setCurrentPlan, [id]), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#setCurrentPlan, [id]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void resetCurrentPlan() =>
|
||||
super.noSuchMethod(Invocation.method(#resetCurrentPlan, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#resetCurrentPlan, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetAllPlansFull() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetAllPlansFull, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> fetchAndSetAllPlansFull() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetAllPlansFull, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetAllPlansSparse() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetAllPlansSparse, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> fetchAndSetAllPlansSparse() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetAllPlansSparse, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<_i6.WorkoutPlan> fetchAndSetPlanSparse(int? planId) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetPlanSparse, [planId]),
|
||||
@@ -128,7 +135,8 @@ class MockWorkoutPlansProvider extends _i1.Mock implements _i12.WorkoutPlansProv
|
||||
as _i13.Future<_i6.WorkoutPlan>);
|
||||
@override
|
||||
_i13.Future<_i6.WorkoutPlan> fetchAndSetWorkoutPlanFull(int? workoutId) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetWorkoutPlanFull, [workoutId]),
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetWorkoutPlanFull, [workoutId]),
|
||||
returnValue: Future<_i6.WorkoutPlan>.value(_FakeWorkoutPlan_4()))
|
||||
as _i13.Future<_i6.WorkoutPlan>);
|
||||
@override
|
||||
@@ -139,78 +147,89 @@ class MockWorkoutPlansProvider extends _i1.Mock implements _i12.WorkoutPlansProv
|
||||
@override
|
||||
_i13.Future<void> editWorkout(_i6.WorkoutPlan? workout) =>
|
||||
(super.noSuchMethod(Invocation.method(#editWorkout, [workout]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value())
|
||||
as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> deleteWorkout(int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteWorkout, [id]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> deleteWorkout(int? id) => (super.noSuchMethod(
|
||||
Invocation.method(#deleteWorkout, [id]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<Map<String, dynamic>> fetchLogData(
|
||||
_i6.WorkoutPlan? workout, _i14.Exercise? exercise) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchLogData, [workout, exercise]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i13.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetRepetitionUnits() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetRepetitionUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetWeightUnits() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetWeightUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetUnits() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<_i7.Day> addDay(_i7.Day? day, _i6.WorkoutPlan? workout) =>
|
||||
(super.noSuchMethod(Invocation.method(#addDay, [day, workout]),
|
||||
returnValue: Future<_i7.Day>.value(_FakeDay_5())) as _i13.Future<_i7.Day>);
|
||||
@override
|
||||
_i13.Future<void> editDay(_i7.Day? day) => (super.noSuchMethod(Invocation.method(#editDay, [day]),
|
||||
_i13.Future<void> fetchAndSetRepetitionUnits() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetRepetitionUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> deleteDay(_i7.Day? day) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteDay, [day]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> fetchAndSetWeightUnits() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetWeightUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> fetchAndSetUnits() => (super.noSuchMethod(
|
||||
Invocation.method(#fetchAndSetUnits, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<_i7.Day> addDay(_i7.Day? day, _i6.WorkoutPlan? workout) =>
|
||||
(super.noSuchMethod(Invocation.method(#addDay, [day, workout]),
|
||||
returnValue: Future<_i7.Day>.value(_FakeDay_5()))
|
||||
as _i13.Future<_i7.Day>);
|
||||
@override
|
||||
_i13.Future<void> editDay(_i7.Day? day) => (super.noSuchMethod(
|
||||
Invocation.method(#editDay, [day]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<void> deleteDay(_i7.Day? day) => (super.noSuchMethod(
|
||||
Invocation.method(#deleteDay, [day]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<_i8.Set> addSet(_i8.Set? workoutSet) =>
|
||||
(super.noSuchMethod(Invocation.method(#addSet, [workoutSet]),
|
||||
returnValue: Future<_i8.Set>.value(_FakeSet_6())) as _i13.Future<_i8.Set>);
|
||||
returnValue: Future<_i8.Set>.value(_FakeSet_6()))
|
||||
as _i13.Future<_i8.Set>);
|
||||
@override
|
||||
_i13.Future<void> editSet(_i8.Set? workoutSet) =>
|
||||
(super.noSuchMethod(Invocation.method(#editSet, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> editSet(_i8.Set? workoutSet) => (super.noSuchMethod(
|
||||
Invocation.method(#editSet, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<List<_i8.Set>> reorderSets(List<_i8.Set>? sets, int? startIndex) =>
|
||||
_i13.Future<List<_i8.Set>> reorderSets(
|
||||
List<_i8.Set>? sets, int? startIndex) =>
|
||||
(super.noSuchMethod(Invocation.method(#reorderSets, [sets, startIndex]),
|
||||
returnValue: Future<List<_i8.Set>>.value(<_i8.Set>[])) as _i13.Future<List<_i8.Set>>);
|
||||
returnValue: Future<List<_i8.Set>>.value(<_i8.Set>[]))
|
||||
as _i13.Future<List<_i8.Set>>);
|
||||
@override
|
||||
_i13.Future<void> fetchComputedSettings(_i8.Set? workoutSet) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchComputedSettings, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> fetchComputedSettings(_i8.Set? workoutSet) => (super
|
||||
.noSuchMethod(Invocation.method(#fetchComputedSettings, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value())
|
||||
as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<String> fetchSmartText(_i8.Set? workoutSet, _i14.Exercise? exercise) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchSmartText, [workoutSet, exercise]),
|
||||
_i13.Future<String> fetchSmartText(
|
||||
_i8.Set? workoutSet, _i14.Exercise? exercise) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#fetchSmartText, [workoutSet, exercise]),
|
||||
returnValue: Future<String>.value('')) as _i13.Future<String>);
|
||||
@override
|
||||
_i13.Future<void> deleteSet(_i8.Set? workoutSet) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteSet, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> deleteSet(_i8.Set? workoutSet) => (super.noSuchMethod(
|
||||
Invocation.method(#deleteSet, [workoutSet]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
_i13.Future<_i9.Setting> addSetting(_i9.Setting? workoutSetting) =>
|
||||
(super.noSuchMethod(Invocation.method(#addSetting, [workoutSetting]),
|
||||
returnValue: Future<_i9.Setting>.value(_FakeSetting_7())) as _i13.Future<_i9.Setting>);
|
||||
returnValue: Future<_i9.Setting>.value(_FakeSetting_7()))
|
||||
as _i13.Future<_i9.Setting>);
|
||||
@override
|
||||
_i13.Future<dynamic> fetchSessionData() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchSessionData, []),
|
||||
@@ -218,55 +237,65 @@ class MockWorkoutPlansProvider extends _i1.Mock implements _i12.WorkoutPlansProv
|
||||
@override
|
||||
_i13.Future<_i10.WorkoutSession> addSession(_i10.WorkoutSession? session) =>
|
||||
(super.noSuchMethod(Invocation.method(#addSession, [session]),
|
||||
returnValue: Future<_i10.WorkoutSession>.value(_FakeWorkoutSession_8()))
|
||||
returnValue:
|
||||
Future<_i10.WorkoutSession>.value(_FakeWorkoutSession_8()))
|
||||
as _i13.Future<_i10.WorkoutSession>);
|
||||
@override
|
||||
_i13.Future<_i11.Log> addLog(_i11.Log? log) =>
|
||||
(super.noSuchMethod(Invocation.method(#addLog, [log]),
|
||||
returnValue: Future<_i11.Log>.value(_FakeLog_9())) as _i13.Future<_i11.Log>);
|
||||
returnValue: Future<_i11.Log>.value(_FakeLog_9()))
|
||||
as _i13.Future<_i11.Log>);
|
||||
@override
|
||||
_i13.Future<void> deleteLog(_i11.Log? log) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteLog, [log]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
_i13.Future<void> deleteLog(_i11.Log? log) => (super.noSuchMethod(
|
||||
Invocation.method(#deleteLog, [log]),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i13.Future<void>);
|
||||
@override
|
||||
Uri makeUrl(String? path, {int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
Uri makeUrl(String? path,
|
||||
{int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#makeUrl, [path], {#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
Invocation.method(#makeUrl, [path],
|
||||
{#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
returnValue: _FakeUri_10()) as Uri);
|
||||
@override
|
||||
_i13.Future<Map<String, dynamic>> fetch(Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i13.Future<Map<String, dynamic>>);
|
||||
_i13.Future<Map<String, dynamic>> fetch(Uri? uri) => (super.noSuchMethod(
|
||||
Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i13.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i13.Future<Map<String, dynamic>> post(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i13.Future<Map<String, dynamic>> post(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#post, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i13.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i13.Future<Map<String, dynamic>> patch(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i13.Future<Map<String, dynamic>> patch(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#patch, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i13.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i13.Future<_i5.Response> deleteRequest(String? url, int? id) => (super.noSuchMethod(
|
||||
Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i5.Response>.value(_FakeResponse_11())) as _i13.Future<_i5.Response>);
|
||||
_i13.Future<_i5.Response> deleteRequest(String? url, int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i5.Response>.value(_FakeResponse_11()))
|
||||
as _i13.Future<_i5.Response>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
@override
|
||||
void addListener(_i15.VoidCallback? listener) => super
|
||||
.noSuchMethod(Invocation.method(#addListener, [listener]), returnValueForMissingStub: null);
|
||||
void addListener(_i15.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#addListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void removeListener(_i15.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#removeListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void dispose() =>
|
||||
super.noSuchMethod(Invocation.method(#dispose, []), returnValueForMissingStub: null);
|
||||
void dispose() => super.noSuchMethod(Invocation.method(#dispose, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void notifyListeners() =>
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []),
|
||||
returnValueForMissingStub: null);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Mocks generated by Mockito 5.0.15 from annotations
|
||||
// in wger/test/workout_set_form_test.dart.
|
||||
// Mocks generated by Mockito 5.0.16 from annotations
|
||||
// in wger/test/workout/workout_set_form_test.dart.
|
||||
// Do not manually edit this file.
|
||||
|
||||
import 'dart:async' as _i6;
|
||||
@@ -18,6 +18,7 @@ import 'package:wger/providers/exercises.dart' as _i5;
|
||||
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
||||
// ignore_for_file: prefer_const_constructors
|
||||
// ignore_for_file: unnecessary_parenthesis
|
||||
// ignore_for_file: camel_case_types
|
||||
|
||||
class _FakeAuthProvider_0 extends _i1.Fake implements _i2.AuthProvider {}
|
||||
|
||||
@@ -38,29 +39,30 @@ class MockExercisesProvider extends _i1.Mock implements _i5.ExercisesProvider {
|
||||
}
|
||||
|
||||
@override
|
||||
List<_i4.Exercise> get items =>
|
||||
(super.noSuchMethod(Invocation.getter(#items), returnValue: <_i4.Exercise>[])
|
||||
as List<_i4.Exercise>);
|
||||
List<_i4.Exercise> get items => (super.noSuchMethod(Invocation.getter(#items),
|
||||
returnValue: <_i4.Exercise>[]) as List<_i4.Exercise>);
|
||||
@override
|
||||
_i2.AuthProvider get auth =>
|
||||
(super.noSuchMethod(Invocation.getter(#auth), returnValue: _FakeAuthProvider_0())
|
||||
as _i2.AuthProvider);
|
||||
_i2.AuthProvider get auth => (super.noSuchMethod(Invocation.getter(#auth),
|
||||
returnValue: _FakeAuthProvider_0()) as _i2.AuthProvider);
|
||||
@override
|
||||
set auth(_i2.AuthProvider? _auth) =>
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#auth, _auth),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
_i3.Client get client =>
|
||||
(super.noSuchMethod(Invocation.getter(#client), returnValue: _FakeClient_1()) as _i3.Client);
|
||||
_i3.Client get client => (super.noSuchMethod(Invocation.getter(#client),
|
||||
returnValue: _FakeClient_1()) as _i3.Client);
|
||||
@override
|
||||
set client(_i3.Client? _client) =>
|
||||
super.noSuchMethod(Invocation.setter(#client, _client), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.setter(#client, _client),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
bool get hasListeners =>
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) as bool);
|
||||
(super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false)
|
||||
as bool);
|
||||
@override
|
||||
_i4.Exercise findById(int? exerciseId) => (super
|
||||
.noSuchMethod(Invocation.method(#findById, [exerciseId]), returnValue: _FakeExercise_2())
|
||||
as _i4.Exercise);
|
||||
_i4.Exercise findById(int? exerciseId) =>
|
||||
(super.noSuchMethod(Invocation.method(#findById, [exerciseId]),
|
||||
returnValue: _FakeExercise_2()) as _i4.Exercise);
|
||||
@override
|
||||
_i6.Future<void> fetchAndSetCategories() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetCategories, []),
|
||||
@@ -79,54 +81,65 @@ class MockExercisesProvider extends _i1.Mock implements _i5.ExercisesProvider {
|
||||
@override
|
||||
_i6.Future<_i4.Exercise> fetchAndSetExercise(int? exerciseId) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetExercise, [exerciseId]),
|
||||
returnValue: Future<_i4.Exercise>.value(_FakeExercise_2())) as _i6.Future<_i4.Exercise>);
|
||||
returnValue: Future<_i4.Exercise>.value(_FakeExercise_2()))
|
||||
as _i6.Future<_i4.Exercise>);
|
||||
@override
|
||||
_i6.Future<void> fetchAndSetExercises() =>
|
||||
(super.noSuchMethod(Invocation.method(#fetchAndSetExercises, []),
|
||||
returnValue: Future<void>.value(),
|
||||
returnValueForMissingStub: Future<void>.value()) as _i6.Future<void>);
|
||||
@override
|
||||
_i6.Future<List<dynamic>> searchExercise(String? name, [String? languageCode = r'en']) =>
|
||||
(super.noSuchMethod(Invocation.method(#searchExercise, [name, languageCode]),
|
||||
returnValue: Future<List<dynamic>>.value(<dynamic>[])) as _i6.Future<List<dynamic>>);
|
||||
@override
|
||||
Uri makeUrl(String? path, {int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
_i6.Future<List<dynamic>> searchExercise(String? name,
|
||||
[String? languageCode = r'en']) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#makeUrl, [path], {#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
Invocation.method(#searchExercise, [name, languageCode]),
|
||||
returnValue: Future<List<dynamic>>.value(<dynamic>[]))
|
||||
as _i6.Future<List<dynamic>>);
|
||||
@override
|
||||
Uri makeUrl(String? path,
|
||||
{int? id, String? objectMethod, Map<String, dynamic>? query}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(#makeUrl, [path],
|
||||
{#id: id, #objectMethod: objectMethod, #query: query}),
|
||||
returnValue: _FakeUri_3()) as Uri);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> fetch(Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
_i6.Future<Map<String, dynamic>> fetch(Uri? uri) => (super.noSuchMethod(
|
||||
Invocation.method(#fetch, [uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> post(Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#post, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> patch(Map<String, dynamic>? data, Uri? uri) =>
|
||||
_i6.Future<Map<String, dynamic>> patch(
|
||||
Map<String, dynamic>? data, Uri? uri) =>
|
||||
(super.noSuchMethod(Invocation.method(#patch, [data, uri]),
|
||||
returnValue: Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
returnValue:
|
||||
Future<Map<String, dynamic>>.value(<String, dynamic>{}))
|
||||
as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<_i3.Response> deleteRequest(String? url, int? id) =>
|
||||
(super.noSuchMethod(Invocation.method(#deleteRequest, [url, id]),
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_4())) as _i6.Future<_i3.Response>);
|
||||
returnValue: Future<_i3.Response>.value(_FakeResponse_4()))
|
||||
as _i6.Future<_i3.Response>);
|
||||
@override
|
||||
String toString() => super.toString();
|
||||
@override
|
||||
void addListener(_i7.VoidCallback? listener) => super
|
||||
.noSuchMethod(Invocation.method(#addListener, [listener]), returnValueForMissingStub: null);
|
||||
void addListener(_i7.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#addListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void removeListener(_i7.VoidCallback? listener) =>
|
||||
super.noSuchMethod(Invocation.method(#removeListener, [listener]),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void dispose() =>
|
||||
super.noSuchMethod(Invocation.method(#dispose, []), returnValueForMissingStub: null);
|
||||
void dispose() => super.noSuchMethod(Invocation.method(#dispose, []),
|
||||
returnValueForMissingStub: null);
|
||||
@override
|
||||
void notifyListeners() =>
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []), returnValueForMissingStub: null);
|
||||
super.noSuchMethod(Invocation.method(#notifyListeners, []),
|
||||
returnValueForMissingStub: null);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user