Advertisement
Guest User

Untitled

a guest
Jun 28th, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. escribe('myControllers', function () {
  2. beforeEach(module('myApp', [ 'ngRoute', 'ngMdIcons']));
  3.  
  4. describe('AboutController', function () {
  5. var controller, scope, route;
  6.  
  7. beforeEach(inject(function ($rootScope, $route, $controller) {
  8. scope = $rootScope.$new();
  9. route = $route;
  10. controller = $controller('AboutController', {
  11. $scope: scope
  12. });
  13. }));
  14.  
  15. it('should ...', function () {
  16. expect(controller).toBeDefined();
  17. expect(scope.template).toBe(route.routes['/about'].templateUrl);
  18. });
  19.  
  20. it('should create a "profile" model with 4 keys', function () {
  21. expect(scope.profile.length(4));
  22.  
  23. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement