Esempio n. 1
0
        public void Get_EntityDoesntExist_ReturnsNull()
        {
            using(var store = new Store(BuildConfiguration())) {
                OnStoreCreate(store);

                using(var steps = new Steps(store)) {
                    // Arrange
                    steps.BeginConversation();

                    // Act
                    steps.IssueGetPerson(Guid.NewGuid());

                    // Assert
                    steps.VerifyRetrievedPersonIsNull();
                }
            }
        }
Esempio n. 2
0
        public void Get_EntityExists_ReturnsCorrespondingEntity()
        {
            using(var store = new Store(BuildConfiguration())) {
                OnStoreCreate(store);

                using(var steps = new Steps(store)) {
                    var person = CreatePerson(1);

                    // Arrange
                    steps.BeginConversation();
                    steps.SavePerson(person);

                    // Act
                    steps.IssueGetPerson(person.Id);

                    // Assert
                    steps.VerifyRetrievedPerson(person);
                }
            }
        }