forked from eatvio/eatvio_app
30 lines
1.1 KiB
Dart
30 lines
1.1 KiB
Dart
import 'package:eatvio_app/core/app_router.dart';
|
||
import 'package:flutter/material.dart';
|
||
import 'package:flutter_test/flutter_test.dart';
|
||
import 'package:go_router/go_router.dart';
|
||
|
||
void main() {
|
||
group('AppRouter', () {
|
||
test('navigatorKey инициализирован', () {
|
||
expect(AppRouter.navigatorKey, isNotNull);
|
||
expect(AppRouter.navigatorKey, isA<GlobalKey<NavigatorState>>());
|
||
});
|
||
|
||
test('appRouter инициализирован', () {
|
||
expect(AppRouter.appRouter, isNotNull);
|
||
expect(AppRouter.appRouter, isA<GoRouter>());
|
||
});
|
||
|
||
test('appRouter инициализирован с правильной конфигурацией', () {
|
||
expect(AppRouter.appRouter.configuration, isNotNull);
|
||
});
|
||
|
||
test('navigateToRegisterViaSocial вызывается без ошибок', () {
|
||
// Этот тест проверяет, что метод существует и может быть вызван
|
||
// Реальная навигация требует инициализированного контекста
|
||
expect(AppRouter.navigateToRegisterViaSocial, isA<Function>());
|
||
});
|
||
});
|
||
}
|
||
|