Esempio n. 1
0
        private PassportModel GetResultFromTextLines(string text)
        {
            var mrz = PassportParser.ParsePassport(text);

            if (mrz != null && mrz.Valid)
            {
                return(mrz);
            }

            return(null);
        }
        public void ValidValueValidationTest(bool expectedResult, string input)
        {
            // Arrange
            var passportParser = new PassportParser();

            // Act
            var validity = new ValidValueValidation().IsValid(passportParser.ParsePassport(input));

            // Assert
            Assert.That(validity, Is.EqualTo(expectedResult));
        }