Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Weird output of data structure #42

Open
kbilsted opened this issue Jul 12, 2015 · 1 comment
Open

Weird output of data structure #42

kbilsted opened this issue Jul 12, 2015 · 1 comment
Assignees
Labels
Milestone

Comments

@kbilsted
Copy link
Owner

curly style output of

public class TagsCollection
{
    public Dictionary<string, List<string>> Pages = new Dictionary<string, List<string>>();

    public void Add(string tag, string url)
    {
        List<string> urls;
        if (!Pages.TryGetValue(tag, out urls))
            Pages.Add(tag, urls = new List<string>());
        urls.Add(url);
    }
}

becomes

var expected = @"new TagsCollection()
{
    Pages[""Design""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""SOLID""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[1] = ""BookReviews\Adaptive Code via CS.md""
    Pages[""Single_Responsibility_Principle""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""Design_Pattern""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""Decorator""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""Wrapper""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""Cache""] = new List<String>()
    Pages[0] = ""Articles\Design\MalleableCodeUsingDecorators.md""
    Pages[""Book_Review""] = new List<String>()
    Pages[0] = ""BookReviews\Adaptive Code via CS.md""
}";
@kbilsted kbilsted added the bug label Jul 12, 2015
@kbilsted kbilsted added this to the 2.2.x milestone Jul 12, 2015
@kbilsted kbilsted self-assigned this May 7, 2016
@kbilsted
Copy link
Owner Author

kbilsted commented May 7, 2016

this bug may very well have been solved in 3.0 - need to check

@kbilsted kbilsted modified the milestones: 3.0.x, 2.2.x May 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant