public void TestMatchShouldNotMatchOnBadString()
 {
     //given
     const string filePath = "asdasdasda.xml.asdasdasd";
     var mapper = Mock.Of<IXmlStockFileMapper>();
     var fileHelper = Mock.Of<IXmlStockFileReaderHelper>();
     var reader = new XmlStockFileReader(mapper, fileHelper);
     //when
     var result = reader.Match(filePath);
     //then
     Assert.That(result, Is.False);
 }
 public void TestMatch()
 {
     //given
     const string filePath = "c:\\d\\d\\test.xml";
     var mapper = Mock.Of<IXmlStockFileMapper>();
     var fileHelper = Mock.Of<IXmlStockFileReaderHelper>();
     var reader = new XmlStockFileReader(mapper, fileHelper);
     //when
     var result = reader.Match(filePath);
     //then
     Assert.That(result, Is.True);
 }
Exemple #3
0
        public void TestMatchShouldNotMatchOnBadString()
        {
            //given
            const string filePath   = "asdasdasda.xml.asdasdasd";
            var          mapper     = Mock.Of <IXmlStockFileMapper>();
            var          fileHelper = Mock.Of <IXmlStockFileReaderHelper>();
            var          reader     = new XmlStockFileReader(mapper, fileHelper);
            //when
            var result = reader.Match(filePath);

            //then
            Assert.That(result, Is.False);
        }
Exemple #4
0
        public void TestMatch()
        {
            //given
            const string filePath   = "c:\\d\\d\\test.xml";
            var          mapper     = Mock.Of <IXmlStockFileMapper>();
            var          fileHelper = Mock.Of <IXmlStockFileReaderHelper>();
            var          reader     = new XmlStockFileReader(mapper, fileHelper);
            //when
            var result = reader.Match(filePath);

            //then
            Assert.That(result, Is.True);
        }