Update dependencies and enhance tender approval status handling
- Updated `pubspec.lock` to reflect new versions for several packages, including `async`, `fake_async`, `leak_tracker`, and `vm_service`. - Modified `TenderApprovalStatus` enum to include a new status `approved`. - Updated routing for `YourTendersRouteData` to accept a status parameter and pass it to the `YourTendersScreen`. - Adjusted API calls and view models to utilize the new status handling, ensuring proper filtering and display of tender data based on approval status. - Enhanced filter dialog to support new status options and improved user feedback in the UI for submitted and approved tenders.
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
////////////////////////////
|
||||
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:tm_app/data/services/model/error/error_model.dart';
|
||||
|
||||
@@ -41,9 +39,7 @@ void main() {
|
||||
details: 'Server error',
|
||||
);
|
||||
|
||||
final updated = error.copyWith(
|
||||
message: 'Timeout error',
|
||||
);
|
||||
final updated = error.copyWith(message: 'Timeout error');
|
||||
|
||||
expect(updated.message, 'Timeout error');
|
||||
expect(updated.code, '500');
|
||||
@@ -51,11 +47,7 @@ void main() {
|
||||
});
|
||||
|
||||
test('fromJson handles null fields safely', () {
|
||||
final json = {
|
||||
'message': null,
|
||||
'code': null,
|
||||
'details': null,
|
||||
};
|
||||
final json = {'message': null, 'code': null, 'details': null};
|
||||
|
||||
final error = ErrorModel.fromJson(json);
|
||||
|
||||
@@ -81,4 +73,4 @@ void main() {
|
||||
});
|
||||
}
|
||||
|
||||
////////////////////////////
|
||||
////////////////////////////
|
||||
|
||||
Reference in New Issue
Block a user