From b5356eb07d253c5928d34367254be1a3725b90f4 Mon Sep 17 00:00:00 2001 From: Carlos Jimenez <=> Date: Wed, 1 Aug 2018 09:47:34 +0200 Subject: [PATCH] spec files renamed accordingly, plus linter or indentation corrections --- .../core/src/components/step-control/step-control.spec.js | 1 + client/core/src/components/th/{th.spec.js => index.spec.js} | 0 client/item/src/barcode/{barcode.spec.js => index.spec.js} | 0 .../item/src/botanical/{botanical.spec.js => index.spec.js} | 0 client/item/src/card/{card.spec.js => index.spec.js} | 0 client/item/src/create/{create.spec.js => index.spec.js} | 0 client/item/src/data/index.js | 2 +- client/item/src/tags/{tags.spec.js => index.spec.js} | 0 client/order/src/filter/index.js | 4 ---- client/ticket/src/component/index.js | 2 +- .../src/component/{component.spec.js => index.spec.js} | 0 .../src/data/step-one/{step-one.spec.js => index.spec.js} | 0 .../data/step-three/{step-three.spec.js => index.spec.js} | 6 +++--- .../src/note/{ticket-observation.spec.js => index.spec.js} | 0 .../ticket/src/package/{package.spec.js => index.spec.js} | 0 .../src/volume/{ticket-volume.spec.js => index.spec.js} | 0 16 files changed, 6 insertions(+), 9 deletions(-) rename client/core/src/components/th/{th.spec.js => index.spec.js} (100%) rename client/item/src/barcode/{barcode.spec.js => index.spec.js} (100%) rename client/item/src/botanical/{botanical.spec.js => index.spec.js} (100%) rename client/item/src/card/{card.spec.js => index.spec.js} (100%) rename client/item/src/create/{create.spec.js => index.spec.js} (100%) rename client/item/src/tags/{tags.spec.js => index.spec.js} (100%) rename client/ticket/src/component/{component.spec.js => index.spec.js} (100%) rename client/ticket/src/data/step-one/{step-one.spec.js => index.spec.js} (100%) rename client/ticket/src/data/step-three/{step-three.spec.js => index.spec.js} (96%) rename client/ticket/src/note/{ticket-observation.spec.js => index.spec.js} (100%) rename client/ticket/src/package/{package.spec.js => index.spec.js} (100%) rename client/ticket/src/volume/{ticket-volume.spec.js => index.spec.js} (100%) diff --git a/client/core/src/components/step-control/step-control.spec.js b/client/core/src/components/step-control/step-control.spec.js index 63a4354db..436e95e37 100644 --- a/client/core/src/components/step-control/step-control.spec.js +++ b/client/core/src/components/step-control/step-control.spec.js @@ -43,6 +43,7 @@ describe('Component vnStepControl', () => { controller.steps = [{state: 'iam_not_current_state'}, {state: 'iam_a_current_state'}]; let result = controller.currentStepIndex; + expect(result).toEqual(1); }); }); diff --git a/client/core/src/components/th/th.spec.js b/client/core/src/components/th/index.spec.js similarity index 100% rename from client/core/src/components/th/th.spec.js rename to client/core/src/components/th/index.spec.js diff --git a/client/item/src/barcode/barcode.spec.js b/client/item/src/barcode/index.spec.js similarity index 100% rename from client/item/src/barcode/barcode.spec.js rename to client/item/src/barcode/index.spec.js diff --git a/client/item/src/botanical/botanical.spec.js b/client/item/src/botanical/index.spec.js similarity index 100% rename from client/item/src/botanical/botanical.spec.js rename to client/item/src/botanical/index.spec.js diff --git a/client/item/src/card/card.spec.js b/client/item/src/card/index.spec.js similarity index 100% rename from client/item/src/card/card.spec.js rename to client/item/src/card/index.spec.js diff --git a/client/item/src/create/create.spec.js b/client/item/src/create/index.spec.js similarity index 100% rename from client/item/src/create/create.spec.js rename to client/item/src/create/index.spec.js diff --git a/client/item/src/data/index.js b/client/item/src/data/index.js index 899ce8fd3..6096a4bfa 100644 --- a/client/item/src/data/index.js +++ b/client/item/src/data/index.js @@ -5,7 +5,7 @@ class Controller { this.$scope = $scope; this.$timeout = $timeout; } - + $onChanges(data) { this.$timeout(() => { this.$scope.watcher.data = data.item.currentValue; diff --git a/client/item/src/tags/tags.spec.js b/client/item/src/tags/index.spec.js similarity index 100% rename from client/item/src/tags/tags.spec.js rename to client/item/src/tags/index.spec.js diff --git a/client/order/src/filter/index.js b/client/order/src/filter/index.js index 0960021a2..f3d831bac 100644 --- a/client/order/src/filter/index.js +++ b/client/order/src/filter/index.js @@ -1,10 +1,6 @@ import ngModule from '../module'; class Controller { - constructor() { - - } - setFilter() { this.catalogue.applyFilter(); } diff --git a/client/ticket/src/component/index.js b/client/ticket/src/component/index.js index 2c912c33c..73a54395f 100644 --- a/client/ticket/src/component/index.js +++ b/client/ticket/src/component/index.js @@ -19,7 +19,7 @@ class Controller extends FilterTicketList { } return sum; } - + base() { let sum; if (this.sales) { diff --git a/client/ticket/src/component/component.spec.js b/client/ticket/src/component/index.spec.js similarity index 100% rename from client/ticket/src/component/component.spec.js rename to client/ticket/src/component/index.spec.js diff --git a/client/ticket/src/data/step-one/step-one.spec.js b/client/ticket/src/data/step-one/index.spec.js similarity index 100% rename from client/ticket/src/data/step-one/step-one.spec.js rename to client/ticket/src/data/step-one/index.spec.js diff --git a/client/ticket/src/data/step-three/step-three.spec.js b/client/ticket/src/data/step-three/index.spec.js similarity index 96% rename from client/ticket/src/data/step-three/step-three.spec.js rename to client/ticket/src/data/step-three/index.spec.js index 76748de0e..db98ab357 100644 --- a/client/ticket/src/data/step-three/step-three.spec.js +++ b/client/ticket/src/data/step-three/index.spec.js @@ -1,4 +1,4 @@ -/* import './step-three.js'; +/* import './index.js'; describe('ticket', () => { describe('Component vnTicketDataStepThree', () => { @@ -38,7 +38,7 @@ describe('ticket', () => { landed: Date.now(), option: 1 }; - + let response = {data: {error: {message: 'NOTHING_HERE'}}}; $httpBackend.whenPOST(`/ticket/api/tickets/1/componentUpdate`, data).respond(400, response); @@ -48,4 +48,4 @@ describe('ticket', () => { }); }); }); -}); */ \ No newline at end of file +}); */ diff --git a/client/ticket/src/note/ticket-observation.spec.js b/client/ticket/src/note/index.spec.js similarity index 100% rename from client/ticket/src/note/ticket-observation.spec.js rename to client/ticket/src/note/index.spec.js diff --git a/client/ticket/src/package/package.spec.js b/client/ticket/src/package/index.spec.js similarity index 100% rename from client/ticket/src/package/package.spec.js rename to client/ticket/src/package/index.spec.js diff --git a/client/ticket/src/volume/ticket-volume.spec.js b/client/ticket/src/volume/index.spec.js similarity index 100% rename from client/ticket/src/volume/ticket-volume.spec.js rename to client/ticket/src/volume/index.spec.js