From 1d3c9ecd1108f449a8716332231f57c8f52fa9e0 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Thu, 6 Dec 2018 11:45:59 +0100 Subject: [PATCH 01/19] updated Docker configuration --- docker/conf/docker-compose-mac.yml.dist | 56 +++++++--------------- docker/conf/docker-compose-win.yml.dist | 63 +++++++++---------------- docker/conf/docker-compose.yml.dist | 43 +++-------------- docker/conf/docker-sync.yml.dist | 21 +++++++-- docker/php-fpm/Dockerfile | 58 +++++++++++++++++++---- docker/php-fpm/docker-php-entrypoint | 8 ++-- 6 files changed, 116 insertions(+), 133 deletions(-) diff --git a/docker/conf/docker-compose-mac.yml.dist b/docker/conf/docker-compose-mac.yml.dist index d2625d9c6..070964994 100644 --- a/docker/conf/docker-compose-mac.yml.dist +++ b/docker/conf/docker-compose-mac.yml.dist @@ -1,11 +1,13 @@ -version: "3.1" +version: "3.4" services: postgres: - image: postgres:9.5-alpine + image: postgres:10.5-alpine container_name: shopsys-framework-postgres volumes: - - shopsys-framework-postgres-data-sync:/var/lib/postgresql/data + - ./docker/postgres/postgres.conf:/var/lib/postgresql/data/postgresql.conf:delegated + - ./var/postgres-data:/var/lib/postgresql/data:cached environment: + - PGDATA=/var/lib/postgresql/data/pgdata - POSTGRES_USER=root - POSTGRES_PASSWORD=root - POSTGRES_DB=shopsys @@ -14,31 +16,26 @@ services: image: nginx:1.13-alpine container_name: shopsys-framework-webserver volumes: - - shopsys-framework-sync:/var/www/html - - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf + - shopsys-framework-web-sync:/var/www/html/web + - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf:delegated ports: - "8000:8080" - links: - - php-fpm - - smtp-server php-fpm: build: - context: docker/php-fpm + context: . + dockerfile: docker/php-fpm/Dockerfile + target: development args: www_data_uid: 501 www_data_gid: 20 container_name: shopsys-framework-php-fpm volumes: - shopsys-framework-sync:/var/www/html - links: - - postgres - - redis + - shopsys-framework-vendor-sync:/var/www/html/vendor + - shopsys-framework-web-sync:/var/www/html/web ports: - "35729:35729" - depends_on: - - postgres - - redis redis: image: redis:4.0-alpine @@ -49,10 +46,6 @@ services: container_name: shopsys-framework-redis-admin environment: - REDIS_1_HOST=redis - links: - - redis - depends_on: - - redis ports: - "1600:80" @@ -64,18 +57,12 @@ services: environment: - HUB_PORT_4444_TCP_ADDR=hub - HUB_PORT_4444_TCP_PORT=4444 - links: - - webserver adminer: image: adminer:4.6 container_name: shopsys-framework-adminer ports: - "1100:8080" - links: - - postgres - depends_on: - - postgres smtp-server: image: namshi/smtp:latest @@ -88,36 +75,27 @@ services: nofile: soft: 65536 hard: 65536 - restart: on-failure ports: - "9200:9200" volumes: - - shopsys-framework-elasticsearch-data-sync:/usr/share/elasticsearch/data + - ./var/elasticsearch-data:/usr/share/elasticsearch/data:cached environment: - discovery.type=single-node microservice-product-search: - image: shopsys/microservice-product-search:v7.0.0-beta2 + image: shopsys/microservice-product-search:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search - links: - - elasticsearch - depends_on: - - elasticsearch microservice-product-search-export: - image: shopsys/microservice-product-search-export:v7.0.0-beta2 + image: shopsys/microservice-product-search-export:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search-export - links: - - elasticsearch - depends_on: - - elasticsearch volumes: shopsys-framework-sync: external: true - shopsys-framework-postgres-data-sync: + shopsys-framework-vendor-sync: external: true - shopsys-framework-elasticsearch-data-sync: + shopsys-framework-web-sync: external: true diff --git a/docker/conf/docker-compose-win.yml.dist b/docker/conf/docker-compose-win.yml.dist index 01e05dd82..992f4ee3e 100644 --- a/docker/conf/docker-compose-win.yml.dist +++ b/docker/conf/docker-compose-win.yml.dist @@ -1,12 +1,13 @@ -version: "3.1" +version: "3.4" services: postgres: - image: postgres:9.5-alpine + image: postgres:10.5-alpine container_name: shopsys-framework-postgres volumes: - pgdata:/var/lib/postgresql/data + - ./docker/postgres/postgres.conf:/var/lib/postgresql/data/postgresql.conf environment: - - PGDATA=/var/lib/postgresql/data + - PGDATA=/var/lib/postgresql/data/pgdata - POSTGRES_USER=root - POSTGRES_PASSWORD=root - POSTGRES_DB=shopsys @@ -15,31 +16,27 @@ services: image: nginx:1.13-alpine container_name: shopsys-framework-webserver volumes: - - .:/var/www/html + - shopsys-framework-web-sync:/var/www/html/web - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf ports: - "8000:8080" - links: - - php-fpm - - smtp-server php-fpm: build: - context: docker/php-fpm + context: . + dockerfile: docker/php-fpm/Dockerfile + target: development args: - www_data_uid: 82 - www_data_gid: 82 + www_data_uid: 1000 + www_data_gid: 1000 container_name: shopsys-framework-php-fpm volumes: - - .:/var/www/html - links: - - postgres - - redis + - shopsys-framework-sync:/var/www/html + - shopsys-framework-vendor-sync:/var/www/html/vendor + - shopsys-framework-web-sync:/var/www/html/web + - ./docker/php-fpm/php-ini-overrides.ini:/usr/local/etc/php/php.ini ports: - "35729:35729" - depends_on: - - postgres - - redis redis: image: redis:4.0-alpine @@ -50,10 +47,6 @@ services: container_name: shopsys-framework-redis-admin environment: - REDIS_1_HOST=redis - links: - - redis - depends_on: - - redis ports: - "1600:80" @@ -65,18 +58,12 @@ services: environment: - HUB_PORT_4444_TCP_ADDR=hub - HUB_PORT_4444_TCP_PORT=4444 - links: - - webserver adminer: image: adminer:4.6 container_name: shopsys-framework-adminer ports: - "1100:8080" - links: - - postgres - depends_on: - - postgres smtp-server: image: namshi/smtp:latest @@ -89,7 +76,6 @@ services: nofile: soft: 65536 hard: 65536 - restart: on-failure ports: - "9200:9200" volumes: @@ -97,25 +83,22 @@ services: environment: - discovery.type=single-node - microservice-product-search: - image: shopsys/microservice-product-search:v7.0.0-beta2 + image: shopsys/microservice-product-search:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search - links: - - elasticsearch - depends_on: - - elasticsearch microservice-product-search-export: - image: shopsys/microservice-product-search-export:v7.0.0-beta2 + image: shopsys/microservice-product-search-export:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search-export - links: - - elasticsearch - depends_on: - - elasticsearch volumes: pgdata: driver: local elasticsearch-data: - driver: local + driver: local + shopsys-framework-sync: + external: true + shopsys-framework-vendor-sync: + external: true + shopsys-framework-web-sync: + external: true diff --git a/docker/conf/docker-compose.yml.dist b/docker/conf/docker-compose.yml.dist index 2f3a52ca2..dab65f074 100644 --- a/docker/conf/docker-compose.yml.dist +++ b/docker/conf/docker-compose.yml.dist @@ -1,4 +1,4 @@ -version: "3.1" +version: "3.4" services: postgres: image: postgres:10.5-alpine @@ -20,30 +20,20 @@ services: - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf ports: - "8000:8080" - links: - - php-fpm - - smtp-server php-fpm: build: - context: docker/php-fpm - args: &common_build_args + context: . + dockerfile: docker/php-fpm/Dockerfile + target: development + args: www_data_uid: 1000 www_data_gid: 1000 - github_oauth_token: place-your-token-here container_name: shopsys-framework-php-fpm volumes: - .:/var/www/html - links: - - postgres - - redis - - microservice-product-search - - microservice-product-search-export ports: - "35729:35729" - depends_on: - - postgres - - redis redis: image: redis:4.0-alpine @@ -54,10 +44,6 @@ services: container_name: shopsys-framework-redis-admin environment: - REDIS_1_HOST=redis - links: - - redis - depends_on: - - redis ports: - "1600:80" @@ -69,18 +55,12 @@ services: environment: - HUB_PORT_4444_TCP_ADDR=hub - HUB_PORT_4444_TCP_PORT=4444 - links: - - webserver adminer: image: adminer:4.6 container_name: shopsys-framework-adminer ports: - "1100:8080" - links: - - postgres - depends_on: - - postgres smtp-server: image: namshi/smtp:latest @@ -93,7 +73,6 @@ services: nofile: soft: 65536 hard: 65536 - restart: on-failure ports: - "9200:9200" volumes: @@ -102,20 +81,12 @@ services: - discovery.type=single-node microservice-product-search: - image: shopsys/microservice-product-search:v7.0.0-beta2 + image: shopsys/microservice-product-search:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search - links: - - elasticsearch - depends_on: - - elasticsearch microservice-product-search-export: - image: shopsys/microservice-product-search-export:v7.0.0-beta2 + image: shopsys/microservice-product-search-export:v7.0.0-beta4 container_name: shopsys-framework-microservice-product-search-export - links: - - elasticsearch - depends_on: - - elasticsearch volumes: elasticsearch-data: diff --git a/docker/conf/docker-sync.yml.dist b/docker/conf/docker-sync.yml.dist index a0329c729..e6a0239f2 100644 --- a/docker/conf/docker-sync.yml.dist +++ b/docker/conf/docker-sync.yml.dist @@ -3,7 +3,20 @@ syncs: shopsys-framework-sync: sync_userid: 501 src: './' - sync_excludes: ['docker/'] - - shopsys-framework-postgres-data-sync: - src: './var/postgres-data/' \ No newline at end of file + sync_excludes: [ + 'docker/', + '.git', + '.idea', + '.docker-sync', + '.DS_Store', + 'docker', + 'docs', + 'kubernetes', + 'nbproject', + 'node_modules', + 'var/cache', + 'var/postgres-data', + 'var/elasticsearch-data', + 'web', + 'vendor' + ] diff --git a/docker/php-fpm/Dockerfile b/docker/php-fpm/Dockerfile index 4eababa9d..025663c0a 100644 --- a/docker/php-fpm/Dockerfile +++ b/docker/php-fpm/Dockerfile @@ -1,10 +1,12 @@ -FROM php:7.2-fpm-alpine +FROM php:7.2-fpm-alpine as base + +ARG project_root=. # install git for computing diffs RUN apk add --update git # install Composer -COPY docker-install-composer /usr/local/bin/docker-install-composer +COPY ${project_root}/docker/php-fpm/docker-install-composer /usr/local/bin/docker-install-composer RUN chmod +x /usr/local/bin/docker-install-composer && docker-install-composer # libpng-dev needed by "gd" extension @@ -58,21 +60,57 @@ ENV LD_PRELOAD /usr/lib/preloadable_libiconv.so php ENV LC_ALL=en_US.utf8 LANG=en_US.utf8 LANGUAGE=en_US.utf8 # overwrite the original entry-point from the PHP Docker image with our own -COPY docker-php-entrypoint /usr/local/bin/ +COPY ${project_root}/docker/php-fpm/docker-php-entrypoint /usr/local/bin/ +RUN chmod +x /usr/local/bin/docker-php-entrypoint # copy php.ini configuration -COPY php-ini-overrides.ini /usr/local/etc/php/php.ini +COPY ${project_root}/docker/php-fpm/php-ini-overrides.ini /usr/local/etc/php/php.ini + +# the user "www-data" is used when running the image, and therefore should own the workdir +RUN chown www-data:www-data /var/www/html +USER www-data + +# hirak/prestissimo makes the install of Composer dependencies faster by parallel downloading +RUN composer global require hirak/prestissimo + +# set COMPOSER_MEMORY_LIMIT to -1 (i.e. unlimited - this is a hotfix until https://github.com/shopsys/shopsys/issues/634 is solved) +ENV COMPOSER_MEMORY_LIMIT=-1 + +######################################################################################################################## + +FROM base as development + +USER root # allow overwriting UID and GID o the user "www-data" to help solve issues with permissions in mounted volumes # if the GID is already in use, we will assign GID 82 instead (82 is the standard uid/gid for "www-data" in Alpine) ARG www_data_uid ARG www_data_gid -RUN deluser www-data && (addgroup -g $www_data_gid www-data || addgroup -g 82 www-data) && adduser -u $www_data_uid -D -S -G www-data www-data +RUN if [ -n "$www_data_uid" ]; then deluser www-data && (addgroup -g $www_data_gid www-data || addgroup -g 82 www-data) && adduser -u $www_data_uid -D -S -G www-data www-data; fi; + +# as the UID and GID might have changed, change the ownership of the home directory workdir again +RUN chown -R www-data:www-data /home/www-data /var/www/html + USER www-data -# allow configuring the GitHub OAuth token -ARG github_oauth_token -RUN if [ -n "$github_oauth_token" ]; then composer config -g github-oauth.github.com $github_oauth_token; fi +######################################################################################################################## -# hirak/prestissimo makes the install of Composer dependencies faster by parallel downloading -RUN composer global require hirak/prestissimo +FROM base as production + +COPY --chown=www-data:www-data / /var/www/html + +RUN composer install --optimize-autoloader --no-interaction --no-progress --no-dev + +RUN php phing composer npm dirs-create assets + +######################################################################################################################## + +FROM base as ci + +COPY --chown=www-data:www-data / /var/www/html + +RUN composer install --optimize-autoloader --no-interaction --no-progress + +RUN php phing composer-dev npm dirs-create test-dirs-create assets standards tests-static tests-acceptance-build + +RUN ./bin/console shopsys:environment:change prod diff --git a/docker/php-fpm/docker-php-entrypoint b/docker/php-fpm/docker-php-entrypoint index 1b8371ff5..44a1aebcb 100755 --- a/docker/php-fpm/docker-php-entrypoint +++ b/docker/php-fpm/docker-php-entrypoint @@ -6,11 +6,11 @@ set -e # reading from a named pipe and writing to stdout via "tail -f" # this workaround prevents logs from being output to console during console commands +# multistage build uses different UIDs and logpipe is transformed into something else than pipe so best way is to recreate it PIPE=/tmp/log-pipe -if ! [ -p $PIPE ]; then - mkfifo $PIPE - chmod 660 $PIPE -fi +rm -rf $PIPE +mkfifo $PIPE +chmod 666 $PIPE tail -f $PIPE & # first arg is `-f` or `--some-option` From b0c404e73ea3f4210cfb71faeb94720fe71d72b7 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Thu, 6 Dec 2018 11:48:39 +0100 Subject: [PATCH 02/19] renamed Database tests to Functional tests - Class DatabaseTestCase was renamed to TransactionFunctionalTestCase (see shopsys/shopsys#541) --- build-dev.xml | 8 +-- easy-coding-standard.yml | 14 ++-- phpunit.xml | 4 +- .../Resources/config/services_test.yml | 4 +- .../Compiler/Constant/Testclass.php | 10 --- .../Constant/testClassName.expected.js | 2 - .../Compiler/Constant/testClassName.js | 2 - .../Compiler/Constant/testDefinedConstant.js | 2 - .../Constant/testUndefinedConstant.js | 1 - .../Doctrine/GroupedScalarHydratorTest.php | 6 +- .../Doctrine/SortableNullsWalkerTest.php | 2 +- .../Domain/Config/DomainsConfigLoaderTest.php | 2 +- .../Component/Domain/Config/test_domains.yml | 0 .../Domain/Config/test_domains_urls.yml | 0 .../MultidomainEntityDataCreatorTest.php | 6 +- .../Component/FlashMessage/BagTest.php | 2 +- .../Grid/QueryBuilderDataSourceTest.php | 6 +- ...uilderWithRowManipulatorDataSourceTest.php | 6 +- .../HttpFoundation/FragmentHandlerTest.php | 6 +- .../Constant/JsConstantCompilerPassTest.php | 2 +- .../Compiler/Constant/Testclass.php | 10 +++ .../Constant/testClassName.expected.js | 2 + .../Compiler/Constant/testClassName.js | 2 + .../Constant/testDefinedConstant.expected.js | 0 .../Compiler/Constant/testDefinedConstant.js | 2 + .../Constant/testUndefinedConstant.js | 1 + .../JsTranslatorCompilerPassTest.php | 2 +- .../Controller/HomepageControllerTest.php | 2 +- .../EntityExtension/EntityExtensionTest.php | 52 +++++++------- .../CategoryManyToManyBidirectionalEntity.php | 8 +-- .../CategoryOneToManyBidirectionalEntity.php | 8 +-- .../CategoryOneToOneBidirectionalEntity.php | 8 +-- .../Model/ExtendedCategory.php | 70 +++++++++---------- .../Model/ExtendedOrderItem.php | 8 +-- .../Model/ExtendedOrderPayment.php | 2 +- .../Model/ExtendedOrderProduct.php | 2 +- .../Model/ExtendedOrderTransport.php | 2 +- .../EntityExtension/Model/ExtendedProduct.php | 70 +++++++++---------- .../ProductManyToManyBidirectionalEntity.php | 8 +-- .../ProductOneToManyBidirectionalEntity.php | 8 +-- .../ProductOneToOneBidirectionalEntity.php | 8 +-- .../Model/UnidirectionalEntity.php | 2 +- .../OverwritableEntityNameResolver.php | 2 +- .../OverwritableLoadORMMetadataSubscriber.php | 2 +- .../AdvancedSearchOperatorTranslationTest.php | 2 +- ...vancedSearchOrderFilterTranslationTest.php | 2 +- ...ncedSearchProductFilterTranslationTest.php | 2 +- .../Form/YesNoTypeTest.php | 2 +- .../AdministratorRepositoryTest.php | 6 +- .../AdministratorFrontSecurityFacadeTest.php | 6 +- .../Cart/CartFacadeDeleteOldCartsTest.php | 6 +- .../Model/Cart/CartFacadeTest.php | 6 +- .../Model/Cart/CartItemTest.php | 6 +- .../Model/Cart/CartServiceTest.php | 2 +- .../Model/Cart/CartTest.php | 6 +- .../Cart/Watcher/CartWatcherServiceTest.php | 2 +- .../Model/Category/CategoryDomainTest.php | 6 +- .../Model/Category/CategoryRepositoryTest.php | 6 +- .../Customer/CustomerPasswordServiceTest.php | 2 +- .../GetAllEmailsDataIteratorMethodTest.php | 6 +- .../NewsletterSubscriberPersistenceTest.php | 6 +- .../Model/Order/Mail/OrderMailServiceTest.php | 2 +- .../Model/Order/OrderFacadeTest.php | 6 +- .../OrderNumberSequenceRepositoryTest.php | 6 +- .../Order/OrderTransportAndPaymentTest.php | 6 +- .../Preview/OrderPreviewCalculationTest.php | 2 +- .../Order/Status/OrderStatusFacadeTest.php | 6 +- ...endentPaymentVisibilityCalculationTest.php | 6 +- .../Model/Payment/PaymentDomainTest.php | 6 +- .../Model/Payment/PaymentTest.php | 6 +- .../Pricing/Group/PricingGroupFacadeTest.php | 6 +- .../InputPriceRecalculationSchedulerTest.php | 6 +- .../Availability/AvailabilityFacadeTest.php | 6 +- .../ProductAvailabilityCalculationTest.php | 2 +- .../ProductAvailabilityRecalculatorTest.php | 6 +- .../Model/Product/Brand/BrandDomainTest.php | 6 +- .../Model/Product/ProductDomainTest.php | 6 +- .../Model/Product/ProductFacadeTest.php | 6 +- .../ProductOnCurrentDomainFacadeTest.php | 6 +- .../Model/Product/ProductRepositoryTest.php | 6 +- .../ProductSellingDeniedRecalculatorTest.php | 6 +- .../Model/Product/ProductServiceTest.php | 6 +- .../ProductVisibilityRepositoryTest.php | 6 +- ...dentTransportVisibilityCalculationTest.php | 6 +- .../Model/Transport/TransportDomainTest.php | 6 +- .../Model/Unit/UnitFacadeTest.php | 6 +- .../Model/Vat/VatFacadeTest.php | 6 +- .../PersonalDataExportXmlTest.php | 6 +- .../PersonalData/Resources/test.xml | 0 .../Twig/DateTimeFormatterExtensionTest.php | 2 +- .../Twig/NumberFormatterExtensionTest.php | 2 +- .../Twig/PriceExtensionTest.php | 2 +- .../Twig/TwigEnvironmentTest.php | 2 +- .../Smoke/LocalizationListenerTest.php | 4 +- ....php => TransactionFunctionalTestCase.php} | 2 +- 95 files changed, 302 insertions(+), 302 deletions(-) delete mode 100644 tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/Testclass.php delete mode 100644 tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/testClassName.expected.js delete mode 100644 tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/testClassName.js delete mode 100644 tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/testDefinedConstant.js delete mode 100644 tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/testUndefinedConstant.js rename tests/ShopBundle/{Database => Functional}/Component/Doctrine/GroupedScalarHydratorTest.php (84%) rename tests/ShopBundle/{Database => Functional}/Component/Doctrine/SortableNullsWalkerTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Component/Domain/Config/DomainsConfigLoaderTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Component/Domain/Config/test_domains.yml (100%) rename tests/ShopBundle/{Database => Functional}/Component/Domain/Config/test_domains_urls.yml (100%) rename tests/ShopBundle/{Database => Functional}/Component/Domain/Multidomain/MultidomainEntityDataCreatorTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Component/FlashMessage/BagTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Component/Grid/QueryBuilderDataSourceTest.php (95%) rename tests/ShopBundle/{Database => Functional}/Component/Grid/QueryBuilderWithRowManipulatorDataSourceTest.php (92%) rename tests/ShopBundle/{Database => Functional}/Component/HttpFoundation/FragmentHandlerTest.php (87%) rename tests/ShopBundle/{Database => Functional}/Component/Javascript/Compiler/Constant/JsConstantCompilerPassTest.php (95%) create mode 100644 tests/ShopBundle/Functional/Component/Javascript/Compiler/Constant/Testclass.php create mode 100644 tests/ShopBundle/Functional/Component/Javascript/Compiler/Constant/testClassName.expected.js create mode 100644 tests/ShopBundle/Functional/Component/Javascript/Compiler/Constant/testClassName.js rename tests/ShopBundle/{Database => Functional}/Component/Javascript/Compiler/Constant/testDefinedConstant.expected.js (100%) create mode 100644 tests/ShopBundle/Functional/Component/Javascript/Compiler/Constant/testDefinedConstant.js create mode 100644 tests/ShopBundle/Functional/Component/Javascript/Compiler/Constant/testUndefinedConstant.js rename tests/ShopBundle/{Database => Functional}/Component/Javascript/Compiler/Translator/JsTranslatorCompilerPassTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Controller/HomepageControllerTest.php (92%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/EntityExtensionTest.php (92%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/CategoryOneToManyBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/CategoryOneToOneBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedCategory.php (73%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedOrderItem.php (68%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedOrderPayment.php (97%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedOrderProduct.php (97%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedOrderTransport.php (97%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ExtendedProduct.php (73%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ProductManyToManyBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ProductOneToManyBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/ProductOneToOneBidirectionalEntity.php (77%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/Model/UnidirectionalEntity.php (90%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/OverwritableEntityNameResolver.php (86%) rename tests/ShopBundle/{Database => Functional}/EntityExtension/OverwritableLoadORMMetadataSubscriber.php (92%) rename tests/ShopBundle/{Database => Functional}/Form/Admin/AdvancedSearch/AdvancedSearchOperatorTranslationTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Form/Admin/AdvancedSearch/AdvancedSearchOrderFilterTranslationTest.php (95%) rename tests/ShopBundle/{Database => Functional}/Form/Admin/AdvancedSearch/AdvancedSearchProductFilterTranslationTest.php (95%) rename tests/ShopBundle/{Database => Functional}/Form/YesNoTypeTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Administrator/AdministratorRepositoryTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Model/Administrator/Security/AdministratorFrontSecurityFacadeTest.php (91%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/CartFacadeDeleteOldCartsTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/CartFacadeTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/CartItemTest.php (92%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/CartServiceTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/CartTest.php (92%) rename tests/ShopBundle/{Database => Functional}/Model/Cart/Watcher/CartWatcherServiceTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Category/CategoryDomainTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Category/CategoryRepositoryTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Model/Customer/CustomerPasswordServiceTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Model/Newsletter/NewsletterRepository/GetAllEmailsDataIteratorMethodTest.php (90%) rename tests/ShopBundle/{Database => Functional}/Model/Newsletter/Subscriber/NewsletterSubscriberPersistenceTest.php (82%) rename tests/ShopBundle/{Database => Functional}/Model/Order/Mail/OrderMailServiceTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Order/OrderFacadeTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Model/Order/OrderNumberSequenceRepositoryTest.php (77%) rename tests/ShopBundle/{Database => Functional}/Model/Order/OrderTransportAndPaymentTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Model/Order/Preview/OrderPreviewCalculationTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Order/Status/OrderStatusFacadeTest.php (91%) rename tests/ShopBundle/{Database => Functional}/Model/Payment/IndependentPaymentVisibilityCalculationTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Payment/PaymentDomainTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Model/Payment/PaymentTest.php (91%) rename tests/ShopBundle/{Database => Functional}/Model/Pricing/Group/PricingGroupFacadeTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Pricing/InputPriceRecalculationSchedulerTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Model/Product/Availability/AvailabilityFacadeTest.php (92%) rename tests/ShopBundle/{Database => Functional}/Model/Product/Availability/ProductAvailabilityCalculationTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Product/Availability/ProductAvailabilityRecalculatorTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Product/Brand/BrandDomainTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductDomainTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductFacadeTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductOnCurrentDomainFacadeTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductRepositoryTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductSellingDeniedRecalculatorTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductServiceTest.php (95%) rename tests/ShopBundle/{Database => Functional}/Model/Product/ProductVisibilityRepositoryTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Model/Transport/IndependentTransportVisibilityCalculationTest.php (96%) rename tests/ShopBundle/{Database => Functional}/Model/Transport/TransportDomainTest.php (94%) rename tests/ShopBundle/{Database => Functional}/Model/Unit/UnitFacadeTest.php (91%) rename tests/ShopBundle/{Database => Functional}/Model/Vat/VatFacadeTest.php (94%) rename tests/ShopBundle/{Database => Functional}/PersonalData/PersonalDataExportXmlTest.php (97%) rename tests/ShopBundle/{Database => Functional}/PersonalData/Resources/test.xml (100%) rename tests/ShopBundle/{Database => Functional}/Twig/DateTimeFormatterExtensionTest.php (97%) rename tests/ShopBundle/{Database => Functional}/Twig/NumberFormatterExtensionTest.php (98%) rename tests/ShopBundle/{Database => Functional}/Twig/PriceExtensionTest.php (99%) rename tests/ShopBundle/{Database => Functional}/Twig/TwigEnvironmentTest.php (93%) rename tests/ShopBundle/Test/{DatabaseTestCase.php => TransactionFunctionalTestCase.php} (87%) diff --git a/build-dev.xml b/build-dev.xml index b2ebf9070..b2c755ffd 100644 --- a/build-dev.xml +++ b/build-dev.xml @@ -18,7 +18,7 @@ - + @@ -442,7 +442,7 @@ - + @@ -454,7 +454,7 @@ > - + @@ -470,7 +470,7 @@ > - + diff --git a/easy-coding-standard.yml b/easy-coding-standard.yml index 268fc97be..90340f304 100644 --- a/easy-coding-standard.yml +++ b/easy-coding-standard.yml @@ -10,22 +10,22 @@ parameters: - '*/src/Shopsys/ShopBundle/Form/Front/Customer/BillingAddressFormType.php' - '*/src/Shopsys/ShopBundle/Form/Front/Customer/DeliveryAddressFormType.php' - '*/src/Shopsys/ShopBundle/Form/Front/Order/PersonalInfoFormType.php' - - '*/tests/ShopBundle/Database/EntityExtension/EntityExtensionTest.php' - - '*/tests/ShopBundle/Database/Model/Order/OrderFacadeTest.php' - - '*/tests/ShopBundle/Database/Model/Order/Preview/OrderPreviewCalculationTest.php' - - '*/tests/ShopBundle/Database/Model/Pricing/InputPriceRecalculationSchedulerTest.php' + - '*/tests/ShopBundle/Functional/EntityExtension/EntityExtensionTest.php' + - '*/tests/ShopBundle/Functional/Model/Order/OrderFacadeTest.php' + - '*/tests/ShopBundle/Functional/Model/Order/Preview/OrderPreviewCalculationTest.php' + - '*/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php' - '*/tests/ShopBundle/Smoke/Http/RouteConfigCustomization.php' - '*/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php' - '*/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php' ObjectCalisthenics\Sniffs\Files\ClassTraitAndInterfaceLengthSniff: - - '*/tests/ShopBundle/Database/Model/Product/ProductVisibilityRepositoryTest.php' + - '*/tests/ShopBundle/Functional/Model/Product/ProductVisibilityRepositoryTest.php' Shopsys\CodingStandards\Sniffs\ValidVariableNameSniff: - - '*/tests/ShopBundle/Database/EntityExtension/EntityExtensionTest.php' + - '*/tests/ShopBundle/Functional/EntityExtension/EntityExtensionTest.php' - '*/tests/ShopBundle/Test/Codeception/_generated/AcceptanceTesterActions.php' Shopsys\CodingStandards\Sniffs\ObjectIsCreatedByFactorySniff: - '*/tests/*' Shopsys\CodingStandards\Sniffs\ForbiddenDumpSniff: - - '*/tests/ShopBundle/Database/Model/Cart/CartFacadeTest.php' + - '*/tests/ShopBundle/Functional/Model/Cart/CartFacadeTest.php' diff --git a/phpunit.xml b/phpunit.xml index 992fc4951..79a632a80 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -22,8 +22,8 @@ tests/*Bundle/Unit - - tests/*Bundle/Database + + tests/*Bundle/Functional tests/*Bundle/Smoke diff --git a/src/Shopsys/ShopBundle/Resources/config/services_test.yml b/src/Shopsys/ShopBundle/Resources/config/services_test.yml index 729757720..af2242454 100644 --- a/src/Shopsys/ShopBundle/Resources/config/services_test.yml +++ b/src/Shopsys/ShopBundle/Resources/config/services_test.yml @@ -12,7 +12,7 @@ services: Shopsys\FrameworkBundle\Model\Localization\IntlCurrencyRepository: ~ Shopsys\FrameworkBundle\Component\EntityExtension\EntityNameResolver: - class: Tests\ShopBundle\Database\EntityExtension\OverwritableEntityNameResolver + class: Tests\ShopBundle\Functional\EntityExtension\OverwritableEntityNameResolver arguments: - "%shopsys.entity_extension.map%" @@ -29,7 +29,7 @@ services: Symfony\Component\Filesystem\Filesystem: ~ joschi127_doctrine_entity_override.event_subscriber.load_orm_metadata: - class: Tests\ShopBundle\Database\EntityExtension\OverwritableLoadORMMetadataSubscriber + class: Tests\ShopBundle\Functional\EntityExtension\OverwritableLoadORMMetadataSubscriber arguments: - "@service_container" - "%shopsys.entity_extension.map%" diff --git a/tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/Testclass.php b/tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/Testclass.php deleted file mode 100644 index 418e17b40..000000000 --- a/tests/ShopBundle/Database/Component/Javascript/Compiler/Constant/Testclass.php +++ /dev/null @@ -1,10 +0,0 @@ -em->getConfiguration(); $metadataDriverChain = $configuration->getMetadataDriverImpl(); if ($metadataDriverChain instanceof MappingDriverChain) { - $metadataDriverChain->addDriver($driver, 'Tests\\ShopBundle\\Database\\EntityExtension'); + $metadataDriverChain->addDriver($driver, 'Tests\\ShopBundle\\Functional\\EntityExtension'); } else { $this->fail(sprintf('Metadata driver must be type of %s', MappingDriverChain::class)); } @@ -110,9 +110,9 @@ public function overwriteEntityExtensionMapInServicesInContainer(array $entityEx $entityExtensionMap = array_merge($originalEntityExtensionMap, $entityExtensionMap); $loadORMMetadataSubscriber = $this->getContainer()->get('joschi127_doctrine_entity_override.event_subscriber.load_orm_metadata'); - /* @var $loadORMMetadataSubscriber \Tests\ShopBundle\Database\EntityExtension\OverwritableLoadORMMetadataSubscriber */ + /* @var $loadORMMetadataSubscriber \Tests\ShopBundle\Functional\EntityExtension\OverwritableLoadORMMetadataSubscriber */ $entityNameResolver = $this->getContainer()->get(EntityNameResolver::class); - /* @var $entityNameResolver \Tests\ShopBundle\Database\EntityExtension\OverwritableEntityNameResolver */ + /* @var $entityNameResolver \Tests\ShopBundle\Functional\EntityExtension\OverwritableEntityNameResolver */ $loadORMMetadataSubscriber->overwriteEntityExtensionMap($entityExtensionMap); $entityNameResolver->overwriteEntityExtensionMap($entityExtensionMap); @@ -275,7 +275,7 @@ private function doTestExtendedProductPersistence(): void /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedProduct + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedProduct */ private function getProduct(int $id): ExtendedProduct { @@ -400,7 +400,7 @@ private function doTestExtendedCategoryPersistence(): void /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedCategory + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedCategory */ public function getCategory(int $id): ExtendedCategory { @@ -450,7 +450,7 @@ private function doTestExtendedOrderItemsPersistence(): void /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedCategory + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedCategory */ private function getOrderTransport(int $id): ExtendedOrderTransport { @@ -461,7 +461,7 @@ private function getOrderTransport(int $id): ExtendedOrderTransport /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedOrderPayment + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedOrderPayment */ private function getOrderPayment(int $id): ExtendedOrderPayment { @@ -472,7 +472,7 @@ private function getOrderPayment(int $id): ExtendedOrderPayment /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedOrderProduct + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedOrderProduct */ private function getOrderProduct(int $id): ExtendedOrderProduct { @@ -483,7 +483,7 @@ private function getOrderProduct(int $id): ExtendedOrderProduct /** * @param int $id - * @return \Tests\ShopBundle\Database\EntityExtension\Model\ExtendedOrderItem + * @return \Tests\ShopBundle\Functional\EntityExtension\Model\ExtendedOrderItem */ private function getOrderItem(int $id): ExtendedOrderItem { diff --git a/tests/ShopBundle/Database/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php b/tests/ShopBundle/Functional/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php similarity index 77% rename from tests/ShopBundle/Database/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php rename to tests/ShopBundle/Functional/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php index f185771dd..d56f68319 100644 --- a/tests/ShopBundle/Database/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php +++ b/tests/ShopBundle/Functional/EntityExtension/Model/CategoryManyToManyBidirectionalEntity.php @@ -1,6 +1,6 @@ Date: Fri, 7 Dec 2018 08:59:05 +0100 Subject: [PATCH 03/19] phpUnit: Remove unsupported syntaxCheckAttribute - see shopsys/shopsys#592 --- phpunit.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/phpunit.xml b/phpunit.xml index 79a632a80..913840285 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -10,7 +10,6 @@ convertWarningsToExceptions="true" processIsolation="false" stopOnFailure="false" - syntaxCheck="false" failOnWarning="true" beStrictAboutTestsThatDoNotTestAnything="false" > From 9022393ec5196f7f5d682f544b5a6d495cb35e84 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 10:08:56 +0100 Subject: [PATCH 04/19] unnecessary files in docker are now ignored --- .dockerignore | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 000000000..b565f6d58 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,24 @@ +# ignore .git (can be volume-mounted in development environment) +.git + +# ignore directories with meta-data +.idea +nbproject + +# ignore directories that should be created and filled during the image build +node_modules +var +!var/.gitkeep +web/assets/scripts +web/bundles +web/components +web/content +vendor + +# ignore kubernetes manifests +kubernetes + +# ignore docker configs for other images than php-fpm, and the php-fpm's Dockerfile itself +docker +!docker/php-fpm +docker/php-fpm/Dockerfile From 1dd60d1145051d4a9daec7db477e26bab229f15d Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 10:10:23 +0100 Subject: [PATCH 05/19] content-test directory is used instead of content during the test - see shopsys/shopsys#547 --- app/config/parameters_test.yml.dist | 2 ++ app/config/paths.yml | 19 ++++++++++--------- build-dev.xml | 20 ++++++++++++++------ build.xml | 3 +++ docker/nginx/nginx.conf | 2 +- web/.gitignore | 1 + 6 files changed, 31 insertions(+), 16 deletions(-) diff --git a/app/config/parameters_test.yml.dist b/app/config/parameters_test.yml.dist index 2707395c7..7c42ada5f 100644 --- a/app/config/parameters_test.yml.dist +++ b/app/config/parameters_test.yml.dist @@ -13,3 +13,5 @@ parameters: test_mailer_host: smtp-server test_mailer_user: ~ test_mailer_password: ~ + + shopsys.content_dir_name: 'content-test' diff --git a/app/config/paths.yml b/app/config/paths.yml index fd72072ff..069f10009 100644 --- a/app/config/paths.yml +++ b/app/config/paths.yml @@ -1,4 +1,5 @@ parameters: + shopsys.content_dir_name: 'content' shopsys.css_version_filepath: '%shopsys.web_dir%/assets/cssVersion' shopsys.data_fixtures.resource_customers_filepath: '%shopsys.data_fixtures.resources_dir%/demo-data-customers.csv' shopsys.data_fixtures.resource_products_filepath: '%shopsys.data_fixtures.resources_dir%/demo-data-products.csv' @@ -6,28 +7,28 @@ parameters: shopsys.default_db_schema_filepath: '%shopsys.framework.resources_dir%/database/schema.sql' shopsys.domain_config_filepath: '%kernel.root_dir%/config/domains.yml' shopsys.domain_images_dir: '/web%shopsys.domain_images_url_prefix%' - shopsys.domain_images_url_prefix: /content/admin/images/domain + shopsys.domain_images_url_prefix: '/%shopsys.content_dir_name%/admin/images/domain' shopsys.domain_urls_config_filepath: '%kernel.root_dir%/config/domains_urls.yml' shopsys.error_pages_dir: '%shopsys.root_dir%/var/errorPages/' shopsys.feed_dir: '/web%shopsys.feed_url_prefix%' - shopsys.feed_url_prefix: /content/feeds/ + shopsys.feed_url_prefix: '/%shopsys.content_dir_name%/feeds/' shopsys.filemanager_upload_dir: '%shopsys.web_dir%/%shopsys.filemanager_upload_web_dir%' - shopsys.filemanager_upload_web_dir: content/wysiwyg + shopsys.filemanager_upload_web_dir: '%shopsys.content_dir_name%/wysiwyg' shopsys.framework.root_dir: '%shopsys.root_dir%/vendor/shopsys/framework' - shopsys.front_design_image_url_prefix: /assets/frontend/images/ + shopsys.front_design_image_url_prefix: '/assets/frontend/images/' shopsys.image_config_filepath: '%shopsys.root_dir%/src/Shopsys/ShopBundle/Resources/config/images.yml' shopsys.image_dir: '/web%shopsys.image_url_prefix%' - shopsys.image_url_prefix: /content/images/ + shopsys.image_url_prefix: '/%shopsys.content_dir_name%/images/' shopsys.javascript_sources_dir: '%shopsys.resources_dir%/scripts' - shopsys.javascript_url_prefix: /assets/scripts/ - shopsys.log_stream: /tmp/log-pipe + shopsys.javascript_url_prefix: '/assets/scripts/' + shopsys.log_stream: '/tmp/log-pipe' shopsys.resources_dir: '%shopsys.root_dir%/src/Shopsys/ShopBundle/Resources' shopsys.root_dir: '%kernel.root_dir%/..' shopsys.sitemaps_dir: '/web%shopsys.sitemaps_url_prefix%' - shopsys.sitemaps_url_prefix: /content/sitemaps + shopsys.sitemaps_url_prefix: '/%shopsys.content_dir_name%/sitemaps' shopsys.uploaded_file_config_filepath: '%shopsys.root_dir%/src/Shopsys/ShopBundle/Resources/config/uploaded_files.yml' shopsys.uploaded_file_dir: '/web%shopsys.uploaded_file_url_prefix%' - shopsys.uploaded_file_url_prefix: /content/uploadedFiles/ + shopsys.uploaded_file_url_prefix: '/%shopsys.content_dir_name%/uploadedFiles/' shopsys.web_dir: '%shopsys.root_dir%/web' shopsys.vendor_dir: '%kernel.root_dir%/../vendor' shopsys.js_form_validator_output_vendor_dir: '../vendor' diff --git a/build-dev.xml b/build-dev.xml index b2c755ffd..667250895 100644 --- a/build-dev.xml +++ b/build-dev.xml @@ -1,12 +1,12 @@ - - - - - - + + + + + + @@ -664,6 +664,14 @@ + + + + + + + + diff --git a/build.xml b/build.xml index d2989ac74..244ebd295 100644 --- a/build.xml +++ b/build.xml @@ -391,6 +391,9 @@ + + + diff --git a/docker/nginx/nginx.conf b/docker/nginx/nginx.conf index 26a1d8413..6fb6b1820 100644 --- a/docker/nginx/nginx.conf +++ b/docker/nginx/nginx.conf @@ -37,7 +37,7 @@ server { try_files $uri @app; } - location ~ ^/content/images/ { + location ~ ^/content(-test)?/images/ { # Newly uploaded images get new ID (different URL) so they could be cached forever. # But change of resolution in images.yml does not induce a change of URL # so it is safer to cache generated images only for few days. diff --git a/web/.gitignore b/web/.gitignore index f5fdf57fe..575b078f7 100644 --- a/web/.gitignore +++ b/web/.gitignore @@ -1,4 +1,5 @@ /bundles /assetic /content +/content-test /components From f87ed07b2bcf51c7dbb1531cecf764e70d23eaaa Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 10:15:21 +0100 Subject: [PATCH 06/19] updated coding standards and applied - added missing @param and @return annotations through the whole codebase - see shopsys/shopsys#573 --- composer.json | 2 +- composer.lock | 12 ++--- .../Controller/Admin/CustomerController.php | 18 +++++++ .../Controller/Admin/LoginController.php | 3 ++ .../Controller/Front/AdvertController.php | 3 ++ .../Controller/Front/ArticleController.php | 3 ++ .../Front/BestsellingProductController.php | 8 +++ .../Controller/Front/BrandController.php | 3 ++ .../Controller/Front/BreadcrumbController.php | 3 ++ .../Controller/Front/CartController.php | 9 ++++ .../Controller/Front/CategoryController.php | 7 +++ .../Front/ContactFormController.php | 5 ++ .../Controller/Front/CustomerController.php | 11 +++++ .../Front/CustomerPasswordController.php | 11 +++++ .../Controller/Front/ErrorController.php | 6 +++ .../Controller/Front/HomepageController.php | 7 +++ .../Controller/Front/ImageController.php | 10 ++++ .../Controller/Front/LoginController.php | 6 +++ .../Controller/Front/NewsletterController.php | 5 ++ .../Controller/Front/OrderController.php | 18 +++++++ .../Front/PersonalDataController.php | 17 +++++++ .../Controller/Front/ProductController.php | 21 ++++++++ .../Controller/Front/PromoCodeController.php | 3 ++ .../Front/RegistrationController.php | 13 +++++ .../Controller/Front/RobotsController.php | 4 ++ .../Controller/Front/ScriptController.php | 4 ++ .../Controller/Front/SearchController.php | 10 ++++ .../Demo/MailTemplateDataFixture.php | 10 ++++ .../MailTemplateDataFixture.php | 5 ++ .../Form/Admin/CategoryFormTypeExtension.php | 4 +- .../Form/Admin/ProductFormTypeExtension.php | 3 ++ .../Front/Customer/BillingAddressFormType.php | 3 ++ .../Form/Front/Customer/CustomerFormType.php | 3 ++ .../Customer/DeliveryAddressFormType.php | 3 ++ .../Order/DomainAwareOrderFlowFactory.php | 4 ++ .../ShopBundle/Form/Front/Order/OrderFlow.php | 2 +- .../Form/Front/Order/PersonalInfoFormType.php | 5 ++ .../Model/AdminNavigation/SideMenuBuilder.php | 3 ++ .../Category/CurrentCategoryResolver.php | 4 ++ .../Model/Customer/BillingAddressFacade.php | 1 + .../Model/Customer/CustomerData.php | 5 ++ .../Model/Customer/CustomerFacade.php | 2 + .../Exception/DuplicateEmailsException.php | 1 + .../Model/Order/OrderDataMapper.php | 8 +++ .../Model/PickUpPlace/PickUpPlaceFacade.php | 6 +++ .../PickUpPlaceIdToEntityTransformer.php | 5 ++ .../PickUpPlace/PickUpPlaceRepository.php | 4 ++ .../Product/Feed/Google/GoogleFeedItem.php | 14 ++++++ .../ShopBundle/Model/Product/Product.php | 1 + .../AdminProductAdvancedSearchCest.php | 5 ++ .../acceptance/AdministratorLoginCest.php | 12 +++++ .../Acceptance/acceptance/CartCest.php | 49 +++++++++++++++++++ .../acceptance/CustomerLoginCest.php | 15 ++++++ .../acceptance/CustomerRegistrationCest.php | 13 +++++ .../acceptance/ErrorHandlingCest.php | 3 ++ .../acceptance/LoginAsCustomerCest.php | 5 ++ .../Acceptance/acceptance/OrderCest.php | 26 ++++++++++ .../acceptance/PageObject/AbstractPage.php | 4 ++ .../PageObject/Front/HomepagePage.php | 5 ++ .../PageObject/Front/ProductFilterPage.php | 4 ++ .../PageObject/Front/ProductListPage.php | 5 ++ .../acceptance/PaymentImageUploadCest.php | 5 ++ .../acceptance/ProductFilterCest.php | 5 ++ .../acceptance/ProductImageUploadCest.php | 5 ++ .../acceptance/PromoCodeInlineEditCest.php | 15 ++++++ .../acceptance/TransportImageUploadCest.php | 5 ++ .../Customer/CustomerPasswordServiceTest.php | 4 ++ .../Order/OrderTransportAndPaymentTest.php | 2 +- ...endentPaymentVisibilityCalculationTest.php | 2 +- .../InputPriceRecalculationSchedulerTest.php | 6 +++ .../ProductAvailabilityCalculationTest.php | 7 +++ .../Model/Product/ProductFacadeTest.php | 6 +++ .../Model/Product/ProductRepositoryTest.php | 12 +++++ .../Twig/DateTimeFormatterExtensionTest.php | 3 ++ .../Twig/NumberFormatterExtensionTest.php | 3 ++ .../Functional/Twig/PriceExtensionTest.php | 9 ++++ .../Feed/PerformanceResultsCsvExporter.php | 3 ++ .../Page/PerformanceResultsCsvExporter.php | 3 ++ .../Page/PerformanceTestSummaryPrinter.php | 3 ++ tests/ShopBundle/Smoke/NewProductTest.php | 1 + .../Codeception/Module/StrictWebDriver.php | 13 +++++ 81 files changed, 564 insertions(+), 12 deletions(-) diff --git a/composer.json b/composer.json index 12b539b33..5166dd89a 100644 --- a/composer.json +++ b/composer.json @@ -96,7 +96,7 @@ "codeception/codeception": "^2.5.0", "phpstan/phpstan": "^0.7", "phpunit/phpunit": "^7.0", - "shopsys/coding-standards": "v7.0.0-beta2", + "shopsys/coding-standards": "v7.0.0-beta3", "shopsys/http-smoke-testing": "v7.0.0-beta2" }, "conflict": { diff --git a/composer.lock b/composer.lock index ea9383cef..06c7d4736 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "11528a4e46054f0cbf0e8837f5b86da1", + "content-hash": "863b8b209c12a9d014f128e6d26911c2", "packages": [ { "name": "arvenil/ninja-mutex", @@ -9612,16 +9612,16 @@ }, { "name": "shopsys/coding-standards", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/coding-standards.git", - "reference": "bb397e146931f7b697e871a3b5355e68a29f0a64" + "reference": "094c55d286e209998bd2808c1167cbb406e9a10b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/coding-standards/zipball/bb397e146931f7b697e871a3b5355e68a29f0a64", - "reference": "bb397e146931f7b697e871a3b5355e68a29f0a64", + "url": "https://api.github.com/repos/shopsys/coding-standards/zipball/094c55d286e209998bd2808c1167cbb406e9a10b", + "reference": "094c55d286e209998bd2808c1167cbb406e9a10b", "shasum": "" }, "require": { @@ -9662,7 +9662,7 @@ "code quality", "coding standards" ], - "time": "2018-08-23T09:12:51+00:00" + "time": "2018-11-15T09:31:59+00:00" }, { "name": "shopsys/http-smoke-testing", diff --git a/src/Shopsys/ShopBundle/Controller/Admin/CustomerController.php b/src/Shopsys/ShopBundle/Controller/Admin/CustomerController.php index a3472ca1b..844bf4134 100644 --- a/src/Shopsys/ShopBundle/Controller/Admin/CustomerController.php +++ b/src/Shopsys/ShopBundle/Controller/Admin/CustomerController.php @@ -111,6 +111,24 @@ class CustomerController extends BaseCustomerController */ protected $domainRouterFactory; + /** + * @param \Shopsys\FrameworkBundle\Model\Customer\UserDataFactoryInterface $userDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerListAdminFacade $customerListAdminFacade + * @param \Shopsys\ShopBundle\Model\Customer\CustomerFacade $customerFacade + * @param \Shopsys\FrameworkBundle\Model\AdminNavigation\BreadcrumbOverrider $breadcrumbOverrider + * @param \Shopsys\FrameworkBundle\Model\Administrator\AdministratorGridFacade $administratorGridFacade + * @param \Shopsys\FrameworkBundle\Component\Grid\GridFactory $gridFactory + * @param \Shopsys\FrameworkBundle\Component\Domain\AdminDomainTabsFacade $adminDomainTabsFacade + * @param \Shopsys\FrameworkBundle\Model\Order\OrderFacade $orderFacade + * @param \Shopsys\FrameworkBundle\Model\Security\LoginAsUserFacade $loginAsUserFacade + * @param \Shopsys\FrameworkBundle\Component\Router\DomainRouterFactory $domainRouterFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerDataFactoryInterface $customerDataFactory + * @param \Shopsys\ShopBundle\Model\Customer\BillingAddressFacade $billingAddressFacade + * @param \Shopsys\ShopBundle\Model\Customer\BillingAddressDataFactory $billingAddressDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\UserFactory $userFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\DeliveryAddressDataFactory $deliveryAddressDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\DeliveryAddressFactory $deliveryAddressFactory + */ public function __construct( UserDataFactoryInterface $userDataFactory, CustomerListAdminFacade $customerListAdminFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Admin/LoginController.php b/src/Shopsys/ShopBundle/Controller/Admin/LoginController.php index 45d23be45..953d68b34 100644 --- a/src/Shopsys/ShopBundle/Controller/Admin/LoginController.php +++ b/src/Shopsys/ShopBundle/Controller/Admin/LoginController.php @@ -12,6 +12,9 @@ class LoginController extends BaseLoginController { + /** + * @param \Shopsys\FrameworkBundle\Component\Router\DomainRouter $domainRouter + */ private function changeDomainContext(DomainRouter $domainRouter) { $mainAdminDomainHost = $domainRouter->getContext()->getHost(); diff --git a/src/Shopsys/ShopBundle/Controller/Front/AdvertController.php b/src/Shopsys/ShopBundle/Controller/Front/AdvertController.php index 848d6b6cf..6bbe093a4 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/AdvertController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/AdvertController.php @@ -11,6 +11,9 @@ class AdvertController extends FrontBaseController */ private $advertFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Advert\AdvertFacade $advertFacade + */ public function __construct(AdvertFacade $advertFacade) { $this->advertFacade = $advertFacade; diff --git a/src/Shopsys/ShopBundle/Controller/Front/ArticleController.php b/src/Shopsys/ShopBundle/Controller/Front/ArticleController.php index a3552538e..4c53bad96 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ArticleController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ArticleController.php @@ -12,6 +12,9 @@ class ArticleController extends FrontBaseController */ private $articleFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Article\ArticleFacade $articleFacade + */ public function __construct(ArticleFacade $articleFacade) { $this->articleFacade = $articleFacade; diff --git a/src/Shopsys/ShopBundle/Controller/Front/BestsellingProductController.php b/src/Shopsys/ShopBundle/Controller/Front/BestsellingProductController.php index 5c8aa7a22..1327b3f47 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/BestsellingProductController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/BestsellingProductController.php @@ -25,6 +25,11 @@ class BestsellingProductController extends FrontBaseController */ private $currentCustomer; + /** + * @param \Shopsys\FrameworkBundle\Model\Product\BestsellingProduct\CachedBestsellingProductFacade $cachedBestsellingProductFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Customer\CurrentCustomer $currentCustomer + */ public function __construct( CachedBestsellingProductFacade $cachedBestsellingProductFacade, Domain $domain, @@ -35,6 +40,9 @@ public function __construct( $this->currentCustomer = $currentCustomer; } + /** + * @param \Shopsys\FrameworkBundle\Model\Category\Category $category + */ public function listAction(Category $category) { $bestsellingProducts = $this->cachedBestsellingProductFacade->getAllOfferedBestsellingProducts( diff --git a/src/Shopsys/ShopBundle/Controller/Front/BrandController.php b/src/Shopsys/ShopBundle/Controller/Front/BrandController.php index add71852f..a3833835e 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/BrandController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/BrandController.php @@ -11,6 +11,9 @@ class BrandController extends FrontBaseController */ private $brandFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Product\Brand\BrandFacade $brandFacade + */ public function __construct( BrandFacade $brandFacade ) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/BreadcrumbController.php b/src/Shopsys/ShopBundle/Controller/Front/BreadcrumbController.php index d4131885e..0e267942e 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/BreadcrumbController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/BreadcrumbController.php @@ -11,6 +11,9 @@ class BreadcrumbController extends FrontBaseController */ private $breadcrumbResolver; + /** + * @param \Shopsys\FrameworkBundle\Component\Breadcrumb\BreadcrumbResolver $breadcrumbResolver + */ public function __construct( BreadcrumbResolver $breadcrumbResolver ) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/CartController.php b/src/Shopsys/ShopBundle/Controller/Front/CartController.php index 39e13b2e6..be84188d6 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/CartController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/CartController.php @@ -58,6 +58,15 @@ class CartController extends FrontBaseController */ private $errorService; + /** + * @param \Shopsys\FrameworkBundle\Model\Product\Accessory\ProductAccessoryFacade $productAccessoryFacade + * @param \Shopsys\FrameworkBundle\Model\Cart\CartFacade $cartFacade + * @param \Shopsys\FrameworkBundle\Model\Customer\CurrentCustomer $currentCustomer + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\TransportAndPayment\FreeTransportAndPaymentFacade $freeTransportAndPaymentFacade + * @param \Shopsys\FrameworkBundle\Model\Order\Preview\OrderPreviewFactory $orderPreviewFactory + * @param \Shopsys\FrameworkBundle\Component\FlashMessage\ErrorService $errorService + */ public function __construct( ProductAccessoryFacade $productAccessoryFacade, CartFacade $cartFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/CategoryController.php b/src/Shopsys/ShopBundle/Controller/Front/CategoryController.php index 1aa0e048d..4832468d1 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/CategoryController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/CategoryController.php @@ -36,6 +36,13 @@ class CategoryController extends FrontBaseController */ private $currentCustomer; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Category\CategoryFacade $categoryFacade + * @param \Shopsys\ShopBundle\Model\Category\CurrentCategoryResolver $currentCategoryResolver + * @param \Shopsys\FrameworkBundle\Model\Category\TopCategory\TopCategoryFacade $topCategoryFacade + * @param \Shopsys\FrameworkBundle\Model\Customer\CurrentCustomer $currentCustomer + */ public function __construct( Domain $domain, CategoryFacade $categoryFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/ContactFormController.php b/src/Shopsys/ShopBundle/Controller/Front/ContactFormController.php index 83c9658b7..84cbca17d 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ContactFormController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ContactFormController.php @@ -27,6 +27,11 @@ class ContactFormController extends FrontBaseController */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Model\ContactForm\ContactFormFacade $contactFormFacade + * @param \Shopsys\FrameworkBundle\Model\LegalConditions\LegalConditionsFacade $legalConditionsFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct( ContactFormFacade $contactFormFacade, LegalConditionsFacade $legalConditionsFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/CustomerController.php b/src/Shopsys/ShopBundle/Controller/Front/CustomerController.php index cb24be973..d6540a005 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/CustomerController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/CustomerController.php @@ -44,6 +44,14 @@ class CustomerController extends FrontBaseController */ private $customerDataFactory; + /** + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerFacade $customerFacade + * @param \Shopsys\FrameworkBundle\Model\Order\OrderFacade $orderFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Order\Item\OrderItemPriceCalculation $orderItemPriceCalculation + * @param \Shopsys\FrameworkBundle\Model\Security\LoginAsUserFacade $loginAsUserFacade + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerDataFactoryInterface $customerDataFactory + */ public function __construct( CustomerFacade $customerFacade, OrderFacade $orderFacade, @@ -60,6 +68,9 @@ public function __construct( $this->customerDataFactory = $customerDataFactory; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function editAction(Request $request) { if (!$this->isGranted(Roles::ROLE_LOGGED_CUSTOMER)) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/CustomerPasswordController.php b/src/Shopsys/ShopBundle/Controller/Front/CustomerPasswordController.php index 4a6ae23b7..986373862 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/CustomerPasswordController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/CustomerPasswordController.php @@ -26,6 +26,11 @@ class CustomerPasswordController extends FrontBaseController */ private $loginService; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerPasswordFacade $customerPasswordFacade + * @param \Shopsys\FrameworkBundle\Model\Security\LoginService $loginService + */ public function __construct( Domain $domain, CustomerPasswordFacade $customerPasswordFacade, @@ -36,6 +41,9 @@ public function __construct( $this->loginService = $loginService; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function resetPasswordAction(Request $request) { $form = $this->createForm(ResetPasswordFormType::class); @@ -72,6 +80,9 @@ public function resetPasswordAction(Request $request) ]); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function setNewPasswordAction(Request $request) { $email = $request->query->get('email'); diff --git a/src/Shopsys/ShopBundle/Controller/Front/ErrorController.php b/src/Shopsys/ShopBundle/Controller/Front/ErrorController.php index 64d93653b..f71c95484 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ErrorController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ErrorController.php @@ -36,6 +36,12 @@ class ErrorController extends FrontBaseController */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Component\Error\ExceptionController $exceptionController + * @param \Shopsys\FrameworkBundle\Component\Error\ExceptionListener $exceptionListener + * @param \Shopsys\FrameworkBundle\Component\Error\ErrorPagesFacade $errorPagesFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct( ExceptionController $exceptionController, ExceptionListener $exceptionListener, diff --git a/src/Shopsys/ShopBundle/Controller/Front/HomepageController.php b/src/Shopsys/ShopBundle/Controller/Front/HomepageController.php index bd53bb6d0..06d4898c5 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/HomepageController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/HomepageController.php @@ -35,6 +35,13 @@ class HomepageController extends FrontBaseController */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Model\Customer\CurrentCustomer $currentCustomer + * @param \Shopsys\FrameworkBundle\Model\Slider\SliderItemFacade $sliderItemFacade + * @param \Shopsys\FrameworkBundle\Model\Product\TopProduct\TopProductFacade $topProductsFacade + * @param \Shopsys\FrameworkBundle\Model\Seo\SeoSettingFacade $seoSettingFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct( CurrentCustomer $currentCustomer, SliderItemFacade $sliderItemFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/ImageController.php b/src/Shopsys/ShopBundle/Controller/Front/ImageController.php index 77cf67d05..ae0b3f715 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ImageController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ImageController.php @@ -19,12 +19,22 @@ class ImageController extends FrontBaseController */ private $filesystem; + /** + * @param \Shopsys\FrameworkBundle\Component\Image\Processing\ImageGeneratorFacade $imageGeneratorFacade + * @param \League\Flysystem\FilesystemInterface $filesystem + */ public function __construct(ImageGeneratorFacade $imageGeneratorFacade, FilesystemInterface $filesystem) { $this->imageGeneratorFacade = $imageGeneratorFacade; $this->filesystem = $filesystem; } + /** + * @param mixed $entityName + * @param mixed $type + * @param mixed $sizeName + * @param mixed $imageId + */ public function getImageAction($entityName, $type, $sizeName, $imageId) { if ($sizeName === ImageConfig::DEFAULT_SIZE_NAME) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/LoginController.php b/src/Shopsys/ShopBundle/Controller/Front/LoginController.php index 1b58fb0cc..a45007c41 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/LoginController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/LoginController.php @@ -15,11 +15,17 @@ class LoginController extends FrontBaseController */ private $loginService; + /** + * @param \Shopsys\FrameworkBundle\Model\Security\LoginService $loginService + */ public function __construct(LoginService $loginService) { $this->loginService = $loginService; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function loginAction(Request $request) { if ($this->isGranted(Roles::ROLE_LOGGED_CUSTOMER)) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/NewsletterController.php b/src/Shopsys/ShopBundle/Controller/Front/NewsletterController.php index d2e308146..52b5f8118 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/NewsletterController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/NewsletterController.php @@ -27,6 +27,11 @@ class NewsletterController extends FrontBaseController */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Model\Newsletter\NewsletterFacade $newsletterFacade + * @param \Shopsys\FrameworkBundle\Model\LegalConditions\LegalConditionsFacade $legalConditionsFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct( NewsletterFacade $newsletterFacade, LegalConditionsFacade $legalConditionsFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/OrderController.php b/src/Shopsys/ShopBundle/Controller/Front/OrderController.php index fbb8cd654..e71bd9ae3 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/OrderController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/OrderController.php @@ -111,6 +111,24 @@ class OrderController extends FrontBaseController */ private $newsletterFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Order\OrderFacade $orderFacade + * @param \Shopsys\FrameworkBundle\Model\Cart\CartFacade $cartFacade + * @param \Shopsys\FrameworkBundle\Model\Order\Preview\OrderPreviewFactory $orderPreviewFactory + * @param \Shopsys\FrameworkBundle\Model\Transport\TransportPriceCalculation $transportPriceCalculation + * @param \Shopsys\FrameworkBundle\Model\Payment\PaymentPriceCalculation $paymentPriceCalculation + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Transport\TransportFacade $transportFacade + * @param \Shopsys\FrameworkBundle\Model\Payment\PaymentFacade $paymentFacade + * @param \Shopsys\FrameworkBundle\Model\Pricing\Currency\CurrencyFacade $currencyFacade + * @param \Shopsys\FrameworkBundle\Model\Order\OrderDataMapper $orderDataMapper + * @param \Shopsys\ShopBundle\Form\Front\Order\DomainAwareOrderFlowFactory $domainAwareOrderFlowFactory + * @param \Symfony\Component\HttpFoundation\Session\SessionInterface $session + * @param \Shopsys\FrameworkBundle\Model\Order\Watcher\TransportAndPaymentWatcherService $transportAndPaymentWatcherService + * @param \Shopsys\FrameworkBundle\Model\Order\Mail\OrderMailFacade $orderMailFacade + * @param \Shopsys\FrameworkBundle\Model\LegalConditions\LegalConditionsFacade $legalConditionsFacade + * @param \Shopsys\FrameworkBundle\Model\Newsletter\NewsletterFacade $newsletterFacade + */ public function __construct( OrderFacade $orderFacade, CartFacade $cartFacade, diff --git a/src/Shopsys/ShopBundle/Controller/Front/PersonalDataController.php b/src/Shopsys/ShopBundle/Controller/Front/PersonalDataController.php index 64e6808dd..d5d2b674b 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/PersonalDataController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/PersonalDataController.php @@ -63,6 +63,17 @@ class PersonalDataController extends FrontBaseController */ private $xmlResponse; + /** + * @param \Shopsys\FrameworkBundle\Component\Setting\Setting $setting + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerFacade $customerFacade + * @param \Shopsys\FrameworkBundle\Model\Order\OrderFacade $orderFacade + * @param \Shopsys\FrameworkBundle\Model\Newsletter\NewsletterFacade $newsletterFacade + * @param \Shopsys\FrameworkBundle\Model\PersonalData\Mail\PersonalDataAccessMailFacade $personalDataAccessMailFacade + * @param \Shopsys\FrameworkBundle\Model\PersonalData\PersonalDataAccessRequestFacade $personalDataAccessRequestFacade + * @param \Shopsys\FrameworkBundle\Model\PersonalData\PersonalDataAccessRequestDataFactoryInterface $personalDataAccessRequestDataFactory + * @param \Shopsys\FrameworkBundle\Component\HttpFoundation\XmlResponse $xmlResponse + */ public function __construct( Setting $setting, Domain $domain, @@ -85,6 +96,9 @@ public function __construct( $this->xmlResponse = $xmlResponse; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function indexAction(Request $request) { $form = $this->createForm( @@ -112,6 +126,9 @@ public function indexAction(Request $request) ]); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function exportAction(Request $request) { $form = $this->createForm( diff --git a/src/Shopsys/ShopBundle/Controller/Front/ProductController.php b/src/Shopsys/ShopBundle/Controller/Front/ProductController.php index f7f5e1b1a..a569d4a73 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ProductController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ProductController.php @@ -75,6 +75,18 @@ class ProductController extends FrontBaseController */ private $brandFacade; + /** + * @param \Shopsys\FrameworkBundle\Twig\RequestExtension $requestExtension + * @param \Shopsys\FrameworkBundle\Model\Category\CategoryFacade $categoryFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Product\ProductOnCurrentDomainFacade $productOnCurrentDomainFacade + * @param \Shopsys\FrameworkBundle\Model\Product\Filter\ProductFilterConfigFactory $productFilterConfigFactory + * @param \Shopsys\FrameworkBundle\Model\Product\Listing\ProductListOrderingModeForListFacade $productListOrderingModeForListFacade + * @param \Shopsys\FrameworkBundle\Model\Product\Listing\ProductListOrderingModeForBrandFacade $productListOrderingModeForBrandFacade + * @param \Shopsys\FrameworkBundle\Model\Product\Listing\ProductListOrderingModeForSearchFacade $productListOrderingModeForSearchFacade + * @param \Shopsys\FrameworkBundle\Model\Module\ModuleFacade $moduleFacade + * @param \Shopsys\FrameworkBundle\Model\Product\Brand\BrandFacade $brandFacade + */ public function __construct( RequestExtension $requestExtension, CategoryFacade $categoryFacade, @@ -320,6 +332,9 @@ private function searchCategories($searchText) ); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function selectOrderingModeForListAction(Request $request) { $productListOrderingConfig = $this->productListOrderingModeForListFacade->getProductListOrderingConfig(); @@ -335,6 +350,9 @@ public function selectOrderingModeForListAction(Request $request) ]); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function selectOrderingModeForListByBrandAction(Request $request) { $productListOrderingConfig = $this->productListOrderingModeForBrandFacade->getProductListOrderingConfig(); @@ -350,6 +368,9 @@ public function selectOrderingModeForListByBrandAction(Request $request) ]); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function selectOrderingModeForSearchAction(Request $request) { $productListOrderingConfig = $this->productListOrderingModeForSearchFacade->getProductListOrderingConfig(); diff --git a/src/Shopsys/ShopBundle/Controller/Front/PromoCodeController.php b/src/Shopsys/ShopBundle/Controller/Front/PromoCodeController.php index ec51db452..0749c9a32 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/PromoCodeController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/PromoCodeController.php @@ -15,6 +15,9 @@ class PromoCodeController extends FrontBaseController */ private $currentPromoCodeFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Order\PromoCode\CurrentPromoCodeFacade $currentPromoCodeFacade + */ public function __construct( CurrentPromoCodeFacade $currentPromoCodeFacade ) { diff --git a/src/Shopsys/ShopBundle/Controller/Front/RegistrationController.php b/src/Shopsys/ShopBundle/Controller/Front/RegistrationController.php index e84a13208..1595309c9 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/RegistrationController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/RegistrationController.php @@ -38,6 +38,13 @@ class RegistrationController extends FrontBaseController */ private $legalConditionsFacade; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Customer\UserDataFactoryInterface $userDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerFacade $customerFacade + * @param \Shopsys\FrameworkBundle\Model\Security\LoginService $loginService + * @param \Shopsys\FrameworkBundle\Model\LegalConditions\LegalConditionsFacade $legalConditionsFacade + */ public function __construct( Domain $domain, UserDataFactoryInterface $userDataFactory, @@ -52,6 +59,9 @@ public function __construct( $this->legalConditionsFacade = $legalConditionsFacade; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function existsEmailAction(Request $request) { $email = $request->get('email'); @@ -60,6 +70,9 @@ public function existsEmailAction(Request $request) return new JsonResponse($user !== null); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function registerAction(Request $request) { $userData = $this->userDataFactory->createForDomainId($this->domain->getId()); diff --git a/src/Shopsys/ShopBundle/Controller/Front/RobotsController.php b/src/Shopsys/ShopBundle/Controller/Front/RobotsController.php index 2be050882..132f65138 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/RobotsController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/RobotsController.php @@ -18,6 +18,10 @@ class RobotsController extends FrontBaseController */ private $sitemapService; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Sitemap\SitemapService $sitemapService + */ public function __construct( Domain $domain, SitemapService $sitemapService diff --git a/src/Shopsys/ShopBundle/Controller/Front/ScriptController.php b/src/Shopsys/ShopBundle/Controller/Front/ScriptController.php index f749a5dc9..9739c9f14 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/ScriptController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/ScriptController.php @@ -19,6 +19,10 @@ class ScriptController extends FrontBaseController */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Model\Script\ScriptFacade $scriptFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct( ScriptFacade $scriptFacade, Domain $domain diff --git a/src/Shopsys/ShopBundle/Controller/Front/SearchController.php b/src/Shopsys/ShopBundle/Controller/Front/SearchController.php index 520e84e72..7dbe543bc 100644 --- a/src/Shopsys/ShopBundle/Controller/Front/SearchController.php +++ b/src/Shopsys/ShopBundle/Controller/Front/SearchController.php @@ -21,6 +21,10 @@ class SearchController extends FrontBaseController */ private $productOnCurrentDomainFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Category\CategoryFacade $categoryFacade + * @param \Shopsys\FrameworkBundle\Model\Product\ProductOnCurrentDomainFacade $productOnCurrentDomainFacade + */ public function __construct( CategoryFacade $categoryFacade, ProductOnCurrentDomainFacade $productOnCurrentDomainFacade @@ -29,6 +33,9 @@ public function __construct( $this->productOnCurrentDomainFacade = $productOnCurrentDomainFacade; } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function autocompleteAction(Request $request) { $searchText = $request->get('searchText'); @@ -47,6 +54,9 @@ public function autocompleteAction(Request $request) ]); } + /** + * @param \Symfony\Component\HttpFoundation\Request $request + */ public function boxAction(Request $request) { $searchText = $request->query->get(ProductController::SEARCH_TEXT_PARAMETER); diff --git a/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php b/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php index 1db1fb69c..116ff2d2a 100644 --- a/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php +++ b/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php @@ -27,6 +27,11 @@ class MailTemplateDataFixture extends AbstractReferenceFixture */ protected $mailTemplateDataFactory; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Mail\MailTemplateFactoryInterface $mailTemplateFactory + * @param \Shopsys\FrameworkBundle\Model\Mail\MailTemplateDataFactoryInterface $mailTemplateDataFactory + */ public function __construct( Domain $domain, MailTemplateFactoryInterface $mailTemplateFactory, @@ -354,6 +359,11 @@ public function load(ObjectManager $manager) $this->createMailTemplate($manager, MailTemplate::PERSONAL_DATA_EXPORT_NAME, $mailTemplateData); } + /** + * @param \Doctrine\Common\Persistence\ObjectManager $manager + * @param mixed $name + * @param \Shopsys\FrameworkBundle\Model\Mail\MailTemplateData $mailTemplateData + */ private function createMailTemplate( ObjectManager $manager, $name, diff --git a/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php b/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php index a2a799de4..4a2663089 100644 --- a/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php +++ b/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php @@ -29,6 +29,11 @@ class MailTemplateDataFixture extends AbstractReferenceFixture */ private $mailTemplateDataFactory; + /** + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Shopsys\FrameworkBundle\Model\Mail\MailTemplateFacade $mailTemplateFacade + * @param \Shopsys\FrameworkBundle\Model\Mail\MailTemplateDataFactoryInterface $mailTemplateDataFactory + */ public function __construct( Domain $domain, MailTemplateFacade $mailTemplateFacade, diff --git a/src/Shopsys/ShopBundle/Form/Admin/CategoryFormTypeExtension.php b/src/Shopsys/ShopBundle/Form/Admin/CategoryFormTypeExtension.php index 50704541d..34102545c 100644 --- a/src/Shopsys/ShopBundle/Form/Admin/CategoryFormTypeExtension.php +++ b/src/Shopsys/ShopBundle/Form/Admin/CategoryFormTypeExtension.php @@ -37,10 +37,10 @@ public function buildForm(FormBuilderInterface $builder, array $options) } /** - * @param FormBuilderInterface $builder + * @param \Symfony\Component\Form\FormBuilderInterface $builder * @param string $name * @param array $options - * @return FormBuilderInterface + * @return \Symfony\Component\Form\FormBuilderInterface */ protected function rebuildChildWithAdditionalOptions(FormBuilderInterface $builder, string $name, array $options): FormBuilderInterface { diff --git a/src/Shopsys/ShopBundle/Form/Admin/ProductFormTypeExtension.php b/src/Shopsys/ShopBundle/Form/Admin/ProductFormTypeExtension.php index 09fb89981..303a7ce99 100644 --- a/src/Shopsys/ShopBundle/Form/Admin/ProductFormTypeExtension.php +++ b/src/Shopsys/ShopBundle/Form/Admin/ProductFormTypeExtension.php @@ -15,6 +15,9 @@ class ProductFormTypeExtension extends AbstractTypeExtension */ private $productConditionFacade; + /** + * @param \Shopsys\ShopBundle\Model\Product\ProductConditionFacade $productConditionFacade + */ public function __construct(ProductConditionFacade $productConditionFacade) { $this->productConditionFacade = $productConditionFacade; diff --git a/src/Shopsys/ShopBundle/Form/Front/Customer/BillingAddressFormType.php b/src/Shopsys/ShopBundle/Form/Front/Customer/BillingAddressFormType.php index 0d94ed726..a5eaced31 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Customer/BillingAddressFormType.php +++ b/src/Shopsys/ShopBundle/Form/Front/Customer/BillingAddressFormType.php @@ -23,6 +23,9 @@ class BillingAddressFormType extends AbstractType */ private $countryFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Country\CountryFacade $countryFacade + */ public function __construct(CountryFacade $countryFacade) { $this->countryFacade = $countryFacade; diff --git a/src/Shopsys/ShopBundle/Form/Front/Customer/CustomerFormType.php b/src/Shopsys/ShopBundle/Form/Front/Customer/CustomerFormType.php index 41e670f39..8eefbfa1a 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Customer/CustomerFormType.php +++ b/src/Shopsys/ShopBundle/Form/Front/Customer/CustomerFormType.php @@ -15,6 +15,9 @@ class CustomerFormType extends AbstractType */ private $customerDataFactory; + /** + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerDataFactoryInterface $customerDataFactory + */ public function __construct(CustomerDataFactoryInterface $customerDataFactory) { $this->customerDataFactory = $customerDataFactory; diff --git a/src/Shopsys/ShopBundle/Form/Front/Customer/DeliveryAddressFormType.php b/src/Shopsys/ShopBundle/Form/Front/Customer/DeliveryAddressFormType.php index bf4a45def..f275974f2 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Customer/DeliveryAddressFormType.php +++ b/src/Shopsys/ShopBundle/Form/Front/Customer/DeliveryAddressFormType.php @@ -23,6 +23,9 @@ class DeliveryAddressFormType extends AbstractType */ private $countryFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Country\CountryFacade $countryFacade + */ public function __construct(CountryFacade $countryFacade) { $this->countryFacade = $countryFacade; diff --git a/src/Shopsys/ShopBundle/Form/Front/Order/DomainAwareOrderFlowFactory.php b/src/Shopsys/ShopBundle/Form/Front/Order/DomainAwareOrderFlowFactory.php index c390d5c18..0d958476b 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Order/DomainAwareOrderFlowFactory.php +++ b/src/Shopsys/ShopBundle/Form/Front/Order/DomainAwareOrderFlowFactory.php @@ -38,6 +38,10 @@ class DomainAwareOrderFlowFactory implements OrderFlowFactoryInterface /** * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + * @param \Symfony\Component\EventDispatcher\EventDispatcherInterface $eventDispatcher + * @param \Symfony\Component\HttpFoundation\RequestStack $requestStack + * @param \Symfony\Component\Form\FormFactoryInterface $formFactory + * @param \Craue\FormFlowBundle\Storage\DataManager $dataManager */ public function __construct( Domain $domain, diff --git a/src/Shopsys/ShopBundle/Form/Front/Order/OrderFlow.php b/src/Shopsys/ShopBundle/Form/Front/Order/OrderFlow.php index 333b52179..8b19f7364 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Order/OrderFlow.php +++ b/src/Shopsys/ShopBundle/Form/Front/Order/OrderFlow.php @@ -119,7 +119,7 @@ public function bind($formData) } /** - * @return StepInterface|null + * @return \Craue\FormFlowBundle\Form\StepInterface|null */ private function getFirstInvalidStep() { diff --git a/src/Shopsys/ShopBundle/Form/Front/Order/PersonalInfoFormType.php b/src/Shopsys/ShopBundle/Form/Front/Order/PersonalInfoFormType.php index 3436266e9..6388bfc56 100644 --- a/src/Shopsys/ShopBundle/Form/Front/Order/PersonalInfoFormType.php +++ b/src/Shopsys/ShopBundle/Form/Front/Order/PersonalInfoFormType.php @@ -42,6 +42,11 @@ class PersonalInfoFormType extends AbstractType */ private $domain; + /** + * @param \Shopsys\FrameworkBundle\Model\Country\CountryFacade $countryFacade + * @param \Shopsys\FrameworkBundle\Model\Heureka\HeurekaFacade $heurekaFacade + * @param \Shopsys\FrameworkBundle\Component\Domain\Domain $domain + */ public function __construct(CountryFacade $countryFacade, HeurekaFacade $heurekaFacade, Domain $domain) { $this->countryFacade = $countryFacade; diff --git a/src/Shopsys/ShopBundle/Model/AdminNavigation/SideMenuBuilder.php b/src/Shopsys/ShopBundle/Model/AdminNavigation/SideMenuBuilder.php index cbe204101..10c036052 100644 --- a/src/Shopsys/ShopBundle/Model/AdminNavigation/SideMenuBuilder.php +++ b/src/Shopsys/ShopBundle/Model/AdminNavigation/SideMenuBuilder.php @@ -7,6 +7,9 @@ class SideMenuBuilder extends BaseSideMenuBuilder { + /** + * @return \Knp\Menu\ItemInterface + */ protected function createSettingsMenu(): ItemInterface { $menu = parent::createSettingsMenu(); diff --git a/src/Shopsys/ShopBundle/Model/Category/CurrentCategoryResolver.php b/src/Shopsys/ShopBundle/Model/Category/CurrentCategoryResolver.php index 5f22d3c6a..992eb2a77 100644 --- a/src/Shopsys/ShopBundle/Model/Category/CurrentCategoryResolver.php +++ b/src/Shopsys/ShopBundle/Model/Category/CurrentCategoryResolver.php @@ -18,6 +18,10 @@ class CurrentCategoryResolver */ private $productFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Category\CategoryFacade $categoryFacade + * @param \Shopsys\FrameworkBundle\Model\Product\ProductFacade $productFacade + */ public function __construct( CategoryFacade $categoryFacade, ProductFacade $productFacade diff --git a/src/Shopsys/ShopBundle/Model/Customer/BillingAddressFacade.php b/src/Shopsys/ShopBundle/Model/Customer/BillingAddressFacade.php index 584303aab..c284e593c 100644 --- a/src/Shopsys/ShopBundle/Model/Customer/BillingAddressFacade.php +++ b/src/Shopsys/ShopBundle/Model/Customer/BillingAddressFacade.php @@ -17,6 +17,7 @@ class BillingAddressFacade protected $billingAddressRepository; /** + * @param \Doctrine\ORM\EntityManagerInterface $em * @param \Shopsys\ShopBundle\Model\Customer\BillingAddressRepository $billingAddressRepository */ public function __construct( diff --git a/src/Shopsys/ShopBundle/Model/Customer/CustomerData.php b/src/Shopsys/ShopBundle/Model/Customer/CustomerData.php index 9ad621761..d235e1de3 100644 --- a/src/Shopsys/ShopBundle/Model/Customer/CustomerData.php +++ b/src/Shopsys/ShopBundle/Model/Customer/CustomerData.php @@ -14,6 +14,11 @@ class CustomerData extends BaseCustomerData */ public $companyUsersData; + /** + * @param \Shopsys\FrameworkBundle\Model\Customer\BillingAddressData $billingAddressData + * @param \Shopsys\FrameworkBundle\Model\Customer\DeliveryAddressData $deliveryAddressData + * @param \Shopsys\FrameworkBundle\Model\Customer\UserData $userData + */ public function __construct( BillingAddressData $billingAddressData, DeliveryAddressData $deliveryAddressData, diff --git a/src/Shopsys/ShopBundle/Model/Customer/CustomerFacade.php b/src/Shopsys/ShopBundle/Model/Customer/CustomerFacade.php index 2f9825fd1..3f6688988 100644 --- a/src/Shopsys/ShopBundle/Model/Customer/CustomerFacade.php +++ b/src/Shopsys/ShopBundle/Model/Customer/CustomerFacade.php @@ -32,6 +32,8 @@ class CustomerFacade extends BaseCustomerFacade * @param \Shopsys\FrameworkBundle\Model\Customer\Mail\CustomerMailFacade $customerMailFacade * @param \Shopsys\FrameworkBundle\Model\Customer\BillingAddressFactoryInterface $billingAddressFactory * @param \Shopsys\FrameworkBundle\Model\Customer\BillingAddressDataFactoryInterface $billingAddressDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\CustomerDataFactoryInterface $customerDataFactory + * @param \Shopsys\FrameworkBundle\Model\Customer\UserFactoryInterface $userFactory */ public function __construct( EntityManagerInterface $em, diff --git a/src/Shopsys/ShopBundle/Model/Customer/Exception/DuplicateEmailsException.php b/src/Shopsys/ShopBundle/Model/Customer/Exception/DuplicateEmailsException.php index 3ba107a36..6fabe3014 100644 --- a/src/Shopsys/ShopBundle/Model/Customer/Exception/DuplicateEmailsException.php +++ b/src/Shopsys/ShopBundle/Model/Customer/Exception/DuplicateEmailsException.php @@ -13,6 +13,7 @@ class DuplicateEmailsException extends Exception implements CustomerException private $email; /** + * @param mixed $email * @param string $message * @param \Exception|null $previous */ diff --git a/src/Shopsys/ShopBundle/Model/Order/OrderDataMapper.php b/src/Shopsys/ShopBundle/Model/Order/OrderDataMapper.php index 671f58957..2a1092791 100644 --- a/src/Shopsys/ShopBundle/Model/Order/OrderDataMapper.php +++ b/src/Shopsys/ShopBundle/Model/Order/OrderDataMapper.php @@ -15,6 +15,10 @@ class OrderDataMapper extends BaseOrderDataMapper */ protected $countryFacade; + /** + * @param \Shopsys\FrameworkBundle\Model\Order\OrderDataFactoryInterface $orderDataFactory + * @param \Shopsys\ShopBundle\Model\Country\CountryFacade $countryFacade + */ public function __construct(OrderDataFactoryInterface $orderDataFactory, CountryFacade $countryFacade) { parent::__construct($orderDataFactory); @@ -41,6 +45,10 @@ public function getOrderDataFromFrontOrderData(BaseFrontOrderData $frontOrderDat return $orderData; } + /** + * @param \Shopsys\ShopBundle\Model\Order\OrderData $orderData + * @param \Shopsys\ShopBundle\Model\Order\FrontOrderData $frontOrderData + */ private function fillPickUpPlaceDeliveryData(OrderData $orderData, FrontOrderData $frontOrderData) { $orderData->deliveryFirstName = $frontOrderData->firstName; diff --git a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceFacade.php b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceFacade.php index 8b743b254..2d48d09db 100644 --- a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceFacade.php +++ b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceFacade.php @@ -29,6 +29,12 @@ class PickUpPlaceFacade */ protected $countryFacade; + /** + * @param \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlaceRepository $pickUpPlaceRepository + * @param \Doctrine\ORM\EntityManagerInterface $em + * @param \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlaceLoader $pickUpPlaceLoader + * @param \Shopsys\ShopBundle\Model\Country\CountryFacade $countryFacade + */ public function __construct( PickUpPlaceRepository $pickUpPlaceRepository, EntityManagerInterface $em, diff --git a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceIdToEntityTransformer.php b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceIdToEntityTransformer.php index 6fd33adaa..8bd49a0e9 100644 --- a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceIdToEntityTransformer.php +++ b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceIdToEntityTransformer.php @@ -12,6 +12,9 @@ class PickUpPlaceIdToEntityTransformer implements DataTransformerInterface */ protected $pickUpPlaceFacade; + /** + * @param \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlaceFacade $pickUpPlaceFacade + */ public function __construct(PickUpPlaceFacade $pickUpPlaceFacade) { $this->pickUpPlaceFacade = $pickUpPlaceFacade; @@ -19,6 +22,7 @@ public function __construct(PickUpPlaceFacade $pickUpPlaceFacade) /** * @var \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlace + * @param mixed $pickUpPlace * @return int|null */ public function transform($pickUpPlace) @@ -31,6 +35,7 @@ public function transform($pickUpPlace) /** * @var int|null + * @param mixed $pickUpPlaceId * @return null|\Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlace */ public function reverseTransform($pickUpPlaceId) diff --git a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceRepository.php b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceRepository.php index 933cc7ce3..e26269d3a 100644 --- a/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceRepository.php +++ b/src/Shopsys/ShopBundle/Model/PickUpPlace/PickUpPlaceRepository.php @@ -13,6 +13,9 @@ class PickUpPlaceRepository */ protected $em; + /** + * @param \Doctrine\ORM\EntityManagerInterface $em + */ public function __construct( EntityManagerInterface $em ) { @@ -118,6 +121,7 @@ public function deactivateAllPendingByTransportType($transportType) /** * @param string|null $searchQuery + * @param mixed $countryCodes * @param $transportType * @return \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlace[] */ diff --git a/src/Shopsys/ShopBundle/Model/Product/Feed/Google/GoogleFeedItem.php b/src/Shopsys/ShopBundle/Model/Product/Feed/Google/GoogleFeedItem.php index 4c42f372c..da6cca5c0 100644 --- a/src/Shopsys/ShopBundle/Model/Product/Feed/Google/GoogleFeedItem.php +++ b/src/Shopsys/ShopBundle/Model/Product/Feed/Google/GoogleFeedItem.php @@ -13,6 +13,20 @@ class GoogleFeedItem extends BaseGoogleFeedItem */ private $condition; + /** + * @param int $id + * @param string $name + * @param string|null $brandName + * @param string|null $description + * @param string|null $ean + * @param string|null $partno + * @param string $url + * @param string|null $imgUrl + * @param bool $sellingDenied + * @param \Shopsys\FrameworkBundle\Model\Pricing\Price $price + * @param \Shopsys\FrameworkBundle\Model\Pricing\Currency\Currency $currency + * @param string $condition + */ public function __construct( int $id, string $name, diff --git a/src/Shopsys/ShopBundle/Model/Product/Product.php b/src/Shopsys/ShopBundle/Model/Product/Product.php index 0ab7e12cc..6dcbf50b8 100644 --- a/src/Shopsys/ShopBundle/Model/Product/Product.php +++ b/src/Shopsys/ShopBundle/Model/Product/Product.php @@ -51,6 +51,7 @@ public static function createMainVariant(BaseProductData $productData, array $va /** * @param \Shopsys\FrameworkBundle\Model\Product\ProductCategoryDomainFactoryInterface $productCategoryDomainFactory + * @param \Shopsys\FrameworkBundle\Model\Product\ProductData $productData * @param \Shopsys\ShopBundle\Model\Product\ProductData */ public function edit( diff --git a/tests/ShopBundle/Acceptance/acceptance/AdminProductAdvancedSearchCest.php b/tests/ShopBundle/Acceptance/acceptance/AdminProductAdvancedSearchCest.php index ecaab2580..7320850b4 100644 --- a/tests/ShopBundle/Acceptance/acceptance/AdminProductAdvancedSearchCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/AdminProductAdvancedSearchCest.php @@ -8,6 +8,11 @@ class AdminProductAdvancedSearchCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\ProductAdvancedSearchPage $productAdvancedSearchPage + */ public function testSearchByCatnum( AcceptanceTester $me, LoginPage $loginPage, diff --git a/tests/ShopBundle/Acceptance/acceptance/AdministratorLoginCest.php b/tests/ShopBundle/Acceptance/acceptance/AdministratorLoginCest.php index 22ecd6c46..17933d02f 100644 --- a/tests/ShopBundle/Acceptance/acceptance/AdministratorLoginCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/AdministratorLoginCest.php @@ -7,12 +7,20 @@ class AdministratorLoginCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testSuccessfulLogin(AcceptanceTester $me, LoginPage $loginPage) { $me->wantTo('login on admin with valid data'); $loginPage->loginAsAdmin(); } + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testLoginWithInvalidUsername(AcceptanceTester $me, LoginPage $loginPage) { $me->wantTo('login on admin with nonexistent username'); @@ -20,6 +28,10 @@ public function testLoginWithInvalidUsername(AcceptanceTester $me, LoginPage $lo $loginPage->assertLoginFailed(); } + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testLoginWithInvalidPassword(AcceptanceTester $me, LoginPage $loginPage) { $me->wantTo('login on admin with invalid password'); diff --git a/tests/ShopBundle/Acceptance/acceptance/CartCest.php b/tests/ShopBundle/Acceptance/acceptance/CartCest.php index 51f8c8c0a..588c8b883 100644 --- a/tests/ShopBundle/Acceptance/acceptance/CartCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/CartCest.php @@ -12,6 +12,13 @@ class CartCest { + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartBoxPage $cartBoxPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\FloatingWindowPage $floatingWindowPage + */ public function testAddingSameProductToCartMakesSum( CartPage $cartPage, ProductDetailPage $productDetailPage, @@ -35,6 +42,13 @@ public function testAddingSameProductToCartMakesSum( $cartPage->assertProductQuantity('22" Sencor SLE 22F46DM4 HELLO KITTY', 6); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartBoxPage $cartBoxPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\FloatingWindowPage $floatingWindowPage + */ public function testAddToCartFromProductListPage( CartPage $cartPage, ProductListPage $productListPage, @@ -52,6 +66,13 @@ public function testAddToCartFromProductListPage( $cartPage->assertProductPrice('Defender 2.0 SPK-480', 'CZK119.00'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\HomepagePage $homepagePage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartBoxPage $cartBoxPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\FloatingWindowPage $floatingWindowPage + */ public function testAddToCartFromHomepage( CartPage $cartPage, HomepagePage $homepagePage, @@ -69,6 +90,12 @@ public function testAddToCartFromHomepage( $cartPage->assertProductPrice('22" Sencor SLE 22F46DM4 HELLO KITTY', 'CZK3,499.00'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartBoxPage $cartBoxPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\FloatingWindowPage $floatingWindowPage + */ public function testAddToCartFromProductDetail( ProductDetailPage $productDetailPage, CartBoxPage $cartBoxPage, @@ -86,6 +113,11 @@ public function testAddToCartFromProductDetail( $me->see('22" Sencor SLE 22F46DM4 HELLO KITTY'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testChangeCartItemAndRecalculatePrice( CartPage $cartPage, ProductDetailPage $productDetailPage, @@ -101,6 +133,11 @@ public function testChangeCartItemAndRecalculatePrice( $cartPage->assertTotalPriceWithVat('CZK34,990.00'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testRemovingItemsFromCart( CartPage $cartPage, ProductDetailPage $productDetailPage, @@ -124,6 +161,13 @@ public function testRemovingItemsFromCart( $me->see('Your cart is unfortunately empty.'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartBoxPage $cartBoxPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\FloatingWindowPage $floatingWindowPage + */ public function testAddingDistinctProductsToCart( CartPage $cartPage, CartBoxPage $cartBoxPage, @@ -148,6 +192,11 @@ public function testAddingDistinctProductsToCart( $cartPage->assertProductIsInCartByName('Canon PIXMA iP7250'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\CartPage $cartPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductDetailPage $productDetailPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testPricingInCart( CartPage $cartPage, ProductDetailPage $productDetailPage, diff --git a/tests/ShopBundle/Acceptance/acceptance/CustomerLoginCest.php b/tests/ShopBundle/Acceptance/acceptance/CustomerLoginCest.php index 8f3cf4cc3..90a8e2014 100644 --- a/tests/ShopBundle/Acceptance/acceptance/CustomerLoginCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/CustomerLoginCest.php @@ -8,6 +8,11 @@ class CustomerLoginCest { + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LoginPage $loginPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LayoutPage $layoutPage + */ public function testLoginAsCustomerFromMainPage( LoginPage $loginPage, AcceptanceTester $me, @@ -23,6 +28,11 @@ public function testLoginAsCustomerFromMainPage( $me->seeCurrentPageEquals('/'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LoginPage $loginPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LayoutPage $layoutPage + */ public function testLoginAsCustomerFromCategoryPage( LoginPage $loginPage, AcceptanceTester $me, @@ -38,6 +48,11 @@ public function testLoginAsCustomerFromCategoryPage( $me->seeCurrentPageEquals('/'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LoginPage $loginPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LayoutPage $layoutPage + */ public function testLoginAsCustomerFromLoginPage( LoginPage $loginPage, AcceptanceTester $me, diff --git a/tests/ShopBundle/Acceptance/acceptance/CustomerRegistrationCest.php b/tests/ShopBundle/Acceptance/acceptance/CustomerRegistrationCest.php index 1e1c77dca..b5ae4d275 100644 --- a/tests/ShopBundle/Acceptance/acceptance/CustomerRegistrationCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/CustomerRegistrationCest.php @@ -10,6 +10,11 @@ class CustomerRegistrationCest { const MINIMUM_FORM_SUBMIT_WAIT_TIME = 10; + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\RegistrationPage $registrationPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\LayoutPage $layoutPage + */ public function testSuccessfulRegistration( RegistrationPage $registrationPage, AcceptanceTester $me, @@ -25,6 +30,10 @@ public function testSuccessfulRegistration( $me->see('Log out'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\RegistrationPage $registrationPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testAlreadyUsedEmail(RegistrationPage $registrationPage, AcceptanceTester $me) { $me->wantTo('use already used email while registration'); @@ -33,6 +42,10 @@ public function testAlreadyUsedEmail(RegistrationPage $registrationPage, Accepta $registrationPage->seeEmailError('Email no-reply@shopsys.com is already registered'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\RegistrationPage $registrationPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testPasswordMismatch(RegistrationPage $registrationPage, AcceptanceTester $me) { $me->wantTo('use mismatching passwords while registration'); diff --git a/tests/ShopBundle/Acceptance/acceptance/ErrorHandlingCest.php b/tests/ShopBundle/Acceptance/acceptance/ErrorHandlingCest.php index 764c50c31..643fa2968 100644 --- a/tests/ShopBundle/Acceptance/acceptance/ErrorHandlingCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/ErrorHandlingCest.php @@ -6,6 +6,9 @@ class ErrorHandlingCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testDisplayNotice(AcceptanceTester $me) { $me->wantTo('display notice error page'); diff --git a/tests/ShopBundle/Acceptance/acceptance/LoginAsCustomerCest.php b/tests/ShopBundle/Acceptance/acceptance/LoginAsCustomerCest.php index 47404bb5d..d609ea2ec 100644 --- a/tests/ShopBundle/Acceptance/acceptance/LoginAsCustomerCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/LoginAsCustomerCest.php @@ -8,6 +8,11 @@ class LoginAsCustomerCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + * @param \Codeception\Scenario $scenario + */ public function testLoginAsCustomer(AcceptanceTester $me, LoginPage $loginPage, Scenario $scenario) { $me->wantTo('login as a customer from admin'); diff --git a/tests/ShopBundle/Acceptance/acceptance/OrderCest.php b/tests/ShopBundle/Acceptance/acceptance/OrderCest.php index 3f94f57b4..f0cbe288a 100644 --- a/tests/ShopBundle/Acceptance/acceptance/OrderCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/OrderCest.php @@ -11,6 +11,11 @@ class OrderCest { + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\OrderPage $orderPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testFormRemembersPaymentAndTransportWhenClickingBack( ProductListPage $productListPage, OrderPage $orderPage, @@ -35,6 +40,11 @@ public function testFormRemembersPaymentAndTransportWhenClickingBack( $orderPage->assertPaymentIsSelected('Cash on delivery'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\OrderPage $orderPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testFormRemembersPaymentAndTransportWhenGoingDirectlyToUrl( ProductListPage $productListPage, OrderPage $orderPage, @@ -59,6 +69,11 @@ public function testFormRemembersPaymentAndTransportWhenGoingDirectlyToUrl( $orderPage->assertPaymentIsSelected('Cash on delivery'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\OrderPage $orderPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ public function testFormRemembersFirstName(ProductListPage $productListPage, OrderPage $orderPage, AcceptanceTester $me) { $me->wantTo('have my first name remembered by order'); @@ -80,6 +95,12 @@ public function testFormRemembersFirstName(ProductListPage $productListPage, Ord $orderPage->assertFirstNameIsFilled('Jan'); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\OrderPage $orderPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Test\Codeception\Helper\SymfonyHelper $symfonyHelper + */ public function testOrderCanBeCompletedAndHasGoogleAnalyticsTrackingIdInSource( ProductListPage $productListPage, OrderPage $orderPage, @@ -103,6 +124,11 @@ private function setGoogleAnalyticsTrackingId($trackingId, ScriptFacade $scriptF $scriptFacade->setGoogleAnalyticsTrackingId($trackingId, Domain::FIRST_DOMAIN_ID); } + /** + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\OrderPage $orderPage + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + */ private function testOrderCanBeCompleted( ProductListPage $productListPage, OrderPage $orderPage, diff --git a/tests/ShopBundle/Acceptance/acceptance/PageObject/AbstractPage.php b/tests/ShopBundle/Acceptance/acceptance/PageObject/AbstractPage.php index 0afc7e26e..fc191475a 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PageObject/AbstractPage.php +++ b/tests/ShopBundle/Acceptance/acceptance/PageObject/AbstractPage.php @@ -17,6 +17,10 @@ abstract class AbstractPage */ protected $tester; + /** + * @param \Tests\ShopBundle\Test\Codeception\Module\StrictWebDriver $strictWebDriver + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $tester + */ public function __construct(StrictWebDriver $strictWebDriver, AcceptanceTester $tester) { $this->webDriver = $strictWebDriver->webDriver; diff --git a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/HomepagePage.php b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/HomepagePage.php index 4ecf9da15..27b31e542 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/HomepagePage.php +++ b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/HomepagePage.php @@ -14,6 +14,11 @@ class HomepagePage extends AbstractPage */ private $productListComponent; + /** + * @param \Tests\ShopBundle\Test\Codeception\Module\StrictWebDriver $strictWebDriver + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $tester + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListComponent $productListComponent + */ public function __construct( StrictWebDriver $strictWebDriver, AcceptanceTester $tester, diff --git a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductFilterPage.php b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductFilterPage.php index 6a28207e1..4b26756ad 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductFilterPage.php +++ b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductFilterPage.php @@ -12,6 +12,10 @@ class ProductFilterPage extends AbstractPage // Product filter waits for more requests before evaluation const PRE_EVALUATION_WAIT = 2; + /** + * @param \Tests\ShopBundle\Test\Codeception\Module\StrictWebDriver $strictWebDriver + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $tester + */ public function __construct(StrictWebDriver $strictWebDriver, AcceptanceTester $tester) { parent::__construct($strictWebDriver, $tester); diff --git a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductListPage.php b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductListPage.php index e08ba4ad1..a6afd378e 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductListPage.php +++ b/tests/ShopBundle/Acceptance/acceptance/PageObject/Front/ProductListPage.php @@ -15,6 +15,11 @@ class ProductListPage extends AbstractPage */ private $productListComponent; + /** + * @param \Tests\ShopBundle\Test\Codeception\Module\StrictWebDriver $strictWebDriver + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $tester + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListComponent $productListComponent + */ public function __construct( StrictWebDriver $strictWebDriver, AcceptanceTester $tester, diff --git a/tests/ShopBundle/Acceptance/acceptance/PaymentImageUploadCest.php b/tests/ShopBundle/Acceptance/acceptance/PaymentImageUploadCest.php index d12084d88..0b69a6a14 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PaymentImageUploadCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/PaymentImageUploadCest.php @@ -15,6 +15,11 @@ class PaymentImageUploadCest const TEST_IMAGE_NAME = 'paymentTestImage.png'; + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\EntityEditPage $entityEditPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testSuccessfulImageUpload(AcceptanceTester $me, EntityEditPage $entityEditPage, LoginPage $loginPage) { $me->wantTo('Upload an image in admin payment edit page'); diff --git a/tests/ShopBundle/Acceptance/acceptance/ProductFilterCest.php b/tests/ShopBundle/Acceptance/acceptance/ProductFilterCest.php index 405989b32..93d29c52d 100644 --- a/tests/ShopBundle/Acceptance/acceptance/ProductFilterCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/ProductFilterCest.php @@ -8,6 +8,11 @@ class ProductFilterCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductFilterPage $productFilterPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Front\ProductListPage $productListPage + */ public function testAllProductFilters( AcceptanceTester $me, ProductFilterPage $productFilterPage, diff --git a/tests/ShopBundle/Acceptance/acceptance/ProductImageUploadCest.php b/tests/ShopBundle/Acceptance/acceptance/ProductImageUploadCest.php index 3a461dafe..4ed895039 100644 --- a/tests/ShopBundle/Acceptance/acceptance/ProductImageUploadCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/ProductImageUploadCest.php @@ -15,6 +15,11 @@ class ProductImageUploadCest const TEST_IMAGE_NAME = 'productTestImage.png'; + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\EntityEditPage $entityEditPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testSuccessfulImageUpload(AcceptanceTester $me, EntityEditPage $entityEditPage, LoginPage $loginPage) { $me->wantTo('upload image in admin product edit page'); diff --git a/tests/ShopBundle/Acceptance/acceptance/PromoCodeInlineEditCest.php b/tests/ShopBundle/Acceptance/acceptance/PromoCodeInlineEditCest.php index ca80ff72e..9b926fe56 100644 --- a/tests/ShopBundle/Acceptance/acceptance/PromoCodeInlineEditCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/PromoCodeInlineEditCest.php @@ -8,6 +8,11 @@ class PromoCodeInlineEditCest { + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\InlineEditPage $inlineEditPage + */ public function testPromoCodeEdit(AcceptanceTester $me, LoginPage $loginPage, InlineEditPage $inlineEditPage) { $me->wantTo('promo code can be edited via inline edit'); @@ -21,6 +26,11 @@ public function testPromoCodeEdit(AcceptanceTester $me, LoginPage $loginPage, In $inlineEditPage->assertSeeInColumn(1, 'code', 'test edited'); } + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\InlineEditPage $inlineEditPage + */ public function testPromoCodeCreate(AcceptanceTester $me, LoginPage $loginPage, InlineEditPage $inlineEditPage) { $me->wantTo('promo code can be created via inline edit'); @@ -38,6 +48,11 @@ public function testPromoCodeCreate(AcceptanceTester $me, LoginPage $loginPage, $inlineEditPage->assertSeeInColumn($newRowId, 'percent', '5%'); } + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\InlineEditPage $inlineEditPage + */ public function testPromoCodeDelete(AcceptanceTester $me, LoginPage $loginPage, InlineEditPage $inlineEditPage) { $me->wantTo('promo code can be deleted via inline edit'); diff --git a/tests/ShopBundle/Acceptance/acceptance/TransportImageUploadCest.php b/tests/ShopBundle/Acceptance/acceptance/TransportImageUploadCest.php index ab468de68..ab526bd07 100644 --- a/tests/ShopBundle/Acceptance/acceptance/TransportImageUploadCest.php +++ b/tests/ShopBundle/Acceptance/acceptance/TransportImageUploadCest.php @@ -15,6 +15,11 @@ class TransportImageUploadCest const TEST_IMAGE_NAME = 'transportTestImage.png'; + /** + * @param \Tests\ShopBundle\Test\Codeception\AcceptanceTester $me + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\EntityEditPage $entityEditPage + * @param \Tests\ShopBundle\Acceptance\acceptance\PageObject\Admin\LoginPage $loginPage + */ public function testSuccessfulImageUpload(AcceptanceTester $me, EntityEditPage $entityEditPage, LoginPage $loginPage) { $me->wantTo('Upload an image in admin transport edit page'); diff --git a/tests/ShopBundle/Functional/Model/Customer/CustomerPasswordServiceTest.php b/tests/ShopBundle/Functional/Model/Customer/CustomerPasswordServiceTest.php index d66a5523e..7e18d3f88 100644 --- a/tests/ShopBundle/Functional/Model/Customer/CustomerPasswordServiceTest.php +++ b/tests/ShopBundle/Functional/Model/Customer/CustomerPasswordServiceTest.php @@ -48,6 +48,10 @@ public function isResetPasswordHashValidProvider() /** * @dataProvider isResetPasswordHashValidProvider + * @param mixed $resetPasswordHash + * @param mixed $resetPasswordHashValidThrough + * @param mixed $sentHash + * @param mixed $isExpectedValid */ public function testIsResetPasswordHashValid( $resetPasswordHash, diff --git a/tests/ShopBundle/Functional/Model/Order/OrderTransportAndPaymentTest.php b/tests/ShopBundle/Functional/Model/Order/OrderTransportAndPaymentTest.php index b2b1999fd..f3d56175d 100644 --- a/tests/ShopBundle/Functional/Model/Order/OrderTransportAndPaymentTest.php +++ b/tests/ShopBundle/Functional/Model/Order/OrderTransportAndPaymentTest.php @@ -373,7 +373,7 @@ public function testVisiblePaymentTransportOnDifferentDomain() * @param \Shopsys\FrameworkBundle\Model\Pricing\Vat\Vat $vat * @param bool[] $enabledForDomains * @param bool $hidden - * @return Payment + * @return \Shopsys\FrameworkBundle\Model\Payment\Payment */ public function getDefaultPayment(Vat $vat, $enabledForDomains, $hidden) { diff --git a/tests/ShopBundle/Functional/Model/Payment/IndependentPaymentVisibilityCalculationTest.php b/tests/ShopBundle/Functional/Model/Payment/IndependentPaymentVisibilityCalculationTest.php index f67052d1b..dc9e9df1c 100644 --- a/tests/ShopBundle/Functional/Model/Payment/IndependentPaymentVisibilityCalculationTest.php +++ b/tests/ShopBundle/Functional/Model/Payment/IndependentPaymentVisibilityCalculationTest.php @@ -114,7 +114,7 @@ public function testIsIndependentlyVisibleHidden() * @param \Shopsys\FrameworkBundle\Model\Pricing\Vat\Vat $vat * @param bool[] $enabledForDomains * @param bool $hidden - * @return Payment + * @return \Shopsys\FrameworkBundle\Model\Payment\Payment */ public function getDefaultPayment(Vat $vat, $enabledForDomains, $hidden) { diff --git a/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php b/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php index dff76d832..0c4b7dc00 100644 --- a/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php +++ b/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php @@ -88,6 +88,9 @@ private function createProductWithInputPriceAndVatPercentAndAutoCalculationPrice /** * @dataProvider inputPricesTestDataProvider + * @param mixed $inputPriceWithoutVat + * @param mixed $inputPriceWithVat + * @param mixed $vatPercent */ public function testOnKernelResponseRecalculateInputPricesWithoutVat( $inputPriceWithoutVat, @@ -166,6 +169,9 @@ public function testOnKernelResponseRecalculateInputPricesWithoutVat( /** * @dataProvider inputPricesTestDataProvider + * @param mixed $inputPriceWithoutVat + * @param mixed $inputPriceWithVat + * @param mixed $vatPercent */ public function testOnKernelResponseRecalculateInputPricesWithVat( $inputPriceWithoutVat, diff --git a/tests/ShopBundle/Functional/Model/Product/Availability/ProductAvailabilityCalculationTest.php b/tests/ShopBundle/Functional/Model/Product/Availability/ProductAvailabilityCalculationTest.php index 7a58b9c03..de1d64d0c 100644 --- a/tests/ShopBundle/Functional/Model/Product/Availability/ProductAvailabilityCalculationTest.php +++ b/tests/ShopBundle/Functional/Model/Product/Availability/ProductAvailabilityCalculationTest.php @@ -18,6 +18,13 @@ class ProductAvailabilityCalculationTest extends FunctionalTestCase { /** * @dataProvider getTestCalculateAvailabilityData + * @param mixed $usingStock + * @param mixed $stockQuantity + * @param mixed $outOfStockAction + * @param \Shopsys\FrameworkBundle\Model\Product\Availability\Availability|null $availability + * @param \Shopsys\FrameworkBundle\Model\Product\Availability\Availability|null $outOfStockAvailability + * @param \Shopsys\FrameworkBundle\Model\Product\Availability\Availability|null $defaultInStockAvailability + * @param \Shopsys\FrameworkBundle\Model\Product\Availability\Availability|null $expectedCalculatedAvailability */ public function testCalculateAvailability( $usingStock, diff --git a/tests/ShopBundle/Functional/Model/Product/ProductFacadeTest.php b/tests/ShopBundle/Functional/Model/Product/ProductFacadeTest.php index 883f1dd10..aac599d08 100644 --- a/tests/ShopBundle/Functional/Model/Product/ProductFacadeTest.php +++ b/tests/ShopBundle/Functional/Model/Product/ProductFacadeTest.php @@ -16,6 +16,12 @@ class ProductFacadeTest extends TransactionFunctionalTestCase { /** * @dataProvider getTestHandleOutOfStockStateDataProvider + * @param mixed $hidden + * @param mixed $sellingDenied + * @param mixed $stockQuantity + * @param mixed $outOfStockAction + * @param mixed $calculatedHidden + * @param mixed $calculatedSellingDenied */ public function testHandleOutOfStockState( $hidden, diff --git a/tests/ShopBundle/Functional/Model/Product/ProductRepositoryTest.php b/tests/ShopBundle/Functional/Model/Product/ProductRepositoryTest.php index 7380a171a..a9c800a1e 100644 --- a/tests/ShopBundle/Functional/Model/Product/ProductRepositoryTest.php +++ b/tests/ShopBundle/Functional/Model/Product/ProductRepositoryTest.php @@ -37,6 +37,10 @@ public function testProductMainVariantIsListed() $this->getAllListableQueryBuilderTest(148, true); } + /** + * @param mixed $productReferenceId + * @param mixed $isExpectedInResult + */ private function getAllListableQueryBuilderTest($productReferenceId, $isExpectedInResult) { $productRepository = $this->getContainer()->get(ProductRepository::class); @@ -78,6 +82,10 @@ public function testProductMainVariantIsNotSellable() $this->getAllSellableQueryBuilderTest(148, false); } + /** + * @param mixed $productReferenceId + * @param mixed $isExpectedInResult + */ private function getAllSellableQueryBuilderTest($productReferenceId, $isExpectedInResult) { $productRepository = $this->getContainer()->get(ProductRepository::class); @@ -119,6 +127,10 @@ public function testProductMainVariantIsOfferred() $this->getAllOfferedQueryBuilderTest(69, true); } + /** + * @param mixed $productReferenceId + * @param mixed $isExpectedInResult + */ private function getAllOfferedQueryBuilderTest($productReferenceId, $isExpectedInResult) { $productRepository = $this->getContainer()->get(ProductRepository::class); diff --git a/tests/ShopBundle/Functional/Twig/DateTimeFormatterExtensionTest.php b/tests/ShopBundle/Functional/Twig/DateTimeFormatterExtensionTest.php index b5a0d1672..745803f2c 100644 --- a/tests/ShopBundle/Functional/Twig/DateTimeFormatterExtensionTest.php +++ b/tests/ShopBundle/Functional/Twig/DateTimeFormatterExtensionTest.php @@ -23,6 +23,9 @@ public function formatDateDataProvider() /** * @dataProvider formatDateDataProvider + * @param mixed $input + * @param mixed $locale + * @param mixed $result */ public function testFormatDate($input, $locale, $result) { diff --git a/tests/ShopBundle/Functional/Twig/NumberFormatterExtensionTest.php b/tests/ShopBundle/Functional/Twig/NumberFormatterExtensionTest.php index 96d7094e9..ff68d7662 100644 --- a/tests/ShopBundle/Functional/Twig/NumberFormatterExtensionTest.php +++ b/tests/ShopBundle/Functional/Twig/NumberFormatterExtensionTest.php @@ -34,6 +34,9 @@ public function formatNumberDataProvider() /** * @dataProvider formatNumberDataProvider + * @param mixed $input + * @param mixed $locale + * @param mixed $result */ public function testFormatNumber($input, $locale, $result) { diff --git a/tests/ShopBundle/Functional/Twig/PriceExtensionTest.php b/tests/ShopBundle/Functional/Twig/PriceExtensionTest.php index a343b5e45..4f667b16a 100644 --- a/tests/ShopBundle/Functional/Twig/PriceExtensionTest.php +++ b/tests/ShopBundle/Functional/Twig/PriceExtensionTest.php @@ -93,6 +93,9 @@ public function priceFilterDataProviderMultiDomain() /** * @group singledomain * @dataProvider priceFilterDataProviderSingleDomain + * @param mixed $input + * @param mixed $domainId + * @param mixed $result */ public function testPriceFilterForSingleDomain($input, $domainId, $result) { @@ -102,6 +105,9 @@ public function testPriceFilterForSingleDomain($input, $domainId, $result) /** * @group multidomain * @dataProvider priceFilterDataProviderMultiDomain + * @param mixed $input + * @param mixed $domainId + * @param mixed $result */ public function testPriceFilterForMultiDomain($input, $domainId, $result) { @@ -110,6 +116,9 @@ public function testPriceFilterForMultiDomain($input, $domainId, $result) /** * @dataProvider priceFilterDataProvider + * @param mixed $input + * @param mixed $domainId + * @param mixed $result */ private function checkPriceFilter($input, $domainId, $result) { diff --git a/tests/ShopBundle/Performance/Feed/PerformanceResultsCsvExporter.php b/tests/ShopBundle/Performance/Feed/PerformanceResultsCsvExporter.php index b23311a33..13c094350 100644 --- a/tests/ShopBundle/Performance/Feed/PerformanceResultsCsvExporter.php +++ b/tests/ShopBundle/Performance/Feed/PerformanceResultsCsvExporter.php @@ -11,6 +11,9 @@ class PerformanceResultsCsvExporter */ private $jmeterCsvReporter; + /** + * @param \Tests\ShopBundle\Performance\JmeterCsvReporter $jmeterCsvReporter + */ public function __construct(JmeterCsvReporter $jmeterCsvReporter) { $this->jmeterCsvReporter = $jmeterCsvReporter; diff --git a/tests/ShopBundle/Performance/Page/PerformanceResultsCsvExporter.php b/tests/ShopBundle/Performance/Page/PerformanceResultsCsvExporter.php index 592ba3220..a8ad3e3ee 100644 --- a/tests/ShopBundle/Performance/Page/PerformanceResultsCsvExporter.php +++ b/tests/ShopBundle/Performance/Page/PerformanceResultsCsvExporter.php @@ -11,6 +11,9 @@ class PerformanceResultsCsvExporter */ private $jmeterCsvReporter; + /** + * @param \Tests\ShopBundle\Performance\JmeterCsvReporter $jmeterCsvReporter + */ public function __construct(JmeterCsvReporter $jmeterCsvReporter) { $this->jmeterCsvReporter = $jmeterCsvReporter; diff --git a/tests/ShopBundle/Performance/Page/PerformanceTestSummaryPrinter.php b/tests/ShopBundle/Performance/Page/PerformanceTestSummaryPrinter.php index c72f48c16..b8bf37bb1 100644 --- a/tests/ShopBundle/Performance/Page/PerformanceTestSummaryPrinter.php +++ b/tests/ShopBundle/Performance/Page/PerformanceTestSummaryPrinter.php @@ -11,6 +11,9 @@ class PerformanceTestSummaryPrinter */ private $performanceTestSampleQualifier; + /** + * @param \Tests\ShopBundle\Performance\Page\PerformanceTestSampleQualifier $performanceTestSampleQualifier + */ public function __construct(PerformanceTestSampleQualifier $performanceTestSampleQualifier) { $this->performanceTestSampleQualifier = $performanceTestSampleQualifier; diff --git a/tests/ShopBundle/Smoke/NewProductTest.php b/tests/ShopBundle/Smoke/NewProductTest.php index e3e5a90bc..1bfb9a901 100644 --- a/tests/ShopBundle/Smoke/NewProductTest.php +++ b/tests/ShopBundle/Smoke/NewProductTest.php @@ -19,6 +19,7 @@ public function createOrEditProductProvider() /** * @dataProvider createOrEditProductProvider + * @param mixed $relativeUrl */ public function testCreateOrEditProduct($relativeUrl) { diff --git a/tests/ShopBundle/Test/Codeception/Module/StrictWebDriver.php b/tests/ShopBundle/Test/Codeception/Module/StrictWebDriver.php index 5572e7879..e8bfdc9ea 100644 --- a/tests/ShopBundle/Test/Codeception/Module/StrictWebDriver.php +++ b/tests/ShopBundle/Test/Codeception/Module/StrictWebDriver.php @@ -55,6 +55,8 @@ protected function findFields($selector) /** * @deprecated + * @param mixed $link + * @param mixed|null $context */ public function click($link, $context = null) { @@ -67,6 +69,8 @@ public function click($link, $context = null) /** * @see click() + * @param mixed $link + * @param mixed|null $context */ private function clickAndWait($link, $context = null) { @@ -129,6 +133,8 @@ public function clickByElement(WebDriverElement $element) /** * @deprecated + * @param mixed $field + * @param mixed $value */ public function fillField($field, $value) { @@ -190,6 +196,7 @@ public function seeInElement($text, WebDriverElement $element) /** * @deprecated + * @param mixed $checkbox */ public function seeCheckboxIsChecked($checkbox) { @@ -236,6 +243,7 @@ public function seeCheckboxIsCheckedByLabel($label) /** * @deprecated + * @param mixed $checkbox */ public function dontSeeCheckboxIsChecked($checkbox) { @@ -282,6 +290,7 @@ public function dontSeeCheckboxIsCheckedByLabel($label) /** * @deprecated + * @param mixed $option */ public function checkOption($option) { @@ -347,6 +356,8 @@ public function countVisibleByCss($css) /** * @deprecated + * @param mixed $field + * @param mixed $value */ public function seeInField($field, $value) { @@ -390,6 +401,8 @@ public function moveMouseOverByCss($css, $offsetX = null, $offsetY = null) /** * @deprecated + * @param mixed $element + * @param mixed $char */ public function pressKey($element, $char) { From 4b5739da78055cdcc1f3210ca0a5c563b3e1b11d Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 11:21:37 +0100 Subject: [PATCH 07/19] dependencies on shopsys packages updated to beta3 version --- composer.json | 18 +- composer.lock | 487 ++++++++++++++++++++++++-------------------- migrations-lock.yml | 15 ++ 3 files changed, 292 insertions(+), 228 deletions(-) diff --git a/composer.json b/composer.json index 5166dd89a..b1a20bbb0 100644 --- a/composer.json +++ b/composer.json @@ -68,15 +68,15 @@ "sensio/framework-extra-bundle": "^3.0.29", "sensio/generator-bundle": "^3.1.7", "shopsys/doctrine-orm": "2.6.2", - "shopsys/migrations": "v7.0.0-beta2", - "shopsys/form-types-bundle": "v7.0.0-beta2", - "shopsys/framework": "v7.0.0-beta2", - "shopsys/plugin-interface": "v7.0.0-beta2", + "shopsys/migrations": "v7.0.0-beta3", + "shopsys/form-types-bundle": "v7.0.0-beta3", + "shopsys/framework": "v7.0.0-beta3", + "shopsys/plugin-interface": "v7.0.0-beta3", "shopsys/postgres-search-bundle": "0.1", - "shopsys/product-feed-heureka": "v7.0.0-beta2", - "shopsys/product-feed-heureka-delivery": "v7.0.0-beta2", - "shopsys/product-feed-zbozi": "v7.0.0-beta2", - "shopsys/product-feed-google": "v7.0.0-beta2", + "shopsys/product-feed-heureka": "v7.0.0-beta3", + "shopsys/product-feed-heureka-delivery": "v7.0.0-beta3", + "shopsys/product-feed-zbozi": "v7.0.0-beta3", + "shopsys/product-feed-google": "v7.0.0-beta3", "snc/redis-bundle": "2.1.4", "stof/doctrine-extensions-bundle": "^1.3.0", "symfony/assetic-bundle": "^2.8.2", @@ -97,7 +97,7 @@ "phpstan/phpstan": "^0.7", "phpunit/phpunit": "^7.0", "shopsys/coding-standards": "v7.0.0-beta3", - "shopsys/http-smoke-testing": "v7.0.0-beta2" + "shopsys/http-smoke-testing": "v7.0.0-beta3" }, "conflict": { "symfony/dependency-injection": "3.4.15|3.4.16" diff --git a/composer.lock b/composer.lock index 06c7d4736..060a9e248 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "863b8b209c12a9d014f128e6d26911c2", + "content-hash": "90feccfe2e603fe0356b342474c49483", "packages": [ { "name": "arvenil/ninja-mutex", @@ -600,16 +600,16 @@ }, { "name": "composer/composer", - "version": "1.7.3", + "version": "1.8.0", "source": { "type": "git", "url": "https://github.com/composer/composer.git", - "reference": "e965b9aaa8854c3067f1ed2ae45f436572d73eb7" + "reference": "d8aef3af866b28786ce9b8647e52c42496436669" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/e965b9aaa8854c3067f1ed2ae45f436572d73eb7", - "reference": "e965b9aaa8854c3067f1ed2ae45f436572d73eb7", + "url": "https://api.github.com/repos/composer/composer/zipball/d8aef3af866b28786ce9b8647e52c42496436669", + "reference": "d8aef3af866b28786ce9b8647e52c42496436669", "shasum": "" }, "require": { @@ -645,7 +645,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.7-dev" + "dev-master": "1.8-dev" } }, "autoload": { @@ -676,7 +676,7 @@ "dependency", "package" ], - "time": "2018-11-01T09:05:06+00:00" + "time": "2018-12-03T09:31:16+00:00" }, { "name": "composer/semver", @@ -803,16 +803,16 @@ }, { "name": "composer/xdebug-handler", - "version": "1.3.0", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "b8e9745fb9b06ea6664d8872c4505fb16df4611c" + "reference": "dc523135366eb68f22268d069ea7749486458562" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/b8e9745fb9b06ea6664d8872c4505fb16df4611c", - "reference": "b8e9745fb9b06ea6664d8872c4505fb16df4611c", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/dc523135366eb68f22268d069ea7749486458562", + "reference": "dc523135366eb68f22268d069ea7749486458562", "shasum": "" }, "require": { @@ -843,7 +843,7 @@ "Xdebug", "performance" ], - "time": "2018-08-31T19:07:57+00:00" + "time": "2018-11-29T10:59:02+00:00" }, { "name": "craue/formflow-bundle", @@ -1123,16 +1123,16 @@ }, { "name": "doctrine/common", - "version": "v2.9.0", + "version": "v2.10.0", "source": { "type": "git", "url": "https://github.com/doctrine/common.git", - "reference": "a210246d286c77d2b89040f8691ba7b3a713d2c1" + "reference": "30e33f60f64deec87df728c02b107f82cdafad9d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/a210246d286c77d2b89040f8691ba7b3a713d2c1", - "reference": "a210246d286c77d2b89040f8691ba7b3a713d2c1", + "url": "https://api.github.com/repos/doctrine/common/zipball/30e33f60f64deec87df728c02b107f82cdafad9d", + "reference": "30e33f60f64deec87df728c02b107f82cdafad9d", "shasum": "" }, "require": { @@ -1142,7 +1142,7 @@ "doctrine/event-manager": "^1.0", "doctrine/inflector": "^1.0", "doctrine/lexer": "^1.0", - "doctrine/persistence": "^1.0", + "doctrine/persistence": "^1.1", "doctrine/reflection": "^1.0", "php": "^7.1" }, @@ -1155,7 +1155,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.9.x-dev" + "dev-master": "2.10.x-dev" } }, "autoload": { @@ -1193,16 +1193,14 @@ "email": "ocramius@gmail.com" } ], - "description": "Common Library for Doctrine projects", - "homepage": "https://www.doctrine-project.org", + "description": "PHP Doctrine Common project is a library that provides additional functionality that other Doctrine projects depend on such as better reflection support, persistence interfaces, proxies, event system and much more.", + "homepage": "https://www.doctrine-project.org/projects/common.html", "keywords": [ - "annotations", - "collections", - "eventmanager", - "persistence", - "spl" + "common", + "doctrine", + "php" ], - "time": "2018-07-12T21:16:12+00:00" + "time": "2018-11-21T01:24:55+00:00" }, { "name": "doctrine/data-fixtures", @@ -1266,16 +1264,16 @@ }, { "name": "doctrine/dbal", - "version": "v2.8.0", + "version": "v2.9.0", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "5140a64c08b4b607b9bedaae0cedd26f04a0e621" + "reference": "21fdabe2fc01e004e1966f200d900554876bc63c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/5140a64c08b4b607b9bedaae0cedd26f04a0e621", - "reference": "5140a64c08b4b607b9bedaae0cedd26f04a0e621", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/21fdabe2fc01e004e1966f200d900554876bc63c", + "reference": "21fdabe2fc01e004e1966f200d900554876bc63c", "shasum": "" }, "require": { @@ -1285,11 +1283,10 @@ "php": "^7.1" }, "require-dev": { - "doctrine/coding-standard": "^4.0", + "doctrine/coding-standard": "^5.0", "jetbrains/phpstorm-stubs": "^2018.1.2", "phpstan/phpstan": "^0.10.1", - "phpunit/phpunit": "^7.1.2", - "phpunit/phpunit-mock-objects": "!=3.2.4,!=3.2.5", + "phpunit/phpunit": "^7.4", "symfony/console": "^2.0.5|^3.0|^4.0", "symfony/phpunit-bridge": "^3.4.5|^4.0.5" }, @@ -1302,13 +1299,13 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8.x-dev", + "dev-master": "2.9.x-dev", "dev-develop": "3.0.x-dev" } }, "autoload": { - "psr-0": { - "Doctrine\\DBAL\\": "lib/" + "psr-4": { + "Doctrine\\DBAL\\": "lib/Doctrine/DBAL" } }, "notification-url": "https://packagist.org/downloads/", @@ -1333,28 +1330,32 @@ "email": "jonwage@gmail.com" } ], - "description": "Database Abstraction Layer", - "homepage": "http://www.doctrine-project.org", + "description": "Powerful PHP database abstraction layer (DBAL) with many features for database schema introspection and management.", + "homepage": "https://www.doctrine-project.org/projects/dbal.html", "keywords": [ + "abstraction", "database", "dbal", + "mysql", "persistence", + "pgsql", + "php", "queryobject" ], - "time": "2018-07-13T03:16:35+00:00" + "time": "2018-12-04T04:39:48+00:00" }, { "name": "doctrine/doctrine-bundle", - "version": "1.9.1", + "version": "1.10.0", "source": { "type": "git", "url": "https://github.com/doctrine/DoctrineBundle.git", - "reference": "703fad32e4c8cbe609caf45a71a1d4266c830f0f" + "reference": "82d2c63cd09acbde2332f55d9aa7b28aefe4983d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/DoctrineBundle/zipball/703fad32e4c8cbe609caf45a71a1d4266c830f0f", - "reference": "703fad32e4c8cbe609caf45a71a1d4266c830f0f", + "url": "https://api.github.com/repos/doctrine/DoctrineBundle/zipball/82d2c63cd09acbde2332f55d9aa7b28aefe4983d", + "reference": "82d2c63cd09acbde2332f55d9aa7b28aefe4983d", "shasum": "" }, "require": { @@ -1372,8 +1373,8 @@ }, "require-dev": { "doctrine/orm": "~2.4", + "php-coveralls/php-coveralls": "^2.1", "phpunit/phpunit": "^4.8.36|^5.7|^6.4", - "satooshi/php-coveralls": "^1.0", "symfony/phpunit-bridge": "~2.7|~3.0|~4.0", "symfony/property-info": "~2.8|~3.0|~4.0", "symfony/validator": "~2.7|~3.0|~4.0", @@ -1388,7 +1389,7 @@ "type": "symfony-bundle", "extra": { "branch-alias": { - "dev-master": "1.8.x-dev" + "dev-master": "1.9.x-dev" } }, "autoload": { @@ -1426,7 +1427,7 @@ "orm", "persistence" ], - "time": "2018-04-19T14:07:39+00:00" + "time": "2018-11-30T13:53:17+00:00" }, { "name": "doctrine/doctrine-cache-bundle", @@ -1521,16 +1522,16 @@ }, { "name": "doctrine/doctrine-fixtures-bundle", - "version": "3.0.2", + "version": "3.0.4", "source": { "type": "git", "url": "https://github.com/doctrine/DoctrineFixturesBundle.git", - "reference": "7fc29d2b18c61ed99826b21fbfd1ff9969cc2e7f" + "reference": "0438f8dd0a21bc5325c6be3ae0a09131815e10d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/DoctrineFixturesBundle/zipball/7fc29d2b18c61ed99826b21fbfd1ff9969cc2e7f", - "reference": "7fc29d2b18c61ed99826b21fbfd1ff9969cc2e7f", + "url": "https://api.github.com/repos/doctrine/DoctrineFixturesBundle/zipball/0438f8dd0a21bc5325c6be3ae0a09131815e10d4", + "reference": "0438f8dd0a21bc5325c6be3ae0a09131815e10d4", "shasum": "" }, "require": { @@ -1541,7 +1542,8 @@ "symfony/framework-bundle": "^3.3|^4.0" }, "require-dev": { - "symfony/phpunit-bridge": "^3.3" + "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^7.4", + "symfony/phpunit-bridge": "^3.4 || ^4.0" }, "type": "symfony-bundle", "extra": { @@ -1578,20 +1580,20 @@ "Fixture", "persistence" ], - "time": "2017-12-04T20:26:38+00:00" + "time": "2018-11-26T19:40:34+00:00" }, { "name": "doctrine/doctrine-migrations-bundle", - "version": "v1.3.1", + "version": "v1.3.2", "source": { "type": "git", "url": "https://github.com/doctrine/DoctrineMigrationsBundle.git", - "reference": "a9e506369f931351a2a6dd2aef588a822802b1b7" + "reference": "49fa399181db4bf4f9f725126bd1cb65c4398dce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/DoctrineMigrationsBundle/zipball/a9e506369f931351a2a6dd2aef588a822802b1b7", - "reference": "a9e506369f931351a2a6dd2aef588a822802b1b7", + "url": "https://api.github.com/repos/doctrine/DoctrineMigrationsBundle/zipball/49fa399181db4bf4f9f725126bd1cb65c4398dce", + "reference": "49fa399181db4bf4f9f725126bd1cb65c4398dce", "shasum": "" }, "require": { @@ -1601,7 +1603,7 @@ "symfony/framework-bundle": "~2.7|~3.3|~4.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.36" + "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^7.4" }, "type": "symfony-bundle", "extra": { @@ -1639,7 +1641,7 @@ "migrations", "schema" ], - "time": "2017-11-01T09:13:26+00:00" + "time": "2018-12-03T11:55:33+00:00" }, { "name": "doctrine/event-manager", @@ -1966,16 +1968,16 @@ }, { "name": "doctrine/persistence", - "version": "v1.0.1", + "version": "v1.1.0", "source": { "type": "git", "url": "https://github.com/doctrine/persistence.git", - "reference": "af1ec238659a83e320f03e0e454e200f689b4b97" + "reference": "c0f1c17602afc18b4cbd8e1c8125f264c9cf7d38" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/persistence/zipball/af1ec238659a83e320f03e0e454e200f689b4b97", - "reference": "af1ec238659a83e320f03e0e454e200f689b4b97", + "url": "https://api.github.com/repos/doctrine/persistence/zipball/c0f1c17602afc18b4cbd8e1c8125f264c9cf7d38", + "reference": "c0f1c17602afc18b4cbd8e1c8125f264c9cf7d38", "shasum": "" }, "require": { @@ -1987,17 +1989,17 @@ "php": "^7.1" }, "conflict": { - "doctrine/common": "<2.9@dev" + "doctrine/common": "<2.10@dev" }, "require-dev": { - "doctrine/coding-standard": "^4.0", + "doctrine/coding-standard": "^5.0", "phpstan/phpstan": "^0.8", "phpunit/phpunit": "^7.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.1.x-dev" } }, "autoload": { @@ -2035,12 +2037,16 @@ "email": "ocramius@gmail.com" } ], - "description": "Doctrine Persistence abstractions.", + "description": "The Doctrine Persistence project is a set of shared interfaces and functionality that the different Doctrine object mappers share.", "homepage": "https://doctrine-project.org/projects/persistence.html", "keywords": [ + "mapper", + "object", + "odm", + "orm", "persistence" ], - "time": "2018-07-12T12:37:50+00:00" + "time": "2018-11-21T00:33:13+00:00" }, { "name": "doctrine/reflection", @@ -2230,16 +2236,16 @@ }, { "name": "egulias/email-validator", - "version": "2.1.6", + "version": "2.1.7", "source": { "type": "git", "url": "https://github.com/egulias/EmailValidator.git", - "reference": "0578b32b30b22de3e8664f797cf846fc9246f786" + "reference": "709f21f92707308cdf8f9bcfa1af4cb26586521e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/0578b32b30b22de3e8664f797cf846fc9246f786", - "reference": "0578b32b30b22de3e8664f797cf846fc9246f786", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/709f21f92707308cdf8f9bcfa1af4cb26586521e", + "reference": "709f21f92707308cdf8f9bcfa1af4cb26586521e", "shasum": "" }, "require": { @@ -2283,7 +2289,7 @@ "validation", "validator" ], - "time": "2018-09-25T20:47:26+00:00" + "time": "2018-12-04T22:38:24+00:00" }, { "name": "fig/link-util", @@ -2661,32 +2667,33 @@ }, { "name": "guzzlehttp/psr7", - "version": "1.4.2", + "version": "1.5.2", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "f5b8a8512e2b58b0071a7280e39f14f72e05d87c" + "reference": "9f83dded91781a01c63574e387eaa769be769115" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/f5b8a8512e2b58b0071a7280e39f14f72e05d87c", - "reference": "f5b8a8512e2b58b0071a7280e39f14f72e05d87c", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/9f83dded91781a01c63574e387eaa769be769115", + "reference": "9f83dded91781a01c63574e387eaa769be769115", "shasum": "" }, "require": { "php": ">=5.4.0", - "psr/http-message": "~1.0" + "psr/http-message": "~1.0", + "ralouphie/getallheaders": "^2.0.5" }, "provide": { "psr/http-message-implementation": "1.0" }, "require-dev": { - "phpunit/phpunit": "~4.0" + "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4-dev" + "dev-master": "1.5-dev" } }, "autoload": { @@ -2716,13 +2723,14 @@ "keywords": [ "http", "message", + "psr-7", "request", "response", "stream", "uri", "url" ], - "time": "2017-03-20T17:10:46+00:00" + "time": "2018-12-04T20:46:45+00:00" }, { "name": "helios-ag/fm-elfinder-bundle", @@ -3516,16 +3524,16 @@ }, { "name": "league/flysystem", - "version": "1.0.48", + "version": "1.0.49", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "a6ded5b2f6055e2db97b4b859fdfca2b952b78aa" + "reference": "a63cc83d8a931b271be45148fa39ba7156782ffd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/a6ded5b2f6055e2db97b4b859fdfca2b952b78aa", - "reference": "a6ded5b2f6055e2db97b4b859fdfca2b952b78aa", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/a63cc83d8a931b271be45148fa39ba7156782ffd", + "reference": "a63cc83d8a931b271be45148fa39ba7156782ffd", "shasum": "" }, "require": { @@ -3596,7 +3604,7 @@ "sftp", "storage" ], - "time": "2018-10-15T13:53:10+00:00" + "time": "2018-11-23T23:41:29+00:00" }, { "name": "league/flysystem-cached-adapter", @@ -3894,16 +3902,16 @@ }, { "name": "oneup/flysystem-bundle", - "version": "3.0.2", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/1up-lab/OneupFlysystemBundle.git", - "reference": "7dd3413d4b87779df489039c025d9cf5ffbd814a" + "reference": "f144242c765e4d3e0a20551f71e76b33cc0a2c0f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/1up-lab/OneupFlysystemBundle/zipball/7dd3413d4b87779df489039c025d9cf5ffbd814a", - "reference": "7dd3413d4b87779df489039c025d9cf5ffbd814a", + "url": "https://api.github.com/repos/1up-lab/OneupFlysystemBundle/zipball/f144242c765e4d3e0a20551f71e76b33cc0a2c0f", + "reference": "f144242c765e4d3e0a20551f71e76b33cc0a2c0f", "shasum": "" }, "require": { @@ -3983,7 +3991,7 @@ "abstraction", "filesystem" ], - "time": "2018-01-17T13:19:31+00:00" + "time": "2018-12-03T08:14:22+00:00" }, { "name": "paragonie/random_compat", @@ -4496,16 +4504,16 @@ }, { "name": "psr/log", - "version": "1.0.2", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d" + "reference": "6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", - "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", + "url": "https://api.github.com/repos/php-fig/log/zipball/6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd", + "reference": "6c001f1daafa3a3ac1d8ff69ee4db8e799a654dd", "shasum": "" }, "require": { @@ -4539,7 +4547,7 @@ "psr", "psr-3" ], - "time": "2016-10-10T12:19:37+00:00" + "time": "2018-11-20T15:27:04+00:00" }, { "name": "psr/simple-cache", @@ -4589,6 +4597,46 @@ ], "time": "2017-10-23T01:57:42+00:00" }, + { + "name": "ralouphie/getallheaders", + "version": "2.0.5", + "source": { + "type": "git", + "url": "https://github.com/ralouphie/getallheaders.git", + "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/5601c8a83fbba7ef674a7369456d12f1e0d0eafa", + "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa", + "shasum": "" + }, + "require": { + "php": ">=5.3" + }, + "require-dev": { + "phpunit/phpunit": "~3.7.0", + "satooshi/php-coveralls": ">=1.0" + }, + "type": "library", + "autoload": { + "files": [ + "src/getallheaders.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "description": "A polyfill for getallheaders.", + "time": "2016-02-11T07:05:27+00:00" + }, { "name": "robloach/component-installer", "version": "0.2.3", @@ -5039,16 +5087,16 @@ }, { "name": "shopsys/form-types-bundle", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/form-types-bundle.git", - "reference": "9adef4126744c00a73c87ea17bbc89e414406d29" + "reference": "bc0b7335b4f5292fb2abbe351b2755e4d642902b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/form-types-bundle/zipball/9adef4126744c00a73c87ea17bbc89e414406d29", - "reference": "9adef4126744c00a73c87ea17bbc89e414406d29", + "url": "https://api.github.com/repos/shopsys/form-types-bundle/zipball/bc0b7335b4f5292fb2abbe351b2755e4d642902b", + "reference": "bc0b7335b4f5292fb2abbe351b2755e4d642902b", "shasum": "" }, "require": { @@ -5065,7 +5113,7 @@ "symfony/dependency-injection": "3.4.15|3.4.16" }, "require-dev": { - "shopsys/coding-standards": "7.0.0-beta2" + "shopsys/coding-standards": "7.0.0-beta3" }, "type": "library", "autoload": { @@ -5090,20 +5138,20 @@ "Shopsys Framework", "form" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/framework", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/framework.git", - "reference": "88d5cecf9627e5aa78cd7cd547740cdda49b0fe4" + "reference": "7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/framework/zipball/88d5cecf9627e5aa78cd7cd547740cdda49b0fe4", - "reference": "88d5cecf9627e5aa78cd7cd547740cdda49b0fe4", + "url": "https://api.github.com/repos/shopsys/framework/zipball/7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5", + "reference": "7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5", "shasum": "" }, "require": { @@ -5111,6 +5159,7 @@ "bmatzner/jquery-bundle": "^2.2.2", "bmatzner/jquery-ui-bundle": "^1.10.3", "commerceguys/intl": "0.7.4", + "composer/composer": "^1.6.0", "craue/formflow-bundle": "^3.0.3", "doctrine/annotations": "^1.6", "doctrine/cache": "^1.7", @@ -5156,11 +5205,11 @@ "psr/log": "^1.0", "sensio/distribution-bundle": "^5.0.21", "sensio/framework-extra-bundle": "^3.0.29", - "shopsys/doctrine-orm": "2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta2", + "shopsys/doctrine-orm": "^2.6.2", + "shopsys/form-types-bundle": "7.0.0-beta3", "shopsys/jparser": "0.1", - "shopsys/migrations": "7.0.0-beta2", - "shopsys/plugin-interface": "7.0.0-beta2", + "shopsys/migrations": "7.0.0-beta3", + "shopsys/plugin-interface": "7.0.0-beta3", "shopsys/postgres-search-bundle": "0.1", "snc/redis-bundle": "2.1.4", "stof/doctrine-extensions-bundle": "^1.3.0", @@ -5180,7 +5229,7 @@ "require-dev": { "phpstan/phpstan": "^0.7", "phpunit/phpunit": "^7.0", - "shopsys/coding-standards": "7.0.0-beta2" + "shopsys/coding-standards": "7.0.0-beta3" }, "suggest": { "ext-pgsql": "Required for dumping the Postgres database in shopsys:database:dump command" @@ -5200,7 +5249,7 @@ "proprietary" ], "description": "Core of Shopsys Framework - open source framework for building large, scalable, fast-growing e-commerce projects based on Symfony", - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/jparser", @@ -5244,16 +5293,16 @@ }, { "name": "shopsys/migrations", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/migrations.git", - "reference": "5732c5a0b6638593630970d88e68c5c705614f40" + "reference": "e53243cf0132c82fd38c444d1275169693d27b64" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/migrations/zipball/5732c5a0b6638593630970d88e68c5c705614f40", - "reference": "5732c5a0b6638593630970d88e68c5c705614f40", + "url": "https://api.github.com/repos/shopsys/migrations/zipball/e53243cf0132c82fd38c444d1275169693d27b64", + "reference": "e53243cf0132c82fd38c444d1275169693d27b64", "shasum": "" }, "require": { @@ -5276,7 +5325,7 @@ }, "require-dev": { "phpunit/phpunit": "^5.7|^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta2" + "shopsys/coding-standards": "7.0.0-beta3" }, "type": "library", "autoload": { @@ -5303,20 +5352,20 @@ "orm", "schema" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/plugin-interface", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/plugin-interface.git", - "reference": "a0ab73e8d22b413bb90189562046f172e5dd197c" + "reference": "215e1431ff2cb45d899ad5fba4fef14f9eda9d87" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/plugin-interface/zipball/a0ab73e8d22b413bb90189562046f172e5dd197c", - "reference": "a0ab73e8d22b413bb90189562046f172e5dd197c", + "url": "https://api.github.com/repos/shopsys/plugin-interface/zipball/215e1431ff2cb45d899ad5fba4fef14f9eda9d87", + "reference": "215e1431ff2cb45d899ad5fba4fef14f9eda9d87", "shasum": "" }, "require": { @@ -5324,7 +5373,7 @@ "symfony/monolog-bridge": "^3.0.0" }, "require-dev": { - "shopsys/coding-standards": "7.0.0-beta2" + "shopsys/coding-standards": "7.0.0-beta3" }, "type": "library", "autoload": { @@ -5348,7 +5397,7 @@ "Shopsys Framework", "plugin" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/postgres-search-bundle", @@ -5398,16 +5447,16 @@ }, { "name": "shopsys/product-feed-google", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-google.git", - "reference": "fa0197e6b9227175fcb7952b1c48482125753a45" + "reference": "17495ea17a33e4a9aad7f880c318d9d4465b0781" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-google/zipball/fa0197e6b9227175fcb7952b1c48482125753a45", - "reference": "fa0197e6b9227175fcb7952b1c48482125753a45", + "url": "https://api.github.com/repos/shopsys/product-feed-google/zipball/17495ea17a33e4a9aad7f880c318d9d4465b0781", + "reference": "17495ea17a33e4a9aad7f880c318d9d4465b0781", "shasum": "" }, "require": { @@ -5416,11 +5465,11 @@ "ext-json": "*", "ext-pdo": "*", "php": "^7.1", - "shopsys/doctrine-orm": "2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta2", - "shopsys/framework": "7.0.0-beta2", - "shopsys/migrations": "7.0.0-beta2", - "shopsys/plugin-interface": "7.0.0-beta2", + "shopsys/doctrine-orm": "^2.6.2", + "shopsys/form-types-bundle": "7.0.0-beta3", + "shopsys/framework": "7.0.0-beta3", + "shopsys/migrations": "7.0.0-beta3", + "shopsys/plugin-interface": "7.0.0-beta3", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5428,7 +5477,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta2", + "shopsys/coding-standards": "7.0.0-beta3", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5457,20 +5506,20 @@ "plugin", "product feed" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/product-feed-heureka", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-heureka.git", - "reference": "7940715dbb800a18215ac9a375013580a55c67a3" + "reference": "2d0b987e62207060527ae41dcea2fedd7ea06f6c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-heureka/zipball/7940715dbb800a18215ac9a375013580a55c67a3", - "reference": "7940715dbb800a18215ac9a375013580a55c67a3", + "url": "https://api.github.com/repos/shopsys/product-feed-heureka/zipball/2d0b987e62207060527ae41dcea2fedd7ea06f6c", + "reference": "2d0b987e62207060527ae41dcea2fedd7ea06f6c", "shasum": "" }, "require": { @@ -5482,11 +5531,11 @@ "ext-pdo": "*", "ext-simplexml": "*", "php": "^7.1", - "shopsys/doctrine-orm": "2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta2", - "shopsys/framework": "7.0.0-beta2", - "shopsys/migrations": "7.0.0-beta2", - "shopsys/plugin-interface": "7.0.0-beta2", + "shopsys/doctrine-orm": "^2.6.2", + "shopsys/form-types-bundle": "7.0.0-beta3", + "shopsys/framework": "7.0.0-beta3", + "shopsys/migrations": "7.0.0-beta3", + "shopsys/plugin-interface": "7.0.0-beta3", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5494,7 +5543,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta2", + "shopsys/coding-standards": "7.0.0-beta3", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5523,29 +5572,29 @@ "plugin", "product feed" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/product-feed-heureka-delivery", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-heureka-delivery.git", - "reference": "e5633990cae0de9fa983963659440c356f624cd6" + "reference": "35c4300ab238b98db228857e2fa481cf797d2fa6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-heureka-delivery/zipball/e5633990cae0de9fa983963659440c356f624cd6", - "reference": "e5633990cae0de9fa983963659440c356f624cd6", + "url": "https://api.github.com/repos/shopsys/product-feed-heureka-delivery/zipball/35c4300ab238b98db228857e2fa481cf797d2fa6", + "reference": "35c4300ab238b98db228857e2fa481cf797d2fa6", "shasum": "" }, "require": { "php": "^7.1", - "shopsys/doctrine-orm": "2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta2", - "shopsys/framework": "7.0.0-beta2", - "shopsys/migrations": "7.0.0-beta2", - "shopsys/plugin-interface": "7.0.0-beta2", + "shopsys/doctrine-orm": "^2.6.2", + "shopsys/form-types-bundle": "7.0.0-beta3", + "shopsys/framework": "7.0.0-beta3", + "shopsys/migrations": "7.0.0-beta3", + "shopsys/plugin-interface": "7.0.0-beta3", "symfony/config": "^3.4", "symfony/dependency-injection": "^3.4", "symfony/framework-bundle": "^3.4", @@ -5556,7 +5605,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta2", + "shopsys/coding-standards": "7.0.0-beta3", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5585,20 +5634,20 @@ "plugin", "product delivery feed" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "shopsys/product-feed-zbozi", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-zbozi.git", - "reference": "a86874c9c2a2b0e932890ea8d9727780cea8df77" + "reference": "3b09a73a9900319caaf461210e6aedc99ecc712f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-zbozi/zipball/a86874c9c2a2b0e932890ea8d9727780cea8df77", - "reference": "a86874c9c2a2b0e932890ea8d9727780cea8df77", + "url": "https://api.github.com/repos/shopsys/product-feed-zbozi/zipball/3b09a73a9900319caaf461210e6aedc99ecc712f", + "reference": "3b09a73a9900319caaf461210e6aedc99ecc712f", "shasum": "" }, "require": { @@ -5607,11 +5656,11 @@ "ext-json": "*", "ext-pdo": "*", "php": "^7.1", - "shopsys/doctrine-orm": "2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta2", - "shopsys/framework": "7.0.0-beta2", - "shopsys/migrations": "7.0.0-beta2", - "shopsys/plugin-interface": "7.0.0-beta2", + "shopsys/doctrine-orm": "^2.6.2", + "shopsys/form-types-bundle": "7.0.0-beta3", + "shopsys/framework": "7.0.0-beta3", + "shopsys/migrations": "7.0.0-beta3", + "shopsys/plugin-interface": "7.0.0-beta3", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5619,7 +5668,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta2", + "shopsys/coding-standards": "7.0.0-beta3", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5648,7 +5697,7 @@ "product feed", "zbozi" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-27T09:20:15+00:00" }, { "name": "snc/redis-bundle", @@ -5782,16 +5831,16 @@ }, { "name": "studio-42/elfinder", - "version": "2.1.42", + "version": "2.1.43", "source": { "type": "git", "url": "https://github.com/Studio-42/elFinder.git", - "reference": "83f4b3102bafd4393cb51ff41af4edd34f8132f4" + "reference": "878daf75321c5c81d1ae308298241d94b383ea62" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Studio-42/elFinder/zipball/83f4b3102bafd4393cb51ff41af4edd34f8132f4", - "reference": "83f4b3102bafd4393cb51ff41af4edd34f8132f4", + "url": "https://api.github.com/repos/Studio-42/elFinder/zipball/878daf75321c5c81d1ae308298241d94b383ea62", + "reference": "878daf75321c5c81d1ae308298241d94b383ea62", "shasum": "" }, "require": { @@ -5836,7 +5885,7 @@ ], "description": "File manager for web", "homepage": "http://elfinder.org", - "time": "2018-08-29T06:44:30+00:00" + "time": "2018-11-24T01:37:42+00:00" }, { "name": "swiftmailer/swiftmailer", @@ -6620,16 +6669,16 @@ }, { "name": "symfony/symfony", - "version": "v3.4.18", + "version": "v3.4.20", "source": { "type": "git", "url": "https://github.com/symfony/symfony.git", - "reference": "ee054aa62e535b7905c5b8e90cb49a1ad65dbfd8" + "reference": "f6b8ddc362b1cf3fb06548693c3adbb736092412" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/symfony/zipball/ee054aa62e535b7905c5b8e90cb49a1ad65dbfd8", - "reference": "ee054aa62e535b7905c5b8e90cb49a1ad65dbfd8", + "url": "https://api.github.com/repos/symfony/symfony/zipball/f6b8ddc362b1cf3fb06548693c3adbb736092412", + "reference": "f6b8ddc362b1cf3fb06548693c3adbb736092412", "shasum": "" }, "require": { @@ -6771,7 +6820,7 @@ "keywords": [ "framework" ], - "time": "2018-11-03T10:03:29+00:00" + "time": "2018-12-06T15:24:36+00:00" }, { "name": "tracy/tracy", @@ -6841,16 +6890,16 @@ }, { "name": "twig/extensions", - "version": "v1.5.2", + "version": "v1.5.4", "source": { "type": "git", "url": "https://github.com/twigphp/Twig-extensions.git", - "reference": "2c1a86526d0044065220d1b51ac08348bea5ca82" + "reference": "57873c8b0c1be51caa47df2cdb824490beb16202" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig-extensions/zipball/2c1a86526d0044065220d1b51ac08348bea5ca82", - "reference": "2c1a86526d0044065220d1b51ac08348bea5ca82", + "url": "https://api.github.com/repos/twigphp/Twig-extensions/zipball/57873c8b0c1be51caa47df2cdb824490beb16202", + "reference": "57873c8b0c1be51caa47df2cdb824490beb16202", "shasum": "" }, "require": { @@ -6892,7 +6941,7 @@ "i18n", "text" ], - "time": "2018-05-22T13:26:07+00:00" + "time": "2018-12-05T18:34:18+00:00" }, { "name": "twig/twig", @@ -8199,36 +8248,36 @@ }, { "name": "object-calisthenics/phpcs-calisthenics-rules", - "version": "v3.3.0", + "version": "v3.4.0", "source": { "type": "git", "url": "https://github.com/object-calisthenics/phpcs-calisthenics-rules.git", - "reference": "17442a5a8f405f1b18eaf53f861d8ba06ba6b510" + "reference": "41a63b1de937281e88ab9e517787334a961f3314" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/object-calisthenics/phpcs-calisthenics-rules/zipball/17442a5a8f405f1b18eaf53f861d8ba06ba6b510", - "reference": "17442a5a8f405f1b18eaf53f861d8ba06ba6b510", + "url": "https://api.github.com/repos/object-calisthenics/phpcs-calisthenics-rules/zipball/41a63b1de937281e88ab9e517787334a961f3314", + "reference": "41a63b1de937281e88ab9e517787334a961f3314", "shasum": "" }, "require": { "nette/utils": "^2.5", "php": "^7.1", - "slevomat/coding-standard": "^4.6", + "slevomat/coding-standard": "^4.8", "squizlabs/php_codesniffer": "^3.3" }, "require-dev": { - "phpstan/phpstan": "^0.10.1", - "phpunit/phpunit": "^7.0", - "symplify/changelog-linker": "^4.5", - "symplify/coding-standard": "^4.5", - "symplify/easy-coding-standard-tester": "^4.5", + "phpstan/phpstan": "^0.10.5", + "phpunit/phpunit": "^7.4", + "symplify/changelog-linker": "^5.2", + "symplify/coding-standard": "^5.2", + "symplify/easy-coding-standard-tester": "^5.2", "tracy/tracy": "^2.5" }, "type": "phpcodesniffer-standard", "extra": { "branch-alias": { - "dev-master": "3.3-dev" + "dev-master": "3.4-dev" } }, "autoload": { @@ -8241,7 +8290,7 @@ "MIT" ], "description": "PHP CodeSniffer Object Calisthenics rules/sniffs", - "time": "2018-07-22T15:52:16+00:00" + "time": "2018-11-17T11:12:41+00:00" }, { "name": "phar-io/manifest", @@ -8965,16 +9014,16 @@ }, { "name": "phpunit/phpunit", - "version": "7.4.3", + "version": "7.5.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c151651fb6ed264038d486ea262e243af72e5e64" + "reference": "520723129e2b3fc1dc4c0953e43c9d40e1ecb352" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c151651fb6ed264038d486ea262e243af72e5e64", - "reference": "c151651fb6ed264038d486ea262e243af72e5e64", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/520723129e2b3fc1dc4c0953e43c9d40e1ecb352", + "reference": "520723129e2b3fc1dc4c0953e43c9d40e1ecb352", "shasum": "" }, "require": { @@ -8995,7 +9044,7 @@ "phpunit/php-timer": "^2.0", "sebastian/comparator": "^3.0", "sebastian/diff": "^3.0", - "sebastian/environment": "^3.1 || ^4.0", + "sebastian/environment": "^4.0", "sebastian/exporter": "^3.1", "sebastian/global-state": "^2.0", "sebastian/object-enumerator": "^3.0.3", @@ -9019,7 +9068,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.4-dev" + "dev-master": "7.5-dev" } }, "autoload": { @@ -9045,7 +9094,7 @@ "testing", "xunit" ], - "time": "2018-10-23T05:57:41+00:00" + "time": "2018-12-07T07:08:12+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -9214,28 +9263,28 @@ }, { "name": "sebastian/environment", - "version": "3.1.0", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "cd0871b3975fb7fc44d11314fd1ee20925fce4f5" + "reference": "febd209a219cea7b56ad799b30ebbea34b71eb8f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/cd0871b3975fb7fc44d11314fd1ee20925fce4f5", - "reference": "cd0871b3975fb7fc44d11314fd1ee20925fce4f5", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/febd209a219cea7b56ad799b30ebbea34b71eb8f", + "reference": "febd209a219cea7b56ad799b30ebbea34b71eb8f", "shasum": "" }, "require": { - "php": "^7.0" + "php": "^7.1" }, "require-dev": { - "phpunit/phpunit": "^6.1" + "phpunit/phpunit": "^7.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -9260,7 +9309,7 @@ "environment", "hhvm" ], - "time": "2017-07-01T08:51:00+00:00" + "time": "2018-11-25T09:31:21+00:00" }, { "name": "sebastian/exporter", @@ -9666,16 +9715,16 @@ }, { "name": "shopsys/http-smoke-testing", - "version": "v7.0.0-beta2", + "version": "v7.0.0-beta3", "source": { "type": "git", "url": "https://github.com/shopsys/http-smoke-testing.git", - "reference": "330ff3311c3857fc3508187ddac278eefcbe1746" + "reference": "3a4e35901157d8038c7810b9d1deec30ae535b96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/http-smoke-testing/zipball/330ff3311c3857fc3508187ddac278eefcbe1746", - "reference": "330ff3311c3857fc3508187ddac278eefcbe1746", + "url": "https://api.github.com/repos/shopsys/http-smoke-testing/zipball/3a4e35901157d8038c7810b9d1deec30ae535b96", + "reference": "3a4e35901157d8038c7810b9d1deec30ae535b96", "shasum": "" }, "require": { @@ -9717,7 +9766,7 @@ "symfony", "testing" ], - "time": "2018-10-19T06:40:57+00:00" + "time": "2018-11-15T09:31:59+00:00" }, { "name": "slam/php-cs-fixer-extensions", @@ -10159,16 +10208,16 @@ }, { "name": "thecodingmachine/safe", - "version": "v0.1.7", + "version": "v0.1.8", "source": { "type": "git", "url": "https://github.com/thecodingmachine/safe.git", - "reference": "70cdfb7732ab22b1bd82c6c4a3f8650a45759c5e" + "reference": "4547d4684086d463b00cbd1a7763395280355e7d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thecodingmachine/safe/zipball/70cdfb7732ab22b1bd82c6c4a3f8650a45759c5e", - "reference": "70cdfb7732ab22b1bd82c6c4a3f8650a45759c5e", + "url": "https://api.github.com/repos/thecodingmachine/safe/zipball/4547d4684086d463b00cbd1a7763395280355e7d", + "reference": "4547d4684086d463b00cbd1a7763395280355e7d", "shasum": "" }, "require": { @@ -10285,7 +10334,7 @@ "MIT" ], "description": "PHP core functions that throw exceptions instead of returning FALSE on error", - "time": "2018-11-08T14:45:50+00:00" + "time": "2018-11-13T09:01:03+00:00" }, { "name": "theseer/tokenizer", diff --git a/migrations-lock.yml b/migrations-lock.yml index b973dcc39..156f0f871 100644 --- a/migrations-lock.yml +++ b/migrations-lock.yml @@ -286,3 +286,18 @@ 20181008000001: class: Shopsys\FrameworkBundle\Migrations\Version20181008000001 skip: false +20181114102106: + class: Shopsys\FrameworkBundle\Migrations\Version20181114102106 + skip: false +20181114120915: + class: Shopsys\FrameworkBundle\Migrations\Version20181114120915 + skip: false +20181114134959: + class: Shopsys\FrameworkBundle\Migrations\Version20181114134959 + skip: false +20181114145244: + class: Shopsys\FrameworkBundle\Migrations\Version20181114145244 + skip: false +20181114145250: + class: Shopsys\FrameworkBundle\Migrations\Version20181114145250 + skip: false From 1c357cd35ae9508263056038021b67a97a529976 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 11:22:13 +0100 Subject: [PATCH 08/19] domains URLs are auto-configured during "composer install" - see shopsys/shopsys#540 --- build-dev.xml | 12 ++++++------ build.xml | 17 +++-------------- composer.json | 6 ++++-- 3 files changed, 13 insertions(+), 22 deletions(-) diff --git a/build-dev.xml b/build-dev.xml index 667250895..016d1da4d 100644 --- a/build-dev.xml +++ b/build-dev.xml @@ -1,12 +1,12 @@ - - - - - - + + + + + + diff --git a/build.xml b/build.xml index 244ebd295..e208befe0 100644 --- a/build.xml +++ b/build.xml @@ -52,10 +52,10 @@ - + - - + + @@ -271,17 +271,6 @@ - - - - - - - - - - - diff --git a/composer.json b/composer.json index b1a20bbb0..e2316b167 100644 --- a/composer.json +++ b/composer.json @@ -106,12 +106,14 @@ "post-install-cmd": [ "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters", "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap", - "Shopsys\\Environment::checkEnvironment" + "Shopsys\\Environment::checkEnvironment", + "Shopsys\\FrameworkBundle\\Command\\ComposerScriptHandler::postInstall" ], "post-update-cmd": [ "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters", "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap", - "Shopsys\\Environment::checkEnvironment" + "Shopsys\\Environment::checkEnvironment", + "Shopsys\\FrameworkBundle\\Command\\ComposerScriptHandler::postUpdate" ] }, "config": { From 4299471818908342de7a0cb87a5132833614e84d Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 11:23:38 +0100 Subject: [PATCH 09/19] new form types are now registered - new OrderItemsType for displaying table for order items management - new DisplayOnlyCustomerType for displaying information about Customer - see shopsys/shopsys#576 --- app/config/packages/twig.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/config/packages/twig.yml b/app/config/packages/twig.yml index c2e29f6b4..877a80b1c 100644 --- a/app/config/packages/twig.yml +++ b/app/config/packages/twig.yml @@ -7,7 +7,9 @@ twig: - '@ShopsysFramework/Admin/Form/fileuploadFields.html.twig' - '@ShopsysFramework/Admin/Form/imageuploadFields.html.twig' - '@ShopsysFramework/Admin/Form/pricetableFields.html.twig' + - '@ShopsysFramework/Admin/Form/orderItems.html.twig' - '@ShopsysFramework/Admin/Form/orderlistFields.html.twig' + - '@ShopsysFramework/Admin/Form/displayOnlyCustomer.html.twig' - '@ShopsysFramework/Admin/Form/displayOnlyDomainIconFields.html.twig' - '@ShopsysFramework/Admin/Form/displayOnlyFields.html.twig' - '@ShopsysShop/Admin/Form/companyUsers.html.twig' From 040a25ab2595c83ad4fd14df7c7f15fb542ec93d Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 11:29:53 +0100 Subject: [PATCH 10/19] phing targets: create-domains-data is now dependent on create-domains-db-functions --- build-dev.xml | 4 ++-- build.xml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build-dev.xml b/build-dev.xml index 016d1da4d..d2f31eab4 100644 --- a/build-dev.xml +++ b/build-dev.xml @@ -16,7 +16,7 @@ - + @@ -537,7 +537,7 @@ - + diff --git a/build.xml b/build.xml index e208befe0..4d486a00f 100644 --- a/build.xml +++ b/build.xml @@ -56,7 +56,7 @@ - + @@ -112,7 +112,7 @@ - + From 353a87ae48d382b03ec0f2e999956be5248542ef Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 7 Dec 2018 11:41:00 +0100 Subject: [PATCH 11/19] phing: improve db-fixtures targets (dependency order, remove obsolete, rename) - remove db-fixtures-demo-multidomain and test-db-fixtures-demo-multidomain and their usages - switch dependency order of db-demo to ...,create-domains-data,db-fixtures-demo-singledomain,... - switch dependency order of test-db-demo to ...,test-create-domains-data,test-db-fixtures-demo-singledomain,... - change db-fixtures-demo-singledomain and test-db-fixtures-demo-singledomain command to as command shopsys:fixtures:load doesn't exist anymore and remove --fixtures argument - rename db-fixtures-demo-singledomain to db-fixtures-demo - rename test-db-fixtures-demo-singledomain to test-db-fixtures-demo --- build-dev.xml | 33 +++------------------------------ build.xml | 31 +++---------------------------- 2 files changed, 6 insertions(+), 58 deletions(-) diff --git a/build-dev.xml b/build-dev.xml index d2f31eab4..2cd39866b 100644 --- a/build-dev.xml +++ b/build-dev.xml @@ -16,7 +16,7 @@ - + @@ -580,38 +580,11 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - + diff --git a/build.xml b/build.xml index 4d486a00f..82f76700d 100644 --- a/build.xml +++ b/build.xml @@ -56,7 +56,7 @@ - + @@ -187,35 +187,10 @@ - - - - - - - - - - - - - - - - - - - - - - - - + - - - + From c6a54c6592ebab8cba6d86e47985fb31f511ba30 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Tue, 11 Dec 2018 13:45:26 +0100 Subject: [PATCH 12/19] OrderFormType in Admin is now properly extended - there is no need to extend twig template anymore - see shopsys/shopsys#576 --- .../views/Admin/Content/Order/edit.html.twig | 256 ------------------ app/config/packages/twig.yml | 2 +- .../Form/Admin/OrderFormTypeExtension.php | 75 +++++ .../ShopBundle/Resources/config/forms.yml | 4 + .../Admin/Form/displayOnlyCustomer.html.twig | 18 ++ 5 files changed, 98 insertions(+), 257 deletions(-) delete mode 100644 app/Resources/ShopsysFrameworkBundle/views/Admin/Content/Order/edit.html.twig create mode 100644 src/Shopsys/ShopBundle/Form/Admin/OrderFormTypeExtension.php create mode 100644 src/Shopsys/ShopBundle/Resources/views/Admin/Form/displayOnlyCustomer.html.twig diff --git a/app/Resources/ShopsysFrameworkBundle/views/Admin/Content/Order/edit.html.twig b/app/Resources/ShopsysFrameworkBundle/views/Admin/Content/Order/edit.html.twig deleted file mode 100644 index 4352eff67..000000000 --- a/app/Resources/ShopsysFrameworkBundle/views/Admin/Content/Order/edit.html.twig +++ /dev/null @@ -1,256 +0,0 @@ -{% extends '@!ShopsysFramework/Admin/Content/Order/edit.html.twig' %} -{% import '@ShopsysFramework/Admin/Content/Order/orderItem.html.twig' as orderItemMacro %} -{% block main_content %} - {{ form_start(form) }} - {{ form_errors(form) }} -
-
-
- {{ 'Order Nr.'|trans }} {{ order.number }} -
-
-
- {{ form_id(order) }} - - {% if isMultidomain() %} -
- -
-
- {{ domainIcon(order.domainId) }} {{ getDomainName(order.domainId) }} -
-
-
- {% endif %} - {{ form_row(form.orderNumber, { label: 'Order number'|trans }) }} -
- -
-
- {{ order.createdAt|formatDateTime }} -
-
-
- {{ form_row(form.status, { label: 'Status'|trans }) }} -
- - -
- {% if order.createdAsAdministrator is not null or order.createdAsAdministratorName is not null %} -
- -
-
- {% if order.createdAsAdministrator is null%} - {{ order.createdAsAdministratorName }} - {% else %} - {{ order.createdAsAdministrator.realName }} - {% endif %} -
-
-
- {% endif %} -
-
-
-
-
- {{ 'Personal data'|trans }} -
-
-
- {{ form_row(form.firstName, { label: 'First name'|trans }) }} - {{ form_row(form.lastName, { label: 'Last name'|trans }) }} - {{ form_row(form.email, { label: 'E-mail'|trans }) }} - {{ form_row(form.telephone, { label: 'Telephone'|trans }) }} -
-
-
-
-
- {{ 'Company data'|trans }} -
-
-
- {{ form_row(form.companyName, { label: 'Company name'|trans }) }} - {{ form_row(form.companyNumber, { label: 'Company number'|trans }) }} - {{ form_row(form.companyTaxNumber, { label: 'Tax number'|trans }) }} -
-
-
-
-
- {{ 'Billing data'|trans }} -
-
-
- {{ form_row(form.street, { label: 'Street'|trans }) }} - {{ form_row(form.city, { label: 'City'|trans }) }} - {{ form_row(form.postcode, { label: 'Postcode'|trans }) }} - {{ form_row(form.country, { label: 'Country'|trans }) }} -
-
-
-
-
- {{ 'Shipping address'|trans }} -
-
-
- {{ form_row(form.deliveryAddressSameAsBillingAddress, { - attr: { class: 'js-checkbox-toggle js-checkbox-toggle--inverted', 'data-checkbox-toggle-container-id': 'js-delivery-address-fields' }, - label: 'Shipping address is the same as billing address'|trans}) - }} -
- {{ form_row(form.deliveryFirstName, { label: 'First name'|trans }) }} - {{ form_row(form.deliveryLastName, { label: 'Last name'|trans }) }} - {{ form_row(form.deliveryCompanyName, { label: 'Company'|trans }) }} - {{ form_row(form.deliveryTelephone, { label: 'Telephone'|trans }) }} - {{ form_row(form.deliveryStreet, { label: 'Street'|trans }) }} - {{ form_row(form.deliveryCity, { label: 'City'|trans }) }} - {{ form_row(form.deliveryPostcode, { label: 'Postcode'|trans }) }} - {{ form_row(form.deliveryCountry, { label: 'Country'|trans }) }} -
-
-
- {% if order.pickUpPlace is not null %} -
-
-
- {{ 'Zasilkovna.cz - dispensing point'|trans }} -
-
-
- -
-
- {{ order.pickUpPlace.id }} -
-
-
-
- -
-
- {{ order.pickUpPlace.name }} -
-
-
-
- -
-
- {{ order.pickUpPlace.fullAddress }} -
-
-
-
- -
-
- {{ order.pickUpPlace.description }} -
-
-
-
- {% endif %} -
-
-
- {{ 'Note'|trans }} -
-
-
- {{ form_row(form.note, { label: 'Contact us'|trans, newline: true }) }} -
-
-

{{ 'Order items'|trans }}

-
-
- {{ form_errors(form.itemsWithoutTransportAndPayment) }} -
- - - - - - - - - - - - - - - - {% for productItem in order.productItems %} - {{ orderItemMacro.orderItem(form.itemsWithoutTransportAndPayment[productItem.id], productItem.id, orderItemTotalPricesById, order.currency, productItem) }} - {% endfor %} - {% for orderItemId, orderItemForm in form.itemsWithoutTransportAndPayment %} - {% if not orderItemForm.rendered %} - {{ orderItemMacro.orderItem(orderItemForm, orderItemId, orderItemTotalPricesById, order.currency, null) }} - {% endif %} - {% endfor %} - {{ orderItemMacro.orderTransport(form.orderTransport, order, transportPricesWithVatByTransportId, transportVatPercentsByTransportId) }} - {{ orderItemMacro.orderPayment(form.orderPayment, order, paymentPricesWithVatByPaymentId, paymentVatPercentsByPaymentId) }} - - - - - - - - - - - - -
{{ 'Name'|trans }}{{ 'Catalogue number'|trans }}{{ 'Unit price including VAT'|trans }}{{ 'Amount'|trans }}{{ 'Unit'|trans }}{{ 'VAT rate (%)'|trans }}{{ 'Total including VAT'|trans }}{{ 'Total excluding VAT'|trans }}
- - + - {{ 'Add item'|trans }} - - - + - {{ 'Add product'|trans }} - -
{{ 'Total'|trans }}:{{ order.totalPriceWithVat|priceWithCurrency(order.currency) }}{{ order.totalPriceWithoutVat|priceWithCurrency(order.currency) }}
-
-
-
- {% embed '@ShopsysFramework/Admin/Inline/FixedBar/fixedBar.html.twig' %} - {% block fixed_bar_content %} - {{ 'Back to overview'|trans }} - {{ form_widget(form.save, { label: 'Save changes'|trans}) }} - {% endblock %} - {% endembed %} - {{ form_end(form) }} -{% endblock %} \ No newline at end of file diff --git a/app/config/packages/twig.yml b/app/config/packages/twig.yml index 877a80b1c..60d5fda2e 100644 --- a/app/config/packages/twig.yml +++ b/app/config/packages/twig.yml @@ -9,7 +9,7 @@ twig: - '@ShopsysFramework/Admin/Form/pricetableFields.html.twig' - '@ShopsysFramework/Admin/Form/orderItems.html.twig' - '@ShopsysFramework/Admin/Form/orderlistFields.html.twig' - - '@ShopsysFramework/Admin/Form/displayOnlyCustomer.html.twig' + - '@ShopsysShop/Admin/Form/displayOnlyCustomer.html.twig' - '@ShopsysFramework/Admin/Form/displayOnlyDomainIconFields.html.twig' - '@ShopsysFramework/Admin/Form/displayOnlyFields.html.twig' - '@ShopsysShop/Admin/Form/companyUsers.html.twig' diff --git a/src/Shopsys/ShopBundle/Form/Admin/OrderFormTypeExtension.php b/src/Shopsys/ShopBundle/Form/Admin/OrderFormTypeExtension.php new file mode 100644 index 000000000..fd1a2162c --- /dev/null +++ b/src/Shopsys/ShopBundle/Form/Admin/OrderFormTypeExtension.php @@ -0,0 +1,75 @@ +getPickUpPlace() !== null) { + // Place pickup place group before noteGroup and orderItems + $noteGroup = $builder->get('noteGroup'); + $builder->remove('noteGroup'); + $itemsGroup = $builder->get('orderItems'); + $builder->remove('orderItems'); + + $builder->add($this->createPickupPlaceGroup($builder, $order->getPickUpPlace())); + + $builder->add($noteGroup); + $builder->add($itemsGroup); + } + } + + /** + * @param \Symfony\Component\Form\FormBuilderInterface $formBuilder + * @param \Shopsys\ShopBundle\Model\PickUpPlace\PickUpPlace $pickUpPlace + * @return \Symfony\Component\Form\FormBuilderInterface + */ + private function createPickupPlaceGroup(FormBuilderInterface $formBuilder, PickUpPlace $pickUpPlace): FormBuilderInterface + { + $pickupPlaceGroup = $formBuilder->create('pickupPlaceGroup', GroupType::class, [ + 'label' => t('Zasilkovna.cz - dispensing point'), + ]); + + $pickupPlaceGroup + ->add('id', DisplayOnlyType::class, [ + 'label' => t('Id'), + 'data' => $pickUpPlace->getId(), + ]) + ->add('name', DisplayOnlyType::class, [ + 'label' => t('Name'), + 'data' => $pickUpPlace->getName(), + ]) + ->add('address', DisplayOnlyType::class, [ + 'label' => t('Address'), + 'data' => $pickUpPlace->getFullAddress(), + ]) + ->add('description', DisplayOnlyType::class, [ + 'label' => t('Description'), + 'data' => $pickUpPlace->getDescription(), + ]); + + return $pickupPlaceGroup; + } + + /** + * {@inheritdoc} + */ + public function getExtendedType() + { + return OrderFormType::class; + } +} diff --git a/src/Shopsys/ShopBundle/Resources/config/forms.yml b/src/Shopsys/ShopBundle/Resources/config/forms.yml index 79383cc9a..7dbd168ee 100644 --- a/src/Shopsys/ShopBundle/Resources/config/forms.yml +++ b/src/Shopsys/ShopBundle/Resources/config/forms.yml @@ -27,6 +27,10 @@ services: tags: - { name: form.type_extension, extended_type: Shopsys\FrameworkBundle\Form\Admin\Customer\CustomerFormType } + Shopsys\ShopBundle\Form\Admin\OrderFormTypeExtension: + tags: + - { name: form.type_extension, extended_type: Shopsys\FrameworkBundle\Form\Admin\Order\OrderFormType } + Shopsys\ShopBundle\Form\Admin\TransportFormTypeExtension: tags: - { name: form.type_extension, extended_type: Shopsys\FrameworkBundle\Form\Admin\Transport\TransportFormType } diff --git a/src/Shopsys/ShopBundle/Resources/views/Admin/Form/displayOnlyCustomer.html.twig b/src/Shopsys/ShopBundle/Resources/views/Admin/Form/displayOnlyCustomer.html.twig new file mode 100644 index 000000000..bdd349759 --- /dev/null +++ b/src/Shopsys/ShopBundle/Resources/views/Admin/Form/displayOnlyCustomer.html.twig @@ -0,0 +1,18 @@ +{% block display_only_customer_widget %} + +{% endblock display_only_customer_widget %} From b5c7377ecd506cebb4c17ad84bf219e372b82b5e Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Tue, 11 Dec 2018 13:47:02 +0100 Subject: [PATCH 13/19] fixed tests related with price calculation removal --- .../Cart/Watcher/CartWatcherServiceTest.php | 39 ++++---- .../Pricing/Group/PricingGroupFacadeTest.php | 40 --------- .../InputPriceRecalculationSchedulerTest.php | 90 +++++-------------- .../Model/Product/ProductServiceTest.php | 4 - .../ProductVisibilityRepositoryTest.php | 43 +++++---- tests/ShopBundle/Smoke/NewProductTest.php | 18 +++- 6 files changed, 81 insertions(+), 153 deletions(-) diff --git a/tests/ShopBundle/Functional/Model/Cart/Watcher/CartWatcherServiceTest.php b/tests/ShopBundle/Functional/Model/Cart/Watcher/CartWatcherServiceTest.php index ed3ed38ae..7390a8b78 100644 --- a/tests/ShopBundle/Functional/Model/Cart/Watcher/CartWatcherServiceTest.php +++ b/tests/ShopBundle/Functional/Model/Cart/Watcher/CartWatcherServiceTest.php @@ -4,6 +4,7 @@ use Shopsys\FrameworkBundle\Component\Domain\Domain; use Shopsys\FrameworkBundle\DataFixtures\Demo\PricingGroupDataFixture; +use Shopsys\FrameworkBundle\DataFixtures\Demo\ProductDataFixture; use Shopsys\FrameworkBundle\Model\Cart\Cart; use Shopsys\FrameworkBundle\Model\Cart\Item\CartItem; use Shopsys\FrameworkBundle\Model\Cart\Watcher\CartWatcherService; @@ -11,51 +12,43 @@ use Shopsys\FrameworkBundle\Model\Customer\CustomerIdentifier; use Shopsys\FrameworkBundle\Model\Pricing\Vat\Vat; use Shopsys\FrameworkBundle\Model\Pricing\Vat\VatData; +use Shopsys\FrameworkBundle\Model\Product\Pricing\ProductManualInputPriceFacade; use Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceCalculationForUser; -use Shopsys\FrameworkBundle\Model\Product\ProductCategoryDomainFactory; use Shopsys\FrameworkBundle\Model\Product\ProductVisibility; use Shopsys\FrameworkBundle\Model\Product\ProductVisibilityRepository; use Shopsys\ShopBundle\Model\Product\Product; use Shopsys\ShopBundle\Model\Product\ProductDataFactory; -use Tests\ShopBundle\Test\FunctionalTestCase; +use Tests\ShopBundle\Test\TransactionFunctionalTestCase; -class CartWatcherServiceTest extends FunctionalTestCase +class CartWatcherServiceTest extends TransactionFunctionalTestCase { public function testGetModifiedPriceItemsAndUpdatePrices() { $customerIdentifier = new CustomerIdentifier('randomString'); - $productDataFactory = $this->getContainer()->get(ProductDataFactory::class); - $vatData = new VatData(); - $vatData->name = 'vat'; - $vatData->percent = 21; - $vat = new Vat($vatData); - $productData1 = $productDataFactory->create(); - $productData1->name = []; - $productData1->price = 100; - $productData1->vat = $vat; - $productData1->priceCalculationType = Product::PRICE_CALCULATION_TYPE_AUTO; - $productMock = Product::create($productData1); + /** @var \Shopsys\ShopBundle\Model\Product\Product $product */ + $product = $this->getReference(ProductDataFixture::PRODUCT_PREFIX . '1'); + /* @var \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceCalculationForUser $productPriceCalculationForUser */ $productPriceCalculationForUser = $this->getContainer()->get(ProductPriceCalculationForUser::class); - /* @var $productPriceCalculationForUser \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceCalculationForUser */ - $productPrice = $productPriceCalculationForUser->calculatePriceForCurrentUser($productMock); - $cartItem = new CartItem($customerIdentifier, $productMock, 1, $productPrice->getPriceWithVat()); + + $productPrice = $productPriceCalculationForUser->calculatePriceForCurrentUser($product); + $cartItem = new CartItem($customerIdentifier, $product, 1, $productPrice->getPriceWithVat()); $cartItems = [$cartItem]; $cart = new Cart($cartItems); + /** @var \Shopsys\FrameworkBundle\Model\Cart\Watcher\CartWatcherService $cartWatcherService */ $cartWatcherService = $this->getContainer()->get(CartWatcherService::class); - /* @var $cartWatcherService \Shopsys\FrameworkBundle\Model\Cart\Watcher\CartWatcherService */ $modifiedItems1 = $cartWatcherService->getModifiedPriceItemsAndUpdatePrices($cart); $this->assertEmpty($modifiedItems1); - $productData2 = $productDataFactory->create(); - $productData2->name = []; - $productData2->price = 200; - $productData2->vat = $vat; + $pricingGroup = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1); + + /** @var \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductManualInputPriceFacade $manualInputPriceFacade */ + $manualInputPriceFacade = $this->getContainer()->get(ProductManualInputPriceFacade::class); + $manualInputPriceFacade->refresh($product, $pricingGroup, '10'); - $productMock->edit(new ProductCategoryDomainFactory(), $productData2); $modifiedItems2 = $cartWatcherService->getModifiedPriceItemsAndUpdatePrices($cart); $this->assertNotEmpty($modifiedItems2); diff --git a/tests/ShopBundle/Functional/Model/Pricing/Group/PricingGroupFacadeTest.php b/tests/ShopBundle/Functional/Model/Pricing/Group/PricingGroupFacadeTest.php index ec77ac0f8..b10539bd2 100644 --- a/tests/ShopBundle/Functional/Model/Pricing/Group/PricingGroupFacadeTest.php +++ b/tests/ShopBundle/Functional/Model/Pricing/Group/PricingGroupFacadeTest.php @@ -2,7 +2,6 @@ namespace Tests\ShopBundle\Functional\Model\Pricing\Group; -use ReflectionClass; use Shopsys\FrameworkBundle\DataFixtures\Demo\PricingGroupDataFixture; use Shopsys\FrameworkBundle\DataFixtures\Demo\ProductDataFixture; use Shopsys\FrameworkBundle\Model\Customer\CustomerDataFactory; @@ -27,7 +26,6 @@ public function testCreate() /* @var $productPriceRecalculator \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator */ $pricingGroupData = new PricingGroupData(); $pricingGroupData->name = 'pricing_group_name'; - $pricingGroupData->coefficient = 1; $domainId = 1; $pricingGroup = $pricingGroupFacade->create($pricingGroupData, $domainId); $productPriceRecalculator->runAllScheduledRecalculations(); @@ -39,44 +37,6 @@ public function testCreate() $this->assertNotNull($productCalculatedPrice); } - public function testEdit() - { - $em = $this->getEntityManager(); - $product = $this->getReference(ProductDataFixture::PRODUCT_PREFIX . '1'); - /* @var $prodcu \Shopsys\ShopBundle\Model\Product\Product */ - $pricingGroup = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1); - /* @var $pricingGroup \Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroup */ - $pricingGroupFacade = $this->getContainer()->get(PricingGroupFacade::class); - /* @var $pricingGroupFacade \Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroupFacade */ - $productPriceRecalculator = $this->getContainer()->get(ProductPriceRecalculator::class); - /* @var $productPriceRecalculator \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator */ - $productCalculatedPrice = $em->getRepository(ProductCalculatedPrice::class)->findOneBy([ - 'product' => $product, - 'pricingGroup' => $pricingGroup, - ]); - - $reflectionClass = new ReflectionClass(ProductCalculatedPrice::class); - $reflectionProperty = $reflectionClass->getProperty('priceWithVat'); - $reflectionProperty->setAccessible(true); - - $productPriceBeforeEdit = $reflectionProperty->getValue($productCalculatedPrice); - - $pricingGroupData = new PricingGroupData(); - $pricingGroupData->name = $pricingGroup->getName(); - $pricingGroupData->coefficient = $pricingGroup->getCoefficient() * 2; - $pricingGroupFacade->edit($pricingGroup->getId(), $pricingGroupData); - $productPriceRecalculator->runAllScheduledRecalculations(); - - $newProductCalculatedPrice = $em->getRepository(ProductCalculatedPrice::class)->findOneBy([ - 'product' => $product, - 'pricingGroup' => $pricingGroup, - ]); - - $productPriceAfterEdit = $reflectionProperty->getValue($newProductCalculatedPrice); - - $this->assertSame(round($productPriceBeforeEdit * 2, 6), round($productPriceAfterEdit, 6)); - } - public function testDeleteAndReplace() { $em = $this->getEntityManager(); diff --git a/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php b/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php index 0c4b7dc00..657772dde 100644 --- a/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php +++ b/tests/ShopBundle/Functional/Model/Pricing/InputPriceRecalculationSchedulerTest.php @@ -4,7 +4,6 @@ use Shopsys\FrameworkBundle\Component\Setting\Setting; use Shopsys\FrameworkBundle\DataFixtures\Demo\CurrencyDataFixture; -use Shopsys\FrameworkBundle\DataFixtures\Demo\ProductDataFixture; use Shopsys\FrameworkBundle\Model\Payment\PaymentDataFactory; use Shopsys\FrameworkBundle\Model\Payment\PaymentFacade; use Shopsys\FrameworkBundle\Model\Pricing\InputPriceRecalculationScheduler; @@ -14,11 +13,8 @@ use Shopsys\FrameworkBundle\Model\Pricing\Vat\VatData; use Shopsys\FrameworkBundle\Model\Product\Availability\Availability; use Shopsys\FrameworkBundle\Model\Product\Availability\AvailabilityData; -use Shopsys\FrameworkBundle\Model\Product\ProductFacade; use Shopsys\FrameworkBundle\Model\Transport\TransportDataFactoryInterface; use Shopsys\FrameworkBundle\Model\Transport\TransportFacade; -use Shopsys\ShopBundle\Model\Product\Product; -use Shopsys\ShopBundle\Model\Product\ProductDataFactory; use Symfony\Component\HttpKernel\Event\FilterResponseEvent; use Tests\ShopBundle\Test\TransactionFunctionalTestCase; @@ -26,8 +22,8 @@ class InputPriceRecalculationSchedulerTest extends TransactionFunctionalTestCase { public function testOnKernelResponseNoAction() { + /** @var \Shopsys\FrameworkBundle\Component\Setting\Setting $setting */ $setting = $this->getContainer()->get(Setting::class); - /* @var $setting \Shopsys\FrameworkBundle\Component\Setting\Setting */ $inputPriceRecalculatorMock = $this->getMockBuilder(InputPriceRecalculator::class) ->setMethods(['__construct', 'recalculateToInputPricesWithoutVat', 'recalculateToInputPricesWithVat']) @@ -56,36 +52,6 @@ public function inputPricesTestDataProvider() ]; } - /** - * @param string $inputPrice - * @param string $vatPercent - * @return \Shopsys\ShopBundle\Model\Product\Product - */ - private function createProductWithInputPriceAndVatPercentAndAutoCalculationPriceType( - $inputPrice, - $vatPercent - ) { - $em = $this->getEntityManager(); - $productDataFactory = $this->getContainer()->get(ProductDataFactory::class); - /* @var $productDataFactory \Shopsys\ShopBundle\Model\Product\ProductDataFactory */ - $productFacade = $this->getContainer()->get(ProductFacade::class); - /* @var $productFacade \Shopsys\FrameworkBundle\Model\Product\ProductFacade */ - - $vatData = new VatData(); - $vatData->name = 'vat'; - $vatData->percent = $vatPercent; - $vat = new Vat($vatData); - $em->persist($vat); - - $templateProduct = $this->getReference(ProductDataFixture::PRODUCT_PREFIX . '1'); - $productData = $productDataFactory->createFromProduct($templateProduct); - $productData->priceCalculationType = Product::PRICE_CALCULATION_TYPE_AUTO; - $productData->price = $inputPrice; - $productData->vat = $vat; - - return $productFacade->create($productData); - } - /** * @dataProvider inputPricesTestDataProvider * @param mixed $inputPriceWithoutVat @@ -99,18 +65,18 @@ public function testOnKernelResponseRecalculateInputPricesWithoutVat( ) { $em = $this->getEntityManager(); - $setting = $this->getContainer()->get(Setting::class); /* @var $setting \Shopsys\FrameworkBundle\Component\Setting\Setting */ - $inputPriceRecalculationScheduler = $this->getContainer()->get(InputPriceRecalculationScheduler::class); + $setting = $this->getContainer()->get(Setting::class); /* @var $inputPriceRecalculationScheduler \Shopsys\FrameworkBundle\Model\Pricing\InputPriceRecalculationScheduler */ - $paymentFacade = $this->getContainer()->get(PaymentFacade::class); + $inputPriceRecalculationScheduler = $this->getContainer()->get(InputPriceRecalculationScheduler::class); /* @var $paymentFacade \Shopsys\FrameworkBundle\Model\Payment\PaymentFacade */ - $transportFacade = $this->getContainer()->get(TransportFacade::class); + $paymentFacade = $this->getContainer()->get(PaymentFacade::class); /* @var $transportFacade \Shopsys\FrameworkBundle\Model\Transport\TransportFacade */ + $transportFacade = $this->getContainer()->get(TransportFacade::class); + /** @var \Shopsys\FrameworkBundle\Model\Payment\PaymentDataFactory $paymentDataFactory */ $paymentDataFactory = $this->getContainer()->get(PaymentDataFactory::class); - /* @var $paymentDataFactory \Shopsys\FrameworkBundle\Model\Payment\PaymentDataFactory */ + /** @var \Shopsys\ShopBundle\Model\Transport\TransportDataFactory $transportDataFactory */ $transportDataFactory = $this->getContainer()->get(TransportDataFactoryInterface::class); - /* @var $transportDataFactory \Shopsys\FrameworkBundle\Model\Transport\TransportDataFactory */ $setting->set(PricingSetting::INPUT_PRICE_TYPE, PricingSetting::INPUT_PRICE_TYPE_WITH_VAT); @@ -118,34 +84,34 @@ public function testOnKernelResponseRecalculateInputPricesWithoutVat( $vatData->name = 'vat'; $vatData->percent = $vatPercent; $vat = new Vat($vatData); + $availabilityData = new AvailabilityData(); $availabilityData->dispatchTime = 0; $availability = new Availability($availabilityData); + $em->persist($vat); $em->persist($availability); + /** @var $currency1 \Shopsys\FrameworkBundle\Model\Pricing\Currency\Currency */ $currency1 = $this->getReference(CurrencyDataFixture::CURRENCY_CZK); + /** @var $currency2 \Shopsys\FrameworkBundle\Model\Pricing\Currency\Currency */ $currency2 = $this->getReference(CurrencyDataFixture::CURRENCY_EUR); - $product = $this->createProductWithInputPriceAndVatPercentAndAutoCalculationPriceType( - $inputPriceWithVat, - $vatPercent - ); - $paymentData = $paymentDataFactory->create(); $paymentData->name = ['cs' => 'name']; $paymentData->pricesByCurrencyId = [$currency1->getId() => $inputPriceWithVat, $currency2->getId() => $inputPriceWithVat]; $paymentData->vat = $vat; + /** @var \Shopsys\FrameworkBundle\Model\Payment\Payment $payment */ $payment = $paymentFacade->create($paymentData); - /* @var $payment \Shopsys\FrameworkBundle\Model\Payment\Payment */ $transportData = $transportDataFactory->create(); $transportData->name = ['cs' => 'name']; $transportData->description = ['cs' => 'desc']; $transportData->pricesByCurrencyId = [$currency1->getId() => $inputPriceWithVat, $currency2->getId() => $inputPriceWithVat]; $transportData->vat = $vat; - $transport = $transportFacade->create($transportData); /* @var $transport \Shopsys\ShopBundle\Model\Transport\Transport */ + $transport = $transportFacade->create($transportData); + $em->flush(); $filterResponseEventMock = $this->getMockBuilder(FilterResponseEvent::class) @@ -158,11 +124,9 @@ public function testOnKernelResponseRecalculateInputPricesWithoutVat( $inputPriceRecalculationScheduler->scheduleSetInputPricesWithoutVat(); $inputPriceRecalculationScheduler->onKernelResponse($filterResponseEventMock); - $em->refresh($product); $em->refresh($payment); $em->refresh($transport); - $this->assertSame(round($inputPriceWithoutVat, 6), round($product->getPrice(), 6)); $this->assertSame(round($inputPriceWithoutVat, 6), round($payment->getPrice($currency1)->getPrice(), 6)); $this->assertSame(round($inputPriceWithoutVat, 6), round($transport->getPrice($currency1)->getPrice(), 6)); } @@ -180,22 +144,24 @@ public function testOnKernelResponseRecalculateInputPricesWithVat( ) { $em = $this->getEntityManager(); - $setting = $this->getContainer()->get(Setting::class); /* @var $setting \Shopsys\FrameworkBundle\Component\Setting\Setting */ - $inputPriceRecalculationScheduler = $this->getContainer()->get(InputPriceRecalculationScheduler::class); + $setting = $this->getContainer()->get(Setting::class); /* @var $inputPriceRecalculationScheduler \Shopsys\FrameworkBundle\Model\Pricing\InputPriceRecalculationScheduler */ - $paymentFacade = $this->getContainer()->get(PaymentFacade::class); + $inputPriceRecalculationScheduler = $this->getContainer()->get(InputPriceRecalculationScheduler::class); /* @var $paymentFacade \Shopsys\FrameworkBundle\Model\Payment\PaymentFacade */ - $transportFacade = $this->getContainer()->get(TransportFacade::class); + $paymentFacade = $this->getContainer()->get(PaymentFacade::class); /* @var $transportFacade \Shopsys\FrameworkBundle\Model\Transport\TransportFacade */ + $transportFacade = $this->getContainer()->get(TransportFacade::class); + /** @var \Shopsys\FrameworkBundle\Model\Payment\PaymentDataFactory $paymentDataFactory */ $paymentDataFactory = $this->getContainer()->get(PaymentDataFactory::class); - /* @var $paymentDataFactory \Shopsys\FrameworkBundle\Model\Payment\PaymentDataFactory */ + /** @var \Shopsys\ShopBundle\Model\Transport\TransportDataFactory $transportDataFactory */ $transportDataFactory = $this->getContainer()->get(TransportDataFactoryInterface::class); - /* @var $transportDataFactory \Shopsys\ShopBundle\Model\Transport\TransportDataFactory */ $setting->set(PricingSetting::INPUT_PRICE_TYPE, PricingSetting::INPUT_PRICE_TYPE_WITHOUT_VAT); + /** @var \Shopsys\FrameworkBundle\Model\Pricing\Currency\Currency $currency1 */ $currency1 = $this->getReference(CurrencyDataFixture::CURRENCY_CZK); + /** @var \Shopsys\FrameworkBundle\Model\Pricing\Currency\Currency $currency1 */ $currency2 = $this->getReference(CurrencyDataFixture::CURRENCY_EUR); $vatData = new VatData(); @@ -207,25 +173,19 @@ public function testOnKernelResponseRecalculateInputPricesWithVat( $availability = new Availability($availabilityData); $em->persist($vat); $em->persist($availability); - - $product = $this->createProductWithInputPriceAndVatPercentAndAutoCalculationPriceType( - $inputPriceWithoutVat, - $vatPercent - ); - $paymentData = $paymentDataFactory->create(); $paymentData->name = ['cs' => 'name']; $paymentData->pricesByCurrencyId = [$currency1->getId() => $inputPriceWithoutVat, $currency2->getId() => $inputPriceWithoutVat]; $paymentData->vat = $vat; - $payment = $paymentFacade->create($paymentData); /* @var $payment \Shopsys\FrameworkBundle\Model\Payment\Payment */ + $payment = $paymentFacade->create($paymentData); $transportData = $transportDataFactory->create(); $transportData->name = ['cs' => 'name']; $transportData->pricesByCurrencyId = [$currency1->getId() => $inputPriceWithoutVat, $currency2->getId() => $inputPriceWithoutVat]; $transportData->vat = $vat; - $transport = $transportFacade->create($transportData); /* @var $transport \Shopsys\ShopBundle\Model\Transport\Transport */ + $transport = $transportFacade->create($transportData); $em->flush(); @@ -239,11 +199,9 @@ public function testOnKernelResponseRecalculateInputPricesWithVat( $inputPriceRecalculationScheduler->scheduleSetInputPricesWithVat(); $inputPriceRecalculationScheduler->onKernelResponse($filterResponseEventMock); - $em->refresh($product); $em->refresh($payment); $em->refresh($transport); - $this->assertSame(round($inputPriceWithVat, 6), round($product->getPrice(), 6)); $this->assertSame(round($inputPriceWithVat, 6), round($payment->getPrice($currency1)->getPrice(), 6)); $this->assertSame(round($inputPriceWithVat, 6), round($transport->getPrice($currency1)->getPrice(), 6)); } diff --git a/tests/ShopBundle/Functional/Model/Product/ProductServiceTest.php b/tests/ShopBundle/Functional/Model/Product/ProductServiceTest.php index 8c4c1e15e..69defaabf 100644 --- a/tests/ShopBundle/Functional/Model/Product/ProductServiceTest.php +++ b/tests/ShopBundle/Functional/Model/Product/ProductServiceTest.php @@ -34,7 +34,6 @@ public function testRecalculateInputPriceForNewVatPercentWithInputPriceWithoutVa $pricingGroup = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1); $productData = $producDataFactory->create(); - $productData->price = 1000; $productData->vat = $vat; $productData->unit = $this->getReference(UnitDataFixture::UNIT_PIECES); $product = Product::create($productData); @@ -43,7 +42,6 @@ public function testRecalculateInputPriceForNewVatPercentWithInputPriceWithoutVa $productService->recalculateInputPriceForNewVatPercent($product, [$productManualInputPrice], 15); - $this->assertSame('1052.173913', (string)$product->getPrice()); $this->assertSame('1052.173913', (string)$productManualInputPrice->getInputPrice()); } @@ -65,7 +63,6 @@ public function testRecalculateInputPriceForNewVatPercentWithInputPriceWithVat() $pricingGroup = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1); $productData = $productDataFactory->create(); - $productData->price = 1000; $productData->vat = $vat; $productData->unit = $this->getReference(UnitDataFixture::UNIT_PIECES); $product = Product::create($productData); @@ -74,7 +71,6 @@ public function testRecalculateInputPriceForNewVatPercentWithInputPriceWithVat() $productService->recalculateInputPriceForNewVatPercent($product, [$productManualInputPrice], 15); - $this->assertSame('1000', (string)$product->getPrice()); $this->assertSame('1000', (string)$productManualInputPrice->getInputPrice()); } } diff --git a/tests/ShopBundle/Functional/Model/Product/ProductVisibilityRepositoryTest.php b/tests/ShopBundle/Functional/Model/Product/ProductVisibilityRepositoryTest.php index 64afcf2ff..ee990bd67 100644 --- a/tests/ShopBundle/Functional/Model/Product/ProductVisibilityRepositoryTest.php +++ b/tests/ShopBundle/Functional/Model/Product/ProductVisibilityRepositoryTest.php @@ -12,6 +12,7 @@ use Shopsys\FrameworkBundle\Model\Pricing\Vat\Vat; use Shopsys\FrameworkBundle\Model\Pricing\Vat\VatData; use Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator; +use Shopsys\FrameworkBundle\Model\Product\ProductData; use Shopsys\FrameworkBundle\Model\Product\ProductFacade; use Shopsys\FrameworkBundle\Model\Product\ProductVisibility; use Shopsys\FrameworkBundle\Model\Product\ProductVisibilityRepository; @@ -24,7 +25,7 @@ class ProductVisibilityRepositoryTest extends TransactionFunctionalTestCase /** * @return \Shopsys\ShopBundle\Model\Product\ProductData */ - private function getDefaultProductData() + private function getDefaultProductData(): ProductData { $category = $this->getReference(CategoryDataFixture::CATEGORY_ELECTRONICS); @@ -41,11 +42,10 @@ private function getDefaultProductData() $productData = $productDataFactory->create(); $productData->name = ['cs' => 'Name', 'en' => 'Name']; $productData->vat = $vat; - $productData->price = 100; - $productData->priceCalculationType = Product::PRICE_CALCULATION_TYPE_AUTO; $productData->categoriesByDomainId = [1 => [$category]]; $productData->availability = $this->getReference(AvailabilityDataFixture::AVAILABILITY_IN_STOCK); $productData->unit = $this->getReference(UnitDataFixture::UNIT_PIECES); + $this->setPriceForAllDomains($productData, 100); return $productData; } @@ -215,10 +215,10 @@ public function testIsNotVisibleWhenZeroOrNullPrice() /* @var $productPriceRecalculator \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator */ $productData = $this->getDefaultProductData(); - $productData->price = 0; + $this->setPriceForAllDomains($productData, 0); $product1 = $productFacade->create($productData); - $productData->price = null; + $this->setPriceForAllDomains($productData, null); $product2 = $productFacade->create($productData); $productPriceRecalculator->runImmediateRecalculations(); @@ -363,16 +363,10 @@ public function testIsNotVisibleWhenZeroManualPrice() /* @var $productFacade \Shopsys\FrameworkBundle\Model\Product\ProductFacade */ $productPriceRecalculator = $this->getContainer()->get(ProductPriceRecalculator::class); /* @var $productPriceRecalculator \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator */ - $pricingGroupFacade = $this->getContainer()->get(PricingGroupFacade::class); - /* @var $pricingGroupFacade \Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroupFacade */ $productData = $this->getDefaultProductData(); - $productData->priceCalculationType = Product::PRICE_CALCULATION_TYPE_MANUAL; - $allPricingGroups = $pricingGroupFacade->getAll(); - foreach ($allPricingGroups as $pricingGroup) { - $productData->manualInputPricesByPricingGroupId[$pricingGroup->getId()] = 10; - } + $this->setPriceForAllDomains($productData, 10); $pricingGroupWithZeroPriceId = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1)->getId(); @@ -404,16 +398,10 @@ public function testIsNotVisibleWhenNullManualPrice() /* @var $productFacade \Shopsys\FrameworkBundle\Model\Product\ProductFacade */ $productPriceRecalculator = $this->getContainer()->get(ProductPriceRecalculator::class); /* @var $productPriceRecalculator \Shopsys\FrameworkBundle\Model\Product\Pricing\ProductPriceRecalculator */ - $pricingGroupFacade = $this->getContainer()->get(PricingGroupFacade::class); - /* @var $pricingGroupFacade \Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroupFacade */ $productData = $this->getDefaultProductData(); - $productData->priceCalculationType = Product::PRICE_CALCULATION_TYPE_MANUAL; - $allPricingGroups = $pricingGroupFacade->getAll(); - foreach ($allPricingGroups as $pricingGroup) { - $productData->manualInputPricesByPricingGroupId[$pricingGroup->getId()] = 10; - } + $this->setPriceForAllDomains($productData, 10); $pricingGroupWithNullPriceId = $this->getReference(PricingGroupDataFixture::PRICING_GROUP_ORDINARY_DOMAIN_1)->getId(); $productData->manualInputPricesByPricingGroupId[$pricingGroupWithNullPriceId] = null; @@ -552,4 +540,21 @@ public function testRefreshProductsVisibilityNotVisibleMainVariant() $this->assertFalse($variant3->isVisible()); $this->assertFalse($mainVariant->isVisible()); } + + /** + * @param \Shopsys\FrameworkBundle\Model\Product\ProductData $productData + * @param $price + */ + private function setPriceForAllDomains(ProductData $productData, $price) + { + /** @var \Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroupFacade $pricingGroupFacade */ + $pricingGroupFacade = $this->getContainer()->get(PricingGroupFacade::class); + + $manualInputPrices = []; + foreach ($pricingGroupFacade->getAll() as $pricingGroup) { + $manualInputPrices[$pricingGroup->getId()] = $price; + } + + $productData->manualInputPricesByPricingGroupId = $manualInputPrices; + } } diff --git a/tests/ShopBundle/Smoke/NewProductTest.php b/tests/ShopBundle/Smoke/NewProductTest.php index 1bfb9a901..db5464ad8 100644 --- a/tests/ShopBundle/Smoke/NewProductTest.php +++ b/tests/ShopBundle/Smoke/NewProductTest.php @@ -6,6 +6,7 @@ use Shopsys\FrameworkBundle\DataFixtures\Demo\UnitDataFixture; use Shopsys\FrameworkBundle\DataFixtures\Demo\VatDataFixture; use Shopsys\FrameworkBundle\Form\Admin\Product\ProductFormType; +use Shopsys\FrameworkBundle\Model\Pricing\Group\PricingGroupFacade; use Symfony\Component\DomCrawler\Form; use Symfony\Component\Security\Csrf\CsrfToken; use Tests\ShopBundle\Test\FunctionalTestCase; @@ -66,7 +67,7 @@ private function fillForm(Form $form) $form['product_form[basicInformationGroup][partno]'] = '123456'; $form['product_form[basicInformationGroup][ean]'] = '123456'; $form['product_form[descriptionsGroup][descriptions][1]'] = 'test description'; - $form['product_form[pricesGroup][productCalculatedPricesGroup][price]'] = '10000'; + $this->fillManualInputPrices($form); $form['product_form[pricesGroup][vat]']->select($this->getReference(VatDataFixture::VAT_ZERO)->getId()); $form['product_form[displayAvailabilityGroup][sellingFrom]'] = '1.1.1990'; $form['product_form[displayAvailabilityGroup][sellingTo]'] = '1.1.2000'; @@ -83,4 +84,19 @@ private function setFormCsrfToken(Form $form, CsrfToken $token) { $form['product_form[_token]'] = $token->getValue(); } + + /** + * @param \Symfony\Component\DomCrawler\Form $form + */ + private function fillManualInputPrices(Form $form) + { + $pricingGroupFacade = $this->getContainer()->get(PricingGroupFacade::class); + foreach ($pricingGroupFacade->getAll() as $pricingGroup) { + $inputName = sprintf( + 'product_form[pricesGroup][productCalculatedPricesGroup][manualInputPricesByPricingGroupId][%s]', + $pricingGroup->getId() + ); + $form[$inputName] = '10000'; + } + } } From 3560e7a15ff51d813f92b46bb7971f60643761c3 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Tue, 11 Dec 2018 13:47:46 +0100 Subject: [PATCH 14/19] changed Shopsys\Environment class for consistent env setting during composer install - see shopsys/project-base@eedcf2ea9eaaef6c4f53a83fedbbd3c34428af83 --- app/Environment.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/app/Environment.php b/app/Environment.php index 55e82f94c..07311a53e 100644 --- a/app/Environment.php +++ b/app/Environment.php @@ -22,12 +22,11 @@ public static function checkEnvironment(Event $event) $io = $event->getIO(); /* @var $io \Composer\IO\IOInterface */ $environmentFileSetting = self::getEnvironmentFileSetting(); - if ($io->isInteractive() && !$environmentFileSetting->isAnyEnvironmentSet()) { - if ($io->askConfirmation('Build in production environment? (Y/n): ', true)) { - $environmentFileSetting->createFileForEnvironment(EnvironmentType::PRODUCTION); - } else { - $environmentFileSetting->createFileForEnvironment(EnvironmentType::DEVELOPMENT); - } + if (!$environmentFileSetting->isAnyEnvironmentSet()) { + $environment = $event->isDevMode() ? EnvironmentType::DEVELOPMENT : EnvironmentType::PRODUCTION; + $environmentFileSetting->createFileForEnvironment($environment); + $environmentFilePath = $environmentFileSetting->getEnvironmentFilePath($environment); + $io->write(sprintf('Created a file "%s" to set the application environment!', $environmentFilePath)); } self::printEnvironmentInfo($io); } From c477436320888917deb193a552029e1fc35bc06f Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Tue, 11 Dec 2018 15:46:47 +0100 Subject: [PATCH 15/19] dependencies on shopsys packages updated to beta4 version --- composer.json | 20 +++---- composer.lock | 162 +++++++++++++++++++++++++------------------------- 2 files changed, 91 insertions(+), 91 deletions(-) diff --git a/composer.json b/composer.json index e2316b167..82921bf3d 100644 --- a/composer.json +++ b/composer.json @@ -68,15 +68,15 @@ "sensio/framework-extra-bundle": "^3.0.29", "sensio/generator-bundle": "^3.1.7", "shopsys/doctrine-orm": "2.6.2", - "shopsys/migrations": "v7.0.0-beta3", - "shopsys/form-types-bundle": "v7.0.0-beta3", - "shopsys/framework": "v7.0.0-beta3", - "shopsys/plugin-interface": "v7.0.0-beta3", + "shopsys/migrations": "v7.0.0-beta4", + "shopsys/form-types-bundle": "v7.0.0-beta4", + "shopsys/framework": "v7.0.0-beta4", + "shopsys/plugin-interface": "v7.0.0-beta4", "shopsys/postgres-search-bundle": "0.1", - "shopsys/product-feed-heureka": "v7.0.0-beta3", - "shopsys/product-feed-heureka-delivery": "v7.0.0-beta3", - "shopsys/product-feed-zbozi": "v7.0.0-beta3", - "shopsys/product-feed-google": "v7.0.0-beta3", + "shopsys/product-feed-heureka": "v7.0.0-beta4", + "shopsys/product-feed-heureka-delivery": "v7.0.0-beta4", + "shopsys/product-feed-zbozi": "v7.0.0-beta4", + "shopsys/product-feed-google": "v7.0.0-beta4", "snc/redis-bundle": "2.1.4", "stof/doctrine-extensions-bundle": "^1.3.0", "symfony/assetic-bundle": "^2.8.2", @@ -96,8 +96,8 @@ "codeception/codeception": "^2.5.0", "phpstan/phpstan": "^0.7", "phpunit/phpunit": "^7.0", - "shopsys/coding-standards": "v7.0.0-beta3", - "shopsys/http-smoke-testing": "v7.0.0-beta3" + "shopsys/coding-standards": "v7.0.0-beta4", + "shopsys/http-smoke-testing": "v7.0.0-beta4" }, "conflict": { "symfony/dependency-injection": "3.4.15|3.4.16" diff --git a/composer.lock b/composer.lock index 060a9e248..de70be0e2 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "90feccfe2e603fe0356b342474c49483", + "content-hash": "e2f6dd44d4787b578f75e7721a5988f3", "packages": [ { "name": "arvenil/ninja-mutex", @@ -4956,16 +4956,16 @@ }, { "name": "sensiolabs/security-checker", - "version": "v5.0.1", + "version": "v5.0.2", "source": { "type": "git", "url": "https://github.com/sensiolabs/security-checker.git", - "reference": "9ea927417c949039a9cfb0d92af76fd1c538d9e9" + "reference": "728f9fb0fe815003b3bcfd331d33106c0d8a6b1e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sensiolabs/security-checker/zipball/9ea927417c949039a9cfb0d92af76fd1c538d9e9", - "reference": "9ea927417c949039a9cfb0d92af76fd1c538d9e9", + "url": "https://api.github.com/repos/sensiolabs/security-checker/zipball/728f9fb0fe815003b3bcfd331d33106c0d8a6b1e", + "reference": "728f9fb0fe815003b3bcfd331d33106c0d8a6b1e", "shasum": "" }, "require": { @@ -4998,7 +4998,7 @@ } ], "description": "A security checker for your composer.lock", - "time": "2018-10-16T10:30:44+00:00" + "time": "2018-12-10T06:08:43+00:00" }, { "name": "shopsys/doctrine-orm", @@ -5087,16 +5087,16 @@ }, { "name": "shopsys/form-types-bundle", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/form-types-bundle.git", - "reference": "bc0b7335b4f5292fb2abbe351b2755e4d642902b" + "reference": "192c3e60e9f2d64acaf3d8c0f75d0bed58ab3ca4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/form-types-bundle/zipball/bc0b7335b4f5292fb2abbe351b2755e4d642902b", - "reference": "bc0b7335b4f5292fb2abbe351b2755e4d642902b", + "url": "https://api.github.com/repos/shopsys/form-types-bundle/zipball/192c3e60e9f2d64acaf3d8c0f75d0bed58ab3ca4", + "reference": "192c3e60e9f2d64acaf3d8c0f75d0bed58ab3ca4", "shasum": "" }, "require": { @@ -5113,7 +5113,7 @@ "symfony/dependency-injection": "3.4.15|3.4.16" }, "require-dev": { - "shopsys/coding-standards": "7.0.0-beta3" + "shopsys/coding-standards": "7.0.0-beta4" }, "type": "library", "autoload": { @@ -5138,20 +5138,20 @@ "Shopsys Framework", "form" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/framework", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/framework.git", - "reference": "7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5" + "reference": "35ee8868c8a0832b7eb2685c7854688d16a3da65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/framework/zipball/7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5", - "reference": "7a5ffdc4dc7cb49b669f5ed4296b7fe5d2137ee5", + "url": "https://api.github.com/repos/shopsys/framework/zipball/35ee8868c8a0832b7eb2685c7854688d16a3da65", + "reference": "35ee8868c8a0832b7eb2685c7854688d16a3da65", "shasum": "" }, "require": { @@ -5206,10 +5206,10 @@ "sensio/distribution-bundle": "^5.0.21", "sensio/framework-extra-bundle": "^3.0.29", "shopsys/doctrine-orm": "^2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta3", + "shopsys/form-types-bundle": "7.0.0-beta4", "shopsys/jparser": "0.1", - "shopsys/migrations": "7.0.0-beta3", - "shopsys/plugin-interface": "7.0.0-beta3", + "shopsys/migrations": "7.0.0-beta4", + "shopsys/plugin-interface": "7.0.0-beta4", "shopsys/postgres-search-bundle": "0.1", "snc/redis-bundle": "2.1.4", "stof/doctrine-extensions-bundle": "^1.3.0", @@ -5229,7 +5229,7 @@ "require-dev": { "phpstan/phpstan": "^0.7", "phpunit/phpunit": "^7.0", - "shopsys/coding-standards": "7.0.0-beta3" + "shopsys/coding-standards": "7.0.0-beta4" }, "suggest": { "ext-pgsql": "Required for dumping the Postgres database in shopsys:database:dump command" @@ -5249,7 +5249,7 @@ "proprietary" ], "description": "Core of Shopsys Framework - open source framework for building large, scalable, fast-growing e-commerce projects based on Symfony", - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/jparser", @@ -5293,16 +5293,16 @@ }, { "name": "shopsys/migrations", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/migrations.git", - "reference": "e53243cf0132c82fd38c444d1275169693d27b64" + "reference": "4222d14f8655c26b0db313ca32b07e0e3c39ec33" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/migrations/zipball/e53243cf0132c82fd38c444d1275169693d27b64", - "reference": "e53243cf0132c82fd38c444d1275169693d27b64", + "url": "https://api.github.com/repos/shopsys/migrations/zipball/4222d14f8655c26b0db313ca32b07e0e3c39ec33", + "reference": "4222d14f8655c26b0db313ca32b07e0e3c39ec33", "shasum": "" }, "require": { @@ -5325,7 +5325,7 @@ }, "require-dev": { "phpunit/phpunit": "^5.7|^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta3" + "shopsys/coding-standards": "7.0.0-beta4" }, "type": "library", "autoload": { @@ -5352,20 +5352,20 @@ "orm", "schema" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/plugin-interface", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/plugin-interface.git", - "reference": "215e1431ff2cb45d899ad5fba4fef14f9eda9d87" + "reference": "c6e5e8a5522dc34827899b73acd8881f6957e77f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/plugin-interface/zipball/215e1431ff2cb45d899ad5fba4fef14f9eda9d87", - "reference": "215e1431ff2cb45d899ad5fba4fef14f9eda9d87", + "url": "https://api.github.com/repos/shopsys/plugin-interface/zipball/c6e5e8a5522dc34827899b73acd8881f6957e77f", + "reference": "c6e5e8a5522dc34827899b73acd8881f6957e77f", "shasum": "" }, "require": { @@ -5373,7 +5373,7 @@ "symfony/monolog-bridge": "^3.0.0" }, "require-dev": { - "shopsys/coding-standards": "7.0.0-beta3" + "shopsys/coding-standards": "7.0.0-beta4" }, "type": "library", "autoload": { @@ -5397,7 +5397,7 @@ "Shopsys Framework", "plugin" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/postgres-search-bundle", @@ -5447,16 +5447,16 @@ }, { "name": "shopsys/product-feed-google", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-google.git", - "reference": "17495ea17a33e4a9aad7f880c318d9d4465b0781" + "reference": "93d0370e4c4b0c12a1995177fe2752b11fd1f72d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-google/zipball/17495ea17a33e4a9aad7f880c318d9d4465b0781", - "reference": "17495ea17a33e4a9aad7f880c318d9d4465b0781", + "url": "https://api.github.com/repos/shopsys/product-feed-google/zipball/93d0370e4c4b0c12a1995177fe2752b11fd1f72d", + "reference": "93d0370e4c4b0c12a1995177fe2752b11fd1f72d", "shasum": "" }, "require": { @@ -5466,10 +5466,10 @@ "ext-pdo": "*", "php": "^7.1", "shopsys/doctrine-orm": "^2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta3", - "shopsys/framework": "7.0.0-beta3", - "shopsys/migrations": "7.0.0-beta3", - "shopsys/plugin-interface": "7.0.0-beta3", + "shopsys/form-types-bundle": "7.0.0-beta4", + "shopsys/framework": "7.0.0-beta4", + "shopsys/migrations": "7.0.0-beta4", + "shopsys/plugin-interface": "7.0.0-beta4", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5477,7 +5477,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta3", + "shopsys/coding-standards": "7.0.0-beta4", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5506,20 +5506,20 @@ "plugin", "product feed" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/product-feed-heureka", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-heureka.git", - "reference": "2d0b987e62207060527ae41dcea2fedd7ea06f6c" + "reference": "7632bdd9ccd92485aca612384d0e0a276f46fcd8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-heureka/zipball/2d0b987e62207060527ae41dcea2fedd7ea06f6c", - "reference": "2d0b987e62207060527ae41dcea2fedd7ea06f6c", + "url": "https://api.github.com/repos/shopsys/product-feed-heureka/zipball/7632bdd9ccd92485aca612384d0e0a276f46fcd8", + "reference": "7632bdd9ccd92485aca612384d0e0a276f46fcd8", "shasum": "" }, "require": { @@ -5532,10 +5532,10 @@ "ext-simplexml": "*", "php": "^7.1", "shopsys/doctrine-orm": "^2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta3", - "shopsys/framework": "7.0.0-beta3", - "shopsys/migrations": "7.0.0-beta3", - "shopsys/plugin-interface": "7.0.0-beta3", + "shopsys/form-types-bundle": "7.0.0-beta4", + "shopsys/framework": "7.0.0-beta4", + "shopsys/migrations": "7.0.0-beta4", + "shopsys/plugin-interface": "7.0.0-beta4", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5543,7 +5543,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta3", + "shopsys/coding-standards": "7.0.0-beta4", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5572,29 +5572,29 @@ "plugin", "product feed" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/product-feed-heureka-delivery", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-heureka-delivery.git", - "reference": "35c4300ab238b98db228857e2fa481cf797d2fa6" + "reference": "d2fba7dc313aedd64a918833bd9aeeee7b0e042c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-heureka-delivery/zipball/35c4300ab238b98db228857e2fa481cf797d2fa6", - "reference": "35c4300ab238b98db228857e2fa481cf797d2fa6", + "url": "https://api.github.com/repos/shopsys/product-feed-heureka-delivery/zipball/d2fba7dc313aedd64a918833bd9aeeee7b0e042c", + "reference": "d2fba7dc313aedd64a918833bd9aeeee7b0e042c", "shasum": "" }, "require": { "php": "^7.1", "shopsys/doctrine-orm": "^2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta3", - "shopsys/framework": "7.0.0-beta3", - "shopsys/migrations": "7.0.0-beta3", - "shopsys/plugin-interface": "7.0.0-beta3", + "shopsys/form-types-bundle": "7.0.0-beta4", + "shopsys/framework": "7.0.0-beta4", + "shopsys/migrations": "7.0.0-beta4", + "shopsys/plugin-interface": "7.0.0-beta4", "symfony/config": "^3.4", "symfony/dependency-injection": "^3.4", "symfony/framework-bundle": "^3.4", @@ -5605,7 +5605,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta3", + "shopsys/coding-standards": "7.0.0-beta4", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5634,20 +5634,20 @@ "plugin", "product delivery feed" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "shopsys/product-feed-zbozi", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/product-feed-zbozi.git", - "reference": "3b09a73a9900319caaf461210e6aedc99ecc712f" + "reference": "5ac301c585feb2641aab6706897b4929ad6cbf2d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/shopsys/product-feed-zbozi/zipball/3b09a73a9900319caaf461210e6aedc99ecc712f", - "reference": "3b09a73a9900319caaf461210e6aedc99ecc712f", + "url": "https://api.github.com/repos/shopsys/product-feed-zbozi/zipball/5ac301c585feb2641aab6706897b4929ad6cbf2d", + "reference": "5ac301c585feb2641aab6706897b4929ad6cbf2d", "shasum": "" }, "require": { @@ -5657,10 +5657,10 @@ "ext-pdo": "*", "php": "^7.1", "shopsys/doctrine-orm": "^2.6.2", - "shopsys/form-types-bundle": "7.0.0-beta3", - "shopsys/framework": "7.0.0-beta3", - "shopsys/migrations": "7.0.0-beta3", - "shopsys/plugin-interface": "7.0.0-beta3", + "shopsys/form-types-bundle": "7.0.0-beta4", + "shopsys/framework": "7.0.0-beta4", + "shopsys/migrations": "7.0.0-beta4", + "shopsys/plugin-interface": "7.0.0-beta4", "symfony/symfony": "^3.4.8" }, "conflict": { @@ -5668,7 +5668,7 @@ }, "require-dev": { "phpunit/phpunit": "^6.0|^7.0", - "shopsys/coding-standards": "7.0.0-beta3", + "shopsys/coding-standards": "7.0.0-beta4", "twig/extensions": "^1.5.1", "twig/twig": "^2.4.8" }, @@ -5697,7 +5697,7 @@ "product feed", "zbozi" ], - "time": "2018-11-27T09:20:15+00:00" + "time": "2018-11-28T16:58:49+00:00" }, { "name": "snc/redis-bundle", @@ -7332,21 +7332,21 @@ }, { "name": "codeception/phpunit-wrapper", - "version": "7.1.4", + "version": "7.5.0", "source": { "type": "git", "url": "https://github.com/Codeception/phpunit-wrapper.git", - "reference": "f18ed631f1eddbb603d72219f577d223b23a1f89" + "reference": "c4272e2d140ff408c8a93fa9aec659a8621cbd58" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Codeception/phpunit-wrapper/zipball/f18ed631f1eddbb603d72219f577d223b23a1f89", - "reference": "f18ed631f1eddbb603d72219f577d223b23a1f89", + "url": "https://api.github.com/repos/Codeception/phpunit-wrapper/zipball/c4272e2d140ff408c8a93fa9aec659a8621cbd58", + "reference": "c4272e2d140ff408c8a93fa9aec659a8621cbd58", "shasum": "" }, "require": { "phpunit/php-code-coverage": "^6.0", - "phpunit/phpunit": "^7.1", + "phpunit/phpunit": ">=7.1 <7.6", "sebastian/comparator": "^3.0", "sebastian/diff": "^3.0" }, @@ -7371,7 +7371,7 @@ } ], "description": "PHPUnit classes used by Codeception", - "time": "2018-06-20T20:07:21+00:00" + "time": "2018-12-07T10:48:17+00:00" }, { "name": "codeception/stub", @@ -9661,7 +9661,7 @@ }, { "name": "shopsys/coding-standards", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/coding-standards.git", @@ -9715,7 +9715,7 @@ }, { "name": "shopsys/http-smoke-testing", - "version": "v7.0.0-beta3", + "version": "v7.0.0-beta4", "source": { "type": "git", "url": "https://github.com/shopsys/http-smoke-testing.git", From 7bd924840c81503544217a1c0e37e04c3cafb095 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Thu, 13 Dec 2018 11:52:42 +0100 Subject: [PATCH 16/19] block loading of original data fixtures, if overridden - overriden data fixtures can be loaded before original, resulting in unwanted data and block loading of original data fixtures fix this problem - see shopsys/shopsys#568 --- src/Shopsys/ShopBundle/Resources/config/services.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Shopsys/ShopBundle/Resources/config/services.yml b/src/Shopsys/ShopBundle/Resources/config/services.yml index 6ab800c45..e712175dd 100644 --- a/src/Shopsys/ShopBundle/Resources/config/services.yml +++ b/src/Shopsys/ShopBundle/Resources/config/services.yml @@ -40,6 +40,10 @@ services: Shopsys\ShopBundle\Form\Front\Order\DomainAwareOrderFlowFactory: ~ + # Don't load data fixtures from FrameworkBundle, because they are overridden in ShopBundle + Shopsys\FrameworkBundle\DataFixtures\Demo\MailTemplateDataFixture: ~ + Shopsys\FrameworkBundle\DataFixtures\Demo\MultidomainMailTemplateDataFixture: ~ + Shopsys\FrameworkBundle\Model\Order\OrderFlowFactoryInterface: '@Shopsys\ShopBundle\Form\Front\Order\DomainAwareOrderFlowFactory' Shopsys\FrameworkBundle\Model\Article\ArticleFactoryInterface: '@Shopsys\ShopBundle\Model\Article\ArticleFactory' From 60e06b75f16dd8906088e31061d742aac83427bf Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 14 Dec 2018 11:57:49 +0100 Subject: [PATCH 17/19] webserver container now starts after php-fpm is started - see shopsys/shopsys#679 --- docker/conf/docker-compose-mac.yml.dist | 2 ++ docker/conf/docker-compose-win.yml.dist | 2 ++ docker/conf/docker-compose.yml.dist | 2 ++ 3 files changed, 6 insertions(+) diff --git a/docker/conf/docker-compose-mac.yml.dist b/docker/conf/docker-compose-mac.yml.dist index 070964994..22f5215ad 100644 --- a/docker/conf/docker-compose-mac.yml.dist +++ b/docker/conf/docker-compose-mac.yml.dist @@ -15,6 +15,8 @@ services: webserver: image: nginx:1.13-alpine container_name: shopsys-framework-webserver + depends_on: + - php-fpm volumes: - shopsys-framework-web-sync:/var/www/html/web - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf:delegated diff --git a/docker/conf/docker-compose-win.yml.dist b/docker/conf/docker-compose-win.yml.dist index 992f4ee3e..b2d95ac67 100644 --- a/docker/conf/docker-compose-win.yml.dist +++ b/docker/conf/docker-compose-win.yml.dist @@ -15,6 +15,8 @@ services: webserver: image: nginx:1.13-alpine container_name: shopsys-framework-webserver + depends_on: + - php-fpm volumes: - shopsys-framework-web-sync:/var/www/html/web - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf diff --git a/docker/conf/docker-compose.yml.dist b/docker/conf/docker-compose.yml.dist index dab65f074..4308493d6 100644 --- a/docker/conf/docker-compose.yml.dist +++ b/docker/conf/docker-compose.yml.dist @@ -15,6 +15,8 @@ services: webserver: image: nginx:1.13-alpine container_name: shopsys-framework-webserver + depends_on: + - php-fpm volumes: - .:/var/www/html - ./docker/nginx/nginx.conf:/etc/nginx/conf.d/default.conf From 0d3358cfb6c4edac22f3a0ae3c3d9754308eb510 Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 14 Dec 2018 14:25:32 +0100 Subject: [PATCH 18/19] fixed wrong links in mail template data fixtures --- .../DataFixtures/Demo/MailTemplateDataFixture.php | 4 ++-- .../DemoMultidomain/MailTemplateDataFixture.php | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php b/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php index 116ff2d2a..370232da1 100644 --- a/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php +++ b/src/Shopsys/ShopBundle/DataFixtures/Demo/MailTemplateDataFixture.php @@ -303,7 +303,7 @@ public function load(ObjectManager $manager) Dear customer,
- For your email, we record personal overview that you can view here.
+ For your email, we record personal overview that you can view here.
The link is valid for 24 hours.


@@ -335,7 +335,7 @@ public function load(ObjectManager $manager) Dear customer,
- You can find your personal information export here.
+ You can find your personal information export here.
The link is valid for 24 hours.

Regards,
diff --git a/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php b/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php index 4a2663089..309678ea3 100644 --- a/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php +++ b/src/Shopsys/ShopBundle/DataFixtures/DemoMultidomain/MailTemplateDataFixture.php @@ -62,7 +62,7 @@ public function load(ObjectManager $manager) Dobrý den,,
- Vaše objednávka byla úspěšně vytvořena. Stav objednávky můžete sledovat na tomto odkaze. O změně stavu objednávky Vás budeme informovat.
+ Vaše objednávka byla úspěšně vytvořena. Stav objednávky můžete sledovat na tomto odkaze. O změně stavu objednávky Vás budeme informovat.
  @@ -127,7 +127,7 @@ public function load(ObjectManager $manager)
Vážený zákazníku,
- Vaše objednávka {number} se zpracovává. Více informací o Vaší objednávce naleznete zde
+ Vaše objednávka {number} se zpracovává. Více informací o Vaší objednávce naleznete zde



@@ -324,7 +324,7 @@ public function load(ObjectManager $manager)
Vážený zákazníku,
na základě vašeho zadaného emailu {e-mail}, Vám zasíláme odkaz na zobrazení osobních údajů. Klikem na odkaz níže se dostanete na stránku s přehledem všech osobních údajů, které k Vašemu e-mailu evidujeme na našem e-shopu {domain}.

- Pro zobrazení osobních údajů klikněte zde.
+ Pro zobrazení osobních údajů klikněte zde.
Odkaz je platný 24 hodin.

S pozdravem
@@ -363,7 +363,7 @@ public function load(ObjectManager $manager) Klikem na odkaz se dostanete na stránku s možností stažení těchto informací, které k
Vašemu e-mailu evidujeme na našem eshopu {domain}.

- Pro přechod na stažení údajů, prosím, klikněte zde .
+ Pro přechod na stažení údajů, prosím, klikněte zde .
Odkaz je platný 24 hodin.

S pozdravem
From 8d77412a47ac8367e3710ee0db644f5546b00e5c Mon Sep 17 00:00:00 2001 From: Martin Grossmann Date: Fri, 14 Dec 2018 14:56:39 +0100 Subject: [PATCH 19/19] updated changelog with beta4 upgrade informations --- CHANGELOG.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fd23d727e..26568742c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,9 +26,19 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - [#19 - Table tags and inline styles can be used in ckEditor for email templates](https://github.com/shopsys/demoshop/pull/19) - `ivory_ck_editor.yml` is updated so email templates wysiwyg can parse table tags and inline styles for all elements - datafixtures for email templates are added so demoshop has now customized emails +- [#27 - Upgrade to shopsys framework 7.0.0-beta4](https://github.com/shopsys/demoshop/pull/27) + - renamed Database tests to Functional tests + - content-test directory is used instead of content during the test + - updated coding standards and applied + - registered new form types (OrderItemsType, DisplayOnlyCustomerType) + - OrderFormType in Admin is extended on a class level. No need to extend twig template anymore + - block loading of original data fixtures, if overridden + - Shopsys\FrameworkBundle\DataFixtures\Demo\MailTemplateDataFixture blocked from loading, because its overridden in ShopBundle + - Shopsys\FrameworkBundle\DataFixtures\Demo\MultidomainMailTemplateDataFixture blocked from loading, because its overridden in ShopBundle + - fixed wrong links in mail template data fixtures ### Fixed - [#8 - Category now has second description attribute that is displayed on the product list page above the product list](https://github.com/shopsys/demoshop/pull/8) - GoogleFeedItemFactory: removed unused imports -[@LukasHeinz]:(https://github.com/LukasHeinz) \ No newline at end of file +[@LukasHeinz]:(https://github.com/LukasHeinz)