diff --git a/test/utils/fixtures/themes/README.md b/test/utils/fixtures/themes/README.md index 24c966d3ae..ed6fc00b16 100644 --- a/test/utils/fixtures/themes/README.md +++ b/test/utils/fixtures/themes/README.md @@ -6,9 +6,20 @@ These files are used throughout our tests to mock themes in various states. The casper fixture is a partial copy of the content/themes/casper folder. It should not include any files that aren't needed to run the theme. -To update it, make sure you are in side this folder (the fixtures/themes directory) and run: +To update it: -`rsync -rv --exclude '.git*' --exclude 'assets/css*' --exclude 'assets/js*' --exclude 'gulpfile.js' --exclude 'yarn.lock' --exlcude 'README.md' ../../../../content/themes/casper .` +1. Ensure your `content/themes/casper` folder is on the latest released version e.g. + +- Run `yarn main` +- `cd content/themes/casper` +- `git log -20` - find the latest tag +- `git checkout vx.y.z` - checkout the latest tag + +2. Ensure you are in side this folder (the fixtures/themes directory), remove casper entirely and then copy it across fresh: + +- `cd tests/utils/fixtures/themes` +- `rm -rf casper` +- `rsync -rv --exclude '.git*' --exclude 'assets/css*' --exclude 'assets/js*' --exclude 'gulpfile.js' --exclude 'yarn.lock' --exclude 'README.md' ../../../../content/themes/casper .` ### Modifying theme fixtures When a new rule is introduced in gscan one of these fixture files might break and you'll have to update a "zip" which isn't as easy as opening a text editor... It could become that one day but for now here are some commands to help out with the edit process diff --git a/test/utils/fixtures/themes/casper/assets/screenshot-desktop.jpg b/test/utils/fixtures/themes/casper/assets/screenshot-desktop.jpg old mode 100644 new mode 100755 diff --git a/test/utils/fixtures/themes/casper/assets/screenshot-mobile.jpg b/test/utils/fixtures/themes/casper/assets/screenshot-mobile.jpg old mode 100644 new mode 100755 diff --git a/test/utils/fixtures/themes/casper/partials/byline-multiple.hbs b/test/utils/fixtures/themes/casper/partials/byline-multiple.hbs deleted file mode 100644 index e1c9d159e6..0000000000 --- a/test/utils/fixtures/themes/casper/partials/byline-multiple.hbs +++ /dev/null @@ -1,72 +0,0 @@ -
- -
-

This post was a collaboration between

-

{{authors}}

-
- - - -
- -{{#contentFor "scripts"}} - -{{/contentFor}} diff --git a/test/utils/fixtures/themes/casper/partials/byline-single.hbs b/test/utils/fixtures/themes/casper/partials/byline-single.hbs deleted file mode 100644 index c888773f5b..0000000000 --- a/test/utils/fixtures/themes/casper/partials/byline-single.hbs +++ /dev/null @@ -1,23 +0,0 @@ -{{!-- Everything inside the #author tags pulls data from the author --}} -{{#primary_author}} - -
- {{#if profile_image}} - {{name}} - {{else}} - {{> "icons/avatar"}} - {{/if}} -
-

{{name}}

- {{#if bio}} -

{{bio}}

- {{else}} -

Read more posts by this author.

- {{/if}} -
-
-
- Read More -
- -{{/primary_author}} diff --git a/test/utils/fixtures/themes/casper/partials/floating-header.hbs b/test/utils/fixtures/themes/casper/partials/floating-header.hbs deleted file mode 100644 index 3ceb8fc769..0000000000 --- a/test/utils/fixtures/themes/casper/partials/floating-header.hbs +++ /dev/null @@ -1,28 +0,0 @@ -
- - -
{{title}}
-
-
Share this {{> "icons/point"}}
- - {{> "icons/twitter"}} - - - {{> "icons/facebook"}} - -
- -
- -
-
-
diff --git a/test/utils/fixtures/themes/casper/partials/icons/ghost-logo.hbs b/test/utils/fixtures/themes/casper/partials/icons/ghost-logo.hbs deleted file mode 100644 index 637a2b5bea..0000000000 --- a/test/utils/fixtures/themes/casper/partials/icons/ghost-logo.hbs +++ /dev/null @@ -1 +0,0 @@ -Ghost Logo diff --git a/test/utils/fixtures/themes/casper/partials/icons/infinity.hbs b/test/utils/fixtures/themes/casper/partials/icons/infinity.hbs deleted file mode 100644 index 87e44eaae1..0000000000 --- a/test/utils/fixtures/themes/casper/partials/icons/infinity.hbs +++ /dev/null @@ -1 +0,0 @@ - diff --git a/test/utils/fixtures/themes/casper/partials/icons/location.hbs b/test/utils/fixtures/themes/casper/partials/icons/location.hbs deleted file mode 100644 index 0c2d86661e..0000000000 --- a/test/utils/fixtures/themes/casper/partials/icons/location.hbs +++ /dev/null @@ -1 +0,0 @@ - diff --git a/test/utils/fixtures/themes/casper/partials/icons/point.hbs b/test/utils/fixtures/themes/casper/partials/icons/point.hbs deleted file mode 100644 index f3c702574a..0000000000 --- a/test/utils/fixtures/themes/casper/partials/icons/point.hbs +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/test/utils/fixtures/themes/casper/partials/icons/website.hbs b/test/utils/fixtures/themes/casper/partials/icons/website.hbs deleted file mode 100644 index 08be39fa02..0000000000 --- a/test/utils/fixtures/themes/casper/partials/icons/website.hbs +++ /dev/null @@ -1 +0,0 @@ - diff --git a/test/utils/fixtures/themes/casper/partials/site-nav.hbs b/test/utils/fixtures/themes/casper/partials/site-nav.hbs deleted file mode 100644 index b2e66abff8..0000000000 --- a/test/utils/fixtures/themes/casper/partials/site-nav.hbs +++ /dev/null @@ -1,29 +0,0 @@ -