Code coverage report for src\services\sop.js

# all files / src/services/ sop.js

55.56% Statements 5/9
100% Branches 0/0
25% Functions 1/4
55.56% Lines 5/9

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    221×
    1×

    1×

    1×

    1×

     (function voyageService(ng) {
      ng.module('services')
        .factory('sop', factory);

      factory.$inject = ['$q', '$http', 'restSettings'];

      function factory($q, $http, restSettings) {
        var service = {
          getList: getList
        };

        return service;

        function getList(force) {
          return $q(function promise(resolve, reject) {
            $http.get(restSettings.url + '/voyage/list', {
              cache: !force
            }).then(resolve, reject);
          });
        }
      }
    })(angular);