|
| 1 | +using UltraWorldAI; |
| 2 | +using UltraWorldAI.Politics; |
| 3 | +using UltraWorldAI.Religion; |
| 4 | +using Xunit; |
| 5 | + |
| 6 | +public class ReligiousConflictSystemTests |
| 7 | +{ |
| 8 | + [Fact] |
| 9 | + public void ProclaimProphecyAddsProphecyAndLogsEvent() |
| 10 | + { |
| 11 | + ReligionSystem.Religions.Clear(); |
| 12 | + HistorySystem.Events.Clear(); |
| 13 | + var religion = ReligionSystem.FoundReligion("Solaris", "Luz eterna", "Sul"); |
| 14 | + var before = ProphecySystem.AllProphecies.Count; |
| 15 | + |
| 16 | + ReligiousConflictSystem.ProclaimProphecy(religion.Name, "Ascensao", "eclipse", "nova era"); |
| 17 | + |
| 18 | + Assert.Equal(before + 1, ProphecySystem.AllProphecies.Count); |
| 19 | + Assert.Contains(HistorySystem.Events, e => e.EventName.Contains("proclamou a profecia")); |
| 20 | + } |
| 21 | + |
| 22 | + [Fact] |
| 23 | + public void TriggerSchismCreatesCultAndLogs() |
| 24 | + { |
| 25 | + CultSplit.AllCults.Clear(); |
| 26 | + DoctrineEngine.Doctrines.Clear(); |
| 27 | + HistorySystem.Events.Clear(); |
| 28 | + var god = GodFactory.CreateGod("Zaros", DivineDomain.Luz, DivineTemperament.Benevolente); |
| 29 | + var doctrine = DoctrineEngine.CreateDoctrine(god); |
| 30 | + |
| 31 | + ReligiousConflictSystem.TriggerSchism(doctrine.Title, "Cyrus", "discordancia"); |
| 32 | + |
| 33 | + Assert.Single(CultSplit.AllCults); |
| 34 | + Assert.Contains(HistorySystem.Events, e => e.EventName.Contains("fundou o culto")); |
| 35 | + } |
| 36 | + |
| 37 | + [Fact] |
| 38 | + public void StartHolyWarCreatesWarAndLogs() |
| 39 | + { |
| 40 | + ReligionSystem.Religions.Clear(); |
| 41 | + HouseWarSystem.Wars.Clear(); |
| 42 | + HistorySystem.Events.Clear(); |
| 43 | + var religion = ReligionSystem.FoundReligion("Lunaris", "Sombra", "Norte"); |
| 44 | + |
| 45 | + ReligiousConflictSystem.StartHolyWar(religion.Name, "Norte"); |
| 46 | + |
| 47 | + Assert.Single(HouseWarSystem.Wars); |
| 48 | + Assert.Contains(HistorySystem.Events, e => e.EventName.Contains("Guerra santa")); |
| 49 | + } |
| 50 | +} |
0 commit comments