Add tests for angular-mocks' typings.

This commit is contained in:
Jasmin Auger
2016-03-21 21:25:58 -04:00
parent 1cced363c0
commit ce7496396f
+10
View File
@@ -87,6 +87,16 @@ logCall = logService.warn;
logs = logCall.logs;
///////////////////////////////////////
// IComponentControllerService
///////////////////////////////////////
var $componentController: ng.IComponentControllerService;
$componentController<{}, {}>('Test controller', { $scope: <ng.IScope>{} });
$componentController<{}, {}>('Test controller', { $scope: <ng.IScope>{}, test: true });
$componentController<{}, { test: boolean }>('Test controller', { $scope: <ng.IScope>{} }, { test: true});
$componentController<{}, { test?: boolean }>('Test controller', { $scope: <ng.IScope>{} }, {});
$componentController<{}, {}>('Test controller', { $scope: <ng.IScope>{} }, {}, 'identity');
$componentController<{ cb: () => void }, {}>('Test controller', { $scope: <ng.IScope>{} });
///////////////////////////////////////
// IHttpBackendService