Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wip: Chore/a11y/add test #822

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions _tests/align-generator/templates.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ headless = true
const list = `+++
fragment = "list"
weight = 110
section = "dev/dev-alignments"
section = "dev/alignments"
count = 1000
summary = false
tiled = true
Expand All @@ -36,4 +36,4 @@ module.exports = {
index,
content,
list,
}
};
4 changes: 2 additions & 2 deletions _tests/colors-generator/templates.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ headless = true
const list = `+++
fragment = "list"
weight = 110
section = "dev/dev-colors"
section = "dev/colors"
count = 1000
summary = false
tiled = true
Expand All @@ -36,4 +36,4 @@ module.exports = {
index,
content,
list,
}
};
9 changes: 9 additions & 0 deletions cypress/integration/accessibility.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
describe('Accessibility tests', () => {
it('should run', () => {
cy.visit('http://localhost:1313/dev/colors/dev-buttons');
cy.injectAxe();
cy.checkA11y(null, {
runOnly: ['cat.color'],
});
});
});
3 changes: 2 additions & 1 deletion cypress/support/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
// ***********************************************************

// Import commands.js using ES2015 syntax:
import './commands'
import 'cypress-axe';
import './commands';

// Alternatively you can use CommonJS syntax:
// require('./commands')
2 changes: 1 addition & 1 deletion exampleSite/content/dev/alignments/_index/list.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
+++
fragment = "list"
weight = 110
section = "dev/dev-alignments"
section = "dev/alignments"
count = 1000
summary = false
tiled = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/_index/list.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
+++
fragment = "list"
weight = 110
section = "dev/dev-colors"
section = "dev/colors"
count = 1000
summary = false
tiled = true
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-dark.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ title_align = "left" # Default is center, can be left, right or center

background = "dark"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-light.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ title_align = "left" # Default is center, can be left, right or center

background = "light"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-primary.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ title_align = "left" # Default is center, can be left, right or center

background = "primary"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-secondary.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ title_align = "left" # Default is center, can be left, right or center

background = "secondary"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-tiled-dark.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ subtitle = "Displays pages from dev/blog section"

background = "dark"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ subtitle = "Displays pages from dev/blog section"

background = "light"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ subtitle = "Displays pages from dev/blog section"

background = "primary"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ subtitle = "Displays pages from dev/blog section"

background = "secondary"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ subtitle = "Displays pages from dev/blog section"

background = "white"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/dev/colors/dev-list/list-white.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ title_align = "left" # Default is center, can be left, right or center

background = "white"
count = 5 # Default value is 10
section = "example/blog" # Default value is current section
section = "dev/blog" # Default value is current section
#summary = false # Default value is true
#images = false # Default value is true
#read_more = true # Default value is empty (empty: show when content is truncated, false to never show, true to always show)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ weight = 30
title = "Third Title"
subtitle = "Lorem ipsum dolor sit amet, consectetur adipiscing"

[background]
image = "cat-1.jpeg"

[asset]
icon = "fab fa-github"
+++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
weight = 50

[asset]
image = "dog-2.jpeg"
icon = "fab fa-github"
+++

Ante in nibh mauris cursus mattis molestie a iaculis. Nisi porta lorem mollis aliquam. Eu consequat ac felis donec et odio pellentesque diam volutpat. Arcu dui vivamus arcu felis. Senectus et netus et malesuada fames ac turpis egestas sed. Orci eu lobortis elementum nibh.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
+++
title = "repositories_github"
fragment = "content"
weight = 100
+++

Different colors for repositories_github fragment
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
+++
fragment = "repositories_github"
weight = 143
background = "dark"

user = "okkur"
count = 4 # default is 4
display_forks = false # default is false
sort = "stargazers_count" # default is "stargazers_count"
# allowlist = ["syna", "syna-start"]
+++
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
+++
fragment = "repositories_github"
weight = 141
background = "light"

user = "okkur"
count = 4 # default is 4
display_forks = false # default is false
sort = "stargazers_count" # default is "stargazers_count"
# allowlist = ["syna", "syna-start"]
+++
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
+++
fragment = "repositories_github"
weight = 144
background = "primary"

user = "okkur"
count = 4 # default is 4
display_forks = false # default is false
sort = "stargazers_count" # default is "stargazers_count"
# allowlist = ["syna", "syna-start"]
+++
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
+++
fragment = "repositories_github"
weight = 142
background = "secondary"

user = "okkur"
count = 4 # default is 4
display_forks = false # default is false
sort = "stargazers_count" # default is "stargazers_count"
# allowlist = ["syna", "syna-start"]
+++
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
+++
fragment = "repositories_github"
weight = 140
background = "white"

user = "okkur"
count = 4 # default is 4
display_forks = false # default is false
sort = "stargazers_count" # default is "stargazers_count"
# allowlist = ["syna", "syna-start"]
+++
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"babel-loader": "^8.1.0",
"concurrently": "^5.2.0",
"cypress": "^4.12.0",
"cypress-axe": "^0.8.1",
"extract-text-webpack-plugin": "^3.0.2",
"node-sass": "^4.14.1",
"style-loader": "^1.2.1",
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2218,6 +2218,11 @@ cyclist@~0.2.2:
version "0.2.2"
resolved "https://registry.yarnpkg.com/cyclist/-/cyclist-0.2.2.tgz#1b33792e11e914a2fd6d6ed6447464444e5fa640"

cypress-axe@^0.8.1:
version "0.8.1"
resolved "https://registry.yarnpkg.com/cypress-axe/-/cypress-axe-0.8.1.tgz#ddb37dca6570c0642dda2388daf678e83b3e8d3f"
integrity sha512-hX48+r5n7Ns7CHkn601Ag0JiCG1vby5+g7QhlP8X+mkiVYpTLpXAPiiaKFj9QTTCdZSI5+0UqwIxA+ShTsr5tA==

cypress@^4.12.0:
version "4.12.0"
resolved "https://registry.yarnpkg.com/cypress/-/cypress-4.12.0.tgz#b9d9b16d45be28543edc0e4dc89987bed5bb090b"
Expand Down