From 81ba212ec1e5402b5bfda10ba88b118c77d4ff10 Mon Sep 17 00:00:00 2001 From: Hidetaka Okamoto Date: Wed, 20 Jun 2018 16:24:06 +0900 Subject: [PATCH] Add snapshot test about `MoreMenu` component (#7338) * add snapshot test about edit-post/components/header/more-menu component * fix test code to allow lint style --- CONTRIBUTORS.md | 3 +- .../test/__snapshots__/index.js.snap | 72 +++++++++++++++++++ .../components/header/more-menu/test/index.js | 19 +++++ 3 files changed, 93 insertions(+), 1 deletion(-) create mode 100644 edit-post/components/header/more-menu/test/__snapshots__/index.js.snap create mode 100644 edit-post/components/header/more-menu/test/index.js diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 1283c8a6182089..aa13f98b947abc 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -98,4 +98,5 @@ This list is manually curated to include valuable contributions by volunteers th | @nfmohit-wpmudev | | @noisysocks | @noisysocks | | @omarreiss | @omarreiss | -| @hedgefield | @hedgefield | \ No newline at end of file +| @hedgefield | @hedgefield | +| @hideokamoto | @hideokamoto | diff --git a/edit-post/components/header/more-menu/test/__snapshots__/index.js.snap b/edit-post/components/header/more-menu/test/__snapshots__/index.js.snap new file mode 100644 index 00000000000000..b4b682a24b1fd9 --- /dev/null +++ b/edit-post/components/header/more-menu/test/__snapshots__/index.js.snap @@ -0,0 +1,72 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`MoreMenu should match snapshot 1`] = ` + + +
+
+ + + + + + +
+
+
+
+`; diff --git a/edit-post/components/header/more-menu/test/index.js b/edit-post/components/header/more-menu/test/index.js new file mode 100644 index 00000000000000..83f9de19ba7068 --- /dev/null +++ b/edit-post/components/header/more-menu/test/index.js @@ -0,0 +1,19 @@ +/** + * External dependencies + */ +import { mount } from 'enzyme'; + +/** + * Internal dependencies + */ +import MoreMenu from '../index'; + +describe( 'MoreMenu', () => { + it( 'should match snapshot', () => { + const wrapper = mount( + + ); + + expect( wrapper ).toMatchSnapshot(); + } ); +} );