From 5b05d014abec2606a32edee09e26983a714bb90d Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Thu, 18 Jun 2020 00:17:14 -0700 Subject: [PATCH 1/7] back to dev --- .../stanford_image_styles_preview.info.yml | 2 +- stanford_image_styles.info.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml index 33600ed..71a1664 100644 --- a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml +++ b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml @@ -3,6 +3,6 @@ type: module description: Provides an admin page to view a preview of all image styles after effects are applied. core: 8.x package: Stanford -version: 8.x-1.1 +version: 8.x-1.2-dev dependencies: - stanford_image_styles:stanford_image_styles diff --git a/stanford_image_styles.info.yml b/stanford_image_styles.info.yml index def6119..76dc831 100755 --- a/stanford_image_styles.info.yml +++ b/stanford_image_styles.info.yml @@ -3,7 +3,7 @@ type: module description: 'Provides Image Styles' core_version_requirement: ^8 || ^9 package: Stanford -version: 8.x-1.1 +version: 8.x-1.2-dev dependencies: - drupal:image - drupal:responsive_image From 395f4265e4670d4af5d2cc80a4a4fb94fbdb3a35 Mon Sep 17 00:00:00 2001 From: pookmish Date: Wed, 8 Jul 2020 20:50:20 -0700 Subject: [PATCH 2/7] D8CORE-1538 Convert behat tests to codeception (#56) * D8CORE-1538 Convert behat tests to codeception. --- .circleci/config.yml | 50 +++++++++++------- .codeclimate.yml | 22 ++++---- tests/behat/features/ImageStyles.feature | 26 ---------- .../features/ResponsiveImageStyles.feature | 12 ----- tests/codeception/acceptance/StylesCest.php | 52 +++++++++++++++++++ 5 files changed, 95 insertions(+), 67 deletions(-) delete mode 100644 tests/behat/features/ImageStyles.feature delete mode 100644 tests/behat/features/ResponsiveImageStyles.feature create mode 100644 tests/codeception/acceptance/StylesCest.php diff --git a/.circleci/config.yml b/.circleci/config.yml index 5036f50..64811aa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -35,47 +35,57 @@ code_coverage: &code_coverage - store_artifacts: path: /var/www/html/artifacts/phpunit/coverage -behat: &behat +codeception: &codeception <<: *defaults steps: - - restore_cache: - keys: - - dependencies- - checkout: path: /var/www/test - run: - name: Run Behat Tests + name: Run Acceptance Tests command: | composer global require SU-SWS/stanford-caravan:dev-8.x-1.x - ~/.composer/vendor/bin/sws-caravan behat /var/www/html --extension-dir=/var/www/test - - save_cache: - key: dependencies-{{ epoch }} - paths: - - . + ~/.composer/vendor/bin/sws-caravan codeception /var/www/html --extension-dir=/var/www/test - store_test_results: path: /var/www/html/artifacts/behat - store_artifacts: path: /var/www/html/artifacts +back_to_dev: &back_to_dev + <<: *defaults + steps: + - checkout + - run: + name: Back to dev + command: | + composer global require SU-SWS/stanford-caravan:dev-8.x-1.x + ~/.composer/vendor/bin/sws-caravan back-to-dev ${CIRCLE_TAG} ${CIRCLE_WORKING_DIRECTORY} + # Declare all of the jobs we should run. jobs: run-coverage: <<: *code_coverage - run-behat: - <<: *behat + run-codeception: + <<: *codeception + run-back-to-dev: + <<: *back_to_dev # Declare a workflow that runs all of our jobs in parallel. workflows: version: 2 - tests: + after_release: jobs: - - run-coverage - - run-behat - # Re-test every sunday in case this code becomes stale. - sundays: + - run-back-to-dev: + filters: + tags: + only: + - /^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*).*?$/ + branches: + ignore: + - /.*/ + weekly: jobs: - run-coverage - - run-behat + - run-codeception triggers: - schedule: cron: "0 0 * * 0" @@ -83,3 +93,7 @@ workflows: branches: only: - 8.x-1.x + tests: + jobs: + - run-coverage + - run-codeception diff --git a/.codeclimate.yml b/.codeclimate.yml index bbe78a1..9f63d61 100755 --- a/.codeclimate.yml +++ b/.codeclimate.yml @@ -111,14 +111,14 @@ plugins: - dsm # exclude these files/paths exclude_patterns: -- "test" -- "tests" -- "**/tests/**/*" -- "vendor" -- "vendors" -- "node_modules" -- "composer.json" -- "package.json" -- "webpack.config.js" -- "**.min.*" -- "spec/" + - "test" + - "tests" + - "**/tests/**/*" + - "vendor" + - "vendors" + - "node_modules" + - "composer.json" + - "package.json" + - "webpack.config.js" + - "**.min.*" + - "spec/" diff --git a/tests/behat/features/ImageStyles.feature b/tests/behat/features/ImageStyles.feature deleted file mode 100644 index 91d8ce7..0000000 --- a/tests/behat/features/ImageStyles.feature +++ /dev/null @@ -1,26 +0,0 @@ -@api -Feature: Stanford Image styles - In order to verify that image styles are added - As an admin - I should be able to see the correct image styles - - Scenario: Check for the image styles - Given I am logged in as a user with the "administrator" role - And I am on "admin/config/media/image-styles" - Then I should see "Circle" - And I should see "Breakpoint - LG - 1x" - And I should see "Breakpoint - LG - 2x" - And I should see "Breakpoint - MD - 1x" - And I should see "Breakpoint - MD - 2x" - And I should see "Breakpoint - SM - 1x" - And I should see "Breakpoint - SM - 2x" - And I should see "Breakpoint - XL - 1x" - And I should see "Breakpoint - XL - 2x" - And I should see "Breakpoint - 2XL - 1x" - And I should see "Breakpoint - 2XL - 2x" - And I should see "Card - 1X - 478x318" - And I should see "Card - 2X - 956x636" - And I should see "CTA - 1X - 507x338" - And I should see "CTA - 1X - 596x397" - And I should see "CTA - 2X - 1014x676" - And I should see "CTA - 2X - 1192x794" diff --git a/tests/behat/features/ResponsiveImageStyles.feature b/tests/behat/features/ResponsiveImageStyles.feature deleted file mode 100644 index 0441e0a..0000000 --- a/tests/behat/features/ResponsiveImageStyles.feature +++ /dev/null @@ -1,12 +0,0 @@ -@api -Feature: Stanford Responsive Image styles - In order to verify that the responsive image styles are added - As an admin - I should be able to see the correct responsive image styles - - Scenario: Check for the responsive image styles - Given I am logged in as a user with the "administrator" role - And I am on "admin/config/media/responsive-image-style" - Then I should see "Card - 478x318" - Then I should see "CTA - 596x397" - Then I should see "Stanford Hero Block - Wide" diff --git a/tests/codeception/acceptance/StylesCest.php b/tests/codeception/acceptance/StylesCest.php new file mode 100644 index 0000000..a4673e4 --- /dev/null +++ b/tests/codeception/acceptance/StylesCest.php @@ -0,0 +1,52 @@ +logInWithRole('administrator'); + } + + /** + * Image styles should have been created. + */ + public function testImageStyles(AcceptanceTester $I) { + $I->amOnPage('/admin/config/media/image-styles'); + + $I->canSee('Circle'); + $I->canSee('Breakpoint - LG - 1x'); + $I->canSee('Breakpoint - LG - 2x'); + $I->canSee('Breakpoint - MD - 1x'); + $I->canSee('Breakpoint - MD - 2x'); + $I->canSee('Breakpoint - SM - 1x'); + $I->canSee('Breakpoint - SM - 2x'); + $I->canSee('Breakpoint - XL - 1x'); + $I->canSee('Breakpoint - XL - 2x'); + $I->canSee('Breakpoint - 2XL - 1x'); + $I->canSee('Breakpoint - 2XL - 2x'); + $I->canSee('Card - 1X - 478x318'); + $I->canSee('Card - 2X - 956x636'); + $I->canSee('CTA - 1X - 507x338'); + $I->canSee('CTA - 1X - 596x397'); + $I->canSee('CTA - 2X - 1014x676'); + $I->canSee('CTA - 2X - 1192x794'); + } + + /** + * Responsive Image styles should have been created. + */ + public function testResponsiveStyles(AcceptanceTester $I) { + $I->amOnPage('/admin/config/media/responsive-image-style'); + $I->canSee('Card - 478x318'); + $I->canSee('CTA - 596x397'); + $I->canSee('Stanford Hero Block - Wide'); + } + +} From 6af9759fc89a1e74bb820a41a6ba76da51b2cd85 Mon Sep 17 00:00:00 2001 From: Ian Monroe Date: Mon, 27 Jul 2020 15:05:46 -0600 Subject: [PATCH 3/7] D8CORE-2155: Added square image styles for various breakpoints (#57) * D8CORE-2155: Added square image styles for various breakpoints, added responsive 1:1 image style, fixed ymls for installation. --- .github/pull_request_template.md | 29 ++++++++++ .../install/image.style.breakpoint_2xl_1x.yml | 1 + .../install/image.style.breakpoint_2xl_2x.yml | 1 + .../install/image.style.breakpoint_lg_1x.yml | 3 +- .../install/image.style.breakpoint_lg_2x.yml | 3 +- .../install/image.style.breakpoint_md_1x.yml | 3 +- .../install/image.style.breakpoint_md_2x.yml | 3 +- .../install/image.style.breakpoint_sm_1x.yml | 3 +- .../install/image.style.breakpoint_sm_2x.yml | 3 +- .../install/image.style.breakpoint_xl_1x.yml | 3 +- .../install/image.style.breakpoint_xl_2x.yml | 3 +- .../install/image.style.card_1x_478x318.yml | 1 + .../install/image.style.card_2x_956x636.yml | 1 + config/install/image.style.cta_1x_507x338.yml | 1 + config/install/image.style.cta_1x_596x397.yml | 1 + .../install/image.style.cta_2x_1014x676.yml | 1 + .../install/image.style.cta_2x_1192x794.yml | 1 + config/install/image.style.square_1192.yml | 17 ++++++ config/install/image.style.square_1900.yml | 17 ++++++ config/install/image.style.square_478.yml | 17 ++++++ config/install/image.style.square_956.yml | 17 ++++++ .../install/image.style.stanford_circle.yml | 1 + .../responsive_image.styles.card_478x318.yml | 1 + .../responsive_image.styles.cta_596x397.yml | 1 + ...responsive_image.styles.responsive_1_1.yml | 56 +++++++++++++++++++ ..._image.styles.stanford_hero_block_wide.yml | 3 +- tests/codeception/acceptance/StylesCest.php | 5 ++ 27 files changed, 178 insertions(+), 18 deletions(-) create mode 100644 .github/pull_request_template.md create mode 100644 config/install/image.style.square_1192.yml create mode 100644 config/install/image.style.square_1900.yml create mode 100644 config/install/image.style.square_478.yml create mode 100644 config/install/image.style.square_956.yml create mode 100644 config/install/responsive_image.styles.responsive_1_1.yml diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..c170efa --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,29 @@ +# READY FOR REVIEW/NOT READY +- (Edit the above to reflect status) + +# Summary +- TL;DR - what's this PR for? + +# Needed By (Date) +- When does this need to be merged by? + +# Urgency +- How critical is this PR? + +# Steps to Test + +1. Do this +1. Then this +2. Then this + +# Affected Projects or Products +- Does this PR impact any particular projects, products, or modules? + +# Associated Issues and/or People +- JIRA ticket +- Other PRs +- Any other contextual information that might be helpful (e.g., description of a bug that this PR fixes, new functionality that it adds, etc.) +- Anyone who should be notified? (`@mention` them here) + +# See Also +- [PR Checklist](https://gist.github.com/sherakama/0ba17601381e3adbe0cad566ad4d80a5) diff --git a/config/install/image.style.breakpoint_2xl_1x.yml b/config/install/image.style.breakpoint_2xl_1x.yml index 2f92448..a6afb1c 100644 --- a/config/install/image.style.breakpoint_2xl_1x.yml +++ b/config/install/image.style.breakpoint_2xl_1x.yml @@ -12,3 +12,4 @@ effects: width: 1500 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_2xl_2x.yml b/config/install/image.style.breakpoint_2xl_2x.yml index ebceb3c..fc2b474 100644 --- a/config/install/image.style.breakpoint_2xl_2x.yml +++ b/config/install/image.style.breakpoint_2xl_2x.yml @@ -12,3 +12,4 @@ effects: width: 3000 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_lg_1x.yml b/config/install/image.style.breakpoint_lg_1x.yml index 7e764d0..38f7a17 100644 --- a/config/install/image.style.breakpoint_lg_1x.yml +++ b/config/install/image.style.breakpoint_lg_1x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: 3aTh0wxysVWRLQvsLSWuf9mYdAql9Ek2O4okVXG5cMs name: breakpoint_lg_1x label: 'Breakpoint - LG - 1x' effects: @@ -14,3 +12,4 @@ effects: width: 992 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_lg_2x.yml b/config/install/image.style.breakpoint_lg_2x.yml index cb04db5..c91e7b7 100644 --- a/config/install/image.style.breakpoint_lg_2x.yml +++ b/config/install/image.style.breakpoint_lg_2x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: cZXot4swbaAIIWXQw7ZhgPwlabmSTQOCZO8AIM5isGE name: breakpoint_lg_2x label: 'Breakpoint - LG - 2x' effects: @@ -14,3 +12,4 @@ effects: width: 1984 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_md_1x.yml b/config/install/image.style.breakpoint_md_1x.yml index 74bddce..3ac9667 100644 --- a/config/install/image.style.breakpoint_md_1x.yml +++ b/config/install/image.style.breakpoint_md_1x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: ofY6kXeN4lN9PG-eTaA78tAzx3ACWtTmlK-APH7PAZg name: breakpoint_md_1x label: 'Breakpoint - MD - 1x' effects: @@ -14,3 +12,4 @@ effects: width: 768 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_md_2x.yml b/config/install/image.style.breakpoint_md_2x.yml index d8c650e..1541d4d 100644 --- a/config/install/image.style.breakpoint_md_2x.yml +++ b/config/install/image.style.breakpoint_md_2x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: TJO8X5EvB-f6_JLymfBhl0dJ2bP0rbm94sJLiSDGkGk name: breakpoint_md_2x label: 'Breakpoint - MD - 2x' effects: @@ -14,3 +12,4 @@ effects: width: 1536 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_sm_1x.yml b/config/install/image.style.breakpoint_sm_1x.yml index 5c2b9c0..38f3e0c 100644 --- a/config/install/image.style.breakpoint_sm_1x.yml +++ b/config/install/image.style.breakpoint_sm_1x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: G0Vkgl6yKu6iHRjh_xyTEUsbM_lAgQ362aTGF_edkg0 name: breakpoint_sm_1x label: 'Breakpoint - SM - 1x' effects: @@ -14,3 +12,4 @@ effects: width: 576 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_sm_2x.yml b/config/install/image.style.breakpoint_sm_2x.yml index 024cd86..44ab245 100644 --- a/config/install/image.style.breakpoint_sm_2x.yml +++ b/config/install/image.style.breakpoint_sm_2x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: jR527GaKk-Mxem_ZnKUgnnXSaqpURbAxzC9WajqFb40 name: breakpoint_sm_2x label: 'Breakpoint - SM - 2x' effects: @@ -14,3 +12,4 @@ effects: width: 1152 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_xl_1x.yml b/config/install/image.style.breakpoint_xl_1x.yml index 4f12d8a..87a079a 100644 --- a/config/install/image.style.breakpoint_xl_1x.yml +++ b/config/install/image.style.breakpoint_xl_1x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: Uy8HsoXATXaSNELbQv6oHjVXQ7CngyBOwJHzGkmOonY name: breakpoint_xl_1x label: 'Breakpoint - XL - 1x' effects: @@ -14,3 +12,4 @@ effects: width: 1200 height: null upscale: false + diff --git a/config/install/image.style.breakpoint_xl_2x.yml b/config/install/image.style.breakpoint_xl_2x.yml index 696f9a1..79a5c6c 100644 --- a/config/install/image.style.breakpoint_xl_2x.yml +++ b/config/install/image.style.breakpoint_xl_2x.yml @@ -1,8 +1,6 @@ langcode: en status: true dependencies: { } -_core: - default_config_hash: Vh36ZWh1RSikZ0pbEJjgQa4UPqirYo__IZ1NsmQwTPA name: breakpoint_xl_2x label: 'Breakpoint - XL - 2x' effects: @@ -14,3 +12,4 @@ effects: width: 2400 height: null upscale: false + diff --git a/config/install/image.style.card_1x_478x318.yml b/config/install/image.style.card_1x_478x318.yml index 713f4f2..1cf1385 100644 --- a/config/install/image.style.card_1x_478x318.yml +++ b/config/install/image.style.card_1x_478x318.yml @@ -14,3 +14,4 @@ effects: width: 478 height: 318 crop_type: focal_point + diff --git a/config/install/image.style.card_2x_956x636.yml b/config/install/image.style.card_2x_956x636.yml index 67cea60..98b5836 100644 --- a/config/install/image.style.card_2x_956x636.yml +++ b/config/install/image.style.card_2x_956x636.yml @@ -14,3 +14,4 @@ effects: width: 956 height: 366 crop_type: focal_point + diff --git a/config/install/image.style.cta_1x_507x338.yml b/config/install/image.style.cta_1x_507x338.yml index dabf473..f7681ec 100644 --- a/config/install/image.style.cta_1x_507x338.yml +++ b/config/install/image.style.cta_1x_507x338.yml @@ -14,3 +14,4 @@ effects: width: 507 height: 338 crop_type: focal_point + diff --git a/config/install/image.style.cta_1x_596x397.yml b/config/install/image.style.cta_1x_596x397.yml index 79288b4..d3ba18e 100644 --- a/config/install/image.style.cta_1x_596x397.yml +++ b/config/install/image.style.cta_1x_596x397.yml @@ -14,3 +14,4 @@ effects: width: 596 height: 397 crop_type: focal_point + diff --git a/config/install/image.style.cta_2x_1014x676.yml b/config/install/image.style.cta_2x_1014x676.yml index 3e20dc6..6c2f46d 100644 --- a/config/install/image.style.cta_2x_1014x676.yml +++ b/config/install/image.style.cta_2x_1014x676.yml @@ -14,3 +14,4 @@ effects: width: 1014 height: 676 crop_type: focal_point + diff --git a/config/install/image.style.cta_2x_1192x794.yml b/config/install/image.style.cta_2x_1192x794.yml index a9532d3..4634d6c 100644 --- a/config/install/image.style.cta_2x_1192x794.yml +++ b/config/install/image.style.cta_2x_1192x794.yml @@ -14,3 +14,4 @@ effects: width: 1192 height: 794 crop_type: focal_point + diff --git a/config/install/image.style.square_1192.yml b/config/install/image.style.square_1192.yml new file mode 100644 index 0000000..cad4fc5 --- /dev/null +++ b/config/install/image.style.square_1192.yml @@ -0,0 +1,17 @@ +langcode: en +status: true +dependencies: + module: + - focal_point +name: square_1192 +label: 'Square - 1192' +effects: + e1b9c81d-c281-4e9d-b145-28144e978ac0: + uuid: e1b9c81d-c281-4e9d-b145-28144e978ac0 + id: focal_point_scale_and_crop + weight: 1 + data: + width: 1192 + height: 1192 + crop_type: focal_point + diff --git a/config/install/image.style.square_1900.yml b/config/install/image.style.square_1900.yml new file mode 100644 index 0000000..08d56ed --- /dev/null +++ b/config/install/image.style.square_1900.yml @@ -0,0 +1,17 @@ +langcode: en +status: true +dependencies: + module: + - focal_point +name: square_1900 +label: 'Square - 1900' +effects: + 578f3e25-6a90-4db7-a90c-91ce8bf4d99e: + uuid: 578f3e25-6a90-4db7-a90c-91ce8bf4d99e + id: focal_point_scale_and_crop + weight: 1 + data: + width: 1900 + height: 1900 + crop_type: focal_point + diff --git a/config/install/image.style.square_478.yml b/config/install/image.style.square_478.yml new file mode 100644 index 0000000..b69bb13 --- /dev/null +++ b/config/install/image.style.square_478.yml @@ -0,0 +1,17 @@ +langcode: en +status: true +dependencies: + module: + - focal_point +name: square_478 +label: 'Square - 478' +effects: + 1891a880-3259-4e36-a1e8-9d9f9de467d0: + uuid: 1891a880-3259-4e36-a1e8-9d9f9de467d0 + id: focal_point_scale_and_crop + weight: 1 + data: + width: 478 + height: 478 + crop_type: focal_point + diff --git a/config/install/image.style.square_956.yml b/config/install/image.style.square_956.yml new file mode 100644 index 0000000..2354ddc --- /dev/null +++ b/config/install/image.style.square_956.yml @@ -0,0 +1,17 @@ +langcode: en +status: true +dependencies: + module: + - focal_point +name: square_956 +label: 'Square - 956' +effects: + d383578e-88ff-41aa-830d-526c90d3df98: + uuid: d383578e-88ff-41aa-830d-526c90d3df98 + id: focal_point_scale_and_crop + weight: 1 + data: + width: 956 + height: 956 + crop_type: focal_point + diff --git a/config/install/image.style.stanford_circle.yml b/config/install/image.style.stanford_circle.yml index 3d3d375..4ac0461 100644 --- a/config/install/image.style.stanford_circle.yml +++ b/config/install/image.style.stanford_circle.yml @@ -32,3 +32,4 @@ effects: weight: -9 data: extension: png + diff --git a/config/install/responsive_image.styles.card_478x318.yml b/config/install/responsive_image.styles.card_478x318.yml index 545d0d3..f095e02 100644 --- a/config/install/responsive_image.styles.card_478x318.yml +++ b/config/install/responsive_image.styles.card_478x318.yml @@ -71,3 +71,4 @@ image_style_mappings: image_mapping: card_2x_956x636 breakpoint_group: stanford_image_styles fallback_image_style: card_2x_956x636 + diff --git a/config/install/responsive_image.styles.cta_596x397.yml b/config/install/responsive_image.styles.cta_596x397.yml index d3c9140..7e07deb 100644 --- a/config/install/responsive_image.styles.cta_596x397.yml +++ b/config/install/responsive_image.styles.cta_596x397.yml @@ -73,3 +73,4 @@ image_style_mappings: image_mapping: cta_2x_1014x676 breakpoint_group: stanford_image_styles fallback_image_style: cta_2x_1014x676 + diff --git a/config/install/responsive_image.styles.responsive_1_1.yml b/config/install/responsive_image.styles.responsive_1_1.yml new file mode 100644 index 0000000..a874c28 --- /dev/null +++ b/config/install/responsive_image.styles.responsive_1_1.yml @@ -0,0 +1,56 @@ +langcode: en +status: true +dependencies: + config: + - image.style.square_1192 + - image.style.square_1900 + - image.style.square_478 + - image.style.square_956 + module: + - stanford_image_styles +id: responsive_1_1 +label: 'Responsive 1:1' +image_style_mappings: + - + breakpoint_id: stanford_image_styles.lg + multiplier: 1x + image_mapping_type: image_style + image_mapping: square_1192 + - + breakpoint_id: stanford_image_styles.lg + multiplier: 2x + image_mapping_type: image_style + image_mapping: square_1900 + - + breakpoint_id: stanford_image_styles.md + multiplier: 1x + image_mapping_type: image_style + image_mapping: square_956 + - + breakpoint_id: stanford_image_styles.md + multiplier: 2x + image_mapping_type: image_style + image_mapping: square_1900 + - + breakpoint_id: stanford_image_styles.sm + multiplier: 1x + image_mapping_type: image_style + image_mapping: square_956 + - + breakpoint_id: stanford_image_styles.sm + multiplier: 2x + image_mapping_type: image_style + image_mapping: square_1192 + - + breakpoint_id: stanford_image_styles.xs + multiplier: 1x + image_mapping_type: image_style + image_mapping: square_478 + - + breakpoint_id: stanford_image_styles.xs + multiplier: 2x + image_mapping_type: image_style + image_mapping: square_956 +breakpoint_group: stanford_image_styles +fallback_image_style: square_1900 + diff --git a/config/install/responsive_image.styles.stanford_hero_block_wide.yml b/config/install/responsive_image.styles.stanford_hero_block_wide.yml index 2cbcdb0..f284cd6 100644 --- a/config/install/responsive_image.styles.stanford_hero_block_wide.yml +++ b/config/install/responsive_image.styles.stanford_hero_block_wide.yml @@ -14,8 +14,6 @@ dependencies: - image.style.breakpoint_xl_2x module: - stanford_image_styles -_core: - default_config_hash: B0tXkjUZrA5gFY6X39MInsKCbjqw1oZHH9cYDwyQkhI id: stanford_hero_block_wide label: 'Stanford Hero Block - Wide' image_style_mappings: @@ -81,3 +79,4 @@ image_style_mappings: image_mapping: breakpoint_sm_2x breakpoint_group: stanford_image_styles fallback_image_style: breakpoint_2xl_2x + diff --git a/tests/codeception/acceptance/StylesCest.php b/tests/codeception/acceptance/StylesCest.php index a4673e4..6d2dbc9 100644 --- a/tests/codeception/acceptance/StylesCest.php +++ b/tests/codeception/acceptance/StylesCest.php @@ -37,6 +37,10 @@ public function testImageStyles(AcceptanceTester $I) { $I->canSee('CTA - 1X - 596x397'); $I->canSee('CTA - 2X - 1014x676'); $I->canSee('CTA - 2X - 1192x794'); + $I->canSee('Square - 478'); + $I->canSee('Square - 956'); + $I->canSee('Square - 1192'); + $I->canSee('Square - 1900'); } /** @@ -47,6 +51,7 @@ public function testResponsiveStyles(AcceptanceTester $I) { $I->canSee('Card - 478x318'); $I->canSee('CTA - 596x397'); $I->canSee('Stanford Hero Block - Wide'); + $I->canSee('Responsive 1:1'); } } From 3c06789536f528c567f3bc85821c2d86d2dab100 Mon Sep 17 00:00:00 2001 From: pookmish Date: Fri, 21 Aug 2020 13:26:48 -0600 Subject: [PATCH 4/7] D8CORE-2499 Updated composer license (#58) --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 77d0441..42487b9 100755 --- a/composer.json +++ b/composer.json @@ -4,7 +4,7 @@ "type": "drupal-custom-module", "homepage": "https://github.com/SU-SWS/stanford_image_styles", "authors": [], - "license": "GPL-2.0+", + "license": "GPL-2.0-or-later", "minimum-stability": "dev", "repositories": [ { From dee3a2ca57328299b3d742cc9b9642cf3a552b62 Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Fri, 13 Nov 2020 10:59:58 -0800 Subject: [PATCH 5/7] phpunit void return annoation --- .../tests/src/Kernel/Form/PreviewFormTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/stanford_image_styles_preview/tests/src/Kernel/Form/PreviewFormTest.php b/modules/stanford_image_styles_preview/tests/src/Kernel/Form/PreviewFormTest.php index c81d0e2..ffa3873 100644 --- a/modules/stanford_image_styles_preview/tests/src/Kernel/Form/PreviewFormTest.php +++ b/modules/stanford_image_styles_preview/tests/src/Kernel/Form/PreviewFormTest.php @@ -50,7 +50,7 @@ class PreviewFormTest extends KernelTestBase { /** * {@inheritDoc} */ - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->installEntitySchema('file'); $this->installEntitySchema('user'); From 121a3b55fb5e143bea97b3569bc052a43dc51adb Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Mon, 16 Nov 2020 11:33:36 -0800 Subject: [PATCH 6/7] Updated submodule for d9 installation --- .../stanford_image_styles_preview.info.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml index 71a1664..60c8331 100644 --- a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml +++ b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml @@ -2,6 +2,7 @@ name: Stanford Image Styles Preview type: module description: Provides an admin page to view a preview of all image styles after effects are applied. core: 8.x +core_version_requirement: ^8 || ^9 package: Stanford version: 8.x-1.2-dev dependencies: From 5e63f77478d9e9ad3bfd1ab8a2d24e2bc5a248d3 Mon Sep 17 00:00:00 2001 From: Ian Monroe Date: Fri, 9 Apr 2021 12:11:11 -0600 Subject: [PATCH 7/7] 8.1.2 --- CHANGELOG.md | 10 ++++++++++ .../stanford_image_styles_preview.info.yml | 2 +- stanford_image_styles.info.yml | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 673a975..80361c5 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,15 @@ # Stanford Image Styles +8.x-1.2 +-------------------------------------------------------------------------------- +_Release Date: 2021-04-09_ + +- Updated submodule for d9 installation (121a3b5) +- phpunit void return annoation (dee3a2c) +- D8CORE-2499 Updated composer license (#58) (3c06789) +- D8CORE-2155: Added square image styles for various breakpoints (#57) (6af9759) +- D8CORE-1538 Convert behat tests to codeception (#56) (395f426) + 8.x-1.1 -------------------------------------------------------------------------------- _Release Date: 2020-06-17_ diff --git a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml index 60c8331..e064502 100644 --- a/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml +++ b/modules/stanford_image_styles_preview/stanford_image_styles_preview.info.yml @@ -4,6 +4,6 @@ description: Provides an admin page to view a preview of all image styles after core: 8.x core_version_requirement: ^8 || ^9 package: Stanford -version: 8.x-1.2-dev +version: 8.x-1.2 dependencies: - stanford_image_styles:stanford_image_styles diff --git a/stanford_image_styles.info.yml b/stanford_image_styles.info.yml index 76dc831..5f3625b 100755 --- a/stanford_image_styles.info.yml +++ b/stanford_image_styles.info.yml @@ -3,7 +3,7 @@ type: module description: 'Provides Image Styles' core_version_requirement: ^8 || ^9 package: Stanford -version: 8.x-1.2-dev +version: 8.x-1.2 dependencies: - drupal:image - drupal:responsive_image