Code coverage report for src\components\table-lo\valueFilter.js

# all files / src/components/table-lo/ valueFilter.js

27.27% Statements 3/11
0% Branches 0/6
33.33% Functions 1/3
27.27% Lines 3/11

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

    1×

     (function component(ng) {
      ng.module('components')
        .filter('value', valueFilter);

        function valueFilter() {
            return function(input, oldValue) {
                if (input === oldValue) {
                    return input;
                } else {
                    if (oldValue == null) {
                        oldValue = '';
                    }
                    if (input == '') {
                        return '';
                    }
                    return oldValue + ' => ' + input;
                }
            }
        }
    })(angular);