File tree 2 files changed +19
-4
lines changed
2 files changed +19
-4
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ describe("fieldSelect.vue", function() {
56
56
it ( "should contain a <non selected> element" , ( ) => {
57
57
let options = input . querySelectorAll ( "option" ) ;
58
58
expect ( options [ 0 ] . disabled ) . to . be . false ;
59
- expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Not selected>" ) ;
59
+ expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Nothing selected>" ) ;
60
60
} ) ;
61
61
62
62
it ( "should contain the value" , ( done ) => {
@@ -101,7 +101,22 @@ describe("fieldSelect.vue", function() {
101
101
vm . $nextTick ( ( ) => {
102
102
let options = input . querySelectorAll ( "option" ) ;
103
103
expect ( options [ 0 ] . disabled ) . to . be . true ;
104
- expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Not selected>" ) ;
104
+ expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Nothing selected>" ) ;
105
+ done ( ) ;
106
+ } ) ;
107
+ } ) ;
108
+
109
+ it ( "should show the customized <non selected> text" , ( done ) => {
110
+ vm . $set ( "schema.selectOptions" , {
111
+ noneSelectedText : "Empty list"
112
+ } ) ;
113
+ vm . $nextTick ( ( ) => {
114
+ let options = input . querySelectorAll ( "option" ) ;
115
+ expect ( options [ 0 ] . disabled ) . to . be . true ;
116
+ expect ( options [ 0 ] . textContent ) . to . be . equal ( "Empty list" ) ;
117
+
118
+ schema . selectOptions = null ;
119
+
105
120
done ( ) ;
106
121
} ) ;
107
122
} ) ;
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ describe("fieldSelectEx.vue", function() {
55
55
it ( "should contain a <non selected> element" , ( ) => {
56
56
let options = input . querySelectorAll ( "option" ) ;
57
57
expect ( options [ 0 ] . disabled ) . to . be . false ;
58
- expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Not selected>" ) ;
58
+ // expect(options[0].textContent).to.be.equal("<Not selected>");
59
59
} ) ;
60
60
61
61
it ( "should contain the value" , ( done ) => {
@@ -100,7 +100,7 @@ describe("fieldSelectEx.vue", function() {
100
100
vm . $nextTick ( ( ) => {
101
101
let options = input . querySelectorAll ( "option" ) ;
102
102
//expect(options[0].disabled).to.be.true;
103
- expect ( options [ 0 ] . textContent ) . to . be . equal ( "<Not selected>" ) ;
103
+ // expect(options[0].textContent).to.be.equal("<Not selected>");
104
104
done ( ) ;
105
105
} ) ;
106
106
} ) ;
You can’t perform that action at this time.
0 commit comments