Skip to content

Commit 64e2a5c

Browse files
committed
Update dependencies and fix errors of feature test
1 parent 31005a5 commit 64e2a5c

File tree

4 files changed

+47
-47
lines changed

4 files changed

+47
-47
lines changed

package.json

+29-29
Original file line numberDiff line numberDiff line change
@@ -31,41 +31,41 @@
3131
"react-component"
3232
],
3333
"dependencies": {
34-
"dompurify": "^0.7.4",
34+
"dompurify": "^0.8.3",
3535
"is-dom": "^1.0.5",
36-
"redux-actions": "^0.9.1"
36+
"redux-actions": "^0.12.0"
3737
},
3838
"devDependencies": {
39-
"babel-cli": "^6.7.5",
40-
"babel-core": "^6.7.5",
41-
"babel-loader": "^6.2.4",
42-
"babel-plugin-espower": "^2.1.2",
43-
"babel-polyfill": "^6.7.4",
44-
"babel-preset-es2015": "^6.6.0",
45-
"babel-preset-react": "^6.5.0",
46-
"babel-preset-stage-2": "^6.5.0",
47-
"cssstyle": "^0.2.34",
39+
"babel-cli": "^6.14.0",
40+
"babel-core": "^6.14.0",
41+
"babel-loader": "^6.2.5",
42+
"babel-plugin-espower": "^2.3.1",
43+
"babel-polyfill": "^6.13.0",
44+
"babel-preset-es2015": "^6.14.0",
45+
"babel-preset-react": "^6.11.1",
46+
"babel-preset-stage-2": "^6.13.0",
47+
"cssstyle": "^0.2.37",
4848
"deep-equal": "^1.0.1",
4949
"espower-babel": "^4.0.3",
5050
"json-loader": "^0.5.4",
51-
"karma": "^0.13.22",
52-
"karma-mocha": "^0.2.2",
53-
"karma-mocha-reporter": "^2.0.0",
54-
"karma-phantomjs-launcher": "^1.0.0",
55-
"karma-sinon": "^1.0.4",
56-
"karma-webpack": "^1.7.0",
57-
"mocha": "^2.4.5",
58-
"phantomjs-prebuilt": "^2.1.7",
59-
"power-assert": "^1.3.1",
60-
"react": "^0.14.8",
61-
"react-addons-test-utils": "^0.14.8",
62-
"react-dom": "^0.14.8",
63-
"react-redux": "^4.4.1",
64-
"redux": "^3.3.1",
51+
"karma": "^1.3.0",
52+
"karma-mocha": "^1.1.1",
53+
"karma-mocha-reporter": "^2.1.0",
54+
"karma-phantomjs-launcher": "^1.0.2",
55+
"karma-sinon": "^1.0.5",
56+
"karma-webpack": "^1.8.0",
57+
"mocha": "^3.0.2",
58+
"phantomjs-prebuilt": "^2.1.12",
59+
"power-assert": "^1.4.1",
60+
"react": "^15.3.1",
61+
"react-addons-test-utils": "^15.3.1",
62+
"react-dom": "^15.3.1",
63+
"react-redux": "^4.4.5",
64+
"redux": "^3.6.0",
6565
"redux-logger": "^2.6.1",
66-
"rimraf": "^2.5.2",
67-
"sinon": "^1.17.3",
68-
"webpack": "^1.12.14",
69-
"webpack-dev-server": "^1.14.1"
66+
"rimraf": "^2.5.4",
67+
"sinon": "^1.17.5",
68+
"webpack": "^1.13.2",
69+
"webpack-dev-server": "^1.15.1"
7070
}
7171
}

tests/feature/content.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ describe('Content Example', () => {
3838

3939
const tooltip = firstComponent(tree, Tooltip.WrappedComponent).refs.tooltip;
4040
assert(getStyleValue(tooltip, 'visibility') === 'visible');
41-
assert(tooltip.innerText === "This is a default content.\nIt's a second line.\n", 'should be default content');
41+
assert(tooltip.innerText === "This is a default content.\nIt's a second line.", 'should be default content');
4242
});
4343
});
4444

tests/feature/multiple.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ describe('Multiple Example', () => {
3434

3535
const greenTip = firstComponent(tree, Tooltip.WrappedComponent, { name: 'green' }).refs.tooltip;
3636
assert(getStyleValue(greenTip, 'visibility') === 'visible');
37-
assert(greenTip.innerText === 'This is a Green tooltip.\n');
37+
assert(greenTip.innerText === 'This is a Green tooltip.');
3838

3939
TestUtils.Simulate.mouseLeave(green);
4040
assert(getStyleValue(greenTip, 'visibility') === 'hidden');
@@ -45,7 +45,7 @@ describe('Multiple Example', () => {
4545

4646
const redTip = firstComponent(tree, Tooltip.WrappedComponent, { name: 'red' }).refs.tooltip;
4747
assert(getStyleValue(redTip, 'visibility') === 'visible');
48-
assert(redTip.innerText === 'This is a Red tooltip.\n');
48+
assert(redTip.innerText === 'This is a Red tooltip.');
4949

5050
TestUtils.Simulate.mouseLeave(red);
5151
assert(getStyleValue(redTip, 'visibility') === 'hidden');
@@ -55,9 +55,9 @@ describe('Multiple Example', () => {
5555
TestUtils.Simulate.mouseEnter(both);
5656

5757
assert(getStyleValue(greenTip, 'visibility') === 'visible');
58-
assert(greenTip.innerText === 'This is a Green tooltip.\n');
58+
assert(greenTip.innerText === 'This is a Green tooltip.');
5959
assert(getStyleValue(redTip, 'visibility') === 'visible');
60-
assert(redTip.innerText === 'This is a Red tooltip.\n');
60+
assert(redTip.innerText === 'This is a Red tooltip.');
6161

6262
TestUtils.Simulate.mouseLeave(both);
6363
assert(getStyleValue(greenTip, 'visibility') === 'hidden');

tests/feature/place.js

+13-13
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ describe('Place Example', () => {
3838

3939
const rightOri = position(right);
4040
const rightTip = position(tooltip);
41-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
41+
assert(tooltip.innerText === 'This is a shared tooltip.');
4242
assert(rightOri.left < rightTip.left);
4343

4444
// Mouseover to bottom
@@ -48,7 +48,7 @@ describe('Place Example', () => {
4848

4949
const bottomOri = position(bottom);
5050
const bottomTip = position(tooltip);
51-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
51+
assert(tooltip.innerText === 'This is a shared tooltip.');
5252
assert(bottomOri.top < bottomTip.top);
5353

5454
// Mouseover to left
@@ -58,7 +58,7 @@ describe('Place Example', () => {
5858

5959
const leftOri = position(left);
6060
const leftTip = position(tooltip);
61-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
61+
assert(tooltip.innerText === 'This is a shared tooltip.');
6262
assert(leftTip.left < leftOri.left);
6363

6464
// Mouseover to top
@@ -68,7 +68,7 @@ describe('Place Example', () => {
6868

6969
const topOri = position(top);
7070
const topTip = position(tooltip);
71-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
71+
assert(tooltip.innerText === 'This is a shared tooltip.');
7272
assert(topTip.top < topOri.top);
7373
});
7474
});
@@ -83,7 +83,7 @@ describe('Place Example', () => {
8383

8484
const rightOri = position(right);
8585
const rightTip = position(rightTooltip);
86-
assert(rightTooltip.innerText === 'This is a right tooltip.\n');
86+
assert(rightTooltip.innerText === 'This is a right tooltip.');
8787
assert(rightOri.left < rightTip.left);
8888

8989
// Mouseover to bottom
@@ -94,7 +94,7 @@ describe('Place Example', () => {
9494

9595
const bottomOri = position(bottom);
9696
const bottomTip = position(bottomTooltip);
97-
assert(bottomTooltip.innerText === 'This is a bottom tooltip.\n');
97+
assert(bottomTooltip.innerText === 'This is a bottom tooltip.');
9898
assert(bottomOri.top < bottomTip.top);
9999

100100
// Mouseover to left
@@ -105,7 +105,7 @@ describe('Place Example', () => {
105105

106106
const leftOri = position(left);
107107
const leftTip = position(leftTooltip);
108-
assert(leftTooltip.innerText === 'This is a left tooltip.\n');
108+
assert(leftTooltip.innerText === 'This is a left tooltip.');
109109
assert(leftTip.left < leftOri.left);
110110

111111
// Mouseover to top
@@ -116,7 +116,7 @@ describe('Place Example', () => {
116116

117117
const topOri = position(top);
118118
const topTip = position(topTooltip);
119-
assert(topTooltip.innerText === 'This is a top tooltip.\n');
119+
assert(topTooltip.innerText === 'This is a top tooltip.');
120120
assert(topTip.top < topOri.top);
121121
});
122122
});
@@ -128,7 +128,7 @@ describe('Place Example', () => {
128128
const origin = firstComponent(tree, Origin.WrappedComponent, { className: 'target auto-basic' }).refs.wrapper;
129129
TestUtils.Simulate.mouseEnter(origin);
130130
assert(getStyleValue(tooltip, 'visibility') === 'visible');
131-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
131+
assert(tooltip.innerText === 'This is a shared tooltip.');
132132

133133
const tipPos = position(tooltip);
134134
const oriPos = position(origin);
@@ -141,7 +141,7 @@ describe('Place Example', () => {
141141
const array = firstComponent(tree, Origin.WrappedComponent, { className: 'target auto-array' }).refs.wrapper;
142142
TestUtils.Simulate.mouseEnter(array);
143143
assert(getStyleValue(tooltip, 'visibility') === 'visible');
144-
assert(tooltip.innerText === 'This is a shared tooltip.\n');
144+
assert(tooltip.innerText === 'This is a shared tooltip.');
145145

146146
const arrayTipPos = position(tooltip);
147147
const arrayOriPos = position(array);
@@ -163,7 +163,7 @@ describe('Place Example', () => {
163163
const more = firstComponent(tree, Origin.WrappedComponent, { className: 'target auto-more' }).refs.wrapper;
164164
TestUtils.Simulate.mouseEnter(more);
165165
assert(getStyleValue(tooltip, 'visibility') === 'visible');
166-
assert(tooltip.innerText === 'This is a more tooltip.\n');
166+
assert(tooltip.innerText === 'This is a more tooltip.');
167167

168168
const tipPos = position(tooltip);
169169
const oriPos = position(more);
@@ -176,7 +176,7 @@ describe('Place Example', () => {
176176
const top = firstComponent(tree, Origin.WrappedComponent, { className: 'target auto-top' }).refs.wrapper;
177177
TestUtils.Simulate.mouseEnter(top);
178178
assert(getStyleValue(tooltip, 'visibility') === 'visible');
179-
assert(tooltip.innerText === 'This is a restricted tooltip.\n');
179+
assert(tooltip.innerText === 'This is a restricted tooltip.');
180180

181181
const topTipPos = position(tooltip);
182182
const topOriPos = position(top);
@@ -207,7 +207,7 @@ describe('Place Example', () => {
207207
const disabled = firstComponent(tree, Origin.WrappedComponent, { className: 'target auto-disabled' }).refs.wrapper;
208208
TestUtils.Simulate.mouseEnter(disabled);
209209
assert(getStyleValue(tooltip, 'visibility') === 'visible');
210-
assert(tooltip.innerText === 'This is a disabled tooltip.\n');
210+
assert(tooltip.innerText === 'This is a disabled tooltip.');
211211

212212
const tipPos = position(tooltip);
213213
const oriPos = position(disabled);

0 commit comments

Comments
 (0)