public void Can_get_built_in_command_hidden_by_override() { var cache = new DefinitionCache(); cache .Add(DefinitionCacheItemType.BuiltIn, "l1", DateTime.Now, false, true, "cmd1", "") .Append(DefinitionCacheItemType.BuiltIn, "l1", DateTime.Now, false, true, "cmd1-1", ""); cache .Add(DefinitionCacheItemType.Script, "l2", DateTime.Now, false, true, "cmd1", "") .Append(DefinitionCacheItemType.Script, "l2", DateTime.Now, false, true, "override-1", ""); var item = cache.GetBuiltIn(new[] { "cmd1" }); Assert.That(item.Type, Is.EqualTo(DefinitionCacheItemType.BuiltIn)); Assert.That(item.Location, Is.EqualTo("l1")); Assert.That(item.Parameters[0].Name, Is.EqualTo("cmd1-1")); }
public DefinitionCacheItem GetBuiltIn(string[] args) { return(_cache.GetBuiltIn(args)); }