주요 변경사항: - 창고 관리 API 응답 구조와 DTO 불일치 수정 - WarehouseLocationDto에 code, manager_phone 필드 추가 - RemoteDataSource에서 API 응답을 DTO 구조에 맞게 변환 - 회사 관리 API 응답 파싱 오류 수정 - CompanyResponse의 필수 필드를 nullable로 변경 - PaginatedResponse 구조 매핑 로직 개선 - 에러 처리 및 로깅 개선 - Service Layer에 상세 에러 로깅 추가 - Controller에서 에러 타입별 처리 - 새로운 유틸리티 추가 - ResponseInterceptor: API 응답 정규화 - DebugLogger: 디버깅 도구 - HealthCheckService: 서버 상태 확인 - 문서화 - API 통합 테스트 가이드 - 에러 분석 보고서 - 리팩토링 계획서
695 lines
18 KiB
Dart
695 lines
18 KiB
Dart
// Mocks generated by Mockito 5.4.5 from annotations
|
|
// in superport/test/integration/auth_integration_test_fixed.dart.
|
|
// Do not manually edit this file.
|
|
|
|
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
|
import 'dart:async' as _i5;
|
|
|
|
import 'package:dio/dio.dart' as _i2;
|
|
import 'package:flutter/foundation.dart' as _i6;
|
|
import 'package:flutter_secure_storage/flutter_secure_storage.dart' as _i3;
|
|
import 'package:mockito/mockito.dart' as _i1;
|
|
import 'package:superport/data/datasources/remote/api_client.dart' as _i4;
|
|
|
|
// ignore_for_file: type=lint
|
|
// ignore_for_file: avoid_redundant_argument_values
|
|
// ignore_for_file: avoid_setters_without_getters
|
|
// ignore_for_file: comment_references
|
|
// ignore_for_file: deprecated_member_use
|
|
// ignore_for_file: deprecated_member_use_from_same_package
|
|
// ignore_for_file: implementation_imports
|
|
// ignore_for_file: invalid_use_of_visible_for_testing_member
|
|
// ignore_for_file: must_be_immutable
|
|
// ignore_for_file: prefer_const_constructors
|
|
// ignore_for_file: unnecessary_parenthesis
|
|
// ignore_for_file: camel_case_types
|
|
// ignore_for_file: subtype_of_sealed_class
|
|
|
|
class _FakeDio_0 extends _i1.SmartFake implements _i2.Dio {
|
|
_FakeDio_0(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeResponse_1<T1> extends _i1.SmartFake implements _i2.Response<T1> {
|
|
_FakeResponse_1(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeIOSOptions_2 extends _i1.SmartFake implements _i3.IOSOptions {
|
|
_FakeIOSOptions_2(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeAndroidOptions_3 extends _i1.SmartFake
|
|
implements _i3.AndroidOptions {
|
|
_FakeAndroidOptions_3(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeLinuxOptions_4 extends _i1.SmartFake implements _i3.LinuxOptions {
|
|
_FakeLinuxOptions_4(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeWindowsOptions_5 extends _i1.SmartFake
|
|
implements _i3.WindowsOptions {
|
|
_FakeWindowsOptions_5(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeWebOptions_6 extends _i1.SmartFake implements _i3.WebOptions {
|
|
_FakeWebOptions_6(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
class _FakeMacOsOptions_7 extends _i1.SmartFake implements _i3.MacOsOptions {
|
|
_FakeMacOsOptions_7(
|
|
Object parent,
|
|
Invocation parentInvocation,
|
|
) : super(
|
|
parent,
|
|
parentInvocation,
|
|
);
|
|
}
|
|
|
|
/// A class which mocks [ApiClient].
|
|
///
|
|
/// See the documentation for Mockito's code generation for more information.
|
|
class MockApiClient extends _i1.Mock implements _i4.ApiClient {
|
|
MockApiClient() {
|
|
_i1.throwOnMissingStub(this);
|
|
}
|
|
|
|
@override
|
|
_i2.Dio get dio => (super.noSuchMethod(
|
|
Invocation.getter(#dio),
|
|
returnValue: _FakeDio_0(
|
|
this,
|
|
Invocation.getter(#dio),
|
|
),
|
|
) as _i2.Dio);
|
|
|
|
@override
|
|
void updateAuthToken(String? token) => super.noSuchMethod(
|
|
Invocation.method(
|
|
#updateAuthToken,
|
|
[token],
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
void removeAuthToken() => super.noSuchMethod(
|
|
Invocation.method(
|
|
#removeAuthToken,
|
|
[],
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> get<T>(
|
|
String? path, {
|
|
Map<String, dynamic>? queryParameters,
|
|
_i2.Options? options,
|
|
_i2.CancelToken? cancelToken,
|
|
_i2.ProgressCallback? onReceiveProgress,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#get,
|
|
[path],
|
|
{
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#get,
|
|
[path],
|
|
{
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> post<T>(
|
|
String? path, {
|
|
dynamic data,
|
|
Map<String, dynamic>? queryParameters,
|
|
_i2.Options? options,
|
|
_i2.CancelToken? cancelToken,
|
|
_i2.ProgressCallback? onSendProgress,
|
|
_i2.ProgressCallback? onReceiveProgress,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#post,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#post,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> put<T>(
|
|
String? path, {
|
|
dynamic data,
|
|
Map<String, dynamic>? queryParameters,
|
|
_i2.Options? options,
|
|
_i2.CancelToken? cancelToken,
|
|
_i2.ProgressCallback? onSendProgress,
|
|
_i2.ProgressCallback? onReceiveProgress,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#put,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#put,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> patch<T>(
|
|
String? path, {
|
|
dynamic data,
|
|
Map<String, dynamic>? queryParameters,
|
|
_i2.Options? options,
|
|
_i2.CancelToken? cancelToken,
|
|
_i2.ProgressCallback? onSendProgress,
|
|
_i2.ProgressCallback? onReceiveProgress,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#patch,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#patch,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
#onSendProgress: onSendProgress,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> delete<T>(
|
|
String? path, {
|
|
dynamic data,
|
|
Map<String, dynamic>? queryParameters,
|
|
_i2.Options? options,
|
|
_i2.CancelToken? cancelToken,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#delete,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#delete,
|
|
[path],
|
|
{
|
|
#data: data,
|
|
#queryParameters: queryParameters,
|
|
#options: options,
|
|
#cancelToken: cancelToken,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<T>> uploadFile<T>(
|
|
String? path, {
|
|
required String? filePath,
|
|
required String? fileFieldName,
|
|
Map<String, dynamic>? additionalData,
|
|
_i2.ProgressCallback? onSendProgress,
|
|
_i2.CancelToken? cancelToken,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#uploadFile,
|
|
[path],
|
|
{
|
|
#filePath: filePath,
|
|
#fileFieldName: fileFieldName,
|
|
#additionalData: additionalData,
|
|
#onSendProgress: onSendProgress,
|
|
#cancelToken: cancelToken,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<_i2.Response<T>>.value(_FakeResponse_1<T>(
|
|
this,
|
|
Invocation.method(
|
|
#uploadFile,
|
|
[path],
|
|
{
|
|
#filePath: filePath,
|
|
#fileFieldName: fileFieldName,
|
|
#additionalData: additionalData,
|
|
#onSendProgress: onSendProgress,
|
|
#cancelToken: cancelToken,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<T>>);
|
|
|
|
@override
|
|
_i5.Future<_i2.Response<dynamic>> downloadFile(
|
|
String? path, {
|
|
required String? savePath,
|
|
_i2.ProgressCallback? onReceiveProgress,
|
|
_i2.CancelToken? cancelToken,
|
|
Map<String, dynamic>? queryParameters,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#downloadFile,
|
|
[path],
|
|
{
|
|
#savePath: savePath,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
#cancelToken: cancelToken,
|
|
#queryParameters: queryParameters,
|
|
},
|
|
),
|
|
returnValue:
|
|
_i5.Future<_i2.Response<dynamic>>.value(_FakeResponse_1<dynamic>(
|
|
this,
|
|
Invocation.method(
|
|
#downloadFile,
|
|
[path],
|
|
{
|
|
#savePath: savePath,
|
|
#onReceiveProgress: onReceiveProgress,
|
|
#cancelToken: cancelToken,
|
|
#queryParameters: queryParameters,
|
|
},
|
|
),
|
|
)),
|
|
) as _i5.Future<_i2.Response<dynamic>>);
|
|
}
|
|
|
|
/// A class which mocks [FlutterSecureStorage].
|
|
///
|
|
/// See the documentation for Mockito's code generation for more information.
|
|
class MockFlutterSecureStorage extends _i1.Mock
|
|
implements _i3.FlutterSecureStorage {
|
|
MockFlutterSecureStorage() {
|
|
_i1.throwOnMissingStub(this);
|
|
}
|
|
|
|
@override
|
|
_i3.IOSOptions get iOptions => (super.noSuchMethod(
|
|
Invocation.getter(#iOptions),
|
|
returnValue: _FakeIOSOptions_2(
|
|
this,
|
|
Invocation.getter(#iOptions),
|
|
),
|
|
) as _i3.IOSOptions);
|
|
|
|
@override
|
|
_i3.AndroidOptions get aOptions => (super.noSuchMethod(
|
|
Invocation.getter(#aOptions),
|
|
returnValue: _FakeAndroidOptions_3(
|
|
this,
|
|
Invocation.getter(#aOptions),
|
|
),
|
|
) as _i3.AndroidOptions);
|
|
|
|
@override
|
|
_i3.LinuxOptions get lOptions => (super.noSuchMethod(
|
|
Invocation.getter(#lOptions),
|
|
returnValue: _FakeLinuxOptions_4(
|
|
this,
|
|
Invocation.getter(#lOptions),
|
|
),
|
|
) as _i3.LinuxOptions);
|
|
|
|
@override
|
|
_i3.WindowsOptions get wOptions => (super.noSuchMethod(
|
|
Invocation.getter(#wOptions),
|
|
returnValue: _FakeWindowsOptions_5(
|
|
this,
|
|
Invocation.getter(#wOptions),
|
|
),
|
|
) as _i3.WindowsOptions);
|
|
|
|
@override
|
|
_i3.WebOptions get webOptions => (super.noSuchMethod(
|
|
Invocation.getter(#webOptions),
|
|
returnValue: _FakeWebOptions_6(
|
|
this,
|
|
Invocation.getter(#webOptions),
|
|
),
|
|
) as _i3.WebOptions);
|
|
|
|
@override
|
|
_i3.MacOsOptions get mOptions => (super.noSuchMethod(
|
|
Invocation.getter(#mOptions),
|
|
returnValue: _FakeMacOsOptions_7(
|
|
this,
|
|
Invocation.getter(#mOptions),
|
|
),
|
|
) as _i3.MacOsOptions);
|
|
|
|
@override
|
|
void registerListener({
|
|
required String? key,
|
|
required _i6.ValueChanged<String?>? listener,
|
|
}) =>
|
|
super.noSuchMethod(
|
|
Invocation.method(
|
|
#registerListener,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#listener: listener,
|
|
},
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
void unregisterListener({
|
|
required String? key,
|
|
required _i6.ValueChanged<String?>? listener,
|
|
}) =>
|
|
super.noSuchMethod(
|
|
Invocation.method(
|
|
#unregisterListener,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#listener: listener,
|
|
},
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
void unregisterAllListenersForKey({required String? key}) =>
|
|
super.noSuchMethod(
|
|
Invocation.method(
|
|
#unregisterAllListenersForKey,
|
|
[],
|
|
{#key: key},
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
void unregisterAllListeners() => super.noSuchMethod(
|
|
Invocation.method(
|
|
#unregisterAllListeners,
|
|
[],
|
|
),
|
|
returnValueForMissingStub: null,
|
|
);
|
|
|
|
@override
|
|
_i5.Future<void> write({
|
|
required String? key,
|
|
required String? value,
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#write,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#value: value,
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<void>.value(),
|
|
returnValueForMissingStub: _i5.Future<void>.value(),
|
|
) as _i5.Future<void>);
|
|
|
|
@override
|
|
_i5.Future<String?> read({
|
|
required String? key,
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#read,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<String?>.value(),
|
|
) as _i5.Future<String?>);
|
|
|
|
@override
|
|
_i5.Future<bool> containsKey({
|
|
required String? key,
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#containsKey,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<bool>.value(false),
|
|
) as _i5.Future<bool>);
|
|
|
|
@override
|
|
_i5.Future<void> delete({
|
|
required String? key,
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#delete,
|
|
[],
|
|
{
|
|
#key: key,
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<void>.value(),
|
|
returnValueForMissingStub: _i5.Future<void>.value(),
|
|
) as _i5.Future<void>);
|
|
|
|
@override
|
|
_i5.Future<Map<String, String>> readAll({
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#readAll,
|
|
[],
|
|
{
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<Map<String, String>>.value(<String, String>{}),
|
|
) as _i5.Future<Map<String, String>>);
|
|
|
|
@override
|
|
_i5.Future<void> deleteAll({
|
|
_i3.IOSOptions? iOptions,
|
|
_i3.AndroidOptions? aOptions,
|
|
_i3.LinuxOptions? lOptions,
|
|
_i3.WebOptions? webOptions,
|
|
_i3.MacOsOptions? mOptions,
|
|
_i3.WindowsOptions? wOptions,
|
|
}) =>
|
|
(super.noSuchMethod(
|
|
Invocation.method(
|
|
#deleteAll,
|
|
[],
|
|
{
|
|
#iOptions: iOptions,
|
|
#aOptions: aOptions,
|
|
#lOptions: lOptions,
|
|
#webOptions: webOptions,
|
|
#mOptions: mOptions,
|
|
#wOptions: wOptions,
|
|
},
|
|
),
|
|
returnValue: _i5.Future<void>.value(),
|
|
returnValueForMissingStub: _i5.Future<void>.value(),
|
|
) as _i5.Future<void>);
|
|
|
|
@override
|
|
_i5.Future<bool?> isCupertinoProtectedDataAvailable() => (super.noSuchMethod(
|
|
Invocation.method(
|
|
#isCupertinoProtectedDataAvailable,
|
|
[],
|
|
),
|
|
returnValue: _i5.Future<bool?>.value(),
|
|
) as _i5.Future<bool?>);
|
|
}
|