From: Jeremy Benoist Date: Wed, 1 Jun 2016 19:27:35 +0000 (+0200) Subject: Jump to Symfony 3.1 X-Git-Tag: 2.0.6~12^2~1 X-Git-Url: https://git.immae.eu/?p=github%2Fwallabag%2Fwallabag.git;a=commitdiff_plain;h=23634d5d842dabcf5d7475e2becb7e127824239e Jump to Symfony 3.1 --- diff --git a/.travis.yml b/.travis.yml index d397c872..7fe15c5f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -55,6 +55,6 @@ before_install: script: - travis_wait composer install --no-interaction --no-progress --prefer-dist -o - ant prepare-$DB - - bin/phpunit -v + - phpunit -v - if [ "$CS_FIXER" = "run" ]; then php bin/php-cs-fixer fix src/ --verbose --dry-run ; fi; - if [ "$VALIDATE_TRANSLATION_FILE" = "run" ]; then php bin/console lint:yaml src/Wallabag/CoreBundle/Resources/translations -v ; fi; diff --git a/app/config/config.yml b/app/config/config.yml index ea028d85..9e2e08a6 100644 --- a/app/config/config.yml +++ b/app/config/config.yml @@ -169,7 +169,7 @@ liip_theme: path_patterns: bundle_resource: - - %%bundle_path%%/Resources/views/themes/%%current_theme%%/%%template%% + - "%%bundle_path%%/Resources/views/themes/%%current_theme%%/%%template%%" fos_user: db_driver: orm @@ -177,9 +177,9 @@ fos_user: user_class: Wallabag\UserBundle\Entity\User registration: confirmation: - enabled: %fosuser_confirmation% + enabled: "%fosuser_confirmation%" from_email: - address: %from_email% + address: "%from_email%" sender_name: wallabag fos_oauth_server: db_driver: orm @@ -197,8 +197,8 @@ scheb_two_factor: cookie_lifetime: 2592000 email: - enabled: %twofactor_auth% - sender_email: %twofactor_sender% + enabled: "%twofactor_auth%" + sender_email: "%twofactor_sender%" digits: 6 template: WallabagUserBundle:Authentication:form.html.twig mailer: wallabag_user.auth_code_mailer diff --git a/app/config/config_dev.yml b/app/config/config_dev.yml index 2813e369..ec23babb 100644 --- a/app/config/config_dev.yml +++ b/app/config/config_dev.yml @@ -17,14 +17,14 @@ monolog: type: stream path: "%kernel.logs_dir%/%kernel.environment%.log" level: debug - channels: [!event] + channels: ['!event'] console: type: console bubble: false verbosity_levels: VERBOSITY_VERBOSE: INFO VERBOSITY_VERY_VERBOSE: DEBUG - channels: [!event, !doctrine] + channels: ['!event', '!doctrine'] console_very_verbose: type: console bubble: false diff --git a/app/config/config_prod.yml b/app/config/config_prod.yml index 342837a0..65b040cc 100644 --- a/app/config/config_prod.yml +++ b/app/config/config_prod.yml @@ -2,8 +2,8 @@ imports: - { resource: config.yml } #framework: -# validation: -# cache: apc +# cache: +# system: cache.adapter.apcu #doctrine: # orm: diff --git a/bin/phpunit b/bin/phpunit deleted file mode 120000 index 4ba32564..00000000 --- a/bin/phpunit +++ /dev/null @@ -1 +0,0 @@ -../vendor/phpunit/phpunit/phpunit \ No newline at end of file diff --git a/composer.json b/composer.json index c4edd3c2..90f3fd1d 100644 --- a/composer.json +++ b/composer.json @@ -43,7 +43,7 @@ "ext-iconv": "*", "ext-tokenizer": "*", "ext-pdo": "*", - "symfony/symfony": "3.0.*", + "symfony/symfony": "3.1.*", "doctrine/orm": "^2.5", "doctrine/doctrine-bundle": "^1.6", "doctrine/doctrine-cache-bundle": "^1.2", @@ -87,7 +87,7 @@ "doctrine/doctrine-fixtures-bundle": "~2.2", "sensio/generator-bundle": "^3.0", "phpunit/phpunit": "~4.4", - "symfony/phpunit-bridge": "^2.7", + "symfony/phpunit-bridge": "^3.0", "friendsofphp/php-cs-fixer": "~1.9" }, "scripts": { @@ -121,6 +121,9 @@ "psr-4": { "Wallabag\\": "src/Wallabag/" }, "classmap": [ "app/AppKernel.php", "app/AppCache.php" ] }, + "autoload-dev": { + "psr-4": { "Tests\\": "tests/" } + }, "config": { "bin-dir": "bin" }, diff --git a/phpunit.xml.dist b/phpunit.xml.dist index e68df9de..38880908 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,24 +1,20 @@ - +> - src/Wallabag/*Bundle/Tests + tests + diff --git a/src/Wallabag/CoreBundle/Form/Type/ConfigType.php b/src/Wallabag/CoreBundle/Form/Type/ConfigType.php index 4cf22200..74c53bf0 100644 --- a/src/Wallabag/CoreBundle/Form/Type/ConfigType.php +++ b/src/Wallabag/CoreBundle/Form/Type/ConfigType.php @@ -32,7 +32,6 @@ class ConfigType extends AbstractType $builder ->add('theme', ChoiceType::class, [ 'choices' => array_flip($this->themes), - 'choices_as_values' => true, 'label' => 'config.form_settings.theme_label', ]) ->add('items_per_page', null, [ @@ -49,7 +48,6 @@ class ConfigType extends AbstractType ]) ->add('language', ChoiceType::class, [ 'choices' => array_flip($this->languages), - 'choices_as_values' => true, 'label' => 'config.form_settings.language_label', ]) ->add('save', SubmitType::class, [ diff --git a/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php b/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php index f3f848e9..bc59c9a1 100644 --- a/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php +++ b/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php @@ -113,7 +113,6 @@ class EntryFilterType extends AbstractType ]) ->add('language', ChoiceFilterType::class, [ 'choices' => array_flip($this->repository->findDistinctLanguageByUser($this->user->getId())), - 'choices_as_values' => true, 'label' => 'entry.filters.language_label', ]) ; diff --git a/src/Wallabag/AnnotationBundle/Tests/Controller/AnnotationControllerTest.php b/tests/Wallabag/AnnotationBundle/Controller/AnnotationControllerTest.php similarity index 97% rename from src/Wallabag/AnnotationBundle/Tests/Controller/AnnotationControllerTest.php rename to tests/Wallabag/AnnotationBundle/Controller/AnnotationControllerTest.php index 3eba7193..70849f74 100644 --- a/src/Wallabag/AnnotationBundle/Tests/Controller/AnnotationControllerTest.php +++ b/tests/Wallabag/AnnotationBundle/Controller/AnnotationControllerTest.php @@ -1,8 +1,8 @@ unregister(); -$apcLoader->register(true); -*/ - $kernel = new AppKernel('prod', false); $kernel->loadClassCache(); //$kernel = new AppCache($kernel);