Skip to content
This repository has been archived by the owner on May 20, 2024. It is now read-only.

Commit

Permalink
[tests] update components paths in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ArmorDarks committed Aug 3, 2019
1 parent 9c4e292 commit 6ddca04
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions tests/kotsu/components/AlternateUrls.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,37 +22,37 @@ const mockContext = {
describe('Nunjucks component `AlternateUrls()`', () => {
it('should print proper meta tag', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US') }}
`)).toMatchSnapshot()
})
it('should print proper meta tag with url specified', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US', '/some/specific/url') }}
`)).toMatchSnapshot()
})
it('should print proper meta tag with absolute url specified', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US', 'https://test.dev') }}
`)).toMatchSnapshot()
})
it('should print proper meta tags when locale is default for its language', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US', undefined, true) }}
`)).toMatchSnapshot()
})
it('should print proper meta tag for language only', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US', undefined, false, true) }}
`)).toMatchSnapshot()
})
it('should print proper meta tag for language only when locale is default for its language', () => {
expect(render(`
{% from '_components/_AlternateUrls.nj' import AlternateUrls with context %}
{% from '_components/AlternateUrls.nj' import AlternateUrls with context %}
{{ AlternateUrls('en-US', undefined, true, true) }}
`)).toMatchSnapshot()
})
Expand Down
4 changes: 2 additions & 2 deletions tests/kotsu/components/Breadcrumb.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ describe('Nunjucks component `Breadcrumb()`', () => {
}

expect(render(`
{% from '_components/_Breadcrumb.nj' import Breadcrumb with context %}
{% from '_components/Breadcrumb.nj' import Breadcrumb with context %}
{{ Breadcrumb() }}
`, testContext)).toMatchSnapshot()
})
Expand All @@ -64,7 +64,7 @@ describe('Nunjucks component `Breadcrumb()`', () => {
}

expect(render(`
{% from '_components/_Breadcrumb.nj' import Breadcrumb with context %}
{% from '_components/Breadcrumb.nj' import Breadcrumb with context %}
{{ Breadcrumb() }}
`, testContext)).toMatchSnapshot()
})
Expand Down

0 comments on commit 6ddca04

Please sign in to comment.