summaryrefslogtreecommitdiff
path: root/product/Presentation/Presenters/NavigationPresenterSpecs.cs
blob: cf05dd0ffc1f70d15adbab1b61bb1ba2828079c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
using developwithpassion.bdd.contexts;
using Gorilla.Commons.Testing;
using MoMoney.Presentation.Model.Navigation;
using MoMoney.Presentation.Views;

namespace MoMoney.Presentation.Presenters
{
    [Concern(typeof (NavigationPresenter))]
    public class when_building_the_navigation_tree : concerns_for<INavigationPresenter, NavigationPresenter>
    {
        it should_visit_the_root_node_of_the_tree = () => view.was_told_to(x => x.accept(tree_view_visitor));

        context c = () =>
        {
            view = the_dependency<INavigationView>();
            tree_view_visitor = the_dependency<INavigationTreeVisitor>();
        };

        because b = () => sut.run();

        static INavigationView view;
        static INavigationTreeVisitor tree_view_visitor;
    }
}