Exemple #1
0
        public void Throw_ArgumentException_WhenIsCalled_WithInCorrectName(string name, string email)
        {
            // Arrange
            var modelsFactory = new Podcaster.Models.Factories.ModelsFactory();

            // Act
            // Assert
            Assert.Throws <ArgumentException>(() => modelsFactory.CreateUser(name, email));
        }
Exemple #2
0
        public void Create_AnInstanceOf_IUser_WhenIsCalled_WithCorrectName()
        {
            // Arrange
            var name  = this.Fixture.Create <string>();
            var email = this.Fixture.Create <string>();

            var modelsFactory = new Podcaster.Models.Factories.ModelsFactory();

            // Act
            var user = modelsFactory.CreateUser(name, email);

            // Assert
            Assert.IsInstanceOf <IApplicationUser>(user);
        }