From aa9b4c8c2b62eca0389adc483c3ef9bd783c319a Mon Sep 17 00:00:00 2001 From: Cameron Ross Date: Thu, 24 Jan 2019 02:01:40 -0400 Subject: [PATCH] fix a Resolver test --- source/dyaml/resolver.d | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/source/dyaml/resolver.d b/source/dyaml/resolver.d index 8d8c027..ca5b347 100644 --- a/source/dyaml/resolver.d +++ b/source/dyaml/resolver.d @@ -95,7 +95,7 @@ final class Resolver } } /// Resolve scalars starting with 'A' to !_tag - unittest + @safe unittest { import std.file : write; import std.regex : regex; @@ -109,11 +109,8 @@ final class Resolver resolver.addImplicitResolver("!tag", regex("A.*"), "A"); loader.resolver = resolver; - //Note that we have no constructor from tag "!tag", so we can't - //actually load anything that resolves to this tag. - //See Constructor API documentation and tutorial for more information. - - //auto node = loader.load(); + auto node = loader.load(); + assert(node.tag == "!tag"); } package: