45 lines
1.6 KiB
Dart
45 lines
1.6 KiB
Dart
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:words999/models/divination_layout.dart';
|
|
import 'package:words999/models/divination_instructions.dart';
|
|
import 'package:words999/services/ogham_feda_repository.dart';
|
|
|
|
void main() {
|
|
TestWidgetsFlutterBinding.ensureInitialized();
|
|
|
|
group('Celtic Ogham Divination System Tests', () {
|
|
test('Ogham layouts exist with correct counts', () {
|
|
expect(DivinationLayouts.oghamLayouts.length, 3);
|
|
expect(DivinationLayouts.oghamLayouts[0].count, 1);
|
|
expect(DivinationLayouts.oghamLayouts[1].count, 3);
|
|
expect(DivinationLayouts.oghamLayouts[2].count, 5);
|
|
});
|
|
|
|
test('Ogham instruction is fully defined with history and rules', () {
|
|
final instr = DivinationInstructionsRepository.get('ogham');
|
|
expect(instr.id, 'ogham');
|
|
expect(instr.title, contains('Огам'));
|
|
expect(instr.icon, '᚛');
|
|
expect(instr.historyAndEssence.isNotEmpty, true);
|
|
expect(instr.physicalDiceMethod.isNotEmpty, true);
|
|
expect(instr.sacredRules.length, greaterThanOrEqualTo(3));
|
|
});
|
|
|
|
test('OghamFedaRepository loads all 20 sacred fedas', () async {
|
|
final repo = OghamFedaRepository();
|
|
await repo.init();
|
|
expect(repo.allFedas.length, 20);
|
|
|
|
final beith = repo.byCanonId('beith');
|
|
expect(beith, isNotNull);
|
|
expect(beith!.symbol, 'ᚁ');
|
|
expect(beith.name, contains('Бэйт'));
|
|
expect(beith.shadow.isNotEmpty, true);
|
|
|
|
final idho = repo.byCanonId('idho');
|
|
expect(idho, isNotNull);
|
|
expect(idho!.symbol, 'ᚔ');
|
|
expect(idho.name, contains('Идо'));
|
|
});
|
|
});
|
|
}
|