Skip to content

Instantly share code, notes, and snippets.

@lmiller1990
Created July 24, 2018 04:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lmiller1990/af236af57f7d4e788c2bc43f44efc9df to your computer and use it in GitHub Desktop.
Save lmiller1990/af236af57f7d4e788c2bc43f44efc9df to your computer and use it in GitHub Desktop.
it("renders a username from query string", () => {
const username = "alice"
const wrapper = shallowMount(NestedRoute, {
mocks: {
$route: {
params: { username }
}
}
})
expect(wrapper.find(".username").text()).toBe(username)
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment