diff --git a/packages/core/src/layout/Header/Waves.test.tsx b/packages/core/src/layout/Header/Waves.test.tsx
new file mode 100644
index 0000000000..2c7d463052
--- /dev/null
+++ b/packages/core/src/layout/Header/Waves.test.tsx
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Spotify AB
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import React from 'react';
+import { render } from '@testing-library/react';
+import { pageTheme } from '../Page/PageThemeProvider';
+import Waves from './Waves';
+
+describe('', () => {
+ it('should render svg', () => {
+ const rendered = render();
+ rendered.getByTestId('wave-svg');
+ });
+});
diff --git a/packages/core/src/layout/Header/Waves.js b/packages/core/src/layout/Header/Waves.tsx
similarity index 94%
rename from packages/core/src/layout/Header/Waves.js
rename to packages/core/src/layout/Header/Waves.tsx
index 52523834dc..f37ecf7b12 100644
--- a/packages/core/src/layout/Header/Waves.js
+++ b/packages/core/src/layout/Header/Waves.tsx
@@ -14,10 +14,11 @@
* limitations under the License.
*/
-import React from 'react';
+import React, { FC } from 'react';
import { makeStyles } from '@material-ui/core';
+import { PageTheme } from '../Page';
-const useStyles = makeStyles({
+const useStyles = makeStyles({
wave: {
position: 'absolute',
height: '100%',
@@ -26,11 +27,15 @@ const useStyles = makeStyles({
bottom: 0,
left: 0,
right: 0,
- 'z-index': -1,
+ zIndex: -1,
},
});
-const Waves = ({ theme }) => {
+type Props = {
+ theme: PageTheme;
+};
+
+const Waves: FC = ({ theme }) => {
const classes = useStyles();
const [color1, color2] = theme.gradient.colors;
@@ -41,6 +46,7 @@ const Waves = ({ theme }) => {
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={classes.wave}
+ data-testid="wave-svg"
>