public void TestChangeOnFile_InvokesProcessor(int index, string filePath) { const string input = @"{ ""file"": [ ""test1.html"", ""test2.html"" ], ""template"": [""templates/**.html""] } "; var fileSystem = new InMemoryFileSystem(new[] { "test1.html", "test2.html", "templates/tmpl1.html", "templates/tmpl2.html" }); var result = Project.FromFile(input, fileSystem); var item = result.GetItems().ToList()[index]; var processor = new Mock<IProjectObserver>(MockBehavior.Strict); processor.Setup(f => f.NotifyItemChanged(result, item)); result.AddObserver(processor.Object); fileSystem.Touch(filePath); processor.VerifyAll(); }