From ffa635ad85ce804e06f7158690803628a17406b5 Mon Sep 17 00:00:00 2001 From: Alejandro Alonso Date: Tue, 5 May 2015 12:34:47 +0200 Subject: [PATCH] Adding home directive tests --- app/modules/home/home.directive.coffee | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/modules/home/home.directive.coffee b/app/modules/home/home.directive.coffee index a929d370..a19108bc 100644 --- a/app/modules/home/home.directive.coffee +++ b/app/modules/home/home.directive.coffee @@ -1,5 +1,6 @@ HomeDirective = (homeService) -> link = (scope, el, attrs, ctrl) -> + console.log 111111 scope.vm = {} taiga.defineImmutableProperty(scope.vm, "workInProgress", () -> homeService.workInProgress) @@ -15,12 +16,14 @@ HomeDirective = (homeService) -> issues = workInProgress.get("watching").get("issues") scope.vm.watching = userStories.concat(tasks).concat(issues) - directive = { + return { templateUrl: "home/home.html" scope: {} link: link } - return directive +HomeDirective.$inject = [ + "tgHomeService" +] -angular.module("taigaHome").directive("tgHome", ["tgHomeService", HomeDirective]) +angular.module("taigaHome").directive("tgHome", HomeDirective)