コード例 #1
0
        public void CheckSeededParty()
        {
            List <Party> parties     = partyRepository.GetPartiesUser("SampleUser");
            Party        sampleParty = parties.First();

            Assert.True(sampleParty.Name == "Party");
            Assert.True(sampleParty.Characters.First().Name == "testChar1");
            Assert.True(sampleParty.Characters.Last().Name == "testChar5");
        }
コード例 #2
0
        public IActionResult PartyOverview()
        {
            PartyOverviewViewModel vm;
            List <Party>           parties = repository.GetPartiesUser(getCurrentUserUsername());
            int selectedPartyIndex         = userManager.GetUserAsync(User).Result.SelectedPartyIndex;

            repository.Complete();
            vm = new PartyOverviewViewModel(selectedPartyIndex, parties);
            return(View(vm));
        }