Skip to content
This repository has been archived by the owner on May 3, 2022. It is now read-only.

Commit

Permalink
EZP-26872: universaldiscoveryview tests
Browse files Browse the repository at this point in the history
  • Loading branch information
stephaneDiot committed Feb 8, 2017
1 parent 48a2e2a commit 0727921
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion Tests/js/views/assets/ez-universaldiscoveryview-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -619,6 +619,8 @@ YUI.add('ez-universaldiscoveryview-tests', function (Y) {
this.config = {};
this.multiple = true;
this.startingLocationId = 'l/o/c/a/t/i/o/n/i/d';
this.startingLocation = {};
this.virtualRootLocation = {};

Y.eZ.UniversalDiscoveryFinderView = Y.Base.create(
'testFinderView', Y.eZ.UniversalDiscoveryMethodBaseView, [], {}
Expand All @@ -630,7 +632,9 @@ YUI.add('ez-universaldiscoveryview-tests', function (Y) {
this.view = new Y.eZ.UniversalDiscoveryView({
multiple: this.multiple,
confirmedListView: this.confirmedList,
startingLocationId: this.startingLocationId
startingLocationId: this.startingLocationId,
startingLocation: this.startingLocation,
virtualRootLocation: this.virtualRootLocation,
});
},

Expand Down Expand Up @@ -669,6 +673,14 @@ YUI.add('ez-universaldiscoveryview-tests', function (Y) {
this.startingLocationId, methods[0].get('startingLocationId'),
"The startingLocationId should be passed to the method views"
);
Assert.areSame(
this.startingLocation, methods[0].get('startingLocation'),
"The startingLocation should be passed to the method views"
);
Assert.areSame(
this.virtualRootLocation, methods[0].get('virtualRootLocation'),
"The virtualRootLocation should be passed to the method views"
);
},

"Should add the universal discovery view as a bubble target": function () {
Expand Down

0 comments on commit 0727921

Please # to comment.