Exemple #1
0
            public void Should_Throw_Exception_If_Folder_Is_Null()
            {
                // Given
                var service = new AutoAddServiceFixture().CreateAutoAddService();

                // When
                var exception = Record.Exception(() => service.CreateFolder(null));

                // Then
                Assert.IsType <ArgumentNullException>(exception);
                Assert.Equal("folder", ((ArgumentNullException)exception).ParamName);
            }
Exemple #2
0
            public void Should_Return_The_Folder_Passed_As_Argument()
            {
                // Given
                var service = new AutoAddServiceFixture().CreateAutoAddService();

                // When
                var folder = service.CreateFolder(new Folder {
                    Path = "<some path>"
                });

                // Then
                Assert.Equal("<some path>", folder.Path);
            }