public void GetValue_ReturnsItemFullPath() { //Assign var param = new ItemIdNoBracketsParameter(); var item = Database.GetItem("/sitecore/content/Tests/DataMappers/SitecoreQueryParameters/ItemIdNoBracketsParameter"); //Act var result = param.GetValue(item); //Assert Assert.AreEqual("3E61E999FED643E09D128B19D60D8A13".ToLower(), result); }
public void GetValue_ReturnsItemFullPath() { using (Db database = new Db { new Sitecore.FakeDb.DbItem("Target") }) { //Assign var param = new ItemIdNoBracketsParameter(); var item = database.GetItem( "/sitecore/content/Target"); //Act var result = param.GetValue(item); //Assert Assert.AreEqual(item.ID.Guid.ToString("N").ToLower(), result); } }