From 16a0ff1c30f1396e13d9f72a1ad9bf121da17ab4 Mon Sep 17 00:00:00 2001 From: Gilgard <Hjelljord.alida@gmail.com> Date: Fri, 29 Apr 2022 12:36:19 +0200 Subject: [PATCH] fix tests after merge --- .../__snapshots__/chat-message.spec.js.snap | 23 ------------- .../chat-component-tests/chat-message.spec.js | 34 ------------------- 2 files changed, 57 deletions(-) delete mode 100644 tests/unit/component-tests/chat-component-tests/__snapshots__/chat-message.spec.js.snap delete mode 100644 tests/unit/component-tests/chat-component-tests/chat-message.spec.js diff --git a/tests/unit/component-tests/chat-component-tests/__snapshots__/chat-message.spec.js.snap b/tests/unit/component-tests/chat-component-tests/__snapshots__/chat-message.spec.js.snap deleted file mode 100644 index 8efff29..0000000 --- a/tests/unit/component-tests/chat-component-tests/__snapshots__/chat-message.spec.js.snap +++ /dev/null @@ -1,23 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`ChatMessageComponent renders correctly 1`] = ` -<div - class="w-full break-words flex justify-start" -> - <div - class="bg-gray-300 rounded px-5 py-2 my-2 relative text-gray-900" - style="max-width: 70%;" - > - <span - class="block" - > - string 1 - </span> - <span - class="block text-xs text-right" - > - 10:20 - </span> - </div> -</div> -`; diff --git a/tests/unit/component-tests/chat-component-tests/chat-message.spec.js b/tests/unit/component-tests/chat-component-tests/chat-message.spec.js deleted file mode 100644 index 074623e..0000000 --- a/tests/unit/component-tests/chat-component-tests/chat-message.spec.js +++ /dev/null @@ -1,34 +0,0 @@ -import { mount } from "@vue/test-utils"; -import ChatMessage from "@/components/ChatComponents/ChatMessage.vue" - -describe("ChatMessageComponent", () => { - let wrapper; - - beforeEach(() => { - wrapper = mount(ChatMessage, { - //passing prop to component - computed: { - userID() { - return 1; - } - }, - props: { - message: { - id: 1, - content: "string", - timestamp: "2022-04-29T08:20:42.850Z", - from: 1, - to: 3 - } - } - }); - }); - - it("renders correctly", () => { - expect(wrapper.element).toMatchSnapshot(); - }); - - it("is instantiated", () => { - expect(wrapper.exists()).toBeTruthy(); - }); -}); \ No newline at end of file -- GitLab