From 8e18df8c3698701a6526bf8eb6f34ff85326693f Mon Sep 17 00:00:00 2001 From: Pantheon Automation Date: Wed, 21 Oct 2015 21:44:50 -0700 Subject: [PATCH] Update to drupal-org-drupal 8.0.0-rc2. For more information, see https://www.drupal.org/node/2598668 --- .eslintrc | 1 + composer.json | 4 +- core/INSTALL.txt | 4 +- core/UPGRADE.txt | 48 +- core/assets/vendor/modernizr/modernizr.min.js | 7 +- core/core.libraries.yml | 2 +- core/core.services.yml | 3 +- core/includes/batch.inc | 1 - core/includes/bootstrap.inc | 8 - core/includes/common.inc | 17 - core/includes/entity.inc | 2 - core/includes/file.inc | 2 - core/includes/form.inc | 5 - core/includes/install.core.inc | 1 - core/includes/module.inc | 1 - core/includes/pager.inc | 1 - core/includes/schema.inc | 2 - core/includes/theme.inc | 5 +- core/includes/update.inc | 1 - core/includes/utility.inc | 1 - core/lib/Drupal.php | 2 +- .../Component/Datetime/DateTimePlus.php | 10 +- .../Component/Diff/Engine/DiffEngine.php | 2 +- .../Component/Gettext/PoMemoryWriter.php | 4 - .../Component/Gettext/PoMetadataInterface.php | 2 - .../Component/Gettext/PoReaderInterface.php | 2 - .../Component/Gettext/PoStreamReader.php | 3 - .../Component/Gettext/PoStreamWriter.php | 6 - .../Component/Gettext/PoWriterInterface.php | 3 - .../SecuredRedirectResponse.php | 14 +- .../Exception/InvalidDecoratedMethod.php | 1 - .../Drupal/Component/Utility/SafeMarkup.php | 2 +- .../Core/Action/ConfigurableActionBase.php | 1 - core/lib/Drupal/Core/Ajax/AddCssCommand.php | 2 - core/lib/Drupal/Core/Ajax/AfterCommand.php | 2 - core/lib/Drupal/Core/Ajax/AjaxResponse.php | 5 - core/lib/Drupal/Core/Ajax/AlertCommand.php | 2 - core/lib/Drupal/Core/Ajax/AppendCommand.php | 2 - core/lib/Drupal/Core/Ajax/BeforeCommand.php | 2 - core/lib/Drupal/Core/Ajax/ChangedCommand.php | 2 - .../Core/Ajax/CloseModalDialogCommand.php | 2 - core/lib/Drupal/Core/Ajax/CssCommand.php | 2 - core/lib/Drupal/Core/Ajax/DataCommand.php | 2 - core/lib/Drupal/Core/Ajax/HtmlCommand.php | 2 - core/lib/Drupal/Core/Ajax/InsertCommand.php | 2 - core/lib/Drupal/Core/Ajax/InvokeCommand.php | 2 - .../Drupal/Core/Ajax/OpenDialogCommand.php | 2 - .../Core/Ajax/OpenModalDialogCommand.php | 2 - core/lib/Drupal/Core/Ajax/PrependCommand.php | 2 - core/lib/Drupal/Core/Ajax/RedirectCommand.php | 2 - core/lib/Drupal/Core/Ajax/RemoveCommand.php | 2 - core/lib/Drupal/Core/Ajax/ReplaceCommand.php | 2 - core/lib/Drupal/Core/Ajax/RestripeCommand.php | 2 - .../Core/Ajax/SetDialogTitleCommand.php | 2 - core/lib/Drupal/Core/Ajax/SettingsCommand.php | 2 - core/lib/Drupal/Core/Asset/AssetDumper.php | 1 - .../Core/Asset/CssCollectionGrouper.php | 2 - core/lib/Drupal/Core/Asset/CssOptimizer.php | 1 - .../Drupal/Core/Asset/JsCollectionGrouper.php | 2 - core/lib/Drupal/Core/Asset/JsOptimizer.php | 1 - .../Core/Asset/LibraryDiscoveryParser.php | 1 - core/lib/Drupal/Core/Cache/ApcuBackend.php | 12 +- core/lib/Drupal/Core/Cache/CacheFactory.php | 1 - .../Core/Cache/CacheableRedirectResponse.php | 26 + core/lib/Drupal/Core/Composer/Composer.php | 137 + .../Core/Condition/ConditionPluginBase.php | 2 - core/lib/Drupal/Core/Config/CachedStorage.php | 1 - .../Drupal/Core/Config/ConfigInstaller.php | 1 - .../Core/Config/Entity/ConfigEntityBase.php | 2 - .../Entity/ConfigEntityStorageInterface.php | 1 - .../Core/Config/Entity/Query/Condition.php | 2 +- .../Core/Config/StorageComparerInterface.php | 2 +- .../Config/Testing/ConfigSchemaChecker.php | 24 +- .../Drupal/Core/Config/TypedConfigManager.php | 1 - .../Core/Database/Driver/mysql/Schema.php | 1 - .../Core/Database/Driver/pgsql/Connection.php | 3 - .../Core/Database/Driver/pgsql/Schema.php | 2 - .../Drupal/Core/Database/Query/Condition.php | 4 +- .../Database/Query/PagerSelectExtender.php | 2 - core/lib/Drupal/Core/Database/Schema.php | 1 - .../Core/Datetime/DateFormatInterface.php | 1 - .../Drupal/Core/Datetime/DateFormatter.php | 1 - core/lib/Drupal/Core/Datetime/DateHelper.php | 10 +- .../Core/Datetime/Element/DateElementBase.php | 2 +- .../Drupal/Core/Datetime/Element/Datelist.php | 12 +- .../Drupal/Core/Datetime/Element/Datetime.php | 6 +- .../Compiler/ProxyServicesPass.php | 2 - .../Compiler/RegisterStreamWrappersPass.php | 2 - core/lib/Drupal/Core/DrupalKernel.php | 2 - .../Entity/Controller/EntityController.php | 143 + .../Controller/EntityListController.php | 1 - core/lib/Drupal/Core/Entity/Entity.php | 1 - .../EntityAccessControlHandlerInterface.php | 1 - .../Core/Entity/EntityConfirmFormBase.php | 1 - .../Drupal/Core/Entity/EntityListBuilder.php | 1 - core/lib/Drupal/Core/Entity/EntityManager.php | 3 +- .../Core/Entity/EntityManagerInterface.php | 4 +- .../Entity/Query/ConditionFundamentals.php | 2 +- .../Core/Entity/Query/Sql/Condition.php | 2 +- .../Entity/Query/Sql/ConditionAggregate.php | 2 +- .../Core/Entity/Query/Sql/QueryFactory.php | 1 - .../Entity/Routing/AdminHtmlRouteProvider.php | 44 + .../Routing/DefaultHtmlRouteProvider.php | 135 + core/lib/Drupal/Core/Entity/entity.api.php | 23 +- .../ActiveLinkResponseFilter.php | 2 - .../AnonymousUserResponseSubscriber.php | 1 - ...lyRenderingControllerWrapperSubscriber.php | 1 - .../EntityRouteProviderSubscriber.php | 8 +- .../FinishResponseSubscriber.php | 28 +- .../HttpExceptionSubscriberBase.php | 2 +- .../EventSubscriber/PathRootsSubscriber.php | 1 - .../RedirectLeadingSlashesSubscriber.php | 4 +- .../RedirectResponseSubscriber.php | 4 +- .../RouterRebuildSubscriber.php | 4 - .../Core/Executable/ExecutablePluginBase.php | 1 - .../Drupal/Core/Extension/ModuleHandler.php | 1 - core/lib/Drupal/Core/Extension/module.api.php | 1 - .../lib/Drupal/Core/Field/FieldConfigBase.php | 6 +- .../Drupal/Core/Field/FieldFilteredMarkup.php | 1 - .../Drupal/Core/Field/FormatterInterface.php | 2 +- .../EntityReferenceEntityFormatter.php | 1 - .../EntityReferenceIdFormatter.php | 1 - .../Field/Plugin/Field/FieldType/MapItem.php | 1 - core/lib/Drupal/Core/Form/ConfigFormBase.php | 1 - core/lib/Drupal/Core/Form/FormCache.php | 1 - .../Core/ImageToolkit/ImageToolkitBase.php | 1 - .../ImageToolkit/ImageToolkitInterface.php | 1 - .../KeyValueDatabaseExpirableFactory.php | 1 - .../KeyValueStore/KeyValueDatabaseFactory.php | 1 - .../KeyValueExpirableFactory.php | 2 - .../Language/LanguageManagerInterface.php | 1 - .../Drupal/Core/Menu/LocalTaskInterface.php | 6 +- .../Drupal/Core/Menu/MenuLinkInterface.php | 2 +- core/lib/Drupal/Core/Menu/MenuLinkTree.php | 2 - .../Menu/Plugin/Block/LocalActionsBlock.php | 1 - core/lib/Drupal/Core/Menu/menu.api.php | 2 +- .../ParamConverter/ParamConverterManager.php | 2 - core/lib/Drupal/Core/Path/AliasManager.php | 18 +- core/lib/Drupal/Core/Path/AliasWhitelist.php | 1 - .../Core/Plugin/CachedDiscoveryClearer.php | 2 - .../lib/Drupal/Core/Render/Element/Button.php | 17 + .../Drupal/Core/Render/Element/Details.php | 2 +- .../Drupal/Core/Render/Element/Dropbutton.php | 30 + .../lib/Drupal/Core/Render/Element/Hidden.php | 13 + core/lib/Drupal/Core/Render/Element/Link.php | 1 - .../Drupal/Core/Render/Element/Operations.php | 2 + .../lib/Drupal/Core/Render/Element/Submit.php | 16 + core/lib/Drupal/Core/Render/Element/Value.php | 14 +- .../HtmlResponseAttachmentsProcessor.php | 2 - .../Core/Render/MainContent/HtmlRenderer.php | 1 - .../Core/Render/MainContent/ModalRenderer.php | 1 - .../RouteProcessor/RouteProcessorCurrent.php | 1 - .../CacheableSecuredRedirectResponse.php | 37 + .../Core/Routing/LinkGeneratorTrait.php | 1 - .../Core/Routing/LocalRedirectResponse.php | 4 +- .../lib/Drupal/Core/Routing/RouteProvider.php | 2 - .../Core/Routing/RouteProviderInterface.php | 1 - .../Core/Routing/RouteSubscriberBase.php | 1 - .../Core/Routing/TrustedRedirectResponse.php | 4 +- core/lib/Drupal/Core/Routing/UrlGenerator.php | 1 - .../Core/Routing/UrlGeneratorInterface.php | 5 +- .../Core/Session/PermissionsHashGenerator.php | 1 - .../ReverseProxyMiddleware.php | 19 +- .../StringTranslationTrait.php | 11 - .../StringTranslation/TranslationManager.php | 1 - core/lib/Drupal/Core/Template/Attribute.php | 8 +- .../Drupal/Core/Template/TwigEnvironment.php | 1 - .../Drupal/Core/Template/TwigExtension.php | 2 +- .../Drupal/Core/Template/TwigNodeTrans.php | 3 - .../lib/Drupal/Core/Test/TestRunnerKernel.php | 2 - .../TypedData/DataDefinitionInterface.php | 5 +- .../TypedData/Plugin/DataType/BinaryData.php | 1 - .../Core/TypedData/Plugin/DataType/Uri.php | 2 - core/lib/Drupal/Core/Url.php | 3 - .../lib/Drupal/Core/Utility/LinkGenerator.php | 1 - core/lib/Drupal/Core/Utility/Token.php | 1 - .../Core/Utility/UnroutedUrlAssembler.php | 1 - core/misc/active-link.js | 2 +- core/misc/ajax.js | 28 +- core/misc/announce.js | 2 +- core/misc/autocomplete.js | 10 +- core/misc/batch.js | 2 +- core/misc/collapse.js | 2 +- core/misc/date.js | 2 +- core/misc/debounce.js | 2 +- core/misc/details-aria.js | 2 +- core/misc/dialog/dialog.ajax.js | 2 +- core/misc/dialog/dialog.jquery-ui.js | 2 +- core/misc/dialog/dialog.js | 2 +- core/misc/dialog/dialog.position.js | 2 +- core/misc/displace.js | 2 +- core/misc/dropbutton/dropbutton.js | 2 +- core/misc/drupal.js | 2 +- core/misc/drupalSettingsLoader.js | 2 +- core/misc/form.js | 2 +- core/misc/machine-name.js | 2 +- core/misc/progress.js | 2 +- core/misc/states.js | 2 +- core/misc/tabbingmanager.js | 2 +- core/misc/tabledrag.js | 6 +- core/misc/tableheader.js | 2 +- core/misc/tableresponsive.js | 2 +- core/misc/tableselect.js | 2 +- core/misc/timezone.js | 2 +- core/misc/vertical-tabs.js | 4 +- .../modules/action/action.views_execution.inc | 2 - core/modules/aggregator/aggregator.install | 1 - .../modules/aggregator/aggregator.routing.yml | 28 - .../src/Controller/AggregatorController.php | 2 - core/modules/aggregator/src/Entity/Feed.php | 6 +- .../aggregator/src/FeedHtmlRouteProvider.php | 39 + .../aggregator/src/FeedStorageInterface.php | 1 - .../aggregator/src/ItemStorageInterface.php | 1 - .../aggregator/src/ItemStorageSchema.php | 1 - .../FieldFormatter/AggregatorXSSFormatter.php | 2 - .../aggregator/processor/DefaultProcessor.php | 1 - .../aggregator/src/Tests/AddFeedTest.php | 5 +- .../aggregator/src/Tests/FeedParserTest.php | 1 - .../Migrate/d7/MigrateAggregatorFeedTest.php | 33 +- .../Migrate/d7/MigrateAggregatorItemTest.php | 39 +- core/modules/block/js/block.admin.js | 2 +- core/modules/block/js/block.js | 2 +- .../src/Controller/BlockAddController.php | 1 - .../block/src/Controller/BlockController.php | 2 - .../BlockPageDisplayVariantSubscriber.php | 1 - .../block/src/Tests/BlockViewBuilderTest.php | 2 - .../src/Plugin/Block/TestCacheBlock.php | 1 - .../block_content/block_content.module | 4 +- .../block_content/block_content.pages.inc | 3 - .../modules/block_content/js/block_content.js | 2 +- .../src/Controller/BlockContentController.php | 1 - .../src/Entity/BlockContentType.php | 2 - .../src/Form/BlockContentTypeDeleteForm.php | 1 - .../src/Plugin/Block/BlockContentBlock.php | 1 - .../src/Tests/BlockContentCacheTagsTest.php | 1 - .../src/Tests/BlockContentTestBase.php | 1 - .../src/Tests/BlockContentTypeTest.php | 1 - core/modules/book/book.js | 2 +- core/modules/book/book.module | 1 - core/modules/book/src/BookExport.php | 2 - .../book/src/Controller/BookController.php | 1 - core/modules/book/src/Form/BookRemoveForm.php | 1 - core/modules/ckeditor/js/ckeditor.admin.js | 2 +- .../ckeditor/js/ckeditor.drupalimage.admin.js | 2 +- core/modules/ckeditor/js/ckeditor.js | 6 +- .../ckeditor/js/ckeditor.stylescombo.admin.js | 8 +- core/modules/ckeditor/js/models/Model.js | 2 +- .../ckeditor/js/plugins/drupalimage/plugin.js | 4 +- .../js/plugins/drupalimagecaption/plugin.js | 2 +- .../ckeditor/js/plugins/drupallink/plugin.js | 4 +- core/modules/ckeditor/js/views/AuralView.js | 30 +- .../ckeditor/js/views/ControllerView.js | 2 +- .../modules/ckeditor/js/views/KeyboardView.js | 2 +- core/modules/ckeditor/js/views/VisualView.js | 2 +- .../src/Plugin/CKEditorPlugin/StylesCombo.php | 1 - .../ckeditor/src/Plugin/Editor/CKEditor.php | 1 - .../src/Tests/CKEditorPluginManagerTest.php | 1 - .../src/Plugin/CKEditorPlugin/LlamaButton.php | 1 - .../Plugin/CKEditorPlugin/LlamaContextual.php | 1 - .../LlamaContextualAndButton.php | 1 - core/modules/color/color.js | 2 +- core/modules/color/preview.js | 2 +- .../js/color_test_theme-fontsize.js | 2 +- core/modules/comment/comment-entity-form.js | 2 +- core/modules/comment/comment.api.php | 1 - core/modules/comment/comment.module | 7 - core/modules/comment/js/comment-by-viewer.js | 2 +- .../comment/js/comment-new-indicator.js | 2 +- .../comment/js/node-new-comments-link.js | 2 +- .../d6_comment_field_instance.yml | 13 +- core/modules/comment/src/CommentForm.php | 4 +- .../comment/src/CommentLinkBuilder.php | 2 +- core/modules/comment/src/CommentManager.php | 1 - .../comment/src/CommentManagerInterface.php | 2 - core/modules/comment/src/CommentStorage.php | 2 +- .../comment/src/CommentStorageInterface.php | 2 +- core/modules/comment/src/CommentTypeForm.php | 1 - .../comment/src/CommentViewBuilder.php | 1 - .../src/Controller/CommentController.php | 2 +- .../comment/src/Entity/CommentType.php | 1 - .../src/Form/CommentTypeDeleteForm.php | 1 - .../CommentDefaultFormatter.php | 4 - .../Plugin/views/field/NodeNewComments.php | 22 +- .../src/Plugin/views/wizard/Comment.php | 1 - .../CommentDefaultFormatterCacheTagsTest.php | 1 - .../src/Tests/CommentFieldAccessTest.php | 2 +- .../comment/src/Tests/CommentFieldsTest.php | 49 + .../comment/src/Tests/CommentNonNodeTest.php | 2 +- .../comment/src/Tests/CommentPagerTest.php | 4 +- .../src/Tests/CommentTokenReplaceTest.php | 1 - .../d6/MigrateCommentVariableInstanceTest.php | 17 +- .../Tests/Migrate/d7/MigrateCommentTest.php | 7 - .../comment_empty_title_test.module | 2 - .../tests/src/Unit/Entity/CommentLockTest.php | 1 - core/modules/config/src/ConfigSubscriber.php | 1 - core/modules/config/src/Form/ConfigSync.php | 2 - .../config/src/Tests/ConfigCRUDTest.php | 1 - .../src/Tests/ConfigEntityStatusUITest.php | 1 - .../config/src/Tests/ConfigEntityUnitTest.php | 1 - .../ConfigImporterMissingContentTest.php | 2 - .../config/src/Tests/ConfigInstallTest.php | 1 - .../config/src/Tests/DefaultConfigTest.php | 1 - .../src/Tests/SchemaConfigListenerTest.php | 1 - .../src/Tests/SchemaConfigListenerWebTest.php | 2 - .../src/Tests/Storage/CachedStorageTest.php | 1 - .../tests/config_test/config_test.module | 1 - .../config_test/src/ConfigTestController.php | 1 - .../config_translation.module | 2 - .../src/ConfigEntityMapper.php | 1 - .../src/ConfigMapperInterface.php | 4 +- .../src/ConfigNamesMapper.php | 1 - .../src/Form/ConfigTranslationDeleteForm.php | 1 - .../src/Form/ConfigTranslationFormBase.php | 1 - .../ConfigTranslationContextualLinks.php | 1 - .../Tests/ConfigTranslationInstallTest.php | 79 + .../src/Tests/ConfigTranslationUiTest.php | 1 - .../src/Unit/ConfigMapperManagerTest.php | 1 - .../tests/src/Unit/ConfigNamesMapperTest.php | 3 +- .../contact/src/ContactFormEditForm.php | 1 - .../contact/src/ContactFormListBuilder.php | 2 - core/modules/contact/src/MessageForm.php | 2 - .../src/Plugin/views/field/ContactLink.php | 1 - .../contact/src/Tests/MessageEntityTest.php | 1 - .../content_translation.admin.js | 2 +- .../content_translation.install | 3 - .../src/ContentTranslationManager.php | 2 - .../ContentTranslationManagerInterface.php | 1 - .../src/FieldTranslationSynchronizer.php | 1 - .../ContentTranslationContextualLinks.php | 1 - .../ContentTranslationRouteSubscriber.php | 1 - .../Tests/ContentTestTranslationUITest.php | 13 - .../Tests/ContentTranslationUITestBase.php | 2 +- .../src/Tests/Views/TranslationLinkTest.php | 1 - .../contextual/css/contextual.theme.css | 4 +- core/modules/contextual/js/contextual.js | 2 +- .../contextual/js/contextual.toolbar.js | 2 +- .../contextual/js/models/StateModel.js | 2 +- .../js/toolbar/models/StateModel.js | 2 +- .../contextual/js/toolbar/views/AuralView.js | 2 +- .../contextual/js/toolbar/views/VisualView.js | 2 +- core/modules/contextual/js/views/AuralView.js | 2 +- .../contextual/js/views/KeyboardView.js | 2 +- .../modules/contextual/js/views/RegionView.js | 4 +- .../modules/contextual/js/views/VisualView.js | 4 +- .../contextual/src/ContextualController.php | 1 - core/modules/datetime/datetime.module | 3 - .../modules/datetime/src/DateTimeComputed.php | 2 +- .../src/Tests/Views/FilterDateTimeTest.php | 1 - .../Plugin/views/field/DblogOperations.php | 2 - .../Tests/DynamicPageCacheIntegrationTest.php | 1 - .../src/DynamicPageCacheTestController.php | 1 - core/modules/editor/js/editor.admin.js | 4 +- core/modules/editor/js/editor.dialog.js | 2 +- .../editor/js/editor.formattedTextEditor.js | 2 +- core/modules/editor/js/editor.js | 2 +- core/modules/editor/src/EditorController.php | 4 - core/modules/editor/src/Plugin/EditorBase.php | 1 - .../src/Tests/EditorImageDialogTest.php | 8 - .../editor/src/Tests/EditorManagerTest.php | 1 - .../src/Tests/QuickEditIntegrationTest.php | 2 - .../Kernel/EditorFilterIntegrationTest.php | 2 +- core/modules/field/field.api.php | 2 - .../d6_field_formatter_settings.yml | 9 +- .../migration_templates/d6_field_instance.yml | 9 +- .../d6_field_instance_widget_settings.yml | 9 +- core/modules/field/src/Entity/FieldConfig.php | 3 +- .../migrate/source/d7/FieldInstance.php | 3 + .../src/Plugin/migrate/source/d7/ViewMode.php | 1 - .../Boolean/BooleanFormatterSettingsTest.php | 2 - .../EntityReferenceIntegrationTest.php | 7 +- .../field/src/Tests/FieldAttachOtherTest.php | 1 - core/modules/field/src/Tests/FormTest.php | 52 +- .../d6/MigrateFieldFormatterSettingsTest.php | 1 - .../Migrate/d6/MigrateFieldInstanceTest.php | 26 +- .../field/src/Tests/TranslationWebTest.php | 2 +- .../modules/field_test/field_test.module | 1 - .../Plugin/Field/FieldType/HiddenTestItem.php | 3 - .../src/Unit/FieldConfigEntityUnitTest.php | 33 +- .../Unit/FieldStorageConfigEntityUnitTest.php | 1 - core/modules/field_ui/field_ui.js | 2 +- .../Controller/FieldConfigListController.php | 1 - .../src/Form/EntityDisplayFormBase.php | 4 +- .../Plugin/Derivative/FieldUiLocalTask.php | 1 - core/modules/file/file.field.inc | 1 - core/modules/file/file.js | 4 +- core/modules/file/file.module | 1 - .../d6_upload_field_instance.yml | 9 +- core/modules/file/src/FileInterface.php | 1 - .../FileUsage/DatabaseFileUsageBackend.php | 1 - .../src/Plugin/Field/FieldType/FileItem.php | 21 +- .../Plugin/Field/FieldWidget/FileWidget.php | 1 - .../src/Plugin/migrate/process/d6/CckFile.php | 7 + .../file/src/Plugin/views/field/File.php | 1 - core/modules/file/src/Tests/DownloadTest.php | 2 - .../file/src/Tests/FileFieldPathTest.php | 15 +- .../src/Tests/FileFieldRSSContentTest.php | 1 - core/modules/file/src/Tests/SaveTest.php | 3 - .../Plugin/migrate/process/d6/CckFileTest.php | 56 + core/modules/filter/filter.admin.js | 2 +- .../filter/filter.filter_html.admin.js | 2 +- core/modules/filter/filter.js | 2 +- core/modules/filter/filter.module | 1 - .../filter/src/Element/ProcessedText.php | 2 - .../filter/src/FilterFormatFormBase.php | 1 - .../filter/src/Tests/FilterAPITest.php | 1 - .../filter/src/Tests/FilterUnitTest.php | 1 - .../Plugin/Filter/FilterTestCacheMerge.php | 1 - core/modules/forum/forum.module | 1 - core/modules/forum/src/Form/Overview.php | 2 - .../forum/src/Plugin/Block/ForumBlockBase.php | 1 - .../ForumLeafConstraintValidator.php | 1 - .../forum/src/Tests/ForumUninstallTest.php | 4 - .../Migrate/d7/MigrateForumSettingsTest.php | 2 - .../ForumListingBreadcrumbBuilderTest.php | 1 - .../hal/src/Normalizer/NormalizerBase.php | 1 - .../help/src/Plugin/Block/HelpBlock.php | 2 - core/modules/history/js/history.js | 2 +- core/modules/history/js/mark-as-read.js | 2 +- core/modules/image/image.field.inc | 1 - .../image/src/Form/ImageEffectAddForm.php | 1 - .../image/src/Form/ImageStyleEditForm.php | 2 +- .../Field/FieldFormatter/ImageFormatter.php | 2 - .../FieldFormatter/ImageFormatterBase.php | 1 - .../Plugin/Field/FieldWidget/ImageWidget.php | 2 +- .../migrate/process/d6/ImageCacheActions.php | 1 - .../migrate/source/d6/ImageCachePreset.php | 3 +- .../src/Tests/ImageStylesPathAndUrlTest.php | 1 - .../Migrate/d6/MigrateImageCacheTest.php | 29 +- core/modules/language/language.admin.js | 2 +- .../src/ConfigurableLanguageInterface.php | 1 - .../ConfigurableLanguageManagerInterface.php | 1 - .../language/src/Form/LanguageAddForm.php | 2 - .../language/src/Form/LanguageDeleteForm.php | 1 - .../language/src/Form/LanguageEditForm.php | 1 - .../src/Form/NegotiationBrowserDeleteForm.php | 1 - .../src/Form/NegotiationConfigureForm.php | 1 - .../Tests/Condition/LanguageConditionTest.php | 1 - .../Tests/LanguageBrowserDetectionTest.php | 3 - .../Tests/LanguageDependencyInjectionTest.php | 2 - .../LanguageNegotiationTestTs.php | 2 - .../src/Unit/ConfigurableLanguageUnitTest.php | 3 - .../src/Unit/LanguageNegotiationUrlTest.php | 1 - .../Field/FieldFormatter/LinkFormatter.php | 2 - .../src/Plugin/Field/FieldType/LinkItem.php | 1 - .../Plugin/Field/FieldWidget/LinkWidget.php | 3 - .../src/Plugin/migrate/process/d6/CckLink.php | 7 +- core/modules/link/src/Tests/LinkFieldTest.php | 2 +- .../LinkAccessConstraintValidatorTest.php | 1 - ...xistingInternalConstraintValidatorTest.php | 1 - core/modules/locale/locale.admin.js | 6 +- core/modules/locale/locale.bulk.js | 2 +- core/modules/locale/locale.datepicker.js | 26 +- core/modules/locale/locale.install | 2 - core/modules/locale/locale.module | 3 - core/modules/locale/locale.pages.inc | 4 - .../src/Controller/LocaleController.php | 1 - core/modules/locale/src/Gettext.php | 2 - .../locale/src/LocaleConfigManager.php | 1 - core/modules/locale/src/PoDatabaseReader.php | 1 - core/modules/locale/src/PoDatabaseWriter.php | 2 - .../src/StreamWrapper/TranslationsStream.php | 1 - core/modules/locale/src/StringBase.php | 2 - .../LocaleConfigTranslationImportTest.php | 1 - .../src/Tests/LocaleConfigTranslationTest.php | 1 - .../locale/src/Tests/LocaleUpdateBase.php | 1 - .../menu_link_content/src/Tests/LinksTest.php | 1 - core/modules/menu_ui/menu_ui.admin.js | 2 +- core/modules/menu_ui/menu_ui.js | 2 +- core/modules/menu_ui/menu_ui.module | 1 - core/modules/menu_ui/src/MenuForm.php | 1 - core/modules/menu_ui/src/MenuListBuilder.php | 1 - .../menu_ui/src/Tests/MenuLanguageTest.php | 1 - core/modules/menu_ui/src/Tests/MenuTest.php | 1 - .../schema/migrate.data_types.schema.yml | 7 + .../migrate/src/Annotation/MigrateSource.php | 26 + core/modules/migrate/src/Entity/Migration.php | 7 +- core/modules/migrate/src/MigrationStorage.php | 2 +- .../migrate/destination/EntityContentBase.php | 11 + .../destination/EntityFieldInstance.php | 2 - .../migrate/destination/EntityRevision.php | 13 +- .../migrate/source/SourcePluginBase.php | 1 - core/modules/migrate/src/Row.php | 9 + .../migrate/src/Tests/MigrateTestBase.php | 24 +- .../tests/src/Kernel/Entity/MigrationTest.php | 76 + .../Unit/destination/EntityRevisionTest.php | 219 + .../tests/src/Unit/process/GetTest.php | 1 - .../tests/src/Unit/process/IteratorTest.php | 1 - .../src/Tests/d6/EntityContentBaseTest.php | 93 + .../migrate_drupal/tests/fixtures/drupal6.php | 9030 ++++++++++++++++- .../migrate_drupal/tests/fixtures/drupal7.php | 1396 ++- .../migrate_overwrite_test.info.yml | 6 + .../migration_templates/users.yml | 31 + core/modules/node/content_types.js | 6 +- .../migration_templates/d6_node_revision.yml | 3 - core/modules/node/node.admin.inc | 1 - core/modules/node/node.js | 2 +- core/modules/node/node.module | 4 +- core/modules/node/node.preview.js | 2 +- core/modules/node/node.views.inc | 3 - .../src/Access/NodeRevisionAccessCheck.php | 2 - .../src/ConfigTranslation/NodeTypeMapper.php | 5 +- .../src/Controller/NodeViewController.php | 1 - core/modules/node/src/Entity/Node.php | 1 - .../node/src/Form/NodeRevisionDeleteForm.php | 1 - .../node/src/NodeAccessControlHandler.php | 1 - core/modules/node/src/NodeForm.php | 1 - .../node/src/NodeGrantDatabaseStorage.php | 3 - core/modules/node/src/NodeInterface.php | 1 - core/modules/node/src/NodeViewBuilder.php | 1 - .../ParamConverter/NodePreviewConverter.php | 1 - .../node/src/Plugin/Block/SyndicateBlock.php | 2 - .../node/src/Plugin/Search/NodeSearch.php | 2 +- .../src/Plugin/migrate/builder/d6/Node.php | 8 + .../src/Plugin/views/field/NodeBulkForm.php | 1 - .../modules/node/src/Plugin/views/row/Rss.php | 2 - .../Migrate/d6/MigrateNodeRevisionTest.php | 2 - .../Tests/Migrate/d6/MigrateNodeTestBase.php | 1 - .../src/Tests/Migrate/d7/MigrateNodeTest.php | 2 +- .../src/Tests/NodeBodyFieldStorageTest.php | 3 - .../node/src/Tests/NodeCacheTagsTest.php | 1 - .../src/Tests/NodeTypeTranslationTest.php | 31 +- .../src/Tests/Views/NodeFieldTokensTest.php | 3 - .../Plugin/views/argument/StringListField.php | 1 - .../Tests/OptionsSelectDynamicValuesTest.php | 2 +- .../options/src/Tests/OptionsWidgetsTest.php | 50 +- .../src/Tests/Views/OptionsTestBase.php | 1 - .../src/StackMiddleware/PageCache.php | 47 +- .../page_cache/src/Tests/PageCacheTest.php | 63 +- core/modules/path/path.js | 2 +- .../quickedit/js/editors/formEditor.js | 2 +- .../quickedit/js/editors/plainTextEditor.js | 2 +- core/modules/quickedit/js/models/AppModel.js | 2 +- core/modules/quickedit/js/models/BaseModel.js | 2 +- .../quickedit/js/models/EditorModel.js | 2 +- .../quickedit/js/models/EntityModel.js | 4 +- .../modules/quickedit/js/models/FieldModel.js | 4 +- core/modules/quickedit/js/quickedit.js | 2 +- core/modules/quickedit/js/theme.js | 2 +- core/modules/quickedit/js/util.js | 4 +- core/modules/quickedit/js/views/AppView.js | 2 +- .../quickedit/js/views/ContextualLinkView.js | 2 +- core/modules/quickedit/js/views/EditorView.js | 2 +- .../js/views/EntityDecorationView.js | 2 +- .../quickedit/js/views/EntityToolbarView.js | 2 +- .../quickedit/js/views/FieldDecorationView.js | 4 +- .../quickedit/js/views/FieldToolbarView.js | 2 +- .../quickedit/src/MetadataGenerator.php | 1 - .../src/Tests/MetadataGeneratorTest.php | 1 - .../tests/modules/quickedit_test.module | 2 - .../src/Tests/Field/DateTimeFieldRdfaTest.php | 2 - .../src/Tests/Field/EmailFieldRdfaTest.php | 2 - .../rdf/src/Tests/Field/LinkFieldRdfaTest.php | 3 - .../rdf/src/Tests/Field/TextFieldRdfaTest.php | 2 - .../js/responsive_image.ajax.js | 2 +- .../responsive_image/responsive_image.module | 2 - .../rest/src/LinkManager/LinkManagerBase.php | 1 - core/modules/rest/src/Plugin/ResourceBase.php | 1 - .../src/Plugin/views/row/DataEntityRow.php | 1 - .../src/Plugin/views/style/Serializer.php | 2 - core/modules/rest/src/RequestHandler.php | 1 - .../rest/src/Routing/ResourceRoutes.php | 3 - core/modules/rest/src/Tests/AuthTest.php | 1 - core/modules/rest/src/Tests/RESTTestBase.php | 1 - core/modules/rest/src/Tests/ReadTest.php | 1 - core/modules/rest/src/Tests/UpdateTest.php | 1 - .../src/Tests/Views/StyleSerializerTest.php | 1 - .../src/Controller/SearchController.php | 2 - core/modules/search/src/Entity/SearchPage.php | 1 - .../search/src/Plugin/Block/SearchBlock.php | 1 - core/modules/search/src/SearchQuery.php | 1 - .../src/Normalizer/ComplexDataNormalizer.php | 2 - .../src/Normalizer/ListNormalizer.php | 2 - .../src/Normalizer/TypedDataNormalizer.php | 2 - .../src/Tests/EntitySerializationTest.php | 2 - .../src/Controller/ShortcutController.php | 1 - .../src/Controller/ShortcutSetController.php | 1 - .../shortcut/src/Form/SetCustomize.php | 2 - .../shortcut/src/Form/SwitchShortcutSet.php | 1 - .../migrate/destination/EntityShortcutSet.php | 1 - .../simpletest/css/simpletest.module.css | 4 + core/modules/simpletest/simpletest.js | 4 +- core/modules/simpletest/simpletest.module | 5 +- .../simpletest/src/BrowserTestBase.php | 71 +- .../src/Form/SimpletestResultsForm.php | 1 - .../src/Form/SimpletestTestForm.php | 1 - .../modules/simpletest/src/KernelTestBase.php | 1 + core/modules/simpletest/src/TestBase.php | 36 +- core/modules/simpletest/src/WebTestBase.php | 32 +- .../simpletest_phpunit_run_command_test.php | 2 +- core/modules/statistics/statistics.js | 4 +- .../css/components/tabledrag.module.css | 10 +- core/modules/system/js/system.date.js | 2 +- core/modules/system/js/system.js | 2 +- core/modules/system/js/system.modules.js | 2 +- .../src/Controller/SystemController.php | 1 - core/modules/system/src/Entity/Menu.php | 1 - .../src/EventSubscriber/ConfigCacheTag.php | 1 - .../system/src/Form/ModulesListForm.php | 5 - .../src/Form/ModulesUninstallConfirmForm.php | 1 - .../system/src/Form/ThemeSettingsForm.php | 51 +- .../src/Plugin/Block/SystemBrandingBlock.php | 2 - .../src/Plugin/Block/SystemMainBlock.php | 2 - .../src/Plugin/Block/SystemMessagesBlock.php | 1 - .../src/Plugin/Block/SystemPoweredByBlock.php | 2 - .../src/Plugin/Condition/RequestPath.php | 1 - core/modules/system/src/SystemManager.php | 2 - .../src/Tests/Block/SystemMenuBlockTest.php | 2 +- .../src/Tests/Cache/ApcuBackendUnitTest.php | 9 + .../src/Tests/Common/AttachedAssetsTest.php | 1 - .../src/Tests/Common/PageRenderTest.php | 1 - .../system/src/Tests/Common/RenderTest.php | 3 - .../src/Tests/Database/ConnectionUnitTest.php | 2 - .../DrupalKernel/ServiceDestructionTest.php | 1 - .../Tests/Entity/ConfigEntityQueryTest.php | 2 +- .../Tests/Entity/ContentEntityChangedTest.php | 2 +- .../src/Tests/Entity/EntityFormTest.php | 10 +- .../src/Tests/Entity/EntityRevisionsTest.php | 3 +- .../EntityTypeConstraintValidatorTest.php | 1 - .../Tests/Form/ElementsTableSelectTest.php | 1 - .../src/Tests/Path/UrlAlterFunctionalTest.php | 1 - .../{Theme => Render/Element}/TableTest.php | 4 +- .../Tests/Routing/RouterPermissionTest.php | 2 - .../system/src/Tests/Routing/RouterTest.php | 13 +- .../system/src/Tests/System/ThemeTest.php | 6 + .../src/Tests/System/TokenReplaceUnitTest.php | 2 +- .../src/Tests/System/TrustedHostsTest.php | 4 - .../system/src/Tests/Theme/TwigFilterTest.php | 1 - .../system/src/Tests/Theme/TwigTransTest.php | 3 - .../src/Tests/Update/FilterHtmlUpdateTest.php | 1 - ...LocalTasksConvertedIntoBlockUpdateTest.php | 2 - ...teBrandingConvertedIntoBlockUpdateTest.php | 2 - .../src/Tests/Update/UpdatePostUpdateTest.php | 32 +- core/modules/system/system.admin.inc | 4 - core/modules/system/system.install | 2 - .../src/Controller/CacheTestController.php | 2 - .../database_test/database_test.module | 1 - .../src/Controller/EntityTestController.php | 20 - .../entity_test/src/Entity/EntityTest.php | 6 +- .../src/Entity/EntityTestAdminRoutes.php | 49 + .../src/Entity/EntityTestBaseFieldDisplay.php | 24 +- .../entity_test/src/Entity/EntityTestMul.php | 12 +- .../src/Entity/EntityTestMulChanged.php | 5 +- .../src/Entity/EntityTestMulLangcodeKey.php | 8 +- .../src/Entity/EntityTestMulRev.php | 12 +- .../src/Entity/EntityTestMulRevChanged.php | 5 +- .../entity_test/src/Entity/EntityTestRev.php | 10 +- .../src/Entity/EntityTestStringId.php | 6 +- .../src/EntityTestAccessControlHandler.php | 1 - .../entity_test/src/EntityTestForm.php | 1 - ...EntityTestCompositeConstraintValidator.php | 1 - .../src/Routing/EntityTestRoutes.php | 24 - .../modules/menu_test/src/TestControllers.php | 1 - .../mock_block/MockComplexContextBlock.php | 1 - .../plugin_test/mock_block/MockMenuBlock.php | 2 - .../mock_block/MockUserNameBlock.php | 1 - .../src/Controller/SessionTestController.php | 1 - .../src/Controller/SystemTestController.php | 7 + .../system_test/system_test.routing.yml | 7 + .../test_page_test/src/Controller/Test.php | 2 - .../update_test_postupdate.post_update.php | 19 + ...ityReferenceSelectionReferenceableTest.php | 2 +- .../Kernel/Extension/ModuleHandlerTest.php | 1 - .../PathBasedBreadcrumbBuilderTest.php | 2 - .../migration_templates/d6_term_node.yml | 9 +- .../d6_term_node_revision.yml | 9 +- .../Plugin/migrate/builder/d6/TermNode.php | 1 - .../src/Plugin/views/argument/IndexTid.php | 1 - .../Plugin/views/argument/IndexTidDepth.php | 1 - .../src/Plugin/views/argument_default/Tid.php | 2 - .../views/argument_validator/TermName.php | 2 - .../Plugin/views/field/TaxonomyIndexTid.php | 1 - .../Plugin/views/filter/TaxonomyIndexTid.php | 2 - core/modules/taxonomy/src/TermStorage.php | 1 - core/modules/taxonomy/src/Tests/EfqTest.php | 2 - .../Tests/Migrate/d6/MigrateTermNodeTest.php | 22 +- .../d6/MigrateVocabularyFieldInstanceTest.php | 1 - .../taxonomy/src/Tests/TermKernelTest.php | 1 - .../Tests/Views/TaxonomyIndexTidUiTest.php | 1 - .../Tests/Views/TaxonomyRelationshipTest.php | 1 - .../Views/TaxonomyViewsFieldAccessTest.php | 1 - .../taxonomy/src/Tests/VocabularyCrudTest.php | 1 - .../taxonomy/src/VocabularyStorage.php | 1 - core/modules/taxonomy/taxonomy.js | 2 +- .../FieldWidget/TextareaWithSummaryWidget.php | 1 - .../src/Plugin/migrate/cckfield/TextField.php | 72 +- core/modules/text/src/Tests/TextFieldTest.php | 2 +- core/modules/text/src/TextProcessed.php | 1 - .../tests/src/Unit/Migrate/TextFieldTest.php | 124 + core/modules/text/text.js | 2 +- core/modules/text/text.module | 1 - core/modules/toolbar/js/escapeAdmin.js | 2 +- core/modules/toolbar/js/models/MenuModel.js | 2 +- .../modules/toolbar/js/models/ToolbarModel.js | 2 +- core/modules/toolbar/js/toolbar.js | 2 +- core/modules/toolbar/js/toolbar.menu.js | 2 +- .../toolbar/js/views/BodyVisualView.js | 2 +- .../toolbar/js/views/MenuVisualView.js | 2 +- .../toolbar/js/views/ToolbarAuralView.js | 2 +- .../toolbar/js/views/ToolbarVisualView.js | 2 +- .../src/Tests/ToolbarAdminMenuTest.php | 1 - core/modules/toolbar/toolbar.module | 2 - core/modules/tour/js/tour.js | 2 +- core/modules/tour/src/Entity/Tour.php | 1 - core/modules/tour/src/TipPluginBase.php | 1 - core/modules/tour/src/TourViewBuilder.php | 1 - core/modules/tour/tour.module | 1 - core/modules/tracker/js/tracker-history.js | 2 +- .../modules/update_test/update_test.module | 2 - core/modules/update/update.module | 1 - core/modules/user/src/AccountForm.php | 2 - core/modules/user/src/Entity/Role.php | 1 - core/modules/user/src/Form/UserLoginForm.php | 1 - .../user/src/Form/UserPasswordForm.php | 2 - .../user/src/Plugin/Action/AddRoleUser.php | 4 - .../user/src/Plugin/Action/RemoveRoleUser.php | 4 - .../user/src/Plugin/Condition/UserRole.php | 1 - .../LanguageNegotiationUserAdmin.php | 1 - .../Constraint/UserMailRequired.php | 1 - .../src/Plugin/migrate/source/d6/User.php | 2 +- .../src/Plugin/migrate/source/d7/User.php | 2 +- .../user/src/Plugin/views/access/Role.php | 1 - .../Plugin/views/argument_default/User.php | 1 - .../src/Plugin/views/field/UserBulkForm.php | 1 - .../user/src/Plugin/views/field/UserData.php | 2 - .../user/src/Plugin/views/filter/Name.php | 1 - core/modules/user/src/RoleForm.php | 1 - .../user/src/SharedTempStoreFactory.php | 1 - .../user/src/Tests/TempStoreDatabaseTest.php | 1 - .../user/src/Tests/UserAccountLinksTest.php | 1 - .../modules/user/src/Tests/UserEntityTest.php | 1 - core/modules/user/src/Tests/UserLoginTest.php | 1 - .../user/src/Tests/UserPermissionsTest.php | 1 - .../user/src/Tests/UserTokenReplaceTest.php | 2 +- .../user/src/Tests/UserValidationTest.php | 2 - .../user/src/Tests/Views/AccessRoleTest.php | 1 - .../src/Tests/Views/HandlerFieldRoleTest.php | 1 - .../Tests/Views/HandlerFilterRolesTest.php | 1 - core/modules/user/src/UserDataInterface.php | 2 - .../src/Unit/Plugin/Core/Entity/UserTest.php | 3 +- core/modules/user/user.api.php | 6 +- core/modules/user/user.js | 2 +- core/modules/user/user.module | 5 +- core/modules/user/user.permissions.js | 4 +- core/modules/views/js/ajax_view.js | 4 +- core/modules/views/js/base.js | 2 +- core/modules/views/src/Analyzer.php | 1 - .../views/src/Annotation/ViewsAccess.php | 1 - .../src/Annotation/ViewsArgumentDefault.php | 2 - .../src/Annotation/ViewsArgumentValidator.php | 2 - .../views/src/Annotation/ViewsCache.php | 2 - .../views/src/Annotation/ViewsDisplay.php | 2 - .../views/src/Annotation/ViewsExposedForm.php | 2 - .../views/src/Annotation/ViewsPager.php | 2 - .../views/src/Annotation/ViewsQuery.php | 2 - .../modules/views/src/Annotation/ViewsRow.php | 2 - .../views/src/Annotation/ViewsStyle.php | 2 - .../views/src/Annotation/ViewsWizard.php | 2 - .../src/Controller/ViewAjaxController.php | 1 - .../src/Entity/Render/EntityFieldRenderer.php | 1 - .../src/EventSubscriber/RouteSubscriber.php | 2 - .../views/src/Form/ViewsExposedForm.php | 1 - .../views/src/Plugin/Block/ViewsBlock.php | 2 - .../src/Plugin/Derivative/ViewsLocalTask.php | 1 - .../views/src/Plugin/views/HandlerBase.php | 1 - .../views/src/Plugin/views/area/Entity.php | 1 - .../views/argument/ArgumentPluginBase.php | 1 - .../views/src/Plugin/views/argument/Date.php | 2 - .../ArgumentDefaultPluginBase.php | 1 - .../src/Plugin/views/argument_default/Raw.php | 1 - .../ArgumentValidatorPluginBase.php | 1 - .../views/argument_validator/Entity.php | 1 - .../Plugin/views/cache/CachePluginBase.php | 1 - .../views/display/DisplayPluginBase.php | 3 - .../views/display/DisplayPluginInterface.php | 13 + .../views/src/Plugin/views/display/Feed.php | 1 - .../views/src/Plugin/views/display/Page.php | 2 - .../Plugin/views/display/PathPluginBase.php | 2 - .../DisplayExtenderPluginBase.php | 1 - .../exposed_form/ExposedFormPluginBase.php | 3 - .../src/Plugin/views/field/EntityLabel.php | 1 - .../Plugin/views/field/FieldPluginBase.php | 2 - .../views/src/Plugin/views/field/LinkBase.php | 2 - .../src/Plugin/views/field/MachineName.php | 1 - .../views/src/Plugin/views/filter/Bundle.php | 1 - .../src/Plugin/views/filter/NumericFilter.php | 1 - .../src/Plugin/views/filter/StringFilter.php | 1 - .../Plugin/views/pager/PagerPluginBase.php | 1 - .../views/src/Plugin/views/pager/SqlBase.php | 2 +- .../Plugin/views/query/QueryPluginBase.php | 1 - .../views/relationship/EntityReverse.php | 3 - .../src/Plugin/views/row/RowPluginBase.php | 1 - .../src/Plugin/views/style/DefaultSummary.php | 1 - .../views/src/Plugin/views/style/Table.php | 3 - .../Plugin/views/wizard/WizardPluginBase.php | 1 - ...sEntitySchemaSubscriberIntegrationTest.php | 1 - .../src/Tests/Handler/FieldDropButtonTest.php | 2 - .../Handler/FieldEntityOperationsTest.php | 1 - .../views/src/Tests/Plugin/AccessTest.php | 1 - .../src/Tests/Plugin/DisplayExtenderTest.php | 1 - .../src/Tests/Plugin/DisplayPageTest.php | 1 - .../views/src/Tests/Plugin/StyleGridTest.php | 1 - .../views/src/Tests/Plugin/ViewsBlockTest.php | 1 - .../views/src/Tests/Plugin/ViewsFormTest.php | 1 - .../views/src/Tests/ViewKernelTestBase.php | 2 - .../views/src/Tests/ViewRenderTest.php | 1 - .../src/Tests/ViewResultAssertionTrait.php | 1 - .../views/src/Tests/ViewStorageTest.php | 3 - .../views/src/Tests/ViewsTemplateTest.php | 1 - core/modules/views/src/ViewExecutable.php | 4 - .../views/src/ViewExecutableFactory.php | 1 - .../views_test_data/views_test_data.module | 2 - .../Unit/Plugin/field/FieldPluginBaseTest.php | 1 - core/modules/views/views.module | 4 - core/modules/views/views.theme.inc | 2 +- core/modules/views_ui/admin.inc | 4 - core/modules/views_ui/js/ajax.js | 8 +- core/modules/views_ui/js/dialog.views.js | 2 +- core/modules/views_ui/js/views-admin.js | 4 +- core/modules/views_ui/js/views_ui.listing.js | 2 +- .../views_ui/src/Form/Ajax/Analyze.php | 2 - .../views_ui/src/Form/Ajax/EditDetails.php | 1 - .../src/Form/Ajax/ReorderDisplays.php | 1 - .../views_ui/src/Form/Ajax/ViewsFormBase.php | 1 - .../src/ParamConverter/ViewUIConverter.php | 2 + core/modules/views_ui/src/Tests/QueryTest.php | 2 - .../views_ui/src/Tests/ViewEditTest.php | 1 - .../tests/src/Unit/ViewUIObjectTest.php | 2 - core/modules/views_ui/views_ui.module | 1 - .../field.field.node.article.field_image.yml | 2 +- .../field.field.user.user.user_picture.yml | 2 +- core/profiles/standard/standard.install | 1 - core/scripts/run-tests.sh | 2 - .../Utility/SafeMarkupKernelTest.php | 2 - .../KernelTests/Config/DefaultConfigTest.php | 2 - .../Core/Entity/RouteProviderTest.php | 148 + .../PhpArrayContainerTest.php | 1 - .../ContainerAwareEventDispatcherTest.php | 2 - .../Tests/Component/Utility/XssTest.php | 2 +- .../Tests/Core/Access/AccessManagerTest.php | 1 - .../Core/Access/CsrfTokenGeneratorTest.php | 1 - .../Tests/Core/Ajax/AjaxResponseTest.php | 1 - .../Drupal/Tests/Core/Cache/CacheTest.php | 2 - .../ConditionAccessResolverTraitTest.php | 1 - .../Drupal/Tests/Core/Config/ConfigTest.php | 1 - .../Tests/Core/Database/ConnectionTest.php | 1 - .../Driver/pgsql/PostgresqlConnectionTest.php | 1 - .../Compiler/BackendCompilerPassTest.php | 1 - .../Compiler/ProxyServicesPassTest.php | 1 - .../Compiler/StackedKernelPassTest.php | 2 +- .../Tests/Core/Entity/EntityUnitTest.php | 2 - .../Entity/Sql/DefaultTableMappingTest.php | 2 +- .../Sql/SqlContentEntityStorageTest.php | 3 - .../TypedData/EntityAdapterUnitTest.php | 2 - .../FormAjaxSubscriberTest.php | 2 - .../Drupal/Tests/Core/Form/FormCacheTest.php | 1 - .../Drupal/Tests/Core/Form/FormTestBase.php | 2 - .../Core/Logger/LoggerChannelFactoryTest.php | 2 - .../Core/Menu/ContextualLinkDefaultTest.php | 1 - .../Core/Menu/LocalActionDefaultTest.php | 1 - .../Core/Menu/LocalActionManagerTest.php | 1 - .../Menu/LocalTaskIntegrationTestBase.php | 1 - .../Tests/Core/Menu/LocalTaskManagerTest.php | 1 - .../Tests/Core/Path/AliasManagerTest.php | 34 +- .../DerivativeDiscoveryDecoratorTest.php | 1 - .../Core/Render/BubbleableMetadataTest.php | 1 - .../Core/Render/Element/TableSelectTest.php | 1 - .../Core/Render/RendererBubblingTest.php | 1 - .../Drupal/Tests/Core/Render/RendererTest.php | 3 +- .../Routing/ContentTypeHeaderMatcherTest.php | 1 - .../Core/Routing/CurrentRouteMatchTest.php | 2 - .../Tests/Core/Routing/RouteMatchTest.php | 1 - .../Tests/Core/Routing/RouteMatchTestBase.php | 3 - .../Routing/TrustedRedirectResponseTest.php | 32 + .../Core/Session/AnonymousUserSessionTest.php | 6 +- .../Session/PermissionsHashGeneratorTest.php | 1 - .../Core/Session/SessionConfigurationTest.php | 1 - .../ReverseProxyMiddlewareTest.php | 16 +- .../Tests/Core/Theme/ThemeNegotiatorTest.php | 2 - core/tests/Drupal/Tests/UnitTestCase.php | 1 - core/themes/bartik/bartik.theme | 1 - core/themes/bartik/color/preview.js | 4 +- core/themes/engines/twig/twig.engine | 1 - core/themes/seven/css/components/buttons.css | 2 +- core/themes/seven/js/mobile.install.js | 2 +- core/themes/seven/js/nav-tabs.js | 2 +- core/themes/seven/seven.theme | 1 - sites/default/default.services.yml | 11 + sites/default/default.settings.php | 28 +- vendor/behat/mink-browserkit-driver/README.md | 0 .../tests/BrowserKitConfig.php | 37 - .../tests/Custom/BaseUrlTest.php | 24 - .../tests/Custom/ErrorHandlingTest.php | 181 - .../mink-browserkit-driver/tests/app.php | 37 - .../tests/web-fixtures/404.php | 3 - .../tests/web-fixtures/500.php | 3 - .../tests/web-fixtures/advanced_form_post.php | 32 - .../tests/web-fixtures/basic_auth.php | 15 - .../tests/web-fixtures/basic_form_post.php | 14 - .../tests/web-fixtures/basic_get_form.php | 23 - .../tests/web-fixtures/cookie_page1.php | 17 - .../tests/web-fixtures/cookie_page2.php | 14 - .../tests/web-fixtures/cookie_page3.php | 20 - .../tests/web-fixtures/headers.php | 10 - .../tests/web-fixtures/issue130.php | 14 - .../tests/web-fixtures/issue140.php | 20 - .../tests/web-fixtures/print_cookies.php | 25 - .../tests/web-fixtures/redirector.php | 3 - .../tests/web-fixtures/response_headers.php | 15 - .../tests/web-fixtures/session_test.php | 19 - .../web-fixtures/sub-folder/cookie_page1.php | 18 - .../web-fixtures/sub-folder/cookie_page2.php | 18 - .../tests/Custom/InstantiationTest.php | 27 - .../mink-goutte-driver/tests/GoutteConfig.php | 26 - vendor/behat/mink/driver-testsuite/README.md | 96 - .../behat/mink/driver-testsuite/bootstrap.php | 28 - .../driver-testsuite/tests/AbstractConfig.php | 83 - .../tests/Basic/BasicAuthTest.php | 64 - .../tests/Basic/BestPracticesTest.php | 84 - .../tests/Basic/ContentTest.php | 86 - .../tests/Basic/CookieTest.php | 168 - .../tests/Basic/ErrorHandlingTest.php | 265 - .../tests/Basic/HeaderTest.php | 78 - .../tests/Basic/IFrameTest.php | 27 - .../tests/Basic/NavigationTest.php | 69 - .../tests/Basic/ScreenshotTest.php | 30 - .../tests/Basic/StatusCodeTest.php | 22 - .../tests/Basic/TraversingTest.php | 143 - .../tests/Basic/VisibilityTest.php | 20 - .../driver-testsuite/tests/Css/HoverTest.php | 76 - .../tests/Form/CheckboxTest.php | 73 - .../tests/Form/GeneralTest.php | 312 - .../driver-testsuite/tests/Form/Html5Test.php | 128 - .../driver-testsuite/tests/Form/RadioTest.php | 84 - .../tests/Form/SelectTest.php | 134 - .../tests/Js/ChangeEventTest.php | 155 - .../driver-testsuite/tests/Js/EventsTest.php | 122 - .../tests/Js/JavascriptEvaluationTest.php | 85 - .../tests/Js/JavascriptTest.php | 42 - .../driver-testsuite/tests/Js/WindowTest.php | 83 - .../mink/driver-testsuite/tests/TestCase.php | 167 - .../driver-testsuite/web-fixtures/404.php | 2 - .../driver-testsuite/web-fixtures/500.php | 2 - .../web-fixtures/advanced_form.html | 40 - .../web-fixtures/advanced_form_post.php | 26 - .../web-fixtures/aria_roles.html | 30 - .../web-fixtures/basic_auth.php | 12 - .../web-fixtures/basic_form.html | 22 - .../web-fixtures/basic_form_post.php | 13 - .../web-fixtures/basic_get_form.php | 20 - .../web-fixtures/cookie_page1.php | 21 - .../web-fixtures/cookie_page2.php | 10 - .../web-fixtures/cookie_page3.php | 16 - .../web-fixtures/css_mouse_events.html | 36 - .../web-fixtures/element_change_detector.html | 65 - .../web-fixtures/empty_textarea.html | 14 - .../web-fixtures/form_without_button.html | 13 - .../driver-testsuite/web-fixtures/headers.php | 10 - .../web-fixtures/html5_form.html | 18 - .../web-fixtures/html5_radio.html | 16 - .../web-fixtures/html5_types.html | 18 - .../web-fixtures/html_decoding.html | 17 - .../driver-testsuite/web-fixtures/iframe.html | 12 - .../web-fixtures/iframe_inner.html | 10 - .../driver-testsuite/web-fixtures/index.html | 55 - .../web-fixtures/issue130.php | 11 - .../web-fixtures/issue131.html | 17 - .../web-fixtures/issue140.php | 16 - .../web-fixtures/issue178.html | 19 - .../web-fixtures/issue193.html | 26 - .../web-fixtures/issue211.html | 23 - .../web-fixtures/issue212.html | 9 - .../web-fixtures/issue215.html | 17 - .../web-fixtures/issue225.html | 20 - .../web-fixtures/issue255.html | 33 - .../web-fixtures/js/jquery-1.6.2-min.js | 18 - .../js/jquery-ui-1.8.14.custom.min.js | 127 - .../web-fixtures/js_test.html | 114 - .../driver-testsuite/web-fixtures/json.php | 7 - .../driver-testsuite/web-fixtures/links.html | 15 - .../web-fixtures/multi_input_form.html | 27 - .../web-fixtures/multicheckbox_form.html | 17 - .../web-fixtures/multiselect_form.html | 32 - .../driver-testsuite/web-fixtures/popup1.html | 13 - .../driver-testsuite/web-fixtures/popup2.html | 13 - .../web-fixtures/print_cookies.php | 10 - .../driver-testsuite/web-fixtures/radio.html | 21 - .../web-fixtures/randomizer.php | 12 - .../web-fixtures/redirect_destination.html | 10 - .../web-fixtures/redirector.php | 3 - .../web-fixtures/response_headers.php | 15 - .../web-fixtures/session_test.php | 18 - .../web-fixtures/some_file.txt | 1 - .../web-fixtures/sub-folder/cookie_page1.php | 4 - .../web-fixtures/sub-folder/cookie_page2.php | 2 - .../driver-testsuite/web-fixtures/window.html | 26 - .../mink/tests/Driver/CoreDriverTest.php | 110 - .../tests/Element/DocumentElementTest.php | 449 - .../behat/mink/tests/Element/ElementTest.php | 71 - .../mink/tests/Element/NodeElementTest.php | 598 -- .../tests/Exception/ElementExceptionTest.php | 42 - .../Exception/ElementHtmlExceptionTest.php | 50 - .../ElementNotFoundExceptionTest.php | 50 - .../Exception/ElementTextExceptionTest.php | 48 - .../Exception/ExpectationExceptionTest.php | 114 - .../Exception/ResponseTextExceptionTest.php | 40 - vendor/behat/mink/tests/MinkTest.php | 246 - .../mink/tests/Selector/CssSelectorTest.php | 41 - .../tests/Selector/ExactNamedSelectorTest.php | 18 - .../mink/tests/Selector/NamedSelectorTest.php | 168 - .../Selector/PartialNamedSelectorTest.php | 18 - .../tests/Selector/SelectorsHandlerTest.php | 96 - .../mink/tests/Selector/Xpath/EscaperTest.php | 31 - .../tests/Selector/Xpath/ManipulatorTest.php | 64 - .../mink/tests/Selector/fixtures/test.html | 312 - vendor/behat/mink/tests/SessionTest.php | 312 - vendor/behat/mink/tests/WebAssertTest.php | 1297 --- vendor/composer/installed.json | 3676 +++---- .../src/Composer/Installers/Installer.php | 2 +- .../Tests/Common/Cache/ApcCacheTest.php | 20 - .../Tests/Common/Cache/ArrayCacheTest.php | 26 - .../Tests/Common/Cache/BaseFileCacheTest.php | 40 - .../Doctrine/Tests/Common/Cache/CacheTest.php | 373 - .../Tests/Common/Cache/ChainCacheTest.php | 94 - .../Tests/Common/Cache/CouchbaseCacheTest.php | 47 - .../Tests/Common/Cache/FileCacheTest.php | 161 - .../Common/Cache/FilesystemCacheTest.php | 75 - .../Tests/Common/Cache/MemcacheCacheTest.php | 54 - .../Tests/Common/Cache/MemcachedCacheTest.php | 70 - .../Tests/Common/Cache/MongoDBCacheTest.php | 61 - .../Tests/Common/Cache/PhpFileCacheTest.php | 128 - .../Tests/Common/Cache/PredisCacheTest.php | 62 - .../Tests/Common/Cache/RedisCacheTest.php | 40 - .../Tests/Common/Cache/RiakCacheTest.php | 64 - .../Tests/Common/Cache/SQLite3CacheTest.php | 48 - .../Tests/Common/Cache/VoidCacheTest.php | 51 - .../Tests/Common/Cache/WinCacheCacheTest.php | 20 - .../Tests/Common/Cache/XcacheCacheTest.php | 20 - .../Tests/Common/Cache/ZendDataCacheTest.php | 28 - .../tests/Doctrine/Tests/DoctrineTestCase.php | 10 - .../cache/tests/Doctrine/Tests/TestInit.php | 19 - vendor/doctrine/cache/tests/travis/php.ini | 7 - .../cache/tests/travis/phpunit.travis.xml | 35 - .../AbstractLazyCollectionTest.php | 20 - .../Collections/ArrayCollectionTest.php | 296 - .../ClosureExpressionVisitorTest.php | 250 - .../Common/Collections/CollectionTest.php | 265 - .../Tests/Common/Collections/CriteriaTest.php | 83 - .../Collections/ExpressionBuilderTest.php | 125 - .../Doctrine/Tests/LazyArrayCollection.php | 22 - .../tests/Doctrine/Tests/TestInit.php | 21 - vendor/doctrine/common/tests/.gitignore | 3 - .../Doctrine/Tests/Common/ClassLoaderTest.php | 133 - .../Common/ClassLoaderTest/ClassA.class.php | 6 - .../Common/ClassLoaderTest/ClassB.class.php | 6 - .../Common/ClassLoaderTest/ClassC.class.php | 6 - .../Tests/Common/ClassLoaderTest/ClassD.php | 5 - .../Tests/Common/ClassLoaderTest/ClassE.php | 5 - .../ClassLoaderTest/EmptyFile.class.php | 0 .../Common/ClassLoaderTest/ExternalLoader.php | 38 - .../ClassLoaderTest/InterfaceA.class.php | 5 - .../Common/ClassLoaderTest/TraitA.class.php | 5 - .../Tests/Common/DoctrineExceptionTest.php | 0 .../Tests/Common/EventManagerTest.php | 88 - .../Persistence/ManagerRegistryTest.php | 97 - .../Mapping/AnnotationDriverTest.php | 29 - .../Persistence/Mapping/ChainDriverTest.php | 152 - .../Mapping/ClassMetadataFactoryTest.php | 209 - .../Mapping/DefaultFileLocatorTest.php | 90 - .../Persistence/Mapping/FileDriverTest.php | 142 - .../Persistence/Mapping/PHPDriverTest.php | 18 - .../Mapping/RuntimeReflectionServiceTest.php | 84 - .../Mapping/StaticPHPDriverTest.php | 35 - .../Mapping/StaticReflectionServiceTest.php | 70 - .../Mapping/SymfonyFileLocatorTest.php | 173 - .../Mapping/_custom_ns/dir/stdClass.yml | 1 - .../Mapping/_custom_ns/dir/sub/subClass.yml | 1 - .../_custom_ns/dir/sub/subsub/subSubClass.yml | 1 - .../Mapping/_custom_ns/dot/stdClass.yml | 1 - .../Mapping/_custom_ns/dot/sub.subClass.yml | 1 - .../_custom_ns/dot/sub.subsub.subSubClass.yml | 1 - .../Persistence/Mapping/_files/TestEntity.php | 3 - .../Mapping/_files/annotation/TestClass.php | 17 - .../Persistence/Mapping/_files/global.yml | 1 - .../Persistence/Mapping/_files/stdClass.yml | 1 - .../ObjectManagerDecoratorTest.php | 60 - .../Persistence/PersistentObjectTest.php | 247 - .../Common/Proxy/AbstractProxyFactoryTest.php | 146 - .../Tests/Common/Proxy/AutoloaderTest.php | 72 - .../Common/Proxy/CallableTypeHintClass.php | 16 - .../Common/Proxy/InvalidTypeHintClass.php | 16 - .../Tests/Common/Proxy/LazyLoadableObject.php | 115 - .../Proxy/LazyLoadableObjectClassMetadata.php | 195 - .../Tests/Common/Proxy/MagicCloneClass.php | 37 - .../Tests/Common/Proxy/MagicGetByRefClass.php | 51 - .../Tests/Common/Proxy/MagicGetClass.php | 38 - .../Tests/Common/Proxy/MagicIssetClass.php | 38 - .../Tests/Common/Proxy/MagicSetClass.php | 43 - .../Tests/Common/Proxy/MagicSleepClass.php | 37 - .../Tests/Common/Proxy/MagicWakeupClass.php | 32 - .../Common/Proxy/ProxyClassGeneratorTest.php | 249 - .../Tests/Common/Proxy/ProxyLogicTest.php | 752 -- .../Common/Proxy/ProxyMagicMethodsTest.php | 327 - .../Tests/Common/Proxy/SerializedClass.php | 72 - .../Tests/Common/Proxy/SleepClass.php | 19 - .../Common/Proxy/StaticPropertyClass.php | 11 - .../Common/Proxy/VariadicTypeHintClass.php | 29 - .../Reflection/DeeperNamespaceParent.php | 7 - .../Common/Reflection/Dummies/NoParent.php | 8 - .../Reflection/ExampleAnnotationClass.php | 14 - .../Reflection/FullyClassifiedParent.php | 7 - .../Tests/Common/Reflection/NoParent.php | 8 - .../RuntimePublicReflectionPropertyTest.php | 192 - .../Common/Reflection/SameNamespaceParent.php | 7 - .../Reflection/StaticReflectionParserTest.php | 93 - .../Tests/Common/Reflection/UseParent.php | 9 - .../Tests/Common/Util/ClassUtilsTest.php | 100 - .../Doctrine/Tests/Common/Util/DebugTest.php | 65 - .../tests/Doctrine/Tests/DoctrineTestCase.php | 10 - .../common/tests/Doctrine/Tests/TestInit.php | 26 - vendor/doctrine/common/tests/README.markdown | 27 - .../Tests/Common/Inflector/InflectorTest.php | 210 - .../tests/Doctrine/Tests/DoctrineTestCase.php | 10 - .../tests/Doctrine/Tests/TestInit.php | 27 - .../InstantiatorPerformanceEvent.php | 96 - .../InvalidArgumentExceptionTest.php | 83 - .../UnexpectedValueExceptionTest.php | 69 - .../InstantiatorTest/InstantiatorTest.php | 219 - .../AbstractClassAsset.php | 29 - .../ArrayObjectAsset.php | 41 - .../InstantiatorTestAsset/ExceptionAsset.php | 41 - .../FinalExceptionAsset.php | 41 - .../InstantiatorTestAsset/PharAsset.php | 41 - .../PharExceptionAsset.php | 44 - .../SerializableArrayObjectAsset.php | 62 - .../SimpleSerializableAsset.php | 61 - .../SimpleTraitAsset.php | 29 - .../UnCloneableAsset.php | 50 - .../UnserializeExceptionArrayObjectAsset.php | 39 - .../WakeUpNoticesAsset.php | 38 - .../InstantiatorTestAsset/XMLReaderAsset.php | 41 - .../email-validator/documentation/Other.md | 69 - .../documentation/RFC5321BNF.html | 89 - .../documentation/RFC5322BNF.html | 141 - .../email-validator/tests/bootstrap.php | 8 - .../egulias/Performance/AgainstFilterVar.php | 33 - .../egulias/Performance/AgainstOldIsemail.php | 34 - .../Tests/EmailValidator/EmailLexerTest.php | 161 - .../EmailValidator/EmailValidatorTest.php | 375 - .../fabpot/goutte/Goutte/Tests/ClientTest.php | 375 - .../fabpot/goutte/Goutte/Tests/fixtures.txt | 1 - .../promises/tests/AggregateExceptionTest.php | 14 - .../promises/tests/EachPromiseTest.php | 288 - .../promises/tests/FulfilledPromiseTest.php | 108 - .../promises/tests/NotPromiseInstance.php | 50 - .../guzzlehttp/promises/tests/PromiseTest.php | 579 -- .../promises/tests/RejectedPromiseTest.php | 143 - .../promises/tests/RejectionExceptionTest.php | 47 - .../promises/tests/TaskQueueTest.php | 31 - .../guzzlehttp/promises/tests/Thennable.php | 24 - .../guzzlehttp/promises/tests/bootstrap.php | 4 - .../promises/tests/functionsTest.php | 694 -- .../psr7/tests/AppendStreamTest.php | 186 - .../psr7/tests/BufferStreamTest.php | 63 - .../psr7/tests/CachingStreamTest.php | 166 - .../psr7/tests/DroppingStreamTest.php | 26 - vendor/guzzlehttp/psr7/tests/FnStreamTest.php | 90 - .../guzzlehttp/psr7/tests/FunctionsTest.php | 586 -- .../psr7/tests/InflateStreamTest.php | 16 - .../psr7/tests/LazyOpenStreamTest.php | 64 - .../guzzlehttp/psr7/tests/LimitStreamTest.php | 166 - .../psr7/tests/MultipartStreamTest.php | 214 - .../psr7/tests/NoSeekStreamTest.php | 40 - .../guzzlehttp/psr7/tests/PumpStreamTest.php | 72 - vendor/guzzlehttp/psr7/tests/RequestTest.php | 157 - vendor/guzzlehttp/psr7/tests/ResponseTest.php | 146 - .../psr7/tests/StreamDecoratorTraitTest.php | 137 - vendor/guzzlehttp/psr7/tests/StreamTest.php | 161 - .../psr7/tests/StreamWrapperTest.php | 100 - vendor/guzzlehttp/psr7/tests/UriTest.php | 247 - vendor/guzzlehttp/psr7/tests/bootstrap.php | 11 - .../html5/test/HTML5/ElementsTest.php | 486 - .../html5/test/HTML5/Html5Test.html | 10 - .../html5/test/HTML5/Html5Test.php | 401 - .../HTML5/Parser/CharacterReferenceTest.php | 44 - .../test/HTML5/Parser/DOMTreeBuilderTest.php | 537 - .../html5/test/HTML5/Parser/EventStack.php | 116 - .../test/HTML5/Parser/EventStackError.php | 6 - .../HTML5/Parser/FileInputStreamTest.html | 10 - .../test/HTML5/Parser/FileInputStreamTest.php | 195 - .../HTML5/Parser/InstructionProcessorMock.php | 26 - .../html5/test/HTML5/Parser/ScannerTest.php | 171 - .../HTML5/Parser/StringInputStreamTest.php | 327 - .../html5/test/HTML5/Parser/TokenizerTest.php | 970 -- .../HTML5/Parser/TreeBuildingRulesTest.php | 104 - .../html5/test/HTML5/Parser/UTF8UtilsTest.php | 26 - .../test/HTML5/Serializer/OutputRulesTest.php | 587 -- .../test/HTML5/Serializer/TraverserTest.php | 105 - .../masterminds/html5/test/HTML5/TestCase.php | 27 - .../bovigo/vfs/DirectoryIterationTestCase.php | 318 - .../php/org/bovigo/vfs/Issue104TestCase.php | 52 - .../org/bovigo/vfs/PermissionsTestCase.php | 118 - .../test/php/org/bovigo/vfs/QuotaTestCase.php | 81 - .../php/org/bovigo/vfs/UnlinkTestCase.php | 58 - .../vfs/content/LargeFileContentTestCase.php | 225 - .../StringBasedFileContentTestCase.php | 230 - .../proxy/vfsStreamWrapperRecordingProxy.php | 326 - .../vfs/vfsStreamAbstractContentTestCase.php | 1054 -- .../org/bovigo/vfs/vfsStreamBlockTestCase.php | 89 - .../vfsStreamContainerIteratorTestCase.php | 112 - .../vfs/vfsStreamDirectoryIssue18TestCase.php | 81 - .../bovigo/vfs/vfsStreamDirectoryTestCase.php | 335 - .../bovigo/vfs/vfsStreamExLockTestCase.php | 56 - .../org/bovigo/vfs/vfsStreamFileTestCase.php | 306 - .../org/bovigo/vfs/vfsStreamGlobTestCase.php | 29 - .../vfsStreamResolveIncludePathTestCase.php | 62 - .../php/org/bovigo/vfs/vfsStreamTestCase.php | 728 -- .../org/bovigo/vfs/vfsStreamUmaskTestCase.php | 195 - ...StreamWrapperAlreadyRegisteredTestCase.php | 63 - .../vfs/vfsStreamWrapperBaseTestCase.php | 99 - .../vfsStreamWrapperDirSeparatorTestCase.php | 73 - .../vfs/vfsStreamWrapperDirTestCase.php | 488 - .../vfs/vfsStreamWrapperFileTestCase.php | 458 - .../vfs/vfsStreamWrapperFileTimesTestCase.php | 315 - .../vfs/vfsStreamWrapperFlockTestCase.php | 440 - .../vfs/vfsStreamWrapperLargeFileTestCase.php | 77 - .../vfs/vfsStreamWrapperQuotaTestCase.php | 224 - .../vfs/vfsStreamWrapperSetOptionTestCase.php | 76 - .../vfsStreamWrapperStreamSelectTestCase.php | 35 - .../bovigo/vfs/vfsStreamWrapperTestCase.php | 770 -- .../vfsStreamWrapperUnregisterTestCase.php | 75 - .../vfsStreamWrapperWithoutRootTestCase.php | 64 - .../org/bovigo/vfs/vfsStreamZipTestCase.php | 53 - .../vfsStreamAbstractVisitorTestCase.php | 99 - .../visitor/vfsStreamPrintVisitorTestCase.php | 103 - .../vfsStreamStructureVisitorTestCase.php | 86 - .../filesystemcopy/withSubfolders/aFile.txt | 1 - .../withSubfolders/subfolder1/file1.txt | 1 - .../Reflection/DocBlock/DescriptionTest.php | 245 - .../Reflection/DocBlock/Tag/CoversTagTest.php | 86 - .../DocBlock/Tag/DeprecatedTagTest.php | 115 - .../DocBlock/Tag/ExampleTagTest.php | 203 - .../Reflection/DocBlock/Tag/LinkTagTest.php | 87 - .../Reflection/DocBlock/Tag/MethodTagTest.php | 146 - .../Reflection/DocBlock/Tag/ParamTagTest.php | 118 - .../Reflection/DocBlock/Tag/ReturnTagTest.php | 102 - .../Reflection/DocBlock/Tag/SeeTagTest.php | 86 - .../Reflection/DocBlock/Tag/SinceTagTest.php | 115 - .../Reflection/DocBlock/Tag/SourceTagTest.php | 116 - .../Reflection/DocBlock/Tag/ThrowsTagTest.php | 102 - .../Reflection/DocBlock/Tag/UsesTagTest.php | 86 - .../Reflection/DocBlock/Tag/VarTagTest.php | 94 - .../DocBlock/Tag/VersionTagTest.php | 115 - .../Reflection/DocBlock/TagTest.php | 313 - .../DocBlock/Type/CollectionTest.php | 195 - .../phpDocumentor/Reflection/DocBlockTest.php | 337 - .../tests/PHP/CodeCoverage/FilterTest.php | 281 - .../PHP/CodeCoverage/Report/CloverTest.php | 66 - .../PHP/CodeCoverage/Report/FactoryTest.php | 222 - .../tests/PHP/CodeCoverage/UtilTest.php | 30 - .../tests/PHP/CodeCoverageTest.php | 487 - .../php-code-coverage/tests/TestCase.php | 311 - .../tests/_files/BankAccount-clover.xml | 26 - .../tests/_files/BankAccount.php | 33 - .../tests/_files/BankAccountTest.php | 66 - .../_files/CoverageClassExtendedTest.php | 12 - .../tests/_files/CoverageClassTest.php | 12 - .../CoverageFunctionParenthesesTest.php | 11 - ...erageFunctionParenthesesWhitespaceTest.php | 11 - .../tests/_files/CoverageFunctionTest.php | 11 - .../CoverageMethodOneLineAnnotationTest.php | 11 - .../_files/CoverageMethodParenthesesTest.php | 12 - ...overageMethodParenthesesWhitespaceTest.php | 12 - .../tests/_files/CoverageMethodTest.php | 12 - .../tests/_files/CoverageNoneTest.php | 9 - .../tests/_files/CoverageNotPrivateTest.php | 12 - .../tests/_files/CoverageNotProtectedTest.php | 12 - .../tests/_files/CoverageNotPublicTest.php | 12 - .../tests/_files/CoverageNothingTest.php | 13 - .../tests/_files/CoveragePrivateTest.php | 12 - .../tests/_files/CoverageProtectedTest.php | 12 - .../tests/_files/CoveragePublicTest.php | 12 - .../CoverageTwoDefaultClassAnnotations.php | 18 - .../tests/_files/CoveredClass.php | 36 - .../tests/_files/CoveredFunction.php | 4 - .../NamespaceCoverageClassExtendedTest.php | 12 - .../_files/NamespaceCoverageClassTest.php | 12 - ...NamespaceCoverageCoversClassPublicTest.php | 15 - .../NamespaceCoverageCoversClassTest.php | 20 - .../_files/NamespaceCoverageMethodTest.php | 12 - .../NamespaceCoverageNotPrivateTest.php | 12 - .../NamespaceCoverageNotProtectedTest.php | 12 - .../_files/NamespaceCoverageNotPublicTest.php | 12 - .../_files/NamespaceCoveragePrivateTest.php | 12 - .../_files/NamespaceCoverageProtectedTest.php | 12 - .../_files/NamespaceCoveragePublicTest.php | 12 - .../tests/_files/NamespaceCoveredClass.php | 38 - .../_files/NotExistingCoveredElementTest.php | 24 - .../class-with-anonymous-function-clover.xml | 22 - .../tests/_files/ignored-lines-clover.xml | 17 - ...urce_with_class_and_anonymous_function.php | 19 - .../tests/_files/source_with_ignore.php | 37 - .../tests/_files/source_with_namespace.php | 20 - .../source_with_oneline_annotations.php | 36 - .../tests/_files/source_without_ignore.php | 4 - .../tests/_files/source_without_namespace.php | 18 - vendor/phpunit/php-timer/Tests/TimerTest.php | 101 - .../tests/Token/ClassTest.php | 112 - .../tests/Token/ClosureTest.php | 85 - .../tests/Token/FunctionTest.php | 146 - .../tests/Token/IncludeTest.php | 73 - .../tests/Token/InterfaceTest.php | 191 - .../tests/Token/NamespaceTest.php | 80 - .../php-token-stream/tests/TokenTest.php | 42 - .../_fixture/classExtendsNamespacedClass.php | 10 - .../tests/_fixture/classInNamespace.php | 6 - .../tests/_fixture/classInScopedNamespace.php | 9 - ...h_method_that_declares_anonymous_class.php | 15 - ..._method_that_declares_anonymous_class2.php | 16 - .../tests/_fixture/closure.php | 7 - .../tests/_fixture/issue19.php | 3 - .../tests/_fixture/issue30.php | 8 - ...tipleNamespacesWithOneClassUsingBraces.php | 12 - ...espacesWithOneClassUsingNonBraceSyntax.php | 14 - .../tests/_fixture/source.php | 36 - .../tests/_fixture/source2.php | 6 - .../tests/_fixture/source3.php | 14 - .../tests/_fixture/source4.php | 30 - .../tests/_fixture/source5.php | 5 - .../php-token-stream/tests/bootstrap.php | 7 - .../tests/Extensions/PhptTestCaseTest.php | 37 - .../tests/Extensions/RepeatedTestTest.php | 64 - vendor/phpunit/phpunit/tests/Fail/fail.phpt | 5 - .../phpunit/tests/Framework/AssertTest.php | 4130 -------- .../tests/Framework/BaseTestListenerTest.php | 34 - .../tests/Framework/Constraint/CountTest.php | 63 - .../Constraint/ExceptionMessageRegExpTest.php | 56 - .../Constraint/ExceptionMessageTest.php | 52 - .../JsonMatches/ErrorMessageProviderTest.php | 83 - .../Framework/Constraint/JsonMatchesTest.php | 48 - .../tests/Framework/ConstraintTest.php | 3490 ------- .../phpunit/tests/Framework/SuiteTest.php | 242 - .../phpunit/tests/Framework/TestCaseTest.php | 550 - .../tests/Framework/TestFailureTest.php | 27 - .../tests/Framework/TestImplementorTest.php | 30 - .../tests/Framework/TestListenerTest.php | 108 - .../phpunit/tests/Regression/1021.phpt | 19 - .../tests/Regression/1021/Issue1021Test.php | 23 - .../phpunit/phpunit/tests/Regression/523.phpt | 19 - .../tests/Regression/523/Issue523Test.php | 13 - .../phpunit/phpunit/tests/Regression/578.phpt | 37 - .../tests/Regression/578/Issue578Test.php | 20 - .../phpunit/phpunit/tests/Regression/684.phpt | 25 - .../tests/Regression/684/Issue684Test.php | 4 - .../phpunit/phpunit/tests/Regression/783.phpt | 21 - .../tests/Regression/783/ChildSuite.php | 15 - .../phpunit/tests/Regression/783/OneTest.php | 10 - .../tests/Regression/783/ParentSuite.php | 13 - .../phpunit/tests/Regression/783/TwoTest.php | 10 - .../phpunit/tests/Regression/GitHub/1149.phpt | 20 - .../Regression/GitHub/1149/Issue1149Test.php | 18 - .../phpunit/tests/Regression/GitHub/1216.phpt | 25 - .../Regression/GitHub/1216/Issue1216Test.php | 8 - .../Regression/GitHub/1216/bootstrap1216.php | 2 - .../Regression/GitHub/1216/phpunit1216.xml | 8 - .../phpunit/tests/Regression/GitHub/1265.phpt | 21 - .../Regression/GitHub/1265/Issue1265Test.php | 8 - .../Regression/GitHub/1265/phpunit1265.xml | 2 - .../phpunit/tests/Regression/GitHub/1330.phpt | 24 - .../Regression/GitHub/1330/Issue1330Test.php | 8 - .../Regression/GitHub/1330/phpunit1330.xml | 5 - .../phpunit/tests/Regression/GitHub/1335.phpt | 21 - .../Regression/GitHub/1335/Issue1335Test.php | 67 - .../Regression/GitHub/1335/bootstrap1335.php | 13 - .../phpunit/tests/Regression/GitHub/1337.phpt | 21 - .../Regression/GitHub/1337/Issue1337Test.php | 19 - .../phpunit/tests/Regression/GitHub/1348.phpt | 35 - .../Regression/GitHub/1348/Issue1348Test.php | 14 - .../phpunit/tests/Regression/GitHub/1351.phpt | 48 - .../GitHub/1351/ChildProcessClass1351.php | 4 - .../Regression/GitHub/1351/Issue1351Test.php | 48 - .../phpunit/tests/Regression/GitHub/1374.phpt | 21 - .../Regression/GitHub/1374/Issue1374Test.php | 21 - .../phpunit/tests/Regression/GitHub/1437.phpt | 28 - .../Regression/GitHub/1437/Issue1437Test.php | 9 - .../phpunit/tests/Regression/GitHub/1468.phpt | 22 - .../Regression/GitHub/1468/Issue1468Test.php | 11 - .../phpunit/tests/Regression/GitHub/1471.phpt | 28 - .../Regression/GitHub/1471/Issue1471Test.php | 12 - .../phpunit/tests/Regression/GitHub/1472.phpt | 26 - .../Regression/GitHub/1472/Issue1472Test.php | 21 - .../phpunit/tests/Regression/GitHub/1570.phpt | 21 - .../Regression/GitHub/1570/Issue1570Test.php | 8 - .../phpunit/tests/Regression/GitHub/244.phpt | 32 - .../Regression/GitHub/244/Issue244Test.php | 55 - .../phpunit/tests/Regression/GitHub/322.phpt | 26 - .../Regression/GitHub/322/Issue322Test.php | 17 - .../Regression/GitHub/322/phpunit322.xml | 11 - .../phpunit/tests/Regression/GitHub/433.phpt | 31 - .../Regression/GitHub/433/Issue433Test.php | 21 - .../phpunit/tests/Regression/GitHub/445.phpt | 32 - .../Regression/GitHub/445/Issue445Test.php | 21 - .../phpunit/tests/Regression/GitHub/498.phpt | 29 - .../Regression/GitHub/498/Issue498Test.php | 44 - .../phpunit/tests/Regression/GitHub/503.phpt | 33 - .../Regression/GitHub/503/Issue503Test.php | 11 - .../phpunit/tests/Regression/GitHub/581.phpt | 42 - .../Regression/GitHub/581/Issue581Test.php | 11 - .../phpunit/tests/Regression/GitHub/74.phpt | 28 - .../Regression/GitHub/74/Issue74Test.php | 9 - .../Regression/GitHub/74/NewException.php | 4 - .../phpunit/tests/Regression/GitHub/765.phpt | 26 - .../Regression/GitHub/765/Issue765Test.php | 22 - .../phpunit/tests/Regression/GitHub/797.phpt | 22 - .../Regression/GitHub/797/Issue797Test.php | 10 - .../Regression/GitHub/797/bootstrap797.php | 6 - .../phpunit/tests/Regression/GitHub/863.phpt | 24 - .../tests/Regression/GitHub/873-php5.phpt | 22 - .../tests/Regression/GitHub/873-php7.phpt | 22 - .../Regression/GitHub/873/Issue873Test.php | 9 - .../tests/Runner/BaseTestRunnerTest.php | 22 - .../tests/TextUI/abstract-test-class.phpt | 25 - .../phpunit/tests/TextUI/colors-always.phpt | 19 - .../tests/TextUI/concrete-test-class.phpt | 19 - .../tests/TextUI/custom-printer-debug.phpt | 27 - .../tests/TextUI/custom-printer-verbose.phpt | 32 - .../tests/TextUI/dataprovider-debug.phpt | 34 - .../dataprovider-log-xml-isolation.phpt | 47 - .../tests/TextUI/dataprovider-log-xml.phpt | 46 - .../tests/TextUI/dataprovider-testdox.phpt | 17 - .../phpunit/phpunit/tests/TextUI/debug.phpt | 26 - .../tests/TextUI/default-isolation.phpt | 20 - .../phpunit/phpunit/tests/TextUI/default.phpt | 19 - .../tests/TextUI/dependencies-isolation.phpt | 40 - .../phpunit/tests/TextUI/dependencies.phpt | 39 - .../tests/TextUI/dependencies2-isolation.phpt | 20 - .../phpunit/tests/TextUI/dependencies2.phpt | 19 - .../tests/TextUI/dependencies3-isolation.phpt | 20 - .../phpunit/tests/TextUI/dependencies3.phpt | 19 - .../phpunit/tests/TextUI/empty-testcase.phpt | 25 - .../phpunit/tests/TextUI/exception-stack.phpt | 65 - .../tests/TextUI/exclude-group-isolation.phpt | 22 - .../phpunit/tests/TextUI/exclude-group.phpt | 21 - .../tests/TextUI/failure-isolation.phpt | 142 - .../phpunit/phpunit/tests/TextUI/failure.phpt | 141 - .../phpunit/tests/TextUI/fatal-isolation.phpt | 26 - .../tests/TextUI/filter-class-isolation.phpt | 22 - .../phpunit/tests/TextUI/filter-class.phpt | 21 - ...ider-by-classname-and-range-isolation.phpt | 22 - ...r-dataprovider-by-classname-and-range.phpt | 21 - ...lter-dataprovider-by-number-isolation.phpt | 22 - .../TextUI/filter-dataprovider-by-number.phpt | 21 - ...-dataprovider-by-only-range-isolation.phpt | 22 - .../filter-dataprovider-by-only-range.phpt | 21 - ...dataprovider-by-only-regexp-isolation.phpt | 22 - .../filter-dataprovider-by-only-regexp.phpt | 21 - ...dataprovider-by-only-string-isolation.phpt | 22 - .../filter-dataprovider-by-only-string.phpt | 21 - ...ilter-dataprovider-by-range-isolation.phpt | 22 - .../TextUI/filter-dataprovider-by-range.phpt | 21 - ...lter-dataprovider-by-regexp-isolation.phpt | 22 - .../TextUI/filter-dataprovider-by-regexp.phpt | 21 - ...lter-dataprovider-by-string-isolation.phpt | 22 - .../TextUI/filter-dataprovider-by-string.phpt | 21 - .../filter-method-case-insensitive.phpt | 21 - ...ilter-method-case-sensitive-no-result.phpt | 21 - .../tests/TextUI/filter-method-isolation.phpt | 22 - .../phpunit/tests/TextUI/filter-method.phpt | 21 - .../tests/TextUI/filter-no-results.phpt | 21 - .../phpunit/tests/TextUI/group-isolation.phpt | 22 - .../phpunit/phpunit/tests/TextUI/group.phpt | 21 - vendor/phpunit/phpunit/tests/TextUI/help.phpt | 87 - .../phpunit/phpunit/tests/TextUI/help2.phpt | 88 - .../phpunit/tests/TextUI/ini-isolation.phpt | 22 - .../phpunit/tests/TextUI/list-groups.phpt | 19 - .../TextUI/log-json-no-pretty-print.phpt | 27 - .../tests/TextUI/log-json-post-66021.phpt | 72 - .../tests/TextUI/log-json-pre-66021.phpt | 78 - .../phpunit/phpunit/tests/TextUI/log-tap.phpt | 26 - .../phpunit/phpunit/tests/TextUI/log-xml.phpt | 29 - .../tests/TextUI/options-after-arguments.phpt | 19 - .../tests/TextUI/output-isolation.phpt | 21 - .../phpunit/phpunit/tests/TextUI/repeat.phpt | 21 - .../report-useless-tests-incomplete.phpt | 21 - .../report-useless-tests-isolation.phpt | 22 - .../tests/TextUI/report-useless-tests.phpt | 21 - vendor/phpunit/phpunit/tests/TextUI/tap.phpt | 18 - .../tests/TextUI/test-suffix-multiple.phpt | 20 - .../tests/TextUI/test-suffix-single.phpt | 20 - .../phpunit/tests/TextUI/testdox-html.phpt | 21 - .../phpunit/tests/TextUI/testdox-text.phpt | 25 - .../phpunit/phpunit/tests/TextUI/testdox.phpt | 19 - .../phpunit/tests/Util/ConfigurationTest.php | 500 - .../phpunit/phpunit/tests/Util/GetoptTest.php | 62 - .../phpunit/tests/Util/GlobalStateTest.php | 35 - .../phpunit/phpunit/tests/Util/RegexTest.php | 52 - .../tests/Util/TestDox/NamePrettifierTest.php | 81 - .../phpunit/phpunit/tests/Util/TestTest.php | 669 -- vendor/phpunit/phpunit/tests/Util/XMLTest.php | 318 - .../phpunit/tests/_files/AbstractTest.php | 7 - .../phpunit/phpunit/tests/_files/Author.php | 27 - .../phpunit/tests/_files/BankAccount.php | 79 - .../phpunit/tests/_files/BankAccountTest.php | 87 - .../tests/_files/BankAccountTest.test.php | 87 - .../tests/_files/BaseTestListenerSample.php | 11 - .../tests/_files/BeforeAndAfterTest.php | 35 - .../_files/BeforeClassAndAfterClassTest.php | 35 - vendor/phpunit/phpunit/tests/_files/Book.php | 20 - .../phpunit/tests/_files/Calculator.php | 14 - .../ChangeCurrentWorkingDirectoryTest.php | 9 - .../_files/ClassWithNonPublicAttributes.php | 29 - .../ClassWithScalarTypeDeclarations.php | 8 - .../tests/_files/ClassWithToString.php | 22 - .../phpunit/tests/_files/ConcreteTest.my.php | 7 - .../phpunit/tests/_files/ConcreteTest.php | 7 - .../_files/CoverageClassExtendedTest.php | 12 - .../tests/_files/CoverageClassTest.php | 12 - .../CoverageFunctionParenthesesTest.php | 11 - ...erageFunctionParenthesesWhitespaceTest.php | 11 - .../tests/_files/CoverageFunctionTest.php | 11 - .../CoverageMethodOneLineAnnotationTest.php | 11 - .../_files/CoverageMethodParenthesesTest.php | 12 - ...overageMethodParenthesesWhitespaceTest.php | 12 - .../tests/_files/CoverageMethodTest.php | 12 - .../_files/CoverageNamespacedFunctionTest.php | 11 - .../phpunit/tests/_files/CoverageNoneTest.php | 9 - .../tests/_files/CoverageNotPrivateTest.php | 12 - .../tests/_files/CoverageNotProtectedTest.php | 12 - .../tests/_files/CoverageNotPublicTest.php | 12 - .../tests/_files/CoverageNothingTest.php | 13 - .../tests/_files/CoveragePrivateTest.php | 12 - .../tests/_files/CoverageProtectedTest.php | 12 - .../tests/_files/CoveragePublicTest.php | 12 - .../CoverageTwoDefaultClassAnnotations.php | 17 - .../phpunit/tests/_files/CoveredClass.php | 36 - .../phpunit/tests/_files/CoveredFunction.php | 4 - .../phpunit/tests/_files/CustomPrinter.php | 4 - .../tests/_files/DataProviderDebugTest.php | 48 - .../tests/_files/DataProviderFilterTest.php | 39 - .../_files/DataProviderIncompleteTest.php | 37 - .../tests/_files/DataProviderSkippedTest.php | 37 - .../phpunit/tests/_files/DataProviderTest.php | 21 - .../tests/_files/DependencyFailureTest.php | 22 - .../tests/_files/DependencySuccessTest.php | 21 - .../tests/_files/DependencyTestSuite.php | 13 - .../phpunit/tests/_files/DoubleTestCase.php | 25 - .../phpunit/tests/_files/DummyException.php | 5 - .../tests/_files/EmptyTestCaseTest.php | 4 - .../ExceptionInAssertPostConditionsTest.php | 35 - .../ExceptionInAssertPreConditionsTest.php | 35 - .../tests/_files/ExceptionInSetUpTest.php | 35 - .../tests/_files/ExceptionInTearDownTest.php | 35 - .../phpunit/tests/_files/ExceptionInTest.php | 35 - .../tests/_files/ExceptionNamespaceTest.php | 38 - .../tests/_files/ExceptionStackTest.php | 21 - .../phpunit/tests/_files/ExceptionTest.php | 139 - .../phpunit/phpunit/tests/_files/Failure.php | 8 - .../phpunit/tests/_files/FailureTest.php | 75 - .../phpunit/tests/_files/FatalTest.php | 13 - .../phpunit/tests/_files/IncompleteTest.php | 8 - .../tests/_files/Inheritance/InheritanceA.php | 7 - .../tests/_files/Inheritance/InheritanceB.php | 8 - .../tests/_files/InheritedTestCase.php | 7 - .../phpunit/phpunit/tests/_files/IniTest.php | 8 - .../phpunit/tests/_files/IsolationTest.php | 13 - .../tests/_files/JsonData/arrayObject.json | 1 - .../tests/_files/JsonData/simpleObject.json | 1 - .../phpunit/tests/_files/MockRunner.php | 7 - .../tests/_files/MultiDependencyTest.php | 23 - .../NamespaceCoverageClassExtendedTest.php | 12 - .../_files/NamespaceCoverageClassTest.php | 12 - ...NamespaceCoverageCoversClassPublicTest.php | 15 - .../NamespaceCoverageCoversClassTest.php | 20 - .../_files/NamespaceCoverageMethodTest.php | 12 - .../NamespaceCoverageNotPrivateTest.php | 12 - .../NamespaceCoverageNotProtectedTest.php | 12 - .../_files/NamespaceCoverageNotPublicTest.php | 12 - .../_files/NamespaceCoveragePrivateTest.php | 12 - .../_files/NamespaceCoverageProtectedTest.php | 12 - .../_files/NamespaceCoveragePublicTest.php | 12 - .../tests/_files/NamespaceCoveredClass.php | 38 - .../tests/_files/NamespaceCoveredFunction.php | 7 - .../tests/_files/NoArgTestCaseTest.php | 7 - .../phpunit/tests/_files/NoTestCaseClass.php | 4 - .../phpunit/tests/_files/NoTestCases.php | 7 - .../phpunit/tests/_files/NonStatic.php | 8 - .../_files/NotExistingCoveredElementTest.php | 24 - .../tests/_files/NotPublicTestCase.php | 11 - .../phpunit/tests/_files/NotVoidTestCase.php | 4 - .../phpunit/tests/_files/NothingTest.php | 7 - .../phpunit/tests/_files/OneTestCase.php | 11 - .../phpunit/tests/_files/OutputTestCase.php | 27 - .../phpunit/tests/_files/OverrideTestCase.php | 7 - .../RequirementsClassBeforeClassHookTest.php | 12 - .../_files/RequirementsClassDocBlockTest.php | 22 - .../phpunit/tests/_files/RequirementsTest.php | 148 - .../tests/_files/SampleArrayAccess.php | 36 - .../phpunit/tests/_files/SampleClass.php | 14 - .../phpunit/tests/_files/Singleton.php | 22 - .../phpunit/tests/_files/StackTest.php | 24 - .../phpunit/phpunit/tests/_files/Struct.php | 10 - .../phpunit/phpunit/tests/_files/Success.php | 7 - .../tests/_files/TemplateMethodsTest.php | 51 - .../phpunit/tests/_files/TestIncomplete.php | 8 - .../phpunit/tests/_files/TestIterator.php | 36 - .../phpunit/tests/_files/TestIterator2.php | 35 - .../phpunit/tests/_files/TestSkipped.php | 8 - .../phpunit/tests/_files/TestTestError.php | 8 - .../phpunit/tests/_files/TestWithTest.php | 24 - .../tests/_files/ThrowExceptionTestCase.php | 8 - .../tests/_files/ThrowNoExceptionTestCase.php | 7 - .../phpunit/phpunit/tests/_files/WasRun.php | 10 - vendor/phpunit/phpunit/tests/_files/bar.xml | 1 - .../_files/configuration.colors.empty.xml | 1 - .../_files/configuration.colors.false.xml | 1 - .../_files/configuration.colors.invalid.xml | 1 - .../_files/configuration.colors.true.xml | 1 - .../_files/configuration.custom-printer.xml | 2 - .../phpunit/tests/_files/configuration.xml | 120 - .../tests/_files/configuration_empty.xml | 57 - .../tests/_files/configuration_xinclude.xml | 75 - .../tests/_files/expectedFileFormat.txt | 1 - vendor/phpunit/phpunit/tests/_files/foo.xml | 1 - ...uctureAttributesAreSameButValuesAreNot.xml | 10 - .../tests/_files/structureExpected.xml | 10 - .../tests/_files/structureIgnoreTextNodes.xml | 13 - .../_files/structureIsSameButDataIsNot.xml | 10 - .../structureWrongNumberOfAttributes.xml | 10 - .../_files/structureWrongNumberOfNodes.xml | 9 - vendor/phpunit/phpunit/tests/bootstrap.php | 6 - .../comparator/tests/ArrayComparatorTest.php | 163 - .../tests/DOMNodeComparatorTest.php | 162 - .../tests/DateTimeComparatorTest.php | 216 - .../comparator/tests/DoubleComparatorTest.php | 134 - .../tests/ExceptionComparatorTest.php | 136 - .../comparator/tests/FactoryTest.php | 115 - .../tests/MockObjectComparatorTest.php | 166 - .../tests/NumericComparatorTest.php | 122 - .../comparator/tests/ObjectComparatorTest.php | 150 - .../tests/ResourceComparatorTest.php | 120 - .../comparator/tests/ScalarComparatorTest.php | 158 - .../tests/SplObjectStorageComparatorTest.php | 137 - .../comparator/tests/TypeComparatorTest.php | 104 - .../comparator/tests/_files/Author.php | 28 - .../comparator/tests/_files/Book.php | 21 - .../tests/_files/ClassWithToString.php | 19 - .../comparator/tests/_files/SampleClass.php | 29 - .../comparator/tests/_files/Struct.php | 25 - .../comparator/tests/_files/TestClass.php | 14 - .../tests/_files/TestClassComparator.php | 14 - .../sebastian/comparator/tests/autoload.php | 38 - .../sebastian/comparator/tests/bootstrap.php | 7 - vendor/sebastian/diff/tests/DifferTest.php | Bin 11371 -> 0 bytes .../LCS/TimeEfficientImplementationTest.php | 175 - vendor/sebastian/diff/tests/ParserTest.php | 62 - .../sebastian/diff/tests/fixtures/patch.txt | 9 - .../sebastian/diff/tests/fixtures/patch2.txt | 21 - .../environment/tests/ConsoleTest.php | 60 - .../environment/tests/RuntimeTest.php | 112 - .../sebastian/exporter/tests/ExporterTest.php | 333 - .../global-state/tests/BlacklistTest.php | 149 - .../tests/_fixture/BlacklistedChildClass.php | 53 - .../tests/_fixture/BlacklistedClass.php | 54 - .../tests/_fixture/BlacklistedImplementor.php | 54 - .../tests/_fixture/BlacklistedInterface.php | 53 - .../recursion-context/tests/ContextTest.php | 144 - .../tests/functional/SilexApplicationTest.php | 60 - .../builder/tests/unit/Stack/BuilderTest.php | 215 - .../unit/Stack/StackedHttpKernelTest.php | 155 - .../routing/Test/CmfUnitTestCase.php | 23 - .../Tests/Candidates/CandidatesTest.php | 105 - .../RegisterRouteEnhancersPassTest.php | 71 - .../Compiler/RegisterRoutersPassTest.php | 98 - .../Enhancer/FieldByClassEnhancerTest.php | 71 - .../Tests/Enhancer/FieldMapEnhancerTest.php | 69 - .../Enhancer/FieldPresenceEnhancerTest.php | 71 - .../Enhancer/RouteContentEnhancerTest.php | 87 - .../routing/Tests/Enhancer/RouteObject.php | 27 - .../Tests/NestedMatcher/NestedMatcherTest.php | 139 - .../Tests/NestedMatcher/UrlMatcherTest.php | 152 - .../routing/Tests/Routing/ChainRouterTest.php | 730 -- .../Routing/ContentAwareGeneratorTest.php | 457 - .../Tests/Routing/DynamicRouterTest.php | 330 - .../Tests/Routing/LazyRouteCollectionTest.php | 42 - .../Routing/PagedRouteCollectionTest.php | 132 - .../Routing/ProviderBasedGeneratorTest.php | 149 - .../routing/Tests/Routing/RouteMock.php | 55 - .../symfony-cmf/routing/Tests/bootstrap.php | 20 - .../symfony/browser-kit/Tests/ClientTest.php | 639 -- .../browser-kit/Tests/CookieJarTest.php | 231 - .../symfony/browser-kit/Tests/CookieTest.php | 179 - .../symfony/browser-kit/Tests/HistoryTest.php | 101 - .../symfony/browser-kit/Tests/RequestTest.php | 53 - .../browser-kit/Tests/ResponseTest.php | 76 - .../Tests/ClassCollectionLoaderTest.php | 292 - .../class-loader/Tests/ClassLoaderTest.php | 212 - .../Tests/ClassMapGeneratorTest.php | 150 - .../Tests/Fixtures/Apc/Namespaced/Bar.php | 17 - .../Tests/Fixtures/Apc/Namespaced/Baz.php | 17 - .../Tests/Fixtures/Apc/Namespaced/Foo.php | 17 - .../Tests/Fixtures/Apc/Namespaced/FooBar.php | 17 - .../Tests/Fixtures/Apc/Pearlike/Bar.php | 6 - .../Tests/Fixtures/Apc/Pearlike/Baz.php | 6 - .../Tests/Fixtures/Apc/Pearlike/Foo.php | 6 - .../alpha/Apc/ApcPrefixCollision/A/Bar.php | 6 - .../alpha/Apc/ApcPrefixCollision/A/Foo.php | 6 - .../alpha/Apc/NamespaceCollision/A/Bar.php | 17 - .../alpha/Apc/NamespaceCollision/A/Foo.php | 17 - .../beta/Apc/ApcPrefixCollision/A/B/Bar.php | 6 - .../beta/Apc/ApcPrefixCollision/A/B/Foo.php | 6 - .../beta/Apc/NamespaceCollision/A/B/Bar.php | 17 - .../beta/Apc/NamespaceCollision/A/B/Foo.php | 17 - .../Apc/fallback/Apc/Pearlike/FooBar.php | 6 - .../Apc/fallback/Namespaced/FooBar.php | 17 - .../Tests/Fixtures/ClassesWithParents/A.php | 7 - .../Fixtures/ClassesWithParents/ATrait.php | 7 - .../Tests/Fixtures/ClassesWithParents/B.php | 7 - .../Fixtures/ClassesWithParents/BTrait.php | 8 - .../ClassesWithParents/CInterface.php | 7 - .../Fixtures/ClassesWithParents/CTrait.php | 7 - .../Tests/Fixtures/ClassesWithParents/D.php | 8 - .../Tests/Fixtures/ClassesWithParents/E.php | 8 - .../Tests/Fixtures/ClassesWithParents/F.php | 8 - .../Tests/Fixtures/ClassesWithParents/G.php | 8 - .../ClassesWithParents/GInterface.php | 7 - .../Tests/Fixtures/Namespaced/Bar.php | 17 - .../Tests/Fixtures/Namespaced/Baz.php | 17 - .../Tests/Fixtures/Namespaced/Foo.php | 17 - .../Fixtures/Namespaced/WithComments.php | 37 - .../Tests/Fixtures/Namespaced2/Bar.php | 8 - .../Tests/Fixtures/Namespaced2/Baz.php | 8 - .../Tests/Fixtures/Namespaced2/Foo.php | 8 - .../Tests/Fixtures/Pearlike/Bar.php | 6 - .../Tests/Fixtures/Pearlike/Baz.php | 6 - .../Tests/Fixtures/Pearlike/Foo.php | 6 - .../Tests/Fixtures/Pearlike/WithComments.php | 16 - .../Tests/Fixtures/Pearlike2/Bar.php | 6 - .../Tests/Fixtures/Pearlike2/Baz.php | 6 - .../Tests/Fixtures/Pearlike2/Foo.php | 6 - .../alpha/NamespaceCollision/A/Bar.php | 17 - .../alpha/NamespaceCollision/A/Foo.php | 17 - .../alpha/NamespaceCollision/C/Bar.php | 8 - .../alpha/NamespaceCollision/C/Foo.php | 8 - .../Fixtures/alpha/PrefixCollision/A/Bar.php | 6 - .../Fixtures/alpha/PrefixCollision/A/Foo.php | 6 - .../Fixtures/alpha/PrefixCollision/C/Bar.php | 6 - .../Fixtures/alpha/PrefixCollision/C/Foo.php | 6 - .../beta/NamespaceCollision/A/B/Bar.php | 17 - .../beta/NamespaceCollision/A/B/Foo.php | 17 - .../beta/NamespaceCollision/C/B/Bar.php | 8 - .../beta/NamespaceCollision/C/B/Foo.php | 8 - .../Fixtures/beta/PrefixCollision/A/B/Bar.php | 6 - .../Fixtures/beta/PrefixCollision/A/B/Foo.php | 6 - .../Fixtures/beta/PrefixCollision/C/B/Bar.php | 6 - .../Fixtures/beta/PrefixCollision/C/B/Foo.php | 6 - .../Tests/Fixtures/classmap/SomeClass.php | 16 - .../Tests/Fixtures/classmap/SomeInterface.php | 16 - .../Tests/Fixtures/classmap/SomeParent.php | 16 - .../Tests/Fixtures/classmap/multipleNs.php | 25 - .../Tests/Fixtures/classmap/notAClass.php | 3 - .../Tests/Fixtures/classmap/notPhpFile.md | 1 - .../classmap/sameNsMultipleClasses.php | 19 - .../Tests/Fixtures/deps/traits.php | 37 - .../Fixtures/fallback/Namespaced/FooBar.php | 17 - .../Fixtures/fallback/Namespaced2/FooBar.php | 8 - .../Fixtures/fallback/Pearlike/FooBar.php | 6 - .../Fixtures/fallback/Pearlike2/FooBar.php | 6 - .../Tests/Fixtures/includepath/Foo.php | 5 - .../Tests/Fixtures/php5.4/traits.php | 32 - .../Tests/Fixtures/php5.5/class_cons.php | 11 - .../Fixtures/psr-4/Class_With_Underscores.php | 7 - .../class-loader/Tests/Fixtures/psr-4/Foo.php | 7 - .../Lets/Go/Deeper/Class_With_Underscores.php | 7 - .../Fixtures/psr-4/Lets/Go/Deeper/Foo.php | 7 - .../LegacyApcUniversalClassLoaderTest.php | 193 - .../Tests/LegacyUniversalClassLoaderTest.php | 223 - .../Tests/Psr4ClassLoaderTest.php | 71 - .../console/Resources/bin/hiddeninput.exe | Bin 9202 -> 9216 bytes .../symfony/console/Tests/ApplicationTest.php | 1060 -- vendor/symfony/console/Tests/ClockMock.php | 41 - .../console/Tests/Command/CommandTest.php | 337 - .../console/Tests/Command/HelpCommandTest.php | 70 - .../console/Tests/Command/ListCommandTest.php | 64 - .../Descriptor/AbstractDescriptorTest.php | 105 - .../Tests/Descriptor/JsonDescriptorTest.php | 35 - .../Descriptor/MarkdownDescriptorTest.php | 27 - .../Tests/Descriptor/ObjectsProvider.php | 77 - .../Tests/Descriptor/TextDescriptorTest.php | 27 - .../Tests/Descriptor/XmlDescriptorTest.php | 27 - .../console/Tests/Fixtures/BarBucCommand.php | 11 - .../Tests/Fixtures/DescriptorApplication1.php | 18 - .../Tests/Fixtures/DescriptorApplication2.php | 24 - .../Tests/Fixtures/DescriptorCommand1.php | 27 - .../Tests/Fixtures/DescriptorCommand2.php | 32 - .../console/Tests/Fixtures/DummyOutput.php | 36 - .../console/Tests/Fixtures/Foo1Command.php | 26 - .../console/Tests/Fixtures/Foo2Command.php | 21 - .../console/Tests/Fixtures/Foo3Command.php | 29 - .../console/Tests/Fixtures/Foo4Command.php | 11 - .../console/Tests/Fixtures/Foo5Command.php | 10 - .../console/Tests/Fixtures/FooCommand.php | 33 - .../Fixtures/FooSubnamespaced1Command.php | 26 - .../Fixtures/FooSubnamespaced2Command.php | 26 - .../console/Tests/Fixtures/FoobarCommand.php | 25 - .../Style/SymfonyStyle/command/command_0.php | 11 - .../Style/SymfonyStyle/command/command_1.php | 13 - .../Style/SymfonyStyle/command/command_2.php | 16 - .../Style/SymfonyStyle/command/command_3.php | 12 - .../Style/SymfonyStyle/command/command_4.php | 34 - .../Style/SymfonyStyle/command/command_5.php | 29 - .../Style/SymfonyStyle/command/command_6.php | 16 - .../Style/SymfonyStyle/command/command_7.php | 15 - .../Style/SymfonyStyle/output/output_0.txt | 3 - .../Style/SymfonyStyle/output/output_1.txt | 9 - .../Style/SymfonyStyle/output/output_2.txt | 13 - .../Style/SymfonyStyle/output/output_3.txt | 7 - .../Style/SymfonyStyle/output/output_4.txt | 32 - .../Style/SymfonyStyle/output/output_5.txt | 11 - .../Style/SymfonyStyle/output/output_6.txt | 6 - .../Style/SymfonyStyle/output/output_7.txt | 5 - .../console/Tests/Fixtures/TestCommand.php | 28 - .../console/Tests/Fixtures/application_1.json | 1 - .../console/Tests/Fixtures/application_1.md | 201 - .../console/Tests/Fixtures/application_1.txt | 17 - .../console/Tests/Fixtures/application_1.xml | 110 - .../console/Tests/Fixtures/application_2.json | 1 - .../console/Tests/Fixtures/application_2.md | 396 - .../console/Tests/Fixtures/application_2.txt | 22 - .../console/Tests/Fixtures/application_2.xml | 190 - .../Tests/Fixtures/application_astext1.txt | 20 - .../Tests/Fixtures/application_astext2.txt | 16 - .../Tests/Fixtures/application_asxml1.txt | 146 - .../Tests/Fixtures/application_asxml2.txt | 37 - .../Tests/Fixtures/application_gethelp.txt | 1 - .../Fixtures/application_renderexception1.txt | 8 - .../Fixtures/application_renderexception2.txt | 11 - .../Fixtures/application_renderexception3.txt | 27 - .../application_renderexception3decorated.txt | 27 - .../Fixtures/application_renderexception4.txt | 9 - ...plication_renderexception_doublewidth1.txt | 11 - ..._renderexception_doublewidth1decorated.txt | 11 - ...plication_renderexception_doublewidth2.txt | 12 - .../Tests/Fixtures/application_run1.txt | 17 - .../Tests/Fixtures/application_run2.txt | 29 - .../Tests/Fixtures/application_run3.txt | 27 - .../Tests/Fixtures/application_run4.txt | 1 - .../console/Tests/Fixtures/command_1.json | 1 - .../console/Tests/Fixtures/command_1.md | 11 - .../console/Tests/Fixtures/command_1.txt | 7 - .../console/Tests/Fixtures/command_1.xml | 12 - .../console/Tests/Fixtures/command_2.json | 1 - .../console/Tests/Fixtures/command_2.md | 33 - .../console/Tests/Fixtures/command_2.txt | 13 - .../console/Tests/Fixtures/command_2.xml | 21 - .../console/Tests/Fixtures/command_astext.txt | 18 - .../console/Tests/Fixtures/command_asxml.txt | 38 - .../Tests/Fixtures/definition_astext.txt | 11 - .../Tests/Fixtures/definition_asxml.txt | 39 - .../Tests/Fixtures/input_argument_1.json | 1 - .../Tests/Fixtures/input_argument_1.md | 7 - .../Tests/Fixtures/input_argument_1.txt | 1 - .../Tests/Fixtures/input_argument_1.xml | 5 - .../Tests/Fixtures/input_argument_2.json | 1 - .../Tests/Fixtures/input_argument_2.md | 7 - .../Tests/Fixtures/input_argument_2.txt | 1 - .../Tests/Fixtures/input_argument_2.xml | 5 - .../Tests/Fixtures/input_argument_3.json | 1 - .../Tests/Fixtures/input_argument_3.md | 7 - .../Tests/Fixtures/input_argument_3.txt | 1 - .../Tests/Fixtures/input_argument_3.xml | 7 - .../Tests/Fixtures/input_argument_4.json | 1 - .../Tests/Fixtures/input_argument_4.md | 8 - .../Tests/Fixtures/input_argument_4.txt | 2 - .../Tests/Fixtures/input_argument_4.xml | 6 - .../Tests/Fixtures/input_definition_1.json | 1 - .../Tests/Fixtures/input_definition_1.md | 0 .../Tests/Fixtures/input_definition_1.txt | 0 .../Tests/Fixtures/input_definition_1.xml | 5 - .../Tests/Fixtures/input_definition_2.json | 1 - .../Tests/Fixtures/input_definition_2.md | 9 - .../Tests/Fixtures/input_definition_2.txt | 2 - .../Tests/Fixtures/input_definition_2.xml | 10 - .../Tests/Fixtures/input_definition_3.json | 1 - .../Tests/Fixtures/input_definition_3.md | 11 - .../Tests/Fixtures/input_definition_3.txt | 2 - .../Tests/Fixtures/input_definition_3.xml | 9 - .../Tests/Fixtures/input_definition_4.json | 1 - .../Tests/Fixtures/input_definition_4.md | 21 - .../Tests/Fixtures/input_definition_4.txt | 5 - .../Tests/Fixtures/input_definition_4.xml | 14 - .../Tests/Fixtures/input_option_1.json | 1 - .../console/Tests/Fixtures/input_option_1.md | 9 - .../console/Tests/Fixtures/input_option_1.txt | 1 - .../console/Tests/Fixtures/input_option_1.xml | 4 - .../Tests/Fixtures/input_option_2.json | 1 - .../console/Tests/Fixtures/input_option_2.md | 9 - .../console/Tests/Fixtures/input_option_2.txt | 1 - .../console/Tests/Fixtures/input_option_2.xml | 7 - .../Tests/Fixtures/input_option_3.json | 1 - .../console/Tests/Fixtures/input_option_3.md | 9 - .../console/Tests/Fixtures/input_option_3.txt | 1 - .../console/Tests/Fixtures/input_option_3.xml | 5 - .../Tests/Fixtures/input_option_4.json | 1 - .../console/Tests/Fixtures/input_option_4.md | 9 - .../console/Tests/Fixtures/input_option_4.txt | 1 - .../console/Tests/Fixtures/input_option_4.xml | 5 - .../Tests/Fixtures/input_option_5.json | 1 - .../console/Tests/Fixtures/input_option_5.md | 10 - .../console/Tests/Fixtures/input_option_5.txt | 2 - .../console/Tests/Fixtures/input_option_5.xml | 6 - .../Tests/Fixtures/input_option_6.json | 1 - .../console/Tests/Fixtures/input_option_6.md | 9 - .../console/Tests/Fixtures/input_option_6.txt | 1 - .../console/Tests/Fixtures/input_option_6.xml | 5 - .../OutputFormatterStyleStackTest.php | 70 - .../Formatter/OutputFormatterStyleTest.php | 99 - .../Tests/Formatter/OutputFormatterTest.php | 273 - .../Tests/Helper/FormatterHelperTest.php | 99 - .../console/Tests/Helper/HelperSetTest.php | 153 - .../Tests/Helper/LegacyDialogHelperTest.php | 195 - .../Tests/Helper/LegacyProgressHelperTest.php | 240 - .../Tests/Helper/LegacyTableHelperTest.php | 324 - .../Tests/Helper/ProcessHelperTest.php | 117 - .../console/Tests/Helper/ProgressBarTest.php | 612 -- .../Tests/Helper/QuestionHelperTest.php | 383 - .../console/Tests/Helper/TableStyleTest.php | 27 - .../console/Tests/Helper/TableTest.php | 568 -- .../console/Tests/Input/ArgvInputTest.php | 317 - .../console/Tests/Input/ArrayInputTest.php | 138 - .../console/Tests/Input/InputArgumentTest.php | 111 - .../Tests/Input/InputDefinitionTest.php | 437 - .../console/Tests/Input/InputOptionTest.php | 204 - .../symfony/console/Tests/Input/InputTest.php | 121 - .../console/Tests/Input/StringInputTest.php | 99 - .../Tests/Logger/ConsoleLoggerTest.php | 58 - .../Tests/Output/ConsoleOutputTest.php | 25 - .../console/Tests/Output/NullOutputTest.php | 39 - .../console/Tests/Output/OutputTest.php | 156 - .../console/Tests/Output/StreamOutputTest.php | 60 - .../console/Tests/Style/SymfonyStyleTest.php | 64 - .../Tests/Tester/ApplicationTesterTest.php | 69 - .../Tests/Tester/CommandTesterTest.php | 84 - .../css-selector/Tests/CssSelectorTest.php | 64 - .../Tests/Node/AbstractNodeTest.php | 32 - .../Tests/Node/AttributeNodeTest.php | 37 - .../css-selector/Tests/Node/ClassNodeTest.php | 33 - .../Tests/Node/CombinedSelectorNodeTest.php | 35 - .../Tests/Node/ElementNodeTest.php | 35 - .../Tests/Node/FunctionNodeTest.php | 47 - .../css-selector/Tests/Node/HashNodeTest.php | 33 - .../Tests/Node/NegationNodeTest.php | 33 - .../Tests/Node/PseudoNodeTest.php | 32 - .../Tests/Node/SelectorNodeTest.php | 34 - .../Tests/Node/SpecificityTest.php | 62 - .../Parser/Handler/AbstractHandlerTest.php | 67 - .../Parser/Handler/CommentHandlerTest.php | 55 - .../Tests/Parser/Handler/HashHandlerTest.php | 49 - .../Parser/Handler/IdentifierHandlerTest.php | 49 - .../Parser/Handler/NumberHandlerTest.php | 50 - .../Parser/Handler/StringHandlerTest.php | 50 - .../Parser/Handler/WhitespaceHandlerTest.php | 44 - .../css-selector/Tests/Parser/ParserTest.php | 248 - .../css-selector/Tests/Parser/ReaderTest.php | 101 - .../Tests/Parser/Shortcut/ClassParserTest.php | 44 - .../Parser/Shortcut/ElementParserTest.php | 43 - .../Parser/Shortcut/EmptyStringParserTest.php | 35 - .../Tests/Parser/Shortcut/HashParserTest.php | 44 - .../Tests/Parser/TokenStreamTest.php | 95 - .../Tests/XPath/Fixtures/ids.html | 48 - .../Tests/XPath/Fixtures/lang.xml | 11 - .../Tests/XPath/Fixtures/shakespear.html | 308 - .../Tests/XPath/TranslatorTest.php | 324 - .../debug/Tests/DebugClassLoaderTest.php | 296 - .../symfony/debug/Tests/ErrorHandlerTest.php | 503 - .../Tests/Exception/FlattenExceptionTest.php | 256 - .../debug/Tests/ExceptionHandlerTest.php | 134 - .../ClassNotFoundFatalErrorHandlerTest.php | 200 - ...UndefinedFunctionFatalErrorHandlerTest.php | 80 - .../UndefinedMethodFatalErrorHandlerTest.php | 66 - .../debug/Tests/Fixtures/ClassAlias.php | 3 - .../debug/Tests/Fixtures/DeprecatedClass.php | 12 - .../Tests/Fixtures/DeprecatedInterface.php | 12 - .../debug/Tests/Fixtures/PEARClass.php | 5 - .../debug/Tests/Fixtures/casemismatch.php | 7 - .../debug/Tests/Fixtures/notPsr0Bis.php | 7 - .../Tests/Fixtures/psr4/Psr4CaseMismatch.php | 7 - .../debug/Tests/Fixtures/reallyNotPsr0.php | 7 - .../debug/Tests/Fixtures2/RequiredTwice.php | 7 - vendor/symfony/debug/Tests/HeaderMock.php | 38 - .../debug/Tests/MockExceptionHandler.php | 24 - .../AnalyzeServiceReferencesPassTest.php | 146 - .../Compiler/AutoAliasServicePassTest.php | 112 - .../CheckCircularReferencesPassTest.php | 130 - .../CheckDefinitionValidityPassTest.php | 103 - ...tionOnInvalidReferenceBehaviorPassTest.php | 70 - .../CheckReferenceValidityPassTest.php | 97 - .../Compiler/DecoratorServicePassTest.php | 81 - .../Compiler/ExtensionCompilerPassTest.php | 46 - .../InlineServiceDefinitionsPassTest.php | 245 - .../Tests/Compiler/IntegrationTest.php | 116 - ...cyResolveParameterPlaceHoldersPassTest.php | 35 - .../MergeExtensionConfigurationPassTest.php | 55 - .../RemoveUnusedDefinitionsPassTest.php | 113 - ...ReplaceAliasByActualDefinitionPassTest.php | 59 - .../ResolveDefinitionTemplatesPassTest.php | 215 - .../ResolveInvalidReferencesPassTest.php | 83 - .../ResolveParameterPlaceHoldersPassTest.php | 91 - .../ResolveReferencesToAliasesPassTest.php | 67 - .../Tests/ContainerBuilderTest.php | 858 -- .../Tests/ContainerTest.php | 713 -- .../Tests/CrossCheckTest.php | 96 - .../Tests/DefinitionDecoratorTest.php | 144 - .../Tests/DefinitionTest.php | 328 - .../Tests/Dumper/GraphvizDumperTest.php | 90 - .../Tests/Dumper/PhpDumperTest.php | 221 - .../Tests/Dumper/XmlDumperTest.php | 184 - .../Tests/Dumper/YamlDumperTest.php | 80 - .../Tests/Extension/ExtensionTest.php | 81 - .../Tests/Fixtures/containers/container10.php | 14 - .../Tests/Fixtures/containers/container11.php | 12 - .../Tests/Fixtures/containers/container12.php | 12 - .../Tests/Fixtures/containers/container13.php | 16 - .../Tests/Fixtures/containers/container14.php | 17 - .../Tests/Fixtures/containers/container15.php | 11 - .../Tests/Fixtures/containers/container16.php | 11 - .../Tests/Fixtures/containers/container17.php | 10 - .../Tests/Fixtures/containers/container18.php | 14 - .../Tests/Fixtures/containers/container19.php | 22 - .../Tests/Fixtures/containers/container20.php | 19 - .../Tests/Fixtures/containers/container21.php | 20 - .../Tests/Fixtures/containers/container8.php | 14 - .../Tests/Fixtures/containers/container9.php | 113 - .../Fixtures/containers/legacy-container9.php | 39 - .../Fixtures/graphviz/legacy-services9.dot | 15 - .../Tests/Fixtures/graphviz/services1.dot | 7 - .../Tests/Fixtures/graphviz/services10-1.dot | 10 - .../Tests/Fixtures/graphviz/services10.dot | 10 - .../Tests/Fixtures/graphviz/services13.dot | 10 - .../Tests/Fixtures/graphviz/services14.dot | 7 - .../Tests/Fixtures/graphviz/services17.dot | 8 - .../Tests/Fixtures/graphviz/services18.dot | 8 - .../Tests/Fixtures/graphviz/services9.dot | 41 - .../Fixtures/includes/ProjectExtension.php | 40 - .../includes/ProjectWithXsdExtension.php | 19 - .../ProjectWithXsdExtensionInPhar.phar | Bin 1161 -> 0 bytes .../Tests/Fixtures/includes/classes.php | 61 - .../Tests/Fixtures/includes/createphar.php | 47 - .../Tests/Fixtures/includes/foo.php | 38 - .../Fixtures/includes/schema/project-1.0.xsd | 13 - .../Tests/Fixtures/ini/nonvalid.ini | 2 - .../Tests/Fixtures/ini/parameters.ini | 3 - .../Tests/Fixtures/ini/parameters1.ini | 3 - .../Tests/Fixtures/ini/parameters2.ini | 2 - .../Tests/Fixtures/php/services1-1.php | 30 - .../Tests/Fixtures/php/services1.php | 29 - .../Tests/Fixtures/php/services10.php | 118 - .../Tests/Fixtures/php/services12.php | 124 - .../Tests/Fixtures/php/services19.php | 63 - .../Tests/Fixtures/php/services20.php | 73 - .../Tests/Fixtures/php/services8.php | 54 - .../Tests/Fixtures/php/services9.php | 376 - .../Tests/Fixtures/php/services9_compiled.php | 357 - .../Tests/Fixtures/php/simple.php | 3 - .../Fixtures/xml/extension1/services.xml | 14 - .../Fixtures/xml/extension2/services.xml | 14 - .../Fixtures/xml/extensions/services1.xml | 19 - .../Fixtures/xml/extensions/services2.xml | 19 - .../Fixtures/xml/extensions/services3.xml | 19 - .../Fixtures/xml/extensions/services4.xml | 6 - .../Fixtures/xml/extensions/services5.xml | 11 - .../Fixtures/xml/extensions/services6.xml | 11 - .../Fixtures/xml/extensions/services7.xml | 11 - .../Tests/Fixtures/xml/legacy-services6.xml | 11 - .../Tests/Fixtures/xml/legacy-services9.xml | 36 - .../Tests/Fixtures/xml/namespaces.xml | 17 - .../Tests/Fixtures/xml/nonvalid.xml | 3 - .../Tests/Fixtures/xml/services1.xml | 2 - .../Tests/Fixtures/xml/services10.xml | 16 - .../Tests/Fixtures/xml/services13.xml | 9 - .../Tests/Fixtures/xml/services14.xml | 19 - .../Tests/Fixtures/xml/services2.xml | 31 - .../Tests/Fixtures/xml/services20.xml | 11 - .../Tests/Fixtures/xml/services21.xml | 21 - .../Tests/Fixtures/xml/services3.xml | 13 - .../Tests/Fixtures/xml/services4.xml | 13 - .../Fixtures/xml/services4_bad_import.xml | 9 - .../Tests/Fixtures/xml/services5.xml | 21 - .../Tests/Fixtures/xml/services6.xml | 62 - .../Tests/Fixtures/xml/services7.xml | 9 - .../Tests/Fixtures/xml/services8.xml | 22 - .../Tests/Fixtures/xml/services9.xml | 106 - .../Tests/Fixtures/xml/withdoctype.xml | 3 - .../Tests/Fixtures/yaml/bad_calls.yml | 4 - .../Tests/Fixtures/yaml/bad_format.yml | 2 - .../Tests/Fixtures/yaml/bad_import.yml | 2 - .../Tests/Fixtures/yaml/bad_imports.yml | 2 - .../Tests/Fixtures/yaml/bad_parameters.yml | 2 - .../Tests/Fixtures/yaml/bad_service.yml | 2 - .../Tests/Fixtures/yaml/bad_services.yml | 1 - .../Tests/Fixtures/yaml/badtag1.yml | 5 - .../Tests/Fixtures/yaml/badtag2.yml | 6 - .../Tests/Fixtures/yaml/badtag3.yml | 6 - .../Tests/Fixtures/yaml/badtag4.yml | 6 - .../Tests/Fixtures/yaml/legacy-services6.yml | 8 - .../Tests/Fixtures/yaml/legacy-services9.yml | 28 - .../Tests/Fixtures/yaml/nonvalid1.yml | 2 - .../Tests/Fixtures/yaml/nonvalid2.yml | 1 - .../Tests/Fixtures/yaml/services1.yml | 1 - .../Tests/Fixtures/yaml/services10.yml | 9 - .../Tests/Fixtures/yaml/services11.yml | 1 - .../Tests/Fixtures/yaml/services13.yml | 3 - .../Tests/Fixtures/yaml/services14.yml | 3 - .../Tests/Fixtures/yaml/services2.yml | 12 - .../Tests/Fixtures/yaml/services20.yml | 9 - .../Tests/Fixtures/yaml/services21.yml | 15 - .../Tests/Fixtures/yaml/services3.yml | 5 - .../Tests/Fixtures/yaml/services4.yml | 7 - .../Fixtures/yaml/services4_bad_import.yml | 2 - .../Tests/Fixtures/yaml/services6.yml | 33 - .../Tests/Fixtures/yaml/services7.yml | 2 - .../Tests/Fixtures/yaml/services8.yml | 7 - .../Tests/Fixtures/yaml/services9.yml | 94 - .../RealServiceInstantiatorTest.php | 37 - .../LazyProxy/PhpDumper/NullDumperTest.php | 35 - .../Tests/LegacyContainerBuilderTest.php | 46 - .../Tests/LegacyDefinitionTest.php | 44 - .../Tests/Loader/ClosureLoaderTest.php | 43 - .../Tests/Loader/IniFileLoaderTest.php | 80 - .../Tests/Loader/PhpFileLoaderTest.php | 42 - .../Tests/Loader/XmlFileLoaderTest.php | 495 - .../Tests/Loader/YamlFileLoaderTest.php | 283 - .../ParameterBag/FrozenParameterBagTest.php | 69 - .../Tests/ParameterBag/ParameterBagTest.php | 279 - .../Tests/ParameterTest.php | 26 - .../Tests/ReferenceTest.php | 32 - .../symfony/dom-crawler/Tests/CrawlerTest.php | 1084 -- .../Tests/Field/ChoiceFormFieldTest.php | 388 - .../Tests/Field/FileFormFieldTest.php | 114 - .../dom-crawler/Tests/Field/FormFieldTest.php | 38 - .../Tests/Field/FormFieldTestCase.php | 27 - .../Tests/Field/InputFormFieldTest.php | 49 - .../Tests/Field/TextareaFormFieldTest.php | 46 - .../dom-crawler/Tests/Fixtures/no-extension | 1 - .../Tests/Fixtures/windows-1250.html | 8 - vendor/symfony/dom-crawler/Tests/FormTest.php | 973 -- vendor/symfony/dom-crawler/Tests/LinkTest.php | 160 - .../Tests/AcceptHeaderItemTest.php | 112 - .../Tests/AcceptHeaderTest.php | 102 - .../Tests/ApacheRequestTest.php | 92 - .../Tests/BinaryFileResponseTest.php | 250 - .../http-foundation/Tests/ClockMock.php | 39 - .../http-foundation/Tests/CookieTest.php | 157 - .../Tests/ExpressionRequestMatcherTest.php | 68 - .../http-foundation/Tests/File/FakeFile.php | 45 - .../http-foundation/Tests/File/FileTest.php | 179 - .../Tests/File/Fixtures/.unknownextension | 1 - .../Tests/File/Fixtures/directory/.empty | 0 .../Tests/File/Fixtures/other-file.example | 0 .../http-foundation/Tests/File/Fixtures/test | Bin 35 -> 0 bytes .../Tests/File/Fixtures/test.gif | Bin 35 -> 0 bytes .../Tests/File/MimeType/MimeTypeTest.php | 89 - .../Tests/File/UploadedFileTest.php | 272 - .../http-foundation/Tests/FileBagTest.php | 148 - .../http-foundation/Tests/HeaderBagTest.php | 216 - .../http-foundation/Tests/IpUtilsTest.php | 84 - .../Tests/JsonResponseTest.php | 229 - .../Tests/ParameterBagTest.php | 266 - .../Tests/RedirectResponseTest.php | 83 - .../Tests/RequestMatcherTest.php | 150 - .../Tests/RequestStackTest.php | 69 - .../http-foundation/Tests/RequestTest.php | 1890 ---- .../Tests/ResponseHeaderBagTest.php | 307 - .../http-foundation/Tests/ResponseTest.php | 890 -- .../Tests/ResponseTestCase.php | 88 - .../http-foundation/Tests/ServerBagTest.php | 154 - .../Session/Attribute/AttributeBagTest.php | 193 - .../Attribute/NamespacedAttributeBagTest.php | 183 - .../Session/Flash/AutoExpireFlashBagTest.php | 155 - .../Tests/Session/Flash/FlashBagTest.php | 155 - .../Tests/Session/SessionTest.php | 227 - .../Handler/LegacyPdoSessionHandlerTest.php | 114 - .../Handler/MemcacheSessionHandlerTest.php | 132 - .../Handler/MemcachedSessionHandlerTest.php | 131 - .../Handler/MongoDbSessionHandlerTest.php | 255 - .../Handler/NativeFileSessionHandlerTest.php | 81 - .../Handler/NativeSessionHandlerTest.php | 40 - .../Handler/NullSessionHandlerTest.php | 58 - .../Storage/Handler/PdoSessionHandlerTest.php | 359 - .../Handler/WriteCheckSessionHandlerTest.php | 94 - .../Tests/Session/Storage/MetadataBagTest.php | 134 - .../Storage/MockArraySessionStorageTest.php | 106 - .../Storage/MockFileSessionStorageTest.php | 126 - .../Storage/NativeSessionStorageTest.php | 258 - .../Storage/PhpBridgeSessionStorageTest.php | 123 - .../Storage/Proxy/AbstractProxyTest.php | 217 - .../Session/Storage/Proxy/NativeProxyTest.php | 35 - .../Storage/Proxy/SessionHandlerProxyTest.php | 127 - .../Tests/StreamedResponseTest.php | 121 - .../http-kernel/Tests/Bundle/BundleTest.php | 44 - .../CacheClearer/ChainCacheClearerTest.php | 57 - .../CacheWarmer/CacheWarmerAggregateTest.php | 100 - .../Tests/CacheWarmer/CacheWarmerTest.php | 67 - .../symfony/http-kernel/Tests/ClientTest.php | 179 - .../Config/EnvParametersResourceTest.php | 106 - .../Tests/Config/FileLocatorTest.php | 47 - .../Controller/ControllerResolverTest.php | 242 - .../DataCollector/ConfigDataCollectorTest.php | 81 - .../DataCollector/DumpDataCollectorTest.php | 138 - .../ExceptionDataCollectorTest.php | 39 - .../DataCollector/LoggerDataCollectorTest.php | 95 - .../DataCollector/MemoryDataCollectorTest.php | 58 - .../RequestDataCollectorTest.php | 222 - .../DataCollector/TimeDataCollectorTest.php | 51 - .../DataCollector/Util/ValueExporterTest.php | 43 - .../Debug/TraceableEventDispatcherTest.php | 117 - .../ContainerAwareHttpKernelTest.php | 168 - .../FragmentRendererPassTest.php | 160 - .../LazyLoadingFragmentHandlerTest.php | 40 - .../MergeExtensionConfigurationPassTest.php | 57 - .../AddRequestFormatsListenerTest.php | 83 - .../DebugHandlersListenerTest.php | 106 - .../Tests/EventListener/DumpListenerTest.php | 82 - .../EventListener/ExceptionListenerTest.php | 146 - .../EventListener/FragmentListenerTest.php | 96 - .../EventListener/LocaleListenerTest.php | 103 - .../EventListener/ProfilerListenerTest.php | 105 - .../EventListener/ResponseListenerTest.php | 94 - .../EventListener/RouterListenerTest.php | 161 - .../EventListener/SurrogateListenerTest.php | 66 - .../EventListener/TestSessionListenerTest.php | 132 - .../EventListener/TranslatorListenerTest.php | 117 - .../Fixtures/BaseBundle/Resources/foo.txt | 0 .../Fixtures/BaseBundle/Resources/hide.txt | 0 .../Fixtures/Bundle1Bundle/Resources/foo.txt | 0 .../Tests/Fixtures/Bundle1Bundle/bar.txt | 0 .../Tests/Fixtures/Bundle1Bundle/foo.txt | 0 .../Tests/Fixtures/Bundle2Bundle/foo.txt | 0 .../Fixtures/ChildBundle/Resources/foo.txt | 0 .../Fixtures/ChildBundle/Resources/hide.txt | 0 .../ExtensionAbsentBundle.php | 18 - .../ExtensionLoadedExtension.php | 22 - .../ExtensionLoadedBundle.php | 18 - .../ExtensionNotValidExtension.php | 20 - .../ExtensionNotValidBundle.php | 18 - .../Command/BarCommand.php | 18 - .../Command/FooCommand.php | 22 - .../ExtensionPresentExtension.php | 22 - .../ExtensionPresentBundle.php | 18 - .../Tests/Fixtures/FooBarBundle.php | 19 - .../Tests/Fixtures/KernelForOverrideName.php | 28 - .../Tests/Fixtures/KernelForTest.php | 37 - .../Fixtures/Resources/BaseBundle/hide.txt | 0 .../Fixtures/Resources/Bundle1Bundle/foo.txt | 0 .../Fixtures/Resources/ChildBundle/foo.txt | 0 .../Fixtures/Resources/FooBundle/foo.txt | 0 .../http-kernel/Tests/Fixtures/TestClient.php | 31 - .../Tests/Fixtures/TestEventDispatcher.php | 28 - .../Fragment/EsiFragmentRendererTest.php | 103 - .../Tests/Fragment/FragmentHandlerTest.php | 95 - .../Fragment/HIncludeFragmentRendererTest.php | 88 - .../Fragment/InlineFragmentRendererTest.php | 210 - .../Fragment/RoutableFragmentRendererTest.php | 93 - .../http-kernel/Tests/HttpCache/EsiTest.php | 247 - .../Tests/HttpCache/HttpCacheTest.php | 1225 --- .../Tests/HttpCache/HttpCacheTestCase.php | 176 - .../http-kernel/Tests/HttpCache/SsiTest.php | 214 - .../http-kernel/Tests/HttpCache/StoreTest.php | 269 - .../Tests/HttpCache/TestHttpKernel.php | 91 - .../HttpCache/TestMultipleHttpKernel.php | 80 - .../http-kernel/Tests/HttpKernelTest.php | 319 - .../symfony/http-kernel/Tests/KernelTest.php | 849 -- vendor/symfony/http-kernel/Tests/Logger.php | 128 - .../Profiler/AbstractProfilerStorageTest.php | 270 - .../Profiler/FileProfilerStorageTest.php | 100 - .../Profiler/MemcacheProfilerStorageTest.php | 49 - .../Profiler/MemcachedProfilerStorageTest.php | 49 - .../Tests/Profiler/Mock/MemcacheMock.php | 254 - .../Tests/Profiler/Mock/MemcachedMock.php | 219 - .../Tests/Profiler/Mock/RedisMock.php | 247 - .../Profiler/MongoDbProfilerStorageTest.php | 165 - .../Tests/Profiler/ProfilerTest.php | 86 - .../Profiler/RedisProfilerStorageTest.php | 49 - .../Profiler/SqliteProfilerStorageTest.php | 50 - .../http-kernel/Tests/TestHttpKernel.php | 41 - .../http-kernel/Tests/UriSignerTest.php | 51 - .../process/Tests/AbstractProcessTest.php | 1213 --- .../process/Tests/ExecutableFinderTest.php | 149 - .../process/Tests/NonStopableProcess.php | 36 - .../process/Tests/PhpExecutableFinderTest.php | 97 - .../symfony/process/Tests/PhpProcessTest.php | 49 - .../PipeStdinInStdoutStdErrStreamSelect.php | 63 - .../process/Tests/ProcessBuilderTest.php | 225 - .../Tests/ProcessFailedExceptionTest.php | 136 - .../Tests/ProcessInSigchildEnvironment.php | 22 - .../process/Tests/ProcessUtilsTest.php | 48 - .../Tests/SigchildDisabledProcessTest.php | 263 - .../Tests/SigchildEnabledProcessTest.php | 148 - .../symfony/process/Tests/SignalListener.php | 16 - .../process/Tests/SimpleProcessTest.php | 222 - .../Tests/Factory/DiactorosFactoryTest.php | 164 - .../Factory/HttpFoundationFactoryTest.php | 211 - .../Tests/Fixtures/Message.php | 89 - .../Tests/Fixtures/Response.php | 45 - .../Tests/Fixtures/ServerRequest.php | 141 - .../Tests/Fixtures/Stream.php | 95 - .../Tests/Fixtures/UploadedFile.php | 65 - .../routing/Tests/Annotation/RouteTest.php | 58 - .../routing/Tests/CompiledRouteTest.php | 26 - .../AnnotatedClasses/AbstractClass.php | 16 - .../Fixtures/AnnotatedClasses/BarClass.php | 19 - .../Fixtures/AnnotatedClasses/FooClass.php | 16 - .../Tests/Fixtures/CustomXmlFileLoader.php | 26 - .../OtherAnnotatedClasses/VariadicClass.php | 19 - .../Tests/Fixtures/RedirectableUrlMatcher.php | 30 - .../routing/Tests/Fixtures/annotated.php | 0 .../routing/Tests/Fixtures/bad_format.yml | 3 - .../Tests/Fixtures/dumper/url_matcher1.apache | 163 - .../Tests/Fixtures/dumper/url_matcher1.php | 312 - .../Tests/Fixtures/dumper/url_matcher2.apache | 7 - .../Tests/Fixtures/dumper/url_matcher2.php | 344 - .../Tests/Fixtures/dumper/url_matcher3.php | 50 - .../symfony/routing/Tests/Fixtures/empty.yml | 0 vendor/symfony/routing/Tests/Fixtures/foo.xml | 0 .../symfony/routing/Tests/Fixtures/foo1.xml | 0 .../routing/Tests/Fixtures/incomplete.yml | 2 - .../Tests/Fixtures/legacy_validpattern.xml | 16 - .../Tests/Fixtures/legacy_validpattern.yml | 8 - .../routing/Tests/Fixtures/missing_id.xml | 8 - .../routing/Tests/Fixtures/missing_path.xml | 8 - .../Tests/Fixtures/namespaceprefix.xml | 13 - .../Fixtures/nonesense_resource_plus_path.yml | 3 - .../nonesense_type_without_resource.yml | 3 - .../routing/Tests/Fixtures/nonvalid.xml | 10 - .../routing/Tests/Fixtures/nonvalid.yml | 1 - .../routing/Tests/Fixtures/nonvalid2.yml | 1 - .../routing/Tests/Fixtures/nonvalidkeys.yml | 3 - .../routing/Tests/Fixtures/nonvalidnode.xml | 8 - .../routing/Tests/Fixtures/nonvalidroute.xml | 12 - .../routing/Tests/Fixtures/null_values.xml | 12 - .../Tests/Fixtures/special_route_name.yml | 2 - .../routing/Tests/Fixtures/validpattern.php | 18 - .../routing/Tests/Fixtures/validpattern.xml | 15 - .../routing/Tests/Fixtures/validpattern.yml | 13 - .../routing/Tests/Fixtures/validresource.php | 18 - .../routing/Tests/Fixtures/validresource.xml | 13 - .../routing/Tests/Fixtures/validresource.yml | 8 - .../Fixtures/with_define_path_variable.php | 5 - .../routing/Tests/Fixtures/withdoctype.xml | 3 - .../Dumper/PhpGeneratorDumperTest.php | 141 - .../Tests/Generator/UrlGeneratorTest.php | 665 -- .../Loader/AbstractAnnotationLoaderTest.php | 31 - .../Loader/AnnotationClassLoaderTest.php | 188 - .../Loader/AnnotationDirectoryLoaderTest.php | 53 - .../Tests/Loader/AnnotationFileLoaderTest.php | 61 - .../Tests/Loader/ClosureLoaderTest.php | 48 - .../Tests/Loader/PhpFileLoaderTest.php | 82 - .../Tests/Loader/XmlFileLoaderTest.php | 152 - .../Tests/Loader/YamlFileLoaderTest.php | 130 - .../Matcher/Dumper/DumperCollectionTest.php | 33 - .../Dumper/DumperPrefixCollectionTest.php | 123 - .../Dumper/LegacyApacheMatcherDumperTest.php | 215 - .../Matcher/Dumper/PhpMatcherDumperTest.php | 289 - .../Matcher/LegacyApacheUrlMatcherTest.php | 155 - .../Matcher/RedirectableUrlMatcherTest.php | 71 - .../Tests/Matcher/TraceableUrlMatcherTest.php | 101 - .../routing/Tests/Matcher/UrlMatcherTest.php | 419 - .../routing/Tests/RequestContextTest.php | 159 - .../routing/Tests/RouteCollectionTest.php | 304 - .../routing/Tests/RouteCompilerTest.php | 253 - vendor/symfony/routing/Tests/RouteTest.php | 284 - vendor/symfony/routing/Tests/RouterTest.php | 161 - .../Tests/Annotation/GroupsTest.php | 52 - .../Tests/Encoder/JsonEncoderTest.php | 79 - .../Tests/Encoder/XmlEncoderTest.php | 510 - .../Tests/Fixtures/CircularReferenceDummy.php | 23 - .../Tests/Fixtures/DenormalizableDummy.php | 22 - .../serializer/Tests/Fixtures/Dummy.php | 43 - .../serializer/Tests/Fixtures/GroupDummy.php | 80 - .../Tests/Fixtures/GroupDummyInterface.php | 25 - .../Tests/Fixtures/GroupDummyParent.php | 49 - .../Fixtures/NormalizableTraversableDummy.php | 36 - .../PropertyCircularReferenceDummy.php | 25 - .../Tests/Fixtures/PropertySiblingHolder.php | 39 - .../serializer/Tests/Fixtures/ScalarDummy.php | 37 - .../Tests/Fixtures/SiblingHolder.php | 57 - .../Tests/Fixtures/TraversableDummy.php | 23 - .../Fixtures/VariadicConstructorArgsDummy.php | 27 - .../Tests/Fixtures/empty-mapping.yml | 0 .../Tests/Fixtures/invalid-mapping.yml | 1 - .../Tests/Fixtures/serialization.xml | 18 - .../Tests/Fixtures/serialization.yml | 6 - .../Tests/Mapping/AttributeMetadataTest.php | 67 - .../Tests/Mapping/ClassMetadataTest.php | 82 - .../Factory/ClassMetadataFactoryTest.php | 78 - .../Mapping/Loader/AnnotationLoaderTest.php | 66 - .../Mapping/Loader/XmlFileLoaderTest.php | 54 - .../Mapping/Loader/YamlFileLoaderTest.php | 69 - .../Mapping/TestClassMetadataFactory.php | 82 - .../CamelCaseToSnakeCaseNameConverterTest.php | 53 - .../Tests/Normalizer/CustomNormalizerTest.php | 69 - .../Normalizer/GetSetMethodNormalizerTest.php | 799 -- .../Tests/Normalizer/ObjectNormalizerTest.php | 605 -- .../Normalizer/PropertyNormalizerTest.php | 493 - .../Tests/Normalizer/TestDenormalizer.php | 37 - .../Tests/Normalizer/TestNormalizer.php | 37 - .../serializer/Tests/SerializerTest.php | 267 - .../Tests/Catalogue/AbstractOperationTest.php | 73 - .../Tests/Catalogue/DiffOperationTest.php | 82 - .../Tests/Catalogue/MergeOperationTest.php | 83 - .../TranslationDataCollectorTest.php | 121 - .../Tests/DataCollectorTranslatorTest.php | 81 - .../Tests/Dumper/CsvFileDumperTest.php | 33 - .../Tests/Dumper/FileDumperTest.php | 70 - .../Tests/Dumper/IcuResFileDumperTest.php | 38 - .../Tests/Dumper/IniFileDumperTest.php | 32 - .../Tests/Dumper/JsonFileDumperTest.php | 36 - .../Tests/Dumper/MoFileDumperTest.php | 31 - .../Tests/Dumper/PhpFileDumperTest.php | 32 - .../Tests/Dumper/PoFileDumperTest.php | 31 - .../Tests/Dumper/QtFileDumperTest.php | 32 - .../Tests/Dumper/XliffFileDumperTest.php | 41 - .../Tests/Dumper/YamlFileDumperTest.php | 32 - .../Tests/IdentityTranslatorTest.php | 95 - .../translation/Tests/IntervalTest.php | 48 - .../Tests/Loader/CsvFileLoaderTest.php | 60 - .../Tests/Loader/IcuDatFileLoaderTest.php | 68 - .../Tests/Loader/IcuResFileLoaderTest.php | 55 - .../Tests/Loader/IniFileLoaderTest.php | 50 - .../Tests/Loader/JsonFileLoaderTest.php | 68 - .../Tests/Loader/LocalizedTestCase.php | 22 - .../Tests/Loader/MoFileLoaderTest.php | 71 - .../Tests/Loader/PhpFileLoaderTest.php | 49 - .../Tests/Loader/PoFileLoaderTest.php | 96 - .../Tests/Loader/QtFileLoaderTest.php | 67 - .../Tests/Loader/XliffFileLoaderTest.php | 143 - .../Tests/Loader/YamlFileLoaderTest.php | 70 - .../Tests/LoggingTranslatorTest.php | 56 - .../Tests/MessageCatalogueTest.php | 214 - .../translation/Tests/MessageSelectorTest.php | 130 - .../Tests/PluralizationRulesTest.php | 123 - .../translation/Tests/TranslatorCacheTest.php | 299 - .../translation/Tests/TranslatorTest.php | 627 -- .../Tests/fixtures/empty-translation.mo | Bin 49 -> 0 bytes .../Tests/fixtures/empty-translation.po | 3 - .../translation/Tests/fixtures/empty.csv | 0 .../translation/Tests/fixtures/empty.ini | 0 .../translation/Tests/fixtures/empty.json | 0 .../translation/Tests/fixtures/empty.mo | 0 .../translation/Tests/fixtures/empty.po | 0 .../translation/Tests/fixtures/empty.xlf | 0 .../translation/Tests/fixtures/empty.yml | 0 .../translation/Tests/fixtures/encoding.xlf | 16 - .../Tests/fixtures/escaped-id-plurals.po | 10 - .../translation/Tests/fixtures/escaped-id.po | 8 - .../Tests/fixtures/invalid-xml-resources.xlf | 23 - .../translation/Tests/fixtures/malformed.json | 3 - .../translation/Tests/fixtures/non-valid.xlf | 11 - .../translation/Tests/fixtures/non-valid.yml | 1 - .../translation/Tests/fixtures/plurals.mo | Bin 74 -> 0 bytes .../translation/Tests/fixtures/plurals.po | 5 - .../translation/Tests/fixtures/resname.xlf | 19 - .../resourcebundle/corrupted/resources.dat | 1 - .../Tests/fixtures/resourcebundle/dat/en.res | Bin 120 -> 0 bytes .../Tests/fixtures/resourcebundle/dat/en.txt | 3 - .../Tests/fixtures/resourcebundle/dat/fr.res | Bin 124 -> 0 bytes .../Tests/fixtures/resourcebundle/dat/fr.txt | 3 - .../resourcebundle/dat/packagelist.txt | 2 - .../fixtures/resourcebundle/dat/resources.dat | Bin 352 -> 0 bytes .../Tests/fixtures/resourcebundle/res/en.res | Bin 84 -> 0 bytes .../Tests/fixtures/resources-clean.xlf | 22 - .../translation/Tests/fixtures/resources.csv | 4 - .../translation/Tests/fixtures/resources.ini | 1 - .../translation/Tests/fixtures/resources.json | 3 - .../translation/Tests/fixtures/resources.mo | Bin 52 -> 0 bytes .../translation/Tests/fixtures/resources.php | 5 - .../translation/Tests/fixtures/resources.po | 8 - .../translation/Tests/fixtures/resources.ts | 10 - .../translation/Tests/fixtures/resources.xlf | 23 - .../translation/Tests/fixtures/resources.yml | 1 - .../translation/Tests/fixtures/valid.csv | 4 - .../Tests/fixtures/withdoctype.xlf | 12 - .../translation/Tests/fixtures/withnote.xlf | 22 - .../validator/Tests/ConstraintTest.php | 209 - .../Tests/ConstraintViolationListTest.php | 134 - .../Tests/ConstraintViolationTest.php | 55 - .../AbstractComparisonValidatorTestCase.php | 177 - .../AbstractConstraintValidatorTest.php | 441 - .../validator/Tests/Constraints/AllTest.php | 41 - .../Tests/Constraints/AllValidatorTest.php | 93 - .../Tests/Constraints/BlankValidatorTest.php | 69 - .../Constraints/CallbackValidatorTest.php | 355 - .../Constraints/CardSchemeValidatorTest.php | 135 - .../Tests/Constraints/ChoiceValidatorTest.php | 304 - .../Tests/Constraints/CollectionTest.php | 112 - .../CollectionValidatorArrayObjectTest.php | 20 - .../CollectionValidatorArrayTest.php | 20 - ...llectionValidatorCustomArrayObjectTest.php | 22 - .../Constraints/CollectionValidatorTest.php | 389 - .../Tests/Constraints/CompositeTest.php | 138 - .../Constraints/CountValidatorArrayTest.php | 23 - .../CountValidatorCountableTest.php | 25 - .../Tests/Constraints/CountValidatorTest.php | 203 - .../Constraints/CountryValidatorTest.php | 109 - .../Constraints/CurrencyValidatorTest.php | 111 - .../Constraints/DateTimeValidatorTest.php | 110 - .../Tests/Constraints/DateValidatorTest.php | 106 - .../Tests/Constraints/EmailValidatorTest.php | 106 - .../Constraints/EqualToValidatorTest.php | 69 - .../Constraints/ExpressionValidatorTest.php | 214 - .../validator/Tests/Constraints/FileTest.php | 152 - .../Constraints/FileValidatorObjectTest.php | 22 - .../Constraints/FileValidatorPathTest.php | 36 - .../Tests/Constraints/FileValidatorTest.php | 477 - .../validator/Tests/Constraints/Fixtures/foo | 0 .../Tests/Constraints/Fixtures/test.gif | Bin 801 -> 0 bytes .../Tests/Constraints/Fixtures/test_4by3.gif | Bin 57 -> 0 bytes .../Constraints/Fixtures/test_landscape.gif | Bin 43 -> 0 bytes .../Constraints/Fixtures/test_portrait.gif | Bin 43 -> 0 bytes .../GreaterThanOrEqualValidatorTest.php | 71 - .../Constraints/GreaterThanValidatorTest.php | 74 - .../Tests/Constraints/GroupSequenceTest.php | 97 - .../Tests/Constraints/IbanValidatorTest.php | 438 - .../Constraints/IdenticalToValidatorTest.php | 89 - .../Tests/Constraints/ImageValidatorTest.php | 332 - .../Tests/Constraints/IpValidatorTest.php | 444 - .../Constraints/IsFalseValidatorTest.php | 56 - .../Tests/Constraints/IsNullValidatorTest.php | 66 - .../Tests/Constraints/IsTrueValidatorTest.php | 56 - .../Tests/Constraints/IsbnValidatorTest.php | 271 - .../Tests/Constraints/IssnValidatorTest.php | 187 - .../Constraints/LanguageValidatorTest.php | 109 - .../Tests/Constraints/LengthValidatorTest.php | 255 - .../LessThanOrEqualValidatorTest.php | 74 - .../Constraints/LessThanValidatorTest.php | 73 - .../Tests/Constraints/LocaleValidatorTest.php | 96 - .../Tests/Constraints/LuhnValidatorTest.php | 127 - .../Constraints/NotBlankValidatorTest.php | 102 - .../Constraints/NotEqualToValidatorTest.php | 69 - .../NotIdenticalToValidatorTest.php | 87 - .../Constraints/NotNullValidatorTest.php | 60 - .../Tests/Constraints/RangeValidatorTest.php | 403 - .../validator/Tests/Constraints/RegexTest.php | 87 - .../Tests/Constraints/RegexValidatorTest.php | 97 - .../Tests/Constraints/TimeValidatorTest.php | 107 - .../Tests/Constraints/TypeValidatorTest.php | 185 - .../Tests/Constraints/UrlValidatorTest.php | 179 - .../Tests/Constraints/UuidValidatorTest.php | 211 - .../validator/Tests/Constraints/ValidTest.php | 28 - .../Tests/Fixtures/CallbackClass.php | 24 - .../Tests/Fixtures/ClassConstraint.php | 22 - .../validator/Tests/Fixtures/ConstraintA.php | 31 - .../Tests/Fixtures/ConstraintAValidator.php | 37 - .../validator/Tests/Fixtures/ConstraintB.php | 23 - .../validator/Tests/Fixtures/ConstraintC.php | 30 - .../Tests/Fixtures/ConstraintWithValue.php | 31 - .../Fixtures/ConstraintWithValueAsDefault.php | 31 - .../validator/Tests/Fixtures/Countable.php | 27 - .../Tests/Fixtures/CustomArrayObject.php | 70 - .../validator/Tests/Fixtures/Entity.php | 100 - .../Tests/Fixtures/EntityInterface.php | 16 - .../validator/Tests/Fixtures/EntityParent.php | 31 - .../Tests/Fixtures/FailingConstraint.php | 24 - .../Fixtures/FailingConstraintValidator.php | 23 - .../Tests/Fixtures/FakeClassMetadata.php | 26 - .../Tests/Fixtures/FakeMetadataFactory.php | 72 - .../validator/Tests/Fixtures/FilesLoader.php | 39 - .../Fixtures/GroupSequenceProviderEntity.php | 36 - .../Tests/Fixtures/InvalidConstraint.php | 18 - .../Fixtures/InvalidConstraintValidator.php | 16 - .../Tests/Fixtures/LegacyClassMetadata.php | 20 - .../Tests/Fixtures/PropertyConstraint.php | 22 - .../validator/Tests/Fixtures/Reference.php | 29 - .../Fixtures/StubGlobalExecutionContext.php | 70 - .../Tests/LegacyExecutionContextTest.php | 334 - .../validator/Tests/LegacyValidatorTest.php | 42 - .../Tests/Mapping/Cache/DoctrineCacheTest.php | 84 - .../Mapping/Cache/LegacyApcCacheTest.php | 81 - .../Tests/Mapping/ClassMetadataTest.php | 280 - .../Factory/BlackHoleMetadataFactoryTest.php | 33 - .../LazyLoadingMetadataFactoryTest.php | 118 - .../Tests/Mapping/GetterMetadataTest.php | 62 - .../Mapping/LegacyElementMetadataTest.php | 78 - .../Loader/AbstractStaticMethodLoader.php | 10 - .../Mapping/Loader/AnnotationLoaderTest.php | 162 - .../Tests/Mapping/Loader/FilesLoaderTest.php | 48 - .../Tests/Mapping/Loader/LoaderChainTest.php | 84 - .../Mapping/Loader/StaticMethodLoaderTest.php | 143 - .../Mapping/Loader/XmlFileLoaderTest.php | 133 - .../Mapping/Loader/YamlFileLoaderTest.php | 134 - .../Tests/Mapping/Loader/bad-format.yml | 9 - .../Loader/constraint-mapping-non-strings.xml | 19 - .../Mapping/Loader/constraint-mapping.xml | 119 - .../Mapping/Loader/constraint-mapping.yml | 62 - .../Tests/Mapping/Loader/empty-mapping.yml | 0 .../Tests/Mapping/Loader/nonvalid-mapping.yml | 1 - .../Tests/Mapping/Loader/withdoctype.xml | 7 - .../Tests/Mapping/MemberMetadataTest.php | 119 - .../Tests/Mapping/PropertyMetadataTest.php | 45 - .../validator/Tests/Util/PropertyPathTest.php | 36 - .../Tests/Validator/Abstract2Dot5ApiTest.php | 724 -- .../Tests/Validator/AbstractLegacyApiTest.php | 315 - .../Tests/Validator/AbstractValidatorTest.php | 1285 --- .../Validator/LegacyValidator2Dot5ApiTest.php | 35 - .../LegacyValidatorLegacyApiTest.php | 35 - .../RecursiveValidator2Dot5ApiTest.php | 57 - .../validator/Tests/ValidatorBuilderTest.php | 116 - vendor/symfony/yaml/Tests/DumperTest.php | 236 - .../yaml/Tests/Fixtures/YtsAnchorAlias.yml | 31 - .../yaml/Tests/Fixtures/YtsBasicTests.yml | 202 - .../yaml/Tests/Fixtures/YtsBlockMapping.yml | 51 - .../Tests/Fixtures/YtsDocumentSeparator.yml | 85 - .../yaml/Tests/Fixtures/YtsErrorTests.yml | 25 - .../Tests/Fixtures/YtsFlowCollections.yml | 60 - .../yaml/Tests/Fixtures/YtsFoldedScalars.yml | 176 - .../Tests/Fixtures/YtsNullsAndEmpties.yml | 45 - .../Fixtures/YtsSpecificationExamples.yml | 1697 ---- .../yaml/Tests/Fixtures/YtsTypeTransfers.yml | 244 - .../yaml/Tests/Fixtures/embededPhp.yml | 1 - .../yaml/Tests/Fixtures/escapedCharacters.yml | 147 - vendor/symfony/yaml/Tests/Fixtures/index.yml | 18 - .../yaml/Tests/Fixtures/sfComments.yml | 73 - .../symfony/yaml/Tests/Fixtures/sfCompact.yml | 159 - .../yaml/Tests/Fixtures/sfMergeKey.yml | 58 - .../symfony/yaml/Tests/Fixtures/sfObjects.yml | 11 - .../symfony/yaml/Tests/Fixtures/sfQuotes.yml | 33 - .../symfony/yaml/Tests/Fixtures/sfTests.yml | 135 - .../Tests/Fixtures/unindentedCollections.yml | 82 - vendor/symfony/yaml/Tests/InlineTest.php | 384 - .../symfony/yaml/Tests/ParseExceptionTest.php | 41 - vendor/symfony/yaml/Tests/ParserTest.php | 773 -- vendor/symfony/yaml/Tests/YamlTest.php | 37 - vendor/twig/twig/doc/advanced.rst | 872 -- vendor/twig/twig/doc/advanced_legacy.rst | 887 -- vendor/twig/twig/doc/api.rst | 552 - vendor/twig/twig/doc/coding_standards.rst | 101 - vendor/twig/twig/doc/deprecated.rst | 149 - vendor/twig/twig/doc/filters/abs.rst | 18 - vendor/twig/twig/doc/filters/batch.rst | 51 - vendor/twig/twig/doc/filters/capitalize.rst | 11 - .../twig/doc/filters/convert_encoding.rst | 28 - vendor/twig/twig/doc/filters/date.rst | 94 - vendor/twig/twig/doc/filters/date_modify.rst | 23 - vendor/twig/twig/doc/filters/default.rst | 33 - vendor/twig/twig/doc/filters/escape.rst | 116 - vendor/twig/twig/doc/filters/first.rst | 25 - vendor/twig/twig/doc/filters/format.rst | 16 - vendor/twig/twig/doc/filters/index.rst | 37 - vendor/twig/twig/doc/filters/join.rst | 23 - vendor/twig/twig/doc/filters/json_encode.rst | 21 - vendor/twig/twig/doc/filters/keys.rst | 11 - vendor/twig/twig/doc/filters/last.rst | 25 - vendor/twig/twig/doc/filters/length.rst | 11 - vendor/twig/twig/doc/filters/lower.rst | 10 - vendor/twig/twig/doc/filters/merge.rst | 48 - vendor/twig/twig/doc/filters/nl2br.rst | 22 - .../twig/twig/doc/filters/number_format.rst | 45 - vendor/twig/twig/doc/filters/raw.rst | 36 - vendor/twig/twig/doc/filters/replace.rst | 19 - vendor/twig/twig/doc/filters/reverse.rst | 47 - vendor/twig/twig/doc/filters/round.rst | 37 - vendor/twig/twig/doc/filters/slice.rst | 71 - vendor/twig/twig/doc/filters/sort.rst | 18 - vendor/twig/twig/doc/filters/split.rst | 53 - vendor/twig/twig/doc/filters/striptags.rst | 15 - vendor/twig/twig/doc/filters/title.rst | 11 - vendor/twig/twig/doc/filters/trim.rst | 29 - vendor/twig/twig/doc/filters/upper.rst | 10 - vendor/twig/twig/doc/filters/url_encode.rst | 34 - vendor/twig/twig/doc/functions/attribute.rst | 26 - vendor/twig/twig/doc/functions/block.rst | 15 - vendor/twig/twig/doc/functions/constant.rst | 18 - vendor/twig/twig/doc/functions/cycle.rst | 28 - vendor/twig/twig/doc/functions/date.rst | 52 - vendor/twig/twig/doc/functions/dump.rst | 69 - vendor/twig/twig/doc/functions/include.rst | 80 - vendor/twig/twig/doc/functions/index.rst | 20 - vendor/twig/twig/doc/functions/max.rst | 20 - vendor/twig/twig/doc/functions/min.rst | 20 - vendor/twig/twig/doc/functions/parent.rst | 20 - vendor/twig/twig/doc/functions/random.rst | 29 - vendor/twig/twig/doc/functions/range.rst | 45 - vendor/twig/twig/doc/functions/source.rst | 32 - .../doc/functions/template_from_string.rst | 32 - vendor/twig/twig/doc/index.rst | 19 - vendor/twig/twig/doc/installation.rst | 116 - vendor/twig/twig/doc/internals.rst | 138 - vendor/twig/twig/doc/intro.rst | 85 - vendor/twig/twig/doc/recipes.rst | 518 - vendor/twig/twig/doc/tags/autoescape.rst | 83 - vendor/twig/twig/doc/tags/block.rst | 11 - vendor/twig/twig/doc/tags/do.rst | 12 - vendor/twig/twig/doc/tags/embed.rst | 178 - vendor/twig/twig/doc/tags/extends.rst | 268 - vendor/twig/twig/doc/tags/filter.rst | 21 - vendor/twig/twig/doc/tags/flush.rst | 17 - vendor/twig/twig/doc/tags/for.rst | 172 - vendor/twig/twig/doc/tags/from.rst | 8 - vendor/twig/twig/doc/tags/if.rst | 76 - vendor/twig/twig/doc/tags/import.rst | 57 - vendor/twig/twig/doc/tags/include.rst | 86 - vendor/twig/twig/doc/tags/index.rst | 24 - vendor/twig/twig/doc/tags/macro.rst | 86 - vendor/twig/twig/doc/tags/sandbox.rst | 30 - vendor/twig/twig/doc/tags/set.rst | 78 - vendor/twig/twig/doc/tags/spaceless.rst | 37 - vendor/twig/twig/doc/tags/use.rst | 124 - vendor/twig/twig/doc/tags/verbatim.rst | 24 - vendor/twig/twig/doc/templates.rst | 888 -- vendor/twig/twig/doc/tests/constant.rst | 22 - vendor/twig/twig/doc/tests/defined.rst | 30 - vendor/twig/twig/doc/tests/divisibleby.rst | 14 - vendor/twig/twig/doc/tests/empty.rst | 11 - vendor/twig/twig/doc/tests/even.rst | 10 - vendor/twig/twig/doc/tests/index.rst | 15 - vendor/twig/twig/doc/tests/iterable.rst | 19 - vendor/twig/twig/doc/tests/null.rst | 12 - vendor/twig/twig/doc/tests/odd.rst | 10 - vendor/twig/twig/doc/tests/sameas.rst | 14 - vendor/twig/twig/ext/twig/.gitignore | 30 - vendor/twig/twig/ext/twig/config.m4 | 8 - vendor/twig/twig/ext/twig/config.w32 | 8 - vendor/twig/twig/ext/twig/php_twig.h | 35 - vendor/twig/twig/ext/twig/twig.c | 1127 -- .../twig/test/Twig/Tests/AutoloaderTest.php | 24 - .../twig/test/Twig/Tests/CompilerTest.php | 33 - .../twig/test/Twig/Tests/EnvironmentTest.php | 303 - .../twig/twig/test/Twig/Tests/ErrorTest.php | 144 - .../test/Twig/Tests/ExpressionParserTest.php | 332 - .../test/Twig/Tests/Extension/CoreTest.php | 156 - .../test/Twig/Tests/Extension/SandboxTest.php | 220 - .../twig/test/Twig/Tests/FileCachingTest.php | 85 - .../FileExtensionEscapingStrategyTest.php | 51 - .../Tests/Fixtures/autoescape/filename.test | 18 - .../test/Twig/Tests/Fixtures/errors/base.html | 1 - .../Twig/Tests/Fixtures/errors/index.html | 7 - ...ltiline_array_with_undefined_variable.test | 18 - ...e_array_with_undefined_variable_again.test | 18 - ...line_function_with_undefined_variable.test | 12 - ...tiline_function_with_unknown_argument.test | 9 - ...multiline_tag_with_undefined_variable.test | 12 - .../syntax_error_in_reused_template.test | 10 - .../Fixtures/exceptions/unclosed_tag.test | 20 - .../Fixtures/exceptions/undefined_parent.test | 8 - .../undefined_template_in_child_template.test | 15 - .../Fixtures/exceptions/undefined_trait.test | 9 - .../Tests/Fixtures/expressions/array.test | 61 - .../Fixtures/expressions/array_call.test | 14 - .../Tests/Fixtures/expressions/binary.test | 46 - .../Tests/Fixtures/expressions/bitwise.test | 14 - .../Fixtures/expressions/comparison.test | 14 - .../Fixtures/expressions/divisibleby.test | 17 - .../Tests/Fixtures/expressions/dotdot.test | 20 - .../Tests/Fixtures/expressions/ends_with.test | 26 - .../Tests/Fixtures/expressions/grouping.test | 8 - .../Tests/Fixtures/expressions/literals.test | 22 - .../Fixtures/expressions/magic_call.test | 27 - .../Tests/Fixtures/expressions/matches.test | 12 - .../Fixtures/expressions/method_call.test | 28 - .../expressions/negative_numbers.test | 18 - .../expressions/operators_as_variables.test | 16 - .../Tests/Fixtures/expressions/postfix.test | 22 - .../Tests/Fixtures/expressions/sameas.test | 21 - .../Fixtures/expressions/starts_with.test | 27 - .../Tests/Fixtures/expressions/strings.test | 10 - .../expressions/ternary_operator.test | 18 - .../expressions/ternary_operator_noelse.test | 10 - .../expressions/ternary_operator_nothen.test | 10 - .../two_word_operators_as_variables.test | 8 - .../Tests/Fixtures/expressions/unary.test | 12 - .../expressions/unary_macro_arguments.test | 22 - .../expressions/unary_precedence.test | 14 - .../test/Twig/Tests/Fixtures/filters/abs.test | 30 - .../Twig/Tests/Fixtures/filters/batch.test | 31 - .../Tests/Fixtures/filters/batch_float.test | 29 - .../filters/batch_with_empty_fill.test | 37 - .../filters/batch_with_exact_elements.test | 33 - .../Fixtures/filters/batch_with_fill.test | 37 - .../Fixtures/filters/batch_with_keys.test | 10 - .../filters/batch_with_zero_elements.test | 10 - .../Fixtures/filters/convert_encoding.test | 10 - .../Twig/Tests/Fixtures/filters/date.test | 90 - .../Fixtures/filters/date_default_format.test | 14 - .../filters/date_default_format_interval.test | 16 - .../Fixtures/filters/date_immutable.test | 37 - .../Tests/Fixtures/filters/date_interval.test | 19 - .../Tests/Fixtures/filters/date_modify.test | 14 - .../Fixtures/filters/date_namedargs.test | 13 - .../Twig/Tests/Fixtures/filters/default.test | 150 - .../Fixtures/filters/dynamic_filter.test | 10 - .../Twig/Tests/Fixtures/filters/escape.test | 8 - .../Fixtures/filters/escape_html_attr.test | 8 - .../filters/escape_non_supported_charset.test | 8 - .../Twig/Tests/Fixtures/filters/first.test | 17 - .../Tests/Fixtures/filters/force_escape.test | 18 - .../Twig/Tests/Fixtures/filters/format.test | 8 - .../Twig/Tests/Fixtures/filters/join.test | 12 - .../Tests/Fixtures/filters/json_encode.test | 12 - .../Twig/Tests/Fixtures/filters/last.test | 17 - .../Twig/Tests/Fixtures/filters/length.test | 14 - .../Tests/Fixtures/filters/length_utf8.test | 12 - .../Twig/Tests/Fixtures/filters/merge.test | 18 - .../Twig/Tests/Fixtures/filters/nl2br.test | 14 - .../Tests/Fixtures/filters/number_format.test | 18 - .../filters/number_format_default.test | 21 - .../Twig/Tests/Fixtures/filters/replace.test | 12 - .../Fixtures/filters/replace_invalid_arg.test | 8 - .../Twig/Tests/Fixtures/filters/reverse.test | 18 - .../Twig/Tests/Fixtures/filters/round.test | 22 - .../Twig/Tests/Fixtures/filters/slice.test | 54 - .../Twig/Tests/Fixtures/filters/sort.test | 12 - .../Tests/Fixtures/filters/special_chars.test | 8 - .../Twig/Tests/Fixtures/filters/split.test | 20 - .../Tests/Fixtures/filters/split_utf8.test | 24 - .../Twig/Tests/Fixtures/filters/trim.test | 12 - .../Tests/Fixtures/filters/urlencode.test | 16 - .../filters/urlencode_deprecated.test | 16 - .../Tests/Fixtures/functions/attribute.test | 18 - .../Twig/Tests/Fixtures/functions/block.test | 12 - .../Tests/Fixtures/functions/constant.test | 10 - .../Twig/Tests/Fixtures/functions/cycle.test | 16 - .../Twig/Tests/Fixtures/functions/date.test | 25 - .../Fixtures/functions/date_namedargs.test | 11 - .../Twig/Tests/Fixtures/functions/dump.test | 16 - .../Tests/Fixtures/functions/dump_array.test | 19 - .../Fixtures/functions/dynamic_function.test | 10 - .../functions/include/assignment.test | 13 - .../functions/include/autoescaping.test | 10 - .../Fixtures/functions/include/basic.test | 17 - .../functions/include/expression.test | 17 - .../functions/include/ignore_missing.test | 10 - .../Fixtures/functions/include/missing.test | 8 - .../functions/include/missing_nested.test | 16 - .../Fixtures/functions/include/sandbox.test | 13 - .../functions/include/sandbox_disabling.test | 16 - .../sandbox_disabling_ignore_missing.test | 13 - .../functions/include/template_instance.test | 10 - .../functions/include/templates_as_array.test | 12 - .../functions/include/with_context.test | 16 - .../functions/include/with_variables.test | 12 - .../Twig/Tests/Fixtures/functions/max.test | 12 - .../Twig/Tests/Fixtures/functions/min.test | 12 - .../Twig/Tests/Fixtures/functions/range.test | 8 - .../recursive_block_with_inheritance.test | 21 - .../Twig/Tests/Fixtures/functions/source.test | 17 - .../Fixtures/functions/special_chars.test | 8 - .../functions/template_from_string.test | 15 - .../Tests/Fixtures/macros/default_values.test | 16 - .../Tests/Fixtures/macros/nested_calls.test | 18 - .../Fixtures/macros/reserved_variables.test | 14 - .../Twig/Tests/Fixtures/macros/simple.test | 22 - .../Twig/Tests/Fixtures/macros/varargs.test | 21 - .../Fixtures/macros/varargs_argument.test | 8 - .../Tests/Fixtures/macros/with_filters.test | 14 - .../regression/combined_debug_info.test | 15 - .../Fixtures/regression/empty_token.test | 8 - .../Tests/Fixtures/regression/issue_1143.test | 23 - .../Fixtures/regression/multi_word_tests.test | 10 - .../regression/simple_xml_element.test | 19 - .../regression/strings_like_numbers.test | 8 - .../Tests/Fixtures/tags/autoescape/basic.test | 26 - .../Fixtures/tags/autoescape/blocks.test | 12 - .../tags/autoescape/double_escaping.test | 10 - .../Fixtures/tags/autoescape/functions.test | 83 - .../Fixtures/tags/autoescape/literal.test | 45 - .../Fixtures/tags/autoescape/nested.test | 26 - .../Fixtures/tags/autoescape/objects.test | 26 - .../Tests/Fixtures/tags/autoescape/raw.test | 10 - .../tags/autoescape/strategy.legacy.test | 11 - .../Fixtures/tags/autoescape/strategy.test | 11 - .../Tests/Fixtures/tags/autoescape/type.test | 69 - .../tags/autoescape/with_filters.test | 131 - .../autoescape/with_filters_arguments.test | 23 - .../autoescape/with_pre_escape_filters.test | 68 - .../with_preserves_safety_filters.test | 50 - .../Twig/Tests/Fixtures/tags/block/basic.test | 11 - .../tags/block/block_unique_name.test | 11 - .../Fixtures/tags/block/special_chars.test | 10 - .../Twig/Tests/Fixtures/tags/embed/basic.test | 35 - .../Tests/Fixtures/tags/embed/error_line.test | 16 - .../Tests/Fixtures/tags/embed/multiple.test | 50 - .../Tests/Fixtures/tags/embed/nested.test | 42 - .../Fixtures/tags/embed/with_extends.test | 57 - .../Tests/Fixtures/tags/filter/basic.test | 10 - .../Fixtures/tags/filter/json_encode.test | 8 - .../Tests/Fixtures/tags/filter/multiple.test | 10 - .../Tests/Fixtures/tags/filter/nested.test | 16 - .../Fixtures/tags/filter/with_for_tag.test | 13 - .../Fixtures/tags/filter/with_if_tag.test | 29 - .../Tests/Fixtures/tags/for/condition.test | 14 - .../Twig/Tests/Fixtures/tags/for/context.test | 18 - .../Twig/Tests/Fixtures/tags/for/else.test | 23 - .../Fixtures/tags/for/inner_variables.test | 17 - .../Twig/Tests/Fixtures/tags/for/keys.test | 11 - .../Fixtures/tags/for/keys_and_values.test | 11 - .../Tests/Fixtures/tags/for/loop_context.test | 19 - .../Fixtures/tags/for/loop_context_local.test | 10 - .../Fixtures/tags/for/loop_not_defined.test | 10 - .../tags/for/loop_not_defined_cond.test | 9 - .../Tests/Fixtures/tags/for/nested_else.test | 17 - .../Twig/Tests/Fixtures/tags/for/objects.test | 43 - .../Fixtures/tags/for/objects_countable.test | 47 - .../Tests/Fixtures/tags/for/recursive.test | 18 - .../Twig/Tests/Fixtures/tags/for/values.test | 11 - .../test/Twig/Tests/Fixtures/tags/from.test | 14 - .../Twig/Tests/Fixtures/tags/if/basic.test | 22 - .../Tests/Fixtures/tags/if/expression.test | 22 - .../Tests/Fixtures/tags/include/basic.test | 16 - .../Fixtures/tags/include/expression.test | 16 - .../Fixtures/tags/include/ignore_missing.test | 10 - .../Tests/Fixtures/tags/include/missing.test | 8 - .../Fixtures/tags/include/missing_nested.test | 16 - .../Tests/Fixtures/tags/include/only.test | 16 - .../tags/include/template_instance.test | 10 - .../tags/include/templates_as_array.test | 12 - .../Fixtures/tags/include/with_variables.test | 12 - .../Fixtures/tags/inheritance/basic.test | 14 - .../Fixtures/tags/inheritance/block_expr.test | 32 - .../tags/inheritance/block_expr2.test | 34 - .../tags/inheritance/conditional.test | 14 - .../Fixtures/tags/inheritance/dynamic.test | 14 - .../Fixtures/tags/inheritance/empty.test | 10 - .../tags/inheritance/extends_as_array.test | 12 - .../extends_as_array_with_empty_name.test | 12 - .../extends_as_array_with_null_name.test | 12 - .../Fixtures/tags/inheritance/multiple.test | 12 - .../tags/inheritance/multiple_dynamic.test | 22 - .../tags/inheritance/nested_blocks.test | 22 - .../nested_blocks_parent_only.test | 15 - .../tags/inheritance/nested_inheritance.test | 16 - .../Fixtures/tags/inheritance/parent.test | 12 - .../tags/inheritance/parent_change.test | 16 - .../tags/inheritance/parent_in_a_block.test | 8 - .../tags/inheritance/parent_isolation.test | 20 - .../tags/inheritance/parent_nested.test | 28 - .../inheritance/parent_without_extends.test | 8 - .../parent_without_extends_but_traits.test | 14 - .../tags/inheritance/template_instance.test | 14 - .../Tests/Fixtures/tags/inheritance/use.test | 44 - .../Twig/Tests/Fixtures/tags/macro/basic.test | 17 - .../Fixtures/tags/macro/endmacro_name.test | 16 - .../Tests/Fixtures/tags/macro/external.test | 17 - .../Twig/Tests/Fixtures/tags/macro/from.test | 18 - .../tags/macro/from_with_reserved_name.test | 9 - .../Tests/Fixtures/tags/macro/global.test | 14 - .../tags/macro/import_with_reserved_nam.test | 11 - .../Fixtures/tags/macro/reserved_name.test | 10 - .../Fixtures/tags/macro/self_import.test | 17 - .../Fixtures/tags/macro/special_chars.test | 14 - .../Fixtures/tags/macro/super_globals.test | 14 - .../Tests/Fixtures/tags/raw/basic.legacy.test | 10 - .../tags/raw/mixed_usage_with_raw.legacy.test | 10 - .../tags/raw/whitespace_control.legacy.test | 56 - .../Fixtures/tags/sandbox/not_valid1.test | 11 - .../Fixtures/tags/sandbox/not_valid2.test | 14 - .../Tests/Fixtures/tags/sandbox/simple.test | 22 - .../Twig/Tests/Fixtures/tags/set/basic.test | 20 - .../Fixtures/tags/set/capture-empty.test | 9 - .../Twig/Tests/Fixtures/tags/set/capture.test | 10 - .../Tests/Fixtures/tags/set/expression.test | 12 - .../Tests/Fixtures/tags/spaceless/simple.test | 12 - .../Tests/Fixtures/tags/special_chars.test | 8 - .../Twig/Tests/Fixtures/tags/trim_block.test | 74 - .../Twig/Tests/Fixtures/tags/use/aliases.test | 12 - .../Twig/Tests/Fixtures/tags/use/basic.test | 12 - .../Twig/Tests/Fixtures/tags/use/deep.test | 22 - .../Tests/Fixtures/tags/use/deep_empty.test | 10 - .../Tests/Fixtures/tags/use/inheritance.test | 25 - .../Tests/Fixtures/tags/use/inheritance2.test | 24 - .../Tests/Fixtures/tags/use/multiple.test | 21 - .../Fixtures/tags/use/multiple_aliases.test | 23 - .../Tests/Fixtures/tags/use/parent_block.test | 24 - .../Fixtures/tags/use/parent_block2.test | 24 - .../Fixtures/tags/use/parent_block3.test | 38 - .../Tests/Fixtures/tags/verbatim/basic.test | 10 - .../tags/verbatim/mixed_usage_with_raw.test | 10 - .../tags/verbatim/whitespace_control.test | 56 - .../test/Twig/Tests/Fixtures/tests/array.test | 24 - .../Twig/Tests/Fixtures/tests/constant.test | 14 - .../Twig/Tests/Fixtures/tests/defined.test | 108 - .../test/Twig/Tests/Fixtures/tests/empty.test | 45 - .../test/Twig/Tests/Fixtures/tests/even.test | 14 - .../test/Twig/Tests/Fixtures/tests/in.test | 128 - .../Tests/Fixtures/tests/in_with_objects.test | 19 - .../Twig/Tests/Fixtures/tests/iterable.test | 19 - .../test/Twig/Tests/Fixtures/tests/odd.test | 10 - .../twig/test/Twig/Tests/IntegrationTest.php | 229 - .../Tests/LegacyFixtures/test.legacy.test | 8 - .../test/Twig/Tests/LegacyIntegrationTest.php | 54 - .../twig/twig/test/Twig/Tests/LexerTest.php | 300 - .../twig/test/Twig/Tests/Loader/ArrayTest.php | 97 - .../twig/test/Twig/Tests/Loader/ChainTest.php | 79 - .../test/Twig/Tests/Loader/FilesystemTest.php | 175 - .../array_inheritance_empty_parent.html.twig | 3 - ...y_inheritance_nonexistent_parent.html.twig | 3 - .../array_inheritance_null_parent.html.twig | 3 - .../array_inheritance_valid_parent.html.twig | 3 - .../Fixtures/inheritance/parent.html.twig | 1 - .../inheritance/spare_parent.html.twig | 1 - .../Tests/Loader/Fixtures/named/index.html | 1 - .../Loader/Fixtures/named_bis/index.html | 1 - .../Loader/Fixtures/named_final/index.html | 1 - .../Fixtures/named_quater/named_absolute.html | 1 - .../Loader/Fixtures/named_ter/index.html | 1 - .../Tests/Loader/Fixtures/normal/index.html | 1 - .../Loader/Fixtures/normal_bis/index.html | 1 - .../Loader/Fixtures/normal_final/index.html | 1 - .../Loader/Fixtures/normal_ter/index.html | 1 - .../Fixtures/themes/theme1/blocks.html.twig | 3 - .../Fixtures/themes/theme2/blocks.html.twig | 3 - .../test/Twig/Tests/NativeExtensionTest.php | 33 - .../test/Twig/Tests/Node/AutoEscapeTest.php | 32 - .../Twig/Tests/Node/BlockReferenceTest.php | 31 - .../twig/test/Twig/Tests/Node/BlockTest.php | 39 - .../twig/twig/test/Twig/Tests/Node/DoTest.php | 32 - .../Twig/Tests/Node/Expression/ArrayTest.php | 37 - .../Tests/Node/Expression/AssignNameTest.php | 29 - .../Tests/Node/Expression/Binary/AddTest.php | 34 - .../Tests/Node/Expression/Binary/AndTest.php | 34 - .../Node/Expression/Binary/ConcatTest.php | 34 - .../Tests/Node/Expression/Binary/DivTest.php | 34 - .../Node/Expression/Binary/FloorDivTest.php | 34 - .../Tests/Node/Expression/Binary/ModTest.php | 34 - .../Tests/Node/Expression/Binary/MulTest.php | 34 - .../Tests/Node/Expression/Binary/OrTest.php | 34 - .../Tests/Node/Expression/Binary/SubTest.php | 34 - .../Twig/Tests/Node/Expression/CallTest.php | 116 - .../Tests/Node/Expression/ConditionalTest.php | 38 - .../Tests/Node/Expression/ConstantTest.php | 30 - .../Twig/Tests/Node/Expression/FilterTest.php | 154 - .../Tests/Node/Expression/FunctionTest.php | 110 - .../Tests/Node/Expression/GetAttrTest.php | 50 - .../Twig/Tests/Node/Expression/NameTest.php | 35 - .../Node/Expression/PHP53/FilterInclude.php | 6 - .../Node/Expression/PHP53/FunctionInclude.php | 6 - .../Node/Expression/PHP53/TestInclude.php | 6 - .../Twig/Tests/Node/Expression/ParentTest.php | 28 - .../Twig/Tests/Node/Expression/TestTest.php | 82 - .../Tests/Node/Expression/Unary/NegTest.php | 32 - .../Tests/Node/Expression/Unary/NotTest.php | 31 - .../Tests/Node/Expression/Unary/PosTest.php | 31 - .../twig/test/Twig/Tests/Node/ForTest.php | 191 - .../twig/twig/test/Twig/Tests/Node/IfTest.php | 88 - .../twig/test/Twig/Tests/Node/ImportTest.php | 40 - .../twig/test/Twig/Tests/Node/IncludeTest.php | 83 - .../twig/test/Twig/Tests/Node/MacroTest.php | 70 - .../twig/test/Twig/Tests/Node/ModuleTest.php | 183 - .../twig/test/Twig/Tests/Node/PrintTest.php | 29 - .../twig/test/Twig/Tests/Node/SandboxTest.php | 44 - .../Twig/Tests/Node/SandboxedPrintTest.php | 33 - .../twig/test/Twig/Tests/Node/SetTest.php | 69 - .../test/Twig/Tests/Node/SpacelessTest.php | 37 - .../twig/test/Twig/Tests/Node/TextTest.php | 28 - .../Twig/Tests/NodeVisitor/OptimizerTest.php | 124 - .../twig/twig/test/Twig/Tests/ParserTest.php | 180 - .../Tests/Profiler/Dumper/AbstractTest.php | 101 - .../Tests/Profiler/Dumper/BlackfireTest.php | 32 - .../Twig/Tests/Profiler/Dumper/HtmlTest.php | 30 - .../Twig/Tests/Profiler/Dumper/TextTest.php | 30 - .../test/Twig/Tests/Profiler/ProfileTest.php | 100 - .../twig/test/Twig/Tests/TemplateTest.php | 693 -- .../twig/test/Twig/Tests/TokenStreamTest.php | 70 - .../twig/test/Twig/Tests/escapingTest.php | 320 - vendor/twig/twig/test/bootstrap.php | 13 - 3062 files changed, 14753 insertions(+), 172215 deletions(-) create mode 100644 core/lib/Drupal/Core/Cache/CacheableRedirectResponse.php create mode 100644 core/lib/Drupal/Core/Entity/Controller/EntityController.php create mode 100644 core/lib/Drupal/Core/Entity/Routing/AdminHtmlRouteProvider.php create mode 100644 core/lib/Drupal/Core/Entity/Routing/DefaultHtmlRouteProvider.php create mode 100644 core/lib/Drupal/Core/Routing/CacheableSecuredRedirectResponse.php create mode 100644 core/modules/aggregator/src/FeedHtmlRouteProvider.php create mode 100644 core/modules/config_translation/src/Tests/ConfigTranslationInstallTest.php create mode 100644 core/modules/file/tests/src/Unit/Plugin/migrate/process/d6/CckFileTest.php create mode 100644 core/modules/migrate/tests/src/Kernel/Entity/MigrationTest.php create mode 100644 core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php create mode 100644 core/modules/migrate_drupal/src/Tests/d6/EntityContentBaseTest.php create mode 100644 core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migrate_overwrite_test.info.yml create mode 100644 core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migration_templates/users.yml rename core/modules/system/src/Tests/{Theme => Render/Element}/TableTest.php (98%) create mode 100644 core/modules/system/tests/modules/entity_test/src/Entity/EntityTestAdminRoutes.php create mode 100644 core/modules/text/tests/src/Unit/Migrate/TextFieldTest.php mode change 100644 => 100755 core/modules/views_ui/src/ParamConverter/ViewUIConverter.php create mode 100644 core/tests/Drupal/KernelTests/Core/Entity/RouteProviderTest.php mode change 100755 => 100644 vendor/behat/mink-browserkit-driver/README.md delete mode 100644 vendor/behat/mink-browserkit-driver/tests/BrowserKitConfig.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/Custom/BaseUrlTest.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/Custom/ErrorHandlingTest.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/app.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/404.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/500.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/advanced_form_post.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_auth.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_form_post.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_get_form.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page1.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page2.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page3.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/headers.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue130.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue140.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/print_cookies.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/redirector.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/response_headers.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/session_test.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page1.php delete mode 100644 vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page2.php delete mode 100644 vendor/behat/mink-goutte-driver/tests/Custom/InstantiationTest.php delete mode 100644 vendor/behat/mink-goutte-driver/tests/GoutteConfig.php delete mode 100644 vendor/behat/mink/driver-testsuite/README.md delete mode 100644 vendor/behat/mink/driver-testsuite/bootstrap.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/AbstractConfig.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/BasicAuthTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/BestPracticesTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/ContentTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/CookieTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/ErrorHandlingTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/HeaderTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/IFrameTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/NavigationTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/ScreenshotTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/StatusCodeTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/TraversingTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Basic/VisibilityTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Css/HoverTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Form/CheckboxTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Form/Html5Test.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Form/RadioTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Form/SelectTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Js/ChangeEventTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Js/EventsTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Js/JavascriptEvaluationTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Js/JavascriptTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/Js/WindowTest.php delete mode 100644 vendor/behat/mink/driver-testsuite/tests/TestCase.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/404.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/500.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/advanced_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/advanced_form_post.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/aria_roles.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/basic_auth.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/basic_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/basic_form_post.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/basic_get_form.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page1.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page2.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page3.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/css_mouse_events.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/element_change_detector.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/empty_textarea.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/form_without_button.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/headers.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/html5_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/html5_radio.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/html5_types.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/html_decoding.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/iframe.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/iframe_inner.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/index.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue130.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue131.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue140.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue178.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue193.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue211.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue212.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue215.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue225.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/issue255.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-1.6.2-min.js delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-ui-1.8.14.custom.min.js delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/js_test.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/json.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/links.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/multi_input_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/multicheckbox_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/multiselect_form.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/popup1.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/popup2.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/print_cookies.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/radio.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/randomizer.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/redirect_destination.html delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/redirector.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/response_headers.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/session_test.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/some_file.txt delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/sub-folder/cookie_page1.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/sub-folder/cookie_page2.php delete mode 100644 vendor/behat/mink/driver-testsuite/web-fixtures/window.html delete mode 100644 vendor/behat/mink/tests/Driver/CoreDriverTest.php delete mode 100644 vendor/behat/mink/tests/Element/DocumentElementTest.php delete mode 100644 vendor/behat/mink/tests/Element/ElementTest.php delete mode 100644 vendor/behat/mink/tests/Element/NodeElementTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ElementExceptionTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ElementHtmlExceptionTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ElementNotFoundExceptionTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ElementTextExceptionTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ExpectationExceptionTest.php delete mode 100644 vendor/behat/mink/tests/Exception/ResponseTextExceptionTest.php delete mode 100644 vendor/behat/mink/tests/MinkTest.php delete mode 100644 vendor/behat/mink/tests/Selector/CssSelectorTest.php delete mode 100644 vendor/behat/mink/tests/Selector/ExactNamedSelectorTest.php delete mode 100644 vendor/behat/mink/tests/Selector/NamedSelectorTest.php delete mode 100644 vendor/behat/mink/tests/Selector/PartialNamedSelectorTest.php delete mode 100644 vendor/behat/mink/tests/Selector/SelectorsHandlerTest.php delete mode 100644 vendor/behat/mink/tests/Selector/Xpath/EscaperTest.php delete mode 100644 vendor/behat/mink/tests/Selector/Xpath/ManipulatorTest.php delete mode 100644 vendor/behat/mink/tests/Selector/fixtures/test.html delete mode 100644 vendor/behat/mink/tests/SessionTest.php delete mode 100644 vendor/behat/mink/tests/WebAssertTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ApcCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ArrayCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/BaseFileCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ChainCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CouchbaseCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FileCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FilesystemCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcachedCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MongoDBCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PhpFileCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PredisCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RedisCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RiakCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/SQLite3CacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/VoidCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/WinCacheCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/XcacheCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ZendDataCacheTest.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/DoctrineTestCase.php delete mode 100644 vendor/doctrine/cache/tests/Doctrine/Tests/TestInit.php delete mode 100644 vendor/doctrine/cache/tests/travis/php.ini delete mode 100644 vendor/doctrine/cache/tests/travis/phpunit.travis.xml delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/AbstractLazyCollectionTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ArrayCollectionTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ClosureExpressionVisitorTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CollectionTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CriteriaTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ExpressionBuilderTest.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/LazyArrayCollection.php delete mode 100644 vendor/doctrine/collections/tests/Doctrine/Tests/TestInit.php delete mode 100644 vendor/doctrine/common/tests/.gitignore delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassA.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassB.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassC.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassD.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassE.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/EmptyFile.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ExternalLoader.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/InterfaceA.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/TraitA.class.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/DoctrineExceptionTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/EventManagerTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/ManagerRegistryTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/AnnotationDriverTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ChainDriverTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ClassMetadataFactoryTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/DefaultFileLocatorTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/FileDriverTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/PHPDriverTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/RuntimeReflectionServiceTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticPHPDriverTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticReflectionServiceTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/SymfonyFileLocatorTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/stdClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subsub/subSubClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/stdClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subsub.subSubClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/TestEntity.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/annotation/TestClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/global.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/stdClass.yml delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/ObjectManagerDecoratorTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/PersistentObjectTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AbstractProxyFactoryTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AutoloaderTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/CallableTypeHintClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/InvalidTypeHintClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObject.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObjectClassMetadata.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicCloneClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetByRefClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicIssetClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicSetClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicSleepClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicWakeupClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyClassGeneratorTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyLogicTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyMagicMethodsTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SerializedClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SleepClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/StaticPropertyClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/VariadicTypeHintClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/DeeperNamespaceParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/Dummies/NoParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/ExampleAnnotationClass.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/FullyClassifiedParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/NoParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/RuntimePublicReflectionPropertyTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/SameNamespaceParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/StaticReflectionParserTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/UseParent.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Util/ClassUtilsTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/Common/Util/DebugTest.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/DoctrineTestCase.php delete mode 100644 vendor/doctrine/common/tests/Doctrine/Tests/TestInit.php delete mode 100644 vendor/doctrine/common/tests/README.markdown delete mode 100644 vendor/doctrine/inflector/tests/Doctrine/Tests/Common/Inflector/InflectorTest.php delete mode 100644 vendor/doctrine/inflector/tests/Doctrine/Tests/DoctrineTestCase.php delete mode 100644 vendor/doctrine/inflector/tests/Doctrine/Tests/TestInit.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorPerformance/InstantiatorPerformanceEvent.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/InvalidArgumentExceptionTest.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/UnexpectedValueExceptionTest.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/InstantiatorTest.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/AbstractClassAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ArrayObjectAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ExceptionAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/FinalExceptionAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharExceptionAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SerializableArrayObjectAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleSerializableAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleTraitAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnCloneableAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnserializeExceptionArrayObjectAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/WakeUpNoticesAsset.php delete mode 100644 vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/XMLReaderAsset.php delete mode 100644 vendor/egulias/email-validator/documentation/Other.md delete mode 100644 vendor/egulias/email-validator/documentation/RFC5321BNF.html delete mode 100644 vendor/egulias/email-validator/documentation/RFC5322BNF.html delete mode 100644 vendor/egulias/email-validator/tests/bootstrap.php delete mode 100644 vendor/egulias/email-validator/tests/egulias/Performance/AgainstFilterVar.php delete mode 100644 vendor/egulias/email-validator/tests/egulias/Performance/AgainstOldIsemail.php delete mode 100644 vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailLexerTest.php delete mode 100644 vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailValidatorTest.php delete mode 100644 vendor/fabpot/goutte/Goutte/Tests/ClientTest.php delete mode 100644 vendor/fabpot/goutte/Goutte/Tests/fixtures.txt delete mode 100644 vendor/guzzlehttp/promises/tests/AggregateExceptionTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/EachPromiseTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/FulfilledPromiseTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/NotPromiseInstance.php delete mode 100644 vendor/guzzlehttp/promises/tests/PromiseTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/RejectedPromiseTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/RejectionExceptionTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/TaskQueueTest.php delete mode 100644 vendor/guzzlehttp/promises/tests/Thennable.php delete mode 100644 vendor/guzzlehttp/promises/tests/bootstrap.php delete mode 100644 vendor/guzzlehttp/promises/tests/functionsTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/AppendStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/BufferStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/CachingStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/FnStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/FunctionsTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/InflateStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/LimitStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/MultipartStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/NoSeekStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/PumpStreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/RequestTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/ResponseTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/StreamTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/UriTest.php delete mode 100644 vendor/guzzlehttp/psr7/tests/bootstrap.php delete mode 100644 vendor/masterminds/html5/test/HTML5/ElementsTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Html5Test.html delete mode 100644 vendor/masterminds/html5/test/HTML5/Html5Test.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/CharacterReferenceTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/DOMTreeBuilderTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/EventStack.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/EventStackError.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.html delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/InstructionProcessorMock.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/ScannerTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/TreeBuildingRulesTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Parser/UTF8UtilsTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Serializer/OutputRulesTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/Serializer/TraverserTest.php delete mode 100644 vendor/masterminds/html5/test/HTML5/TestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/DirectoryIterationTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/Issue104TestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/PermissionsTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/QuotaTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/UnlinkTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/LargeFileContentTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/proxy/vfsStreamWrapperRecordingProxy.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamAbstractContentTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamBlockTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamContainerIteratorTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryIssue18TestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamExLockTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamFileTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamGlobTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamResolveIncludePathTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamUmaskTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperAlreadyRegisteredTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperBaseTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirSeparatorTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTimesTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFlockTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperLargeFileTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperQuotaTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperSetOptionTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperStreamSelectTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperUnregisterTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperWithoutRootTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamZipTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamAbstractVisitorTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamPrintVisitorTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamStructureVisitorTestCase.php delete mode 100644 vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/aFile.txt delete mode 100644 vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/subfolder1/file1.txt delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/DescriptionTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/CoversTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/DeprecatedTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ExampleTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/LinkTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/MethodTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ParamTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ReturnTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SeeTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SinceTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SourceTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ThrowsTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/UsesTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VarTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VersionTagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/TagTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Type/CollectionTest.php delete mode 100644 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlockTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/FilterTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/CloverTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/FactoryTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/UtilTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverageTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/TestCase.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodOneLineAnnotationTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_ignore.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_namespace.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_oneline_annotations.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_without_namespace.php delete mode 100644 vendor/phpunit/php-timer/Tests/TimerTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/ClassTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/ClosureTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/FunctionTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/IncludeTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/InterfaceTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/TokenTest.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/classExtendsNamespacedClass.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/classInNamespace.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/classInScopedNamespace.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/class_with_method_that_declares_anonymous_class.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/class_with_method_that_declares_anonymous_class2.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/closure.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/issue19.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/issue30.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/multipleNamespacesWithOneClassUsingBraces.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/multipleNamespacesWithOneClassUsingNonBraceSyntax.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/source.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/source2.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/source3.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/source4.php delete mode 100644 vendor/phpunit/php-token-stream/tests/_fixture/source5.php delete mode 100644 vendor/phpunit/php-token-stream/tests/bootstrap.php delete mode 100644 vendor/phpunit/phpunit/tests/Extensions/PhptTestCaseTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Extensions/RepeatedTestTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Fail/fail.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Framework/AssertTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/BaseTestListenerTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/Constraint/CountTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageRegExpTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatches/ErrorMessageProviderTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatchesTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/ConstraintTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/SuiteTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/TestCaseTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/TestFailureTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/TestImplementorTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Framework/TestListenerTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/1021.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/1021/Issue1021Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/523.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/523/Issue523Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/578.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/578/Issue578Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/684.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/684/Issue684Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/783.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/783/ChildSuite.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/783/OneTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/783/ParentSuite.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/783/TwoTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1149.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1149/Issue1149Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1216.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1216/Issue1216Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1216/bootstrap1216.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1216/phpunit1216.xml delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1265.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1265/Issue1265Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1265/phpunit1265.xml delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1330.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1330/Issue1330Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1330/phpunit1330.xml delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1335.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1335/Issue1335Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1335/bootstrap1335.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1337.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1337/Issue1337Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1348.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1348/Issue1348Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1351.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1351/ChildProcessClass1351.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1351/Issue1351Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1374.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1374/Issue1374Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1437.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1437/Issue1437Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1468.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1468/Issue1468Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1471.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1471/Issue1471Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1472.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1472/Issue1472Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1570.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/1570/Issue1570Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/244.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/244/Issue244Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/322.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/322/Issue322Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/322/phpunit322.xml delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/433.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/433/Issue433Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/445.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/445/Issue445Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/498.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/498/Issue498Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/503.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/503/Issue503Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/581.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/581/Issue581Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/74.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/74/Issue74Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/74/NewException.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/765.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/765/Issue765Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/797.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/797/Issue797Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/797/bootstrap797.php delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/863.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/873-php5.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/873-php7.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Regression/GitHub/873/Issue873Test.php delete mode 100644 vendor/phpunit/phpunit/tests/Runner/BaseTestRunnerTest.php delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/abstract-test-class.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/colors-always.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/concrete-test-class.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/custom-printer-debug.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/custom-printer-verbose.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dataprovider-debug.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dataprovider-testdox.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/debug.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/default-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/default.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies2-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies2.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies3-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/dependencies3.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/empty-testcase.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/exception-stack.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/exclude-group-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/exclude-group.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/failure-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/failure.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/fatal-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-class-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-class.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-method-case-insensitive.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-method-case-sensitive-no-result.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-method-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-method.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/filter-no-results.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/group-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/group.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/help.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/help2.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/ini-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/list-groups.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/log-json-no-pretty-print.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/log-json-post-66021.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/log-json-pre-66021.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/log-tap.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/log-xml.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/options-after-arguments.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/output-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/repeat.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-incomplete.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-isolation.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/report-useless-tests.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/tap.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/test-suffix-multiple.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/test-suffix-single.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/testdox-html.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/testdox-text.phpt delete mode 100644 vendor/phpunit/phpunit/tests/TextUI/testdox.phpt delete mode 100644 vendor/phpunit/phpunit/tests/Util/ConfigurationTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/GetoptTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/GlobalStateTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/RegexTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/TestDox/NamePrettifierTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/TestTest.php delete mode 100644 vendor/phpunit/phpunit/tests/Util/XMLTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/AbstractTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Author.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BankAccount.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BankAccountTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BankAccountTest.test.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BaseTestListenerSample.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BeforeAndAfterTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/BeforeClassAndAfterClassTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Book.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Calculator.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ChangeCurrentWorkingDirectoryTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ClassWithNonPublicAttributes.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ClassWithScalarTypeDeclarations.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ClassWithToString.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ConcreteTest.my.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ConcreteTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageClassTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageFunctionParenthesesTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageFunctionParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageFunctionTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageMethodOneLineAnnotationTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageMethodTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNamespacedFunctionTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNoneTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNotPublicTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageNothingTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoveragePrivateTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageProtectedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoveragePublicTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoverageTwoDefaultClassAnnotations.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoveredClass.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CoveredFunction.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/CustomPrinter.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DataProviderDebugTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DataProviderFilterTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DataProviderIncompleteTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DataProviderSkippedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DataProviderTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DependencyFailureTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DependencySuccessTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DependencyTestSuite.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DoubleTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/DummyException.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/EmptyTestCaseTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionInAssertPostConditionsTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionInAssertPreConditionsTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionInSetUpTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionInTearDownTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionInTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionNamespaceTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionStackTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ExceptionTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Failure.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/FailureTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/FatalTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/IncompleteTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Inheritance/InheritanceA.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Inheritance/InheritanceB.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/InheritedTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/IniTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/IsolationTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/JsonData/arrayObject.json delete mode 100644 vendor/phpunit/phpunit/tests/_files/JsonData/simpleObject.json delete mode 100644 vendor/phpunit/phpunit/tests/_files/MockRunner.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/MultiDependencyTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassPublicTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageMethodTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPublicTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePrivateTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoverageProtectedTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePublicTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoveredClass.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NamespaceCoveredFunction.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NoArgTestCaseTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NoTestCaseClass.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NoTestCases.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NonStatic.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NotExistingCoveredElementTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NotPublicTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NotVoidTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/NothingTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/OneTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/OutputTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/OverrideTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/RequirementsClassBeforeClassHookTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/RequirementsClassDocBlockTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/RequirementsTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/SampleArrayAccess.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/SampleClass.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Singleton.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/StackTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Struct.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/Success.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TemplateMethodsTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestIncomplete.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestIterator.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestIterator2.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestSkipped.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestTestError.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/TestWithTest.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ThrowExceptionTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/ThrowNoExceptionTestCase.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/WasRun.php delete mode 100644 vendor/phpunit/phpunit/tests/_files/bar.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.colors.empty.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.colors.false.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.colors.invalid.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.colors.true.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.custom-printer.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration_empty.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/configuration_xinclude.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/expectedFileFormat.txt delete mode 100644 vendor/phpunit/phpunit/tests/_files/foo.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureAttributesAreSameButValuesAreNot.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureExpected.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureIgnoreTextNodes.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureIsSameButDataIsNot.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfAttributes.xml delete mode 100644 vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfNodes.xml delete mode 100644 vendor/phpunit/phpunit/tests/bootstrap.php delete mode 100644 vendor/sebastian/comparator/tests/ArrayComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/DateTimeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/DoubleComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ExceptionComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/FactoryTest.php delete mode 100644 vendor/sebastian/comparator/tests/MockObjectComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/NumericComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ObjectComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ResourceComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ScalarComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/TypeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/_files/Author.php delete mode 100644 vendor/sebastian/comparator/tests/_files/Book.php delete mode 100644 vendor/sebastian/comparator/tests/_files/ClassWithToString.php delete mode 100644 vendor/sebastian/comparator/tests/_files/SampleClass.php delete mode 100644 vendor/sebastian/comparator/tests/_files/Struct.php delete mode 100644 vendor/sebastian/comparator/tests/_files/TestClass.php delete mode 100644 vendor/sebastian/comparator/tests/_files/TestClassComparator.php delete mode 100644 vendor/sebastian/comparator/tests/autoload.php delete mode 100644 vendor/sebastian/comparator/tests/bootstrap.php delete mode 100644 vendor/sebastian/diff/tests/DifferTest.php delete mode 100644 vendor/sebastian/diff/tests/LCS/TimeEfficientImplementationTest.php delete mode 100644 vendor/sebastian/diff/tests/ParserTest.php delete mode 100644 vendor/sebastian/diff/tests/fixtures/patch.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/patch2.txt delete mode 100644 vendor/sebastian/environment/tests/ConsoleTest.php delete mode 100644 vendor/sebastian/environment/tests/RuntimeTest.php delete mode 100644 vendor/sebastian/exporter/tests/ExporterTest.php delete mode 100644 vendor/sebastian/global-state/tests/BlacklistTest.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php delete mode 100644 vendor/sebastian/recursion-context/tests/ContextTest.php delete mode 100644 vendor/stack/builder/tests/functional/SilexApplicationTest.php delete mode 100644 vendor/stack/builder/tests/unit/Stack/BuilderTest.php delete mode 100644 vendor/stack/builder/tests/unit/Stack/StackedHttpKernelTest.php delete mode 100644 vendor/symfony-cmf/routing/Test/CmfUnitTestCase.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Candidates/CandidatesTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRouteEnhancersPassTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRoutersPassTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Enhancer/FieldByClassEnhancerTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Enhancer/FieldMapEnhancerTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Enhancer/FieldPresenceEnhancerTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Enhancer/RouteContentEnhancerTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Enhancer/RouteObject.php delete mode 100644 vendor/symfony-cmf/routing/Tests/NestedMatcher/NestedMatcherTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/NestedMatcher/UrlMatcherTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/ChainRouterTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/DynamicRouterTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/LazyRouteCollectionTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/PagedRouteCollectionTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/ProviderBasedGeneratorTest.php delete mode 100644 vendor/symfony-cmf/routing/Tests/Routing/RouteMock.php delete mode 100644 vendor/symfony-cmf/routing/Tests/bootstrap.php delete mode 100644 vendor/symfony/browser-kit/Tests/ClientTest.php delete mode 100644 vendor/symfony/browser-kit/Tests/CookieJarTest.php delete mode 100644 vendor/symfony/browser-kit/Tests/CookieTest.php delete mode 100644 vendor/symfony/browser-kit/Tests/HistoryTest.php delete mode 100644 vendor/symfony/browser-kit/Tests/RequestTest.php delete mode 100644 vendor/symfony/browser-kit/Tests/ResponseTest.php delete mode 100644 vendor/symfony/class-loader/Tests/ClassCollectionLoaderTest.php delete mode 100644 vendor/symfony/class-loader/Tests/ClassLoaderTest.php delete mode 100644 vendor/symfony/class-loader/Tests/ClassMapGeneratorTest.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/ApcPrefixCollision/A/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/ApcPrefixCollision/A/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/NamespaceCollision/A/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/NamespaceCollision/A/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/ApcPrefixCollision/A/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/ApcPrefixCollision/A/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/NamespaceCollision/A/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/NamespaceCollision/A/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/fallback/Apc/Pearlike/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Apc/fallback/Namespaced/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/A.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/ATrait.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/B.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/BTrait.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/CInterface.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/CTrait.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/D.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/E.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/F.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/G.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/GInterface.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced/WithComments.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced2/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced2/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Namespaced2/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike/WithComments.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Baz.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/A/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/A/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/C/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/C/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/PrefixCollision/A/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/PrefixCollision/A/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/PrefixCollision/C/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/alpha/PrefixCollision/C/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/A/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/A/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/C/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/C/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/PrefixCollision/A/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/PrefixCollision/A/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/PrefixCollision/C/B/Bar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/beta/PrefixCollision/C/B/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeClass.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeInterface.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeParent.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/multipleNs.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/notAClass.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/notPhpFile.md delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/classmap/sameNsMultipleClasses.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/deps/traits.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/fallback/Namespaced/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/fallback/Namespaced2/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/fallback/Pearlike/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/fallback/Pearlike2/FooBar.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/includepath/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/php5.4/traits.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/php5.5/class_cons.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/psr-4/Class_With_Underscores.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/psr-4/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/psr-4/Lets/Go/Deeper/Class_With_Underscores.php delete mode 100644 vendor/symfony/class-loader/Tests/Fixtures/psr-4/Lets/Go/Deeper/Foo.php delete mode 100644 vendor/symfony/class-loader/Tests/LegacyApcUniversalClassLoaderTest.php delete mode 100644 vendor/symfony/class-loader/Tests/LegacyUniversalClassLoaderTest.php delete mode 100644 vendor/symfony/class-loader/Tests/Psr4ClassLoaderTest.php delete mode 100644 vendor/symfony/console/Tests/ApplicationTest.php delete mode 100644 vendor/symfony/console/Tests/ClockMock.php delete mode 100644 vendor/symfony/console/Tests/Command/CommandTest.php delete mode 100644 vendor/symfony/console/Tests/Command/HelpCommandTest.php delete mode 100644 vendor/symfony/console/Tests/Command/ListCommandTest.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/AbstractDescriptorTest.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/JsonDescriptorTest.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/MarkdownDescriptorTest.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/ObjectsProvider.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/TextDescriptorTest.php delete mode 100644 vendor/symfony/console/Tests/Descriptor/XmlDescriptorTest.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/BarBucCommand.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/DescriptorApplication1.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/DescriptorApplication2.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/DescriptorCommand1.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/DescriptorCommand2.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/DummyOutput.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Foo1Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Foo2Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Foo3Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Foo4Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Foo5Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/FooCommand.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/FooSubnamespaced1Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/FooSubnamespaced2Command.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/FoobarCommand.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_0.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_1.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_2.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_3.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_4.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_5.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_6.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_7.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_0.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_5.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_6.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_7.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/TestCommand.php delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_1.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_1.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_1.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_2.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_2.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_2.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_astext1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_astext2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_asxml1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_asxml2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_gethelp.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception3decorated.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1decorated.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_run1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_run2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_run3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/application_run4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_1.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_1.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_1.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_2.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_2.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_2.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_astext.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/command_asxml.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/definition_astext.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/definition_asxml.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_1.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_1.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_1.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_2.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_2.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_2.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_3.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_3.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_3.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_4.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_4.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_argument_4.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_1.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_1.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_1.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_2.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_2.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_2.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_3.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_3.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_3.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_4.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_4.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_definition_4.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_1.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_1.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_1.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_1.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_2.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_2.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_2.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_2.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_3.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_3.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_3.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_3.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_4.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_4.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_4.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_4.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_5.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_5.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_5.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_5.xml delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_6.json delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_6.md delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_6.txt delete mode 100644 vendor/symfony/console/Tests/Fixtures/input_option_6.xml delete mode 100644 vendor/symfony/console/Tests/Formatter/OutputFormatterStyleStackTest.php delete mode 100644 vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php delete mode 100644 vendor/symfony/console/Tests/Formatter/OutputFormatterTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/FormatterHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/HelperSetTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/LegacyDialogHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/LegacyProgressHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/LegacyTableHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/ProcessHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/ProgressBarTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/QuestionHelperTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/TableStyleTest.php delete mode 100644 vendor/symfony/console/Tests/Helper/TableTest.php delete mode 100644 vendor/symfony/console/Tests/Input/ArgvInputTest.php delete mode 100644 vendor/symfony/console/Tests/Input/ArrayInputTest.php delete mode 100644 vendor/symfony/console/Tests/Input/InputArgumentTest.php delete mode 100644 vendor/symfony/console/Tests/Input/InputDefinitionTest.php delete mode 100644 vendor/symfony/console/Tests/Input/InputOptionTest.php delete mode 100644 vendor/symfony/console/Tests/Input/InputTest.php delete mode 100644 vendor/symfony/console/Tests/Input/StringInputTest.php delete mode 100644 vendor/symfony/console/Tests/Logger/ConsoleLoggerTest.php delete mode 100644 vendor/symfony/console/Tests/Output/ConsoleOutputTest.php delete mode 100644 vendor/symfony/console/Tests/Output/NullOutputTest.php delete mode 100644 vendor/symfony/console/Tests/Output/OutputTest.php delete mode 100644 vendor/symfony/console/Tests/Output/StreamOutputTest.php delete mode 100644 vendor/symfony/console/Tests/Style/SymfonyStyleTest.php delete mode 100644 vendor/symfony/console/Tests/Tester/ApplicationTesterTest.php delete mode 100644 vendor/symfony/console/Tests/Tester/CommandTesterTest.php delete mode 100644 vendor/symfony/css-selector/Tests/CssSelectorTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/AbstractNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/AttributeNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/ClassNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/CombinedSelectorNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/ElementNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/FunctionNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/HashNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/NegationNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/PseudoNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/SelectorNodeTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Node/SpecificityTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/AbstractHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/CommentHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/HashHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/IdentifierHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/NumberHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/StringHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Handler/WhitespaceHandlerTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/ParserTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/ReaderTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Shortcut/ClassParserTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Shortcut/ElementParserTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Shortcut/EmptyStringParserTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/Shortcut/HashParserTest.php delete mode 100644 vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php delete mode 100644 vendor/symfony/css-selector/Tests/XPath/Fixtures/ids.html delete mode 100644 vendor/symfony/css-selector/Tests/XPath/Fixtures/lang.xml delete mode 100644 vendor/symfony/css-selector/Tests/XPath/Fixtures/shakespear.html delete mode 100644 vendor/symfony/css-selector/Tests/XPath/TranslatorTest.php delete mode 100644 vendor/symfony/debug/Tests/DebugClassLoaderTest.php delete mode 100644 vendor/symfony/debug/Tests/ErrorHandlerTest.php delete mode 100644 vendor/symfony/debug/Tests/Exception/FlattenExceptionTest.php delete mode 100644 vendor/symfony/debug/Tests/ExceptionHandlerTest.php delete mode 100644 vendor/symfony/debug/Tests/FatalErrorHandler/ClassNotFoundFatalErrorHandlerTest.php delete mode 100644 vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedFunctionFatalErrorHandlerTest.php delete mode 100644 vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedMethodFatalErrorHandlerTest.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/ClassAlias.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/DeprecatedClass.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/DeprecatedInterface.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/PEARClass.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/casemismatch.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/notPsr0Bis.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/psr4/Psr4CaseMismatch.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures/reallyNotPsr0.php delete mode 100644 vendor/symfony/debug/Tests/Fixtures2/RequiredTwice.php delete mode 100644 vendor/symfony/debug/Tests/HeaderMock.php delete mode 100644 vendor/symfony/debug/Tests/MockExceptionHandler.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/LegacyResolveParameterPlaceHoldersPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ContainerTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/CrossCheckTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/DefinitionTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container10.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container15.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container18.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container20.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/legacy-container9.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/legacy-services9.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtensionInPhar.phar delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services1.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services10.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services20.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services6.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services9.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services20.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag4.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services6.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services9.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services20.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml delete mode 100644 vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/LegacyContainerBuilderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/LegacyDefinitionTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ParameterTest.php delete mode 100644 vendor/symfony/dependency-injection/Tests/ReferenceTest.php delete mode 100755 vendor/symfony/dom-crawler/Tests/CrawlerTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/ChoiceFormFieldTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/FileFormFieldTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/FormFieldTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/FormFieldTestCase.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/InputFormFieldTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Field/TextareaFormFieldTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/Fixtures/no-extension delete mode 100644 vendor/symfony/dom-crawler/Tests/Fixtures/windows-1250.html delete mode 100644 vendor/symfony/dom-crawler/Tests/FormTest.php delete mode 100644 vendor/symfony/dom-crawler/Tests/LinkTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/AcceptHeaderItemTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/AcceptHeaderTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ApacheRequestTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/BinaryFileResponseTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ClockMock.php delete mode 100644 vendor/symfony/http-foundation/Tests/CookieTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ExpressionRequestMatcherTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/File/FakeFile.php delete mode 100644 vendor/symfony/http-foundation/Tests/File/FileTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/File/Fixtures/.unknownextension delete mode 100644 vendor/symfony/http-foundation/Tests/File/Fixtures/directory/.empty delete mode 100644 vendor/symfony/http-foundation/Tests/File/Fixtures/other-file.example delete mode 100644 vendor/symfony/http-foundation/Tests/File/Fixtures/test delete mode 100644 vendor/symfony/http-foundation/Tests/File/Fixtures/test.gif delete mode 100644 vendor/symfony/http-foundation/Tests/File/MimeType/MimeTypeTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/File/UploadedFileTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/FileBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/HeaderBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/IpUtilsTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/JsonResponseTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ParameterBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/RedirectResponseTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/RequestMatcherTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/RequestStackTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/RequestTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ResponseHeaderBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ResponseTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/ResponseTestCase.php delete mode 100644 vendor/symfony/http-foundation/Tests/ServerBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Attribute/AttributeBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Attribute/NamespacedAttributeBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Flash/AutoExpireFlashBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Flash/FlashBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/SessionTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/LegacyPdoSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/MemcacheSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/MemcachedSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/MongoDbSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/NativeFileSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/NativeSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/NullSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/PdoSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Handler/WriteCheckSessionHandlerTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/MetadataBagTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/MockArraySessionStorageTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/MockFileSessionStorageTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/NativeSessionStorageTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/PhpBridgeSessionStorageTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Proxy/AbstractProxyTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Proxy/NativeProxyTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/Session/Storage/Proxy/SessionHandlerProxyTest.php delete mode 100644 vendor/symfony/http-foundation/Tests/StreamedResponseTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Bundle/BundleTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/CacheClearer/ChainCacheClearerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/CacheWarmer/CacheWarmerAggregateTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/CacheWarmer/CacheWarmerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/ClientTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Config/EnvParametersResourceTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Config/FileLocatorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Controller/ControllerResolverTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/ConfigDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/DumpDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/ExceptionDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/LoggerDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/MemoryDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/RequestDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/TimeDataCollectorTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DataCollector/Util/ValueExporterTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Debug/TraceableEventDispatcherTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DependencyInjection/ContainerAwareHttpKernelTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DependencyInjection/FragmentRendererPassTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DependencyInjection/LazyLoadingFragmentHandlerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/DependencyInjection/MergeExtensionConfigurationPassTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/AddRequestFormatsListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/DebugHandlersListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/DumpListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/ExceptionListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/FragmentListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/LocaleListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/ProfilerListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/ResponseListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/RouterListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/SurrogateListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/TestSessionListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/EventListener/TranslatorListenerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/BaseBundle/Resources/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/BaseBundle/Resources/hide.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Bundle1Bundle/Resources/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Bundle1Bundle/bar.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Bundle1Bundle/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Bundle2Bundle/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ChildBundle/Resources/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ChildBundle/Resources/hide.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionAbsentBundle/ExtensionAbsentBundle.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionLoadedBundle/DependencyInjection/ExtensionLoadedExtension.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionLoadedBundle/ExtensionLoadedBundle.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionNotValidBundle/DependencyInjection/ExtensionNotValidExtension.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionNotValidBundle/ExtensionNotValidBundle.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionPresentBundle/Command/BarCommand.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionPresentBundle/Command/FooCommand.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionPresentBundle/DependencyInjection/ExtensionPresentExtension.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/ExtensionPresentBundle/ExtensionPresentBundle.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/FooBarBundle.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/KernelForOverrideName.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/KernelForTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Resources/BaseBundle/hide.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Resources/Bundle1Bundle/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Resources/ChildBundle/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/Resources/FooBundle/foo.txt delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/TestClient.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fixtures/TestEventDispatcher.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fragment/EsiFragmentRendererTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fragment/FragmentHandlerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fragment/HIncludeFragmentRendererTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fragment/InlineFragmentRendererTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Fragment/RoutableFragmentRendererTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/EsiTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/HttpCacheTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/HttpCacheTestCase.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/SsiTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/StoreTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/TestHttpKernel.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpCache/TestMultipleHttpKernel.php delete mode 100644 vendor/symfony/http-kernel/Tests/HttpKernelTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/KernelTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Logger.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/AbstractProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/FileProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/MemcacheProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/MemcachedProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/Mock/MemcacheMock.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/Mock/MemcachedMock.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/Mock/RedisMock.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/MongoDbProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/ProfilerTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/RedisProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/Profiler/SqliteProfilerStorageTest.php delete mode 100644 vendor/symfony/http-kernel/Tests/TestHttpKernel.php delete mode 100644 vendor/symfony/http-kernel/Tests/UriSignerTest.php delete mode 100644 vendor/symfony/process/Tests/AbstractProcessTest.php delete mode 100644 vendor/symfony/process/Tests/ExecutableFinderTest.php delete mode 100644 vendor/symfony/process/Tests/NonStopableProcess.php delete mode 100644 vendor/symfony/process/Tests/PhpExecutableFinderTest.php delete mode 100644 vendor/symfony/process/Tests/PhpProcessTest.php delete mode 100644 vendor/symfony/process/Tests/PipeStdinInStdoutStdErrStreamSelect.php delete mode 100644 vendor/symfony/process/Tests/ProcessBuilderTest.php delete mode 100644 vendor/symfony/process/Tests/ProcessFailedExceptionTest.php delete mode 100644 vendor/symfony/process/Tests/ProcessInSigchildEnvironment.php delete mode 100644 vendor/symfony/process/Tests/ProcessUtilsTest.php delete mode 100644 vendor/symfony/process/Tests/SigchildDisabledProcessTest.php delete mode 100644 vendor/symfony/process/Tests/SigchildEnabledProcessTest.php delete mode 100644 vendor/symfony/process/Tests/SignalListener.php delete mode 100644 vendor/symfony/process/Tests/SimpleProcessTest.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Factory/DiactorosFactoryTest.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Factory/HttpFoundationFactoryTest.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/Message.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/Response.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/ServerRequest.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/Stream.php delete mode 100644 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/UploadedFile.php delete mode 100644 vendor/symfony/routing/Tests/Annotation/RouteTest.php delete mode 100644 vendor/symfony/routing/Tests/CompiledRouteTest.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/AnnotatedClasses/AbstractClass.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/AnnotatedClasses/BarClass.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/AnnotatedClasses/FooClass.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/CustomXmlFileLoader.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/OtherAnnotatedClasses/VariadicClass.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/RedirectableUrlMatcher.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/annotated.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/bad_format.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/dumper/url_matcher1.apache delete mode 100644 vendor/symfony/routing/Tests/Fixtures/dumper/url_matcher1.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/dumper/url_matcher2.apache delete mode 100644 vendor/symfony/routing/Tests/Fixtures/dumper/url_matcher2.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/dumper/url_matcher3.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/empty.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/foo.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/foo1.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/incomplete.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/legacy_validpattern.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/legacy_validpattern.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/missing_id.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/missing_path.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/namespaceprefix.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonesense_resource_plus_path.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonesense_type_without_resource.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalid.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalid.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalid2.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalidkeys.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalidnode.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/nonvalidroute.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/null_values.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/special_route_name.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validpattern.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validpattern.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validpattern.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validresource.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validresource.xml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/validresource.yml delete mode 100644 vendor/symfony/routing/Tests/Fixtures/with_define_path_variable.php delete mode 100644 vendor/symfony/routing/Tests/Fixtures/withdoctype.xml delete mode 100644 vendor/symfony/routing/Tests/Generator/Dumper/PhpGeneratorDumperTest.php delete mode 100644 vendor/symfony/routing/Tests/Generator/UrlGeneratorTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/AbstractAnnotationLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/AnnotationClassLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/AnnotationDirectoryLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/AnnotationFileLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/ClosureLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/PhpFileLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/XmlFileLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Loader/YamlFileLoaderTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/Dumper/DumperCollectionTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/Dumper/DumperPrefixCollectionTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/Dumper/LegacyApacheMatcherDumperTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/Dumper/PhpMatcherDumperTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/LegacyApacheUrlMatcherTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/RedirectableUrlMatcherTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/TraceableUrlMatcherTest.php delete mode 100644 vendor/symfony/routing/Tests/Matcher/UrlMatcherTest.php delete mode 100644 vendor/symfony/routing/Tests/RequestContextTest.php delete mode 100644 vendor/symfony/routing/Tests/RouteCollectionTest.php delete mode 100644 vendor/symfony/routing/Tests/RouteCompilerTest.php delete mode 100644 vendor/symfony/routing/Tests/RouteTest.php delete mode 100644 vendor/symfony/routing/Tests/RouterTest.php delete mode 100644 vendor/symfony/serializer/Tests/Annotation/GroupsTest.php delete mode 100644 vendor/symfony/serializer/Tests/Encoder/JsonEncoderTest.php delete mode 100644 vendor/symfony/serializer/Tests/Encoder/XmlEncoderTest.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/CircularReferenceDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/DenormalizableDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/Dummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/GroupDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/GroupDummyInterface.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/GroupDummyParent.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/NormalizableTraversableDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/PropertyCircularReferenceDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/PropertySiblingHolder.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/ScalarDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/SiblingHolder.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/TraversableDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/VariadicConstructorArgsDummy.php delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/empty-mapping.yml delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/invalid-mapping.yml delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/serialization.xml delete mode 100644 vendor/symfony/serializer/Tests/Fixtures/serialization.yml delete mode 100644 vendor/symfony/serializer/Tests/Mapping/AttributeMetadataTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/ClassMetadataTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/Factory/ClassMetadataFactoryTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/Loader/AnnotationLoaderTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/Loader/XmlFileLoaderTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/Loader/YamlFileLoaderTest.php delete mode 100644 vendor/symfony/serializer/Tests/Mapping/TestClassMetadataFactory.php delete mode 100644 vendor/symfony/serializer/Tests/NameConverter/CamelCaseToSnakeCaseNameConverterTest.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/CustomNormalizerTest.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/GetSetMethodNormalizerTest.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/ObjectNormalizerTest.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/PropertyNormalizerTest.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/TestDenormalizer.php delete mode 100644 vendor/symfony/serializer/Tests/Normalizer/TestNormalizer.php delete mode 100644 vendor/symfony/serializer/Tests/SerializerTest.php delete mode 100644 vendor/symfony/translation/Tests/Catalogue/AbstractOperationTest.php delete mode 100644 vendor/symfony/translation/Tests/Catalogue/DiffOperationTest.php delete mode 100644 vendor/symfony/translation/Tests/Catalogue/MergeOperationTest.php delete mode 100644 vendor/symfony/translation/Tests/DataCollector/TranslationDataCollectorTest.php delete mode 100644 vendor/symfony/translation/Tests/DataCollectorTranslatorTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/CsvFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/FileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/IcuResFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/IniFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/JsonFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/MoFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/PhpFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/PoFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/QtFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/XliffFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/Dumper/YamlFileDumperTest.php delete mode 100644 vendor/symfony/translation/Tests/IdentityTranslatorTest.php delete mode 100644 vendor/symfony/translation/Tests/IntervalTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/CsvFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/IcuDatFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/IcuResFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/IniFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/JsonFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/LocalizedTestCase.php delete mode 100644 vendor/symfony/translation/Tests/Loader/MoFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/PhpFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/PoFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/QtFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/XliffFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/Loader/YamlFileLoaderTest.php delete mode 100644 vendor/symfony/translation/Tests/LoggingTranslatorTest.php delete mode 100644 vendor/symfony/translation/Tests/MessageCatalogueTest.php delete mode 100644 vendor/symfony/translation/Tests/MessageSelectorTest.php delete mode 100644 vendor/symfony/translation/Tests/PluralizationRulesTest.php delete mode 100644 vendor/symfony/translation/Tests/TranslatorCacheTest.php delete mode 100644 vendor/symfony/translation/Tests/TranslatorTest.php delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty-translation.mo delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty-translation.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.csv delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.ini delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.json delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.mo delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/empty.yml delete mode 100644 vendor/symfony/translation/Tests/fixtures/encoding.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/escaped-id-plurals.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/escaped-id.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/invalid-xml-resources.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/malformed.json delete mode 100644 vendor/symfony/translation/Tests/fixtures/non-valid.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/non-valid.yml delete mode 100644 vendor/symfony/translation/Tests/fixtures/plurals.mo delete mode 100644 vendor/symfony/translation/Tests/fixtures/plurals.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/resname.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/corrupted/resources.dat delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/en.res delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/en.txt delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/fr.res delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/fr.txt delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/packagelist.txt delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/dat/resources.dat delete mode 100644 vendor/symfony/translation/Tests/fixtures/resourcebundle/res/en.res delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources-clean.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.csv delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.ini delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.json delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.mo delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.php delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.po delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.ts delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/resources.yml delete mode 100644 vendor/symfony/translation/Tests/fixtures/valid.csv delete mode 100644 vendor/symfony/translation/Tests/fixtures/withdoctype.xlf delete mode 100644 vendor/symfony/translation/Tests/fixtures/withnote.xlf delete mode 100644 vendor/symfony/validator/Tests/ConstraintTest.php delete mode 100644 vendor/symfony/validator/Tests/ConstraintViolationListTest.php delete mode 100644 vendor/symfony/validator/Tests/ConstraintViolationTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/AbstractComparisonValidatorTestCase.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/AbstractConstraintValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/AllTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/AllValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/BlankValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CallbackValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CardSchemeValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/ChoiceValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CollectionTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CollectionValidatorArrayObjectTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CollectionValidatorArrayTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CollectionValidatorCustomArrayObjectTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CollectionValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CompositeTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CountValidatorArrayTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CountValidatorCountableTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CountValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CountryValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/CurrencyValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/DateTimeValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/DateValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/EmailValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/EqualToValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/ExpressionValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/FileTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/FileValidatorObjectTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/FileValidatorPathTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/FileValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/Fixtures/foo delete mode 100644 vendor/symfony/validator/Tests/Constraints/Fixtures/test.gif delete mode 100644 vendor/symfony/validator/Tests/Constraints/Fixtures/test_4by3.gif delete mode 100644 vendor/symfony/validator/Tests/Constraints/Fixtures/test_landscape.gif delete mode 100644 vendor/symfony/validator/Tests/Constraints/Fixtures/test_portrait.gif delete mode 100644 vendor/symfony/validator/Tests/Constraints/GreaterThanOrEqualValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/GreaterThanValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/GroupSequenceTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IbanValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IdenticalToValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/ImageValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IpValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IsFalseValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IsNullValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IsTrueValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IsbnValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/IssnValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LanguageValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LengthValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LessThanOrEqualValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LessThanValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LocaleValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/LuhnValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/NotBlankValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/NotEqualToValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/NotIdenticalToValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/NotNullValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/RangeValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/RegexTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/RegexValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/TimeValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/TypeValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/UrlValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/UuidValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Constraints/ValidTest.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/CallbackClass.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ClassConstraint.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintA.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintAValidator.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintB.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintC.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintWithValue.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/ConstraintWithValueAsDefault.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/Countable.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/CustomArrayObject.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/Entity.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/EntityInterface.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/EntityParent.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/FailingConstraint.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/FailingConstraintValidator.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/FakeClassMetadata.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/FakeMetadataFactory.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/FilesLoader.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/GroupSequenceProviderEntity.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/InvalidConstraint.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/InvalidConstraintValidator.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/LegacyClassMetadata.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/PropertyConstraint.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/Reference.php delete mode 100644 vendor/symfony/validator/Tests/Fixtures/StubGlobalExecutionContext.php delete mode 100644 vendor/symfony/validator/Tests/LegacyExecutionContextTest.php delete mode 100644 vendor/symfony/validator/Tests/LegacyValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Cache/DoctrineCacheTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Cache/LegacyApcCacheTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/ClassMetadataTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Factory/BlackHoleMetadataFactoryTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Factory/LazyLoadingMetadataFactoryTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/GetterMetadataTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/LegacyElementMetadataTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/AbstractStaticMethodLoader.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/AnnotationLoaderTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/FilesLoaderTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/LoaderChainTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/StaticMethodLoaderTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/XmlFileLoaderTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/YamlFileLoaderTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/bad-format.yml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/constraint-mapping-non-strings.xml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/constraint-mapping.xml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/constraint-mapping.yml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/empty-mapping.yml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/nonvalid-mapping.yml delete mode 100644 vendor/symfony/validator/Tests/Mapping/Loader/withdoctype.xml delete mode 100644 vendor/symfony/validator/Tests/Mapping/MemberMetadataTest.php delete mode 100644 vendor/symfony/validator/Tests/Mapping/PropertyMetadataTest.php delete mode 100644 vendor/symfony/validator/Tests/Util/PropertyPathTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/Abstract2Dot5ApiTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/AbstractLegacyApiTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/AbstractValidatorTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/LegacyValidator2Dot5ApiTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/LegacyValidatorLegacyApiTest.php delete mode 100644 vendor/symfony/validator/Tests/Validator/RecursiveValidator2Dot5ApiTest.php delete mode 100644 vendor/symfony/validator/Tests/ValidatorBuilderTest.php delete mode 100644 vendor/symfony/yaml/Tests/DumperTest.php delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsAnchorAlias.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsBasicTests.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsBlockMapping.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsDocumentSeparator.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsErrorTests.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsFlowCollections.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsFoldedScalars.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsNullsAndEmpties.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsSpecificationExamples.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/YtsTypeTransfers.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/embededPhp.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/escapedCharacters.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/index.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfComments.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfCompact.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfMergeKey.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfObjects.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfQuotes.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/sfTests.yml delete mode 100644 vendor/symfony/yaml/Tests/Fixtures/unindentedCollections.yml delete mode 100644 vendor/symfony/yaml/Tests/InlineTest.php delete mode 100644 vendor/symfony/yaml/Tests/ParseExceptionTest.php delete mode 100644 vendor/symfony/yaml/Tests/ParserTest.php delete mode 100644 vendor/symfony/yaml/Tests/YamlTest.php delete mode 100644 vendor/twig/twig/doc/advanced.rst delete mode 100644 vendor/twig/twig/doc/advanced_legacy.rst delete mode 100644 vendor/twig/twig/doc/api.rst delete mode 100644 vendor/twig/twig/doc/coding_standards.rst delete mode 100644 vendor/twig/twig/doc/deprecated.rst delete mode 100644 vendor/twig/twig/doc/filters/abs.rst delete mode 100644 vendor/twig/twig/doc/filters/batch.rst delete mode 100644 vendor/twig/twig/doc/filters/capitalize.rst delete mode 100644 vendor/twig/twig/doc/filters/convert_encoding.rst delete mode 100644 vendor/twig/twig/doc/filters/date.rst delete mode 100644 vendor/twig/twig/doc/filters/date_modify.rst delete mode 100644 vendor/twig/twig/doc/filters/default.rst delete mode 100644 vendor/twig/twig/doc/filters/escape.rst delete mode 100644 vendor/twig/twig/doc/filters/first.rst delete mode 100644 vendor/twig/twig/doc/filters/format.rst delete mode 100644 vendor/twig/twig/doc/filters/index.rst delete mode 100644 vendor/twig/twig/doc/filters/join.rst delete mode 100644 vendor/twig/twig/doc/filters/json_encode.rst delete mode 100644 vendor/twig/twig/doc/filters/keys.rst delete mode 100644 vendor/twig/twig/doc/filters/last.rst delete mode 100644 vendor/twig/twig/doc/filters/length.rst delete mode 100644 vendor/twig/twig/doc/filters/lower.rst delete mode 100644 vendor/twig/twig/doc/filters/merge.rst delete mode 100644 vendor/twig/twig/doc/filters/nl2br.rst delete mode 100644 vendor/twig/twig/doc/filters/number_format.rst delete mode 100644 vendor/twig/twig/doc/filters/raw.rst delete mode 100644 vendor/twig/twig/doc/filters/replace.rst delete mode 100644 vendor/twig/twig/doc/filters/reverse.rst delete mode 100644 vendor/twig/twig/doc/filters/round.rst delete mode 100644 vendor/twig/twig/doc/filters/slice.rst delete mode 100644 vendor/twig/twig/doc/filters/sort.rst delete mode 100644 vendor/twig/twig/doc/filters/split.rst delete mode 100644 vendor/twig/twig/doc/filters/striptags.rst delete mode 100644 vendor/twig/twig/doc/filters/title.rst delete mode 100644 vendor/twig/twig/doc/filters/trim.rst delete mode 100644 vendor/twig/twig/doc/filters/upper.rst delete mode 100644 vendor/twig/twig/doc/filters/url_encode.rst delete mode 100644 vendor/twig/twig/doc/functions/attribute.rst delete mode 100644 vendor/twig/twig/doc/functions/block.rst delete mode 100644 vendor/twig/twig/doc/functions/constant.rst delete mode 100644 vendor/twig/twig/doc/functions/cycle.rst delete mode 100644 vendor/twig/twig/doc/functions/date.rst delete mode 100644 vendor/twig/twig/doc/functions/dump.rst delete mode 100644 vendor/twig/twig/doc/functions/include.rst delete mode 100644 vendor/twig/twig/doc/functions/index.rst delete mode 100644 vendor/twig/twig/doc/functions/max.rst delete mode 100644 vendor/twig/twig/doc/functions/min.rst delete mode 100644 vendor/twig/twig/doc/functions/parent.rst delete mode 100644 vendor/twig/twig/doc/functions/random.rst delete mode 100644 vendor/twig/twig/doc/functions/range.rst delete mode 100644 vendor/twig/twig/doc/functions/source.rst delete mode 100644 vendor/twig/twig/doc/functions/template_from_string.rst delete mode 100644 vendor/twig/twig/doc/index.rst delete mode 100644 vendor/twig/twig/doc/installation.rst delete mode 100644 vendor/twig/twig/doc/internals.rst delete mode 100644 vendor/twig/twig/doc/intro.rst delete mode 100644 vendor/twig/twig/doc/recipes.rst delete mode 100644 vendor/twig/twig/doc/tags/autoescape.rst delete mode 100644 vendor/twig/twig/doc/tags/block.rst delete mode 100644 vendor/twig/twig/doc/tags/do.rst delete mode 100644 vendor/twig/twig/doc/tags/embed.rst delete mode 100644 vendor/twig/twig/doc/tags/extends.rst delete mode 100644 vendor/twig/twig/doc/tags/filter.rst delete mode 100644 vendor/twig/twig/doc/tags/flush.rst delete mode 100644 vendor/twig/twig/doc/tags/for.rst delete mode 100644 vendor/twig/twig/doc/tags/from.rst delete mode 100644 vendor/twig/twig/doc/tags/if.rst delete mode 100644 vendor/twig/twig/doc/tags/import.rst delete mode 100644 vendor/twig/twig/doc/tags/include.rst delete mode 100644 vendor/twig/twig/doc/tags/index.rst delete mode 100644 vendor/twig/twig/doc/tags/macro.rst delete mode 100644 vendor/twig/twig/doc/tags/sandbox.rst delete mode 100644 vendor/twig/twig/doc/tags/set.rst delete mode 100644 vendor/twig/twig/doc/tags/spaceless.rst delete mode 100644 vendor/twig/twig/doc/tags/use.rst delete mode 100644 vendor/twig/twig/doc/tags/verbatim.rst delete mode 100644 vendor/twig/twig/doc/templates.rst delete mode 100644 vendor/twig/twig/doc/tests/constant.rst delete mode 100644 vendor/twig/twig/doc/tests/defined.rst delete mode 100644 vendor/twig/twig/doc/tests/divisibleby.rst delete mode 100644 vendor/twig/twig/doc/tests/empty.rst delete mode 100644 vendor/twig/twig/doc/tests/even.rst delete mode 100644 vendor/twig/twig/doc/tests/index.rst delete mode 100644 vendor/twig/twig/doc/tests/iterable.rst delete mode 100644 vendor/twig/twig/doc/tests/null.rst delete mode 100644 vendor/twig/twig/doc/tests/odd.rst delete mode 100644 vendor/twig/twig/doc/tests/sameas.rst delete mode 100644 vendor/twig/twig/ext/twig/.gitignore delete mode 100644 vendor/twig/twig/ext/twig/config.m4 delete mode 100644 vendor/twig/twig/ext/twig/config.w32 delete mode 100644 vendor/twig/twig/ext/twig/php_twig.h delete mode 100644 vendor/twig/twig/ext/twig/twig.c delete mode 100644 vendor/twig/twig/test/Twig/Tests/AutoloaderTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/CompilerTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/EnvironmentTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/ErrorTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/ExpressionParserTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Extension/CoreTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Extension/SandboxTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/FileCachingTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/FileExtensionEscapingStrategyTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/autoescape/filename.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/errors/base.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/errors/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable_again.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_undefined_variable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_unknown_argument.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_tag_with_undefined_variable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/syntax_error_in_reused_template.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/unclosed_tag.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_parent.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_template_in_child_template.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_trait.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array_call.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/binary.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/bitwise.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/comparison.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/divisibleby.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/dotdot.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ends_with.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/grouping.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/literals.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/magic_call.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/matches.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/method_call.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/negative_numbers.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/operators_as_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/postfix.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/sameas.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/starts_with.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/strings.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_noelse.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_nothen.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/two_word_operators_as_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_macro_arguments.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_precedence.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/abs.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_float.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_empty_fill.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_exact_elements.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_fill.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_keys.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_zero_elements.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/convert_encoding.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format_interval.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_immutable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_interval.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_modify.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_namedargs.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/default.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/dynamic_filter.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_html_attr.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_non_supported_charset.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/first.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/force_escape.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/format.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/join.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/json_encode.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/last.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length_utf8.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/merge.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/nl2br.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format_default.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace_invalid_arg.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/reverse.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/round.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/slice.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/sort.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/special_chars.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split_utf8.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/trim.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode_deprecated.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/attribute.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/block.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/constant.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/cycle.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date_namedargs.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump_array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dynamic_function.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/assignment.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/autoescaping.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/expression.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/ignore_missing.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing_nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling_ignore_missing.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/template_instance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/templates_as_array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_context.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/max.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/min.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/range.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/recursive_block_with_inheritance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/source.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/special_chars.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/functions/template_from_string.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/default_values.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/nested_calls.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/reserved_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/simple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs_argument.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/macros/with_filters.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/combined_debug_info.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/empty_token.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/issue_1143.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/multi_word_tests.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/simple_xml_element.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/regression/strings_like_numbers.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/blocks.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/double_escaping.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/functions.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/literal.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/objects.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/raw.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.legacy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/type.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters_arguments.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_pre_escape_filters.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_preserves_safety_filters.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/block_unique_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/special_chars.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/error_line.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/multiple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/with_extends.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/json_encode.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/multiple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_for_tag.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_if_tag.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/condition.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/context.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/else.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/inner_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys_and_values.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context_local.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined_cond.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/nested_else.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects_countable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/recursive.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/values.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/from.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/expression.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/expression.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/ignore_missing.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing_nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/only.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/template_instance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/templates_as_array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/with_variables.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr2.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/conditional.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/dynamic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/empty.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_empty_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_null_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple_dynamic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks_parent_only.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_inheritance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_change.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_in_a_block.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_isolation.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_nested.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends_but_traits.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/template_instance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/use.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/endmacro_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/external.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from_with_reserved_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/global.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/import_with_reserved_nam.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/reserved_name.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/self_import.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/special_chars.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/super_globals.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/basic.legacy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/mixed_usage_with_raw.legacy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/whitespace_control.legacy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid1.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid2.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/simple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture-empty.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/expression.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/spaceless/simple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/special_chars.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/trim_block.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/aliases.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep_empty.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance2.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple_aliases.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block2.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block3.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/basic.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/mixed_usage_with_raw.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/whitespace_control.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/array.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/constant.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/defined.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/empty.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/even.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in_with_objects.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/iterable.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/Fixtures/tests/odd.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/IntegrationTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/LegacyFixtures/test.legacy.test delete mode 100644 vendor/twig/twig/test/Twig/Tests/LegacyIntegrationTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/LexerTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/ArrayTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/FilesystemTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_empty_parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_nonexistent_parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_null_parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_valid_parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/spare_parent.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_bis/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_final/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_quater/named_absolute.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_ter/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_bis/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_final/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_ter/index.html delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme1/blocks.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme2/blocks.html.twig delete mode 100644 vendor/twig/twig/test/Twig/Tests/NativeExtensionTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/AutoEscapeTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/BlockReferenceTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/BlockTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/DoTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/ArrayTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/AssignNameTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AddTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AndTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ConcatTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/DivTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/FloorDivTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ModTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/MulTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/OrTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/SubTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/CallTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/ConditionalTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/ConstantTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/FilterTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/FunctionTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/GetAttrTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/NameTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FilterInclude.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FunctionInclude.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/TestInclude.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/ParentTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/TestTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NegTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NotTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/PosTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/ForTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/IfTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/ImportTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/IncludeTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/MacroTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/ModuleTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/PrintTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/SandboxTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/SandboxedPrintTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/SetTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/SpacelessTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Node/TextTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/NodeVisitor/OptimizerTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/ParserTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/AbstractTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/BlackfireTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/HtmlTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/TextTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/Profiler/ProfileTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/TemplateTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/TokenStreamTest.php delete mode 100644 vendor/twig/twig/test/Twig/Tests/escapingTest.php delete mode 100644 vendor/twig/twig/test/bootstrap.php diff --git a/.eslintrc b/.eslintrc index b624e42be..0ebfd5a86 100644 --- a/.eslintrc +++ b/.eslintrc @@ -71,6 +71,7 @@ "object-curly-spacing": [2, "never"], "one-var": [2, "never"], "quote-props": [2, "consistent-as-needed"], + "quotes": [2, "single", "avoid-escape"], "semi": [2, "always"], "semi-spacing": [2, {"before": false, "after": true}], "space-after-keywords": [2, "always"], diff --git a/composer.json b/composer.json index 901e0fb05..04e1806ee 100644 --- a/composer.json +++ b/composer.json @@ -37,6 +37,8 @@ }, "scripts": { "pre-autoload-dump": "Drupal\\Core\\Composer\\Composer::preAutoloadDump", - "post-autoload-dump": "Drupal\\Core\\Composer\\Composer::ensureHtaccess" + "post-autoload-dump": "Drupal\\Core\\Composer\\Composer::ensureHtaccess", + "post-package-install": "Drupal\\Core\\Composer\\Composer::vendorTestCodeCleanup", + "post-package-update": "Drupal\\Core\\Composer\\Composer::vendorTestCodeCleanup" } } diff --git a/core/INSTALL.txt b/core/INSTALL.txt index a4b88edbc..6a0bb9a0a 100644 --- a/core/INSTALL.txt +++ b/core/INSTALL.txt @@ -26,8 +26,8 @@ Drupal requires: compatible drop-in replacement for MySQL. - Percona Server 5.5.8 (or greater) (http://www.percona.com/). Percona Server is a backwards-compatible replacement for MySQL. - - PostgreSQL 8.3 (or greater) (http://www.postgresql.org/). - - SQLite 3.4.2 (or greater) (http://www.sqlite.org/). + - PostgreSQL 9.1.2 (or greater) (http://www.postgresql.org/). + - SQLite 3.6.8 (or greater) (http://www.sqlite.org/). For more detailed information about Drupal requirements, including a list of PHP extensions and configurations that are required, see "System requirements" diff --git a/core/UPGRADE.txt b/core/UPGRADE.txt index 5394a4eae..cde885fb9 100644 --- a/core/UPGRADE.txt +++ b/core/UPGRADE.txt @@ -1,17 +1,24 @@ INTRODUCTION ------------ -This document describes how to: - - * Update your Drupal site from one minor 8.x version to another minor 8.x - version; for example, from 8.8 to 8.9, or from 8.6 to 8.10. - - * Migrate your Drupal site to version 8.x. +This document describes how to update your Drupal site between 8.x.x minor and +patch versions; for example, from 8.1.2 to 8.1.3, or from 8.3.5 to 8.4.0. + +To upgrade from a previous major version (for example, Drupal 6 or 7), the +process involves importing site configuration and content from your old site +into a new Drupal 8 site. The tools and process are currently experimental, +rather than being fully supported, so be sure to test in a development +environment. You will need to use the contributed Drupal Upgrade module +(https://www.drupal.org/project/migrate_upgrade), as well as the core Migrate +and Migrate Drupal modules. See https://www.drupal.org/upgrade/migrate for +details, and https://www.drupal.org/node/2167633 for known issues. First steps and definitions: - * If you are upgrading to Drupal version x.y, then x is known as the major - version number, and y is known as the minor version number. The download - file will be named drupal-x.y.tar.gz (or drupal-x.y.zip). + * If you are upgrading to Drupal version x.y.z, then x is known as the major + version number, y is known as the minor version number, and z is known as + the patch version number. The download file will be named + drupal-x.y.z.tar.gz (or drupal-x.y.z.zip). Previous Drupal versions used + only x.y (MAJOR.MINOR) to designate their versions. * All directories mentioned in this document are relative to the directory of your Drupal installation. @@ -46,9 +53,9 @@ If you encounter errors during this process, More in-depth information on upgrading can be found at https://www.drupal.org/upgrade -MINOR VERSION UPDATES ---------------------- -To update from one minor 8.x version of Drupal to any later 8.x version, after +MINOR AND PATCH VERSION UPDATES +------------------------------- +To update from one 8.x.x version of Drupal to any later 8.x.x version, after following the instructions in the INTRODUCTION section at the top of this file: 1. Log in as a user with the permission "Administer software updates". @@ -87,20 +94,20 @@ following the instructions in the INTRODUCTION section at the top of this file: this page you can scroll down or use the filter to find your version and its release notes. -4. Download the latest Drupal 8.x release from https://www.drupal.org to a +4. Download the latest Drupal 8.x.x release from https://www.drupal.org to a directory outside of your web root. Extract the archive and copy the files into your Drupal directory. On a typical Unix/Linux command line, use the following commands to download and extract: - wget https://www.drupal.org/files/projects/drupal-x.y.tar.gz - tar -zxvf drupal-x.y.tar.gz + wget https://www.drupal.org/files/projects/drupal-x.y.z.tar.gz + tar -zxvf drupal-x.y.z.tar.gz - This creates a new directory drupal-x.y/ containing all Drupal files and + This creates a new directory drupal-x.y.z/ containing all Drupal files and directories. Copy the files into your Drupal installation directory: - cp -R drupal-x.y/* drupal-x.y/.htaccess /path/to/your/installation + cp -R drupal-x.y.z/* drupal-x.y.z/.htaccess /path/to/your/installation If you do not have command line access to your server, download the archive from https://www.drupal.org using your web browser, extract it, and then use @@ -135,10 +142,3 @@ following the instructions in the INTRODUCTION section at the top of this file: Disable the "Put site into maintenance mode" checkbox and save the configuration. -MAJOR VERSION MIGRATION ------------------------ -Upgrading from a prior major version of Drupal to Drupal 8.x is not possible. -The process now requires a migration to a Drupal 8.x site, using the Migrate -module in Drupal core. - -Note that migration support in Drupal 8 is currently only partially implemented. diff --git a/core/assets/vendor/modernizr/modernizr.min.js b/core/assets/vendor/modernizr/modernizr.min.js index 619035afb..6a71a8406 100644 --- a/core/assets/vendor/modernizr/modernizr.min.js +++ b/core/assets/vendor/modernizr/modernizr.min.js @@ -1,4 +1,3 @@ -/* Modernizr 2.8.3 (Custom Build) | MIT & BSD - * Build: http://modernizr.com/download/#-inputtypes-touch-cssclasses-addtest-teststyles-prefixes-elem_details - */ -;window.Modernizr=function(a,b,c){function x(a){j.cssText=a}function y(a,b){return x(n.join(a+";")+(b||""))}function z(a,b){return typeof a===b}function A(a,b){return!!~(""+a).indexOf(b)}function B(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:z(f,"function")?f.bind(d||b):f}return!1}function C(){e.inputtypes=function(a){for(var d=0,e,f,h,i=a.length;d',a,""].join(""),l.id=h,(m?l:n).innerHTML+=f,n.appendChild(l),m||(n.style.background="",n.style.overflow="hidden",k=g.style.overflow,g.style.overflow="hidden",g.appendChild(n)),i=c(l,a),m?l.parentNode.removeChild(l):(n.parentNode.removeChild(n),g.style.overflow=k),!!i},v={}.hasOwnProperty,w;!z(v,"undefined")&&!z(v.call,"undefined")?w=function(a,b){return v.call(a,b)}:w=function(a,b){return b in a&&z(a.constructor.prototype[b],"undefined")},Function.prototype.bind||(Function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new TypeError;var d=s.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(s.call(arguments)));return Object(g)===g?g:f}return c.apply(b,d.concat(s.call(arguments)))};return e}),o.touch=function(){var c;return"ontouchstart"in a||a.DocumentTouch&&b instanceof DocumentTouch?c=!0:u(["@media (",n.join("touch-enabled),("),h,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(a){c=a.offsetTop===9}),c};for(var D in o)w(o,D)&&(t=D.toLowerCase(),e[t]=o[D](),r.push((e[t]?"":"no-")+t));return e.input||C(),e.addTest=function(a,b){if(typeof a=="object")for(var d in a)w(a,d)&&e.addTest(d,a[d]);else{a=a.toLowerCase();if(e[a]!==c)return e;b=typeof b=="function"?b():b,typeof f!="undefined"&&f&&(g.className+=" "+(b?"":"no-")+a),e[a]=b}return e},x(""),i=k=null,e._version=d,e._prefixes=n,e.testStyles=u,g.className=g.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(f?" js "+r.join(" "):""),e}(this,this.document),Modernizr.addTest("details",function(){var a=document,b=a.createElement("details"),c,d,e;return"open"in b?(d=a.body||function(){var b=a.documentElement;return c=!0,b.insertBefore(a.createElement("body"),b.firstElementChild||b.firstChild)}(),b.innerHTML="ab",b.style.display="block",d.appendChild(b),e=b.offsetHeight,b.open=!0,e=e!=b.offsetHeight,d.removeChild(b),c&&d.parentNode.removeChild(d),e):!1}); \ No newline at end of file +/*! modernizr 3.1.0 (Custom Build) | MIT * + * http://modernizr.com/download/?-details-inputtypes-touchevents-addtest-prefixes-teststyles !*/ +!function(e,t,n){function o(e,t){return typeof e===t}function i(){var e,t,n,i,s,a,r;for(var l in u){if(e=[],t=u[l],t.name&&(e.push(t.name.toLowerCase()),t.options&&t.options.aliases&&t.options.aliases.length))for(n=0;nl;l++)g.setAttribute("type",o=e[l]),s="text"!==g.type&&"style"in g,s&&(g.value=r,g.style.cssText="position:absolute;visibility:hidden;",/^range$/.test(o)&&g.style.WebkitAppearance!==n?(p.appendChild(g),i=t.defaultView,s=i.getComputedStyle&&"textfield"!==i.getComputedStyle(g,null).WebkitAppearance&&0!==g.offsetHeight,p.removeChild(g)):/^(search|tel)$/.test(o)||(s=/^(url|email|number)$/.test(o)?g.checkValidity&&g.checkValidity()===!1:g.value!=r)),w[e[l]]=!!s;return w}(_),Modernizr.addTest("touchevents",function(){var n;if("ontouchstart"in e||e.DocumentTouch&&t instanceof DocumentTouch)n=!0;else{var o=["@media (",m.join("touch-enabled),("),"heartz",")","{#modernizr{top:9px;position:absolute}}"].join("");y(o,function(e){n=9===e.offsetTop})}return n}),Modernizr.addTest("details",function(){var e,t=r("details");return"open"in t?(y("#modernizr details{display:block}",function(n){n.appendChild(t),t.innerHTML="ab",e=t.offsetHeight,t.open=!0,e=e!=t.offsetHeight}),e):!1}),i(),s(c),delete d.addTest,delete d.addAsyncTest;for(var b=0;b array( '#prefix' => '', 'title' => array( - '#markup' => t($element['#title']), + '#markup' => $element['#title'], ), '#suffix' => '', ), diff --git a/core/includes/update.inc b/core/includes/update.inc index 24eeddfd6..68401a9de 100644 --- a/core/includes/update.inc +++ b/core/includes/update.inc @@ -9,7 +9,6 @@ */ use Drupal\Component\Graph\Graph; -use Drupal\Component\Utility\Html; use Drupal\Core\Utility\Error; /** diff --git a/core/includes/utility.inc b/core/includes/utility.inc index 4918719a5..2bb650776 100644 --- a/core/includes/utility.inc +++ b/core/includes/utility.inc @@ -5,7 +5,6 @@ * Miscellaneous functions. */ -use Drupal\Component\Utility\Variable; use Drupal\Core\PhpStorage\PhpStorageFactory; use Drupal\Core\Cache\Cache; use Drupal\Core\DrupalKernel; diff --git a/core/lib/Drupal.php b/core/lib/Drupal.php index 33e930c13..564aec247 100644 --- a/core/lib/Drupal.php +++ b/core/lib/Drupal.php @@ -81,7 +81,7 @@ class Drupal { /** * The current system version. */ - const VERSION = '8.0.0-rc1'; + const VERSION = '8.0.0-rc2'; /** * Core API compatibility. diff --git a/core/lib/Drupal/Component/Datetime/DateTimePlus.php b/core/lib/Drupal/Component/Datetime/DateTimePlus.php index 114d68cea..4540b3b61 100644 --- a/core/lib/Drupal/Component/Datetime/DateTimePlus.php +++ b/core/lib/Drupal/Component/Datetime/DateTimePlus.php @@ -203,7 +203,7 @@ public static function createFromFormat($format, $time, $timezone = NULL, $setti $datetimeplus = new static('', $timezone, $settings); $date = \DateTime::createFromFormat($format, $time, $datetimeplus->getTimezone()); - if (!$date instanceOf \DateTime) { + if (!$date instanceof \DateTime) { throw new \Exception('The date cannot be created from a format.'); } else { @@ -212,10 +212,10 @@ public static function createFromFormat($format, $time, $timezone = NULL, $setti // re-creating the date/time formatted string and comparing it to the input. For // instance, an input value of '11' using a format of Y (4 digits) gets // created as '0011' instead of '2011'. - if ($date instanceOf DateTimePlus) { + if ($date instanceof DateTimePlus) { $test_time = $date->format($format, $settings); } - elseif ($date instanceOf \DateTime) { + elseif ($date instanceof \DateTime) { $test_time = $date->format($format); } $datetimeplus->setTimestamp($date->getTimestamp()); @@ -345,7 +345,7 @@ protected function prepareTime($time) { */ protected function prepareTimezone($timezone) { // If the input timezone is a valid timezone object, use it. - if ($timezone instanceOf \DateTimezone) { + if ($timezone instanceof \DateTimezone) { $timezone_adjusted = $timezone; } @@ -356,7 +356,7 @@ protected function prepareTimezone($timezone) { // Default to the system timezone when not explicitly provided. // If the system timezone is missing, use 'UTC'. - if (empty($timezone_adjusted) || !$timezone_adjusted instanceOf \DateTimezone) { + if (empty($timezone_adjusted) || !$timezone_adjusted instanceof \DateTimezone) { $system_timezone = date_default_timezone_get(); $timezone_name = !empty($system_timezone) ? $system_timezone : 'UTC'; $timezone_adjusted = new \DateTimeZone($timezone_name); diff --git a/core/lib/Drupal/Component/Diff/Engine/DiffEngine.php b/core/lib/Drupal/Component/Diff/Engine/DiffEngine.php index 387c40119..805f9c7fd 100644 --- a/core/lib/Drupal/Component/Diff/Engine/DiffEngine.php +++ b/core/lib/Drupal/Component/Diff/Engine/DiffEngine.php @@ -19,7 +19,7 @@ * More ideas are taken from: * http://www.ics.uci.edu/~eppstein/161/960229.html * - * Some ideas are (and a bit of code) are from from analyze.c, from GNU + * Some ideas (and a bit of code) are from analyze.c, from GNU * diffutils-2.7, which can be found at: * ftp://gnudist.gnu.org/pub/gnu/diffutils/diffutils-2.7.tar.gz * diff --git a/core/lib/Drupal/Component/Gettext/PoMemoryWriter.php b/core/lib/Drupal/Component/Gettext/PoMemoryWriter.php index d44f18d69..3026c3220 100644 --- a/core/lib/Drupal/Component/Gettext/PoMemoryWriter.php +++ b/core/lib/Drupal/Component/Gettext/PoMemoryWriter.php @@ -7,10 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoWriterInterface; -use Drupal\Component\Gettext\PoHeader; -use Drupal\Component\Gettext\PoItem; - /** * Defines a Gettext PO memory writer, to be used by the installer. */ diff --git a/core/lib/Drupal/Component/Gettext/PoMetadataInterface.php b/core/lib/Drupal/Component/Gettext/PoMetadataInterface.php index 5801daa2d..f3b54db8f 100644 --- a/core/lib/Drupal/Component/Gettext/PoMetadataInterface.php +++ b/core/lib/Drupal/Component/Gettext/PoMetadataInterface.php @@ -7,8 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoHeader; - /** * Methods required for both reader and writer implementations. * diff --git a/core/lib/Drupal/Component/Gettext/PoReaderInterface.php b/core/lib/Drupal/Component/Gettext/PoReaderInterface.php index 49b73dffd..c9beba1a7 100644 --- a/core/lib/Drupal/Component/Gettext/PoReaderInterface.php +++ b/core/lib/Drupal/Component/Gettext/PoReaderInterface.php @@ -7,8 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoMetadataInterface; - /** * Shared interface definition for all Gettext PO Readers. */ diff --git a/core/lib/Drupal/Component/Gettext/PoStreamReader.php b/core/lib/Drupal/Component/Gettext/PoStreamReader.php index 0cf52ad05..9e58d8056 100644 --- a/core/lib/Drupal/Component/Gettext/PoStreamReader.php +++ b/core/lib/Drupal/Component/Gettext/PoStreamReader.php @@ -7,9 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoReaderInterface; -use Drupal\Component\Gettext\PoStreamInterface; -use Drupal\Component\Gettext\PoHeader; use Drupal\Component\Utility\SafeMarkup; /** diff --git a/core/lib/Drupal/Component/Gettext/PoStreamWriter.php b/core/lib/Drupal/Component/Gettext/PoStreamWriter.php index 848171b94..e804a2ea4 100644 --- a/core/lib/Drupal/Component/Gettext/PoStreamWriter.php +++ b/core/lib/Drupal/Component/Gettext/PoStreamWriter.php @@ -7,12 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoHeader; -use Drupal\Component\Gettext\PoItem; -use Drupal\Component\Gettext\PoReaderInterface; -use Drupal\Component\Gettext\PoWriterInterface; -use Drupal\Component\Gettext\PoStreamInterface; - /** * Defines a Gettext PO stream writer. */ diff --git a/core/lib/Drupal/Component/Gettext/PoWriterInterface.php b/core/lib/Drupal/Component/Gettext/PoWriterInterface.php index 18206d9ea..fa4ece41d 100644 --- a/core/lib/Drupal/Component/Gettext/PoWriterInterface.php +++ b/core/lib/Drupal/Component/Gettext/PoWriterInterface.php @@ -7,9 +7,6 @@ namespace Drupal\Component\Gettext; -use Drupal\Component\Gettext\PoMetadataInterface; -use Drupal\Component\Gettext\PoItem; - /** * Shared interface definition for all Gettext PO Writers. */ diff --git a/core/lib/Drupal/Component/HttpFoundation/SecuredRedirectResponse.php b/core/lib/Drupal/Component/HttpFoundation/SecuredRedirectResponse.php index 77c978c7d..5a7d4bbd6 100644 --- a/core/lib/Drupal/Component/HttpFoundation/SecuredRedirectResponse.php +++ b/core/lib/Drupal/Component/HttpFoundation/SecuredRedirectResponse.php @@ -33,11 +33,21 @@ abstract class SecuredRedirectResponse extends RedirectResponse { */ public static function createFromRedirectResponse(RedirectResponse $response) { $safe_response = new static($response->getTargetUrl(), $response->getStatusCode(), $response->headers->allPreserveCase()); - $safe_response->setProtocolVersion($response->getProtocolVersion()); - $safe_response->setCharset($response->getCharset()); + $safe_response->fromResponse($response); return $safe_response; } + /** + * Copies over the values from the given response. + * + * @param \Symfony\Component\HttpFoundation\RedirectResponse $response + * The redirect reponse object. + */ + protected function fromResponse(RedirectResponse $response) { + $this->setProtocolVersion($response->getProtocolVersion()); + $this->setCharset($response->getCharset()); + } + /** * {@inheritdoc} */ diff --git a/core/lib/Drupal/Component/Plugin/Exception/InvalidDecoratedMethod.php b/core/lib/Drupal/Component/Plugin/Exception/InvalidDecoratedMethod.php index 57fd8359e..24427bf1d 100644 --- a/core/lib/Drupal/Component/Plugin/Exception/InvalidDecoratedMethod.php +++ b/core/lib/Drupal/Component/Plugin/Exception/InvalidDecoratedMethod.php @@ -6,7 +6,6 @@ namespace Drupal\Component\Plugin\Exception; -use Drupal\Component\Plugin\Exception\ExceptionInterface; use \BadMethodCallException; /** diff --git a/core/lib/Drupal/Component/Utility/SafeMarkup.php b/core/lib/Drupal/Component/Utility/SafeMarkup.php index 8d6387c11..cd24daa71 100644 --- a/core/lib/Drupal/Component/Utility/SafeMarkup.php +++ b/core/lib/Drupal/Component/Utility/SafeMarkup.php @@ -41,7 +41,7 @@ class SafeMarkup { * \Drupal\Component\Render\MarkupInterface. */ public static function isSafe($string, $strategy = 'html') { - return $string instanceOf MarkupInterface; + return $string instanceof MarkupInterface; } /** diff --git a/core/lib/Drupal/Core/Action/ConfigurableActionBase.php b/core/lib/Drupal/Core/Action/ConfigurableActionBase.php index e0368807f..8e3297299 100644 --- a/core/lib/Drupal/Core/Action/ConfigurableActionBase.php +++ b/core/lib/Drupal/Core/Action/ConfigurableActionBase.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Action; use Drupal\Component\Plugin\ConfigurablePluginInterface; -use Drupal\Core\Action\ActionBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\PluginFormInterface; diff --git a/core/lib/Drupal/Core/Ajax/AddCssCommand.php b/core/lib/Drupal/Core/Ajax/AddCssCommand.php index c5a0208a1..f7d1677f2 100644 --- a/core/lib/Drupal/Core/Ajax/AddCssCommand.php +++ b/core/lib/Drupal/Core/Ajax/AddCssCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * An AJAX command for adding css to the page via ajax. * diff --git a/core/lib/Drupal/Core/Ajax/AfterCommand.php b/core/lib/Drupal/Core/Ajax/AfterCommand.php index ae270302d..05cf95cf4 100644 --- a/core/lib/Drupal/Core/Ajax/AfterCommand.php +++ b/core/lib/Drupal/Core/Ajax/AfterCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * An AJAX command for calling the jQuery after() method. * diff --git a/core/lib/Drupal/Core/Ajax/AjaxResponse.php b/core/lib/Drupal/Core/Ajax/AjaxResponse.php index c2e8967e2..67723418f 100644 --- a/core/lib/Drupal/Core/Ajax/AjaxResponse.php +++ b/core/lib/Drupal/Core/Ajax/AjaxResponse.php @@ -7,15 +7,10 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Asset\AttachedAssets; use Drupal\Core\Render\BubbleableMetadata; -use Drupal\Core\Render\Renderer; use Drupal\Core\Render\AttachmentsInterface; use Drupal\Core\Render\AttachmentsTrait; -use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\JsonResponse; -use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\HttpFoundation\Response; /** * JSON response object for AJAX requests. diff --git a/core/lib/Drupal/Core/Ajax/AlertCommand.php b/core/lib/Drupal/Core/Ajax/AlertCommand.php index 65a9f4604..dbfb0d59a 100644 --- a/core/lib/Drupal/Core/Ajax/AlertCommand.php +++ b/core/lib/Drupal/Core/Ajax/AlertCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * AJAX command for a javascript alert box. * diff --git a/core/lib/Drupal/Core/Ajax/AppendCommand.php b/core/lib/Drupal/Core/Ajax/AppendCommand.php index 041f79430..26061b2d3 100644 --- a/core/lib/Drupal/Core/Ajax/AppendCommand.php +++ b/core/lib/Drupal/Core/Ajax/AppendCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * An AJAX command for calling the jQuery append() method. * diff --git a/core/lib/Drupal/Core/Ajax/BeforeCommand.php b/core/lib/Drupal/Core/Ajax/BeforeCommand.php index 8d526286b..7bf8f416d 100644 --- a/core/lib/Drupal/Core/Ajax/BeforeCommand.php +++ b/core/lib/Drupal/Core/Ajax/BeforeCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * An AJAX command for calling the jQuery before() method. * diff --git a/core/lib/Drupal/Core/Ajax/ChangedCommand.php b/core/lib/Drupal/Core/Ajax/ChangedCommand.php index 7f30972b1..ec92f68d7 100644 --- a/core/lib/Drupal/Core/Ajax/ChangedCommand.php +++ b/core/lib/Drupal/Core/Ajax/ChangedCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * An AJAX command for marking HTML elements as changed. * diff --git a/core/lib/Drupal/Core/Ajax/CloseModalDialogCommand.php b/core/lib/Drupal/Core/Ajax/CloseModalDialogCommand.php index 46d0080f9..64973ae6e 100644 --- a/core/lib/Drupal/Core/Ajax/CloseModalDialogCommand.php +++ b/core/lib/Drupal/Core/Ajax/CloseModalDialogCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CloseDialogCommand; - /** * Defines an AJAX command that closes the currently visible modal dialog. * diff --git a/core/lib/Drupal/Core/Ajax/CssCommand.php b/core/lib/Drupal/Core/Ajax/CssCommand.php index 1a14a4057..24766f353 100644 --- a/core/lib/Drupal/Core/Ajax/CssCommand.php +++ b/core/lib/Drupal/Core/Ajax/CssCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * An AJAX command for calling the jQuery css() method. * diff --git a/core/lib/Drupal/Core/Ajax/DataCommand.php b/core/lib/Drupal/Core/Ajax/DataCommand.php index a495f71a7..4604bf2b4 100644 --- a/core/lib/Drupal/Core/Ajax/DataCommand.php +++ b/core/lib/Drupal/Core/Ajax/DataCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * An AJAX command for implementing jQuery's data() method. * diff --git a/core/lib/Drupal/Core/Ajax/HtmlCommand.php b/core/lib/Drupal/Core/Ajax/HtmlCommand.php index cbae08e9d..96a8d336f 100644 --- a/core/lib/Drupal/Core/Ajax/HtmlCommand.php +++ b/core/lib/Drupal/Core/Ajax/HtmlCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * AJAX command for calling the jQuery html() method. * diff --git a/core/lib/Drupal/Core/Ajax/InsertCommand.php b/core/lib/Drupal/Core/Ajax/InsertCommand.php index 05a7fd188..8c477f5a0 100644 --- a/core/lib/Drupal/Core/Ajax/InsertCommand.php +++ b/core/lib/Drupal/Core/Ajax/InsertCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * Generic AJAX command for inserting content. * diff --git a/core/lib/Drupal/Core/Ajax/InvokeCommand.php b/core/lib/Drupal/Core/Ajax/InvokeCommand.php index 8c032106f..6c1d16e78 100644 --- a/core/lib/Drupal/Core/Ajax/InvokeCommand.php +++ b/core/lib/Drupal/Core/Ajax/InvokeCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * AJAX command for invoking an arbitrary jQuery method. * diff --git a/core/lib/Drupal/Core/Ajax/OpenDialogCommand.php b/core/lib/Drupal/Core/Ajax/OpenDialogCommand.php index d373cf8fe..3c351fdb7 100644 --- a/core/lib/Drupal/Core/Ajax/OpenDialogCommand.php +++ b/core/lib/Drupal/Core/Ajax/OpenDialogCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * Defines an AJAX command to open certain content in a dialog. * diff --git a/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php b/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php index e9b2c4fed..519d192d0 100644 --- a/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php +++ b/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\OpenDialogCommand; - /** * Defines an AJAX command to open certain content in a dialog in a modal dialog. * diff --git a/core/lib/Drupal/Core/Ajax/PrependCommand.php b/core/lib/Drupal/Core/Ajax/PrependCommand.php index c6cc0361c..0ccc6d80d 100644 --- a/core/lib/Drupal/Core/Ajax/PrependCommand.php +++ b/core/lib/Drupal/Core/Ajax/PrependCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * AJAX command for calling the jQuery insert() method. * diff --git a/core/lib/Drupal/Core/Ajax/RedirectCommand.php b/core/lib/Drupal/Core/Ajax/RedirectCommand.php index f7d05e140..cd4c6d536 100644 --- a/core/lib/Drupal/Core/Ajax/RedirectCommand.php +++ b/core/lib/Drupal/Core/Ajax/RedirectCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * Defines an AJAX command to set the window.location, loading that URL. * diff --git a/core/lib/Drupal/Core/Ajax/RemoveCommand.php b/core/lib/Drupal/Core/Ajax/RemoveCommand.php index f4e6bbe35..5131b20c0 100644 --- a/core/lib/Drupal/Core/Ajax/RemoveCommand.php +++ b/core/lib/Drupal/Core/Ajax/RemoveCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * AJAX command for calling the jQuery remove() method. * diff --git a/core/lib/Drupal/Core/Ajax/ReplaceCommand.php b/core/lib/Drupal/Core/Ajax/ReplaceCommand.php index b8cc881a4..615f4eb56 100644 --- a/core/lib/Drupal/Core/Ajax/ReplaceCommand.php +++ b/core/lib/Drupal/Core/Ajax/ReplaceCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\InsertCommand; - /** * AJAX command for calling the jQuery replace() method. * diff --git a/core/lib/Drupal/Core/Ajax/RestripeCommand.php b/core/lib/Drupal/Core/Ajax/RestripeCommand.php index 834e555b5..711950f4c 100644 --- a/core/lib/Drupal/Core/Ajax/RestripeCommand.php +++ b/core/lib/Drupal/Core/Ajax/RestripeCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * AJAX command for resetting the striping on a table. * diff --git a/core/lib/Drupal/Core/Ajax/SetDialogTitleCommand.php b/core/lib/Drupal/Core/Ajax/SetDialogTitleCommand.php index 9a2c5ac65..d4021cc58 100644 --- a/core/lib/Drupal/Core/Ajax/SetDialogTitleCommand.php +++ b/core/lib/Drupal/Core/Ajax/SetDialogTitleCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\SetDialogOptionCommand; - /** * Defines an AJAX command that sets jQuery UI dialog properties. * diff --git a/core/lib/Drupal/Core/Ajax/SettingsCommand.php b/core/lib/Drupal/Core/Ajax/SettingsCommand.php index e33477016..b4ba8cd90 100644 --- a/core/lib/Drupal/Core/Ajax/SettingsCommand.php +++ b/core/lib/Drupal/Core/Ajax/SettingsCommand.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Ajax; -use Drupal\Core\Ajax\CommandInterface; - /** * AJAX command for adjusting Drupal's JavaScript settings. * diff --git a/core/lib/Drupal/Core/Asset/AssetDumper.php b/core/lib/Drupal/Core/Asset/AssetDumper.php index cc5c97a81..0504fa454 100644 --- a/core/lib/Drupal/Core/Asset/AssetDumper.php +++ b/core/lib/Drupal/Core/Asset/AssetDumper.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Asset; -use Drupal\Core\Asset\AssetDumperInterface; use Drupal\Component\Utility\Crypt; /** diff --git a/core/lib/Drupal/Core/Asset/CssCollectionGrouper.php b/core/lib/Drupal/Core/Asset/CssCollectionGrouper.php index 0a751e13c..6ed066252 100644 --- a/core/lib/Drupal/Core/Asset/CssCollectionGrouper.php +++ b/core/lib/Drupal/Core/Asset/CssCollectionGrouper.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Asset; -use Drupal\Core\Asset\AssetCollectionGrouperInterface; - /** * Groups CSS assets. */ diff --git a/core/lib/Drupal/Core/Asset/CssOptimizer.php b/core/lib/Drupal/Core/Asset/CssOptimizer.php index c85caafe8..dc34a237a 100644 --- a/core/lib/Drupal/Core/Asset/CssOptimizer.php +++ b/core/lib/Drupal/Core/Asset/CssOptimizer.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Asset; -use Drupal\Core\Asset\AssetOptimizerInterface; use Drupal\Component\Utility\Unicode; /** diff --git a/core/lib/Drupal/Core/Asset/JsCollectionGrouper.php b/core/lib/Drupal/Core/Asset/JsCollectionGrouper.php index f23cf7759..6ea34e41b 100644 --- a/core/lib/Drupal/Core/Asset/JsCollectionGrouper.php +++ b/core/lib/Drupal/Core/Asset/JsCollectionGrouper.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Asset; -use Drupal\Core\Asset\AssetCollectionGrouperInterface; - /** * Groups JavaScript assets. */ diff --git a/core/lib/Drupal/Core/Asset/JsOptimizer.php b/core/lib/Drupal/Core/Asset/JsOptimizer.php index 546733ce5..e07ca9950 100644 --- a/core/lib/Drupal/Core/Asset/JsOptimizer.php +++ b/core/lib/Drupal/Core/Asset/JsOptimizer.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Asset; -use Drupal\Core\Asset\AssetOptimizerInterface; use Drupal\Component\Utility\Unicode; /** diff --git a/core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php b/core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php index 427640f6d..9d6e796e9 100644 --- a/core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php +++ b/core/lib/Drupal/Core/Asset/LibraryDiscoveryParser.php @@ -11,7 +11,6 @@ use Drupal\Core\Asset\Exception\InvalidLibrariesOverrideSpecificationException; use Drupal\Core\Asset\Exception\InvalidLibraryFileException; use Drupal\Core\Asset\Exception\LibraryDefinitionMissingLicenseException; -use Drupal\Core\Extension\Extension; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Theme\ThemeManagerInterface; use Drupal\Component\Serialization\Exception\InvalidDataTypeException; diff --git a/core/lib/Drupal/Core/Cache/ApcuBackend.php b/core/lib/Drupal/Core/Cache/ApcuBackend.php index 7f04f0e90..b64fd7177 100644 --- a/core/lib/Drupal/Core/Cache/ApcuBackend.php +++ b/core/lib/Drupal/Core/Cache/ApcuBackend.php @@ -68,7 +68,7 @@ public function __construct($bin, $site_prefix, CacheTagsChecksumInterface $chec * @return string * The APCu key for the cache item ID. */ - protected function getApcuKey($cid) { + public function getApcuKey($cid) { return $this->binPrefix . $cid; } @@ -178,14 +178,8 @@ public function set($cid, $data, $expire = CacheBackendInterface::CACHE_PERMANEN $cache->serialized = 0; $cache->data = $data; - // apc_store()'s $ttl argument can be omitted but also set to 0 (zero), - // in which case the value will persist until it's removed from the cache or - // until the next cache clear, restart, etc. This is what we want to do - // when $expire equals CacheBackendInterface::CACHE_PERMANENT. - if ($expire === CacheBackendInterface::CACHE_PERMANENT) { - $expire = 0; - } - apc_store($this->getApcuKey($cid), $cache, $expire); + // Expiration is handled by our own prepareItem(), not APCu. + apc_store($this->getApcuKey($cid), $cache); } /** diff --git a/core/lib/Drupal/Core/Cache/CacheFactory.php b/core/lib/Drupal/Core/Cache/CacheFactory.php index 0a0a97773..a8a5c41ea 100644 --- a/core/lib/Drupal/Core/Cache/CacheFactory.php +++ b/core/lib/Drupal/Core/Cache/CacheFactory.php @@ -13,7 +13,6 @@ use Drupal\Core\Site\Settings; use Symfony\Component\DependencyInjection\ContainerAwareInterface; use Symfony\Component\DependencyInjection\ContainerAwareTrait; -use Symfony\Component\DependencyInjection\ContainerBuilder; class CacheFactory implements CacheFactoryInterface, ContainerAwareInterface { diff --git a/core/lib/Drupal/Core/Cache/CacheableRedirectResponse.php b/core/lib/Drupal/Core/Cache/CacheableRedirectResponse.php new file mode 100644 index 000000000..07d9831c7 --- /dev/null +++ b/core/lib/Drupal/Core/Cache/CacheableRedirectResponse.php @@ -0,0 +1,26 @@ + ['tests', 'driver-testsuite'], + 'behat/mink-browserkit-driver' => ['tests'], + 'behat/mink-goutte-driver' => ['tests'], + 'doctrine/cache' => ['tests'], + 'doctrine/collections' => ['tests'], + 'doctrine/common' => ['tests'], + 'doctrine/inflector' => ['tests'], + 'doctrine/instantiator' => ['tests'], + 'egulias/email-validator' => ['documentation', 'tests'], + 'fabpot/goutte' => ['Goutte/Tests'], + 'guzzlehttp/promises' => ['tests'], + 'guzzlehttp/psr7' => ['tests'], + 'masterminds/html5' => ['test'], + 'mikey179/vfsStream' => ['src/test'], + 'phpdocumentor/reflection-docblock' => ['tests'], + 'phpunit/php-code-coverage' => ['tests'], + 'phpunit/php-timer' => ['tests'], + 'phpunit/php-token-stream' => ['tests'], + 'phpunit/phpunit' => ['tests'], + 'phpunit/php-mock-objects' => ['tests'], + 'sebastian/comparator' => ['tests'], + 'sebastian/diff' => ['tests'], + 'sebastian/environment' => ['tests'], + 'sebastian/exporter' => ['tests'], + 'sebastian/global-state' => ['tests'], + 'sebastian/recursion-context' => ['tests'], + 'stack/builder' => ['tests'], + 'symfony/browser-kit' => ['Tests'], + 'symfony/class-loader' => ['Tests'], + 'symfony/console' => ['Tests'], + 'symfony/css-selector' => ['Tests'], + 'symfony/debug' => ['Tests'], + 'symfony/dependency-injection' => ['Tests'], + 'symfony/dom-crawler' => ['Tests'], + // @see \Drupal\Tests\Component\EventDispatcher\ContainerAwareEventDispatcherTest + // 'symfony/event-dispatcher' => ['Tests'], + 'symfony/http-foundation' => ['Tests'], + 'symfony/http-kernel' => ['Tests'], + 'symfony/process' => ['Tests'], + 'symfony/psr-http-message-bridge' => ['Tests'], + 'symfony/routing' => ['Tests'], + 'symfony/serializer' => ['Tests'], + 'symfony/translation' => ['Tests'], + 'symfony/validator' => ['Tests'], + 'symfony/yaml' => ['Tests'], + 'symfony-cmf/routing' => ['Test', 'Tests'], + 'twig/twig' => ['doc', 'ext', 'test'], + ]; + /** * Add vendor classes to composers static classmap. */ @@ -70,4 +121,90 @@ public static function ensureHtaccess(Event $event) { } } + /** + * Remove possibly problematic test files from vendored projects. + * + * @param \Composer\Script\Event $event + */ + public static function vendorTestCodeCleanup(PackageEvent $event) { + $vendor_dir = $event->getComposer()->getConfig()->get('vendor-dir'); + $op = $event->getOperation(); + if ($op->getJobType() == 'update') { + $package = $op->getTargetPackage(); + } + else { + $package = $op->getPackage(); + } + $package_key = static::findPackageKey($package->getName()); + if ($package_key) { + foreach (static::$packageToCleanup[$package_key] as $path) { + $dir_to_remove = $vendor_dir . '/' . $package_key . '/' . $path; + if (is_dir($dir_to_remove)) { + if (!static::deleteRecursive($dir_to_remove)) { + throw new \RuntimeException(sprintf("Failure removing directory '%s' in package '%s'.", $path, $package->getPrettyName())); + } + } + else { + throw new \RuntimeException(sprintf("The directory '%s' in package '%s' does not exist.", $path, $package->getPrettyName())); + } + } + } + } + + /** + * Find the array key for a given package name with a case-insensitive search. + * + * @param string $package_name + * The package name from composer. This is always already lower case. + * + * @return NULL|string + * The string key, or NULL if none was found. + */ + protected static function findPackageKey($package_name) { + $package_key = NULL; + // In most cases the package name is already used as the array key. + if (isset(static::$packageToCleanup[$package_name])) { + $package_key = $package_name; + } + else { + // Handle any mismatch in case between the package name and array key. + // For example, the array key 'mikey179/vfsStream' needs to be found + // when composer returns a package name of 'mikey179/vfsstream'. + foreach (static::$packageToCleanup as $key => $dirs) { + if (strtolower($key) === $package_name) { + $package_key = $key; + break; + } + } + } + return $package_key; + } + + /** + * Helper method to remove directories and the files they contain. + * + * @param string $path + * The directory or file to remove. It must exist. + * + * @return bool + * TRUE on success or FALSE on failure. + */ + protected static function deleteRecursive($path) { + if (is_file($path) || is_link($path)) { + return unlink($path); + } + $success = TRUE; + $dir = dir($path); + while (($entry = $dir->read()) !== FALSE) { + if ($entry == '.' || $entry == '..') { + continue; + } + $entry_path = $path . '/' . $entry; + $success = static::deleteRecursive($entry_path) && $success; + } + $dir->close(); + + return rmdir($path) && $success; + } + } diff --git a/core/lib/Drupal/Core/Condition/ConditionPluginBase.php b/core/lib/Drupal/Core/Condition/ConditionPluginBase.php index 6f6ffc3e5..5237d0d29 100644 --- a/core/lib/Drupal/Core/Condition/ConditionPluginBase.php +++ b/core/lib/Drupal/Core/Condition/ConditionPluginBase.php @@ -7,8 +7,6 @@ namespace Drupal\Core\Condition; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Executable\ExecutableManagerInterface; use Drupal\Core\Executable\ExecutablePluginBase; use Drupal\Core\Form\FormStateInterface; diff --git a/core/lib/Drupal/Core/Config/CachedStorage.php b/core/lib/Drupal/Core/Config/CachedStorage.php index 590d857ec..eb9749ebe 100644 --- a/core/lib/Drupal/Core/Config/CachedStorage.php +++ b/core/lib/Drupal/Core/Config/CachedStorage.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Config; -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\DependencyInjection\DependencySerializationTrait; diff --git a/core/lib/Drupal/Core/Config/ConfigInstaller.php b/core/lib/Drupal/Core/Config/ConfigInstaller.php index 0cc5d00a3..7209030dd 100644 --- a/core/lib/Drupal/Core/Config/ConfigInstaller.php +++ b/core/lib/Drupal/Core/Config/ConfigInstaller.php @@ -10,7 +10,6 @@ use Drupal\Component\Utility\Unicode; use Drupal\Core\Config\Entity\ConfigDependencyManager; use Drupal\Core\Config\Entity\ConfigEntityDependency; -use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Site\Settings; use Symfony\Component\EventDispatcher\EventDispatcherInterface; diff --git a/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php b/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php index 7e5c3a4a6..0ed51620d 100644 --- a/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php +++ b/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php @@ -9,14 +9,12 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Core\Cache\Cache; -use Drupal\Core\Config\ConfigException; use Drupal\Core\Config\Schema\SchemaIncompleteException; use Drupal\Core\Entity\Entity; use Drupal\Core\Config\ConfigDuplicateUUIDException; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Entity\EntityWithPluginCollectionInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Plugin\PluginDependencyTrait; /** diff --git a/core/lib/Drupal/Core/Config/Entity/ConfigEntityStorageInterface.php b/core/lib/Drupal/Core/Config/Entity/ConfigEntityStorageInterface.php index 8bb9e43cb..55c119323 100644 --- a/core/lib/Drupal/Core/Config/Entity/ConfigEntityStorageInterface.php +++ b/core/lib/Drupal/Core/Config/Entity/ConfigEntityStorageInterface.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Config\Entity; -use Drupal\Core\Config\Config; use Drupal\Core\Entity\EntityStorageInterface; /** diff --git a/core/lib/Drupal/Core/Config/Entity/Query/Condition.php b/core/lib/Drupal/Core/Config/Entity/Query/Condition.php index e6d2d523c..3d378b9ec 100644 --- a/core/lib/Drupal/Core/Config/Entity/Query/Condition.php +++ b/core/lib/Drupal/Core/Config/Entity/Query/Condition.php @@ -27,7 +27,7 @@ public function compile($configs) { $single_conditions = array(); $condition_groups = array(); foreach ($this->conditions as $condition) { - if ($condition['field'] instanceOf ConditionInterface) { + if ($condition['field'] instanceof ConditionInterface) { $condition_groups[] = $condition; } else { diff --git a/core/lib/Drupal/Core/Config/StorageComparerInterface.php b/core/lib/Drupal/Core/Config/StorageComparerInterface.php index 180f29a94..293d9db99 100644 --- a/core/lib/Drupal/Core/Config/StorageComparerInterface.php +++ b/core/lib/Drupal/Core/Config/StorageComparerInterface.php @@ -109,7 +109,7 @@ public function moveRenameToUpdate($rename, $collection = StorageInterface::DEFA * * @return array * An associative array of configuration names. The array keys are - * 'old_name' and and 'new_name' representing the old and name configuration + * 'old_name' and 'new_name' representing the old and new configuration * object names during a rename operation. * * @see \Drupal\Core\Config\StorageComparer::createRenameNames() diff --git a/core/lib/Drupal/Core/Config/Testing/ConfigSchemaChecker.php b/core/lib/Drupal/Core/Config/Testing/ConfigSchemaChecker.php index 4c01e13f7..e01d16408 100644 --- a/core/lib/Drupal/Core/Config/Testing/ConfigSchemaChecker.php +++ b/core/lib/Drupal/Core/Config/Testing/ConfigSchemaChecker.php @@ -43,14 +43,24 @@ class ConfigSchemaChecker implements EventSubscriberInterface { */ protected $checked = array(); + /** + * An array of config object names that are excluded from schema checking. + * + * @var string[] + */ + protected $exclude = array(); + /** * Constructs the ConfigSchemaChecker object. * * @param \Drupal\Core\Config\TypedConfigManagerInterface $typed_manager * The typed config manager. + * @param string[] $exclude + * An array of config object names that are excluded from schema checking. */ - public function __construct(TypedConfigManagerInterface $typed_manager) { + public function __construct(TypedConfigManagerInterface $typed_manager, array $exclude = array()) { $this->typedManager = $typed_manager; + $this->exclude = $exclude; } /** @@ -74,17 +84,7 @@ public function onConfigSave(ConfigCrudEvent $event) { $name = $saved_config->getName(); $data = $saved_config->get(); $checksum = hash('crc32b', serialize($data)); - $exceptions = array( - // Following are used to test lack of or partial schema. Where partial - // schema is provided, that is explicitly tested in specific tests. - 'config_schema_test.noschema', - 'config_schema_test.someschema', - 'config_schema_test.schema_data_types', - 'config_schema_test.no_schema_data_types', - // Used to test application of schema to filtering of configuration. - 'config_test.dynamic.system', - ); - if (!in_array($name, $exceptions) && !isset($this->checked[$name . ':' . $checksum])) { + if (!in_array($name, $this->exclude) && !isset($this->checked[$name . ':' . $checksum])) { $this->checked[$name . ':' . $checksum] = TRUE; $errors = $this->checkConfigSchema($this->typedManager, $name, $data); if ($errors === FALSE) { diff --git a/core/lib/Drupal/Core/Config/TypedConfigManager.php b/core/lib/Drupal/Core/Config/TypedConfigManager.php index 625e1eaba..ca0eb5070 100644 --- a/core/lib/Drupal/Core/Config/TypedConfigManager.php +++ b/core/lib/Drupal/Core/Config/TypedConfigManager.php @@ -9,7 +9,6 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Core\Cache\CacheBackendInterface; -use Drupal\Core\Config\Schema\ArrayElement; use Drupal\Core\Config\Schema\ConfigSchemaAlterException; use Drupal\Core\Config\Schema\ConfigSchemaDiscovery; use Drupal\Core\Extension\ModuleHandlerInterface; diff --git a/core/lib/Drupal/Core/Database/Driver/mysql/Schema.php b/core/lib/Drupal/Core/Database/Driver/mysql/Schema.php index c4d482eae..a20e58d67 100644 --- a/core/lib/Drupal/Core/Database/Driver/mysql/Schema.php +++ b/core/lib/Drupal/Core/Database/Driver/mysql/Schema.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Database\Driver\mysql; -use Drupal\Core\Database\Database; use Drupal\Core\Database\Query\Condition; use Drupal\Core\Database\SchemaException; use Drupal\Core\Database\SchemaObjectExistsException; diff --git a/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php b/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php index ff38a22c5..b5ef45d18 100644 --- a/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php +++ b/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php @@ -10,9 +10,6 @@ use Drupal\Core\Database\Database; use Drupal\Core\Database\Connection as DatabaseConnection; use Drupal\Core\Database\DatabaseNotFoundException; -use Drupal\Core\Database\StatementInterface; -use Drupal\Core\Database\IntegrityConstraintViolationException; -use Drupal\Core\Database\DatabaseExceptionWrapper; /** * @addtogroup database diff --git a/core/lib/Drupal/Core/Database/Driver/pgsql/Schema.php b/core/lib/Drupal/Core/Database/Driver/pgsql/Schema.php index 0828d5929..cd22b94e3 100644 --- a/core/lib/Drupal/Core/Database/Driver/pgsql/Schema.php +++ b/core/lib/Drupal/Core/Database/Driver/pgsql/Schema.php @@ -8,8 +8,6 @@ namespace Drupal\Core\Database\Driver\pgsql; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Database\Database; -use Drupal\Core\Database\Query\Condition; use Drupal\Core\Database\SchemaObjectExistsException; use Drupal\Core\Database\SchemaObjectDoesNotExistException; use Drupal\Core\Database\Schema as DatabaseSchema; diff --git a/core/lib/Drupal/Core/Database/Query/Condition.php b/core/lib/Drupal/Core/Database/Query/Condition.php index 2b9574e3d..fe9ac4f07 100644 --- a/core/lib/Drupal/Core/Database/Query/Condition.php +++ b/core/lib/Drupal/Core/Database/Query/Condition.php @@ -277,10 +277,10 @@ function __clone() { $this->changed = TRUE; foreach ($this->conditions as $key => $condition) { if ($key !== '#conjunction') { - if ($condition['field'] instanceOf ConditionInterface) { + if ($condition['field'] instanceof ConditionInterface) { $this->conditions[$key]['field'] = clone($condition['field']); } - if ($condition['value'] instanceOf SelectInterface) { + if ($condition['value'] instanceof SelectInterface) { $this->conditions[$key]['value'] = clone($condition['value']); } } diff --git a/core/lib/Drupal/Core/Database/Query/PagerSelectExtender.php b/core/lib/Drupal/Core/Database/Query/PagerSelectExtender.php index bc5c5335a..95cdf53dc 100644 --- a/core/lib/Drupal/Core/Database/Query/PagerSelectExtender.php +++ b/core/lib/Drupal/Core/Database/Query/PagerSelectExtender.php @@ -8,8 +8,6 @@ namespace Drupal\Core\Database\Query; use Drupal\Core\Database\Connection; -use Drupal\Core\Database\Query\SelectExtender; -use Drupal\Core\Database\Query\SelectInterface; /** * Query extender for pager queries. diff --git a/core/lib/Drupal/Core/Database/Schema.php b/core/lib/Drupal/Core/Database/Schema.php index f064156f4..8b6fa57ec 100644 --- a/core/lib/Drupal/Core/Database/Schema.php +++ b/core/lib/Drupal/Core/Database/Schema.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Database; -use Drupal\Core\Database\SchemaObjectExistsException; use Drupal\Core\Database\Query\Condition; use Drupal\Core\Database\Query\PlaceholderInterface; diff --git a/core/lib/Drupal/Core/Datetime/DateFormatInterface.php b/core/lib/Drupal/Core/Datetime/DateFormatInterface.php index 162ec3bf0..810af6d7c 100644 --- a/core/lib/Drupal/Core/Datetime/DateFormatInterface.php +++ b/core/lib/Drupal/Core/Datetime/DateFormatInterface.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Datetime; use Drupal\Core\Config\Entity\ConfigEntityInterface; -use Drupal\Core\Datetime\DrupalDateTime; /** * Provides an interface defining a date format. diff --git a/core/lib/Drupal/Core/Datetime/DateFormatter.php b/core/lib/Drupal/Core/Datetime/DateFormatter.php index be2330332..d288fee4c 100644 --- a/core/lib/Drupal/Core/Datetime/DateFormatter.php +++ b/core/lib/Drupal/Core/Datetime/DateFormatter.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Datetime; use Drupal\Core\Config\ConfigFactoryInterface; -use Drupal\Core\Datetime\DrupalDateTime; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Language\Language; use Drupal\Core\Language\LanguageManagerInterface; diff --git a/core/lib/Drupal/Core/Datetime/DateHelper.php b/core/lib/Drupal/Core/Datetime/DateHelper.php index 9cdd1f120..0bc8fdb23 100644 --- a/core/lib/Drupal/Core/Datetime/DateHelper.php +++ b/core/lib/Drupal/Core/Datetime/DateHelper.php @@ -16,8 +16,6 @@ */ namespace Drupal\Core\Datetime; -use Drupal\Core\Datetime\DrupalDateTime; - /** * Defines Gregorian Calendar date values. */ @@ -449,7 +447,7 @@ public static function ampm($required = FALSE) { * The number of days in the month. */ public static function daysInMonth($date = NULL) { - if (!$date instanceOf DrupalDateTime) { + if (!$date instanceof DrupalDateTime) { $date = new DrupalDateTime($date); } if (!$date->hasErrors()) { @@ -469,7 +467,7 @@ public static function daysInMonth($date = NULL) { * The number of days in the year. */ public static function daysInYear($date = NULL) { - if (!$date instanceOf DrupalDateTime) { + if (!$date instanceof DrupalDateTime) { $date = new DrupalDateTime($date); } if (!$date->hasErrors()) { @@ -494,7 +492,7 @@ public static function daysInYear($date = NULL) { * The number of the day in the week. */ public static function dayOfWeek($date = NULL) { - if (!$date instanceOf DrupalDateTime) { + if (!$date instanceof DrupalDateTime) { $date = new DrupalDateTime($date); } if (!$date->hasErrors()) { @@ -517,7 +515,7 @@ public static function dayOfWeek($date = NULL) { * The name of the day in the week for that date. */ public static function dayOfWeekName($date = NULL, $abbr = TRUE) { - if (!$date instanceOf DrupalDateTime) { + if (!$date instanceof DrupalDateTime) { $date = new DrupalDateTime($date); } $dow = self::dayOfWeek($date); diff --git a/core/lib/Drupal/Core/Datetime/Element/DateElementBase.php b/core/lib/Drupal/Core/Datetime/Element/DateElementBase.php index 8e359158d..16d0a176f 100644 --- a/core/lib/Drupal/Core/Datetime/Element/DateElementBase.php +++ b/core/lib/Drupal/Core/Datetime/Element/DateElementBase.php @@ -66,7 +66,7 @@ protected static function datetimeRangeYears($string, $date = NULL) { $min_year = $temp; } // If there is a current value, stretch the range to include it. - $value_year = $date instanceOf DrupalDateTime ? $date->format('Y') : ''; + $value_year = $date instanceof DrupalDateTime ? $date->format('Y') : ''; if (!empty($value_year)) { $min_year = min($value_year, $min_year); $max_year = max($value_year, $max_year); diff --git a/core/lib/Drupal/Core/Datetime/Element/Datelist.php b/core/lib/Drupal/Core/Datetime/Element/Datelist.php index 2caa4cad6..15ce2f362 100644 --- a/core/lib/Drupal/Core/Datetime/Element/Datelist.php +++ b/core/lib/Drupal/Core/Datetime/Element/Datelist.php @@ -67,7 +67,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form } $timezone = !empty($element['#date_timezone']) ? $element['#date_timezone'] : NULL; $date = DrupalDateTime::createFromArray($input, $timezone); - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { static::incrementRound($date, $increment); } } @@ -76,7 +76,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form $return = array_fill_keys($parts, ''); if (!empty($element['#default_value'])) { $date = $element['#default_value']; - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { static::incrementRound($date, $increment); foreach ($parts as $part) { switch ($part) { @@ -184,7 +184,7 @@ public static function processDatelist(&$element, FormStateInterface $form_state $date = !empty($element['#value']['object']) ? $element['#value']['object'] : NULL; // Set a fallback timezone. - if ($date instanceOf DrupalDateTime) { + if ($date instanceof DrupalDateTime) { $element['#date_timezone'] = $date->getTimezone()->getName(); } elseif (!empty($element['#timezone'])) { @@ -253,7 +253,7 @@ public static function processDatelist(&$element, FormStateInterface $form_state } $default = isset($element['#value'][$part]) && trim($element['#value'][$part]) != '' ? $element['#value'][$part] : ''; - $value = $date instanceOf DrupalDateTime && !$date->hasErrors() ? $date->format($format) : $default; + $value = $date instanceof DrupalDateTime && !$date->hasErrors() ? $date->format($format) : $default; if (!empty($value) && $part != 'ampm') { $value = intval($value); } @@ -320,7 +320,7 @@ public static function validateDatelist(&$element, FormStateInterface $form_stat else { // If the input is valid, set it. $date = $input['object']; - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { $form_state->setValueForElement($element, $date); } // If the input is invalid, set an error. @@ -364,7 +364,7 @@ protected static function checkEmptyInputs($input, $parts) { */ protected static function incrementRound(&$date, $increment) { // Round minutes and seconds, if necessary. - if ($date instanceOf DrupalDateTime && $increment > 1) { + if ($date instanceof DrupalDateTime && $increment > 1) { $day = intval($date->format('j')); $hour = intval($date->format('H')); $second = intval(round(intval($date->format('s')) / $increment) * $increment); diff --git a/core/lib/Drupal/Core/Datetime/Element/Datetime.php b/core/lib/Drupal/Core/Datetime/Element/Datetime.php index 3eb7c8446..a68927ab9 100644 --- a/core/lib/Drupal/Core/Datetime/Element/Datetime.php +++ b/core/lib/Drupal/Core/Datetime/Element/Datetime.php @@ -101,7 +101,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form } else { $date = $element['#default_value']; - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { $input = array( 'date' => $date->format($element['#date_date_format']), 'time' => $date->format($element['#date_time_format']), @@ -223,7 +223,7 @@ public static function processDatetime(&$element, FormStateInterface $form_state $date = !empty($element['#value']['object']) ? $element['#value']['object'] : NULL; // Set a fallback timezone. - if ($date instanceOf DrupalDateTime) { + if ($date instanceof DrupalDateTime) { $element['#date_timezone'] = $date->getTimezone()->getName(); } elseif (empty($element['#timezone'])) { @@ -246,7 +246,7 @@ public static function processDatetime(&$element, FormStateInterface $form_state ); // Adds the HTML5 date attributes. - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { $html5_min = clone($date); $range = static::datetimeRangeYears($element['#date_year_range'], $date); $html5_min->setDate($range[0], 1, 1)->setTime(0, 0, 0); diff --git a/core/lib/Drupal/Core/DependencyInjection/Compiler/ProxyServicesPass.php b/core/lib/Drupal/Core/DependencyInjection/Compiler/ProxyServicesPass.php index 90b1755dc..ac424ab64 100644 --- a/core/lib/Drupal/Core/DependencyInjection/Compiler/ProxyServicesPass.php +++ b/core/lib/Drupal/Core/DependencyInjection/Compiler/ProxyServicesPass.php @@ -10,8 +10,6 @@ use Drupal\Component\ProxyBuilder\ProxyBuilder; use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; use Symfony\Component\DependencyInjection\Reference; /** diff --git a/core/lib/Drupal/Core/DependencyInjection/Compiler/RegisterStreamWrappersPass.php b/core/lib/Drupal/Core/DependencyInjection/Compiler/RegisterStreamWrappersPass.php index 4659cb04f..b46ae2dc2 100644 --- a/core/lib/Drupal/Core/DependencyInjection/Compiler/RegisterStreamWrappersPass.php +++ b/core/lib/Drupal/Core/DependencyInjection/Compiler/RegisterStreamWrappersPass.php @@ -7,10 +7,8 @@ namespace Drupal\Core\DependencyInjection\Compiler; -use Drupal\Core\StreamWrapper\StreamWrapperInterface; use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Reference; /** * Adds services tagged 'stream_wrapper' to the stream_wrapper_manager service. diff --git a/core/lib/Drupal/Core/DrupalKernel.php b/core/lib/Drupal/Core/DrupalKernel.php index 16b3baca2..0c16cb35c 100644 --- a/core/lib/Drupal/Core/DrupalKernel.php +++ b/core/lib/Drupal/Core/DrupalKernel.php @@ -22,14 +22,12 @@ use Drupal\Core\File\MimeType\MimeTypeGuesser; use Drupal\Core\Http\TrustedHostsRequestFactory; use Drupal\Core\Language\Language; -use Drupal\Core\PageCache\RequestPolicyInterface; use Drupal\Core\Site\Settings; use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\HttpFoundation\RequestStack; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; use Symfony\Component\HttpKernel\Exception\HttpExceptionInterface; diff --git a/core/lib/Drupal/Core/Entity/Controller/EntityController.php b/core/lib/Drupal/Core/Entity/Controller/EntityController.php new file mode 100644 index 000000000..0af9638f5 --- /dev/null +++ b/core/lib/Drupal/Core/Entity/Controller/EntityController.php @@ -0,0 +1,143 @@ +entityManager = $entity_manager; + $this->stringTranslation = $string_translation; + } + + /** + * {@inheritdoc} + */ + public static function create(ContainerInterface $container) { + return new static( + $container->get('entity.manager'), + $container->get('string_translation') + ); + } + + /** + * Provides a generic title callback for a single entity. + * + * @param \Drupal\Core\Routing\RouteMatchInterface $route_match + * The route match. + * @param \Drupal\Core\Entity\EntityInterface $_entity + * (optional) An entity, passed in directly from the request attributes. + * + * @return string + * The title for the entity view page. + */ + public function title(RouteMatchInterface $route_match, EntityInterface $_entity = NULL) { + if ($entity = $this->doGetEntity($route_match, $_entity)) { + return $entity->label(); + } + } + + /** + * Provides a generic edit title callback. + * + * @param \Drupal\Core\Routing\RouteMatchInterface $route_match + * The route match. + * @param \Drupal\Core\Entity\EntityInterface $_entity + * (optional) An entity, passed in directly from the request attributes. + * + * @return string + * The title for the entity edit page. + */ + public function editTitle(RouteMatchInterface $route_match, EntityInterface $_entity = NULL) { + if ($entity = $this->doGetEntity($route_match, $_entity)) { + return $this->t('Edit %label', ['%label' => $entity->label()]); + } + } + + /** + * Provides a generic delete title callback. + * + * @param \Drupal\Core\Routing\RouteMatchInterface $route_match + * The route match. + * @param \Drupal\Core\Entity\EntityInterface $_entity + * (optional) An entity, passed in directly from the request attributes, and + * set in \Drupal\Core\Entity\Enhancer\EntityRouteEnhancer. + * + * @return string + * The title for the delete entity page. + */ + public function deleteTitle(RouteMatchInterface $route_match, EntityInterface $_entity = NULL) { + if ($entity = $this->doGetEntity($route_match, $_entity)) { + return $this->t('Delete %label', ['%label' => $entity->label()]); + } + } + + /** + * Determines the entity. + * + * @param \Drupal\Core\Routing\RouteMatchInterface $route_match + * The route match. + * @param \Drupal\Core\Entity\EntityInterface $_entity + * (optional) The entity, set in + * \Drupal\Core\Entity\Enhancer\EntityRouteEnhancer. + * + * @return \Drupal\Core\Entity\EntityInterface|NULL + * The entity, if it is passed in directly or if the first parameter of the + * active route is an entity; otherwise, NULL. + */ + protected function doGetEntity(RouteMatchInterface $route_match, EntityInterface $_entity = NULL) { + if ($_entity) { + $entity = $_entity; + } + else { + // Let's look up in the route object for the name of upcasted values. + foreach ($route_match->getParameters() as $parameter) { + if ($parameter instanceof EntityInterface) { + $entity = $parameter; + break; + } + } + } + if ($entity) { + return $this->entityManager->getTranslationFromContext($entity); + } + } + +} diff --git a/core/lib/Drupal/Core/Entity/Controller/EntityListController.php b/core/lib/Drupal/Core/Entity/Controller/EntityListController.php index 1b081bb97..1c7e7462b 100644 --- a/core/lib/Drupal/Core/Entity/Controller/EntityListController.php +++ b/core/lib/Drupal/Core/Entity/Controller/EntityListController.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Entity\Controller; use Drupal\Core\Controller\ControllerBase; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Defines a generic controller to list entities. diff --git a/core/lib/Drupal/Core/Entity/Entity.php b/core/lib/Drupal/Core/Entity/Entity.php index 74ce4e78e..fa1f8adcd 100644 --- a/core/lib/Drupal/Core/Entity/Entity.php +++ b/core/lib/Drupal/Core/Entity/Entity.php @@ -10,7 +10,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\RefinableCacheableDependencyTrait; use Drupal\Core\DependencyInjection\DependencySerializationTrait; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Component\Utility\Unicode; use Drupal\Core\Config\Entity\Exception\ConfigEntityIdLengthException; use Drupal\Core\Entity\Exception\UndefinedLinkTemplateException; diff --git a/core/lib/Drupal/Core/Entity/EntityAccessControlHandlerInterface.php b/core/lib/Drupal/Core/Entity/EntityAccessControlHandlerInterface.php index 8d6a1d135..c1e7333f9 100644 --- a/core/lib/Drupal/Core/Entity/EntityAccessControlHandlerInterface.php +++ b/core/lib/Drupal/Core/Entity/EntityAccessControlHandlerInterface.php @@ -10,7 +10,6 @@ use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Field\FieldDefinitionInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Session\AccountInterface; /** diff --git a/core/lib/Drupal/Core/Entity/EntityConfirmFormBase.php b/core/lib/Drupal/Core/Entity/EntityConfirmFormBase.php index 7b320e168..75e4ae8b9 100644 --- a/core/lib/Drupal/Core/Entity/EntityConfirmFormBase.php +++ b/core/lib/Drupal/Core/Entity/EntityConfirmFormBase.php @@ -10,7 +10,6 @@ use Drupal\Core\Form\ConfirmFormHelper; use Drupal\Core\Form\ConfirmFormInterface; use Drupal\Core\Form\FormStateInterface; -use Symfony\Component\HttpFoundation\Request; /** * Provides a generic base class for an entity-based confirmation form. diff --git a/core/lib/Drupal/Core/Entity/EntityListBuilder.php b/core/lib/Drupal/Core/Entity/EntityListBuilder.php index 5cb89f794..3e2d3513b 100644 --- a/core/lib/Drupal/Core/Entity/EntityListBuilder.php +++ b/core/lib/Drupal/Core/Entity/EntityListBuilder.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Entity; -use Drupal\Core\Extension\ModuleHandlerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/lib/Drupal/Core/Entity/EntityManager.php b/core/lib/Drupal/Core/Entity/EntityManager.php index da4fec06a..185ca8b3a 100644 --- a/core/lib/Drupal/Core/Entity/EntityManager.php +++ b/core/lib/Drupal/Core/Entity/EntityManager.php @@ -24,7 +24,6 @@ use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\Core\Field\FieldStorageDefinitionListenerInterface; use Drupal\Core\KeyValueStore\KeyValueFactoryInterface; -use Drupal\Core\KeyValueStore\KeyValueStoreInterface; use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Core\Plugin\DefaultPluginManager; @@ -1133,7 +1132,7 @@ protected function getDisplayModeOptions($display_type, $entity_type_id) { } /** - * Returns an array of display mode options by bundle. + * Returns an array of enabled display mode options by bundle. * * @param $display_type * The display type to be retrieved. It can be "view_mode" or "form_mode". diff --git a/core/lib/Drupal/Core/Entity/EntityManagerInterface.php b/core/lib/Drupal/Core/Entity/EntityManagerInterface.php index 8132c73ec..edce82c76 100644 --- a/core/lib/Drupal/Core/Entity/EntityManagerInterface.php +++ b/core/lib/Drupal/Core/Entity/EntityManagerInterface.php @@ -450,7 +450,7 @@ public function getViewModeOptions($entity_type_id); public function getFormModeOptions($entity_type_id); /** - * Returns an array of view mode options by bundle. + * Returns an array of enabled view mode options by bundle. * * @param string $entity_type_id * The entity type whose view mode options should be returned. @@ -463,7 +463,7 @@ public function getFormModeOptions($entity_type_id); public function getViewModeOptionsByBundle($entity_type_id, $bundle); /** - * Returns an array of form mode options by bundle. + * Returns an array of enabled form mode options by bundle. * * @param string $entity_type_id * The entity type whose form mode options should be returned. diff --git a/core/lib/Drupal/Core/Entity/Query/ConditionFundamentals.php b/core/lib/Drupal/Core/Entity/Query/ConditionFundamentals.php index b93e192c2..21667a7b7 100644 --- a/core/lib/Drupal/Core/Entity/Query/ConditionFundamentals.php +++ b/core/lib/Drupal/Core/Entity/Query/ConditionFundamentals.php @@ -87,7 +87,7 @@ public function &conditions() { */ public function __clone() { foreach ($this->conditions as $key => $condition) { - if ($condition['field'] instanceOf ConditionInterface) { + if ($condition['field'] instanceof ConditionInterface) { $this->conditions[$key]['field'] = clone($condition['field']); } } diff --git a/core/lib/Drupal/Core/Entity/Query/Sql/Condition.php b/core/lib/Drupal/Core/Entity/Query/Sql/Condition.php index 1ee2c3da8..53c611276 100644 --- a/core/lib/Drupal/Core/Entity/Query/Sql/Condition.php +++ b/core/lib/Drupal/Core/Entity/Query/Sql/Condition.php @@ -37,7 +37,7 @@ public function compile($conditionContainer) { $sql_query = $conditionContainer instanceof SelectInterface ? $conditionContainer : $conditionContainer->sqlQuery; $tables = $this->query->getTables($sql_query); foreach ($this->conditions as $condition) { - if ($condition['field'] instanceOf ConditionInterface) { + if ($condition['field'] instanceof ConditionInterface) { $sql_condition = new SqlCondition($condition['field']->getConjunction()); // Add the SQL query to the object before calling this method again. $sql_condition->sqlQuery = $sql_query; diff --git a/core/lib/Drupal/Core/Entity/Query/Sql/ConditionAggregate.php b/core/lib/Drupal/Core/Entity/Query/Sql/ConditionAggregate.php index 9db67ea73..1f6965d12 100644 --- a/core/lib/Drupal/Core/Entity/Query/Sql/ConditionAggregate.php +++ b/core/lib/Drupal/Core/Entity/Query/Sql/ConditionAggregate.php @@ -30,7 +30,7 @@ public function compile($conditionContainer) { $sql_query = ($conditionContainer instanceof SelectInterface) ? $conditionContainer : $conditionContainer->sqlQuery; $tables = new Tables($sql_query); foreach ($this->conditions as $condition) { - if ($condition['field'] instanceOf ConditionAggregateInterface) { + if ($condition['field'] instanceof ConditionAggregateInterface) { $sql_condition = new SqlCondition($condition['field']->getConjunction()); // Add the SQL query to the object before calling this method again. $sql_condition->sqlQuery = $sql_query; diff --git a/core/lib/Drupal/Core/Entity/Query/Sql/QueryFactory.php b/core/lib/Drupal/Core/Entity/Query/Sql/QueryFactory.php index 4b7de43cc..e233e2f0d 100644 --- a/core/lib/Drupal/Core/Entity/Query/Sql/QueryFactory.php +++ b/core/lib/Drupal/Core/Entity/Query/Sql/QueryFactory.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Entity\Query\Sql; use Drupal\Core\Database\Connection; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Entity\Query\QueryBase; use Drupal\Core\Entity\Query\QueryFactoryInterface; diff --git a/core/lib/Drupal/Core/Entity/Routing/AdminHtmlRouteProvider.php b/core/lib/Drupal/Core/Entity/Routing/AdminHtmlRouteProvider.php new file mode 100644 index 000000000..39c1c6ebc --- /dev/null +++ b/core/lib/Drupal/Core/Entity/Routing/AdminHtmlRouteProvider.php @@ -0,0 +1,44 @@ +setOption('_admin_route', TRUE); + return $route; + } + } + + /** + * {@inheritdoc} + */ + protected function getDeleteFormRoute(EntityTypeInterface $entity_type) { + if ($route = parent::getDeleteFormRoute($entity_type)) { + $route->setOption('_admin_route', TRUE); + return $route; + } + } + +} diff --git a/core/lib/Drupal/Core/Entity/Routing/DefaultHtmlRouteProvider.php b/core/lib/Drupal/Core/Entity/Routing/DefaultHtmlRouteProvider.php new file mode 100644 index 000000000..f0b5907de --- /dev/null +++ b/core/lib/Drupal/Core/Entity/Routing/DefaultHtmlRouteProvider.php @@ -0,0 +1,135 @@ +id(); + + if ($edit_route = $this->getEditFormRoute($entity_type)) { + $collection->add("entity.{$entity_type_id}.edit_form", $edit_route); + } + + if ($canonical_route = $this->getCanonicalRoute($entity_type)) { + $collection->add("entity.{$entity_type_id}.canonical", $canonical_route); + } + + if ($delete_route = $this->getDeleteFormRoute($entity_type)) { + $collection->add("entity.{$entity_type_id}.delete_form", $delete_route); + } + + return $collection; + } + + /** + * Gets the canonical route. + * + * @param \Drupal\Core\Entity\EntityTypeInterface $entity_type + * The entity type. + * + * @return \Symfony\Component\Routing\Route|null + * The generated route, if available. + */ + protected function getCanonicalRoute(EntityTypeInterface $entity_type) { + if ($entity_type->hasLinkTemplate('canonical') && $entity_type->hasViewBuilderClass()) { + $entity_type_id = $entity_type->id(); + $route = new Route($entity_type->getLinkTemplate('canonical')); + $route + ->addDefaults([ + '_entity_view' => "{$entity_type_id}.full", + '_title_callback' => '\Drupal\Core\Entity\Controller\EntityController::title', + ]) + ->setRequirement('_entity_access', "{$entity_type_id}.view") + ->setOption('parameters', [ + $entity_type_id => ['type' => 'entity:' . $entity_type_id], + ]); + return $route; + } + } + + /** + * Gets the edit-form route. + * + * @param \Drupal\Core\Entity\EntityTypeInterface $entity_type + * The entity type. + * + * @return \Symfony\Component\Routing\Route|null + * The generated route, if available. + */ + protected function getEditFormRoute(EntityTypeInterface $entity_type) { + if ($entity_type->hasLinkTemplate('edit-form')) { + $entity_type_id = $entity_type->id(); + $route = new Route($entity_type->getLinkTemplate('edit-form')); + // Use the edit form handler, if available, otherwise default. + $operation = 'default'; + if ($entity_type->getFormClass('edit')) { + $operation = 'edit'; + } + $route + ->setDefaults([ + '_entity_form' => "{$entity_type_id}.{$operation}", + '_title_callback' => '\Drupal\Core\Entity\Controller\EntityController::editTitle' + ]) + ->setRequirement('_entity_access', "{$entity_type_id}.update") + ->setOption('parameters', [ + $entity_type_id => ['type' => 'entity:' . $entity_type_id], + ]); + return $route; + } + } + + /** + * Gets the delete-form route. + * + * @param \Drupal\Core\Entity\EntityTypeInterface $entity_type + * The entity type. + * + * @return \Symfony\Component\Routing\Route|null + * The generated route, if available. + */ + protected function getDeleteFormRoute(EntityTypeInterface $entity_type) { + if ($entity_type->hasLinkTemplate('delete-form')) { + $entity_type_id = $entity_type->id(); + $route = new Route($entity_type->getLinkTemplate('delete-form')); + $route + ->addDefaults([ + '_entity_form' => "{$entity_type_id}.delete", + '_title_callback' => '\Drupal\Core\Entity\Controller\EntityController::deleteTitle', + ]) + ->setRequirement('_entity_access', "{$entity_type_id}.delete") + ->setOption('parameters', [ + $entity_type_id => ['type' => 'entity:' . $entity_type_id], + ]); + return $route; + } + } + +} diff --git a/core/lib/Drupal/Core/Entity/entity.api.php b/core/lib/Drupal/Core/Entity/entity.api.php index 3a3d61c6b..8883f78d0 100644 --- a/core/lib/Drupal/Core/Entity/entity.api.php +++ b/core/lib/Drupal/Core/Entity/entity.api.php @@ -324,7 +324,9 @@ * also need to add a corresponding route to your module's routing.yml file; * see the entity.node.canonical route in node.routing.yml for an example, and see * @ref sec_routes below for some notes. - * - Define routes and links for the various URLs associated with the entity. + * - Optionally, instead of defining routes, routes can be auto generated by + * providing a route handler. See @ref sec_routes. Otherwise, define routes + * and links for the various URLs associated with the entity. * These go into the 'links' annotation, with the link type as the key, and * the path of this link template as the value. The corresponding route * requires the following route name: @@ -358,8 +360,10 @@ * * @section sec_routes Entity routes * Entity routes, like other routes, are defined in *.routing.yml files; see - * the @link menu Menu and routing @endlink topic for more information. Here - * is a typical entry, for the block configure form: + * the @link routing Routing API @endlink topic for more information. Entities + * may alternatively use an auto route provider class; there is an example of + * this at the end of this section. If providing routes directly, here is a + * typical entry, for the block configure form: * @code * entity.block.edit_form: * path: '/admin/structure/block/manage/{block}' @@ -386,6 +390,19 @@ * "form" = { * "default" = "Drupal\block\BlockForm", * @endcode + * - Instead of putting the routes for your entity in a *.routing.yml file, you + * can instead use a route provider class. + * \Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider provides canonical, + * edit-form, and delete-form routes; + * \Drupal\Core\Entity\Routing\AdminHtmlRouteProvider provides the same + * routes, set up to use the administrative theme for edit and delete pages. + * You can also create your own class. To use a route provider class, add + * lines like the following to your entity annotation: + * @code + * handlers = { + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * @endcode * * @section bundle Defining a content entity bundle * For entity types that use bundles, such as Node (bundles are content types) diff --git a/core/lib/Drupal/Core/EventSubscriber/ActiveLinkResponseFilter.php b/core/lib/Drupal/Core/EventSubscriber/ActiveLinkResponseFilter.php index d2da0fd66..0d8d9da0c 100644 --- a/core/lib/Drupal/Core/EventSubscriber/ActiveLinkResponseFilter.php +++ b/core/lib/Drupal/Core/EventSubscriber/ActiveLinkResponseFilter.php @@ -12,9 +12,7 @@ use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Core\Path\CurrentPathStack; use Drupal\Core\Path\PathMatcherInterface; -use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\Core\Url; use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\HttpKernel\Event\FilterResponseEvent; use Symfony\Component\HttpKernel\KernelEvents; diff --git a/core/lib/Drupal/Core/EventSubscriber/AnonymousUserResponseSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/AnonymousUserResponseSubscriber.php index f73437afb..1efc7170f 100644 --- a/core/lib/Drupal/Core/EventSubscriber/AnonymousUserResponseSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/AnonymousUserResponseSubscriber.php @@ -11,7 +11,6 @@ use Drupal\Core\Cache\CacheableResponseInterface; use Drupal\Core\Session\AccountInterface; use Symfony\Component\HttpKernel\Event\FilterResponseEvent; -use Symfony\Component\HttpKernel\HttpKernelInterface; use Symfony\Component\HttpKernel\KernelEvents; use Symfony\Component\EventDispatcher\EventSubscriberInterface; diff --git a/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php index 0acda56ef..da6327d55 100644 --- a/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php @@ -15,7 +15,6 @@ use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Render\RenderContext; use Drupal\Core\Render\RendererInterface; -use Drupal\Core\Routing\RouteMatchInterface; use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\HttpKernel\Event\FilterControllerEvent; use Symfony\Component\HttpKernel\KernelEvents; diff --git a/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php index d5c4def45..326c9984c 100644 --- a/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php @@ -48,12 +48,14 @@ public function onDynamicRouteEvent(RouteBuildEvent $event) { foreach ($this->entityManager->getRouteProviders($entity_type->id()) as $route_provider) { // Allow to both return an array of routes or a route collection, // like route_callbacks in the routing.yml file. + $routes = $route_provider->getRoutes($entity_type); if ($routes instanceof RouteCollection) { - $route_collection->addCollection($routes); + $routes = $routes->all(); } - elseif (is_array($routes)) { - foreach ($routes as $route_name => $route) { + foreach ($routes as $route_name => $route) { + // Don't override existing routes. + if (!$route_collection->get($route_name)) { $route_collection->add($route_name, $route); } } diff --git a/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php index f7d513b09..a373688bb 100644 --- a/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php @@ -10,19 +10,15 @@ use Drupal\Component\Datetime\DateTimePlus; use Drupal\Core\Cache\CacheableResponseInterface; use Drupal\Core\Cache\Context\CacheContextsManager; -use Drupal\Core\Config\Config; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Core\PageCache\RequestPolicyInterface; use Drupal\Core\PageCache\ResponsePolicyInterface; use Drupal\Core\Site\Settings; -use Symfony\Component\HttpFoundation\BinaryFileResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; -use Symfony\Component\HttpFoundation\StreamedResponse; use Symfony\Component\HttpKernel\Event\FilterResponseEvent; use Symfony\Component\HttpKernel\KernelEvents; -use Symfony\Component\HttpKernel\HttpKernelInterface; use Symfony\Component\EventDispatcher\EventSubscriberInterface; /** @@ -65,6 +61,13 @@ class FinishResponseSubscriber implements EventSubscriberInterface { */ protected $cacheContexts; + /** + * Whether to send cacheability headers for debugging purposes. + * + * @var bool + */ + protected $debugCacheabilityHeaders = FALSE; + /** * Constructs a FinishResponseSubscriber object. * @@ -78,13 +81,16 @@ class FinishResponseSubscriber implements EventSubscriberInterface { * A policy rule determining the cacheability of a response. * @param \Drupal\Core\Cache\Context\CacheContextsManager $cache_contexts_manager * The cache contexts manager service. + * @param bool $http_response_debug_cacheability_headers + * (optional) Whether to send cacheability headers for debugging purposes. */ - public function __construct(LanguageManagerInterface $language_manager, ConfigFactoryInterface $config_factory, RequestPolicyInterface $request_policy, ResponsePolicyInterface $response_policy, CacheContextsManager $cache_contexts_manager) { + public function __construct(LanguageManagerInterface $language_manager, ConfigFactoryInterface $config_factory, RequestPolicyInterface $request_policy, ResponsePolicyInterface $response_policy, CacheContextsManager $cache_contexts_manager, $http_response_debug_cacheability_headers = FALSE) { $this->languageManager = $language_manager; $this->config = $config_factory->get('system.performance'); $this->requestPolicy = $request_policy; $this->responsePolicy = $response_policy; $this->cacheContextsManager = $cache_contexts_manager; + $this->debugCacheabilityHeaders = $http_response_debug_cacheability_headers; } /** @@ -134,11 +140,13 @@ public function onRespond(FilterResponseEvent $event) { return; } - // Expose the cache contexts and cache tags associated with this page in a - // X-Drupal-Cache-Contexts and X-Drupal-Cache-Tags header respectively. - $response_cacheability = $response->getCacheableMetadata(); - $response->headers->set('X-Drupal-Cache-Tags', implode(' ', $response_cacheability->getCacheTags())); - $response->headers->set('X-Drupal-Cache-Contexts', implode(' ', $this->cacheContextsManager->optimizeTokens($response_cacheability->getCacheContexts()))); + if ($this->debugCacheabilityHeaders) { + // Expose the cache contexts and cache tags associated with this page in a + // X-Drupal-Cache-Contexts and X-Drupal-Cache-Tags header respectively. + $response_cacheability = $response->getCacheableMetadata(); + $response->headers->set('X-Drupal-Cache-Tags', implode(' ', $response_cacheability->getCacheTags())); + $response->headers->set('X-Drupal-Cache-Contexts', implode(' ', $this->cacheContextsManager->optimizeTokens($response_cacheability->getCacheContexts()))); + } $is_cacheable = ($this->requestPolicy->check($request) === RequestPolicyInterface::ALLOW) && ($this->responsePolicy->check($response, $request) !== ResponsePolicyInterface::DENY); diff --git a/core/lib/Drupal/Core/EventSubscriber/HttpExceptionSubscriberBase.php b/core/lib/Drupal/Core/EventSubscriber/HttpExceptionSubscriberBase.php index 6fcacc944..13685f0d7 100644 --- a/core/lib/Drupal/Core/EventSubscriber/HttpExceptionSubscriberBase.php +++ b/core/lib/Drupal/Core/EventSubscriber/HttpExceptionSubscriberBase.php @@ -56,7 +56,7 @@ abstract class HttpExceptionSubscriberBase implements EventSubscriberInterface { * * @return array * An indexed array of the format machine names that this subscriber will - * attempt ot process,such as "html" or "json". Returning an empty array + * attempt to process, such as "html" or "json". Returning an empty array * will apply to all formats. * * @see \Symfony\Component\HttpFoundation\Request diff --git a/core/lib/Drupal/Core/EventSubscriber/PathRootsSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/PathRootsSubscriber.php index 8d967672d..7b2cc7c99 100644 --- a/core/lib/Drupal/Core/EventSubscriber/PathRootsSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/PathRootsSubscriber.php @@ -11,7 +11,6 @@ use Drupal\Core\Routing\RouteBuildEvent; use Drupal\Core\Routing\RoutingEvents; use Symfony\Component\EventDispatcher\EventSubscriberInterface; -use Symfony\Component\Routing\RouteCollection; /** * Provides all available first bits of all route paths. diff --git a/core/lib/Drupal/Core/EventSubscriber/RedirectLeadingSlashesSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/RedirectLeadingSlashesSubscriber.php index 51ebbc22d..84bdda1d2 100644 --- a/core/lib/Drupal/Core/EventSubscriber/RedirectLeadingSlashesSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/RedirectLeadingSlashesSubscriber.php @@ -7,7 +7,7 @@ namespace Drupal\Core\EventSubscriber; -use Symfony\Component\HttpFoundation\RedirectResponse; +use Drupal\Core\Cache\CacheableRedirectResponse; use Symfony\Component\HttpKernel\Event\GetResponseEvent; use Symfony\Component\HttpKernel\KernelEvents; use Symfony\Component\EventDispatcher\EventSubscriberInterface; @@ -39,7 +39,7 @@ public function redirect(GetResponseEvent $event) { if ($qs) { $qs = '?' . $qs; } - $event->setResponse(new RedirectResponse($request->getUriForPath($path) . $qs)); + $event->setResponse(new CacheableRedirectResponse($request->getUriForPath($path) . $qs)); } } diff --git a/core/lib/Drupal/Core/EventSubscriber/RedirectResponseSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/RedirectResponseSubscriber.php index 09540eada..435246d71 100644 --- a/core/lib/Drupal/Core/EventSubscriber/RedirectResponseSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/RedirectResponseSubscriber.php @@ -52,7 +52,7 @@ public function __construct(UnroutedUrlAssemblerInterface $url_assembler, Reques */ public function checkRedirectUrl(FilterResponseEvent $event) { $response = $event->getResponse(); - if ($response instanceOf RedirectResponse) { + if ($response instanceof RedirectResponse) { $request = $event->getRequest(); // Let the 'destination' query parameter override the redirect target. @@ -71,7 +71,7 @@ public function checkRedirectUrl(FilterResponseEvent $event) { // Regardless of whether the target is the original one or the overridden // destination, ensure that all redirects are safe. - if (!($response instanceOf SecuredRedirectResponse)) { + if (!($response instanceof SecuredRedirectResponse)) { try { // SecuredRedirectResponse is an abstract class that requires a // concrete implementation. Default to LocalRedirectResponse, which diff --git a/core/lib/Drupal/Core/EventSubscriber/RouterRebuildSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/RouterRebuildSubscriber.php index 584b141f2..9ada39ce3 100644 --- a/core/lib/Drupal/Core/EventSubscriber/RouterRebuildSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/RouterRebuildSubscriber.php @@ -7,11 +7,7 @@ namespace Drupal\Core\EventSubscriber; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Lock\LockBackendInterface; use Drupal\Core\Routing\RouteBuilderInterface; -use Drupal\Core\Routing\RoutingEvents; -use Symfony\Component\EventDispatcher\Event; use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\HttpKernel\Event\PostResponseEvent; use Symfony\Component\HttpKernel\KernelEvents; diff --git a/core/lib/Drupal/Core/Executable/ExecutablePluginBase.php b/core/lib/Drupal/Core/Executable/ExecutablePluginBase.php index c438e1d6e..ac075729e 100644 --- a/core/lib/Drupal/Core/Executable/ExecutablePluginBase.php +++ b/core/lib/Drupal/Core/Executable/ExecutablePluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Executable; use Drupal\Core\Plugin\ContextAwarePluginBase; -use Symfony\Component\Validator\Validation; use Drupal\Component\Plugin\Exception\PluginException; /** diff --git a/core/lib/Drupal/Core/Extension/ModuleHandler.php b/core/lib/Drupal/Core/Extension/ModuleHandler.php index f97897c18..b9a9a3e49 100644 --- a/core/lib/Drupal/Core/Extension/ModuleHandler.php +++ b/core/lib/Drupal/Core/Extension/ModuleHandler.php @@ -9,7 +9,6 @@ use Drupal\Component\Graph\Graph; use Drupal\Component\Utility\NestedArray; -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheBackendInterface; /** diff --git a/core/lib/Drupal/Core/Extension/module.api.php b/core/lib/Drupal/Core/Extension/module.api.php index 414e517bc..7d13f745d 100644 --- a/core/lib/Drupal/Core/Extension/module.api.php +++ b/core/lib/Drupal/Core/Extension/module.api.php @@ -6,7 +6,6 @@ */ use Drupal\Core\Database\Database; -use Drupal\Core\Field\BaseFieldDefinition; use Drupal\Core\Url; use Drupal\Core\Utility\UpdateException; diff --git a/core/lib/Drupal/Core/Field/FieldConfigBase.php b/core/lib/Drupal/Core/Field/FieldConfigBase.php index e3728be01..c7b98fd08 100644 --- a/core/lib/Drupal/Core/Field/FieldConfigBase.php +++ b/core/lib/Drupal/Core/Field/FieldConfigBase.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Field; -use Drupal\Component\Plugin\DependentPluginInterface; use Drupal\Core\Config\Entity\ConfigEntityBase; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\FieldableEntityInterface; @@ -252,9 +251,12 @@ public function calculateDependencies() { * {@inheritdoc} */ public function onDependencyRemoval(array $dependencies) { + $changed = parent::onDependencyRemoval($dependencies); $field_type_manager = \Drupal::service('plugin.manager.field.field_type'); $definition = $field_type_manager->getDefinition($this->getType()); - $changed = $definition['class']::onDependencyRemoval($this, $dependencies); + if ($definition['class']::onDependencyRemoval($this, $dependencies)) { + $changed = TRUE; + } return $changed; } diff --git a/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php b/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php index 78900a924..8dcadca69 100644 --- a/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php +++ b/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php @@ -10,7 +10,6 @@ use Drupal\Component\Utility\Html; use Drupal\Component\Render\MarkupInterface; use Drupal\Component\Render\MarkupTrait; -use Drupal\Component\Utility\Unicode; use Drupal\Component\Utility\Xss; /** diff --git a/core/lib/Drupal/Core/Field/FormatterInterface.php b/core/lib/Drupal/Core/Field/FormatterInterface.php index a60ffa65f..149438c3e 100644 --- a/core/lib/Drupal/Core/Field/FormatterInterface.php +++ b/core/lib/Drupal/Core/Field/FormatterInterface.php @@ -39,7 +39,7 @@ public function settingsForm(array $form, FormStateInterface $form_state); * If an empty result is returned, a UI can still be provided to display * a settings form in case the formatter has configurable settings. * - * @return array() + * @return string[] * A short summary of the formatter settings. */ public function settingsSummary(); diff --git a/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceEntityFormatter.php b/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceEntityFormatter.php index b98fc4502..8a4a60279 100644 --- a/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceEntityFormatter.php +++ b/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceEntityFormatter.php @@ -10,7 +10,6 @@ use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Logger\LoggerChannelFactoryInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceIdFormatter.php b/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceIdFormatter.php index 3b58c68f3..2cf8c2075 100644 --- a/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceIdFormatter.php +++ b/core/lib/Drupal/Core/Field/Plugin/Field/FieldFormatter/EntityReferenceIdFormatter.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Field\Plugin\Field\FieldFormatter; use Drupal\Core\Field\FieldItemListInterface; -use Drupal\Core\Language\LanguageInterface; /** * Plugin implementation of the 'entity reference ID' formatter. diff --git a/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/MapItem.php b/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/MapItem.php index 5ccc6d295..cd4887879 100644 --- a/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/MapItem.php +++ b/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/MapItem.php @@ -9,7 +9,6 @@ use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\Core\Field\FieldItemBase; -use Drupal\Core\TypedData\DataDefinition; /** * Defines the 'map' entity field type. diff --git a/core/lib/Drupal/Core/Form/ConfigFormBase.php b/core/lib/Drupal/Core/Form/ConfigFormBase.php index 5ed650a61..ee50389b8 100644 --- a/core/lib/Drupal/Core/Form/ConfigFormBase.php +++ b/core/lib/Drupal/Core/Form/ConfigFormBase.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Form; use Drupal\Core\Config\ConfigFactoryInterface; -use Drupal\Core\Form\FormBase; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/lib/Drupal/Core/Form/FormCache.php b/core/lib/Drupal/Core/Form/FormCache.php index b091ed8c7..63273d6cc 100644 --- a/core/lib/Drupal/Core/Form/FormCache.php +++ b/core/lib/Drupal/Core/Form/FormCache.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Form; use Drupal\Component\Utility\Crypt; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Access\CsrfTokenGenerator; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\KeyValueStore\KeyValueExpirableFactoryInterface; diff --git a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitBase.php b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitBase.php index 4481af3ea..eab55c125 100644 --- a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitBase.php +++ b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitBase.php @@ -10,7 +10,6 @@ use Drupal\Component\Plugin\Exception\PluginNotFoundException; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Image\ImageInterface; use Drupal\Core\Plugin\PluginBase; use Psr\Log\LoggerInterface; diff --git a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitInterface.php b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitInterface.php index 1cf350e28..c7b064cca 100644 --- a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitInterface.php +++ b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitInterface.php @@ -9,7 +9,6 @@ use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Plugin\PluginFormInterface; -use Drupal\Core\Image\ImageInterface; use Drupal\Component\Plugin\PluginInspectionInterface; /** diff --git a/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseExpirableFactory.php b/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseExpirableFactory.php index ff9fb14c7..583bcf086 100644 --- a/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseExpirableFactory.php +++ b/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseExpirableFactory.php @@ -8,7 +8,6 @@ namespace Drupal\Core\KeyValueStore; use Drupal\Component\Serialization\SerializationInterface; -use Drupal\Core\DestructableInterface; use Drupal\Core\Database\Connection; /** diff --git a/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseFactory.php b/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseFactory.php index fda143dc5..a35d97997 100644 --- a/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseFactory.php +++ b/core/lib/Drupal/Core/KeyValueStore/KeyValueDatabaseFactory.php @@ -9,7 +9,6 @@ use Drupal\Component\Serialization\SerializationInterface; use Drupal\Core\Database\Connection; -use Drupal\Core\Database\Database; /** * Defines the key/value store factory for the database backend. diff --git a/core/lib/Drupal/Core/KeyValueStore/KeyValueExpirableFactory.php b/core/lib/Drupal/Core/KeyValueStore/KeyValueExpirableFactory.php index 0c7b0a550..50eafe729 100644 --- a/core/lib/Drupal/Core/KeyValueStore/KeyValueExpirableFactory.php +++ b/core/lib/Drupal/Core/KeyValueStore/KeyValueExpirableFactory.php @@ -7,8 +7,6 @@ namespace Drupal\Core\KeyValueStore; -use Symfony\Component\DependencyInjection\ContainerInterface; - /** * Defines the key/value store factory. */ diff --git a/core/lib/Drupal/Core/Language/LanguageManagerInterface.php b/core/lib/Drupal/Core/Language/LanguageManagerInterface.php index 950fc6989..ef5fcbdbd 100644 --- a/core/lib/Drupal/Core/Language/LanguageManagerInterface.php +++ b/core/lib/Drupal/Core/Language/LanguageManagerInterface.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Language; -use Drupal\Core\StringTranslation\TranslationInterface; use Drupal\Core\Url; /** diff --git a/core/lib/Drupal/Core/Menu/LocalTaskInterface.php b/core/lib/Drupal/Core/Menu/LocalTaskInterface.php index 58987105c..23dd4eb4d 100644 --- a/core/lib/Drupal/Core/Menu/LocalTaskInterface.php +++ b/core/lib/Drupal/Core/Menu/LocalTaskInterface.php @@ -12,9 +12,9 @@ /** * Defines an interface for menu local tasks. * - * Menu local tasks are are typically rendered as navigation tabs above the - * content region, though other presentations are possible. It is convention - * that the titles of these tasks should be short verbs if possible. + * Menu local tasks are typically rendered as navigation tabs above the content + * region, though other presentations are possible. It is convention that the + * titles of these tasks should be short verbs if possible. * * @see \Drupal\Core\Menu\LocalTaskManagerInterface */ diff --git a/core/lib/Drupal/Core/Menu/MenuLinkInterface.php b/core/lib/Drupal/Core/Menu/MenuLinkInterface.php index da5ca3966..4722e381f 100644 --- a/core/lib/Drupal/Core/Menu/MenuLinkInterface.php +++ b/core/lib/Drupal/Core/Menu/MenuLinkInterface.php @@ -131,7 +131,7 @@ public function getRouteParameters(); * the description is not empty. * * @return \Drupal\Core\Url - * A a URL object containing either the external path or route. + * A URL object containing either the external path or route. */ public function getUrlObject($title_attribute = TRUE); diff --git a/core/lib/Drupal/Core/Menu/MenuLinkTree.php b/core/lib/Drupal/Core/Menu/MenuLinkTree.php index 6307c4970..5b3aee85f 100644 --- a/core/lib/Drupal/Core/Menu/MenuLinkTree.php +++ b/core/lib/Drupal/Core/Menu/MenuLinkTree.php @@ -10,9 +10,7 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Core\Access\AccessResultInterface; use Drupal\Core\Cache\CacheableMetadata; -use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Controller\ControllerResolverInterface; -use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\Template\Attribute; diff --git a/core/lib/Drupal/Core/Menu/Plugin/Block/LocalActionsBlock.php b/core/lib/Drupal/Core/Menu/Plugin/Block/LocalActionsBlock.php index 7b1dc3a55..42a79fc43 100644 --- a/core/lib/Drupal/Core/Menu/Plugin/Block/LocalActionsBlock.php +++ b/core/lib/Drupal/Core/Menu/Plugin/Block/LocalActionsBlock.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Menu\Plugin\Block; use Drupal\Core\Block\BlockBase; -use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Menu\LocalActionManagerInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/lib/Drupal/Core/Menu/menu.api.php b/core/lib/Drupal/Core/Menu/menu.api.php index b37fa61e5..af33b326c 100644 --- a/core/lib/Drupal/Core/Menu/menu.api.php +++ b/core/lib/Drupal/Core/Menu/menu.api.php @@ -297,7 +297,7 @@ function hook_menu_links_discovered_alter(&$links) { * * @param array $data * An associative array containing list of (up to 2) tab levels that contain a - * list of of tabs keyed by their href, each one being an associative array + * list of tabs keyed by their href, each one being an associative array * as described above. * @param string $route_name * The route name of the page. diff --git a/core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php b/core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php index 997749f5c..1c515d26c 100644 --- a/core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php +++ b/core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php @@ -7,8 +7,6 @@ namespace Drupal\Core\ParamConverter; -use Symfony\Component\DependencyInjection\ContainerAwareInterface; -use Symfony\Component\DependencyInjection\ContainerAwareTrait; use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\Routing\RouteCollection; diff --git a/core/lib/Drupal/Core/Path/AliasManager.php b/core/lib/Drupal/Core/Path/AliasManager.php index 9fe0e2c8b..c201e0b1b 100644 --- a/core/lib/Drupal/Core/Path/AliasManager.php +++ b/core/lib/Drupal/Core/Path/AliasManager.php @@ -145,10 +145,8 @@ public function writeCache() { } } - if (!empty($path_lookups)) { - $twenty_four_hours = 60 * 60 * 24; - $this->cache->set($this->cacheKey, $path_lookups, $this->getRequestTime() + $twenty_four_hours); - } + $twenty_four_hours = 60 * 60 * 24; + $this->cache->set($this->cacheKey, $path_lookups, $this->getRequestTime() + $twenty_four_hours); } } @@ -175,7 +173,6 @@ public function getPathByAlias($alias, $langcode = NULL) { // Look for path in storage. if ($path = $this->storage->lookupPathSource($alias, $langcode)) { $this->lookupMap[$langcode][$path] = $alias; - $this->cacheNeedsWriting = TRUE; return $path; } @@ -216,8 +213,13 @@ public function getAliasByPath($path, $langcode = NULL) { // happens if a cache key has been set. if ($this->preloadedPathLookups === FALSE) { $this->preloadedPathLookups = array(); - if ($this->cacheKey && $cached = $this->cache->get($this->cacheKey)) { - $this->preloadedPathLookups = $cached->data; + if ($this->cacheKey) { + if ($cached = $this->cache->get($this->cacheKey)) { + $this->preloadedPathLookups = $cached->data; + } + else { + $this->cacheNeedsWriting = TRUE; + } } } @@ -242,14 +244,12 @@ public function getAliasByPath($path, $langcode = NULL) { // Try to load alias from storage. if ($alias = $this->storage->lookupPathAlias($path, $langcode)) { $this->lookupMap[$langcode][$path] = $alias; - $this->cacheNeedsWriting = TRUE; return $alias; } // We can't record anything into $this->lookupMap because we didn't find any // aliases for this path. Thus cache to $this->noAlias. $this->noAlias[$langcode][$path] = TRUE; - $this->cacheNeedsWriting = TRUE; return $path; } diff --git a/core/lib/Drupal/Core/Path/AliasWhitelist.php b/core/lib/Drupal/Core/Path/AliasWhitelist.php index fc26b77eb..dff0c9d2b 100644 --- a/core/lib/Drupal/Core/Path/AliasWhitelist.php +++ b/core/lib/Drupal/Core/Path/AliasWhitelist.php @@ -9,7 +9,6 @@ use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Cache\CacheCollector; -use Drupal\Core\Database\Connection; use Drupal\Core\State\StateInterface; use Drupal\Core\Lock\LockBackendInterface; diff --git a/core/lib/Drupal/Core/Plugin/CachedDiscoveryClearer.php b/core/lib/Drupal/Core/Plugin/CachedDiscoveryClearer.php index 2001eea00..7275a0e81 100644 --- a/core/lib/Drupal/Core/Plugin/CachedDiscoveryClearer.php +++ b/core/lib/Drupal/Core/Plugin/CachedDiscoveryClearer.php @@ -8,8 +8,6 @@ namespace Drupal\Core\Plugin; use Drupal\Component\Plugin\Discovery\CachedDiscoveryInterface; -use Drupal\Component\Plugin\Exception\PluginException; -use Drupal\Component\Plugin\PluginManagerInterface; /** * Defines a class which is capable of clearing the cache on plugin managers. diff --git a/core/lib/Drupal/Core/Render/Element/Button.php b/core/lib/Drupal/Core/Render/Element/Button.php index a64615744..29ed48a06 100644 --- a/core/lib/Drupal/Core/Render/Element/Button.php +++ b/core/lib/Drupal/Core/Render/Element/Button.php @@ -16,6 +16,23 @@ * When the button is pressed, the form will be submitted to Drupal, where it is * validated and rebuilt. The submit handler is not invoked. * + * Properties: + * - #limit_validation_errors: An array of form element keys that will block + * form submission when validation for these elements or any child elements + * fails. Specify an empty array to suppress all form validation errors. + * - #value: The text to be shown on the button. + * + * + * Usage Example: + * @code + * $form['actions']['preview'] = array( + * '#type' => 'button', + * '#value => $this->t('Preview'), + * ); + * @endcode + * + * @see \Drupal\Core\Render\Element\Submit + * * @FormElement("button") */ class Button extends FormElement { diff --git a/core/lib/Drupal/Core/Render/Element/Details.php b/core/lib/Drupal/Core/Render/Element/Details.php index a7fab3524..afdd445e1 100644 --- a/core/lib/Drupal/Core/Render/Element/Details.php +++ b/core/lib/Drupal/Core/Render/Element/Details.php @@ -13,7 +13,7 @@ * Provides a render element for a details element, similar to a fieldset. * * Fieldsets can only be used in forms, while details elements can be used - * outside of forms. Users click on the the title to open or close the details + * outside of forms. Users click on the title to open or close the details * element, showing or hiding the contained elements. * * Properties: diff --git a/core/lib/Drupal/Core/Render/Element/Dropbutton.php b/core/lib/Drupal/Core/Render/Element/Dropbutton.php index 76fab8960..f84d7044f 100644 --- a/core/lib/Drupal/Core/Render/Element/Dropbutton.php +++ b/core/lib/Drupal/Core/Render/Element/Dropbutton.php @@ -10,6 +10,36 @@ /** * Provides a render element for a set of links rendered as a drop-down button. * + * By default, this element sets #theme so that the 'links' theme hook is used + * for rendering, with suffixes so that themes can override this specifically + * without overriding all links theming. If the #subtype property is provided in + * your render array with value 'foo', #theme is set to links__dropbutton__foo; + * if not, it's links__dropbutton; both of these can be overridden by setting + * the #theme property in your render array. See template_preprocess_links() + * for documentation on the other properties used in theming; for instance, use + * element property #links to provide $variables['links'] for theming. + * + * Properties: + * - #links: An array of links to actions. See template_preprocess_links() for + * documentation the properties of links in this array. + * + * Usage Example: + * @code + * $form['actions']['extra_actions'] = array( + * '#type' => 'dropbutton', + * '#links' => array( + * 'simple_form' => array( + * 'title' => $this->t('Simple Form'), + * 'url' => Url::fromRoute('fapi_example.simple_form'), + * ), + * 'demo' => array( + * 'title' => $this->t('Build Demo'), + * 'url' => Url::fromRoute('fapi_example.build_demo'), + * ), + * ), + * ); + * @endcode + * * @see \Drupal\Core\Render\Element\Operations * * @RenderElement("dropbutton") diff --git a/core/lib/Drupal/Core/Render/Element/Hidden.php b/core/lib/Drupal/Core/Render/Element/Hidden.php index 0da3405e0..7bd10b949 100644 --- a/core/lib/Drupal/Core/Render/Element/Hidden.php +++ b/core/lib/Drupal/Core/Render/Element/Hidden.php @@ -12,6 +12,19 @@ /** * Provides a form element for an HTML 'hidden' input element. * + * Specify either #default_value or #value but not both. + * + * Properties: + * - #default_value: The initial value of the form element. JavaScript may + * alter the value prior to submission. + * - #value: The value of the form element. The Form API ensures that this + * value remains unchanged by the browser. + * + * Usage example: + * @code + * $form['entity_id'] = array('#type' => 'hidden', '#value' => $entity_id); + * @endcode + * * @see \Drupal\Core\Render\Element\Value * * @FormElement("hidden") diff --git a/core/lib/Drupal/Core/Render/Element/Link.php b/core/lib/Drupal/Core/Render/Element/Link.php index baa279e85..8f908d2ee 100644 --- a/core/lib/Drupal/Core/Render/Element/Link.php +++ b/core/lib/Drupal/Core/Render/Element/Link.php @@ -9,7 +9,6 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Component\Utility\Html as HtmlUtility; -use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Url as CoreUrl; diff --git a/core/lib/Drupal/Core/Render/Element/Operations.php b/core/lib/Drupal/Core/Render/Element/Operations.php index 89bc68b72..dd3e3c9d7 100644 --- a/core/lib/Drupal/Core/Render/Element/Operations.php +++ b/core/lib/Drupal/Core/Render/Element/Operations.php @@ -14,6 +14,8 @@ * difference is that it offers themes the possibility to render it differently * through a theme suggestion. * + * @see \Drupal|Core\Render\Element\DropButton + * * @RenderElement("operations") */ class Operations extends Dropbutton { diff --git a/core/lib/Drupal/Core/Render/Element/Submit.php b/core/lib/Drupal/Core/Render/Element/Submit.php index 41e592d3b..8b2622730 100644 --- a/core/lib/Drupal/Core/Render/Element/Submit.php +++ b/core/lib/Drupal/Core/Render/Element/Submit.php @@ -13,6 +13,22 @@ * Submit buttons are processed the same as regular buttons, except they trigger * the form's submit handler. * + * Properties: + * - #submit: Specifies an alternate callback for form submission when the + * submit button is pressed. Use '::methodName' format or an array containing + * the object and method name (for example, [ $this, 'methodName'] ). + * - #value: The text to be shown on the button. + * + * Usage Example: + * @code + * $form['actions']['submit'] = array( + * '#type' => 'submit, + * '#value' => $this->t('Save'), + * ); + * @endcode + * + * @see \Drupal\Core\Render\Element\Button + * * @FormElement("submit") */ class Submit extends Button { diff --git a/core/lib/Drupal/Core/Render/Element/Value.php b/core/lib/Drupal/Core/Render/Element/Value.php index 5da3e0c9b..689e7548e 100644 --- a/core/lib/Drupal/Core/Render/Element/Value.php +++ b/core/lib/Drupal/Core/Render/Element/Value.php @@ -10,9 +10,17 @@ /** * Provides a form element for storage of internal information. * - * Unlike \Drupal\Core\Render\Element\Hidden, this information is not - * sent to the browser in a hidden form field, but is just stored in the form - * array for use in validation and submit processing. + * Unlike \Drupal\Core\Render\Element\Hidden, this information is not sent to + * the browser in a hidden form field, but only stored in the form array for use + * in validation and submit processing. + * + * Properties: + * - #value: The value of the form element that cannot be edited by the user. + * + * Usage Example: + * @code + * $form['entity_id'] = array('#type' => 'value', '#value' => $entity_id); + * @endcode * * @FormElement("value") */ diff --git a/core/lib/Drupal/Core/Render/HtmlResponseAttachmentsProcessor.php b/core/lib/Drupal/Core/Render/HtmlResponseAttachmentsProcessor.php index b9cbc812e..e0160d1b4 100644 --- a/core/lib/Drupal/Core/Render/HtmlResponseAttachmentsProcessor.php +++ b/core/lib/Drupal/Core/Render/HtmlResponseAttachmentsProcessor.php @@ -12,9 +12,7 @@ use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Form\EnforcedResponseException; use Drupal\Core\Extension\ModuleHandlerInterface; -use Drupal\Core\Render\BubbleableMetadata; use Drupal\Component\Utility\Html; -use Drupal\Component\Utility\SafeMarkup; use Symfony\Component\HttpFoundation\RequestStack; /** diff --git a/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php b/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php index 4a4ab59bc..767087627 100644 --- a/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php +++ b/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php @@ -13,7 +13,6 @@ use Drupal\Core\Display\PageVariantInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Display\ContextAwareVariantInterface; -use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Render\HtmlResponse; use Drupal\Core\Render\PageDisplayVariantSelectionEvent; use Drupal\Core\Render\RenderCacheInterface; diff --git a/core/lib/Drupal/Core/Render/MainContent/ModalRenderer.php b/core/lib/Drupal/Core/Render/MainContent/ModalRenderer.php index 945a76c67..8f2ef17d1 100644 --- a/core/lib/Drupal/Core/Render/MainContent/ModalRenderer.php +++ b/core/lib/Drupal/Core/Render/MainContent/ModalRenderer.php @@ -9,7 +9,6 @@ use Drupal\Core\Ajax\AjaxResponse; use Drupal\Core\Ajax\OpenModalDialogCommand; -use Drupal\Core\Render\MainContent\DialogRenderer; use Drupal\Core\Routing\RouteMatchInterface; use Symfony\Component\HttpFoundation\Request; diff --git a/core/lib/Drupal/Core/RouteProcessor/RouteProcessorCurrent.php b/core/lib/Drupal/Core/RouteProcessor/RouteProcessorCurrent.php index 0dbfcaa77..11299afc9 100644 --- a/core/lib/Drupal/Core/RouteProcessor/RouteProcessorCurrent.php +++ b/core/lib/Drupal/Core/RouteProcessor/RouteProcessorCurrent.php @@ -7,7 +7,6 @@ namespace Drupal\Core\RouteProcessor; -use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Routing\RouteMatchInterface; use Symfony\Component\Routing\Route; diff --git a/core/lib/Drupal/Core/Routing/CacheableSecuredRedirectResponse.php b/core/lib/Drupal/Core/Routing/CacheableSecuredRedirectResponse.php new file mode 100644 index 000000000..c8d024416 --- /dev/null +++ b/core/lib/Drupal/Core/Routing/CacheableSecuredRedirectResponse.php @@ -0,0 +1,37 @@ +getCacheableMetadata(); + if ($response instanceof CacheableResponseInterface) { + $metadata->addCacheableDependency($response->getCacheableMetadata()); + } + else { + $metadata->setCacheMaxAge(0); + } + } + +} diff --git a/core/lib/Drupal/Core/Routing/LinkGeneratorTrait.php b/core/lib/Drupal/Core/Routing/LinkGeneratorTrait.php index 1dcb34370..dc2c9de07 100644 --- a/core/lib/Drupal/Core/Routing/LinkGeneratorTrait.php +++ b/core/lib/Drupal/Core/Routing/LinkGeneratorTrait.php @@ -10,7 +10,6 @@ use Drupal\Core\Url; use Drupal\Core\Utility\LinkGeneratorInterface; -use Drupal\Core\Routing\UrlGeneratorInterface; /** * Wrapper methods for the Link Generator. diff --git a/core/lib/Drupal/Core/Routing/LocalRedirectResponse.php b/core/lib/Drupal/Core/Routing/LocalRedirectResponse.php index d8ad719bc..4d0e275ae 100644 --- a/core/lib/Drupal/Core/Routing/LocalRedirectResponse.php +++ b/core/lib/Drupal/Core/Routing/LocalRedirectResponse.php @@ -7,12 +7,10 @@ namespace Drupal\Core\Routing; -use Drupal\Component\HttpFoundation\SecuredRedirectResponse; - /** * Provides a redirect response which cannot redirect to an external URL. */ -class LocalRedirectResponse extends SecuredRedirectResponse { +class LocalRedirectResponse extends CacheableSecuredRedirectResponse { use LocalAwareRedirectResponseTrait { LocalAwareRedirectResponseTrait::isLocal as isSafe; diff --git a/core/lib/Drupal/Core/Routing/RouteProvider.php b/core/lib/Drupal/Core/Routing/RouteProvider.php index 58b8320b4..937cff71f 100644 --- a/core/lib/Drupal/Core/Routing/RouteProvider.php +++ b/core/lib/Drupal/Core/Routing/RouteProvider.php @@ -19,8 +19,6 @@ use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\Exception\RouteNotFoundException; use Symfony\Component\Routing\RouteCollection; -use Symfony\Component\Routing\Exception\ResourceNotFoundException; - use \Drupal\Core\Database\Connection; /** diff --git a/core/lib/Drupal/Core/Routing/RouteProviderInterface.php b/core/lib/Drupal/Core/Routing/RouteProviderInterface.php index 8c8e3561d..03dcb0401 100644 --- a/core/lib/Drupal/Core/Routing/RouteProviderInterface.php +++ b/core/lib/Drupal/Core/Routing/RouteProviderInterface.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Routing; use Symfony\Cmf\Component\Routing\RouteProviderInterface as RouteProviderBaseInterface; -use Symfony\Component\Routing\RouteCollection; /** * Extends the router provider interface diff --git a/core/lib/Drupal/Core/Routing/RouteSubscriberBase.php b/core/lib/Drupal/Core/Routing/RouteSubscriberBase.php index 757c8c118..f26a2e80c 100644 --- a/core/lib/Drupal/Core/Routing/RouteSubscriberBase.php +++ b/core/lib/Drupal/Core/Routing/RouteSubscriberBase.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Routing; -use Drupal\Core\Routing\RoutingEvents; use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\Routing\RouteCollection; diff --git a/core/lib/Drupal/Core/Routing/TrustedRedirectResponse.php b/core/lib/Drupal/Core/Routing/TrustedRedirectResponse.php index c7a43a21c..3beb17646 100644 --- a/core/lib/Drupal/Core/Routing/TrustedRedirectResponse.php +++ b/core/lib/Drupal/Core/Routing/TrustedRedirectResponse.php @@ -7,14 +7,12 @@ namespace Drupal\Core\Routing; -use Drupal\Component\HttpFoundation\SecuredRedirectResponse; - /** * Provides a redirect response which contains trusted URLs. * * Use this class in case you know that you want to redirect to an external URL. */ -class TrustedRedirectResponse extends SecuredRedirectResponse { +class TrustedRedirectResponse extends CacheableSecuredRedirectResponse { use LocalAwareRedirectResponseTrait; diff --git a/core/lib/Drupal/Core/Routing/UrlGenerator.php b/core/lib/Drupal/Core/Routing/UrlGenerator.php index cf6607a35..f3d1275b2 100644 --- a/core/lib/Drupal/Core/Routing/UrlGenerator.php +++ b/core/lib/Drupal/Core/Routing/UrlGenerator.php @@ -14,7 +14,6 @@ use Symfony\Component\Routing\Route as SymfonyRoute; use Symfony\Component\Routing\Exception\RouteNotFoundException; use Drupal\Component\Utility\UrlHelper; -use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\PathProcessor\OutboundPathProcessorInterface; use Drupal\Core\RouteProcessor\OutboundRouteProcessorInterface; use Symfony\Component\Routing\Exception\InvalidParameterException; diff --git a/core/lib/Drupal/Core/Routing/UrlGeneratorInterface.php b/core/lib/Drupal/Core/Routing/UrlGeneratorInterface.php index 0db116b99..7c33fd4b6 100644 --- a/core/lib/Drupal/Core/Routing/UrlGeneratorInterface.php +++ b/core/lib/Drupal/Core/Routing/UrlGeneratorInterface.php @@ -17,7 +17,7 @@ interface UrlGeneratorInterface extends VersatileGeneratorInterface { /** - * Gets the internal path (system path) of a route. + * Gets the internal path (system path) for a route. * * @param string|\Symfony\Component\Routing\Route $name * The route name or a route object. @@ -27,9 +27,6 @@ interface UrlGeneratorInterface extends VersatileGeneratorInterface { * * @return string * The internal Drupal path corresponding to the route. - * - * @deprecated in Drupal 8.0.x-dev, will be removed before Drupal 8.0.0 - * System paths should not be used - use route names and parameters. */ public function getPathFromRoute($name, $parameters = array()); diff --git a/core/lib/Drupal/Core/Session/PermissionsHashGenerator.php b/core/lib/Drupal/Core/Session/PermissionsHashGenerator.php index f9da69dd9..aaf4468f3 100644 --- a/core/lib/Drupal/Core/Session/PermissionsHashGenerator.php +++ b/core/lib/Drupal/Core/Session/PermissionsHashGenerator.php @@ -11,7 +11,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Site\Settings; -use Drupal\user\Entity\Role; /** * Generates and caches the permissions hash for a user. diff --git a/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php b/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php index c6b49ab27..db8019b18 100644 --- a/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php +++ b/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php @@ -11,7 +11,7 @@ use Symfony\Component\HttpKernel\HttpKernelInterface; /** - * + * Provides support for reverse proxies. */ class ReverseProxyMiddleware implements HttpKernelInterface { @@ -48,8 +48,21 @@ public function __construct(HttpKernelInterface $http_kernel, Settings $settings public function handle(Request $request, $type = self::MASTER_REQUEST, $catch = TRUE) { // Initialize proxy settings. if ($this->settings->get('reverse_proxy', FALSE)) { - $reverse_proxy_header = $this->settings->get('reverse_proxy_header', 'X_FORWARDED_FOR'); - $request::setTrustedHeaderName($request::HEADER_CLIENT_IP, $reverse_proxy_header); + $ip_header = $this->settings->get('reverse_proxy_header', 'X_FORWARDED_FOR'); + $request::setTrustedHeaderName($request::HEADER_CLIENT_IP, $ip_header); + + $proto_header = $this->settings->get('reverse_proxy_proto_header', 'X_FORWARDED_PROTO'); + $request::setTrustedHeaderName($request::HEADER_CLIENT_PROTO, $proto_header); + + $host_header = $this->settings->get('reverse_proxy_host_header', 'X_FORWARDED_HOST'); + $request::setTrustedHeaderName($request::HEADER_CLIENT_HOST, $host_header); + + $port_header = $this->settings->get('reverse_proxy_port_header', 'X_FORWARDED_PORT'); + $request::setTrustedHeaderName($request::HEADER_CLIENT_PORT, $port_header); + + $forwarded_header = $this->settings->get('reverse_proxy_forwarded_header', 'FORWARDED'); + $request::setTrustedHeaderName($request::HEADER_FORWARDED, $forwarded_header); + $proxies = $this->settings->get('reverse_proxy_addresses', array()); if (count($proxies) > 0) { $request::setTrustedProxies($proxies); diff --git a/core/lib/Drupal/Core/StringTranslation/StringTranslationTrait.php b/core/lib/Drupal/Core/StringTranslation/StringTranslationTrait.php index f4b4bd326..53e1f6f54 100644 --- a/core/lib/Drupal/Core/StringTranslation/StringTranslationTrait.php +++ b/core/lib/Drupal/Core/StringTranslation/StringTranslationTrait.php @@ -56,17 +56,6 @@ protected function formatPlural($count, $singular, $plural, array $args = array( return $this->getStringTranslation()->formatPlural($count, $singular, $plural, $args, $options); } - /** - * Formats a translated string containing a count of items. - * - * See the - * \Drupal\Core\StringTranslation\TranslationInterface::formatPluralTranslated() - * documentation for details. - */ - protected function formatPluralTranslated($count, $translated, array $args = array(), array $options = array()) { - return $this->getStringTranslation()->formatPluralTranslated($count, $translated, $args, $options); - } - /** * Returns the number of plurals supported by a given language. * diff --git a/core/lib/Drupal/Core/StringTranslation/TranslationManager.php b/core/lib/Drupal/Core/StringTranslation/TranslationManager.php index 7ccf5a39a..9d3966b02 100644 --- a/core/lib/Drupal/Core/StringTranslation/TranslationManager.php +++ b/core/lib/Drupal/Core/StringTranslation/TranslationManager.php @@ -7,7 +7,6 @@ namespace Drupal\Core\StringTranslation; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Language\LanguageDefault; use Drupal\Core\StringTranslation\Translator\TranslatorInterface; diff --git a/core/lib/Drupal/Core/Template/Attribute.php b/core/lib/Drupal/Core/Template/Attribute.php index a79414279..611c13391 100644 --- a/core/lib/Drupal/Core/Template/Attribute.php +++ b/core/lib/Drupal/Core/Template/Attribute.php @@ -119,7 +119,7 @@ public function offsetSet($name, $value) { protected function createAttributeValue($name, $value) { // If the value is already an AttributeValueBase object, return it // straight away. - if ($value instanceOf AttributeValueBase) { + if ($value instanceof AttributeValueBase) { return $value; } // An array value or 'class' attribute name are forced to always be an @@ -184,7 +184,7 @@ public function addClass() { } // Merge if there are values, just add them otherwise. - if (isset($this->storage['class']) && $this->storage['class'] instanceOf AttributeArray) { + if (isset($this->storage['class']) && $this->storage['class'] instanceof AttributeArray) { // Merge the values passed in from the class value array. $classes = array_merge($this->storage['class']->value(), $classes); $this->storage['class']->exchangeArray($classes); @@ -248,7 +248,7 @@ public function removeAttribute() { */ public function removeClass() { // With no class attribute, there is no need to remove. - if (isset($this->storage['class']) && $this->storage['class'] instanceOf AttributeArray) { + if (isset($this->storage['class']) && $this->storage['class'] instanceof AttributeArray) { $args = func_get_args(); $classes = array(); foreach ($args as $arg) { @@ -276,7 +276,7 @@ public function removeClass() { * Returns TRUE if the class exists, or FALSE otherwise. */ public function hasClass($class) { - if (isset($this->storage['class']) && $this->storage['class'] instanceOf AttributeArray) { + if (isset($this->storage['class']) && $this->storage['class'] instanceof AttributeArray) { return in_array($class, $this->storage['class']->value()); } else { diff --git a/core/lib/Drupal/Core/Template/TwigEnvironment.php b/core/lib/Drupal/Core/Template/TwigEnvironment.php index 8d3feaae0..eb4f8e54e 100644 --- a/core/lib/Drupal/Core/Template/TwigEnvironment.php +++ b/core/lib/Drupal/Core/Template/TwigEnvironment.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Template; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Render\Markup; diff --git a/core/lib/Drupal/Core/Template/TwigExtension.php b/core/lib/Drupal/Core/Template/TwigExtension.php index 52291c3ee..9d6dd1a44 100644 --- a/core/lib/Drupal/Core/Template/TwigExtension.php +++ b/core/lib/Drupal/Core/Template/TwigExtension.php @@ -415,7 +415,7 @@ public function escapeFilter(\Twig_Environment $env, $arg, $strategy = 'html', $ } // Keep Twig_Markup objects intact to support autoescaping. - if ($autoescape && ($arg instanceOf \Twig_Markup || $arg instanceOf MarkupInterface)) { + if ($autoescape && ($arg instanceof \Twig_Markup || $arg instanceof MarkupInterface)) { return $arg; } diff --git a/core/lib/Drupal/Core/Template/TwigNodeTrans.php b/core/lib/Drupal/Core/Template/TwigNodeTrans.php index 757b94b4c..6bd4b8a9b 100644 --- a/core/lib/Drupal/Core/Template/TwigNodeTrans.php +++ b/core/lib/Drupal/Core/Template/TwigNodeTrans.php @@ -14,9 +14,6 @@ namespace Drupal\Core\Template; -use Drupal\Component\Utility\Unicode; -use Drupal\Core\Site\Settings; - /** * A class that defines the Twig 'trans' tag for Drupal. */ diff --git a/core/lib/Drupal/Core/Test/TestRunnerKernel.php b/core/lib/Drupal/Core/Test/TestRunnerKernel.php index f19afb3bf..9a19d842c 100644 --- a/core/lib/Drupal/Core/Test/TestRunnerKernel.php +++ b/core/lib/Drupal/Core/Test/TestRunnerKernel.php @@ -9,8 +9,6 @@ use Drupal\Core\DrupalKernel; use Drupal\Core\Extension\Extension; -use Drupal\Core\Installer\InstallerServiceProvider; -use Composer\Autoload\ClassLoader; use Drupal\Core\Site\Settings; use Symfony\Component\HttpFoundation\Request; diff --git a/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php b/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php index 33f9db327..a4e40944f 100644 --- a/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php +++ b/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php @@ -62,8 +62,9 @@ public function getDataType(); /** * Returns a human readable label. * - * @return string - * The label. + * @return string|\Drupal\Core\StringTranslation\TranslatableMarkup + * The label. A string or an instance of TranslatableMarkup will be returned + * based on the way the label translation is handled. */ public function getLabel(); diff --git a/core/lib/Drupal/Core/TypedData/Plugin/DataType/BinaryData.php b/core/lib/Drupal/Core/TypedData/Plugin/DataType/BinaryData.php index a18c7d511..7cc76cbef 100644 --- a/core/lib/Drupal/Core/TypedData/Plugin/DataType/BinaryData.php +++ b/core/lib/Drupal/Core/TypedData/Plugin/DataType/BinaryData.php @@ -9,7 +9,6 @@ use Drupal\Core\TypedData\PrimitiveBase; use Drupal\Core\TypedData\Type\BinaryInterface; -use Drupal\Core\TypedData\TypedData; /** * The binary data type. diff --git a/core/lib/Drupal/Core/TypedData/Plugin/DataType/Uri.php b/core/lib/Drupal/Core/TypedData/Plugin/DataType/Uri.php index ac3d48d02..3fa168850 100644 --- a/core/lib/Drupal/Core/TypedData/Plugin/DataType/Uri.php +++ b/core/lib/Drupal/Core/TypedData/Plugin/DataType/Uri.php @@ -7,9 +7,7 @@ namespace Drupal\Core\TypedData\Plugin\DataType; -use Drupal\Core\TypedData\PrimitiveBase; use Drupal\Core\TypedData\Type\UriInterface; -use Drupal\Core\TypedData\TypedData; /** * The URI data type. diff --git a/core/lib/Drupal/Core/Url.php b/core/lib/Drupal/Core/Url.php index 5da8ffb85..de047eaa2 100644 --- a/core/lib/Drupal/Core/Url.php +++ b/core/lib/Drupal/Core/Url.php @@ -775,9 +775,6 @@ public function toRenderArray() { * * @throws \UnexpectedValueException. * If this is a URI with no corresponding system path. - * - * @deprecated in Drupal 8.x-dev, will be removed before Drupal 8.0. - * System paths should not be used - use route names and parameters. */ public function getInternalPath() { if ($this->unrouted) { diff --git a/core/lib/Drupal/Core/Utility/LinkGenerator.php b/core/lib/Drupal/Core/Utility/LinkGenerator.php index 8b453f7ea..70af47316 100644 --- a/core/lib/Drupal/Core/Utility/LinkGenerator.php +++ b/core/lib/Drupal/Core/Utility/LinkGenerator.php @@ -14,7 +14,6 @@ use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\GeneratedLink; use Drupal\Core\Link; -use Drupal\Core\Path\AliasManagerInterface; use Drupal\Core\Render\RendererInterface; use Drupal\Core\Routing\UrlGeneratorInterface; use Drupal\Core\Template\Attribute; diff --git a/core/lib/Drupal/Core/Utility/Token.php b/core/lib/Drupal/Core/Utility/Token.php index 688731a1a..8d98232e6 100644 --- a/core/lib/Drupal/Core/Utility/Token.php +++ b/core/lib/Drupal/Core/Utility/Token.php @@ -9,7 +9,6 @@ use Drupal\Component\Render\HtmlEscapedText; use Drupal\Component\Render\MarkupInterface; -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Cache\CacheTagsInvalidatorInterface; diff --git a/core/lib/Drupal/Core/Utility/UnroutedUrlAssembler.php b/core/lib/Drupal/Core/Utility/UnroutedUrlAssembler.php index 81795635a..dc1c237aa 100644 --- a/core/lib/Drupal/Core/Utility/UnroutedUrlAssembler.php +++ b/core/lib/Drupal/Core/Utility/UnroutedUrlAssembler.php @@ -8,7 +8,6 @@ namespace Drupal\Core\Utility; use Drupal\Component\Utility\UrlHelper; -use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\GeneratedUrl; use Drupal\Core\PathProcessor\OutboundPathProcessorInterface; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/core/misc/active-link.js b/core/misc/active-link.js index 97c9966bc..9cf55b434 100644 --- a/core/misc/active-link.js +++ b/core/misc/active-link.js @@ -5,7 +5,7 @@ (function (Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Append is-active class. diff --git a/core/misc/ajax.js b/core/misc/ajax.js index 4dba53e24..2a6616dc7 100644 --- a/core/misc/ajax.js +++ b/core/misc/ajax.js @@ -13,7 +13,7 @@ (function ($, window, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Attaches the Ajax behavior to each Ajax form element. @@ -106,20 +106,20 @@ var responseText; var readyStateText; if (xmlhttp.status) { - statusCode = "\n" + Drupal.t("An AJAX HTTP error occurred.") + "\n" + Drupal.t("HTTP Result Code: !status", {'!status': xmlhttp.status}); + statusCode = '\n' + Drupal.t('An AJAX HTTP error occurred.') + '\n' + Drupal.t('HTTP Result Code: !status', {'!status': xmlhttp.status}); } else { - statusCode = "\n" + Drupal.t("An AJAX HTTP request terminated abnormally."); + statusCode = '\n' + Drupal.t('An AJAX HTTP request terminated abnormally.'); } - statusCode += "\n" + Drupal.t("Debugging information follows."); - pathText = "\n" + Drupal.t("Path: !uri", {'!uri': uri}); + statusCode += '\n' + Drupal.t('Debugging information follows.'); + pathText = '\n' + Drupal.t('Path: !uri', {'!uri': uri}); statusText = ''; // In some cases, when statusCode === 0, xmlhttp.statusText may not be // defined. Unfortunately, testing for it with typeof, etc, doesn't seem to // catch that and the test causes an exception. So we need to catch the // exception here. try { - statusText = "\n" + Drupal.t("StatusText: !statusText", {'!statusText': $.trim(xmlhttp.statusText)}); + statusText = '\n' + Drupal.t('StatusText: !statusText', {'!statusText': $.trim(xmlhttp.statusText)}); } catch (e) { // Empty. @@ -129,20 +129,20 @@ // Again, we don't have a way to know for sure whether accessing // xmlhttp.responseText is going to throw an exception. So we'll catch it. try { - responseText = "\n" + Drupal.t("ResponseText: !responseText", {'!responseText': $.trim(xmlhttp.responseText)}); + responseText = '\n' + Drupal.t('ResponseText: !responseText', {'!responseText': $.trim(xmlhttp.responseText)}); } catch (e) { // Empty. } // Make the responseText more readable by stripping HTML tags and newlines. - responseText = responseText.replace(/<("[^"]*"|'[^']*'|[^'">])*>/gi, ""); - responseText = responseText.replace(/[\n]+\s+/g, "\n"); + responseText = responseText.replace(/<("[^"]*"|'[^']*'|[^'">])*>/gi, ''); + responseText = responseText.replace(/[\n]+\s+/g, '\n'); // We don't need readyState except for status == 0. - readyStateText = xmlhttp.status === 0 ? ("\n" + Drupal.t("ReadyState: !readyState", {'!readyState': xmlhttp.readyState})) : ""; + readyStateText = xmlhttp.status === 0 ? ('\n' + Drupal.t('ReadyState: !readyState', {'!readyState': xmlhttp.readyState})) : ''; - customMessage = customMessage ? ("\n" + Drupal.t("CustomMessage: !customMessage", {'!customMessage': customMessage})) : ""; + customMessage = customMessage ? ('\n' + Drupal.t('CustomMessage: !customMessage', {'!customMessage': customMessage})) : ''; /** * Formatted and translated error message. @@ -406,7 +406,7 @@ // the response headers cannot be accessed for verification. if (response !== null && !drupalSettings.ajaxTrustedUrl[ajax.url]) { if (xmlhttprequest.getResponseHeader('X-Drupal-Ajax-Token') !== '1') { - var customMessage = Drupal.t("The response failed verification so will not be processed."); + var customMessage = Drupal.t('The response failed verification so will not be processed.'); return ajax.error(xmlhttprequest, ajax.url, customMessage); } } @@ -499,7 +499,7 @@ // Unset the ajax.ajaxing flag here because it won't be unset during // the complete response. this.ajaxing = false; - window.alert("An error occurred while attempting to process " + this.options.url + ": " + e.message); + window.alert('An error occurred while attempting to process ' + this.options.url + ': ' + e.message); } }; @@ -579,7 +579,7 @@ // Unset the ajax.ajaxing flag here because it won't be unset during // the complete response. ajax.ajaxing = false; - window.alert("An error occurred while attempting to process " + ajax.options.url + ": " + e.message); + window.alert('An error occurred while attempting to process ' + ajax.options.url + ': ' + e.message); } }; diff --git a/core/misc/announce.js b/core/misc/announce.js index 0a0abebbd..235c597ec 100644 --- a/core/misc/announce.js +++ b/core/misc/announce.js @@ -20,7 +20,7 @@ (function (Drupal, debounce) { - "use strict"; + 'use strict'; var liveElement; var announcements = []; diff --git a/core/misc/autocomplete.js b/core/misc/autocomplete.js index f826281b4..afcc84b67 100644 --- a/core/misc/autocomplete.js +++ b/core/misc/autocomplete.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; var autocomplete; @@ -158,7 +158,7 @@ // Remove the current input. terms.pop(); // Add the selected item. - if (ui.item.value.search(",") > 0) { + if (ui.item.value.search(',') > 0) { terms.push('"' + ui.item.value + '"'); } else { @@ -178,8 +178,8 @@ * @return {object} */ function renderItem(ul, item) { - return $("
  • ") - .append($("").html(item.label)) + return $('
  • ') + .append($('').html(item.label)) .appendTo(ul); } @@ -200,7 +200,7 @@ }); // Use jQuery UI Autocomplete on the textfield. $autocomplete.autocomplete(autocomplete.options) - .data("ui-autocomplete") + .data('ui-autocomplete') ._renderItem = autocomplete.options.renderItem; } }, diff --git a/core/misc/batch.js b/core/misc/batch.js index 43242eab9..411badba4 100644 --- a/core/misc/batch.js +++ b/core/misc/batch.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Attaches the batch behavior to progress bars. diff --git a/core/misc/collapse.js b/core/misc/collapse.js index 1ad89f7e8..f6356474a 100644 --- a/core/misc/collapse.js +++ b/core/misc/collapse.js @@ -5,7 +5,7 @@ (function ($, Modernizr, Drupal) { - "use strict"; + 'use strict'; /** * The collapsible details object represents a single details element. diff --git a/core/misc/date.js b/core/misc/date.js index fe2a23999..8b6b71cb1 100644 --- a/core/misc/date.js +++ b/core/misc/date.js @@ -5,7 +5,7 @@ (function ($, Modernizr, Drupal) { - "use strict"; + 'use strict'; /** * Attach datepicker fallback on date elements. diff --git a/core/misc/debounce.js b/core/misc/debounce.js index 0239ce6af..995e3d713 100644 --- a/core/misc/debounce.js +++ b/core/misc/debounce.js @@ -28,7 +28,7 @@ */ Drupal.debounce = function (func, wait, immediate) { - "use strict"; + 'use strict'; var timeout; var result; diff --git a/core/misc/details-aria.js b/core/misc/details-aria.js index 4de6bdf4f..d34142235 100644 --- a/core/misc/details-aria.js +++ b/core/misc/details-aria.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Handles `aria-expanded` and `aria-pressed` attributes on details elements. diff --git a/core/misc/dialog/dialog.ajax.js b/core/misc/dialog/dialog.ajax.js index 7f56672bc..bfe298063 100644 --- a/core/misc/dialog/dialog.ajax.js +++ b/core/misc/dialog/dialog.ajax.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Initialize dialogs for Ajax purposes. diff --git a/core/misc/dialog/dialog.jquery-ui.js b/core/misc/dialog/dialog.jquery-ui.js index 27fff752a..2526e3095 100644 --- a/core/misc/dialog/dialog.jquery-ui.js +++ b/core/misc/dialog/dialog.jquery-ui.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; $.widget('ui.dialog', $.ui.dialog, { options: { diff --git a/core/misc/dialog/dialog.js b/core/misc/dialog/dialog.js index cb7fb9275..5683cfb16 100644 --- a/core/misc/dialog/dialog.js +++ b/core/misc/dialog/dialog.js @@ -7,7 +7,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Default dialog options. diff --git a/core/misc/dialog/dialog.position.js b/core/misc/dialog/dialog.position.js index a3564778b..c0dd9df0e 100644 --- a/core/misc/dialog/dialog.position.js +++ b/core/misc/dialog/dialog.position.js @@ -11,7 +11,7 @@ (function ($, Drupal, drupalSettings, debounce, displace) { - "use strict"; + 'use strict'; // autoResize option will turn off resizable and draggable. drupalSettings.dialog = $.extend({autoResize: true, maxHeight: '95%'}, drupalSettings.dialog); diff --git a/core/misc/displace.js b/core/misc/displace.js index 5e21ca12a..3315f2ea5 100644 --- a/core/misc/displace.js +++ b/core/misc/displace.js @@ -26,7 +26,7 @@ (function ($, Drupal, debounce) { - "use strict"; + 'use strict'; /** * @name Drupal.displace.offsets diff --git a/core/misc/dropbutton/dropbutton.js b/core/misc/dropbutton/dropbutton.js index 4f7645cc4..ef707a6c8 100644 --- a/core/misc/dropbutton/dropbutton.js +++ b/core/misc/dropbutton/dropbutton.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Process elements with the .dropbutton class on page load. diff --git a/core/misc/drupal.js b/core/misc/drupal.js index fef81f325..f1f7d6f5d 100644 --- a/core/misc/drupal.js +++ b/core/misc/drupal.js @@ -52,7 +52,7 @@ if (window.jQuery) { // wrapping it in an anonymous closure. (function (domready, Drupal, drupalSettings, drupalTranslations) { - "use strict"; + 'use strict'; /** * Helper to rethrow errors asynchronously. diff --git a/core/misc/drupalSettingsLoader.js b/core/misc/drupalSettingsLoader.js index ab3911dea..da61b7edd 100644 --- a/core/misc/drupalSettingsLoader.js +++ b/core/misc/drupalSettingsLoader.js @@ -5,7 +5,7 @@ (function () { - "use strict"; + 'use strict'; var settingsElement = document.querySelector('script[type="application/json"][data-drupal-selector="drupal-settings-json"]'); diff --git a/core/misc/form.js b/core/misc/form.js index 7210be5d3..f2bf08ac1 100644 --- a/core/misc/form.js +++ b/core/misc/form.js @@ -14,7 +14,7 @@ (function ($, Drupal, debounce) { - "use strict"; + 'use strict'; /** * Retrieves the summary for the first element. diff --git a/core/misc/machine-name.js b/core/misc/machine-name.js index 688c4b6ba..27016edb5 100644 --- a/core/misc/machine-name.js +++ b/core/misc/machine-name.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Attach the machine-readable name form element behavior. diff --git a/core/misc/progress.js b/core/misc/progress.js index fdfd3b69b..bf678f55b 100644 --- a/core/misc/progress.js +++ b/core/misc/progress.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Theme function for the progress bar. diff --git a/core/misc/states.js b/core/misc/states.js index 589a3708b..4f3da8df7 100644 --- a/core/misc/states.js +++ b/core/misc/states.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * The base States namespace. diff --git a/core/misc/tabbingmanager.js b/core/misc/tabbingmanager.js index 4593ec48f..6e2ce843f 100644 --- a/core/misc/tabbingmanager.js +++ b/core/misc/tabbingmanager.js @@ -29,7 +29,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Provides an API for managing page tabbing order modifications. diff --git a/core/misc/tabledrag.js b/core/misc/tabledrag.js index 8754b98ad..aa512acea 100644 --- a/core/misc/tabledrag.js +++ b/core/misc/tabledrag.js @@ -11,7 +11,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Store the state of weight columns display for all tables. @@ -236,7 +236,7 @@ // Add event bindings to the document. The self variable is passed along // as event handlers do not have direct access to the tableDrag object. - if (Modernizr.touch) { + if (Modernizr.touchevents) { $(document).on('touchmove', function (event) { return self.dragRow(event.originalEvent.touches[0], self); }); $(document).on('touchend', function (event) { return self.dropRow(event.originalEvent.touches[0], self); }); } @@ -460,7 +460,7 @@ $item.find('td').eq(0).prepend(handle); } - if (Modernizr.touch) { + if (Modernizr.touchevents) { handle.on('touchstart', function (event) { event.preventDefault(); event = event.originalEvent.touches[0]; diff --git a/core/misc/tableheader.js b/core/misc/tableheader.js index 7a212904e..7d55a0486 100644 --- a/core/misc/tableheader.js +++ b/core/misc/tableheader.js @@ -5,7 +5,7 @@ (function ($, Drupal, displace) { - "use strict"; + 'use strict'; /** * Attaches sticky table headers. diff --git a/core/misc/tableresponsive.js b/core/misc/tableresponsive.js index f2ebd1893..04965efc4 100644 --- a/core/misc/tableresponsive.js +++ b/core/misc/tableresponsive.js @@ -5,7 +5,7 @@ (function ($, Drupal, window) { - "use strict"; + 'use strict'; /** * Attach the tableResponsive function to {@link Drupal.behaviors}. diff --git a/core/misc/tableselect.js b/core/misc/tableselect.js index 8a7769597..fb82ec054 100644 --- a/core/misc/tableselect.js +++ b/core/misc/tableselect.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Initialize tableSelects. diff --git a/core/misc/timezone.js b/core/misc/timezone.js index 801d72839..f1ba7c928 100644 --- a/core/misc/timezone.js +++ b/core/misc/timezone.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Set the client's system time zone as default values of form fields. diff --git a/core/misc/vertical-tabs.js b/core/misc/vertical-tabs.js index 840a38cd1..2794481d3 100644 --- a/core/misc/vertical-tabs.js +++ b/core/misc/vertical-tabs.js @@ -14,7 +14,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * This script transforms a set of details into a stack of vertical tabs. @@ -126,7 +126,7 @@ event.preventDefault(); self.focus(); // Set focus on the first input field of the visible details/tab pane. - $(".vertical-tabs__pane :input:visible:enabled").eq(0).trigger('focus'); + $('.vertical-tabs__pane :input:visible:enabled').eq(0).trigger('focus'); } }); diff --git a/core/modules/action/action.views_execution.inc b/core/modules/action/action.views_execution.inc index db7fef5e1..5b4f71f81 100644 --- a/core/modules/action/action.views_execution.inc +++ b/core/modules/action/action.views_execution.inc @@ -5,8 +5,6 @@ * Provides views runtime hooks for action.module. */ -use Drupal\Component\Utility\SafeMarkup; - /** * Implements hook_views_form_substitutions(). */ diff --git a/core/modules/aggregator/aggregator.install b/core/modules/aggregator/aggregator.install index 88812c475..ad5f92f1f 100644 --- a/core/modules/aggregator/aggregator.install +++ b/core/modules/aggregator/aggregator.install @@ -4,7 +4,6 @@ * @file * Install, update and uninstall functions for the aggregator module. */ -use Drupal\Core\Language\Language; /** * Implements hook_requirements(). diff --git a/core/modules/aggregator/aggregator.routing.yml b/core/modules/aggregator/aggregator.routing.yml index 2f2d5536c..941f69343 100644 --- a/core/modules/aggregator/aggregator.routing.yml +++ b/core/modules/aggregator/aggregator.routing.yml @@ -49,34 +49,6 @@ aggregator.feed_add: options: _admin_route: TRUE -entity.aggregator_feed.canonical: - path: '/aggregator/sources/{aggregator_feed}' - defaults: - _entity_view: 'aggregator_feed' - _title_callback: '\Drupal\aggregator\Controller\AggregatorController::feedTitle' - requirements: - _permission: 'access news feeds' - -entity.aggregator_feed.edit_form: - path: '/aggregator/sources/{aggregator_feed}/configure' - defaults: - _entity_form: 'aggregator_feed.default' - _title: 'Configure' - requirements: - _permission: 'administer news feeds' - options: - _admin_route: TRUE - -entity.aggregator_feed.delete_form: - path: '/aggregator/sources/{aggregator_feed}/delete' - defaults: - _entity_form: 'aggregator_feed.delete' - _title: 'Delete feed' - requirements: - _permission: 'administer news feeds' - options: - _admin_route: TRUE - aggregator.page_last: path: '/aggregator' defaults: diff --git a/core/modules/aggregator/src/Controller/AggregatorController.php b/core/modules/aggregator/src/Controller/AggregatorController.php index 70c66976d..c6568383c 100644 --- a/core/modules/aggregator/src/Controller/AggregatorController.php +++ b/core/modules/aggregator/src/Controller/AggregatorController.php @@ -12,8 +12,6 @@ use Drupal\Core\Datetime\DateFormatterInterface; use Drupal\aggregator\FeedInterface; use Drupal\Core\Url; -use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\HttpFoundation\Response; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/aggregator/src/Entity/Feed.php b/core/modules/aggregator/src/Entity/Feed.php index a78d85357..f478d1cc3 100644 --- a/core/modules/aggregator/src/Entity/Feed.php +++ b/core/modules/aggregator/src/Entity/Feed.php @@ -10,7 +10,6 @@ use Drupal\Core\Entity\ContentEntityBase; use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Field\BaseFieldDefinition; -use Symfony\Component\DependencyInjection\Container; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\aggregator\FeedInterface; @@ -30,7 +29,10 @@ * "default" = "Drupal\aggregator\FeedForm", * "delete" = "Drupal\aggregator\Form\FeedDeleteForm", * "delete_items" = "Drupal\aggregator\Form\FeedItemsDeleteForm", - * } + * }, + * "route_provider" = { + * "html" = "Drupal\aggregator\FeedHtmlRouteProvider", + * }, * }, * links = { * "canonical" = "/aggregator/sources/{aggregator_feed}", diff --git a/core/modules/aggregator/src/FeedHtmlRouteProvider.php b/core/modules/aggregator/src/FeedHtmlRouteProvider.php new file mode 100644 index 000000000..ad168ee1a --- /dev/null +++ b/core/modules/aggregator/src/FeedHtmlRouteProvider.php @@ -0,0 +1,39 @@ +setDefault('_title_controller', '\Drupal\aggregator\Controller\AggregatorController::feedTitle'); + + return $route; + } + + /** + * {@inheritdoc} + */ + protected function getEditFormRoute(EntityTypeInterface $entity_type) { + $route = parent::getEditFormRoute($entity_type); + + $route->setDefault('_title', 'Configure'); + + return $route; + } + +} diff --git a/core/modules/aggregator/src/FeedStorageInterface.php b/core/modules/aggregator/src/FeedStorageInterface.php index 1075f75f3..48b2732d2 100644 --- a/core/modules/aggregator/src/FeedStorageInterface.php +++ b/core/modules/aggregator/src/FeedStorageInterface.php @@ -7,7 +7,6 @@ namespace Drupal\aggregator; -use Drupal\aggregator\FeedInterface; use Drupal\Core\Entity\EntityStorageInterface; /** diff --git a/core/modules/aggregator/src/ItemStorageInterface.php b/core/modules/aggregator/src/ItemStorageInterface.php index f5012bd64..f6526a4f6 100644 --- a/core/modules/aggregator/src/ItemStorageInterface.php +++ b/core/modules/aggregator/src/ItemStorageInterface.php @@ -7,7 +7,6 @@ namespace Drupal\aggregator; -use Drupal\aggregator\Entity\Item; use Drupal\Core\Entity\EntityStorageInterface; /** diff --git a/core/modules/aggregator/src/ItemStorageSchema.php b/core/modules/aggregator/src/ItemStorageSchema.php index 9688f670b..b174ee23d 100644 --- a/core/modules/aggregator/src/ItemStorageSchema.php +++ b/core/modules/aggregator/src/ItemStorageSchema.php @@ -7,7 +7,6 @@ namespace Drupal\aggregator; -use Drupal\Core\Entity\ContentEntityTypeInterface; use Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema; use Drupal\Core\Field\FieldStorageDefinitionInterface; diff --git a/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorXSSFormatter.php b/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorXSSFormatter.php index 0edb460a5..2b6525a54 100644 --- a/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorXSSFormatter.php +++ b/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorXSSFormatter.php @@ -7,10 +7,8 @@ namespace Drupal\aggregator\Plugin\Field\FieldFormatter; -use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Field\FormatterBase; -use Drupal\Core\Form\FormStateInterface; /** * Plugin implementation of the 'aggregator_xss' formatter. diff --git a/core/modules/aggregator/src/Plugin/aggregator/processor/DefaultProcessor.php b/core/modules/aggregator/src/Plugin/aggregator/processor/DefaultProcessor.php index 21a67dda4..95c6324b9 100644 --- a/core/modules/aggregator/src/Plugin/aggregator/processor/DefaultProcessor.php +++ b/core/modules/aggregator/src/Plugin/aggregator/processor/DefaultProcessor.php @@ -12,7 +12,6 @@ use Drupal\aggregator\Plugin\ProcessorInterface; use Drupal\aggregator\FeedInterface; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Database\Database; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Datetime\DateFormatterInterface; use Drupal\Core\Entity\Query\QueryInterface; diff --git a/core/modules/aggregator/src/Tests/AddFeedTest.php b/core/modules/aggregator/src/Tests/AddFeedTest.php index cf95815cc..56f558634 100644 --- a/core/modules/aggregator/src/Tests/AddFeedTest.php +++ b/core/modules/aggregator/src/Tests/AddFeedTest.php @@ -6,7 +6,6 @@ */ namespace Drupal\aggregator\Tests; -use Drupal\Component\Utility\Html; /** * Add feed test. @@ -62,8 +61,8 @@ public function testFeedLabelEscaping() { $this->drupalGet('aggregator/sources/' . $feed->id()); $this->assertResponse(200); - $result = $this->xpath('//h1'); - $this->assertEqual((string) $result[0], 'Test feed title alert(123);'); + $this->assertEscaped('Test feed title '); + $this->assertNoRaw('Test feed title '); // Ensure the feed icon title is escaped. $this->assertTrue(strpos(str_replace(["\n", "\r"], '', $this->getRawContent()), 'class="feed-icon"> Subscribe to Test feed title <script>alert(123);</script> feed') !== FALSE); diff --git a/core/modules/aggregator/src/Tests/FeedParserTest.php b/core/modules/aggregator/src/Tests/FeedParserTest.php index 6da2ec8eb..f507302a3 100644 --- a/core/modules/aggregator/src/Tests/FeedParserTest.php +++ b/core/modules/aggregator/src/Tests/FeedParserTest.php @@ -8,7 +8,6 @@ namespace Drupal\aggregator\Tests; use Drupal\Core\Url; -use Zend\Feed\Reader\Reader; /** * Tests the built-in feed parser with valid feed samples. diff --git a/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorFeedTest.php b/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorFeedTest.php index 024d5ee22..065476b81 100644 --- a/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorFeedTest.php +++ b/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorFeedTest.php @@ -13,11 +13,14 @@ /** * Test migration to aggregator_feed entities. * - * @group aggregator + * @group migrate_drupal_7 */ class MigrateAggregatorFeedTest extends MigrateDrupal7TestBase { - public static $modules = array('aggregator'); + /** + * {@inheritdoc} + */ + public static $modules = ['aggregator']; /** * {@inheritdoc} @@ -32,19 +35,25 @@ protected function setUp() { * Tests migration of aggregator feeds. */ public function testAggregatorFeedImport() { - /** @var \Drupal\aggregator\Entity\Feed $feed */ + /** @var \Drupal\aggregator\FeedInterface $feed */ $feed = Feed::load(1); - $this->assertIdentical('Know Your Meme', $feed->title->value); + $this->assertIdentical('Know Your Meme', $feed->label()); $this->assertIdentical('en', $feed->language()->getId()); - $this->assertIdentical('http://knowyourmeme.com/newsfeed.rss', $feed->url->value); - $this->assertIdentical('900', $feed->refresh->value); - $this->assertIdentical('1387659487', $feed->checked->value); - $this->assertIdentical('0', $feed->queued->value); + $this->assertIdentical('http://knowyourmeme.com/newsfeed.rss', $feed->getUrl()); + $this->assertIdentical('900', $feed->getRefreshRate()); + // The feed's last checked time can change as the fixture is updated, so + // assert that its format is correct. + $checked_time = $feed->getLastCheckedTime(); + $this->assertTrue(is_numeric($checked_time)); + $this->assertTrue($checked_time > 1000000000); + $this->assertIdentical('0', $feed->getQueuedTime()); $this->assertIdentical('http://knowyourmeme.com', $feed->link->value); - $this->assertIdentical('New items added to the News Feed', $feed->description->value); - $this->assertIdentical('http://b.thumbs.redditmedia.com/harEHsUUZVajabtC.png', $feed->image->value); - $this->assertIdentical('"213cc1365b96c310e92053c5551f0504"', $feed->etag->value); - $this->assertIdentical('0', $feed->modified->value); + $this->assertIdentical('New items added to the News Feed', $feed->getDescription()); + $this->assertNull($feed->getImage()); + // As with getLastCheckedTime(), the etag can change as the fixture is + // updated normally, so assert that its format is correct. + $this->assertTrue(preg_match('/^"[a-z0-9]{32}"$/', $feed->getEtag())); + $this->assertIdentical('0', $feed->getLastModified()); } } diff --git a/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorItemTest.php b/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorItemTest.php index 27b4b8cd9..d0c01541c 100644 --- a/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorItemTest.php +++ b/core/modules/aggregator/src/Tests/Migrate/d7/MigrateAggregatorItemTest.php @@ -13,11 +13,14 @@ /** * Tests migration of aggregator items. * - * @group aggregator + * @group migrate_drupal_7 */ class MigrateAggregatorItemTest extends MigrateDrupal7TestBase { - public static $modules = array('aggregator'); + /** + * {@inheritdoc} + */ + public static $modules = ['aggregator']; /** * {@inheritdoc} @@ -34,17 +37,27 @@ protected function setUp() { * Test Drupal 7 aggregator item migration to Drupal 8. */ public function testAggregatorItem() { - /** @var \Drupal\aggregator\Entity\Item $item */ - $item = Item::load(1); - $this->assertIdentical('1', $item->id()); - $this->assertIdentical('1', $item->getFeedId()); - $this->assertIdentical('This (three) weeks in Drupal Core - January 10th 2014', $item->label()); - $this->assertIdentical('larowlan', $item->getAuthor()); - $this->assertIdentical("

    What's new with Drupal 8?

    ", $item->getDescription()); - $this->assertIdentical('https://groups.drupal.org/node/395218', $item->getLink()); - $this->assertIdentical('1389297196', $item->getPostedTime()); - $this->assertIdentical('en', $item->language()->getId()); - $this->assertIdentical('395218 at https://groups.drupal.org', $item->getGuid()); + // Since the feed items can change as the fixture is updated normally, + // assert all migrated feed items against the values in the fixture. + $items = $this->sourceDatabase + ->select('aggregator_item', 'ai') + ->fields('ai') + ->execute(); + + foreach ($items as $original) { + /** @var \Drupal\aggregator\ItemInterface $item */ + $item = Item::load($original->iid); + $this->assertIdentical($original->fid, $item->getFeedId()); + $this->assertIdentical($original->title, $item->label()); + // If $original->author is an empty string, getAuthor() returns NULL so + // we need to use assertEqual() here. + $this->assertEqual($original->author, $item->getAuthor()); + $this->assertIdentical($original->description, $item->getDescription()); + $this->assertIdentical($original->link, $item->getLink()); + $this->assertIdentical($original->timestamp, $item->getPostedTime()); + $this->assertIdentical('en', $item->language()->getId()); + $this->assertIdentical($original->guid, $item->getGuid()); + } } } diff --git a/core/modules/block/js/block.admin.js b/core/modules/block/js/block.admin.js index 20be7fdbb..9f99b7fab 100644 --- a/core/modules/block/js/block.admin.js +++ b/core/modules/block/js/block.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Filters the block list by a text input search string. diff --git a/core/modules/block/js/block.js b/core/modules/block/js/block.js index 5607b02ca..df9327bbc 100644 --- a/core/modules/block/js/block.js +++ b/core/modules/block/js/block.js @@ -5,7 +5,7 @@ (function ($, window) { - "use strict"; + 'use strict'; /** * Provide the summary information for the block settings vertical tabs. diff --git a/core/modules/block/src/Controller/BlockAddController.php b/core/modules/block/src/Controller/BlockAddController.php index dacfde352..a9abfd6f1 100644 --- a/core/modules/block/src/Controller/BlockAddController.php +++ b/core/modules/block/src/Controller/BlockAddController.php @@ -8,7 +8,6 @@ namespace Drupal\block\Controller; use Drupal\Core\Controller\ControllerBase; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Controller for building the block instance add form. diff --git a/core/modules/block/src/Controller/BlockController.php b/core/modules/block/src/Controller/BlockController.php index 32a662668..2779a9b57 100644 --- a/core/modules/block/src/Controller/BlockController.php +++ b/core/modules/block/src/Controller/BlockController.php @@ -9,10 +9,8 @@ use Drupal\Component\Utility\Html; use Drupal\Core\Controller\ControllerBase; -use Drupal\Core\Extension\ThemeHandler; use Drupal\Core\Extension\ThemeHandlerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Controller routines for admin block routes. diff --git a/core/modules/block/src/EventSubscriber/BlockPageDisplayVariantSubscriber.php b/core/modules/block/src/EventSubscriber/BlockPageDisplayVariantSubscriber.php index f66b9688d..a686188a4 100644 --- a/core/modules/block/src/EventSubscriber/BlockPageDisplayVariantSubscriber.php +++ b/core/modules/block/src/EventSubscriber/BlockPageDisplayVariantSubscriber.php @@ -7,7 +7,6 @@ namespace Drupal\block\EventSubscriber; -use Drupal\Core\StringTranslation\StringTranslationTrait; use Drupal\Core\Render\PageDisplayVariantSelectionEvent; use Drupal\Core\Render\RenderEvents; use Symfony\Component\EventDispatcher\EventSubscriberInterface; diff --git a/core/modules/block/src/Tests/BlockViewBuilderTest.php b/core/modules/block/src/Tests/BlockViewBuilderTest.php index bd35f1d10..331db82a9 100644 --- a/core/modules/block/src/Tests/BlockViewBuilderTest.php +++ b/core/modules/block/src/Tests/BlockViewBuilderTest.php @@ -11,8 +11,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Language\LanguageInterface; use Drupal\simpletest\KernelTestBase; -use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\HttpFoundation\RequestStack; use Drupal\block\Entity\Block; /** diff --git a/core/modules/block/tests/modules/block_test/src/Plugin/Block/TestCacheBlock.php b/core/modules/block/tests/modules/block_test/src/Plugin/Block/TestCacheBlock.php index 157acb409..58da8a762 100644 --- a/core/modules/block/tests/modules/block_test/src/Plugin/Block/TestCacheBlock.php +++ b/core/modules/block/tests/modules/block_test/src/Plugin/Block/TestCacheBlock.php @@ -8,7 +8,6 @@ namespace Drupal\block_test\Plugin\Block; use Drupal\Core\Block\BlockBase; -use Drupal\Core\Cache\Cache; /** * Provides a block to test caching. diff --git a/core/modules/block_content/block_content.module b/core/modules/block_content/block_content.module index 49de8acaa..74fe9f168 100644 --- a/core/modules/block_content/block_content.module +++ b/core/modules/block_content/block_content.module @@ -72,8 +72,8 @@ function block_content_entity_type_alter(array &$entity_types) { * @param string $label * (optional) The label for the body instance. Defaults to 'Body' * - * @return array() - * Body field. + * @return \Drupal\field\Entity\FieldConfig + * A Body field object. */ function block_content_add_body_field($block_type_id, $label = 'Body') { // Add or remove the body field, as needed. diff --git a/core/modules/block_content/block_content.pages.inc b/core/modules/block_content/block_content.pages.inc index 9e019cd3e..86296900d 100644 --- a/core/modules/block_content/block_content.pages.inc +++ b/core/modules/block_content/block_content.pages.inc @@ -6,9 +6,6 @@ */ use Drupal\Core\Url; -use Drupal\block_content\Entity\BlockContentType; -use Drupal\block_content\Entity\BlockContent; -use Symfony\Component\HttpFoundation\RedirectResponse; /** * Prepares variables for a custom block type creation list templates. diff --git a/core/modules/block_content/js/block_content.js b/core/modules/block_content/js/block_content.js index 8ce1e6501..dbc89f9a8 100644 --- a/core/modules/block_content/js/block_content.js +++ b/core/modules/block_content/js/block_content.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Sets summaries about revision and translation of block content. diff --git a/core/modules/block_content/src/Controller/BlockContentController.php b/core/modules/block_content/src/Controller/BlockContentController.php index 4d653624d..e43fb83e0 100644 --- a/core/modules/block_content/src/Controller/BlockContentController.php +++ b/core/modules/block_content/src/Controller/BlockContentController.php @@ -7,7 +7,6 @@ namespace Drupal\block_content\Controller; -use Drupal\Component\Plugin\PluginManagerInterface; use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\block_content\BlockContentTypeInterface; diff --git a/core/modules/block_content/src/Entity/BlockContentType.php b/core/modules/block_content/src/Entity/BlockContentType.php index 84948144b..f020bbd41 100644 --- a/core/modules/block_content/src/Entity/BlockContentType.php +++ b/core/modules/block_content/src/Entity/BlockContentType.php @@ -7,9 +7,7 @@ namespace Drupal\block_content\Entity; -use Drupal\Core\Config\Entity\ConfigEntityBase; use Drupal\Core\Config\Entity\ConfigEntityBundleBase; -use Drupal\Core\Entity\EntityStorageInterface; use Drupal\block_content\BlockContentTypeInterface; /** diff --git a/core/modules/block_content/src/Form/BlockContentTypeDeleteForm.php b/core/modules/block_content/src/Form/BlockContentTypeDeleteForm.php index a9ec5d96b..3c3b75a6e 100644 --- a/core/modules/block_content/src/Form/BlockContentTypeDeleteForm.php +++ b/core/modules/block_content/src/Form/BlockContentTypeDeleteForm.php @@ -10,7 +10,6 @@ use Drupal\Core\Entity\EntityDeleteForm; use Drupal\Core\Entity\Query\QueryFactory; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Url; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/block_content/src/Plugin/Block/BlockContentBlock.php b/core/modules/block_content/src/Plugin/Block/BlockContentBlock.php index 266b29502..d271ea1d5 100644 --- a/core/modules/block_content/src/Plugin/Block/BlockContentBlock.php +++ b/core/modules/block_content/src/Plugin/Block/BlockContentBlock.php @@ -13,7 +13,6 @@ use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; -use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Routing\UrlGeneratorInterface; use Drupal\Core\Session\AccountInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/block_content/src/Tests/BlockContentCacheTagsTest.php b/core/modules/block_content/src/Tests/BlockContentCacheTagsTest.php index 1aecb8523..8f543c373 100644 --- a/core/modules/block_content/src/Tests/BlockContentCacheTagsTest.php +++ b/core/modules/block_content/src/Tests/BlockContentCacheTagsTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Language\LanguageInterface; -use Drupal\field\Entity\FieldStorageConfig; use Drupal\system\Tests\Entity\EntityCacheTagsTestBase; use Symfony\Component\HttpFoundation\Request; diff --git a/core/modules/block_content/src/Tests/BlockContentTestBase.php b/core/modules/block_content/src/Tests/BlockContentTestBase.php index 6a01fa689..494bd8584 100644 --- a/core/modules/block_content/src/Tests/BlockContentTestBase.php +++ b/core/modules/block_content/src/Tests/BlockContentTestBase.php @@ -7,7 +7,6 @@ namespace Drupal\block_content\Tests; -use Drupal\field\Entity\FieldStorageConfig; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/block_content/src/Tests/BlockContentTypeTest.php b/core/modules/block_content/src/Tests/BlockContentTypeTest.php index 2e29d108a..e669a72e3 100644 --- a/core/modules/block_content/src/Tests/BlockContentTypeTest.php +++ b/core/modules/block_content/src/Tests/BlockContentTypeTest.php @@ -9,7 +9,6 @@ use Drupal\block_content\Entity\BlockContentType; use Drupal\Component\Utility\Html; -use Drupal\Core\Url; /** * Ensures that custom block type functions work correctly. diff --git a/core/modules/book/book.js b/core/modules/book/book.js index 249f5a634..fa4081812 100644 --- a/core/modules/book/book.js +++ b/core/modules/book/book.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Adds summaries to the book outline form. diff --git a/core/modules/book/book.module b/core/modules/book/book.module index 2bba2777f..abf11eb2a 100644 --- a/core/modules/book/book.module +++ b/core/modules/book/book.module @@ -6,7 +6,6 @@ */ use Drupal\book\BookManager; -use Drupal\book\BookManagerInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Element; diff --git a/core/modules/book/src/BookExport.php b/core/modules/book/src/BookExport.php index dbb62e9fc..4ae2ea134 100644 --- a/core/modules/book/src/BookExport.php +++ b/core/modules/book/src/BookExport.php @@ -8,8 +8,6 @@ namespace Drupal\book; use Drupal\Core\Entity\EntityManagerInterface; -use Drupal\Core\Render\RendererInterface; -use Drupal\node\Entity\Node; use Drupal\node\NodeInterface; /** diff --git a/core/modules/book/src/Controller/BookController.php b/core/modules/book/src/Controller/BookController.php index 53c64ad3c..3206e4335 100644 --- a/core/modules/book/src/Controller/BookController.php +++ b/core/modules/book/src/Controller/BookController.php @@ -12,7 +12,6 @@ use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Render\RendererInterface; use Drupal\Core\Url; -use Drupal\node\Entity\Node; use Drupal\node\NodeInterface; use Symfony\Component\DependencyInjection\Container; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/book/src/Form/BookRemoveForm.php b/core/modules/book/src/Form/BookRemoveForm.php index 7623f5fd1..80c7f8995 100644 --- a/core/modules/book/src/Form/BookRemoveForm.php +++ b/core/modules/book/src/Form/BookRemoveForm.php @@ -10,7 +10,6 @@ use Drupal\book\BookManagerInterface; use Drupal\Core\Form\ConfirmFormBase; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Url; use Drupal\node\NodeInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/ckeditor/js/ckeditor.admin.js b/core/modules/ckeditor/js/ckeditor.admin.js index 30b3dc2b3..7adc9b1e4 100644 --- a/core/modules/ckeditor/js/ckeditor.admin.js +++ b/core/modules/ckeditor/js/ckeditor.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal, _, CKEDITOR) { - "use strict"; + 'use strict'; Drupal.ckeditor = Drupal.ckeditor || {}; diff --git a/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js b/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js index 05a2315e0..256bb41c0 100644 --- a/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js +++ b/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Provides the summary for the "drupalimage" plugin settings vertical tab. diff --git a/core/modules/ckeditor/js/ckeditor.js b/core/modules/ckeditor/js/ckeditor.js index 79350e527..313621f26 100644 --- a/core/modules/ckeditor/js/ckeditor.js +++ b/core/modules/ckeditor/js/ckeditor.js @@ -5,7 +5,7 @@ (function (Drupal, debounce, CKEDITOR, $) { - "use strict"; + 'use strict'; /** * @namespace @@ -34,7 +34,7 @@ // label so that screen readers say something that is understandable // for end users. var label = $('label[for=' + element.getAttribute('id') + ']').html(); - format.editorSettings.title = Drupal.t("Rich Text Editor, !label field", {'!label': label}); + format.editorSettings.title = Drupal.t('Rich Text Editor, !label field', {'!label': label}); return !!CKEDITOR.replace(element, format.editorSettings); }, @@ -249,7 +249,7 @@ // Moves the dialog to the top of the CKEDITOR stack. $(window).on('dialogcreate', function (e, dialog, $element, settings) { - $('.ui-dialog--narrow').css("zIndex", CKEDITOR.config.baseFloatZIndex + 1); + $('.ui-dialog--narrow').css('zIndex', CKEDITOR.config.baseFloatZIndex + 1); }); // Respond to new dialogs that are opened by CKEditor, closing the AJAX loader. diff --git a/core/modules/ckeditor/js/ckeditor.stylescombo.admin.js b/core/modules/ckeditor/js/ckeditor.stylescombo.admin.js index c61611319..5b8ad4a27 100644 --- a/core/modules/ckeditor/js/ckeditor.stylescombo.admin.js +++ b/core/modules/ckeditor/js/ckeditor.stylescombo.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Ensures that the "stylescombo" button's metadata remains up-to-date. @@ -66,8 +66,8 @@ _generateStylesSetSetting: function (styles) { var stylesSet = []; - styles = styles.replace(/\r/g, "\n"); - var lines = styles.split("\n"); + styles = styles.replace(/\r/g, '\n'); + var lines = styles.split('\n'); for (var i = 0; i < lines.length; i++) { var style = $.trim(lines[i]); @@ -118,7 +118,7 @@ return Drupal.t('No styles configured'); } else { - var count = $.trim(styles).split("\n").length; + var count = $.trim(styles).split('\n').length; return Drupal.t('@count styles configured', {'@count': count}); } }); diff --git a/core/modules/ckeditor/js/models/Model.js b/core/modules/ckeditor/js/models/Model.js index 201351b8e..162e363ea 100644 --- a/core/modules/ckeditor/js/models/Model.js +++ b/core/modules/ckeditor/js/models/Model.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; /** * Backbone model for the CKEditor toolbar configuration state. diff --git a/core/modules/ckeditor/js/plugins/drupalimage/plugin.js b/core/modules/ckeditor/js/plugins/drupalimage/plugin.js index 724fa5068..80921c250 100644 --- a/core/modules/ckeditor/js/plugins/drupalimage/plugin.js +++ b/core/modules/ckeditor/js/plugins/drupalimage/plugin.js @@ -15,7 +15,7 @@ (function ($, Drupal, CKEDITOR) { - "use strict"; + 'use strict'; CKEDITOR.plugins.add('drupalimage', { requires: 'image2', @@ -32,6 +32,7 @@ // Override requiredContent & allowedContent. widgetDefinition.requiredContent = new CKEDITOR.style({ element: 'img', + styles: {}, attributes: { 'alt': '', 'src': '', @@ -43,6 +44,7 @@ }); var allowedContentDefinition = { element: 'img', + styles: {}, attributes: { '!data-entity-type': '', '!data-entity-uuid': '' diff --git a/core/modules/ckeditor/js/plugins/drupalimagecaption/plugin.js b/core/modules/ckeditor/js/plugins/drupalimagecaption/plugin.js index 0963c0478..8dd91b170 100644 --- a/core/modules/ckeditor/js/plugins/drupalimagecaption/plugin.js +++ b/core/modules/ckeditor/js/plugins/drupalimagecaption/plugin.js @@ -12,7 +12,7 @@ (function (CKEDITOR) { - "use strict"; + 'use strict'; CKEDITOR.plugins.add('drupalimagecaption', { requires: 'drupalimage', diff --git a/core/modules/ckeditor/js/plugins/drupallink/plugin.js b/core/modules/ckeditor/js/plugins/drupallink/plugin.js index e595815f9..e9fb555b8 100644 --- a/core/modules/ckeditor/js/plugins/drupallink/plugin.js +++ b/core/modules/ckeditor/js/plugins/drupallink/plugin.js @@ -7,7 +7,7 @@ (function ($, Drupal, drupalSettings, CKEDITOR) { - "use strict"; + 'use strict'; CKEDITOR.plugins.add('drupallink', { init: function (editor) { @@ -15,6 +15,7 @@ editor.addCommand('drupallink', { allowedContent: new CKEDITOR.style({ element: 'a', + styles: {}, attributes: { '!href': '', 'target': '' @@ -22,6 +23,7 @@ }), requiredContent: new CKEDITOR.style({ element: 'a', + styles: {}, attributes: { href: '' } diff --git a/core/modules/ckeditor/js/views/AuralView.js b/core/modules/ckeditor/js/views/AuralView.js index 6acfb915d..0659eb206 100644 --- a/core/modules/ckeditor/js/views/AuralView.js +++ b/core/modules/ckeditor/js/views/AuralView.js @@ -6,7 +6,7 @@ (function (Drupal, Backbone, $) { - "use strict"; + 'use strict'; Drupal.ckeditor.AuralView = Backbone.View.extend(/** @lends Drupal.ckeditor.AuralView# */{ @@ -104,8 +104,8 @@ // If this position is the first in the last row then tell the user that // pressing the down arrow key will create a new row. if (position === 1 && row === rowCount) { - text += "\n"; - text += Drupal.t("Press the down arrow key to create a new row."); + text += '\n'; + text += Drupal.t('Press the down arrow key to create a new row.'); } Drupal.announce(text, 'assertive'); }, @@ -139,7 +139,7 @@ '@name': $button.children().attr('aria-label'), '@type': type }); - text += "\n" + Drupal.t('Press the down arrow key to activate.'); + text += '\n' + Drupal.t('Press the down arrow key to activate.'); Drupal.announce(text, 'assertive'); } @@ -157,14 +157,14 @@ // If this position is the first in the last row then tell the user that // pressing the down arrow key will create a new row. if (groupPosition === 1 && position === 1 && row === rowCount) { - text += "\n"; - text += Drupal.t("Press the down arrow key to create a new button group in a new row."); + text += '\n'; + text += Drupal.t('Press the down arrow key to create a new button group in a new row.'); } // If this position is the last one in this row then tell the user that // moving the button to the next group will create a new group. if (groupPosition === groupPositionCount && position === positionCount) { - text += "\n"; - text += Drupal.t("This is the last group. Move the button forward to create a new group."); + text += '\n'; + text += Drupal.t('This is the last group. Move the button forward to create a new group.'); } Drupal.announce(text, 'assertive'); } @@ -186,14 +186,14 @@ message = Drupal.t('The "@name" button is currently enabled.', { '@name': $link.attr('aria-label') }); - message += "\n" + Drupal.t('Use the keyboard arrow keys to change the position of this button.'); - message += "\n" + Drupal.t('Press the up arrow key on the top row to disable the button.'); + message += '\n' + Drupal.t('Use the keyboard arrow keys to change the position of this button.'); + message += '\n' + Drupal.t('Press the up arrow key on the top row to disable the button.'); } else { message = Drupal.t('The "@name" button is currently disabled.', { '@name': $link.attr('aria-label') }); - message += "\n" + Drupal.t('Use the down arrow key to move this button into the active toolbar.'); + message += '\n' + Drupal.t('Use the down arrow key to move this button into the active toolbar.'); } Drupal.announce(message); event.preventDefault(); @@ -215,15 +215,15 @@ message = Drupal.t('This @name is currently enabled.', { '@name': $link.attr('aria-label') }); - message += "\n" + Drupal.t('Use the keyboard arrow keys to change the position of this separator.'); + message += '\n' + Drupal.t('Use the keyboard arrow keys to change the position of this separator.'); } else { message = Drupal.t('Separators are used to visually split individual buttons.'); - message += "\n" + Drupal.t('This @name is currently disabled.', { + message += '\n' + Drupal.t('This @name is currently disabled.', { '@name': $link.attr('aria-label') }); - message += "\n" + Drupal.t('Use the down arrow key to move this separator into the active toolbar.'); - message += "\n" + Drupal.t('You may add multiple separators to each button group.'); + message += '\n' + Drupal.t('Use the down arrow key to move this separator into the active toolbar.'); + message += '\n' + Drupal.t('You may add multiple separators to each button group.'); } Drupal.announce(message); event.preventDefault(); diff --git a/core/modules/ckeditor/js/views/ControllerView.js b/core/modules/ckeditor/js/views/ControllerView.js index 7cfaeeed0..8d215a1a7 100644 --- a/core/modules/ckeditor/js/views/ControllerView.js +++ b/core/modules/ckeditor/js/views/ControllerView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone, $) { - "use strict"; + 'use strict'; Drupal.ckeditor.ControllerView = Backbone.View.extend(/** @lends Drupal.ckeditor.ControllerView# */{ diff --git a/core/modules/ckeditor/js/views/KeyboardView.js b/core/modules/ckeditor/js/views/KeyboardView.js index 642598033..27d6c8897 100644 --- a/core/modules/ckeditor/js/views/KeyboardView.js +++ b/core/modules/ckeditor/js/views/KeyboardView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone, $) { - "use strict"; + 'use strict'; Drupal.ckeditor.KeyboardView = Backbone.View.extend(/** @lends Drupal.ckeditor.KeyboardView# */{ diff --git a/core/modules/ckeditor/js/views/VisualView.js b/core/modules/ckeditor/js/views/VisualView.js index c165152b3..2d8042ebb 100644 --- a/core/modules/ckeditor/js/views/VisualView.js +++ b/core/modules/ckeditor/js/views/VisualView.js @@ -6,7 +6,7 @@ (function (Drupal, Backbone, $) { - "use strict"; + 'use strict'; Drupal.ckeditor.VisualView = Backbone.View.extend(/** @lends Drupal.ckeditor.VisualView# */{ diff --git a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php index d3eb49f1b..47b39aaa1 100644 --- a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php +++ b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php @@ -9,7 +9,6 @@ use Drupal\ckeditor\CKEditorPluginBase; use Drupal\ckeditor\CKEditorPluginConfigurableInterface; -use Drupal\Component\Utility\NestedArray; use Drupal\Core\Form\FormStateInterface; use Drupal\editor\Entity\Editor; diff --git a/core/modules/ckeditor/src/Plugin/Editor/CKEditor.php b/core/modules/ckeditor/src/Plugin/Editor/CKEditor.php index 914c1b453..abf409b64 100644 --- a/core/modules/ckeditor/src/Plugin/Editor/CKEditor.php +++ b/core/modules/ckeditor/src/Plugin/Editor/CKEditor.php @@ -7,7 +7,6 @@ namespace Drupal\ckeditor\Plugin\Editor; -use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\ckeditor\CKEditorPluginManager; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/ckeditor/src/Tests/CKEditorPluginManagerTest.php b/core/modules/ckeditor/src/Tests/CKEditorPluginManagerTest.php index 96cf56f54..aec8dbb89 100644 --- a/core/modules/ckeditor/src/Tests/CKEditorPluginManagerTest.php +++ b/core/modules/ckeditor/src/Tests/CKEditorPluginManagerTest.php @@ -8,7 +8,6 @@ namespace Drupal\ckeditor\Tests; use Drupal\simpletest\KernelTestBase; -use Drupal\ckeditor\CKEditorPluginManager; /** * Tests different ways of enabling CKEditor plugins. diff --git a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaButton.php b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaButton.php index 855f81745..6fa198177 100644 --- a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaButton.php +++ b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaButton.php @@ -8,7 +8,6 @@ namespace Drupal\ckeditor_test\Plugin\CKEditorPlugin; use Drupal\ckeditor\CKEditorPluginButtonsInterface; -use Drupal\Component\Plugin\PluginBase; /** * Defines a "LlamaButton" plugin, with a toolbar builder-enabled "llama" feature. diff --git a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextual.php b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextual.php index 16bb68acc..8a52ff49d 100644 --- a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextual.php +++ b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextual.php @@ -8,7 +8,6 @@ namespace Drupal\ckeditor_test\Plugin\CKEditorPlugin; use Drupal\ckeditor\CKEditorPluginContextualInterface; -use Drupal\Component\Plugin\PluginBase; use Drupal\editor\Entity\Editor; /** diff --git a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextualAndButton.php b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextualAndButton.php index 4c43cb754..358742bd3 100644 --- a/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextualAndButton.php +++ b/core/modules/ckeditor/tests/modules/src/Plugin/CKEditorPlugin/LlamaContextualAndButton.php @@ -10,7 +10,6 @@ use Drupal\ckeditor\CKEditorPluginButtonsInterface; use Drupal\ckeditor\CKEditorPluginContextualInterface; use Drupal\ckeditor\CKEditorPluginConfigurableInterface; -use Drupal\Component\Plugin\PluginBase; use Drupal\Core\Form\FormStateInterface; use Drupal\editor\Entity\Editor; diff --git a/core/modules/color/color.js b/core/modules/color/color.js index 437dffeb7..a870e9ea1 100644 --- a/core/modules/color/color.js +++ b/core/modules/color/color.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Displays farbtastic color selector and initialize color administration UI. diff --git a/core/modules/color/preview.js b/core/modules/color/preview.js index 551cfd7a1..0796ee908 100644 --- a/core/modules/color/preview.js +++ b/core/modules/color/preview.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Namespace for color-related functionality for Drupal. diff --git a/core/modules/color/tests/modules/color_test/themes/color_test_theme/js/color_test_theme-fontsize.js b/core/modules/color/tests/modules/color_test/themes/color_test_theme/js/color_test_theme-fontsize.js index 109f7438a..232428164 100644 --- a/core/modules/color/tests/modules/color_test/themes/color_test_theme/js/color_test_theme-fontsize.js +++ b/core/modules/color/tests/modules/color_test/themes/color_test_theme/js/color_test_theme-fontsize.js @@ -3,7 +3,7 @@ * Adds javascript functions for font resizing. */ (function ($) { - "use strict"; + 'use strict'; $(document).ready(function () {}); })(jQuery); diff --git a/core/modules/comment/comment-entity-form.js b/core/modules/comment/comment-entity-form.js index 3cdf08c65..3ad1a3d74 100644 --- a/core/modules/comment/comment-entity-form.js +++ b/core/modules/comment/comment-entity-form.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * diff --git a/core/modules/comment/comment.api.php b/core/modules/comment/comment.api.php index 563cc5d4b..4b79b3686 100644 --- a/core/modules/comment/comment.api.php +++ b/core/modules/comment/comment.api.php @@ -1,6 +1,5 @@ COMMENT_MODE_FLAT + 1: 0 + # COMMENT_MODE_FLAT_EXPANDED --> COMMENT_MODE_FLAT + 2: 0 + # COMMENT_MODE_THREADED_COLLAPSED --> COMMENT_MODE_THREADED + 3: 1 + # COMMENT_MODE_THREADED_EXPANDED --> COMMENT_MODE_THREADED + 4: 1 'settings/per_page': comment_default_per_page 'settings/anonymous': comment_anonymous 'settings/form_location': comment_form_location diff --git a/core/modules/comment/src/CommentForm.php b/core/modules/comment/src/CommentForm.php index 15d1ece46..df59363c0 100644 --- a/core/modules/comment/src/CommentForm.php +++ b/core/modules/comment/src/CommentForm.php @@ -10,13 +10,11 @@ use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Cache\Cache; use Drupal\Core\Datetime\DrupalDateTime; use Drupal\Core\Entity\ContentEntityForm; use Drupal\Core\Entity\EntityConstraintViolationListInterface; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Render\RendererInterface; use Drupal\Core\Session\AccountInterface; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -265,7 +263,7 @@ protected function actions(array $form, FormStateInterface $form_state) { public function buildEntity(array $form, FormStateInterface $form_state) { /** @var \Drupal\comment\CommentInterface $comment */ $comment = parent::buildEntity($form, $form_state); - if (!$form_state->isValueEmpty('date') && $form_state->getValue('date') instanceOf DrupalDateTime) { + if (!$form_state->isValueEmpty('date') && $form_state->getValue('date') instanceof DrupalDateTime) { $comment->setCreatedTime($form_state->getValue('date')->getTimestamp()); } else { diff --git a/core/modules/comment/src/CommentLinkBuilder.php b/core/modules/comment/src/CommentLinkBuilder.php index 7ce175c8b..8d43f2fe3 100644 --- a/core/modules/comment/src/CommentLinkBuilder.php +++ b/core/modules/comment/src/CommentLinkBuilder.php @@ -208,7 +208,7 @@ public function buildCommentedEntityLinks(FieldableEntityInterface $entity, arra if ($new_comments > 0) { $page_number = $this->entityManager ->getStorage('comment') - ->getNewCommentPageNumber($entity->{$field_name}->comment_count, $new_comments, $entity); + ->getNewCommentPageNumber($entity->{$field_name}->comment_count, $new_comments, $entity, $field_name); $query = $page_number ? ['page' => $page_number] : NULL; $value = [ 'new_comment_count' => (int) $new_comments, diff --git a/core/modules/comment/src/CommentManager.php b/core/modules/comment/src/CommentManager.php index 729f3dc4e..496132424 100644 --- a/core/modules/comment/src/CommentManager.php +++ b/core/modules/comment/src/CommentManager.php @@ -8,7 +8,6 @@ namespace Drupal\comment; use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; -use Drupal\Component\Utility\Unicode; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; diff --git a/core/modules/comment/src/CommentManagerInterface.php b/core/modules/comment/src/CommentManagerInterface.php index 2c9a53163..de8492c8b 100644 --- a/core/modules/comment/src/CommentManagerInterface.php +++ b/core/modules/comment/src/CommentManagerInterface.php @@ -8,8 +8,6 @@ namespace Drupal\comment; use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Session\AccountInterface; -use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; /** * Comment manager contains common functions to manage comment fields. diff --git a/core/modules/comment/src/CommentStorage.php b/core/modules/comment/src/CommentStorage.php index 7737d4456..d387c841c 100644 --- a/core/modules/comment/src/CommentStorage.php +++ b/core/modules/comment/src/CommentStorage.php @@ -135,7 +135,7 @@ public function getDisplayOrdinal(CommentInterface $comment, $comment_mode, $div /** * {@inheritdoc} */ - public function getNewCommentPageNumber($total_comments, $new_comments, FieldableEntityInterface $entity, $field_name = 'comment') { + public function getNewCommentPageNumber($total_comments, $new_comments, FieldableEntityInterface $entity, $field_name) { $field = $entity->getFieldDefinition($field_name); $comments_per_page = $field->getSetting('per_page'); diff --git a/core/modules/comment/src/CommentStorageInterface.php b/core/modules/comment/src/CommentStorageInterface.php index 5be477646..318c0b4e4 100644 --- a/core/modules/comment/src/CommentStorageInterface.php +++ b/core/modules/comment/src/CommentStorageInterface.php @@ -54,7 +54,7 @@ public function getMaxThreadPerThread(CommentInterface $comment); * @return array|null * The page number where first new comment appears. (First page returns 0.) */ - public function getNewCommentPageNumber($total_comments, $new_comments, FieldableEntityInterface $entity, $field_name = 'comment'); + public function getNewCommentPageNumber($total_comments, $new_comments, FieldableEntityInterface $entity, $field_name); /** * Gets the display ordinal or page number for a comment. diff --git a/core/modules/comment/src/CommentTypeForm.php b/core/modules/comment/src/CommentTypeForm.php index 3c7ef6af6..12d65fb15 100644 --- a/core/modules/comment/src/CommentTypeForm.php +++ b/core/modules/comment/src/CommentTypeForm.php @@ -7,7 +7,6 @@ namespace Drupal\comment; -use Drupal\Core\Entity\ContentEntityTypeInterface; use Drupal\Core\Entity\EntityForm; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Entity\EntityTypeInterface; diff --git a/core/modules/comment/src/CommentViewBuilder.php b/core/modules/comment/src/CommentViewBuilder.php index f17649e4d..22914d310 100644 --- a/core/modules/comment/src/CommentViewBuilder.php +++ b/core/modules/comment/src/CommentViewBuilder.php @@ -7,7 +7,6 @@ namespace Drupal\comment; -use Drupal\Core\Cache\Cache; use Drupal\Core\Entity\Display\EntityViewDisplayInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; diff --git a/core/modules/comment/src/Controller/CommentController.php b/core/modules/comment/src/Controller/CommentController.php index ef86d5dd5..bcc6a8df6 100644 --- a/core/modules/comment/src/Controller/CommentController.php +++ b/core/modules/comment/src/Controller/CommentController.php @@ -335,7 +335,7 @@ public function renderNewCommentsNodeLinks(Request $request) { $node = $this->entityManager->getStorage('node')->load($nid); $new = $this->commentManager->getCountNewComments($node); $page_number = $this->entityManager()->getStorage('comment') - ->getNewCommentPageNumber($node->{$field_name}->comment_count, $new, $node); + ->getNewCommentPageNumber($node->{$field_name}->comment_count, $new, $node, $field_name); $query = $page_number ? array('page' => $page_number) : NULL; $links[$nid] = array( 'new_comment_count' => (int) $new, diff --git a/core/modules/comment/src/Entity/CommentType.php b/core/modules/comment/src/Entity/CommentType.php index 94fd193bb..3e6ba0a8a 100644 --- a/core/modules/comment/src/Entity/CommentType.php +++ b/core/modules/comment/src/Entity/CommentType.php @@ -8,7 +8,6 @@ namespace Drupal\comment\Entity; use Drupal\Core\Config\Entity\ConfigEntityBundleBase; -use Drupal\Core\Entity\EntityStorageInterface; use Drupal\comment\CommentTypeInterface; /** diff --git a/core/modules/comment/src/Form/CommentTypeDeleteForm.php b/core/modules/comment/src/Form/CommentTypeDeleteForm.php index deac0acfb..f37e47b2a 100644 --- a/core/modules/comment/src/Form/CommentTypeDeleteForm.php +++ b/core/modules/comment/src/Form/CommentTypeDeleteForm.php @@ -12,7 +12,6 @@ use Drupal\Core\Entity\EntityManager; use Drupal\Core\Entity\Query\QueryFactory; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Url; use Drupal\field\Entity\FieldStorageConfig; use Psr\Log\LoggerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php b/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php index ac641b6c8..64ff3015f 100644 --- a/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php +++ b/core/modules/comment/src/Plugin/Field/FieldFormatter/CommentDefaultFormatter.php @@ -7,12 +7,8 @@ namespace Drupal\comment\Plugin\Field\FieldFormatter; -use Drupal\comment\CommentManagerInterface; -use Drupal\comment\CommentStorageInterface; -use Drupal\comment\Entity\Comment; use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; use Drupal\Core\Entity\EntityManagerInterface; -use Drupal\Core\Entity\EntityViewBuilderInterface; use Drupal\Core\Entity\EntityFormBuilderInterface; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/comment/src/Plugin/views/field/NodeNewComments.php b/core/modules/comment/src/Plugin/views/field/NodeNewComments.php index 55d161354..6b223b1ca 100644 --- a/core/modules/comment/src/Plugin/views/field/NodeNewComments.php +++ b/core/modules/comment/src/Plugin/views/field/NodeNewComments.php @@ -161,12 +161,28 @@ public function preRender(&$values) { */ protected function renderLink($data, ResultRow $values) { if (!empty($this->options['link_to_comment']) && $data !== NULL && $data !== '') { + $node_type = $this->getValue($values, 'type'); $node = entity_create('node', array( 'nid' => $this->getValue($values, 'nid'), - 'type' => $this->getValue($values, 'type'), + 'type' => $node_type, )); - $page_number = \Drupal::entityManager()->getStorage('comment') - ->getNewCommentPageNumber($this->getValue($values, 'comment_count'), $this->getValue($values), $node); + // Because there is no support for selecting a specific comment field to + // reference, we arbitrarily use the first such field name we find. + // @todo Provide a means for selecting the comment field. + // https://www.drupal.org/node/2594201 + $entity_manager = \Drupal::entityManager(); + $field_map = $entity_manager->getFieldMapByFieldType('comment'); + $comment_field_name = 'comment'; + foreach ($field_map['node'] as $field_name => $field_data) { + foreach ($field_data['bundles'] as $bundle_name) { + if ($node_type == $bundle_name) { + $comment_field_name = $field_name; + break 2; + } + } + } + $page_number = $entity_manager->getStorage('comment') + ->getNewCommentPageNumber($this->getValue($values, 'comment_count'), $this->getValue($values), $node, $comment_field_name); $this->options['alter']['make_link'] = TRUE; $this->options['alter']['url'] = $node->urlInfo(); $this->options['alter']['query'] = $page_number ? array('page' => $page_number) : NULL; diff --git a/core/modules/comment/src/Plugin/views/wizard/Comment.php b/core/modules/comment/src/Plugin/views/wizard/Comment.php index 366e2565e..6f9dd7990 100644 --- a/core/modules/comment/src/Plugin/views/wizard/Comment.php +++ b/core/modules/comment/src/Plugin/views/wizard/Comment.php @@ -7,7 +7,6 @@ namespace Drupal\comment\Plugin\views\wizard; -use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\wizard\WizardPluginBase; /** diff --git a/core/modules/comment/src/Tests/CommentDefaultFormatterCacheTagsTest.php b/core/modules/comment/src/Tests/CommentDefaultFormatterCacheTagsTest.php index 2c9a86733..1164ba044 100644 --- a/core/modules/comment/src/Tests/CommentDefaultFormatterCacheTagsTest.php +++ b/core/modules/comment/src/Tests/CommentDefaultFormatterCacheTagsTest.php @@ -8,7 +8,6 @@ namespace Drupal\comment\Tests; use Drupal\Core\Cache\Cache; -use Drupal\Core\Session\UserSession; use Drupal\comment\CommentInterface; use Drupal\system\Tests\Entity\EntityUnitTestBase; use Symfony\Component\HttpFoundation\Request; diff --git a/core/modules/comment/src/Tests/CommentFieldAccessTest.php b/core/modules/comment/src/Tests/CommentFieldAccessTest.php index c79def258..e55dbfb03 100644 --- a/core/modules/comment/src/Tests/CommentFieldAccessTest.php +++ b/core/modules/comment/src/Tests/CommentFieldAccessTest.php @@ -243,7 +243,7 @@ public function testAccessToAdministrativeFields() { foreach ($permutations as $set) { $may_view = $set['comment']->{$field}->access('view', $set['user']); $may_update = $set['comment']->{$field}->access('edit', $set['user']); - // Nobody has access to to view the hostname field. + // Nobody has access to view the hostname field. if ($field === 'hostname') { $view_access = FALSE; $state = 'cannot'; diff --git a/core/modules/comment/src/Tests/CommentFieldsTest.php b/core/modules/comment/src/Tests/CommentFieldsTest.php index 77cbbc072..408b78242 100644 --- a/core/modules/comment/src/Tests/CommentFieldsTest.php +++ b/core/modules/comment/src/Tests/CommentFieldsTest.php @@ -94,6 +94,55 @@ public function testCommentFieldDelete() { $this->assertEqual(1, count($elements), 'There is one comment field on the node.'); } + /** + * Tests link building with non-default comment field names. + */ + public function testCommentFieldLinksNonDefaultName() { + $this->drupalCreateContentType(['type' => 'test_node_type']); + $this->addDefaultCommentField('node', 'test_node_type', 'comment2'); + + $web_user2 = $this->drupalCreateUser([ + 'access comments', + 'post comments', + 'create article content', + 'edit own comments', + 'skip comment approval', + 'access content', + ]); + + // Create a sample node. + $node = $this->drupalCreateNode([ + 'title' => 'Baloney', + 'type' => 'test_node_type', + ]); + + // Go to the node first so that webuser2 see new comments. + $this->drupalLogin($web_user2); + $this->drupalGet($node->urlInfo()); + $this->drupalLogout(); + + // Test that buildCommentedEntityLinks() does not break when the 'comment' + // field does not exist. Requires at least one comment. + $this->drupalLogin($this->webUser); + $this->postComment($node, 'Here is a comment', '', NULL, 'comment2'); + $this->drupalLogout(); + + $this->drupalLogin($web_user2); + + // We want to check the attached drupalSettings of + // \Drupal\comment\CommentLinkBuilder::buildCommentedEntityLinks. Therefore + // we need a node listing, let's use views for that. + $this->container->get('module_installer')->install(['views'], TRUE); + // We also need a router rebuild, as the router is lazily rebuild in the + // module installer. + \Drupal::service('router.builder')->rebuild(); + $this->drupalGet('node'); + + $link_info = $this->getDrupalSettings()['comment']['newCommentsLinks']['node']['comment2']['2']; + $this->assertIdentical($link_info['new_comment_count'], 1); + $this->assertIdentical($link_info['first_new_comment_link'], $node->url('canonical', ['fragment' => 'new'])); + } + /** * Tests creating a comment field through the interface. */ diff --git a/core/modules/comment/src/Tests/CommentNonNodeTest.php b/core/modules/comment/src/Tests/CommentNonNodeTest.php index 98099fb85..c7f3e71a5 100644 --- a/core/modules/comment/src/Tests/CommentNonNodeTest.php +++ b/core/modules/comment/src/Tests/CommentNonNodeTest.php @@ -435,7 +435,7 @@ function testCommentFunctionality() { $data = array('bundle' => 'entity_test', 'name' => $random_label); $new_entity = entity_create('entity_test', $data); $new_entity->save(); - $this->drupalGet('entity_test/manage/' . $new_entity->id()); + $this->drupalGet('entity_test/manage/' . $new_entity->id() . '/edit'); $this->assertNoFieldChecked('edit-field-foobar-0-status-1'); $this->assertFieldChecked('edit-field-foobar-0-status-2'); $this->assertNoField('edit-field-foobar-0-status-0'); diff --git a/core/modules/comment/src/Tests/CommentPagerTest.php b/core/modules/comment/src/Tests/CommentPagerTest.php index 92fc9ff0e..9061f648f 100644 --- a/core/modules/comment/src/Tests/CommentPagerTest.php +++ b/core/modules/comment/src/Tests/CommentPagerTest.php @@ -250,7 +250,7 @@ function testCommentNewPageIndicator() { $node = Node::load($node->id()); foreach ($expected_pages as $new_replies => $expected_page) { $returned_page = \Drupal::entityManager()->getStorage('comment') - ->getNewCommentPageNumber($node->get('comment')->comment_count, $new_replies, $node); + ->getNewCommentPageNumber($node->get('comment')->comment_count, $new_replies, $node, 'comment'); $this->assertIdentical($expected_page, $returned_page, format_string('Flat mode, @new replies: expected page @expected, returned page @returned.', array('@new' => $new_replies, '@expected' => $expected_page, '@returned' => $returned_page))); } @@ -269,7 +269,7 @@ function testCommentNewPageIndicator() { $node = Node::load($node->id()); foreach ($expected_pages as $new_replies => $expected_page) { $returned_page = \Drupal::entityManager()->getStorage('comment') - ->getNewCommentPageNumber($node->get('comment')->comment_count, $new_replies, $node); + ->getNewCommentPageNumber($node->get('comment')->comment_count, $new_replies, $node, 'comment'); $this->assertEqual($expected_page, $returned_page, format_string('Threaded mode, @new replies: expected page @expected, returned page @returned.', array('@new' => $new_replies, '@expected' => $expected_page, '@returned' => $returned_page))); } } diff --git a/core/modules/comment/src/Tests/CommentTokenReplaceTest.php b/core/modules/comment/src/Tests/CommentTokenReplaceTest.php index b7172e354..60f1c28d1 100644 --- a/core/modules/comment/src/Tests/CommentTokenReplaceTest.php +++ b/core/modules/comment/src/Tests/CommentTokenReplaceTest.php @@ -10,7 +10,6 @@ use Drupal\Component\Render\FormattableMarkup; use Drupal\Component\Utility\Html; use Drupal\Component\Utility\UrlHelper; -use Drupal\Component\Utility\Xss; use Drupal\comment\Entity\Comment; use Drupal\Core\Render\BubbleableMetadata; use Drupal\node\Entity\Node; diff --git a/core/modules/comment/src/Tests/Migrate/d6/MigrateCommentVariableInstanceTest.php b/core/modules/comment/src/Tests/Migrate/d6/MigrateCommentVariableInstanceTest.php index 2ceb33aa4..7b501255d 100644 --- a/core/modules/comment/src/Tests/Migrate/d6/MigrateCommentVariableInstanceTest.php +++ b/core/modules/comment/src/Tests/Migrate/d6/MigrateCommentVariableInstanceTest.php @@ -7,6 +7,7 @@ namespace Drupal\comment\Tests\Migrate\d6; +use Drupal\comment\CommentManagerInterface; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; use Drupal\node\Entity\Node; @@ -44,21 +45,21 @@ public function testCommentFieldInstance() { $this->assertIdentical(0, $node->comment->status); $this->assertIdentical('comment', $node->comment->getFieldDefinition()->getName()); $settings = $node->comment->getFieldDefinition()->getSettings(); - $this->assertIdentical(4, $settings['default_mode']); + $this->assertIdentical(CommentManagerInterface::COMMENT_MODE_THREADED, $settings['default_mode']); $this->assertIdentical(50, $settings['per_page']); - $this->assertIdentical(0, $settings['anonymous']); - $this->assertIdentical(FALSE, $settings['form_location']); - $this->assertIdentical(1, $settings['preview']); + $this->assertFalse($settings['anonymous']); + $this->assertFalse($settings['form_location']); + $this->assertTrue($settings['preview']); $node = Node::create(['type' => 'story']); $this->assertIdentical(2, $node->comment_no_subject->status); $this->assertIdentical('comment_no_subject', $node->comment_no_subject->getFieldDefinition()->getName()); $settings = $node->comment_no_subject->getFieldDefinition()->getSettings(); - $this->assertIdentical(2, $settings['default_mode']); + $this->assertIdentical(CommentManagerInterface::COMMENT_MODE_FLAT, $settings['default_mode']); $this->assertIdentical(70, $settings['per_page']); - $this->assertIdentical(1, $settings['anonymous']); - $this->assertIdentical(FALSE, $settings['form_location']); - $this->assertIdentical(0, $settings['preview']); + $this->assertTrue($settings['anonymous']); + $this->assertFalse($settings['form_location']); + $this->assertFalse($settings['preview']); } } diff --git a/core/modules/comment/src/Tests/Migrate/d7/MigrateCommentTest.php b/core/modules/comment/src/Tests/Migrate/d7/MigrateCommentTest.php index 6c7277e7e..8d6e668df 100644 --- a/core/modules/comment/src/Tests/Migrate/d7/MigrateCommentTest.php +++ b/core/modules/comment/src/Tests/Migrate/d7/MigrateCommentTest.php @@ -11,7 +11,6 @@ use Drupal\comment\Entity\Comment; use Drupal\migrate_drupal\Tests\d7\MigrateDrupal7TestBase; use Drupal\node\NodeInterface; -use Drupal\user\Entity\User; /** * Tests migration of comments from Drupal 7. @@ -37,12 +36,6 @@ protected function setUp() { 'd7_user_role', 'd7_user', ]); - // The test database doesn't include uid 1, so we'll need to create it. - User::create(array( - 'uid' => 1, - 'name' => 'admin', - 'mail' => 'admin@local.host', - ))->save(); $this->executeMigration('d7_node_type'); // We only need the test_content_type node migration to run for real, so // mock all the others. diff --git a/core/modules/comment/tests/modules/comment_empty_title_test/comment_empty_title_test.module b/core/modules/comment/tests/modules/comment_empty_title_test/comment_empty_title_test.module index d9a050390..1fdbd6d86 100644 --- a/core/modules/comment/tests/modules/comment_empty_title_test/comment_empty_title_test.module +++ b/core/modules/comment/tests/modules/comment_empty_title_test/comment_empty_title_test.module @@ -6,8 +6,6 @@ * markup in edge case scenarios where comments have empty titles. */ -use Drupal\comment\CommentInterface; - /** * Implements hook_preprocess_comment(). */ diff --git a/core/modules/comment/tests/src/Unit/Entity/CommentLockTest.php b/core/modules/comment/tests/src/Unit/Entity/CommentLockTest.php index 3289e3cb2..021e7b660 100644 --- a/core/modules/comment/tests/src/Unit/Entity/CommentLockTest.php +++ b/core/modules/comment/tests/src/Unit/Entity/CommentLockTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\comment\Unit\Entity; use Drupal\Core\DependencyInjection\ContainerBuilder; -use Drupal\Core\Entity\EntityType; use Drupal\Tests\UnitTestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/core/modules/config/src/ConfigSubscriber.php b/core/modules/config/src/ConfigSubscriber.php index 9da0233f8..ae71a1de5 100644 --- a/core/modules/config/src/ConfigSubscriber.php +++ b/core/modules/config/src/ConfigSubscriber.php @@ -9,7 +9,6 @@ use Drupal\Core\Config\ConfigEvents; use Drupal\Core\Config\ConfigImporterEvent; -use Drupal\Core\Config\ConfigImporterException; use Drupal\Core\Config\ConfigImportValidateEventSubscriberBase; diff --git a/core/modules/config/src/Form/ConfigSync.php b/core/modules/config/src/Form/ConfigSync.php index 3c1769771..03de002da 100644 --- a/core/modules/config/src/Form/ConfigSync.php +++ b/core/modules/config/src/Form/ConfigSync.php @@ -7,11 +7,9 @@ namespace Drupal\config\Form; -use Drupal\Component\Uuid\UuidInterface; use Drupal\Core\Config\ConfigImporterException; use Drupal\Core\Config\ConfigImporter; use Drupal\Core\Config\TypedConfigManagerInterface; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Extension\ModuleInstallerInterface; use Drupal\Core\Extension\ThemeHandlerInterface; diff --git a/core/modules/config/src/Tests/ConfigCRUDTest.php b/core/modules/config/src/Tests/ConfigCRUDTest.php index 70b891975..6258ccc12 100644 --- a/core/modules/config/src/Tests/ConfigCRUDTest.php +++ b/core/modules/config/src/Tests/ConfigCRUDTest.php @@ -12,7 +12,6 @@ use Drupal\Core\Config\ConfigValueException; use Drupal\Core\Config\InstallStorage; use Drupal\simpletest\KernelTestBase; -use Drupal\Core\Config\FileStorage; use Drupal\Core\Config\DatabaseStorage; use Drupal\Core\Config\UnsupportedDataTypeConfigException; diff --git a/core/modules/config/src/Tests/ConfigEntityStatusUITest.php b/core/modules/config/src/Tests/ConfigEntityStatusUITest.php index 87ad9a1b2..b959acc43 100644 --- a/core/modules/config/src/Tests/ConfigEntityStatusUITest.php +++ b/core/modules/config/src/Tests/ConfigEntityStatusUITest.php @@ -7,7 +7,6 @@ namespace Drupal\config\Tests; -use Drupal\Core\Entity\EntityMalformedException; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/config/src/Tests/ConfigEntityUnitTest.php b/core/modules/config/src/Tests/ConfigEntityUnitTest.php index b7249a3db..dd6a58662 100644 --- a/core/modules/config/src/Tests/ConfigEntityUnitTest.php +++ b/core/modules/config/src/Tests/ConfigEntityUnitTest.php @@ -7,7 +7,6 @@ namespace Drupal\config\Tests; -use Drupal\Core\Entity\EntityInterface; use Drupal\simpletest\KernelTestBase; /** diff --git a/core/modules/config/src/Tests/ConfigImporterMissingContentTest.php b/core/modules/config/src/Tests/ConfigImporterMissingContentTest.php index 7990da3db..cb5522db7 100644 --- a/core/modules/config/src/Tests/ConfigImporterMissingContentTest.php +++ b/core/modules/config/src/Tests/ConfigImporterMissingContentTest.php @@ -7,9 +7,7 @@ namespace Drupal\config\Tests; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Config\ConfigImporter; -use Drupal\Core\Config\ConfigImporterException; use Drupal\Core\Config\StorageComparer; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/config/src/Tests/ConfigInstallTest.php b/core/modules/config/src/Tests/ConfigInstallTest.php index 7358e65c6..e5ac68dda 100644 --- a/core/modules/config/src/Tests/ConfigInstallTest.php +++ b/core/modules/config/src/Tests/ConfigInstallTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Config\InstallStorage; use Drupal\Core\Config\PreExistingConfigException; -use Drupal\Core\Config\StorageInterface; use Drupal\Core\Config\UnmetDependenciesException; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/config/src/Tests/DefaultConfigTest.php b/core/modules/config/src/Tests/DefaultConfigTest.php index 330cfb25e..2610c3df0 100644 --- a/core/modules/config/src/Tests/DefaultConfigTest.php +++ b/core/modules/config/src/Tests/DefaultConfigTest.php @@ -9,7 +9,6 @@ use Drupal\config_test\TestInstallStorage; use Drupal\Core\Config\InstallStorage; -use Drupal\Core\Config\TypedConfigManager; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\simpletest\KernelTestBase; use Symfony\Component\DependencyInjection\Reference; diff --git a/core/modules/config/src/Tests/SchemaConfigListenerTest.php b/core/modules/config/src/Tests/SchemaConfigListenerTest.php index bac62453b..58939b6b3 100644 --- a/core/modules/config/src/Tests/SchemaConfigListenerTest.php +++ b/core/modules/config/src/Tests/SchemaConfigListenerTest.php @@ -7,7 +7,6 @@ namespace Drupal\config\Tests; -use Drupal\Core\Config\Schema\SchemaCheckTrait; use Drupal\Core\Config\Schema\SchemaIncompleteException; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/config/src/Tests/SchemaConfigListenerWebTest.php b/core/modules/config/src/Tests/SchemaConfigListenerWebTest.php index 65ca4c34c..26bb9307b 100644 --- a/core/modules/config/src/Tests/SchemaConfigListenerWebTest.php +++ b/core/modules/config/src/Tests/SchemaConfigListenerWebTest.php @@ -7,9 +7,7 @@ namespace Drupal\config\Tests; -use Drupal\Core\Config\Schema\SchemaCheckTrait; use Drupal\Core\Config\Schema\SchemaIncompleteException; -use Drupal\simpletest\KernelTestBase; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/config/src/Tests/Storage/CachedStorageTest.php b/core/modules/config/src/Tests/Storage/CachedStorageTest.php index 4d8a8ac0a..402d87abd 100644 --- a/core/modules/config/src/Tests/Storage/CachedStorageTest.php +++ b/core/modules/config/src/Tests/Storage/CachedStorageTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Config\FileStorage; use Drupal\Core\Config\CachedStorage; -use Drupal\Core\Database\Database; use Drupal\Core\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Reference; diff --git a/core/modules/config/tests/config_test/config_test.module b/core/modules/config/tests/config_test/config_test.module index 9510abab6..08aeac61e 100644 --- a/core/modules/config/tests/config_test/config_test.module +++ b/core/modules/config/tests/config_test/config_test.module @@ -6,7 +6,6 @@ */ use Drupal\config_test\Entity\ConfigTest; -use Symfony\Component\HttpFoundation\RedirectResponse; require_once dirname(__FILE__) . '/config_test.hooks.inc'; diff --git a/core/modules/config/tests/config_test/src/ConfigTestController.php b/core/modules/config/tests/config_test/src/ConfigTestController.php index a195a6e06..6b1bd3305 100644 --- a/core/modules/config/tests/config_test/src/ConfigTestController.php +++ b/core/modules/config/tests/config_test/src/ConfigTestController.php @@ -9,7 +9,6 @@ use Drupal\Core\Controller\ControllerBase; use Drupal\config_test\Entity\ConfigTest; -use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\RedirectResponse; /** diff --git a/core/modules/config_translation/config_translation.module b/core/modules/config_translation/config_translation.module index d7274cbfa..93b280fc3 100644 --- a/core/modules/config_translation/config_translation.module +++ b/core/modules/config_translation/config_translation.module @@ -5,11 +5,9 @@ * Configuration Translation module. */ -use Drupal\config_translation\Plugin\Derivative\ConfigTranslationLocalTasks; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\field\FieldConfigInterface; -use Symfony\Component\Routing\Exception\RouteNotFoundException; /** * Implements hook_help(). diff --git a/core/modules/config_translation/src/ConfigEntityMapper.php b/core/modules/config_translation/src/ConfigEntityMapper.php index 541101bdc..7caf72cae 100644 --- a/core/modules/config_translation/src/ConfigEntityMapper.php +++ b/core/modules/config_translation/src/ConfigEntityMapper.php @@ -12,7 +12,6 @@ use Drupal\Core\Config\TypedConfigManagerInterface; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Language\LanguageManagerInterface; -use Drupal\Core\Routing\RouteMatch; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\StringTranslation\TranslationInterface; diff --git a/core/modules/config_translation/src/ConfigMapperInterface.php b/core/modules/config_translation/src/ConfigMapperInterface.php index 90d405ac9..507b191b4 100644 --- a/core/modules/config_translation/src/ConfigMapperInterface.php +++ b/core/modules/config_translation/src/ConfigMapperInterface.php @@ -9,7 +9,6 @@ use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Routing\RouteMatchInterface; -use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\RouteCollection; /** @@ -175,6 +174,9 @@ public function getConfigNames(); /** * Adds the given configuration name to the list of names. * + * Note that it is the responsibility of the calling code to ensure that the + * configuration exists. + * * @param string $name * Configuration name. */ diff --git a/core/modules/config_translation/src/ConfigNamesMapper.php b/core/modules/config_translation/src/ConfigNamesMapper.php index 4d98e2a4f..5d15dd56e 100644 --- a/core/modules/config_translation/src/ConfigNamesMapper.php +++ b/core/modules/config_translation/src/ConfigNamesMapper.php @@ -9,7 +9,6 @@ use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Config\TypedConfigManagerInterface; -use Drupal\Core\Language\Language; use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Core\Plugin\PluginBase; diff --git a/core/modules/config_translation/src/Form/ConfigTranslationDeleteForm.php b/core/modules/config_translation/src/Form/ConfigTranslationDeleteForm.php index 8e2b669c0..5b74b954f 100644 --- a/core/modules/config_translation/src/Form/ConfigTranslationDeleteForm.php +++ b/core/modules/config_translation/src/Form/ConfigTranslationDeleteForm.php @@ -16,7 +16,6 @@ use Drupal\Core\Url; use Drupal\language\ConfigurableLanguageManagerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; /** diff --git a/core/modules/config_translation/src/Form/ConfigTranslationFormBase.php b/core/modules/config_translation/src/Form/ConfigTranslationFormBase.php index f7b0497c0..afcb35a7d 100644 --- a/core/modules/config_translation/src/Form/ConfigTranslationFormBase.php +++ b/core/modules/config_translation/src/Form/ConfigTranslationFormBase.php @@ -11,7 +11,6 @@ use Drupal\Core\Config\TypedConfigManagerInterface; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\TypedData\TypedDataInterface; -use Drupal\Core\TypedData\TraversableTypedDataInterface; use Drupal\Core\Form\BaseFormIdInterface; use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/config_translation/src/Plugin/Derivative/ConfigTranslationContextualLinks.php b/core/modules/config_translation/src/Plugin/Derivative/ConfigTranslationContextualLinks.php index 8ecde5e06..0b95881dd 100644 --- a/core/modules/config_translation/src/Plugin/Derivative/ConfigTranslationContextualLinks.php +++ b/core/modules/config_translation/src/Plugin/Derivative/ConfigTranslationContextualLinks.php @@ -7,7 +7,6 @@ namespace Drupal\config_translation\Plugin\Derivative; -use Drupal\Component\Utility\Unicode; use Drupal\Component\Plugin\Derivative\DeriverBase; use Drupal\config_translation\ConfigMapperManagerInterface; use Drupal\Core\Plugin\Discovery\ContainerDeriverInterface; diff --git a/core/modules/config_translation/src/Tests/ConfigTranslationInstallTest.php b/core/modules/config_translation/src/Tests/ConfigTranslationInstallTest.php new file mode 100644 index 000000000..1735fc72e --- /dev/null +++ b/core/modules/config_translation/src/Tests/ConfigTranslationInstallTest.php @@ -0,0 +1,79 @@ +siteDirectory . '/files/translations', 0777, TRUE); + file_put_contents(DRUPAL_ROOT . '/' . $this->siteDirectory . '/files/translations/drupal-8.0.0.eo.po', $this->getPo('eo')); + + parent::setUpLanguage(); + + $this->translations['Save and continue'] = 'Save and continue eo'; + } + + /** + * Returns the string for the test .po file. + * + * @param string $langcode + * The language code. + * @return string + * Contents for the test .po file. + */ + protected function getPo($langcode) { + return <<drupalPostForm('admin/config/regional/language/add', ['predefined_langcode' => 'en'], t('Add custom language')); + $this->drupalPostForm('admin/config/regional/language/add', ['predefined_langcode' => 'fr'], t('Add custom language')); + + $edit = [ + 'modules[Multilingual][config_translation][enable]' => TRUE, + ]; + $this->drupalPostForm('admin/modules', $edit, t('Install')); + + $this->drupalGet('/admin/structure/types/manage/article/fields'); + $this->assertResponse(200); + } + +} diff --git a/core/modules/config_translation/src/Tests/ConfigTranslationUiTest.php b/core/modules/config_translation/src/Tests/ConfigTranslationUiTest.php index a18bc9529..a718808f0 100644 --- a/core/modules/config_translation/src/Tests/ConfigTranslationUiTest.php +++ b/core/modules/config_translation/src/Tests/ConfigTranslationUiTest.php @@ -10,7 +10,6 @@ use Drupal\Component\Serialization\Json; use Drupal\Component\Utility\SafeMarkup; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Config\FileStorage; use Drupal\Core\Language\Language; use Drupal\Core\Language\LanguageInterface; use Drupal\field\Entity\FieldConfig; diff --git a/core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php b/core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php index 5cb6351ff..2dc9c1e50 100644 --- a/core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php +++ b/core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php @@ -13,7 +13,6 @@ use Drupal\Core\TypedData\TypedDataInterface; use Drupal\Tests\UnitTestCase; use Drupal\Core\TypedData\DataDefinition; -use Drupal\Core\TypedData\DataDefinitionInterface; /** * Tests the functionality provided by configuration translation mapper manager. diff --git a/core/modules/config_translation/tests/src/Unit/ConfigNamesMapperTest.php b/core/modules/config_translation/tests/src/Unit/ConfigNamesMapperTest.php index 0223c6fb5..4d5765f6e 100644 --- a/core/modules/config_translation/tests/src/Unit/ConfigNamesMapperTest.php +++ b/core/modules/config_translation/tests/src/Unit/ConfigNamesMapperTest.php @@ -15,7 +15,6 @@ use Drupal\Core\Url; use Drupal\Tests\UnitTestCase; use Symfony\Component\Routing\Route; -use Symfony\Component\HttpFoundation\Request; /** * Tests the functionality provided by the configuration names mapper. @@ -503,7 +502,7 @@ public function testHasSchema(array $mock_return_values, $expected) { } /** - * Provides data for for ConfigMapperTest::testHasSchema(). + * Provides data for ConfigMapperTest::testHasSchema(). * * @return array * An array of arrays, where each inner array has an array of values that diff --git a/core/modules/contact/src/ContactFormEditForm.php b/core/modules/contact/src/ContactFormEditForm.php index c545b0e53..b4adde6bd 100644 --- a/core/modules/contact/src/ContactFormEditForm.php +++ b/core/modules/contact/src/ContactFormEditForm.php @@ -7,7 +7,6 @@ namespace Drupal\contact; -use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\DependencyInjection\ContainerInjectionInterface; use Symfony\Component\DependencyInjection\ContainerInterface; use Drupal\Core\Entity\EntityForm; diff --git a/core/modules/contact/src/ContactFormListBuilder.php b/core/modules/contact/src/ContactFormListBuilder.php index ed027c1bf..29ace7703 100644 --- a/core/modules/contact/src/ContactFormListBuilder.php +++ b/core/modules/contact/src/ContactFormListBuilder.php @@ -7,10 +7,8 @@ namespace Drupal\contact; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Config\Entity\ConfigEntityListBuilder; use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Link; /** * Defines a class to build a listing of contact form entities. diff --git a/core/modules/contact/src/MessageForm.php b/core/modules/contact/src/MessageForm.php index fec2ca868..46bb5d972 100644 --- a/core/modules/contact/src/MessageForm.php +++ b/core/modules/contact/src/MessageForm.php @@ -7,13 +7,11 @@ namespace Drupal\contact; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Datetime\DateFormatterInterface; use Drupal\Core\Entity\ContentEntityForm; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Flood\FloodInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Language\LanguageManagerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/contact/src/Plugin/views/field/ContactLink.php b/core/modules/contact/src/Plugin/views/field/ContactLink.php index 8b85eb1c4..d5db76977 100644 --- a/core/modules/contact/src/Plugin/views/field/ContactLink.php +++ b/core/modules/contact/src/Plugin/views/field/ContactLink.php @@ -8,7 +8,6 @@ namespace Drupal\contact\Plugin\views\field; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Session\AccountInterface; use Drupal\Core\Url; use Drupal\views\Plugin\views\field\LinkBase; use Drupal\views\ResultRow; diff --git a/core/modules/contact/src/Tests/MessageEntityTest.php b/core/modules/contact/src/Tests/MessageEntityTest.php index 7d9b9b2af..4e61e2116 100644 --- a/core/modules/contact/src/Tests/MessageEntityTest.php +++ b/core/modules/contact/src/Tests/MessageEntityTest.php @@ -6,7 +6,6 @@ namespace Drupal\contact\Tests; -use Drupal\contact\Entity\Message; use Drupal\system\Tests\Entity\EntityUnitTestBase; /** diff --git a/core/modules/content_translation/content_translation.admin.js b/core/modules/content_translation/content_translation.admin.js index 2ca749669..9d5b8826b 100644 --- a/core/modules/content_translation/content_translation.admin.js +++ b/core/modules/content_translation/content_translation.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Forces applicable options to be checked as translatable. diff --git a/core/modules/content_translation/content_translation.install b/core/modules/content_translation/content_translation.install index 6565a2b91..0bfe4149e 100644 --- a/core/modules/content_translation/content_translation.install +++ b/core/modules/content_translation/content_translation.install @@ -5,9 +5,6 @@ * Installation functions for Content Translation module. */ -use Drupal\Core\Language\LanguageInterface; -use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl; - /** * Implements hook_install(). */ diff --git a/core/modules/content_translation/src/ContentTranslationManager.php b/core/modules/content_translation/src/ContentTranslationManager.php index d0525e192..b4d701767 100644 --- a/core/modules/content_translation/src/ContentTranslationManager.php +++ b/core/modules/content_translation/src/ContentTranslationManager.php @@ -9,8 +9,6 @@ use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; -use Drupal\Core\Entity\EntityTypeInterface; -use Drupal\language\Entity\ContentLanguageSettings; /** * Provides common functionality for content translation. diff --git a/core/modules/content_translation/src/ContentTranslationManagerInterface.php b/core/modules/content_translation/src/ContentTranslationManagerInterface.php index 5afa2de35..f06c03056 100644 --- a/core/modules/content_translation/src/ContentTranslationManagerInterface.php +++ b/core/modules/content_translation/src/ContentTranslationManagerInterface.php @@ -8,7 +8,6 @@ namespace Drupal\content_translation; use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Entity\EntityTypeInterface; /** * Provides an interface for common functionality for content translation. diff --git a/core/modules/content_translation/src/FieldTranslationSynchronizer.php b/core/modules/content_translation/src/FieldTranslationSynchronizer.php index 6b94671b4..b2dbf6546 100644 --- a/core/modules/content_translation/src/FieldTranslationSynchronizer.php +++ b/core/modules/content_translation/src/FieldTranslationSynchronizer.php @@ -9,7 +9,6 @@ use Drupal\Core\Config\Entity\ThirdPartySettingsInterface; use Drupal\Core\Entity\ContentEntityInterface; -use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; /** diff --git a/core/modules/content_translation/src/Plugin/Derivative/ContentTranslationContextualLinks.php b/core/modules/content_translation/src/Plugin/Derivative/ContentTranslationContextualLinks.php index 9acf39451..f1c2fe3a1 100644 --- a/core/modules/content_translation/src/Plugin/Derivative/ContentTranslationContextualLinks.php +++ b/core/modules/content_translation/src/Plugin/Derivative/ContentTranslationContextualLinks.php @@ -9,7 +9,6 @@ use Drupal\Component\Plugin\Derivative\DeriverBase; use Drupal\Core\Plugin\Discovery\ContainerDeriverInterface; -use Drupal\Core\Routing\RouteProviderInterface; use Drupal\content_translation\ContentTranslationManagerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/content_translation/src/Routing/ContentTranslationRouteSubscriber.php b/core/modules/content_translation/src/Routing/ContentTranslationRouteSubscriber.php index 91d4314cf..a2b54a8a2 100644 --- a/core/modules/content_translation/src/Routing/ContentTranslationRouteSubscriber.php +++ b/core/modules/content_translation/src/Routing/ContentTranslationRouteSubscriber.php @@ -8,7 +8,6 @@ namespace Drupal\content_translation\Routing; use Drupal\content_translation\ContentTranslationManagerInterface; -use Drupal\Core\Access\AccessManagerInterface; use Drupal\Core\Routing\RouteSubscriberBase; use Drupal\Core\Routing\RoutingEvents; use Symfony\Component\Routing\Route; diff --git a/core/modules/content_translation/src/Tests/ContentTestTranslationUITest.php b/core/modules/content_translation/src/Tests/ContentTestTranslationUITest.php index ce9237cc3..3569a457d 100644 --- a/core/modules/content_translation/src/Tests/ContentTestTranslationUITest.php +++ b/core/modules/content_translation/src/Tests/ContentTestTranslationUITest.php @@ -26,19 +26,6 @@ class ContentTestTranslationUITest extends ContentTranslationUITestBase { */ public static $modules = array('language', 'content_translation', 'entity_test'); - /** - * {@inheritdoc} - */ - protected $defaultCacheContexts = [ - 'languages:language_interface', - 'session', - 'theme', - 'url.path', - 'url.query_args', - 'user.permissions', - 'user.roles:authenticated', - ]; - /** * Overrides \Drupal\simpletest\WebTestBase::setUp(). */ diff --git a/core/modules/content_translation/src/Tests/ContentTranslationUITestBase.php b/core/modules/content_translation/src/Tests/ContentTranslationUITestBase.php index 9ed2e4629..33d936a46 100644 --- a/core/modules/content_translation/src/Tests/ContentTranslationUITestBase.php +++ b/core/modules/content_translation/src/Tests/ContentTranslationUITestBase.php @@ -455,7 +455,7 @@ protected function getValue(EntityInterface $translation, $property, $langcode) * The entity being tested. * * @return string - * The the field name. + * The field name. */ protected function getChangedFieldName($entity) { return $entity->hasField('content_translation_changed') ? 'content_translation_changed' : 'changed'; diff --git a/core/modules/content_translation/src/Tests/Views/TranslationLinkTest.php b/core/modules/content_translation/src/Tests/Views/TranslationLinkTest.php index bb349e209..30ebe9f55 100644 --- a/core/modules/content_translation/src/Tests/Views/TranslationLinkTest.php +++ b/core/modules/content_translation/src/Tests/Views/TranslationLinkTest.php @@ -7,7 +7,6 @@ namespace Drupal\content_translation\Tests\Views; -use Drupal\views\Tests\ViewTestBase; use Drupal\content_translation\Tests\ContentTranslationTestBase; use Drupal\views\Tests\ViewTestData; use Drupal\Core\Language\Language; diff --git a/core/modules/contextual/css/contextual.theme.css b/core/modules/contextual/css/contextual.theme.css index 065065d11..8dc63b26f 100644 --- a/core/modules/contextual/css/contextual.theme.css +++ b/core/modules/contextual/css/contextual.theme.css @@ -99,14 +99,14 @@ margin: 0.25em 0; padding: 0.4em 0.6em; } -.touch .contextual-region .contextual .contextual-links a { +.touchevents .contextual-region .contextual .contextual-links a { font-size: large; } .contextual-region .contextual .contextual-links a, .contextual-region .contextual .contextual-links a:hover { text-decoration: none; } -.no-touch .contextual-region .contextual .contextual-links li a:hover { +.no-touchevents .contextual-region .contextual .contextual-links li a:hover { color: #000; background: #f7fcff; } diff --git a/core/modules/contextual/js/contextual.js b/core/modules/contextual/js/contextual.js index c90911c78..7f93a15f4 100644 --- a/core/modules/contextual/js/contextual.js +++ b/core/modules/contextual/js/contextual.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings, _, Backbone, JSON, storage) { - "use strict"; + 'use strict'; var options = $.extend(drupalSettings.contextual, // Merge strings on top of drupalSettings so that they are not mutable. diff --git a/core/modules/contextual/js/contextual.toolbar.js b/core/modules/contextual/js/contextual.toolbar.js index 839d1b008..b5a905349 100644 --- a/core/modules/contextual/js/contextual.toolbar.js +++ b/core/modules/contextual/js/contextual.toolbar.js @@ -5,7 +5,7 @@ (function ($, Drupal, Backbone) { - "use strict"; + 'use strict'; var strings = { tabbingReleased: Drupal.t('Tabbing is no longer constrained by the Contextual module.'), diff --git a/core/modules/contextual/js/models/StateModel.js b/core/modules/contextual/js/models/StateModel.js index 154013a89..465d717d5 100644 --- a/core/modules/contextual/js/models/StateModel.js +++ b/core/modules/contextual/js/models/StateModel.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; /** * Models the state of a contextual link's trigger, list & region. diff --git a/core/modules/contextual/js/toolbar/models/StateModel.js b/core/modules/contextual/js/toolbar/models/StateModel.js index bca190f4d..d9159e4e9 100644 --- a/core/modules/contextual/js/toolbar/models/StateModel.js +++ b/core/modules/contextual/js/toolbar/models/StateModel.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; Drupal.contextualToolbar.StateModel = Backbone.Model.extend(/** @lends Drupal.contextualToolbar.StateModel# */{ diff --git a/core/modules/contextual/js/toolbar/views/AuralView.js b/core/modules/contextual/js/toolbar/views/AuralView.js index 1bb99b4e9..d684ffb9e 100644 --- a/core/modules/contextual/js/toolbar/views/AuralView.js +++ b/core/modules/contextual/js/toolbar/views/AuralView.js @@ -5,7 +5,7 @@ (function ($, Drupal, Backbone, _) { - "use strict"; + 'use strict'; Drupal.contextualToolbar.AuralView = Backbone.View.extend(/** @lends Drupal.contextualToolbar.AuralView# */{ diff --git a/core/modules/contextual/js/toolbar/views/VisualView.js b/core/modules/contextual/js/toolbar/views/VisualView.js index e76f65e4f..d1d413502 100644 --- a/core/modules/contextual/js/toolbar/views/VisualView.js +++ b/core/modules/contextual/js/toolbar/views/VisualView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; Drupal.contextualToolbar.VisualView = Backbone.View.extend(/** @lends Drupal.contextualToolbar.VisualView# */{ diff --git a/core/modules/contextual/js/views/AuralView.js b/core/modules/contextual/js/views/AuralView.js index 70466d7b2..8ba2e33e3 100644 --- a/core/modules/contextual/js/views/AuralView.js +++ b/core/modules/contextual/js/views/AuralView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; Drupal.contextual.AuralView = Backbone.View.extend(/** @lends Drupal.contextual.AuralView# */{ diff --git a/core/modules/contextual/js/views/KeyboardView.js b/core/modules/contextual/js/views/KeyboardView.js index e57ccad45..9c247730e 100644 --- a/core/modules/contextual/js/views/KeyboardView.js +++ b/core/modules/contextual/js/views/KeyboardView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone) { - "use strict"; + 'use strict'; Drupal.contextual.KeyboardView = Backbone.View.extend(/** @lends Drupal.contextual.KeyboardView# */{ diff --git a/core/modules/contextual/js/views/RegionView.js b/core/modules/contextual/js/views/RegionView.js index 624bb1812..e960db36b 100644 --- a/core/modules/contextual/js/views/RegionView.js +++ b/core/modules/contextual/js/views/RegionView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone, Modernizr) { - "use strict"; + 'use strict'; Drupal.contextual.RegionView = Backbone.View.extend(/** @lends Drupal.contextual.RegionView# */{ @@ -23,7 +23,7 @@ } }; // We don't want mouse hover events on touch. - if (Modernizr.touch) { + if (Modernizr.touchevents) { mapping = {}; } return mapping; diff --git a/core/modules/contextual/js/views/VisualView.js b/core/modules/contextual/js/views/VisualView.js index 7c8e3ef95..b22bb373d 100644 --- a/core/modules/contextual/js/views/VisualView.js +++ b/core/modules/contextual/js/views/VisualView.js @@ -5,7 +5,7 @@ (function (Drupal, Backbone, Modernizr) { - "use strict"; + 'use strict'; Drupal.contextual.VisualView = Backbone.View.extend(/** @lends Drupal.contextual.VisualView# */{ @@ -28,7 +28,7 @@ 'touchend .contextual-links a': touchEndToClick }; // We only want mouse hover events on non-touch. - if (!Modernizr.touch) { + if (!Modernizr.touchevents) { mapping.mouseenter = function () { this.model.focus(); }; } return mapping; diff --git a/core/modules/contextual/src/ContextualController.php b/core/modules/contextual/src/ContextualController.php index 975113dc9..62ee55a41 100644 --- a/core/modules/contextual/src/ContextualController.php +++ b/core/modules/contextual/src/ContextualController.php @@ -12,7 +12,6 @@ use Symfony\Component\HttpFoundation\JsonResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; -use Drupal\Core\Entity\EntityInterface; /** * Returns responses for Contextual module routes. diff --git a/core/modules/datetime/datetime.module b/core/modules/datetime/datetime.module index 9d55b0938..2ad07a241 100644 --- a/core/modules/datetime/datetime.module +++ b/core/modules/datetime/datetime.module @@ -5,9 +5,6 @@ * Field hooks to implement a simple datetime field. */ -use Drupal\Component\Utility\NestedArray; -use Drupal\Core\Datetime\DrupalDateTime; -use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Routing\RouteMatchInterface; /** diff --git a/core/modules/datetime/src/DateTimeComputed.php b/core/modules/datetime/src/DateTimeComputed.php index 184a490de..fd1505850 100644 --- a/core/modules/datetime/src/DateTimeComputed.php +++ b/core/modules/datetime/src/DateTimeComputed.php @@ -51,7 +51,7 @@ public function getValue($langcode = NULL) { $storage_format = $item->getFieldDefinition()->getSetting('datetime_type') == 'date' ? DATETIME_DATE_STORAGE_FORMAT : DATETIME_DATETIME_STORAGE_FORMAT; try { $date = DrupalDateTime::createFromFormat($storage_format, $value, DATETIME_STORAGE_TIMEZONE); - if ($date instanceOf DrupalDateTime && !$date->hasErrors()) { + if ($date instanceof DrupalDateTime && !$date->hasErrors()) { $this->date = $date; } } diff --git a/core/modules/datetime/src/Tests/Views/FilterDateTimeTest.php b/core/modules/datetime/src/Tests/Views/FilterDateTimeTest.php index 137f45ccf..4392cbf1b 100644 --- a/core/modules/datetime/src/Tests/Views/FilterDateTimeTest.php +++ b/core/modules/datetime/src/Tests/Views/FilterDateTimeTest.php @@ -7,7 +7,6 @@ namespace Drupal\datetime\Tests\Views; -use Drupal\Core\Datetime\Element\Datetime; use Drupal\views\Views; /** diff --git a/core/modules/dblog/src/Plugin/views/field/DblogOperations.php b/core/modules/dblog/src/Plugin/views/field/DblogOperations.php index 0aac20f6a..445927508 100644 --- a/core/modules/dblog/src/Plugin/views/field/DblogOperations.php +++ b/core/modules/dblog/src/Plugin/views/field/DblogOperations.php @@ -9,8 +9,6 @@ use Drupal\views\Plugin\views\field\FieldPluginBase; use Drupal\views\ResultRow; -use Drupal\views\ViewExecutable; -use Drupal\views\Plugin\views\display\DisplayPluginBase; /** * Provides a field handler that renders operation link markup. diff --git a/core/modules/dynamic_page_cache/src/Tests/DynamicPageCacheIntegrationTest.php b/core/modules/dynamic_page_cache/src/Tests/DynamicPageCacheIntegrationTest.php index 5c174a8a7..ccc917098 100644 --- a/core/modules/dynamic_page_cache/src/Tests/DynamicPageCacheIntegrationTest.php +++ b/core/modules/dynamic_page_cache/src/Tests/DynamicPageCacheIntegrationTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Url; use Drupal\dynamic_page_cache\EventSubscriber\DynamicPageCacheSubscriber; use Drupal\simpletest\WebTestBase; -use Drupal\system\Tests\Cache\AssertPageCacheContextsAndTagsTrait; /** * Enables the Dynamic Page Cache and tests it in various scenarios. diff --git a/core/modules/dynamic_page_cache/tests/dynamic_page_cache_test/src/DynamicPageCacheTestController.php b/core/modules/dynamic_page_cache/tests/dynamic_page_cache_test/src/DynamicPageCacheTestController.php index b11984e5e..929f3a08a 100644 --- a/core/modules/dynamic_page_cache/tests/dynamic_page_cache_test/src/DynamicPageCacheTestController.php +++ b/core/modules/dynamic_page_cache/tests/dynamic_page_cache_test/src/DynamicPageCacheTestController.php @@ -7,7 +7,6 @@ namespace Drupal\dynamic_page_cache_test; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Cache\CacheableResponse; use Drupal\Core\StringTranslation\StringTranslationTrait; use Drupal\user\Entity\User; diff --git a/core/modules/editor/js/editor.admin.js b/core/modules/editor/js/editor.admin.js index bc7ebccee..1fdb35320 100644 --- a/core/modules/editor/js/editor.admin.js +++ b/core/modules/editor/js/editor.admin.js @@ -9,7 +9,7 @@ (function ($, _, Drupal, document) { - "use strict"; + 'use strict'; /** * Editor configuration namespace. @@ -308,7 +308,7 @@ // The complex case: wildcard in property value. else { var atLeastOneFound = false; - var regex = key.replace(/\*/g, "[^ ]*"); + var regex = key.replace(/\*/g, '[^ ]*'); _.each(_.keys(universe[tag]), function (key) { if (key.match(regex)) { atLeastOneFound = true; diff --git a/core/modules/editor/js/editor.dialog.js b/core/modules/editor/js/editor.dialog.js index 5b0ad50a6..3bf6120c7 100644 --- a/core/modules/editor/js/editor.dialog.js +++ b/core/modules/editor/js/editor.dialog.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Command to save the contents of an editor-provided modal. diff --git a/core/modules/editor/js/editor.formattedTextEditor.js b/core/modules/editor/js/editor.formattedTextEditor.js index d3cc0f9b5..9c3b43444 100644 --- a/core/modules/editor/js/editor.formattedTextEditor.js +++ b/core/modules/editor/js/editor.formattedTextEditor.js @@ -13,7 +13,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; Drupal.quickedit.editors.editor = Drupal.quickedit.EditorView.extend(/** @lends Drupal.quickedit.editors.editor# */{ diff --git a/core/modules/editor/js/editor.js b/core/modules/editor/js/editor.js index 20731b4bf..2be16f57c 100644 --- a/core/modules/editor/js/editor.js +++ b/core/modules/editor/js/editor.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Finds the text area field associated with the given text format selector. diff --git a/core/modules/editor/src/EditorController.php b/core/modules/editor/src/EditorController.php index 44feda30f..fd605cd78 100644 --- a/core/modules/editor/src/EditorController.php +++ b/core/modules/editor/src/EditorController.php @@ -8,13 +8,9 @@ namespace Drupal\editor; use Drupal\Core\Ajax\AjaxResponse; -use Drupal\Core\Ajax\OpenModalDialogCommand; -use Drupal\Core\Ajax\CloseModalDialogCommand; use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Entity\EntityInterface; use Drupal\editor\Ajax\GetUntransformedTextCommand; -use Drupal\editor\Form\EditorImageDialog; -use Drupal\editor\Form\EditorLinkDialog; use Drupal\filter\Plugin\FilterInterface; use Drupal\filter\FilterFormatInterface; use Symfony\Component\HttpFoundation\JsonResponse; diff --git a/core/modules/editor/src/Plugin/EditorBase.php b/core/modules/editor/src/Plugin/EditorBase.php index eafe673fe..cc39c18a4 100644 --- a/core/modules/editor/src/Plugin/EditorBase.php +++ b/core/modules/editor/src/Plugin/EditorBase.php @@ -10,7 +10,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\PluginBase; use Drupal\editor\Entity\Editor; -use Drupal\editor\Plugin\EditorPluginInterface; /** * Defines a base class from which other modules providing editors may extend. diff --git a/core/modules/editor/src/Tests/EditorImageDialogTest.php b/core/modules/editor/src/Tests/EditorImageDialogTest.php index 8efea38fc..b1745b055 100644 --- a/core/modules/editor/src/Tests/EditorImageDialogTest.php +++ b/core/modules/editor/src/Tests/EditorImageDialogTest.php @@ -7,20 +7,12 @@ namespace Drupal\editor\Tests; -use Drupal\Core\Form\FormInterface; use Drupal\Core\Form\FormState; -use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Render\Element\PathElement; -use Drupal\Core\Url; use Drupal\editor\Entity\Editor; use Drupal\editor\Form\EditorImageDialog; use Drupal\filter\Entity\FilterFormat; use Drupal\node\Entity\NodeType; -use Drupal\simpletest\KernelTestBase; use Drupal\system\Tests\Entity\EntityUnitTestBase; -use Drupal\user\Entity\Role; -use Drupal\user\Entity\User; -use Symfony\Component\HttpFoundation\Request; /** * Tests EditorImageDialog validation and conversion functionality. diff --git a/core/modules/editor/src/Tests/EditorManagerTest.php b/core/modules/editor/src/Tests/EditorManagerTest.php index c28d99dc8..9bb7a67e7 100644 --- a/core/modules/editor/src/Tests/EditorManagerTest.php +++ b/core/modules/editor/src/Tests/EditorManagerTest.php @@ -8,7 +8,6 @@ namespace Drupal\editor\Tests; use Drupal\simpletest\KernelTestBase; -use Drupal\editor\Plugin\EditorManager; /** * Tests detection of text editors and correct generation of attachments. diff --git a/core/modules/editor/src/Tests/QuickEditIntegrationTest.php b/core/modules/editor/src/Tests/QuickEditIntegrationTest.php index 098b4cf49..f9e1625d2 100644 --- a/core/modules/editor/src/Tests/QuickEditIntegrationTest.php +++ b/core/modules/editor/src/Tests/QuickEditIntegrationTest.php @@ -10,9 +10,7 @@ use Drupal\Component\Serialization\Json; use Drupal\Core\EventSubscriber\AjaxResponseSubscriber; use Drupal\Core\Language\LanguageInterface; -use Drupal\quickedit\EditorSelector; use Drupal\quickedit\MetadataGenerator; -use Drupal\quickedit\Plugin\InPlaceEditorManager; use Drupal\quickedit\Tests\QuickEditTestBase; use Drupal\quickedit_test\MockEditEntityFieldAccessCheck; use Drupal\editor\EditorController; diff --git a/core/modules/editor/tests/src/Kernel/EditorFilterIntegrationTest.php b/core/modules/editor/tests/src/Kernel/EditorFilterIntegrationTest.php index 625fb9001..b6ec02736 100644 --- a/core/modules/editor/tests/src/Kernel/EditorFilterIntegrationTest.php +++ b/core/modules/editor/tests/src/Kernel/EditorFilterIntegrationTest.php @@ -2,7 +2,7 @@ /** * @file - * Contains \Drupal\Tests\editor\Kernel\EditorFilterIntegration. + * Contains \Drupal\Tests\editor\Kernel\EditorFilterIntegrationTest. */ namespace Drupal\Tests\editor\Kernel; diff --git a/core/modules/field/field.api.php b/core/modules/field/field.api.php index 55c239d73..fb85d62bc 100644 --- a/core/modules/field/field.api.php +++ b/core/modules/field/field.api.php @@ -5,8 +5,6 @@ * @{ */ -use Drupal\Component\Utility\NestedArray; - /** * @defgroup field_types Field Types API * @{ diff --git a/core/modules/field/migration_templates/d6_field_formatter_settings.yml b/core/modules/field/migration_templates/d6_field_formatter_settings.yml index c851bf5b2..1e91fa2fd 100644 --- a/core/modules/field/migration_templates/d6_field_formatter_settings.yml +++ b/core/modules/field/migration_templates/d6_field_formatter_settings.yml @@ -28,7 +28,14 @@ process: index: - 1 entity_type: 'constants/entity_type' - bundle: type_name + bundle: + - + plugin: migration + migration: d6_node_type + source: type_name + - + plugin: skip_on_empty + method: row view_mode: - plugin: migration diff --git a/core/modules/field/migration_templates/d6_field_instance.yml b/core/modules/field/migration_templates/d6_field_instance.yml index 78b81adc3..aa7861a6a 100644 --- a/core/modules/field/migration_templates/d6_field_instance.yml +++ b/core/modules/field/migration_templates/d6_field_instance.yml @@ -28,7 +28,14 @@ process: method: row entity_type: 'constants/entity_type' field_name: field_name - bundle: type_name + bundle: + - + plugin: migration + migration: d6_node_type + source: type_name + - + plugin: skip_on_empty + method: row label: label description: description required: required diff --git a/core/modules/field/migration_templates/d6_field_instance_widget_settings.yml b/core/modules/field/migration_templates/d6_field_instance_widget_settings.yml index ad9c74aba..d34648dbc 100644 --- a/core/modules/field/migration_templates/d6_field_instance_widget_settings.yml +++ b/core/modules/field/migration_templates/d6_field_instance_widget_settings.yml @@ -28,7 +28,14 @@ process: - plugin: skip_on_empty method: row - bundle: type_name + bundle: + - + plugin: migration + migration: d6_node_type + source: type_name + - + plugin: skip_on_empty + method: row form_mode: 'constants/form_mode' field_name: field_name entity_type: 'constants/entity_type' diff --git a/core/modules/field/src/Entity/FieldConfig.php b/core/modules/field/src/Entity/FieldConfig.php index e2ab409fc..8e0e0b489 100644 --- a/core/modules/field/src/Entity/FieldConfig.php +++ b/core/modules/field/src/Entity/FieldConfig.php @@ -7,7 +7,6 @@ namespace Drupal\field\Entity; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Field\FieldConfigBase; use Drupal\Core\Field\FieldException; @@ -185,7 +184,7 @@ public function preSave(EntityStorageInterface $storage) { */ public function calculateDependencies() { parent::calculateDependencies(); - // Mark the field_storage_config as a a dependency. + // Mark the field_storage_config as a dependency. $this->addDependency('config', $this->getFieldStorageDefinition()->getConfigDependencyName()); return $this; } diff --git a/core/modules/field/src/Plugin/migrate/source/d7/FieldInstance.php b/core/modules/field/src/Plugin/migrate/source/d7/FieldInstance.php index 87853efb5..feb578869 100755 --- a/core/modules/field/src/Plugin/migrate/source/d7/FieldInstance.php +++ b/core/modules/field/src/Plugin/migrate/source/d7/FieldInstance.php @@ -82,6 +82,9 @@ public function prepareRow(Row $row) { $row->setSourceProperty('widget_settings', $data['widget']); $row->setSourceProperty('display_settings', $data['display']); + // This is for parity with the d6_field_instance plugin. + $row->setSourceProperty('widget_type', $data['widget']['type']); + return parent::prepareRow($row); } diff --git a/core/modules/field/src/Plugin/migrate/source/d7/ViewMode.php b/core/modules/field/src/Plugin/migrate/source/d7/ViewMode.php index 89bdc78b7..f471e48ff 100644 --- a/core/modules/field/src/Plugin/migrate/source/d7/ViewMode.php +++ b/core/modules/field/src/Plugin/migrate/source/d7/ViewMode.php @@ -7,7 +7,6 @@ namespace Drupal\field\Plugin\migrate\source\d7; -use Drupal\migrate\Annotation\MigrateSource; use Drupal\migrate_drupal\Plugin\migrate\source\DrupalSqlBase; /** diff --git a/core/modules/field/src/Tests/Boolean/BooleanFormatterSettingsTest.php b/core/modules/field/src/Tests/Boolean/BooleanFormatterSettingsTest.php index e9b693dc8..8c5146b49 100644 --- a/core/modules/field/src/Tests/Boolean/BooleanFormatterSettingsTest.php +++ b/core/modules/field/src/Tests/Boolean/BooleanFormatterSettingsTest.php @@ -9,8 +9,6 @@ use Drupal\Component\Utility\Unicode; use Drupal\Component\Utility\SafeMarkup; -use Drupal\Core\Entity\Display\EntityViewDisplayInterface; -use Drupal\Core\Entity\FieldableEntityInterface; use Drupal\field\Entity\FieldConfig; use Drupal\field\Entity\FieldStorageConfig; use Drupal\simpletest\WebTestBase; diff --git a/core/modules/field/src/Tests/EntityReference/EntityReferenceIntegrationTest.php b/core/modules/field/src/Tests/EntityReference/EntityReferenceIntegrationTest.php index 0d1fe9bb1..4d678f8a5 100644 --- a/core/modules/field/src/Tests/EntityReference/EntityReferenceIntegrationTest.php +++ b/core/modules/field/src/Tests/EntityReference/EntityReferenceIntegrationTest.php @@ -9,7 +9,6 @@ use Drupal\Component\Utility\SafeMarkup; use Drupal\config\Tests\AssertConfigEntityImportTrait; -use Drupal\Core\Config\Entity\ConfigEntityBase; use Drupal\field\Entity\FieldConfig; use Drupal\simpletest\WebTestBase; @@ -88,7 +87,7 @@ public function testSupportedEntityTypesAndWidgets() { // Try to post the form again with no modification and check if the field // values remain the same. $entity = current(entity_load_multiple_by_properties($this->entityType, array('name' => $entity_name))); - $this->drupalGet($this->entityType . '/manage/' . $entity->id()); + $this->drupalGet($this->entityType . '/manage/' . $entity->id() . '/edit'); $this->assertFieldByName($this->fieldName . '[0][target_id]', $referenced_entities[0]->label() . ' (' . $referenced_entities[0]->id() . ')'); $this->assertFieldByName($this->fieldName . '[1][target_id]', $referenced_entities[1]->label() . ' (' . $referenced_entities[1]->id() . ')'); @@ -114,7 +113,7 @@ public function testSupportedEntityTypesAndWidgets() { // Try to post the form again with no modification and check if the field // values remain the same. $entity = current(entity_load_multiple_by_properties($this->entityType, array('name' => $entity_name))); - $this->drupalGet($this->entityType . '/manage/' . $entity->id()); + $this->drupalGet($this->entityType . '/manage/' . $entity->id() . '/edit'); $this->assertFieldByName($this->fieldName . '[target_id]', $target_id . ' (' . $referenced_entities[1]->id() . ')'); $this->drupalPostForm(NULL, array(), t('Save')); @@ -133,7 +132,7 @@ public function testSupportedEntityTypesAndWidgets() { 'type' => $widget_type, ))->save(); - $this->drupalPostForm($this->entityType . '/manage/' . $entity->id(), array(), t('Save')); + $this->drupalPostForm($this->entityType . '/manage/' . $entity->id() . '/edit', array(), t('Save')); $this->assertFieldValues($entity_name, $referenced_entities); } diff --git a/core/modules/field/src/Tests/FieldAttachOtherTest.php b/core/modules/field/src/Tests/FieldAttachOtherTest.php index 9441f679c..e76145e41 100644 --- a/core/modules/field/src/Tests/FieldAttachOtherTest.php +++ b/core/modules/field/src/Tests/FieldAttachOtherTest.php @@ -8,7 +8,6 @@ namespace Drupal\field\Tests; use Drupal\Core\Form\FormState; -use Drupal\Core\Language\LanguageInterface; /** * Tests other Field API functions. diff --git a/core/modules/field/src/Tests/FormTest.php b/core/modules/field/src/Tests/FormTest.php index ce0001171..dbdc71a4f 100644 --- a/core/modules/field/src/Tests/FormTest.php +++ b/core/modules/field/src/Tests/FormTest.php @@ -8,8 +8,10 @@ namespace Drupal\field\Tests; use Drupal\Component\Utility\Html; +use Drupal\Core\Entity\Entity\EntityFormDisplay; use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\Core\Form\FormState; +use Drupal\entity_test\Entity\EntityTestBaseFieldDisplay; use Drupal\field\Entity\FieldConfig; use Drupal\field\Entity\FieldStorageConfig; @@ -137,7 +139,7 @@ function testFieldFormSingle() { $this->assertEqual($entity->{$field_name}->value, $value, 'Field value was saved'); // Display edit form. - $this->drupalGet('entity_test/manage/' . $id); + $this->drupalGet('entity_test/manage/' . $id . '/edit'); $this->assertFieldByName("{$field_name}[0][value]", $value, 'Widget is displayed with the correct default value'); $this->assertNoField("{$field_name}[1][value]", 'No extraneous widget is displayed'); @@ -157,7 +159,7 @@ function testFieldFormSingle() { $edit = array( "{$field_name}[0][value]" => $value ); - $this->drupalPostForm('entity_test/manage/' . $id, $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $id . '/edit', $edit, t('Save')); $this->assertText(t('entity_test @id has been updated.', array('@id' => $id)), 'Entity was updated'); $this->container->get('entity.manager')->getStorage('entity_test')->resetCache(array($id)); $entity = entity_load('entity_test', $id); @@ -229,7 +231,7 @@ function testFieldFormSingleRequired() { $edit = array( "{$field_name}[0][value]" => $value, ); - $this->drupalPostForm('entity_test/manage/' . $id, $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $id . '/edit', $edit, t('Save')); $this->assertRaw(t('@name field is required.', array('@name' => $this->field['label'])), 'Required field with no value fails validation'); } @@ -489,7 +491,7 @@ function testFieldFormMultipleWidget() { $this->assertFieldValues($entity_init, $field_name, array(1, 2, 3)); // Display the form, check that the values are correctly filled in. - $this->drupalGet('entity_test/manage/' . $id); + $this->drupalGet('entity_test/manage/' . $id . '/edit'); $this->assertFieldByName($field_name, '1, 2, 3', 'Widget is displayed.'); // Submit the form with more values than the field accepts. @@ -572,7 +574,7 @@ function testFieldFormAccess() { "{$field_name}[0][value]" => 2, 'revision' => TRUE, ); - $this->drupalPostForm($entity_type . '/manage/' . $id, $edit, t('Save')); + $this->drupalPostForm($entity_type . '/manage/' . $id . '/edit', $edit, t('Save')); // Check that the new revision has the expected values. $this->container->get('entity.manager')->getStorage($entity_type)->resetCache(array($id)); @@ -628,7 +630,7 @@ function testHiddenField() { ->save(); // Display edit form. - $this->drupalGet($entity_type . '/manage/' . $id); + $this->drupalGet($entity_type . '/manage/' . $id . '/edit'); $this->assertFieldByName("{$field_name}[0][value]", 99, 'Widget is displayed with the correct default value'); // Update the entity. @@ -647,7 +649,7 @@ function testHiddenField() { // Create a new revision. $edit = array('revision' => TRUE); - $this->drupalPostForm($entity_type . '/manage/' . $id, $edit, t('Save')); + $this->drupalPostForm($entity_type . '/manage/' . $id . '/edit', $edit, t('Save')); // Check that the expected value has been carried over to the new revision. \Drupal::entityManager()->getStorage($entity_type)->resetCache(array($id)); @@ -655,4 +657,40 @@ function testHiddenField() { $this->assertEqual($entity->{$field_name}->value, $value, 'New revision has the expected value for the field with the Hidden widget'); } + /** + * Tests the form display of the label for multi-value fields. + */ + public function testLabelOnMultiValueFields() { + $user = $this->drupalCreateUser(['administer entity_test content']); + $this->drupalLogin($user); + + FieldStorageConfig::create([ + 'entity_type' => 'entity_test_base_field_display', + 'field_name' => 'foo', + 'type' => 'text', + 'cardinality' => FieldStorageConfig::CARDINALITY_UNLIMITED, + ])->save(); + FieldConfig::create([ + 'entity_type' => 'entity_test_base_field_display', + 'bundle' => 'bar', + 'field_name' => 'foo', + // Set a dangerous label to test XSS filtering. + 'label' => "", + ])->save(); + EntityFormDisplay::create([ + 'targetEntityType' => 'entity_test_base_field_display', + 'bundle' => 'bar', + 'mode' => 'default', + ])->setComponent('foo', ['type' => 'text_textfield'])->enable()->save(); + + $entity = EntityTestBaseFieldDisplay::create(['type' => 'bar']); + $entity->save(); + + $this->drupalGet('entity_test_base_field_display/manage/' . $entity->id()); + $this->assertResponse(200); + $this->assertText('A field with multiple values'); + // Test if labels were XSS filtered. + $this->assertEscaped(""); + } + } diff --git a/core/modules/field/src/Tests/Migrate/d6/MigrateFieldFormatterSettingsTest.php b/core/modules/field/src/Tests/Migrate/d6/MigrateFieldFormatterSettingsTest.php index 435c83c37..1ad3d36fb 100644 --- a/core/modules/field/src/Tests/Migrate/d6/MigrateFieldFormatterSettingsTest.php +++ b/core/modules/field/src/Tests/Migrate/d6/MigrateFieldFormatterSettingsTest.php @@ -8,7 +8,6 @@ namespace Drupal\field\Tests\Migrate\d6; use Drupal\Core\Entity\Entity\EntityViewDisplay; -use Drupal\Core\Entity\Entity\EntityViewMode; use Drupal\migrate\Entity\Migration; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; diff --git a/core/modules/field/src/Tests/Migrate/d6/MigrateFieldInstanceTest.php b/core/modules/field/src/Tests/Migrate/d6/MigrateFieldInstanceTest.php index afc6703a4..c3c0cb62c 100644 --- a/core/modules/field/src/Tests/Migrate/d6/MigrateFieldInstanceTest.php +++ b/core/modules/field/src/Tests/Migrate/d6/MigrateFieldInstanceTest.php @@ -20,17 +20,11 @@ class MigrateFieldInstanceTest extends MigrateDrupal6TestBase { /** - * {@inheritdoc} + * Tests migration of file variables to file.settings.yml. */ - protected function setUp() { - parent::setUp(); + public function testFieldInstanceMigration() { $this->migrateFields(); - } - /** - * Tests migration of file variables to file.settings.yml. - */ - public function testFieldInstanceSettings() { $entity = Node::create(['type' => 'story']); // Test a text field. $field = FieldConfig::load('node.story.field_test'); @@ -98,4 +92,20 @@ public function testFieldInstanceSettings() { $this->assertIdentical([], $entity->field_test_link->options['attributes']); } + /** + * Tests migrating fields into non-existent content types. + */ + public function testMigrateFieldIntoUnknownNodeType() { + $this->sourceDatabase->delete('node_type') + ->condition('type', 'test_planet') + ->execute(); + // The field migrations use the migration plugin to ensure that the node + // types exist, so this should produce no failures... + $this->migrateFields(); + + // ...and the field instances should not have been migrated. + $this->assertNull(FieldConfig::load('node.test_planet.field_multivalue')); + $this->assertNull(FieldConfig::load('node.test_planet.field_test_text_single_checkbox')); + } + } diff --git a/core/modules/field/src/Tests/TranslationWebTest.php b/core/modules/field/src/Tests/TranslationWebTest.php index 4aa8c4893..8350285c1 100644 --- a/core/modules/field/src/Tests/TranslationWebTest.php +++ b/core/modules/field/src/Tests/TranslationWebTest.php @@ -114,7 +114,7 @@ function testFieldFormTranslationRevisions() { "{$field_name}[0][value]" => $entity->{$field_name}->value, 'revision' => TRUE, ); - $this->drupalPostForm($this->entityTypeId . '/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm($this->entityTypeId . '/manage/' . $entity->id() . '/edit', $edit, t('Save')); // Check translation revisions. $this->checkTranslationRevisions($entity->id(), $entity->getRevisionId(), $available_langcodes); diff --git a/core/modules/field/tests/modules/field_test/field_test.module b/core/modules/field/tests/modules/field_test/field_test.module index bf608d8dd..c66a0d682 100644 --- a/core/modules/field/tests/modules/field_test/field_test.module +++ b/core/modules/field/tests/modules/field_test/field_test.module @@ -1,6 +1,5 @@ calculateDependencies(); } + /** + * @covers ::onDependencyRemoval + */ + public function testOnDependencyRemoval() { + $this->fieldTypePluginManager->expects($this->any()) + ->method('getDefinition') + ->with('test_field') + ->willReturn(['class' => '\Drupal\Tests\field\Unit\DependencyFieldItem']); + + $field = new FieldConfig([ + 'field_name' => $this->fieldStorage->getName(), + 'entity_type' => 'test_entity_type', + 'bundle' => 'test_bundle', + 'field_type' => 'test_field', + 'dependencies' => [ + 'module' => [ + 'fruiter', + ] + ], + 'third_party_settings' => [ + 'fruiter' => [ + 'fruit' => 'apple', + ] + ] + ]); + $changed = $field->onDependencyRemoval(['module' => ['fruiter']]); + $this->assertTrue($changed); + } + /** * @covers ::toArray */ @@ -291,4 +319,7 @@ public static function calculateDependencies(FieldDefinitionInterface $definitio return ['module' => ['test_module3']]; } + public static function onDependencyRemoval($field_config, $dependencies) { + } + } diff --git a/core/modules/field/tests/src/Unit/FieldStorageConfigEntityUnitTest.php b/core/modules/field/tests/src/Unit/FieldStorageConfigEntityUnitTest.php index e41615b94..13ba3cf93 100644 --- a/core/modules/field/tests/src/Unit/FieldStorageConfigEntityUnitTest.php +++ b/core/modules/field/tests/src/Unit/FieldStorageConfigEntityUnitTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\field\Unit; use Drupal\Core\DependencyInjection\ContainerBuilder; -use Drupal\Core\Field\FieldItemBase; use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\Core\Field\FieldTypePluginManagerInterface; use Drupal\field\Entity\FieldStorageConfig; diff --git a/core/modules/field_ui/field_ui.js b/core/modules/field_ui/field_ui.js index 9f1afc632..a53553dc4 100644 --- a/core/modules/field_ui/field_ui.js +++ b/core/modules/field_ui/field_ui.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * @type {Drupal~behavior} diff --git a/core/modules/field_ui/src/Controller/FieldConfigListController.php b/core/modules/field_ui/src/Controller/FieldConfigListController.php index 649e7bba6..9555cad10 100644 --- a/core/modules/field_ui/src/Controller/FieldConfigListController.php +++ b/core/modules/field_ui/src/Controller/FieldConfigListController.php @@ -9,7 +9,6 @@ use Drupal\Core\Entity\Controller\EntityListController; use Drupal\Core\Routing\RouteMatchInterface; -use Symfony\Component\HttpFoundation\Request; /** * Defines a controller to list field instances. diff --git a/core/modules/field_ui/src/Form/EntityDisplayFormBase.php b/core/modules/field_ui/src/Form/EntityDisplayFormBase.php index e32d73be8..6681f6180 100644 --- a/core/modules/field_ui/src/Form/EntityDisplayFormBase.php +++ b/core/modules/field_ui/src/Form/EntityDisplayFormBase.php @@ -211,8 +211,8 @@ public function form(array $form, FormStateInterface $form_state) { ); // Prepare default values for the 'Custom display settings' checkboxes. $default = array(); - if ($display_statuses = array_filter($this->getDisplayStatuses())) { - $default = array_keys(array_intersect_key($display_mode_options, $display_statuses)); + if ($enabled_displays = array_filter($this->getDisplayStatuses())) { + $default = array_keys(array_intersect_key($display_mode_options, $enabled_displays)); } $form['modes']['display_modes_custom'] = array( '#type' => 'checkboxes', diff --git a/core/modules/field_ui/src/Plugin/Derivative/FieldUiLocalTask.php b/core/modules/field_ui/src/Plugin/Derivative/FieldUiLocalTask.php index 6c869e500..14c2aecb1 100644 --- a/core/modules/field_ui/src/Plugin/Derivative/FieldUiLocalTask.php +++ b/core/modules/field_ui/src/Plugin/Derivative/FieldUiLocalTask.php @@ -7,7 +7,6 @@ namespace Drupal\field_ui\Plugin\Derivative; -use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Component\Plugin\Derivative\DeriverBase; use Drupal\Core\Plugin\Discovery\ContainerDeriverInterface; diff --git a/core/modules/file/file.field.inc b/core/modules/file/file.field.inc index aac6bd8ff..6c065758a 100644 --- a/core/modules/file/file.field.inc +++ b/core/modules/file/file.field.inc @@ -5,7 +5,6 @@ * Field module functionality for the File module. */ -use Drupal\Component\Utility\Html; use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldFilteredMarkup; use Drupal\Core\Render\Element; diff --git a/core/modules/file/file.js b/core/modules/file/file.js index 7d5d9199d..30cf2450e 100644 --- a/core/modules/file/file.js +++ b/core/modules/file/file.js @@ -9,7 +9,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Attach behaviors to the file fields passed in the settings. @@ -142,7 +142,7 @@ if (extensionPattern.length > 1 && this.value.length > 0) { var acceptableMatch = new RegExp('\\.(' + extensionPattern + ')$', 'gi'); if (!acceptableMatch.test(this.value)) { - var error = Drupal.t("The selected file %filename cannot be uploaded. Only files with the following extensions are allowed: %extensions.", { + var error = Drupal.t('The selected file %filename cannot be uploaded. Only files with the following extensions are allowed: %extensions.', { // According to the specifications of HTML5, a file upload control // should not reveal the real local path to the file that a user // has selected. Some web browsers implement this restriction by diff --git a/core/modules/file/file.module b/core/modules/file/file.module index b198dcb2b..d48b23209 100644 --- a/core/modules/file/file.module +++ b/core/modules/file/file.module @@ -18,7 +18,6 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Component\Utility\Unicode; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Template\Attribute; -use Drupal\file\FileUsage\FileUsageInterface; // Load all Field module hooks for File. require_once __DIR__ . '/file.field.inc'; diff --git a/core/modules/file/migration_templates/d6_upload_field_instance.yml b/core/modules/file/migration_templates/d6_upload_field_instance.yml index 8b53503d9..5bd7c9a2c 100644 --- a/core/modules/file/migration_templates/d6_upload_field_instance.yml +++ b/core/modules/file/migration_templates/d6_upload_field_instance.yml @@ -11,7 +11,14 @@ source: description_field: 1 process: entity_type: 'constants/entity_type' - bundle: node_type + bundle: + - + plugin: migration + migration: d6_node_type + source: node_type + - + plugin: skip_on_empty + method: row field_name: 'constants/name' settings: 'constants/settings' 'settings/file_extensions': file_extensions diff --git a/core/modules/file/src/FileInterface.php b/core/modules/file/src/FileInterface.php index 8dd131b02..1b02d1f4a 100644 --- a/core/modules/file/src/FileInterface.php +++ b/core/modules/file/src/FileInterface.php @@ -10,7 +10,6 @@ use Drupal\Core\Entity\ContentEntityInterface; use Drupal\user\EntityOwnerInterface; use Drupal\Core\Entity\EntityChangedInterface; -use Drupal\user\UserInterface; /** * Defines getter and setter methods for file entity base fields. diff --git a/core/modules/file/src/FileUsage/DatabaseFileUsageBackend.php b/core/modules/file/src/FileUsage/DatabaseFileUsageBackend.php index e28c94b61..e00b9f26c 100644 --- a/core/modules/file/src/FileUsage/DatabaseFileUsageBackend.php +++ b/core/modules/file/src/FileUsage/DatabaseFileUsageBackend.php @@ -8,7 +8,6 @@ namespace Drupal\file\FileUsage; use Drupal\Core\Database\Connection; -use Drupal\Core\Database\DatabaseExceptionWrapper; use Drupal\file\FileInterface; /** diff --git a/core/modules/file/src/Plugin/Field/FieldType/FileItem.php b/core/modules/file/src/Plugin/Field/FieldType/FileItem.php index 584160444..1633147b2 100644 --- a/core/modules/file/src/Plugin/Field/FieldType/FileItem.php +++ b/core/modules/file/src/Plugin/Field/FieldType/FileItem.php @@ -51,7 +51,7 @@ public static function defaultStorageSettings() { public static function defaultFieldSettings() { return array( 'file_extensions' => 'txt', - 'file_directory' => '', + 'file_directory' => '[date:custom:Y]-[date:custom:m]', 'max_filesize' => '', 'description_field' => 0, ) + parent::defaultFieldSettings(); @@ -267,7 +267,22 @@ public static function validateMaxFilesize($element, FormStateInterface $form_st * @see token_replace() */ public function getUploadLocation($data = array()) { - $settings = $this->getSettings(); + return static::doGetUploadLocation($this->getSettings(), $data); + } + + /** + * Determines the URI for a file field. + * + * @param array $settings + * The array of field settings. + * @param array $data + * An array of token objects to pass to token_replace(). + * + * @return string + * An unsanitized file directory URI with tokens replaced. The result of + * the token replacement is then converted to plain text and returned. + */ + protected static function doGetUploadLocation(array $settings, $data = []) { $destination = trim($settings['file_directory'], '/'); // Replace tokens. As the tokens might contain HTML we convert it to plain @@ -312,7 +327,7 @@ public static function generateSampleValue(FieldDefinitionInterface $field_defin $settings = $field_definition->getSettings(); // Prepare destination. - $dirname = $settings['uri_scheme'] . '://' . $settings['file_directory']; + $dirname = static::doGetUploadLocation($settings); file_prepare_directory($dirname, FILE_CREATE_DIRECTORY); // Generate a file entity. diff --git a/core/modules/file/src/Plugin/Field/FieldWidget/FileWidget.php b/core/modules/file/src/Plugin/Field/FieldWidget/FileWidget.php index 7d32ce90f..bd511c8cf 100644 --- a/core/modules/file/src/Plugin/Field/FieldWidget/FileWidget.php +++ b/core/modules/file/src/Plugin/Field/FieldWidget/FileWidget.php @@ -17,7 +17,6 @@ use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Render\Element; use Drupal\Core\Render\ElementInfoManagerInterface; -use Drupal\Core\Url; use Drupal\file\Element\ManagedFile; use Symfony\Component\DependencyInjection\ContainerInterface; use Drupal\file\Entity\File; diff --git a/core/modules/file/src/Plugin/migrate/process/d6/CckFile.php b/core/modules/file/src/Plugin/migrate/process/d6/CckFile.php index e45800d3f..4270b7971 100644 --- a/core/modules/file/src/Plugin/migrate/process/d6/CckFile.php +++ b/core/modules/file/src/Plugin/migrate/process/d6/CckFile.php @@ -23,6 +23,11 @@ */ class CckFile extends ProcessPluginBase implements ContainerFactoryPluginInterface { + /** + * The migration process plugin, configured for lookups in d6_file. + * + * @var \Drupal\migrate\Plugin\MigrateProcessInterface + */ protected $migrationPlugin; /** @@ -92,6 +97,8 @@ public function transform($value, MigrateExecutableInterface $migrate_executable 'target_id' => $fid, 'display' => $value['list'], 'description' => isset($options['description']) ? $options['description'] : '', + 'alt' => isset($options['alt']) ? $options['alt'] : '', + 'title' => isset($options['title']) ? $options['title'] : '', ]; } else { diff --git a/core/modules/file/src/Plugin/views/field/File.php b/core/modules/file/src/Plugin/views/field/File.php index 77237e82a..615aa9f8e 100644 --- a/core/modules/file/src/Plugin/views/field/File.php +++ b/core/modules/file/src/Plugin/views/field/File.php @@ -8,7 +8,6 @@ namespace Drupal\file\Plugin\views\field; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Url; use Drupal\views\ResultRow; use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; diff --git a/core/modules/file/src/Tests/DownloadTest.php b/core/modules/file/src/Tests/DownloadTest.php index ea2b7456e..997eb560a 100644 --- a/core/modules/file/src/Tests/DownloadTest.php +++ b/core/modules/file/src/Tests/DownloadTest.php @@ -7,8 +7,6 @@ namespace Drupal\file\Tests; -use Symfony\Component\HttpFoundation\Request; - /** * Tests for download/file transfer functions. * diff --git a/core/modules/file/src/Tests/FileFieldPathTest.php b/core/modules/file/src/Tests/FileFieldPathTest.php index 346fc7a27..acafd4bf1 100644 --- a/core/modules/file/src/Tests/FileFieldPathTest.php +++ b/core/modules/file/src/Tests/FileFieldPathTest.php @@ -19,20 +19,29 @@ class FileFieldPathTest extends FileFieldTestBase { * Tests the normal formatter display on node display. */ function testUploadPath() { + /** @var \Drupal\node\NodeStorageInterface $node_storage */ $node_storage = $this->container->get('entity.manager')->getStorage('node'); $field_name = strtolower($this->randomMachineName()); $type_name = 'article'; $this->createFileField($field_name, 'node', $type_name); + /** @var \Drupal\file\FileInterface $test_file */ $test_file = $this->getTestFile('text'); // Create a new node. $nid = $this->uploadNodeFile($test_file, $field_name, $type_name); - // Check that the file was uploaded to the file root. + // Check that the file was uploaded to the correct location. $node_storage->resetCache(array($nid)); $node = $node_storage->load($nid); - $node_file = File::load($node->{$field_name}->target_id); - $this->assertPathMatch('public://' . $test_file->getFilename(), $node_file->getFileUri(), format_string('The file %file was uploaded to the correct path.', array('%file' => $node_file->getFileUri()))); + /** @var \Drupal\file\FileInterface $node_file */ + $node_file = $node->{$field_name}->entity; + $date_formatter = $this->container->get('date.formatter'); + $expected_filename = + 'public://' . + $date_formatter->format(REQUEST_TIME, 'custom', 'Y') . '-' . + $date_formatter->format(REQUEST_TIME, 'custom', 'm') . '/' . + $test_file->getFilename(); + $this->assertPathMatch($expected_filename, $node_file->getFileUri(), format_string('The file %file was uploaded to the correct path.', array('%file' => $node_file->getFileUri()))); // Change the path to contain multiple subdirectories. $this->updateFileField($field_name, $type_name, array('file_directory' => 'foo/bar/baz')); diff --git a/core/modules/file/src/Tests/FileFieldRSSContentTest.php b/core/modules/file/src/Tests/FileFieldRSSContentTest.php index 5314a7bbb..dd31f85a2 100644 --- a/core/modules/file/src/Tests/FileFieldRSSContentTest.php +++ b/core/modules/file/src/Tests/FileFieldRSSContentTest.php @@ -7,7 +7,6 @@ namespace Drupal\file\Tests; -use Drupal\node\Entity\Node; use Drupal\file\Entity\File; /** diff --git a/core/modules/file/src/Tests/SaveTest.php b/core/modules/file/src/Tests/SaveTest.php index 97d4882e6..ecd7d6095 100644 --- a/core/modules/file/src/Tests/SaveTest.php +++ b/core/modules/file/src/Tests/SaveTest.php @@ -8,9 +8,6 @@ namespace Drupal\file\Tests; use Drupal\file\Entity\File; -use Drupal\Core\Entity\EntityStorageException; -use Drupal\Core\Entity\EntityStorageInterface; -use Drupal\Core\Entity\Sql\SqlEntityStorageInterface; /** * File saving tests. diff --git a/core/modules/file/tests/src/Unit/Plugin/migrate/process/d6/CckFileTest.php b/core/modules/file/tests/src/Unit/Plugin/migrate/process/d6/CckFileTest.php new file mode 100644 index 000000000..b98d3a908 --- /dev/null +++ b/core/modules/file/tests/src/Unit/Plugin/migrate/process/d6/CckFileTest.php @@ -0,0 +1,56 @@ +prophesize(MigrateExecutableInterface::class)->reveal(); + $row = $this->prophesize(Row::class)->reveal(); + $migration = $this->prophesize(MigrationInterface::class)->reveal(); + + $migration_plugin = $this->prophesize(MigrateProcessInterface::class); + $migration_plugin->transform(1, $executable, $row, 'foo')->willReturn(1); + + $plugin = new CckFile(array(), 'd6_cck_file', array(), $migration, $migration_plugin->reveal()); + + $options = array( + 'alt' => 'Foobaz', + 'title' => 'Wambooli', + ); + $value = array( + 'fid' => 1, + 'list' => TRUE, + 'data' => serialize($options), + ); + + $transformed = $plugin->transform($value, $executable, $row, 'foo'); + $expected = array( + 'target_id' => 1, + 'display' => TRUE, + 'description' => '', + 'alt' => 'Foobaz', + 'title' => 'Wambooli', + ); + $this->assertSame($expected, $transformed); + } + +} diff --git a/core/modules/filter/filter.admin.js b/core/modules/filter/filter.admin.js index 3af562455..801067163 100644 --- a/core/modules/filter/filter.admin.js +++ b/core/modules/filter/filter.admin.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Displays and updates the status of filters on the admin page. diff --git a/core/modules/filter/filter.filter_html.admin.js b/core/modules/filter/filter.filter_html.admin.js index 5de2d11d5..8c9cef64f 100644 --- a/core/modules/filter/filter.filter_html.admin.js +++ b/core/modules/filter/filter.filter_html.admin.js @@ -5,7 +5,7 @@ (function ($, _, document, window) { - "use strict"; + 'use strict'; if (Drupal.filterConfiguration) { diff --git a/core/modules/filter/filter.js b/core/modules/filter/filter.js index cdb0795aa..2455b7fec 100644 --- a/core/modules/filter/filter.js +++ b/core/modules/filter/filter.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Displays the guidelines of the selected text format automatically. diff --git a/core/modules/filter/filter.module b/core/modules/filter/filter.module index 3afa7a113..f1f28b516 100644 --- a/core/modules/filter/filter.module +++ b/core/modules/filter/filter.module @@ -7,7 +7,6 @@ use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Unicode; -use Drupal\Component\Utility\Xss; use Drupal\Core\Cache\Cache; use Drupal\Core\Render\Element; use Drupal\Core\Routing\RouteMatchInterface; diff --git a/core/modules/filter/src/Element/ProcessedText.php b/core/modules/filter/src/Element/ProcessedText.php index 6a3fa4018..fc7e52b93 100644 --- a/core/modules/filter/src/Element/ProcessedText.php +++ b/core/modules/filter/src/Element/ProcessedText.php @@ -7,11 +7,9 @@ namespace Drupal\filter\Element; -use Drupal\Component\Utility\NestedArray; use Drupal\Core\Cache\Cache; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Render\Element\RenderElement; -use Drupal\Core\Render\Renderer; use Drupal\filter\Entity\FilterFormat; use Drupal\filter\Plugin\FilterInterface; use Drupal\filter\Render\FilteredMarkup; diff --git a/core/modules/filter/src/FilterFormatFormBase.php b/core/modules/filter/src/FilterFormatFormBase.php index e1222b45d..a528c0d90 100644 --- a/core/modules/filter/src/FilterFormatFormBase.php +++ b/core/modules/filter/src/FilterFormatFormBase.php @@ -7,7 +7,6 @@ namespace Drupal\filter; -use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Entity\EntityForm; use Drupal\Core\Entity\Query\QueryFactory; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/filter/src/Tests/FilterAPITest.php b/core/modules/filter/src/Tests/FilterAPITest.php index b8a93f1dd..08a5e56b1 100644 --- a/core/modules/filter/src/Tests/FilterAPITest.php +++ b/core/modules/filter/src/Tests/FilterAPITest.php @@ -8,7 +8,6 @@ namespace Drupal\filter\Tests; use Drupal\Core\Language\LanguageInterface; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Session\AnonymousUserSession; use Drupal\Core\TypedData\OptionsProviderInterface; use Drupal\Core\TypedData\DataDefinition; diff --git a/core/modules/filter/src/Tests/FilterUnitTest.php b/core/modules/filter/src/Tests/FilterUnitTest.php index 1e3d3337f..a407ebf34 100644 --- a/core/modules/filter/src/Tests/FilterUnitTest.php +++ b/core/modules/filter/src/Tests/FilterUnitTest.php @@ -8,7 +8,6 @@ namespace Drupal\filter\Tests; use Drupal\Component\Utility\Html; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Language\Language; use Drupal\Core\Render\RenderContext; use Drupal\editor\EditorXssFilter\Standard; diff --git a/core/modules/filter/tests/filter_test/src/Plugin/Filter/FilterTestCacheMerge.php b/core/modules/filter/tests/filter_test/src/Plugin/Filter/FilterTestCacheMerge.php index 9e56c9bf9..8d5608d31 100644 --- a/core/modules/filter/tests/filter_test/src/Plugin/Filter/FilterTestCacheMerge.php +++ b/core/modules/filter/tests/filter_test/src/Plugin/Filter/FilterTestCacheMerge.php @@ -10,7 +10,6 @@ use Drupal\filter\FilterProcessResult; use Drupal\filter\Plugin\FilterBase; use Drupal\Core\Cache\CacheableMetadata; -use Drupal\Core\Language\LanguageInterface; /** * Provides a test filter to merge with CacheableMetadata. diff --git a/core/modules/forum/forum.module b/core/modules/forum/forum.module index 7921a36ca..c82c167b5 100644 --- a/core/modules/forum/forum.module +++ b/core/modules/forum/forum.module @@ -7,7 +7,6 @@ use Drupal\comment\CommentInterface; use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; -use Drupal\Component\Utility\Xss; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Url; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/forum/src/Form/Overview.php b/core/modules/forum/src/Form/Overview.php index 5f9b6f33c..720ee85f9 100644 --- a/core/modules/forum/src/Form/Overview.php +++ b/core/modules/forum/src/Form/Overview.php @@ -12,9 +12,7 @@ use Drupal\Core\Render\Element; use Drupal\Core\Url; use Drupal\taxonomy\Form\OverviewTerms; -use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Extension\ModuleHandlerInterface; -use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; /* diff --git a/core/modules/forum/src/Plugin/Block/ForumBlockBase.php b/core/modules/forum/src/Plugin/Block/ForumBlockBase.php index 5e8fbebc5..53b07272b 100644 --- a/core/modules/forum/src/Plugin/Block/ForumBlockBase.php +++ b/core/modules/forum/src/Plugin/Block/ForumBlockBase.php @@ -11,7 +11,6 @@ use Drupal\Core\Block\BlockBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\Core\Cache\Cache; use Drupal\Core\Url; /** diff --git a/core/modules/forum/src/Plugin/Validation/Constraint/ForumLeafConstraintValidator.php b/core/modules/forum/src/Plugin/Validation/Constraint/ForumLeafConstraintValidator.php index f2d240067..10dd3cfc5 100644 --- a/core/modules/forum/src/Plugin/Validation/Constraint/ForumLeafConstraintValidator.php +++ b/core/modules/forum/src/Plugin/Validation/Constraint/ForumLeafConstraintValidator.php @@ -7,7 +7,6 @@ namespace Drupal\forum\Plugin\Validation\Constraint; -use Drupal\Component\Utility\Unicode; use Symfony\Component\Validator\Constraint; use Symfony\Component\Validator\ConstraintValidator; diff --git a/core/modules/forum/src/Tests/ForumUninstallTest.php b/core/modules/forum/src/Tests/ForumUninstallTest.php index d6186f05c..8eb13452f 100644 --- a/core/modules/forum/src/Tests/ForumUninstallTest.php +++ b/core/modules/forum/src/Tests/ForumUninstallTest.php @@ -8,10 +8,6 @@ namespace Drupal\forum\Tests; use Drupal\comment\CommentInterface; -use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; -use Drupal\Core\DrupalKernel; -use Drupal\Core\Session\UserSession; -use Drupal\Core\Site\Settings; use Drupal\field\Entity\FieldStorageConfig; use Drupal\node\Entity\NodeType; use Drupal\simpletest\WebTestBase; diff --git a/core/modules/forum/src/Tests/Migrate/d7/MigrateForumSettingsTest.php b/core/modules/forum/src/Tests/Migrate/d7/MigrateForumSettingsTest.php index 008ace0cd..9eb80e7cd 100644 --- a/core/modules/forum/src/Tests/Migrate/d7/MigrateForumSettingsTest.php +++ b/core/modules/forum/src/Tests/Migrate/d7/MigrateForumSettingsTest.php @@ -7,8 +7,6 @@ namespace Drupal\forum\Tests\Migrate\d7; -use Drupal\migrate\Entity\Migration; -use Drupal\migrate\MigrateExecutable; use Drupal\migrate_drupal\Tests\d7\MigrateDrupal7TestBase; /** diff --git a/core/modules/forum/tests/src/Unit/Breadcrumb/ForumListingBreadcrumbBuilderTest.php b/core/modules/forum/tests/src/Unit/Breadcrumb/ForumListingBreadcrumbBuilderTest.php index b59139491..36fd401eb 100644 --- a/core/modules/forum/tests/src/Unit/Breadcrumb/ForumListingBreadcrumbBuilderTest.php +++ b/core/modules/forum/tests/src/Unit/Breadcrumb/ForumListingBreadcrumbBuilderTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Link; use Drupal\Tests\UnitTestCase; -use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\DependencyInjection\Container; /** diff --git a/core/modules/hal/src/Normalizer/NormalizerBase.php b/core/modules/hal/src/Normalizer/NormalizerBase.php index 9b049777e..e92a1e27f 100644 --- a/core/modules/hal/src/Normalizer/NormalizerBase.php +++ b/core/modules/hal/src/Normalizer/NormalizerBase.php @@ -7,7 +7,6 @@ namespace Drupal\hal\Normalizer; -use Drupal\serialization\EntityResolver\EntityResolverInterface; use Drupal\serialization\Normalizer\NormalizerBase as SerializationNormalizerBase; use Symfony\Component\Serializer\Normalizer\DenormalizerInterface; diff --git a/core/modules/help/src/Plugin/Block/HelpBlock.php b/core/modules/help/src/Plugin/Block/HelpBlock.php index abe3c254e..0a29dddff 100644 --- a/core/modules/help/src/Plugin/Block/HelpBlock.php +++ b/core/modules/help/src/Plugin/Block/HelpBlock.php @@ -7,12 +7,10 @@ namespace Drupal\help\Plugin\Block; -use Drupal\Core\Access\AccessResult; use Drupal\Core\Block\BlockBase; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Routing\RouteMatchInterface; -use Drupal\Core\Session\AccountInterface; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\Request; diff --git a/core/modules/history/js/history.js b/core/modules/history/js/history.js index 789f085a9..6ce807c07 100644 --- a/core/modules/history/js/history.js +++ b/core/modules/history/js/history.js @@ -7,7 +7,7 @@ (function ($, Drupal, drupalSettings, storage) { - "use strict"; + 'use strict'; var currentUserID = parseInt(drupalSettings.user.uid, 10); diff --git a/core/modules/history/js/mark-as-read.js b/core/modules/history/js/mark-as-read.js index 848d3519b..e225401e3 100644 --- a/core/modules/history/js/mark-as-read.js +++ b/core/modules/history/js/mark-as-read.js @@ -9,7 +9,7 @@ (function (window, Drupal, drupalSettings) { - "use strict"; + 'use strict'; // When the window's "load" event is triggered, mark all enumerated nodes as // read. This still allows for Drupal behaviors (which are triggered on the diff --git a/core/modules/image/image.field.inc b/core/modules/image/image.field.inc index 49c6534f5..1bf4369e7 100644 --- a/core/modules/image/image.field.inc +++ b/core/modules/image/image.field.inc @@ -5,7 +5,6 @@ * Implement an image field, based on the file module's file field. */ -use Drupal\Component\Utility\NestedArray; use Drupal\Component\Utility\Unicode; use Drupal\Core\Render\Element; diff --git a/core/modules/image/src/Form/ImageEffectAddForm.php b/core/modules/image/src/Form/ImageEffectAddForm.php index e491d0791..8bbe2c4a0 100644 --- a/core/modules/image/src/Form/ImageEffectAddForm.php +++ b/core/modules/image/src/Form/ImageEffectAddForm.php @@ -7,7 +7,6 @@ namespace Drupal\image\Form; -use Drupal\Core\DependencyInjection\ContainerInjectionInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\image\ImageEffectManager; use Drupal\image\ImageStyleInterface; diff --git a/core/modules/image/src/Form/ImageStyleEditForm.php b/core/modules/image/src/Form/ImageStyleEditForm.php index d17a12958..b3e7f8e89 100644 --- a/core/modules/image/src/Form/ImageStyleEditForm.php +++ b/core/modules/image/src/Form/ImageStyleEditForm.php @@ -273,7 +273,7 @@ public function actions(array $form, FormStateInterface $form_state) { * Updates image effect weights. * * @param array $effects - * Associative array with effects having effect uuid as keys and and array + * Associative array with effects having effect uuid as keys and array * with effect data as values. */ protected function updateEffectWeights(array $effects) { diff --git a/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php b/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php index aa24a9551..572041527 100644 --- a/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php +++ b/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php @@ -12,10 +12,8 @@ use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Link; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; -use Drupal\Core\Routing\UrlGeneratorInterface; use Drupal\Core\Session\AccountInterface; use Drupal\Core\Url; -use Drupal\Core\Utility\LinkGeneratorInterface; use Symfony\Component\DependencyInjection\ContainerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Cache\Cache; diff --git a/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatterBase.php b/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatterBase.php index 6f794974b..899aa4957 100644 --- a/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatterBase.php +++ b/core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatterBase.php @@ -8,7 +8,6 @@ namespace Drupal\image\Plugin\Field\FieldFormatter; use Drupal\Core\Field\EntityReferenceFieldItemListInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\field\FieldConfigInterface; use Drupal\file\Plugin\Field\FieldFormatter\FileFormatterBase; diff --git a/core/modules/image/src/Plugin/Field/FieldWidget/ImageWidget.php b/core/modules/image/src/Plugin/Field/FieldWidget/ImageWidget.php index ec83970d0..82092e65a 100644 --- a/core/modules/image/src/Plugin/Field/FieldWidget/ImageWidget.php +++ b/core/modules/image/src/Plugin/Field/FieldWidget/ImageWidget.php @@ -71,7 +71,7 @@ public function settingsSummary() { $preview_image_style = t('Preview image style: @style', array('@style' => $image_styles[$image_style_setting])); } else { - $preview_image_style = t('Original image'); + $preview_image_style = t('No preview'); } array_unshift($summary, $preview_image_style); diff --git a/core/modules/image/src/Plugin/migrate/process/d6/ImageCacheActions.php b/core/modules/image/src/Plugin/migrate/process/d6/ImageCacheActions.php index deb993441..30e4dec67 100644 --- a/core/modules/image/src/Plugin/migrate/process/d6/ImageCacheActions.php +++ b/core/modules/image/src/Plugin/migrate/process/d6/ImageCacheActions.php @@ -8,7 +8,6 @@ namespace Drupal\image\Plugin\migrate\process\d6; use Drupal\migrate\MigrateExecutableInterface; -use Drupal\migrate\MigrateSkipRowException; use Drupal\migrate\ProcessPluginBase; use Drupal\migrate\Row; diff --git a/core/modules/image/src/Plugin/migrate/source/d6/ImageCachePreset.php b/core/modules/image/src/Plugin/migrate/source/d6/ImageCachePreset.php index 8c563f0b9..7745772c4 100644 --- a/core/modules/image/src/Plugin/migrate/source/d6/ImageCachePreset.php +++ b/core/modules/image/src/Plugin/migrate/source/d6/ImageCachePreset.php @@ -14,7 +14,8 @@ * Drupal 6 imagecache presets source from database. * * @MigrateSource( - * id = "d6_imagecache_presets" + * id = "d6_imagecache_presets", + * source_provider = "imagecache" * ) */ class ImageCachePreset extends DrupalSqlBase { diff --git a/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php b/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php index 1de060715..81c16285d 100644 --- a/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php +++ b/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php @@ -8,7 +8,6 @@ namespace Drupal\image\Tests; use Drupal\simpletest\WebTestBase; -use Symfony\Component\HttpFoundation\Request; /** * Tests the functions for generating paths and URLs for image styles. diff --git a/core/modules/image/src/Tests/Migrate/d6/MigrateImageCacheTest.php b/core/modules/image/src/Tests/Migrate/d6/MigrateImageCacheTest.php index 55cdc27cc..99ee2925b 100644 --- a/core/modules/image/src/Tests/Migrate/d6/MigrateImageCacheTest.php +++ b/core/modules/image/src/Tests/Migrate/d6/MigrateImageCacheTest.php @@ -9,13 +9,13 @@ use Drupal\Core\Database\Database; use Drupal\image\Entity\ImageStyle; -use \Drupal\image\ConfigurableImageEffectBase; +use Drupal\migrate\Entity\Migration; use Drupal\migrate\Entity\MigrationInterface; -use Drupal\migrate\MigrateException; +use Drupal\migrate\Exception\RequirementsException; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; /** - * Migrate ImageCache presets to Image styles + * Tests migration of ImageCache presets to image styles. * * @group image */ @@ -29,6 +29,29 @@ public function setUp() { $this->installConfig(['image']); } + /** + * Tests that an exception is thrown when ImageCache is not installed. + */ + public function testMissingTable() { + $this->sourceDatabase->update('system') + ->fields(array( + 'status' => 0, + )) + ->condition('name', 'imagecache') + ->condition('type', 'module') + ->execute(); + + try { + Migration::load('d6_imagecache_presets') + ->getSourcePlugin() + ->checkRequirements(); + $this->fail('Did not catch expected RequirementsException.'); + } + catch (RequirementsException $e) { + $this->pass('Caught expected RequirementsException: ' . $e->getMessage()); + } + } + /** * Test basic passing migrations. */ diff --git a/core/modules/language/language.admin.js b/core/modules/language/language.admin.js index cedd78d7a..9d3daa4ce 100644 --- a/core/modules/language/language.admin.js +++ b/core/modules/language/language.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Makes language negotiation inherit user interface negotiation. diff --git a/core/modules/language/src/ConfigurableLanguageInterface.php b/core/modules/language/src/ConfigurableLanguageInterface.php index 401848bc9..9106df568 100644 --- a/core/modules/language/src/ConfigurableLanguageInterface.php +++ b/core/modules/language/src/ConfigurableLanguageInterface.php @@ -8,7 +8,6 @@ namespace Drupal\language; use Drupal\Core\Config\Entity\ConfigEntityInterface; -use Drupal\Core\Language\Language; use Drupal\Core\Language\LanguageInterface; /** diff --git a/core/modules/language/src/ConfigurableLanguageManagerInterface.php b/core/modules/language/src/ConfigurableLanguageManagerInterface.php index 8f78de75d..57d365df7 100644 --- a/core/modules/language/src/ConfigurableLanguageManagerInterface.php +++ b/core/modules/language/src/ConfigurableLanguageManagerInterface.php @@ -9,7 +9,6 @@ use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Language\LanguageManagerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Common interface for language negotiation services. diff --git a/core/modules/language/src/Form/LanguageAddForm.php b/core/modules/language/src/Form/LanguageAddForm.php index d43927b5d..964883c89 100644 --- a/core/modules/language/src/Form/LanguageAddForm.php +++ b/core/modules/language/src/Form/LanguageAddForm.php @@ -11,8 +11,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Language\LanguageManager; use Drupal\language\Entity\ConfigurableLanguage; -use Drupal\language\Form\LanguageFormBase; -use Drupal\Core\Language\Language; /** * Controller for language addition forms. diff --git a/core/modules/language/src/Form/LanguageDeleteForm.php b/core/modules/language/src/Form/LanguageDeleteForm.php index 3dfdb3524..9810f2c0d 100644 --- a/core/modules/language/src/Form/LanguageDeleteForm.php +++ b/core/modules/language/src/Form/LanguageDeleteForm.php @@ -8,7 +8,6 @@ namespace Drupal\language\Form; use Drupal\Core\Entity\EntityDeleteForm; -use Drupal\Core\Form\FormStateInterface; /** * Defines a confirmation form for deleting a language entity. diff --git a/core/modules/language/src/Form/LanguageEditForm.php b/core/modules/language/src/Form/LanguageEditForm.php index 79a3a171e..bb5abdedb 100644 --- a/core/modules/language/src/Form/LanguageEditForm.php +++ b/core/modules/language/src/Form/LanguageEditForm.php @@ -8,7 +8,6 @@ namespace Drupal\language\Form; use Drupal\Core\Form\FormStateInterface; -use Drupal\language\Form\LanguageFormBase; /** * Controller for language edit forms. diff --git a/core/modules/language/src/Form/NegotiationBrowserDeleteForm.php b/core/modules/language/src/Form/NegotiationBrowserDeleteForm.php index 857cf3258..2877d4deb 100644 --- a/core/modules/language/src/Form/NegotiationBrowserDeleteForm.php +++ b/core/modules/language/src/Form/NegotiationBrowserDeleteForm.php @@ -11,7 +11,6 @@ use Drupal\Core\Form\ConfirmFormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; -use Symfony\Component\HttpFoundation\Request; /** * Defines a confirmation form for deleting a browser language negotiation mapping. diff --git a/core/modules/language/src/Form/NegotiationConfigureForm.php b/core/modules/language/src/Form/NegotiationConfigureForm.php index 7f2304515..a5b79a7c4 100644 --- a/core/modules/language/src/Form/NegotiationConfigureForm.php +++ b/core/modules/language/src/Form/NegotiationConfigureForm.php @@ -9,7 +9,6 @@ use Drupal\Core\Block\BlockManagerInterface; use Drupal\Component\Utility\Unicode; -use Drupal\Component\Utility\Xss; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Extension\ThemeHandlerInterface; diff --git a/core/modules/language/src/Tests/Condition/LanguageConditionTest.php b/core/modules/language/src/Tests/Condition/LanguageConditionTest.php index 9cd3cf9d4..e976ae0b4 100644 --- a/core/modules/language/src/Tests/Condition/LanguageConditionTest.php +++ b/core/modules/language/src/Tests/Condition/LanguageConditionTest.php @@ -9,7 +9,6 @@ use Drupal\language\Entity\ConfigurableLanguage; use Drupal\simpletest\KernelTestBase; -use Drupal\Core\Condition\ConditionManager; /** * Tests that the language condition, provided by the language module, is diff --git a/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php b/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php index c66fce7f7..845528bfd 100644 --- a/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php +++ b/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php @@ -7,10 +7,7 @@ namespace Drupal\language\Tests; -use Drupal\Component\Utility\UserAgent; -use Drupal\Core\Language\Language; use Drupal\simpletest\WebTestBase; -use Symfony\Component\HttpFoundation\Request; /** * Tests browser language detection. diff --git a/core/modules/language/src/Tests/LanguageDependencyInjectionTest.php b/core/modules/language/src/Tests/LanguageDependencyInjectionTest.php index 8b289abce..fc13a61b1 100644 --- a/core/modules/language/src/Tests/LanguageDependencyInjectionTest.php +++ b/core/modules/language/src/Tests/LanguageDependencyInjectionTest.php @@ -7,8 +7,6 @@ namespace Drupal\language\Tests; -use Drupal\Core\DependencyInjection\ContainerBuilder; -use Drupal\Core\Language\Language; use Drupal\language\Entity\ConfigurableLanguage; use Drupal\language\Exception\DeleteDefaultLanguageException; diff --git a/core/modules/language/tests/language_test/src/Plugin/LanguageNegotiation/LanguageNegotiationTestTs.php b/core/modules/language/tests/language_test/src/Plugin/LanguageNegotiation/LanguageNegotiationTestTs.php index c9d1e9c08..4efde9f2a 100644 --- a/core/modules/language/tests/language_test/src/Plugin/LanguageNegotiation/LanguageNegotiationTestTs.php +++ b/core/modules/language/tests/language_test/src/Plugin/LanguageNegotiation/LanguageNegotiationTestTs.php @@ -7,8 +7,6 @@ namespace Drupal\language_test\Plugin\LanguageNegotiation; -use Symfony\Component\HttpFoundation\Request; - /** * Class for identifying language from a selected language. * diff --git a/core/modules/language/tests/src/Unit/ConfigurableLanguageUnitTest.php b/core/modules/language/tests/src/Unit/ConfigurableLanguageUnitTest.php index 44967ada5..02e745777 100644 --- a/core/modules/language/tests/src/Unit/ConfigurableLanguageUnitTest.php +++ b/core/modules/language/tests/src/Unit/ConfigurableLanguageUnitTest.php @@ -6,9 +6,6 @@ namespace Drupal\Tests\language\Unit; -use Drupal\Core\DependencyInjection\ContainerBuilder; -use Drupal\Core\Entity\EntityType; -use Drupal\Core\Language\Language; use Drupal\language\Entity\ConfigurableLanguage; use Drupal\Tests\UnitTestCase; diff --git a/core/modules/language/tests/src/Unit/LanguageNegotiationUrlTest.php b/core/modules/language/tests/src/Unit/LanguageNegotiationUrlTest.php index d0d946e06..f1d2914fe 100644 --- a/core/modules/language/tests/src/Unit/LanguageNegotiationUrlTest.php +++ b/core/modules/language/tests/src/Unit/LanguageNegotiationUrlTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Render\BubbleableMetadata; -use Drupal\Core\Session\UserSession; use Drupal\Tests\UnitTestCase; use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl; use Symfony\Component\DependencyInjection\ContainerBuilder; diff --git a/core/modules/link/src/Plugin/Field/FieldFormatter/LinkFormatter.php b/core/modules/link/src/Plugin/Field/FieldFormatter/LinkFormatter.php index aeb208cda..a7e104b1f 100644 --- a/core/modules/link/src/Plugin/Field/FieldFormatter/LinkFormatter.php +++ b/core/modules/link/src/Plugin/Field/FieldFormatter/LinkFormatter.php @@ -8,7 +8,6 @@ namespace Drupal\link\Plugin\Field\FieldFormatter; use Drupal\Component\Utility\Unicode; -use Drupal\Component\Utility\UrlHelper; use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Field\FormatterBase; @@ -18,7 +17,6 @@ use Drupal\Core\Url; use Drupal\link\LinkItemInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Plugin implementation of the 'link' formatter. diff --git a/core/modules/link/src/Plugin/Field/FieldType/LinkItem.php b/core/modules/link/src/Plugin/Field/FieldType/LinkItem.php index 4c0467c64..5c21ace87 100644 --- a/core/modules/link/src/Plugin/Field/FieldType/LinkItem.php +++ b/core/modules/link/src/Plugin/Field/FieldType/LinkItem.php @@ -8,7 +8,6 @@ namespace Drupal\link\Plugin\Field\FieldType; use Drupal\Component\Utility\Random; -use Drupal\Component\Utility\UrlHelper; use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldItemBase; use Drupal\Core\Field\FieldStorageDefinitionInterface; diff --git a/core/modules/link/src/Plugin/Field/FieldWidget/LinkWidget.php b/core/modules/link/src/Plugin/Field/FieldWidget/LinkWidget.php index b2470e637..9c97caa72 100644 --- a/core/modules/link/src/Plugin/Field/FieldWidget/LinkWidget.php +++ b/core/modules/link/src/Plugin/Field/FieldWidget/LinkWidget.php @@ -7,14 +7,11 @@ namespace Drupal\link\Plugin\Field\FieldWidget; -use Drupal\Component\Utility\UrlHelper; use Drupal\Core\Entity\Element\EntityAutocomplete; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Field\WidgetBase; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Url; use Drupal\link\LinkItemInterface; -use Symfony\Component\Routing\Exception\RouteNotFoundException; use Symfony\Component\Validator\ConstraintViolation; use Symfony\Component\Validator\ConstraintViolationListInterface; diff --git a/core/modules/link/src/Plugin/migrate/process/d6/CckLink.php b/core/modules/link/src/Plugin/migrate/process/d6/CckLink.php index becf88c43..d70567122 100644 --- a/core/modules/link/src/Plugin/migrate/process/d6/CckLink.php +++ b/core/modules/link/src/Plugin/migrate/process/d6/CckLink.php @@ -45,8 +45,11 @@ public static function create(ContainerInterface $container, array $configuratio * {@inheritdoc} */ public function transform($value, MigrateExecutableInterface $migrate_executable, Row $row, $destination_property) { - // Drupal 6 link attributes are double serialized. - $attributes = unserialize(unserialize($value['attributes'])); + $attributes = unserialize($value['attributes']); + // Drupal 6 link attributes might be double serialized. + if (!is_array($attributes)) { + $attributes = unserialize($attributes); + } // Massage the values into the correct form for the link. $route['uri'] = $value['url']; diff --git a/core/modules/link/src/Tests/LinkFieldTest.php b/core/modules/link/src/Tests/LinkFieldTest.php index 4b61f730a..494936a09 100644 --- a/core/modules/link/src/Tests/LinkFieldTest.php +++ b/core/modules/link/src/Tests/LinkFieldTest.php @@ -318,7 +318,7 @@ function testLinkTitle() { $edit = array( "{$field_name}[0][title]" => $title, ); - $this->drupalPostForm("entity_test/manage/$id", $edit, t('Save')); + $this->drupalPostForm("entity_test/manage/$id/edit", $edit, t('Save')); $this->assertText(t('entity_test @id has been updated.', array('@id' => $id))); $this->renderTestEntity($id); diff --git a/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkAccessConstraintValidatorTest.php b/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkAccessConstraintValidatorTest.php index 82db60c77..7089e4718 100644 --- a/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkAccessConstraintValidatorTest.php +++ b/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkAccessConstraintValidatorTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\link\Unit\Plugin\Validation\Constraint; -use Drupal\Core\Url; use Drupal\link\Plugin\Validation\Constraint\LinkAccessConstraint; use Drupal\link\Plugin\Validation\Constraint\LinkAccessConstraintValidator; use Drupal\Tests\UnitTestCase; diff --git a/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkNotExistingInternalConstraintValidatorTest.php b/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkNotExistingInternalConstraintValidatorTest.php index 2325306c9..aa2e527bb 100644 --- a/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkNotExistingInternalConstraintValidatorTest.php +++ b/core/modules/link/tests/src/Unit/Plugin/Validation/Constraint/LinkNotExistingInternalConstraintValidatorTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\link\Unit\Plugin\Validation\Constraint; -use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Core\Url; use Drupal\link\Plugin\Validation\Constraint\LinkNotExistingInternalConstraint; use Drupal\link\Plugin\Validation\Constraint\LinkNotExistingInternalConstraintValidator; diff --git a/core/modules/locale/locale.admin.js b/core/modules/locale/locale.admin.js index be54349f2..d9701ef94 100644 --- a/core/modules/locale/locale.admin.js +++ b/core/modules/locale/locale.admin.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Marks changes of translations. @@ -19,7 +19,7 @@ */ Drupal.behaviors.localeTranslateDirty = { attach: function () { - var $form = $("#locale-translate-edit-form").once('localetranslatedirty'); + var $form = $('#locale-translate-edit-form').once('localetranslatedirty'); if ($form.length) { // Display a notice if any row changed. $form.one('formUpdated.localeTranslateDirty', 'table', function () { @@ -43,7 +43,7 @@ }, detach: function (context, settings, trigger) { if (trigger === 'unload') { - var $form = $("#locale-translate-edit-form").removeOnce('localetranslatedirty'); + var $form = $('#locale-translate-edit-form').removeOnce('localetranslatedirty'); if ($form.length) { $form.off('formUpdated.localeTranslateDirty'); } diff --git a/core/modules/locale/locale.bulk.js b/core/modules/locale/locale.bulk.js index c6c4daf56..c6743e832 100644 --- a/core/modules/locale/locale.bulk.js +++ b/core/modules/locale/locale.bulk.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Select the language code of an imported file based on its filename. diff --git a/core/modules/locale/locale.datepicker.js b/core/modules/locale/locale.datepicker.js index 197fc421a..a952ade32 100644 --- a/core/modules/locale/locale.datepicker.js +++ b/core/modules/locale/locale.datepicker.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Attaches language support to the jQuery UI datepicker component. @@ -23,18 +23,18 @@ nextText: Drupal.t('Next'), currentText: Drupal.t('Today'), monthNames: [ - Drupal.t('January', {}, {context: "Long month name"}), - Drupal.t('February', {}, {context: "Long month name"}), - Drupal.t('March', {}, {context: "Long month name"}), - Drupal.t('April', {}, {context: "Long month name"}), - Drupal.t('May', {}, {context: "Long month name"}), - Drupal.t('June', {}, {context: "Long month name"}), - Drupal.t('July', {}, {context: "Long month name"}), - Drupal.t('August', {}, {context: "Long month name"}), - Drupal.t('September', {}, {context: "Long month name"}), - Drupal.t('October', {}, {context: "Long month name"}), - Drupal.t('November', {}, {context: "Long month name"}), - Drupal.t('December', {}, {context: "Long month name"}) + Drupal.t('January', {}, {context: 'Long month name'}), + Drupal.t('February', {}, {context: 'Long month name'}), + Drupal.t('March', {}, {context: 'Long month name'}), + Drupal.t('April', {}, {context: 'Long month name'}), + Drupal.t('May', {}, {context: 'Long month name'}), + Drupal.t('June', {}, {context: 'Long month name'}), + Drupal.t('July', {}, {context: 'Long month name'}), + Drupal.t('August', {}, {context: 'Long month name'}), + Drupal.t('September', {}, {context: 'Long month name'}), + Drupal.t('October', {}, {context: 'Long month name'}), + Drupal.t('November', {}, {context: 'Long month name'}), + Drupal.t('December', {}, {context: 'Long month name'}) ], monthNamesShort: [ Drupal.t('Jan'), diff --git a/core/modules/locale/locale.install b/core/modules/locale/locale.install index 94b5a4424..075510441 100644 --- a/core/modules/locale/locale.install +++ b/core/modules/locale/locale.install @@ -6,8 +6,6 @@ */ use Drupal\Core\Url; -use Drupal\Core\Language\Language; -use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationSelected; /** * Implements hook_install(). diff --git a/core/modules/locale/locale.module b/core/modules/locale/locale.module index 387d0c3b7..ca8df4746 100644 --- a/core/modules/locale/locale.module +++ b/core/modules/locale/locale.module @@ -16,11 +16,8 @@ use Drupal\Component\Utility\UrlHelper; use Drupal\Component\Utility\Xss; use Drupal\Core\Url; use Drupal\Core\Asset\AttachedAssetsInterface; -use Drupal\Core\Cache\Cache; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Language\Language; use Drupal\Core\Routing\RouteMatchInterface; -use Drupal\Core\StringTranslation\TranslatableMarkup; use Drupal\Core\Language\LanguageInterface; use Drupal\language\ConfigurableLanguageInterface; use Drupal\Component\Utility\Crypt; diff --git a/core/modules/locale/locale.pages.inc b/core/modules/locale/locale.pages.inc index 83bdebb70..d4776d55f 100644 --- a/core/modules/locale/locale.pages.inc +++ b/core/modules/locale/locale.pages.inc @@ -5,13 +5,9 @@ * Interface translation summary, editing and deletion user interfaces. */ -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Url; use Drupal\Core\Render\Element; -use Drupal\locale\SourceString; -use Drupal\locale\TranslationString; use Symfony\Component\HttpFoundation\RedirectResponse; -use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; /** * Page callback: Checks for translation updates and displays the status. diff --git a/core/modules/locale/src/Controller/LocaleController.php b/core/modules/locale/src/Controller/LocaleController.php index 0638b08b0..921629619 100644 --- a/core/modules/locale/src/Controller/LocaleController.php +++ b/core/modules/locale/src/Controller/LocaleController.php @@ -7,7 +7,6 @@ namespace Drupal\locale\Controller; use Drupal\Core\Controller\ControllerBase; -use Symfony\Component\HttpFoundation\RedirectResponse; /** * Return response for manual check translations. diff --git a/core/modules/locale/src/Gettext.php b/core/modules/locale/src/Gettext.php index dfefe906d..4d5b65ee0 100644 --- a/core/modules/locale/src/Gettext.php +++ b/core/modules/locale/src/Gettext.php @@ -8,8 +8,6 @@ namespace Drupal\locale; use Drupal\Component\Gettext\PoStreamReader; -use Drupal\Component\Gettext\PoMemoryWriter; -use Drupal\locale\PoDatabaseWriter; /** * Static class providing Drupal specific Gettext functionality. diff --git a/core/modules/locale/src/LocaleConfigManager.php b/core/modules/locale/src/LocaleConfigManager.php index 1312f6d40..cab881661 100644 --- a/core/modules/locale/src/LocaleConfigManager.php +++ b/core/modules/locale/src/LocaleConfigManager.php @@ -9,7 +9,6 @@ use Drupal\Component\Utility\NestedArray; use Drupal\Core\Config\ConfigFactoryInterface; -use Drupal\Core\Config\InstallStorage; use Drupal\Core\Config\StorageInterface; use Drupal\Core\Config\TypedConfigManagerInterface; use Drupal\Core\StringTranslation\TranslatableMarkup; diff --git a/core/modules/locale/src/PoDatabaseReader.php b/core/modules/locale/src/PoDatabaseReader.php index 7e7519eb7..86bf65571 100644 --- a/core/modules/locale/src/PoDatabaseReader.php +++ b/core/modules/locale/src/PoDatabaseReader.php @@ -10,7 +10,6 @@ use Drupal\Component\Gettext\PoHeader; use Drupal\Component\Gettext\PoItem; use Drupal\Component\Gettext\PoReaderInterface; -use Drupal\locale\TranslationString; /** * Gettext PO reader working with the locale module database. diff --git a/core/modules/locale/src/PoDatabaseWriter.php b/core/modules/locale/src/PoDatabaseWriter.php index 27b9b78c0..c79944c1a 100644 --- a/core/modules/locale/src/PoDatabaseWriter.php +++ b/core/modules/locale/src/PoDatabaseWriter.php @@ -11,8 +11,6 @@ use Drupal\Component\Gettext\PoItem; use Drupal\Component\Gettext\PoReaderInterface; use Drupal\Component\Gettext\PoWriterInterface; -use Drupal\locale\SourceString; -use Drupal\locale\TranslationString; /** * Gettext PO writer working with the locale module database. diff --git a/core/modules/locale/src/StreamWrapper/TranslationsStream.php b/core/modules/locale/src/StreamWrapper/TranslationsStream.php index eaa712236..7866ad9d7 100644 --- a/core/modules/locale/src/StreamWrapper/TranslationsStream.php +++ b/core/modules/locale/src/StreamWrapper/TranslationsStream.php @@ -8,7 +8,6 @@ namespace Drupal\locale\StreamWrapper; use Drupal\Core\Annotation\StreamWrapper; -use Drupal\Core\Annotation\Translation; use Drupal\Core\StreamWrapper\LocalStream; use Drupal\Core\StreamWrapper\StreamWrapperInterface; diff --git a/core/modules/locale/src/StringBase.php b/core/modules/locale/src/StringBase.php index d0340ef01..8113c1ff0 100644 --- a/core/modules/locale/src/StringBase.php +++ b/core/modules/locale/src/StringBase.php @@ -7,8 +7,6 @@ namespace Drupal\locale; -use Drupal\Component\Utility\SafeMarkup; - /** * Defines the locale string base class. * diff --git a/core/modules/locale/src/Tests/LocaleConfigTranslationImportTest.php b/core/modules/locale/src/Tests/LocaleConfigTranslationImportTest.php index 6605b3b57..b0450e55b 100644 --- a/core/modules/locale/src/Tests/LocaleConfigTranslationImportTest.php +++ b/core/modules/locale/src/Tests/LocaleConfigTranslationImportTest.php @@ -10,7 +10,6 @@ use Drupal\locale\Locale; use Drupal\simpletest\WebTestBase; use Drupal\language\Entity\ConfigurableLanguage; -use Drupal\Core\Url; /** * Tests translation update's effects on configuration translations. diff --git a/core/modules/locale/src/Tests/LocaleConfigTranslationTest.php b/core/modules/locale/src/Tests/LocaleConfigTranslationTest.php index 588e779f2..e03f061b5 100644 --- a/core/modules/locale/src/Tests/LocaleConfigTranslationTest.php +++ b/core/modules/locale/src/Tests/LocaleConfigTranslationTest.php @@ -7,7 +7,6 @@ namespace Drupal\locale\Tests; -use Drupal\Component\Utility\SafeMarkup; use Drupal\simpletest\WebTestBase; use Drupal\core\language\languageInterface; diff --git a/core/modules/locale/src/Tests/LocaleUpdateBase.php b/core/modules/locale/src/Tests/LocaleUpdateBase.php index 5b03e9539..41922bbc4 100644 --- a/core/modules/locale/src/Tests/LocaleUpdateBase.php +++ b/core/modules/locale/src/Tests/LocaleUpdateBase.php @@ -8,7 +8,6 @@ namespace Drupal\locale\Tests; use Drupal\Core\StreamWrapper\PublicStream; -use Drupal\Core\Url; use Drupal\simpletest\WebTestBase; use Drupal\Component\Utility\SafeMarkup; diff --git a/core/modules/menu_link_content/src/Tests/LinksTest.php b/core/modules/menu_link_content/src/Tests/LinksTest.php index 81d48a456..29a8d9715 100644 --- a/core/modules/menu_link_content/src/Tests/LinksTest.php +++ b/core/modules/menu_link_content/src/Tests/LinksTest.php @@ -8,7 +8,6 @@ namespace Drupal\menu_link_content\Tests; use Drupal\Component\Utility\SafeMarkup; -use Drupal\locale\TranslationString; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/menu_ui/menu_ui.admin.js b/core/modules/menu_ui/menu_ui.admin.js index 5120d6e3e..2bc80dd2d 100644 --- a/core/modules/menu_ui/menu_ui.admin.js +++ b/core/modules/menu_ui/menu_ui.admin.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * diff --git a/core/modules/menu_ui/menu_ui.js b/core/modules/menu_ui/menu_ui.js index 935d1a303..113b90a7d 100644 --- a/core/modules/menu_ui/menu_ui.js +++ b/core/modules/menu_ui/menu_ui.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Set a summary on the menu link form. diff --git a/core/modules/menu_ui/menu_ui.module b/core/modules/menu_ui/menu_ui.module index 6f31eb585..3baf11719 100644 --- a/core/modules/menu_ui/menu_ui.module +++ b/core/modules/menu_ui/menu_ui.module @@ -20,7 +20,6 @@ use Drupal\Core\Routing\RouteMatchInterface; use Drupal\menu_link_content\Entity\MenuLinkContent; use Drupal\node\NodeTypeInterface; use Drupal\system\Entity\Menu; -use Symfony\Component\HttpFoundation\JsonResponse; use Drupal\node\NodeInterface; /** diff --git a/core/modules/menu_ui/src/MenuForm.php b/core/modules/menu_ui/src/MenuForm.php index efd145171..0932cdb05 100644 --- a/core/modules/menu_ui/src/MenuForm.php +++ b/core/modules/menu_ui/src/MenuForm.php @@ -19,7 +19,6 @@ use Drupal\Core\Menu\MenuLinkTreeInterface; use Drupal\Core\Menu\MenuTreeParameters; use Drupal\Core\Render\Element; -use Drupal\Core\Routing\UrlGeneratorTrait; use Drupal\Core\Url; use Drupal\Core\Utility\LinkGeneratorInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/menu_ui/src/MenuListBuilder.php b/core/modules/menu_ui/src/MenuListBuilder.php index be9fc1ec7..406a60f02 100644 --- a/core/modules/menu_ui/src/MenuListBuilder.php +++ b/core/modules/menu_ui/src/MenuListBuilder.php @@ -7,7 +7,6 @@ namespace Drupal\menu_ui; -use Drupal\Component\Utility\Xss; use Drupal\Core\Config\Entity\ConfigEntityListBuilder; use Drupal\Core\Entity\EntityInterface; diff --git a/core/modules/menu_ui/src/Tests/MenuLanguageTest.php b/core/modules/menu_ui/src/Tests/MenuLanguageTest.php index c35c221e2..b204e47c9 100644 --- a/core/modules/menu_ui/src/Tests/MenuLanguageTest.php +++ b/core/modules/menu_ui/src/Tests/MenuLanguageTest.php @@ -12,7 +12,6 @@ use Drupal\Component\Utility\Unicode; use Drupal\language\Entity\ConfigurableLanguage; use Drupal\language\Entity\ContentLanguageSettings; -use Drupal\system\Entity\Menu; /** * Create menu and menu links in non-English language, and edit language diff --git a/core/modules/menu_ui/src/Tests/MenuTest.php b/core/modules/menu_ui/src/Tests/MenuTest.php index 326db813c..f8c26c903 100644 --- a/core/modules/menu_ui/src/Tests/MenuTest.php +++ b/core/modules/menu_ui/src/Tests/MenuTest.php @@ -10,7 +10,6 @@ use Drupal\block\Entity\Block; use Drupal\Component\Serialization\Json; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Cache\Cache; use Drupal\Core\Menu\MenuLinkInterface; use Drupal\Core\Url; use Drupal\menu_link_content\Entity\MenuLinkContent; diff --git a/core/modules/migrate/config/schema/migrate.data_types.schema.yml b/core/modules/migrate/config/schema/migrate.data_types.schema.yml index 7521ee129..60dd5193f 100644 --- a/core/modules/migrate/config/schema/migrate.data_types.schema.yml +++ b/core/modules/migrate/config/schema/migrate.data_types.schema.yml @@ -10,6 +10,13 @@ migrate_plugin: migrate_destination: type: migrate_plugin label: 'Destination' + mapping: + overwrite_properties: + type: sequence + label: 'Properties to overwrite' + sequence: + type: string + label: 'Property' migrate_source: type: migrate_plugin diff --git a/core/modules/migrate/src/Annotation/MigrateSource.php b/core/modules/migrate/src/Annotation/MigrateSource.php index 85a69bb94..95b53e3e8 100644 --- a/core/modules/migrate/src/Annotation/MigrateSource.php +++ b/core/modules/migrate/src/Annotation/MigrateSource.php @@ -45,4 +45,30 @@ class MigrateSource extends Plugin { */ public $requirements_met = TRUE; + /** + * Identifies the system providing the data the source plugin will read. + * + * This can be any type, and the source plugin itself determines how the value + * is used. For example, Migrate Drupal's source plugins expect + * source_provider to be the name of a module that must be installed and + * enabled in the source database. + * + * @see \Drupal\migrate_drupal\Plugin\migrate\source\DrupalSqlBase::checkRequirements + * + * @var mixed + */ + public $source_provider; + + /** + * Specifies the minimum version of the source provider. + * + * This can be any type, and the source plugin itself determines how it is + * used. For example, Migrate Drupal's source plugins expect this to be an + * integer representing the minimum installed database schema version of the + * module specified by source_provider. + * + * @var mixed + */ + public $minimum_version; + } diff --git a/core/modules/migrate/src/Entity/Migration.php b/core/modules/migrate/src/Entity/Migration.php index 0d7e3c81f..094713d1d 100644 --- a/core/modules/migrate/src/Entity/Migration.php +++ b/core/modules/migrate/src/Entity/Migration.php @@ -585,8 +585,11 @@ public function calculateDependencies() { parent::calculateDependencies(); $this->calculatePluginDependencies($this->getSourcePlugin()); $this->calculatePluginDependencies($this->getDestinationPlugin()); - // Add dependencies on required migration dependencies. - foreach ($this->getMigrationDependencies()['required'] as $dependency) { + + // Add hard dependencies on required migrations. + $dependencies = $this->getEntityManager()->getStorage($this->entityTypeId) + ->getVariantIds($this->getMigrationDependencies()['required']); + foreach ($dependencies as $dependency) { $this->addDependency('config', $this->getEntityType()->getConfigPrefix() . '.' . $dependency); } diff --git a/core/modules/migrate/src/MigrationStorage.php b/core/modules/migrate/src/MigrationStorage.php index 93c371bd3..e43496e36 100644 --- a/core/modules/migrate/src/MigrationStorage.php +++ b/core/modules/migrate/src/MigrationStorage.php @@ -92,7 +92,7 @@ public function loadMultiple(array $ids = NULL) { * @return string[] * The expanded list of IDs. */ - protected function getVariantIds(array $ids) { + public function getVariantIds(array $ids) { // Re-index the array numerically, since we need to limit the loop by size. $ids = array_values($ids); diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php index 69c9e660a..f80034ce2 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php @@ -109,6 +109,17 @@ public function getIds() { * The row object to update from. */ protected function updateEntity(EntityInterface $entity, Row $row) { + // If the migration has specified a list of properties to be overwritten, + // clone the row with an empty set of destination values, and re-add only + // the specified properties. + if (isset($this->configuration['overwrite_properties'])) { + $clone = $row->cloneWithoutDestination(); + foreach ($this->configuration['overwrite_properties'] as $property) { + $clone->setDestinationProperty($property, $row->getDestinationProperty($property)); + } + $row = $clone; + } + foreach ($row->getDestination() as $field_name => $values) { $field = $entity->$field_name; if ($field instanceof TypedDataInterface) { diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php index 77297e8a0..c6cd7e467 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityFieldInstance.php @@ -7,8 +7,6 @@ namespace Drupal\migrate\Plugin\migrate\destination; -use Drupal\migrate\Row; - /** * @MigrateDestination( * id = "entity:field_config" diff --git a/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php b/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php index 8aaefef86..81498c39b 100644 --- a/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php +++ b/core/modules/migrate/src/Plugin/migrate/destination/EntityRevision.php @@ -32,18 +32,29 @@ protected static function getEntityTypeId($plugin_id) { * * @param \Drupal\migrate\Row $row * The row object. + * @param array $old_destination_id_values + * The old destination ids. * * @return \Drupal\Core\Entity\EntityInterface|false * The entity or false if it can not be created. */ protected function getEntity(Row $row, array $old_destination_id_values) { - $revision_id = $old_destination_id_values ? reset($old_destination_id_values) : $row->getDestinationProperty($this->getKey('revision')); + $revision_id = $old_destination_id_values ? + reset($old_destination_id_values) : + $row->getDestinationProperty($this->getKey('revision')); if (!empty($revision_id) && ($entity = $this->storage->loadRevision($revision_id))) { $entity->setNewRevision(FALSE); } else { $entity_id = $row->getDestinationProperty($this->getKey('id')); $entity = $this->storage->load($entity_id); + + // If we fail to load the original entity something is wrong and we need + // to return immediately. + if (!$entity) { + return FALSE; + } + $entity->enforceIsNew(FALSE); $entity->setNewRevision(TRUE); } diff --git a/core/modules/migrate/src/Plugin/migrate/source/SourcePluginBase.php b/core/modules/migrate/src/Plugin/migrate/source/SourcePluginBase.php index bc7a8544a..a7e3e89b9 100644 --- a/core/modules/migrate/src/Plugin/migrate/source/SourcePluginBase.php +++ b/core/modules/migrate/src/Plugin/migrate/source/SourcePluginBase.php @@ -10,7 +10,6 @@ use Drupal\Core\Plugin\PluginBase; use Drupal\migrate\Entity\MigrationInterface; use Drupal\migrate\MigrateException; -use Drupal\migrate\MigrateExecutableInterface; use Drupal\migrate\MigrateSkipRowException; use Drupal\migrate\Plugin\MigrateIdMapInterface; use Drupal\migrate\Plugin\MigrateSourceInterface; diff --git a/core/modules/migrate/src/Row.php b/core/modules/migrate/src/Row.php index 877497695..e055c1d4c 100644 --- a/core/modules/migrate/src/Row.php +++ b/core/modules/migrate/src/Row.php @@ -187,6 +187,15 @@ public function freezeSource() { return $this; } + /** + * Clones the row with an empty set of destination values. + * + * @return static + */ + public function cloneWithoutDestination() { + return (new static($this->getSource(), $this->sourceIds, $this->isStub()))->freezeSource(); + } + /** * Tests if destination property exists. * diff --git a/core/modules/migrate/src/Tests/MigrateTestBase.php b/core/modules/migrate/src/Tests/MigrateTestBase.php index 248a059d2..139bc2ff2 100644 --- a/core/modules/migrate/src/Tests/MigrateTestBase.php +++ b/core/modules/migrate/src/Tests/MigrateTestBase.php @@ -9,9 +9,9 @@ use Drupal\Core\Database\Database; use Drupal\migrate\Entity\Migration; -use Drupal\migrate\Entity\MigrationInterface; use Drupal\migrate\MigrateExecutable; use Drupal\migrate\MigrateMessageInterface; +use Drupal\migrate\Plugin\MigrateIdMapInterface; use Drupal\migrate\Row; use Drupal\simpletest\KernelTestBase; @@ -199,4 +199,26 @@ public function stopCollectingMessages() { $this->collectMessages = FALSE; } + /** + * Records a failure in the map table of a specific migration in order to + * test scenarios which require a failed row. + * + * @param string|\Drupal\migrate\Entity\MigrationInterface $migration + * The migration entity, or its ID. + * @param array $row + * The raw source row which "failed". + * @param int $status + * (optional) The failure status. Should be one of the + * MigrateIdMapInterface::STATUS_* constants. + */ + protected function mockFailure($migration, array $row, $status = MigrateIdMapInterface::STATUS_FAILED) { + if (is_string($migration)) { + $migration = Migration::load($migration); + } + /** @var \Drupal\migrate\Entity\MigrationInterface $migration */ + $destination = array_map(function() { return NULL; }, $migration->getDestinationPlugin()->getIds()); + $row = new Row($row, $migration->getSourcePlugin()->getIds()); + $migration->getIdMap()->saveIdMapping($row, $destination, $status); + } + } diff --git a/core/modules/migrate/tests/src/Kernel/Entity/MigrationTest.php b/core/modules/migrate/tests/src/Kernel/Entity/MigrationTest.php new file mode 100644 index 000000000..fd37ac44c --- /dev/null +++ b/core/modules/migrate/tests/src/Kernel/Entity/MigrationTest.php @@ -0,0 +1,76 @@ + 'd6_node', + 'd6_node__page' => 'd6_node', + 'd6_variables' => 'd6_variables', + ]; + + foreach ($fixture_migrations as $id => $template) { + $values = [ + 'id' => $id, + 'template' => $template, + 'source' => [ + 'plugin' => 'empty', + ], + 'destination' => [ + 'plugin' => 'null', + ], + 'migration_tags' => [] + ]; + Migration::create($values)->save(); + } + + $values = [ + 'migration_dependencies' => [ + 'required' => [ + 'd6_node:*', + 'd6_variables' + ] + ], + 'source' => [ + 'plugin' => 'empty', + ], + 'destination' => [ + 'plugin' => 'null', + ], + ]; + + $migration = new Migration($values, 'migration'); + $expected = [ + 'migrate.migration.d6_node__article', + 'migrate.migration.d6_node__page', + 'migrate.migration.d6_variables' + ]; + $migration->calculateDependencies(); + $this->assertEquals($expected, $migration->getDependencies()['config']); + } + +} diff --git a/core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php b/core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php new file mode 100644 index 000000000..d5f71a072 --- /dev/null +++ b/core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php @@ -0,0 +1,219 @@ +migration = $this->prophesize('\Drupal\migrate\Entity\MigrationInterface'); + $this->storage = $this->prophesize('\Drupal\Core\Entity\EntityStorageInterface'); + $this->entityManager = $this->prophesize('\Drupal\Core\Entity\EntityManagerInterface'); + } + + /** + * Test that passed old destination values are used by default. + * + * @covers ::getEntity + */ + public function testGetEntityDestinationValues() { + $destination = $this->getEntityRevisionDestination([]); + // Return a dummy because we don't care what gets called. + $entity = $this->prophesize('\Drupal\Core\Entity\EntityInterface') + ->willImplement('\Drupal\Core\Entity\RevisionableInterface'); + // Assert that the first ID from the destination values is used to load the + // entity. + $this->storage->loadRevision(12) + ->shouldBeCalled() + ->willReturn($entity->reveal()); + $row = new Row([], []); + $this->assertEquals($entity->reveal(), $destination->getEntity($row, [12, 13])); + } + + /** + * Test that revision updates update. + * + * @covers ::getEntity + */ + public function testGetEntityUpdateRevision() { + $destination = $this->getEntityRevisionDestination([]); + $entity = $this->prophesize('\Drupal\Core\Entity\EntityInterface') + ->willImplement('\Drupal\Core\Entity\RevisionableInterface'); + + $entity_type = $this->prophesize('\Drupal\Core\Entity\EntityTypeInterface'); + $entity_type->getKey('id')->willReturn('nid'); + $entity_type->getKey('revision')->willReturn('vid'); + $this->storage->getEntityType()->willReturn($entity_type->reveal()); + + // Assert we load the correct revision. + $this->storage->loadRevision(2) + ->shouldBeCalled() + ->willReturn($entity->reveal()); + // Make sure its set as an update and not the default revision. + $entity->setNewRevision(FALSE)->shouldBeCalled(); + $entity->isDefaultRevision(FALSE)->shouldBeCalled(); + + $row = new Row(['nid' => 1, 'vid' => 2], ['nid' => 1, 'vid' => 2]); + $row->setDestinationProperty('vid', 2); + $this->assertEquals($entity->reveal(), $destination->getEntity($row, [])); + } + + /** + * Test that new revisions are flagged to be written as new. + * + * @covers ::getEntity + */ + public function testGetEntityNewRevision() { + $destination = $this->getEntityRevisionDestination([]); + $entity = $this->prophesize('\Drupal\Core\Entity\EntityInterface') + ->willImplement('\Drupal\Core\Entity\RevisionableInterface'); + + $entity_type = $this->prophesize('\Drupal\Core\Entity\EntityTypeInterface'); + $entity_type->getKey('id')->willReturn('nid'); + $entity_type->getKey('revision')->willReturn('vid'); + $this->storage->getEntityType()->willReturn($entity_type->reveal()); + + // Enforce is new should be disabled. + $entity->enforceIsNew(FALSE)->shouldBeCalled(); + // And toggle this as new revision but not the default revision. + $entity->setNewRevision(TRUE)->shouldBeCalled(); + $entity->isDefaultRevision(FALSE)->shouldBeCalled(); + + // Assert we load the correct revision. + $this->storage->load(1) + ->shouldBeCalled() + ->willReturn($entity->reveal()); + + $row = new Row(['nid' => 1, 'vid' => 2], ['nid' => 1, 'vid' => 2]); + $row->setDestinationProperty('nid', 1); + $this->assertEquals($entity->reveal(), $destination->getEntity($row, [])); + } + + /** + * Test entity load failure. + * + * @covers ::getEntity + */ + public function testGetEntityLoadFailure() { + $destination = $this->getEntityRevisionDestination([]); + + $entity_type = $this->prophesize('\Drupal\Core\Entity\EntityTypeInterface'); + $entity_type->getKey('id')->willReturn('nid'); + $entity_type->getKey('revision')->willReturn('vid'); + $this->storage->getEntityType()->willReturn($entity_type->reveal()); + + // Return a failed load and make sure we don't fail and we return FALSE. + $this->storage->load(1) + ->shouldBeCalled() + ->willReturn(FALSE); + + $row = new Row(['nid' => 1, 'vid' => 2], ['nid' => 1, 'vid' => 2]); + $row->setDestinationProperty('nid', 1); + $this->assertFalse($destination->getEntity($row, [])); + } + + /** + * Test entity revision save. + * + * @covers ::save + */ + public function testSave() { + $entity = $this->prophesize('\Drupal\Core\Entity\ContentEntityInterface'); + $entity->save() + ->shouldBeCalled(); + $entity->getRevisionId() + ->shouldBeCalled() + ->willReturn(1234); + $destination = $this->getEntityRevisionDestination(); + $this->assertEquals([1234], $destination->save($entity->reveal(), [])); + } + + + /** + * Helper method to create an entity revision destination with mock services. + * + * @see \Drupal\Tests\migrate\Unit\Destination\EntityRevision + * + * @param $configuration + * Configuration for the destination. + * @param string $plugin_id + * The plugin id. + * @param array $plugin_definition + * The plugin definition. + * + * @return \Drupal\Tests\migrate\Unit\destination\EntityRevision + * Mocked destination. + */ + protected function getEntityRevisionDestination(array $configuration = [], $plugin_id = 'entity_revision', array $plugin_definition = []) { + return new EntityRevision($configuration, $plugin_id, $plugin_definition, + $this->migration->reveal(), + $this->storage->reveal(), + [], + $this->entityManager->reveal()); + } + +} + +/** + * Mock that exposes from internal methods for testing. + */ +class EntityRevision extends RealEntityRevision { + + /** + * Allow public access for testing. + */ + public function getEntity(Row $row, array $old_destination_id_values) { + return parent::getEntity($row, $old_destination_id_values); + } + + /** + * Allow public access for testing. + */ + public function save(ContentEntityInterface $entity, array $old_destination_id_values = array()) { + return parent::save($entity, $old_destination_id_values); + } + + /** + * Don't test method from base class. + * + * This method is from the parent and we aren't concerned with the inner + * workings of its implementation which would trickle into mock assertions. An + * empty implementation avoids this. + */ + protected function updateEntity(EntityInterface $entity, Row $row) {} + +} diff --git a/core/modules/migrate/tests/src/Unit/process/GetTest.php b/core/modules/migrate/tests/src/Unit/process/GetTest.php index bdcf27c43..dc8ea70a8 100644 --- a/core/modules/migrate/tests/src/Unit/process/GetTest.php +++ b/core/modules/migrate/tests/src/Unit/process/GetTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\migrate\Unit\process; use Drupal\migrate\Plugin\migrate\process\TestGet; -use Drupal\migrate\Row; /** * Tests the get process plugin. diff --git a/core/modules/migrate/tests/src/Unit/process/IteratorTest.php b/core/modules/migrate/tests/src/Unit/process/IteratorTest.php index 69e707d4c..fe34095de 100644 --- a/core/modules/migrate/tests/src/Unit/process/IteratorTest.php +++ b/core/modules/migrate/tests/src/Unit/process/IteratorTest.php @@ -9,7 +9,6 @@ use Drupal\migrate\MigrateExecutable; use Drupal\migrate\Plugin\migrate\process\Get; use Drupal\migrate\Plugin\migrate\process\Iterator; -use Drupal\migrate\Plugin\migrate\process\StaticMap; use Drupal\migrate\Row; use Drupal\Tests\migrate\Unit\MigrateTestCase; diff --git a/core/modules/migrate_drupal/src/Tests/d6/EntityContentBaseTest.php b/core/modules/migrate_drupal/src/Tests/d6/EntityContentBaseTest.php new file mode 100644 index 000000000..1015aa16a --- /dev/null +++ b/core/modules/migrate_drupal/src/Tests/d6/EntityContentBaseTest.php @@ -0,0 +1,93 @@ + 'signature', + 'entity_type' => 'user', + 'type' => 'text_long', + ])->save(); + + FieldConfig::create([ + 'field_name' => 'signature', + 'entity_type' => 'user', + 'bundle' => 'user', + ])->save(); + + User::create([ + 'uid' => 2, + 'name' => 'Ford Prefect', + 'mail' => 'ford.prefect@localhost', + 'signature' => array( + array( + 'value' => 'Bring a towel.', + 'format' => 'filtered_html', + ), + ), + 'init' => 'proto@zo.an', + ])->save(); + + $this->executeMigrations(['d6_filter_format', 'd6_user_role']); + } + + /** + * Tests overwriting all mapped properties in the destination entity (default + * behavior). + */ + public function testOverwriteAllMappedProperties() { + $this->executeMigration('d6_user'); + /** @var \Drupal\user\UserInterface $account */ + $account = User::load(2); + $this->assertIdentical('john.doe', $account->label()); + $this->assertIdentical('john.doe@example.com', $account->getEmail()); + $this->assertIdentical('doe@example.com', $account->getInitialEmail()); + } + + /** + * Tests overwriting selected properties in the destination entity, specified + * in the destination configuration. + */ + public function testOverwriteProperties() { + // Execute the migration in migrate_overwrite_test, which documents how + // property overwrites work. + $this->executeMigration('users'); + + /** @var \Drupal\user\UserInterface $account */ + $account = User::load(2); + $this->assertIdentical('john.doe', $account->label()); + $this->assertIdentical('john.doe@example.com', $account->getEmail()); + $this->assertIdentical('The answer is 42.', $account->signature->value); + // This value is not overwritten because it's not listed in + // overwrite_properties. + $this->assertIdentical('proto@zo.an', $account->getInitialEmail()); + } + +} diff --git a/core/modules/migrate_drupal/tests/fixtures/drupal6.php b/core/modules/migrate_drupal/tests/fixtures/drupal6.php index 965f69e00..c9b07e502 100644 --- a/core/modules/migrate_drupal/tests/fixtures/drupal6.php +++ b/core/modules/migrate_drupal/tests/fixtures/drupal6.php @@ -102,6 +102,20 @@ 'parameters' => '', 'description' => 'Unpublish comment', )) +->values(array( + 'aid' => 'imagecache_flush_action', + 'type' => 'node', + 'callback' => 'imagecache_flush_action', + 'parameters' => '', + 'description' => "ImageCache: Flush ALL presets for this node's filefield images", +)) +->values(array( + 'aid' => 'imagecache_generate_all_action', + 'type' => 'node', + 'callback' => 'imagecache_generate_all_action', + 'parameters' => '', + 'description' => "ImageCache: Generate ALL presets for this node's filefield images", +)) ->values(array( 'aid' => 'node_make_sticky_action', 'type' => 'node', @@ -854,6 +868,21 @@ 'title' => '', 'cache' => '5', )) +->values(array( + 'bid' => '21', + 'module' => 'locale', + 'delta' => '0', + 'theme' => 'garland', + 'status' => '0', + 'weight' => '0', + 'region' => '', + 'custom' => '0', + 'throttle' => '0', + 'visibility' => '0', + 'pages' => '', + 'title' => '', + 'cache' => '-1', +)) ->execute(); $connection->schema()->createTable('blocks_roles', array( @@ -1641,6 +1670,14 @@ 'primary key' => array( 'cid', ), + 'indexes' => array( + 'pid' => array( + 'pid', + ), + 'comment_uid' => array( + 'uid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -1932,6 +1969,11 @@ 'vid', 'delta', ), + 'indexes' => array( + 'nid' => array( + 'nid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -1987,6 +2029,11 @@ 'primary key' => array( 'vid', ), + 'indexes' => array( + 'nid' => array( + 'nid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -2021,6 +2068,12 @@ 'field_test_value' => NULL, 'field_test_format' => NULL, )) +->values(array( + 'vid' => '12', + 'nid' => '9', + 'field_test_value' => 'text for default value', + 'field_test_format' => '1', +)) ->execute(); $connection->schema()->createTable('content_field_test_text_single_checkbox', array( @@ -2048,6 +2101,11 @@ 'primary key' => array( 'vid', ), + 'indexes' => array( + 'nid' => array( + 'nid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -2077,6 +2135,11 @@ 'nid' => '2', 'field_test_text_single_checkbox_value' => NULL, )) +->values(array( + 'vid' => '12', + 'nid' => '9', + 'field_test_text_single_checkbox_value' => '0', +)) ->execute(); $connection->schema()->createTable('content_field_test_two', array( @@ -2112,6 +2175,11 @@ 'vid', 'delta', ), + 'indexes' => array( + 'nid' => array( + 'nid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -2146,6 +2214,12 @@ 'delta' => '0', 'field_test_two_value' => NULL, )) +->values(array( + 'vid' => '12', + 'nid' => '9', + 'delta' => '0', + 'field_test_two_value' => NULL, +)) ->values(array( 'vid' => '1', 'nid' => '1', @@ -2285,7 +2359,7 @@ 'locked' => array( 'type' => 'int', 'not null' => TRUE, - 'size' => 'normal', + 'size' => 'tiny', 'default' => '0', ), ), @@ -2524,6 +2598,18 @@ 'active' => '1', 'locked' => '0', )) +->values(array( + 'field_name' => 'field_test_text_single_checkbox2', + 'type' => 'text', + 'global_settings' => "a:4:{s:15:\"text_processing\";s:1:\"0\";s:10:\"max_length\";s:0:\"\";s:14:\"allowed_values\";s:10:\"Off\r\nHello\";s:18:\"allowed_values_php\";s:0:\"\";}", + 'required' => '0', + 'multiple' => '0', + 'db_storage' => '1', + 'module' => 'text', + 'db_columns' => 'a:1:{s:5:"value";a:5:{s:4:"type";s:4:"text";s:4:"size";s:3:"big";s:8:"not null";b:0;s:8:"sortable";b:1;s:5:"views";b:1;}}', + 'active' => '1', + 'locked' => '0', +)) ->values(array( 'field_name' => 'field_test_three', 'type' => 'number_decimal', @@ -2870,6 +2956,18 @@ 'widget_module' => 'text', 'widget_active' => '1', )) +->values(array( + 'field_name' => 'field_test_text_single_checkbox2', + 'type_name' => 'story', + 'weight' => '19', + 'label' => 'Text Single Checkbox Field 2', + 'widget_type' => 'optionwidgets_onoff', + 'widget_settings' => 'a:2:{s:13:"default_value";a:1:{i:0;a:1:{s:5:"value";N;}}s:17:"default_value_php";N;}', + 'display_settings' => 'a:5:{s:5:"label";a:2:{s:6:"format";s:5:"above";s:7:"exclude";i:0;}i:5;a:2:{s:6:"format";s:7:"default";s:7:"exclude";i:0;}s:6:"teaser";a:2:{s:6:"format";s:7:"default";s:7:"exclude";i:0;}s:4:"full";a:2:{s:6:"format";s:7:"default";s:7:"exclude";i:0;}i:4;a:2:{s:6:"format";s:7:"default";s:7:"exclude";i:0;}}', + 'description' => 'Checkbox that uses keys only and no label.', + 'widget_module' => 'optionwidgets', + 'widget_active' => '1', +)) ->values(array( 'field_name' => 'field_test_three', 'type_name' => 'story', @@ -3085,10 +3183,20 @@ 'not null' => FALSE, 'size' => 'normal', ), + 'field_test_text_single_checkbox2_value' => array( + 'type' => 'text', + 'not null' => FALSE, + 'size' => 'big', + ), ), 'primary key' => array( 'vid', ), + 'indexes' => array( + 'nid' => array( + 'nid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -3120,6 +3228,7 @@ 'field_test_imagefield_fid', 'field_test_imagefield_list', 'field_test_imagefield_data', + 'field_test_text_single_checkbox2_value', )) ->values(array( 'nid' => '1', @@ -3148,6 +3257,7 @@ 'field_test_imagefield_fid' => NULL, 'field_test_imagefield_list' => NULL, 'field_test_imagefield_data' => NULL, + 'field_test_text_single_checkbox2_value' => 'Hello', )) ->values(array( 'nid' => '1', @@ -3176,6 +3286,7 @@ 'field_test_imagefield_fid' => NULL, 'field_test_imagefield_list' => NULL, 'field_test_imagefield_data' => NULL, + 'field_test_text_single_checkbox2_value' => NULL, )) ->values(array( 'nid' => '2', @@ -3204,6 +3315,7 @@ 'field_test_imagefield_fid' => NULL, 'field_test_imagefield_list' => NULL, 'field_test_imagefield_data' => NULL, + 'field_test_text_single_checkbox2_value' => NULL, )) ->values(array( 'nid' => '2', @@ -3232,6 +3344,36 @@ 'field_test_imagefield_fid' => NULL, 'field_test_imagefield_list' => NULL, 'field_test_imagefield_data' => NULL, + 'field_test_text_single_checkbox2_value' => NULL, +)) +->values(array( + 'nid' => '9', + 'vid' => '12', + 'uid' => '0', + 'field_test_three_value' => '101.00', + 'field_test_identical1_value' => NULL, + 'field_test_identical2_value' => NULL, + 'field_test_link_url' => 'http://www.example.com/buy-one-upon-a-time', + 'field_test_link_title' => 'Buy it now', + 'field_test_link_attributes' => 'a:1:{s:6:"target";s:6:"_blank";}', + 'field_test_date_value' => NULL, + 'field_test_datestamp_value' => NULL, + 'field_test_datetime_value' => NULL, + 'field_test_email_email' => NULL, + 'field_test_filefield_fid' => NULL, + 'field_test_filefield_list' => NULL, + 'field_test_filefield_data' => NULL, + 'field_test_four_value' => '101', + 'field_test_integer_selectlist_value' => NULL, + 'field_test_float_single_checkbox_value' => '3', + 'field_test_decimal_radio_buttons_value' => NULL, + 'field_test_phone_value' => NULL, + 'field_test_exclude_unset_value' => 'text for default value', + 'field_test_exclude_unset_format' => '1', + 'field_test_imagefield_fid' => NULL, + 'field_test_imagefield_list' => NULL, + 'field_test_imagefield_data' => NULL, + 'field_test_text_single_checkbox2_value' => NULL, )) ->execute(); @@ -7950,167 +8092,7406 @@ )) ->execute(); -$connection->schema()->createTable('menu_custom', array( +$connection->schema()->createTable('languages', array( 'fields' => array( - 'menu_name' => array( + 'language' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '32', + 'length' => '12', 'default' => '', ), - 'title' => array( + 'name' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '255', + 'length' => '64', 'default' => '', ), - 'description' => array( - 'type' => 'text', - 'not null' => FALSE, - 'size' => 'normal', - ), - ), - 'primary key' => array( - 'menu_name', - ), - 'mysql_character_set' => 'utf8', -)); - -$connection->insert('menu_custom') -->fields(array( - 'menu_name', - 'title', - 'description', -)) -->values(array( - 'menu_name' => 'navigation', - 'title' => 'Navigation', - 'description' => 'The navigation menu is provided by Drupal and is the main interactive menu for any site. It is usually the only menu that contains personalized links for authenticated users, and is often not even visible to anonymous users.', -)) -->values(array( - 'menu_name' => 'primary-links', - 'title' => 'Primary links', - 'description' => 'Primary links are often used at the theme layer to show the major sections of a site. A typical representation for primary links would be tabs along the top.', -)) -->values(array( - 'menu_name' => 'secondary-links', - 'title' => 'Secondary links', - 'description' => 'Secondary links are often used for pages like legal notices, contact details, and other secondary navigation items that play a lesser role than primary links', -)) -->execute(); - -$connection->schema()->createTable('menu_links', array( - 'fields' => array( - 'menu_name' => array( + 'native' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '32', + 'length' => '64', 'default' => '', ), - 'mlid' => array( - 'type' => 'serial', + 'direction' => array( + 'type' => 'int', 'not null' => TRUE, 'size' => 'normal', - 'unsigned' => TRUE, + 'default' => '0', ), - 'plid' => array( + 'enabled' => array( 'type' => 'int', 'not null' => TRUE, 'size' => 'normal', 'default' => '0', - 'unsigned' => TRUE, ), - 'link_path' => array( - 'type' => 'varchar', + 'plurals' => array( + 'type' => 'int', 'not null' => TRUE, - 'length' => '255', - 'default' => '', + 'size' => 'normal', + 'default' => '0', ), - 'router_path' => array( + 'formula' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '255', + 'length' => '128', 'default' => '', ), - 'link_title' => array( + 'domain' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '255', + 'length' => '128', 'default' => '', ), - 'options' => array( - 'type' => 'text', - 'not null' => FALSE, - 'size' => 'normal', - ), - 'module' => array( + 'prefix' => array( 'type' => 'varchar', 'not null' => TRUE, - 'length' => '255', - 'default' => 'system', + 'length' => '128', + 'default' => '', ), - 'hidden' => array( + 'weight' => array( 'type' => 'int', 'not null' => TRUE, 'size' => 'normal', 'default' => '0', ), - 'external' => array( - 'type' => 'int', + 'javascript' => array( + 'type' => 'varchar', 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', + 'length' => '32', + 'default' => '', ), - 'has_children' => array( - 'type' => 'int', - 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', + ), + 'primary key' => array( + 'language', + ), + 'indexes' => array( + 'list' => array( + 'weight', + 'name', ), - 'expanded' => array( - 'type' => 'int', + ), + 'mysql_character_set' => 'utf8', +)); + +$connection->insert('languages') +->fields(array( + 'language', + 'name', + 'native', + 'direction', + 'enabled', + 'plurals', + 'formula', + 'domain', + 'prefix', + 'weight', + 'javascript', +)) +->values(array( + 'language' => 'en', + 'name' => 'English', + 'native' => 'English', + 'direction' => '0', + 'enabled' => '1', + 'plurals' => '0', + 'formula' => '', + 'domain' => '', + 'prefix' => '', + 'weight' => '0', + 'javascript' => '', +)) +->values(array( + 'language' => 'fr', + 'name' => 'French', + 'native' => 'Français', + 'direction' => '0', + 'enabled' => '1', + 'plurals' => '2', + 'formula' => '($n>1)', + 'domain' => '', + 'prefix' => 'fr', + 'weight' => '0', + 'javascript' => '', +)) +->execute(); + +$connection->schema()->createTable('locales_source', array( + 'fields' => array( + 'lid' => array( + 'type' => 'serial', 'not null' => TRUE, 'size' => 'normal', - 'default' => '0', ), - 'weight' => array( - 'type' => 'int', + 'location' => array( + 'type' => 'varchar', 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', + 'length' => '255', + 'default' => '', ), - 'depth' => array( - 'type' => 'int', + 'textgroup' => array( + 'type' => 'varchar', 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', + 'length' => '255', + 'default' => 'default', ), - 'customized' => array( - 'type' => 'int', + 'source' => array( + 'type' => 'blob', 'not null' => TRUE, 'size' => 'normal', - 'default' => '0', ), - 'p1' => array( - 'type' => 'int', + 'version' => array( + 'type' => 'varchar', 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', - 'unsigned' => TRUE, + 'length' => '20', + 'default' => 'none', ), - 'p2' => array( - 'type' => 'int', - 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', - 'unsigned' => TRUE, + ), + 'primary key' => array( + 'lid', + ), + 'indexes' => array( + 'source' => array( + array( + 'source', + '30', + ), ), - 'p3' => array( - 'type' => 'int', - 'not null' => TRUE, - 'size' => 'normal', - 'default' => '0', - 'unsigned' => TRUE, + ), + 'mysql_character_set' => 'utf8', +)); + +$connection->insert('locales_source') +->fields(array( + 'lid', + 'location', + 'textgroup', + 'source', + 'version', +)) +->values(array( + 'lid' => '1', + 'location' => 'misc/drupal.js', + 'textgroup' => 'default', + 'source' => 'Unspecified error', + 'version' => 'none', +)) +->values(array( + 'lid' => '2', + 'location' => 'misc/drupal.js', + 'textgroup' => 'default', + 'source' => 'An error occurred. \n@uri\n@text', + 'version' => 'none', +)) +->values(array( + 'lid' => '3', + 'location' => 'misc/drupal.js', + 'textgroup' => 'default', + 'source' => 'An error occurred. \n@uri\n(no information available).', + 'version' => 'none', +)) +->values(array( + 'lid' => '4', + 'location' => 'misc/drupal.js', + 'textgroup' => 'default', + 'source' => 'An HTTP error @status occurred. \n@uri', + 'version' => 'none', +)) +->values(array( + 'lid' => '5', + 'location' => 'content.module:21', + 'textgroup' => 'default', + 'source' => 'The content module, a required component of the Content Construction Kit (CCK), allows administrators to associate custom fields with content types. In Drupal, content types are used to define the characteristics of a post, including the title and description of the fields displayed on its add and edit pages. Using the content module (and the other helper modules included in CCK), custom fields beyond the default "Title" and "Body" may be added. CCK features are accessible through tabs on the content types administration page. (See the node module help page for more information about content types.)', + 'version' => 'none', +)) +->values(array( + 'lid' => '6', + 'location' => 'content.module:22', + 'textgroup' => 'default', + 'source' => 'When adding a custom field to a content type, you determine its type (whether it will contain text, numbers, or references to other objects) and how it will be displayed (either as a text field or area, a select box, checkbox, radio button, or autocompleting field). A field may have multiple values (i.e., a "person" may have multiple e-mail addresses) or a single value (i.e., an "employee" has a single employee identification number). As you add and edit fields, CCK automatically adjusts the structure of the database as necessary. CCK also provides a number of other features, including intelligent caching for your custom data, an import and export facility for content type definitions, and integration with other contributed modules.', + 'version' => 'none', +)) +->values(array( + 'lid' => '7', + 'location' => 'content.module:23', + 'textgroup' => 'default', + 'source' => 'Custom field types are provided by a set of optional modules included with CCK (each module provides a different type). The modules page allows you to enable or disable CCK components. A default installation of CCK includes:', + 'version' => 'none', +)) +->values(array( + 'lid' => '8', + 'location' => 'content.module:25', + 'textgroup' => 'default', + 'source' => 'number, which adds numeric field types, in integer, decimal or floating point form. You may define a set of allowed inputs, or specify an allowable range of values. A variety of common formats for displaying numeric data are available.', + 'version' => 'none', +)) +->values(array( + 'lid' => '9', + 'location' => 'content.module:26', + 'textgroup' => 'default', + 'source' => "text, which adds text field types. A text field may contain plain text only, or optionally, may use Drupal's input format filters to securely manage rich text input. Text input fields may be either a single line (text field), multiple lines (text area), or for greater input control, a select box, checkbox, or radio buttons. If desired, CCK can validate the input to a set of allowed values.", + 'version' => 'none', +)) +->values(array( + 'lid' => '10', + 'location' => 'content.module:27', + 'textgroup' => 'default', + 'source' => 'nodereference, which creates custom references between Drupal nodes. By adding a nodereference field and two different content types, for instance, you can easily create complex parent/child relationships between data (multiple "employee" nodes may contain a nodereference field linking to an "employer" node).', + 'version' => 'none', +)) +->values(array( + 'lid' => '11', + 'location' => 'content.module:28', + 'textgroup' => 'default', + 'source' => "userreference, which creates custom references to your sites' user accounts. By adding a userreference field, you can create complex relationships between your site's users and posts. To track user involvement in a post beyond Drupal's standard Authored by field, for instance, add a userreference field named \"Edited by\" to a content type to store a link to an editor's user account page.", + 'version' => 'none', +)) +->values(array( + 'lid' => '12', + 'location' => 'content.module:29', + 'textgroup' => 'default', + 'source' => 'fieldgroup, which creates collapsible fieldsets to hold a group of related fields. A fieldset may either be open or closed by default. The order of your fieldsets, and the order of fields within a fieldset, is managed via a drag-and-drop interface provided by content module.', + 'version' => 'none', +)) +->values(array( + 'lid' => '13', + 'location' => 'content.module:31', + 'textgroup' => 'default', + 'source' => 'For more information, see the online handbook entry for CCK or the CCK project page.', + 'version' => 'none', +)) +->values(array( + 'lid' => '14', + 'location' => 'theme/theme.inc:111', + 'textgroup' => 'default', + 'source' => "Configure how this content type's fields and field labels should be displayed when it's viewed in teaser and full-page mode.", + 'version' => 'none', +)) +->values(array( + 'lid' => '15', + 'location' => 'theme/theme.inc:114', + 'textgroup' => 'default', + 'source' => "Configure how this content type's fields should be displayed when it's rendered in the following contexts.", + 'version' => 'none', +)) +->values(array( + 'lid' => '16', + 'location' => 'content.module:48', + 'textgroup' => 'default', + 'source' => 'Control the order of fields in the input form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '17', + 'location' => 'content.module:486, modules/content_multigroup/content_multigroup.module:1422', + 'textgroup' => 'default', + 'source' => 'This field is required.', + 'version' => 'none', +)) +->values(array( + 'lid' => '18', + 'location' => 'content.module:490', + 'textgroup' => 'default', + 'source' => '!title: !required', + 'version' => 'none', +)) +->values(array( + 'lid' => '19', + 'location' => 'content.module:493, modules/content_multigroup/content_multigroup.module:1434', + 'textgroup' => 'default', + 'source' => 'Order', + 'version' => 'none', +)) +->values(array( + 'lid' => '20', + 'location' => 'content.module:1640', + 'textgroup' => 'default', + 'source' => 'RSS Item', + 'version' => 'none', +)) +->values(array( + 'lid' => '21', + 'location' => 'content.module:1897', + 'textgroup' => 'default', + 'source' => 'Search Index', + 'version' => 'none', +)) +->values(array( + 'lid' => '22', + 'location' => 'content.module:1901', + 'textgroup' => 'default', + 'source' => 'Search Result', + 'version' => 'none', +)) +->values(array( + 'lid' => '23', + 'location' => 'content.module:2363', + 'textgroup' => 'default', + 'source' => 'Language', + 'version' => 'none', +)) +->values(array( + 'lid' => '24', + 'location' => 'content.module:2377', + 'textgroup' => 'default', + 'source' => 'Taxonomy', + 'version' => 'none', +)) +->values(array( + 'lid' => '25', + 'location' => 'content.module:2408', + 'textgroup' => 'default', + 'source' => 'File attachments', + 'version' => 'none', +)) +->values(array( + 'lid' => '26', + 'location' => 'content.module:600', + 'textgroup' => 'default', + 'source' => 'Updating field type %type with module %module.', + 'version' => 'none', +)) +->values(array( + 'lid' => '27', + 'location' => 'content.module:607', + 'textgroup' => 'default', + 'source' => 'Updating widget type %type with module %module.', + 'version' => 'none', +)) +->values(array( + 'lid' => '28', + 'location' => 'content.module:63', + 'textgroup' => 'default', + 'source' => 'Use PHP input for field settings (dangerous - grant with care)', + 'version' => 'none', +)) +->values(array( + 'lid' => '29', + 'location' => 'content.module:104', + 'textgroup' => 'default', + 'source' => 'Manage fields', + 'version' => 'none', +)) +->values(array( + 'lid' => '30', + 'location' => 'content.module:113', + 'textgroup' => 'default', + 'source' => 'Display fields', + 'version' => 'none', +)) +->values(array( + 'lid' => '31', + 'location' => 'content.module:143', + 'textgroup' => 'default', + 'source' => 'General', + 'version' => 'none', +)) +->values(array( + 'lid' => '32', + 'location' => 'content.module:149', + 'textgroup' => 'default', + 'source' => 'Advanced', + 'version' => 'none', +)) +->values(array( + 'lid' => '33', + 'location' => 'content.module:144', + 'textgroup' => 'default', + 'source' => 'Remove field', + 'version' => 'none', +)) +->values(array( + 'lid' => '34', + 'location' => 'content.info:0, includes/content.rules.inc:19;200, includes/views/content.views.inc:178;254', + 'textgroup' => 'default', + 'source' => 'Content', + 'version' => 'none', +)) +->values(array( + 'lid' => '35', + 'location' => 'content.info:0', + 'textgroup' => 'default', + 'source' => 'Allows administrators to define new content types.', + 'version' => 'none', +)) +->values(array( + 'lid' => '36', + 'location' => 'content.info:0, modules/content_copy/content_copy.info:0, modules/content_multigroup/content_multigroup.info:0, modules/content_permissions/content_permissions.info:0', + 'textgroup' => 'default', + 'source' => 'CCK', + 'version' => 'none', +)) +->values(array( + 'lid' => '37', + 'location' => 'modules/text/text.module:41, modules/text/text.info:0', + 'textgroup' => 'default', + 'source' => 'Text', + 'version' => 'none', +)) +->values(array( + 'lid' => '38', + 'location' => 'examples/example_field.php:178', + 'textgroup' => 'default', + 'source' => 'The possible values this field can contain. Enter one value per line, in the format key|label. The key is the value that will be stored in the database and it must match the field storage type, %type. The label is optional and the key will be used as the label if no label is specified.', + 'version' => 'none', +)) +->values(array( + 'lid' => '39', + 'location' => 'examples/example_field.php:484', + 'textgroup' => 'default', + 'source' => 'Text area', + 'version' => 'none', +)) +->values(array( + 'lid' => '40', + 'location' => 'includes/content.admin.inc:148;164;790, modules/fieldgroup/fieldgroup.module:236', + 'textgroup' => 'default', + 'source' => 'Remove', + 'version' => 'none', +)) +->values(array( + 'lid' => '41', + 'location' => 'content.module:1868', + 'textgroup' => 'default', + 'source' => 'Basic', + 'version' => 'none', +)) +->values(array( + 'lid' => '42', + 'location' => 'content.module:1635 modules/nodereference/nodereference.module:215', + 'textgroup' => 'default', + 'source' => 'Teaser', + 'version' => 'none', +)) +->values(array( + 'lid' => '43', + 'location' => 'content.module:1636 modules/nodereference/nodereference.module:210', + 'textgroup' => 'default', + 'source' => 'Full node', + 'version' => 'none', +)) +->values(array( + 'lid' => '44', + 'location' => 'content.module:1881;1884', + 'textgroup' => 'default', + 'source' => 'RSS', + 'version' => 'none', +)) +->values(array( + 'lid' => '45', + 'location' => 'content.module:1894', + 'textgroup' => 'default', + 'source' => 'Search', + 'version' => 'none', +)) +->values(array( + 'lid' => '46', + 'location' => 'content.module:2349;2356', + 'textgroup' => 'default', + 'source' => 'Node module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '47', + 'location' => 'content.module:2364', + 'textgroup' => 'default', + 'source' => 'Locale module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '48', + 'location' => 'content.module:2370', + 'textgroup' => 'default', + 'source' => 'Menu settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '49', + 'location' => 'content.module:2371', + 'textgroup' => 'default', + 'source' => 'Menu module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '50', + 'location' => 'content.module:2378', + 'textgroup' => 'default', + 'source' => 'Taxonomy module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '51', + 'location' => 'content.module:2384', + 'textgroup' => 'default', + 'source' => 'Book', + 'version' => 'none', +)) +->values(array( + 'lid' => '52', + 'location' => 'content.module:2385', + 'textgroup' => 'default', + 'source' => 'Book module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '53', + 'location' => 'content.module:2391', + 'textgroup' => 'default', + 'source' => 'Poll title', + 'version' => 'none', +)) +->values(array( + 'lid' => '54', + 'location' => 'content.module:2392', + 'textgroup' => 'default', + 'source' => 'Poll module title.', + 'version' => 'none', +)) +->values(array( + 'lid' => '55', + 'location' => 'content.module:2396', + 'textgroup' => 'default', + 'source' => 'Poll choices', + 'version' => 'none', +)) +->values(array( + 'lid' => '56', + 'location' => 'content.module:2397', + 'textgroup' => 'default', + 'source' => 'Poll module choices.', + 'version' => 'none', +)) +->values(array( + 'lid' => '57', + 'location' => 'content.module:2401', + 'textgroup' => 'default', + 'source' => 'Poll settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '58', + 'location' => 'content.module:2402', + 'textgroup' => 'default', + 'source' => 'Poll module settings.', + 'version' => 'none', +)) +->values(array( + 'lid' => '59', + 'location' => 'content.module:2409', + 'textgroup' => 'default', + 'source' => 'Upload module form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '60', + 'location' => 'content.module:557;564;0 includes/content.crud.inc:591;629', + 'textgroup' => 'default', + 'source' => 'content', + 'version' => 'none', +)) +->values(array( + 'lid' => '61', + 'location' => 'content.module:103 modules/content_copy/content_copy.module:125', + 'textgroup' => 'default', + 'source' => 'Fields', + 'version' => 'none', +)) +->values(array( + 'lid' => '62', + 'location' => 'content.install:236', + 'textgroup' => 'default', + 'source' => "Updates for CCK-related modules are not run until the modules are enabled on the administer modules page. When you enable them, you'll need to return to update.php and run the remaining updates.", + 'version' => 'none', +)) +->values(array( + 'lid' => '63', + 'location' => 'content.install:239', + 'textgroup' => 'default', + 'source' => '!module.module has updates but cannot be updated because content.module is not enabled.
    If and when content.module is enabled, you will need to re-run the update script. You will continue to see this message until the module is enabled and updates are run.', + 'version' => 'none', +)) +->values(array( + 'lid' => '64', + 'location' => 'content.install:244', + 'textgroup' => 'default', + 'source' => '!module.module has updates and is available in the modules folder but is not enabled.
    If and when it is enabled, you will need to re-run the update script. You will continue to see this message until the module is enabled and updates are run.', + 'version' => 'none', +)) +->values(array( + 'lid' => '65', + 'location' => 'content.install:251', + 'textgroup' => 'default', + 'source' => 'Some updates are still pending. Please return to update.php and run the remaining updates.', + 'version' => 'none', +)) +->values(array( + 'lid' => '66', + 'location' => '(duplicate) content.install:10', + 'textgroup' => 'default', + 'source' => 'CCK - No Views integration', + 'version' => 'none', +)) +->values(array( + 'lid' => '67', + 'location' => '(duplicate) content.install:11', + 'textgroup' => 'default', + 'source' => 'CCK integration with Views module requires Views 6.x-2.0-rc2 or greater.', + 'version' => 'none', +)) +->values(array( + 'lid' => '68', + 'location' => 'includes/content.admin.inc:16;212', + 'textgroup' => 'default', + 'source' => 'Name', + 'version' => 'none', +)) +->values(array( + 'lid' => '69', + 'location' => 'includes/content.admin.inc:16;212', + 'textgroup' => 'default', + 'source' => 'Type', + 'version' => 'none', +)) +->values(array( + 'lid' => '70', + 'location' => 'includes/content.admin.inc:16 modules/fieldgroup/fieldgroup.module:156', + 'textgroup' => 'default', + 'source' => 'Description', + 'version' => 'none', +)) +->values(array( + 'lid' => '71', + 'location' => 'includes/content.admin.inc:16;212', + 'textgroup' => 'default', + 'source' => 'Operations', + 'version' => 'none', +)) +->values(array( + 'lid' => '72', + 'location' => 'includes/content.admin.inc:30', + 'textgroup' => 'default', + 'source' => 'edit', + 'version' => 'none', +)) +->values(array( + 'lid' => '73', + 'location' => 'includes/content.admin.inc:34', + 'textgroup' => 'default', + 'source' => 'manage fields', + 'version' => 'none', +)) +->values(array( + 'lid' => '74', + 'location' => 'includes/content.admin.inc:37', + 'textgroup' => 'default', + 'source' => 'delete', + 'version' => 'none', +)) +->values(array( + 'lid' => '75', + 'location' => 'includes/content.admin.inc:48', + 'textgroup' => 'default', + 'source' => 'No content types available.', + 'version' => 'none', +)) +->values(array( + 'lid' => '76', + 'location' => 'includes/content.admin.inc:55', + 'textgroup' => 'default', + 'source' => '» Add a new content type', + 'version' => 'none', +)) +->values(array( + 'lid' => '77', + 'location' => 'includes/content.admin.inc:64;602;856', + 'textgroup' => 'default', + 'source' => 'Field name', + 'version' => 'none', +)) +->values(array( + 'lid' => '78', + 'location' => 'includes/content.admin.inc:64;632;643;862', + 'textgroup' => 'default', + 'source' => 'Field type', + 'version' => 'none', +)) +->values(array( + 'lid' => '79', + 'location' => 'includes/content.admin.inc:64', + 'textgroup' => 'default', + 'source' => 'Used in', + 'version' => 'none', +)) +->values(array( + 'lid' => '80', + 'location' => 'includes/content.admin.inc:71', + 'textgroup' => 'default', + 'source' => '@field_name (Locked)', + 'version' => 'none', +)) +->values(array( + 'lid' => '81', + 'location' => 'includes/content.admin.inc:87', + 'textgroup' => 'default', + 'source' => 'No fields have been defined for any content type yet.', + 'version' => 'none', +)) +->values(array( + 'lid' => '82', + 'location' => 'includes/content.admin.inc:106', + 'textgroup' => 'default', + 'source' => 'This content type has inactive fields. Inactive fields are not included in lists of available fields until their modules are enabled.', + 'version' => 'none', +)) +->values(array( + 'lid' => '83', + 'location' => 'includes/content.admin.inc:108', + 'textgroup' => 'default', + 'source' => '!field (!field_name) is an inactive !field_type field that uses a !widget_type widget.', + 'version' => 'none', +)) +->values(array( + 'lid' => '84', + 'location' => 'includes/content.admin.inc:147;163', + 'textgroup' => 'default', + 'source' => 'Configure', + 'version' => 'none', +)) +->values(array( + 'lid' => '85', + 'location' => 'includes/content.admin.inc:181', + 'textgroup' => 'default', + 'source' => 'Locked', + 'version' => 'none', +)) +->values(array( + 'lid' => '86', + 'location' => 'includes/content.admin.inc:237', + 'textgroup' => 'default', + 'source' => '- Select a field type -', + 'version' => 'none', +)) +->values(array( + 'lid' => '87', + 'location' => 'includes/content.admin.inc:238', + 'textgroup' => 'default', + 'source' => '- Select a widget -', + 'version' => 'none', +)) +->values(array( + 'lid' => '88', + 'location' => 'includes/content.admin.inc:212;413;623;850, modules/fieldgroup/fieldgroup.module:121', + 'textgroup' => 'default', + 'source' => 'Label', + 'version' => 'none', +)) +->values(array( + 'lid' => '89', + 'location' => 'includes/content.admin.inc:253', + 'textgroup' => 'default', + 'source' => 'Field name (a-z, 0-9, _)', + 'version' => 'none', +)) +->values(array( + 'lid' => '90', + 'location' => 'includes/content.admin.inc:258', + 'textgroup' => 'default', + 'source' => 'Type of data to store.', + 'version' => 'none', +)) +->values(array( + 'lid' => '91', + 'location' => 'includes/content.admin.inc:263;295', + 'textgroup' => 'default', + 'source' => 'Form element to edit the data.', + 'version' => 'none', +)) +->values(array( + 'lid' => '92', + 'location' => 'includes/content.admin.inc:279', + 'textgroup' => 'default', + 'source' => '- Select an existing field -', + 'version' => 'none', +)) +->values(array( + 'lid' => '93', + 'location' => 'includes/content.admin.inc:290', + 'textgroup' => 'default', + 'source' => 'Field to share', + 'version' => 'none', +)) +->values(array( + 'lid' => '94', + 'location' => 'includes/content.admin.inc:324', + 'textgroup' => 'default', + 'source' => 'Group name (a-z, 0-9, _)', + 'version' => 'none', +)) +->values(array( + 'lid' => '95', + 'location' => 'includes/content.admin.inc:201;402, modules/fieldgroup/fieldgroup.module:110;363', + 'textgroup' => 'default', + 'source' => 'Save', + 'version' => 'none', +)) +->values(array( + 'lid' => '96', + 'location' => 'includes/content.admin.inc:365', + 'textgroup' => 'default', + 'source' => 'Add new field: you need to provide a label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '97', + 'location' => 'includes/content.admin.inc:370', + 'textgroup' => 'default', + 'source' => 'Add new field: you need to provide a field name.', + 'version' => 'none', +)) +->values(array( + 'lid' => '98', + 'location' => 'includes/content.admin.inc:384', + 'textgroup' => 'default', + 'source' => 'Add new field: the field name %field_name is invalid. The name must include only lowercase unaccentuated letters, numbers, and underscores.', + 'version' => 'none', +)) +->values(array( + 'lid' => '99', + 'location' => 'includes/content.admin.inc:387', + 'textgroup' => 'default', + 'source' => "Add new field: the field name %field_name is too long. The name is limited to 32 characters, including the 'field_' prefix.", + 'version' => 'none', +)) +->values(array( + 'lid' => '100', + 'location' => 'includes/content.admin.inc:391', + 'textgroup' => 'default', + 'source' => "Add new field: the name 'field_instance' is a reserved name.", + 'version' => 'none', +)) +->values(array( + 'lid' => '101', + 'location' => 'includes/content.admin.inc:403', + 'textgroup' => 'default', + 'source' => 'Add new field: the field name %field_name already exists.', + 'version' => 'none', +)) +->values(array( + 'lid' => '102', + 'location' => 'includes/content.admin.inc:409', + 'textgroup' => 'default', + 'source' => 'Add new field: you need to select a field type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '103', + 'location' => 'includes/content.admin.inc:414', + 'textgroup' => 'default', + 'source' => 'Add new field: you need to select a widget.', + 'version' => 'none', +)) +->values(array( + 'lid' => '104', + 'location' => 'includes/content.admin.inc:420', + 'textgroup' => 'default', + 'source' => 'Add new field: invalid widget.', + 'version' => 'none', +)) +->values(array( + 'lid' => '105', + 'location' => 'includes/content.admin.inc:441', + 'textgroup' => 'default', + 'source' => 'Add existing field: you need to provide a label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '106', + 'location' => 'includes/content.admin.inc:446', + 'textgroup' => 'default', + 'source' => 'Add existing field: you need to select a field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '107', + 'location' => 'includes/content.admin.inc:451', + 'textgroup' => 'default', + 'source' => 'Add existing field: you need to select a widget.', + 'version' => 'none', +)) +->values(array( + 'lid' => '108', + 'location' => 'includes/content.admin.inc:457', + 'textgroup' => 'default', + 'source' => 'Add existing field: invalid widget.', + 'version' => 'none', +)) +->values(array( + 'lid' => '109', + 'location' => 'includes/content.admin.inc:745', + 'textgroup' => 'default', + 'source' => 'There was a problem creating field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '110', + 'location' => 'includes/content.admin.inc:518', + 'textgroup' => 'default', + 'source' => 'The field %label cannot be added to a content type because it is locked.', + 'version' => 'none', +)) +->values(array( + 'lid' => '111', + 'location' => 'includes/content.admin.inc:550', + 'textgroup' => 'default', + 'source' => 'There was a problem adding field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '112', + 'location' => 'includes/content.admin.inc:571', + 'textgroup' => 'default', + 'source' => 'There are no fields configured for this content type. You can add new fields on the Manage fields page.', + 'version' => 'none', +)) +->values(array( + 'lid' => '113', + 'location' => 'includes/content.admin.inc:319;360', + 'textgroup' => 'default', + 'source' => 'Above', + 'version' => 'none', +)) +->values(array( + 'lid' => '114', + 'location' => 'includes/content.admin.inc:320', + 'textgroup' => 'default', + 'source' => 'Inline', + 'version' => 'none', +)) +->values(array( + 'lid' => '115', + 'location' => 'includes/content.admin.inc:618;661', + 'textgroup' => 'default', + 'source' => 'Include', + 'version' => 'none', +)) +->values(array( + 'lid' => '116', + 'location' => 'includes/content.admin.inc:618;661, theme/content-admin-display-overview-form.tpl.php:17', + 'textgroup' => 'default', + 'source' => 'Exclude', + 'version' => 'none', +)) +->values(array( + 'lid' => '117', + 'location' => 'includes/content.admin.inc:364', + 'textgroup' => 'default', + 'source' => 'no styling', + 'version' => 'none', +)) +->values(array( + 'lid' => '118', + 'location' => 'includes/content.admin.inc:365', + 'textgroup' => 'default', + 'source' => 'simple', + 'version' => 'none', +)) +->values(array( + 'lid' => '119', + 'location' => 'includes/content.admin.inc:366', + 'textgroup' => 'default', + 'source' => 'fieldset', + 'version' => 'none', +)) +->values(array( + 'lid' => '120', + 'location' => 'includes/content.admin.inc:367', + 'textgroup' => 'default', + 'source' => 'fieldset - collapsible', + 'version' => 'none', +)) +->values(array( + 'lid' => '121', + 'location' => 'includes/content.admin.inc:368', + 'textgroup' => 'default', + 'source' => 'fieldset - collapsed', + 'version' => 'none', +)) +->values(array( + 'lid' => '122', + 'location' => 'includes/content.admin.inc:460', + 'textgroup' => 'default', + 'source' => 'Your settings have been saved.', + 'version' => 'none', +)) +->values(array( + 'lid' => '123', + 'location' => 'includes/content.admin.inc:760', + 'textgroup' => 'default', + 'source' => '@type: @field (@label)', + 'version' => 'none', +)) +->values(array( + 'lid' => '124', + 'location' => 'includes/content.admin.inc:597', + 'textgroup' => 'default', + 'source' => 'Edit basic information', + 'version' => 'none', +)) +->values(array( + 'lid' => '125', + 'location' => 'includes/content.admin.inc:792', + 'textgroup' => 'default', + 'source' => 'The machine-readable name of the field. This name cannot be changed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '126', + 'location' => 'includes/content.admin.inc:626', + 'textgroup' => 'default', + 'source' => 'A human-readable name to be used as the label for this field in the %type content type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '127', + 'location' => 'includes/content.admin.inc:646', + 'textgroup' => 'default', + 'source' => 'The type of data you would like to store in the database with this field. This option cannot be changed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '128', + 'location' => 'includes/content.admin.inc:651;869', + 'textgroup' => 'default', + 'source' => 'Widget type', + 'version' => 'none', +)) +->values(array( + 'lid' => '129', + 'location' => 'includes/content.admin.inc:655', + 'textgroup' => 'default', + 'source' => 'The type of form element you would like to present to the user when creating this field in the %type content type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '130', + 'location' => 'includes/content.admin.inc:669', + 'textgroup' => 'default', + 'source' => 'Continue', + 'version' => 'none', +)) +->values(array( + 'lid' => '131', + 'location' => 'includes/content.admin.inc:854', + 'textgroup' => 'default', + 'source' => 'Updated basic settings for field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '132', + 'location' => 'includes/content.admin.inc:858', + 'textgroup' => 'default', + 'source' => 'There was a problem updating the basic settings for field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '133', + 'location' => 'includes/content.admin.inc:786', + 'textgroup' => 'default', + 'source' => 'Are you sure you want to remove the field %field?', + 'version' => 'none', +)) +->values(array( + 'lid' => '134', + 'location' => 'includes/content.admin.inc:789', + 'textgroup' => 'default', + 'source' => 'If you have any content left in this field, it will be lost. This action cannot be undone.', + 'version' => 'none', +)) +->values(array( + 'lid' => '135', + 'location' => 'includes/content.admin.inc:790 modules/fieldgroup/fieldgroup.module:236', + 'textgroup' => 'default', + 'source' => 'Cancel', + 'version' => 'none', +)) +->values(array( + 'lid' => '136', + 'location' => 'includes/content.admin.inc:894', + 'textgroup' => 'default', + 'source' => 'This field is locked and cannot be removed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '137', + 'location' => 'includes/content.admin.inc:808', + 'textgroup' => 'default', + 'source' => 'Removed field %field from %type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '138', + 'location' => 'includes/content.admin.inc:813', + 'textgroup' => 'default', + 'source' => 'There was a problem deleting %field from %type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '139', + 'location' => 'includes/content.admin.inc:939', + 'textgroup' => 'default', + 'source' => 'The field %field is locked and cannot be edited.', + 'version' => 'none', +)) +->values(array( + 'lid' => '140', + 'location' => 'includes/content.admin.inc:846', + 'textgroup' => 'default', + 'source' => '%type basic information', + 'version' => 'none', +)) +->values(array( + 'lid' => '141', + 'location' => 'includes/content.admin.inc:876', + 'textgroup' => 'default', + 'source' => 'Change basic information', + 'version' => 'none', +)) +->values(array( + 'lid' => '142', + 'location' => 'includes/content.admin.inc:882', + 'textgroup' => 'default', + 'source' => '%type settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '143', + 'location' => 'includes/content.admin.inc:883', + 'textgroup' => 'default', + 'source' => 'These settings apply only to the %field field as it appears in the %type content type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '144', + 'location' => 'includes/content.admin.inc:897 modules/fieldgroup/fieldgroup.module:143', + 'textgroup' => 'default', + 'source' => 'Help text', + 'version' => 'none', +)) +->values(array( + 'lid' => '145', + 'location' => 'includes/content.admin.inc:900', + 'textgroup' => 'default', + 'source' => 'Instructions to present to the user below this field on the editing form.
    Allowed HTML tags: @tags', + 'version' => 'none', +)) +->values(array( + 'lid' => '146', + 'location' => 'includes/content.admin.inc:908', + 'textgroup' => 'default', + 'source' => 'Default value', + 'version' => 'none', +)) +->values(array( + 'lid' => '147', + 'location' => 'examples/example_field.php:182 includes/content.admin.inc:930, modules/number/number.module:137 modules/text/text.module:96', + 'textgroup' => 'default', + 'source' => 'PHP code', + 'version' => 'none', +)) +->values(array( + 'lid' => '148', + 'location' => 'includes/content.admin.inc:1083;1238, includes/content.rules.inc:93', + 'textgroup' => 'default', + 'source' => "'@column' => value for @column", + 'version' => 'none', +)) +->values(array( + 'lid' => '149', + 'location' => 'includes/content.admin.inc:1085;1240, includes/content.rules.inc:95', + 'textgroup' => 'default', + 'source' => "return array(\n 0 => array(@columns),\n // You'll usually want to stop here. Provide more values\n // if you want your 'default value' to be multi-valued:\n 1 => array(@columns),\n 2 => ...\n);", + 'version' => 'none', +)) +->values(array( + 'lid' => '150', + 'location' => 'examples/example_field.php:188 includes/content.admin.inc:951;964, modules/number/number.module:144;153 modules/text/text.module:103;112', + 'textgroup' => 'default', + 'source' => 'Code', + 'version' => 'none', +)) +->values(array( + 'lid' => '151', + 'location' => 'includes/content.admin.inc:1093', + 'textgroup' => 'default', + 'source' => 'Advanced usage only: PHP code that returns a default value. Should not include <?php ?> delimiters. If this field is filled out, the value returned by this code will override any value specified above. Expected format:
    !sample
    To figure out the expected format, you can use the devel load tab provided by devel module on a %type content page.', + 'version' => 'none', +)) +->values(array( + 'lid' => '152', + 'location' => 'includes/content.admin.inc:965 modules/number/number.module:154, modules/text/text.module:113', + 'textgroup' => 'default', + 'source' => '<none>', + 'version' => 'none', +)) +->values(array( + 'lid' => '153', + 'location' => 'includes/content.admin.inc:966 modules/number/number.module:155, modules/text/text.module:114', + 'textgroup' => 'default', + 'source' => "You're not allowed to input PHP code.", + 'version' => 'none', +)) +->values(array( + 'lid' => '154', + 'location' => 'includes/content.admin.inc:966', + 'textgroup' => 'default', + 'source' => 'This PHP code was set by an administrator and will override any value specified above.', + 'version' => 'none', +)) +->values(array( + 'lid' => '155', + 'location' => 'includes/content.admin.inc:973', + 'textgroup' => 'default', + 'source' => 'Global settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '156', + 'location' => 'includes/content.admin.inc:974', + 'textgroup' => 'default', + 'source' => 'These settings apply to the %field field in every content type in which it appears.', + 'version' => 'none', +)) +->values(array( + 'lid' => '157', + 'location' => 'includes/content.admin.inc:978', + 'textgroup' => 'default', + 'source' => 'Required', + 'version' => 'none', +)) +->values(array( + 'lid' => '158', + 'location' => 'includes/content.admin.inc:1119', + 'textgroup' => 'default', + 'source' => 'Maximum number of values users can enter for this field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '159', + 'location' => 'includes/content.admin.inc:1121', + 'textgroup' => 'default', + 'source' => "'Unlimited' will provide an 'Add more' button so the users can add as many values as they like.", + 'version' => 'none', +)) +->values(array( + 'lid' => '160', + 'location' => 'includes/content.admin.inc:986', + 'textgroup' => 'default', + 'source' => 'Warning! Changing this setting after data has been created could result in the loss of data!', + 'version' => 'none', +)) +->values(array( + 'lid' => '161', + 'location' => 'includes/content.admin.inc:983', + 'textgroup' => 'default', + 'source' => 'Number of values', + 'version' => 'none', +)) +->values(array( + 'lid' => '162', + 'location' => 'includes/content.admin.inc:984', + 'textgroup' => 'default', + 'source' => 'Unlimited', + 'version' => 'none', +)) +->values(array( + 'lid' => '163', + 'location' => 'includes/content.admin.inc:1001', + 'textgroup' => 'default', + 'source' => 'Save field settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '164', + 'location' => 'includes/content.admin.inc:1281', + 'textgroup' => 'default', + 'source' => "The PHP code for 'default value' returned @value, which is invalid.", + 'version' => 'none', +)) +->values(array( + 'lid' => '165', + 'location' => 'includes/content.admin.inc:1135', + 'textgroup' => 'default', + 'source' => 'The default value is invalid.', + 'version' => 'none', +)) +->values(array( + 'lid' => '166', + 'location' => 'includes/content.admin.inc:547', + 'textgroup' => 'default', + 'source' => 'Added field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '167', + 'location' => 'includes/content.admin.inc:1158', + 'textgroup' => 'default', + 'source' => 'Saved field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '168', + 'location' => 'includes/content.admin.inc:1463', + 'textgroup' => 'default', + 'source' => 'Processing', + 'version' => 'none', +)) +->values(array( + 'lid' => '169', + 'location' => 'includes/content.admin.inc:1464', + 'textgroup' => 'default', + 'source' => 'The update has encountered an error.', + 'version' => 'none', +)) +->values(array( + 'lid' => '170', + 'location' => 'includes/content.admin.inc:1478', + 'textgroup' => 'default', + 'source' => 'The database has been altered and data has been migrated or deleted.', + 'version' => 'none', +)) +->values(array( + 'lid' => '171', + 'location' => 'includes/content.admin.inc:1481', + 'textgroup' => 'default', + 'source' => 'An error occurred and database alteration did not complete.', + 'version' => 'none', +)) +->values(array( + 'lid' => '172', + 'location' => 'includes/content.admin.inc:1584', + 'textgroup' => 'default', + 'source' => 'Processing %title', + 'version' => 'none', +)) +->values(array( + 'lid' => '173', + 'location' => 'includes/content.admin.inc:1849', + 'textgroup' => 'default', + 'source' => '%name must be an integer.', + 'version' => 'none', +)) +->values(array( + 'lid' => '174', + 'location' => 'includes/content.admin.inc:1859', + 'textgroup' => 'default', + 'source' => '%name must be a positive integer.', + 'version' => 'none', +)) +->values(array( + 'lid' => '175', + 'location' => 'includes/content.admin.inc:1869', + 'textgroup' => 'default', + 'source' => '%name must be a number.', + 'version' => 'none', +)) +->values(array( + 'lid' => '176', + 'location' => 'includes/content.admin.inc:1482', + 'textgroup' => 'default', + 'source' => '1 item successfully processed:', + 'version' => 'none', +)) +->values(array( + 'lid' => '177', + 'location' => 'includes/content.admin.inc:1482', + 'textgroup' => 'default', + 'source' => '@count items successfully processed:', + 'version' => 'none', +)) +->values(array( + 'lid' => '178', + 'location' => 'includes/content.crud.inc:591', + 'textgroup' => 'default', + 'source' => 'Content fields table %old_name has been renamed to %new_name and field instances have been updated.', + 'version' => 'none', +)) +->values(array( + 'lid' => '179', + 'location' => 'includes/content.crud.inc:629', + 'textgroup' => 'default', + 'source' => 'The content fields table %name has been deleted.', + 'version' => 'none', +)) +->values(array( + 'lid' => '180', + 'location' => 'includes/content.node_form.inc:206', + 'textgroup' => 'default', + 'source' => 'Add another item', + 'version' => 'none', +)) +->values(array( + 'lid' => '181', + 'location' => 'includes/content.panels.inc:21;35', + 'textgroup' => 'default', + 'source' => 'Content field', + 'version' => 'none', +)) +->values(array( + 'lid' => '182', + 'location' => 'includes/content.panels.inc:38', + 'textgroup' => 'default', + 'source' => 'A content field from the referenced node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '183', + 'location' => 'includes/content.panels.inc:39, modules/fieldgroup/fieldgroup.panels.inc:31', + 'textgroup' => 'default', + 'source' => 'Node', + 'version' => 'none', +)) +->values(array( + 'lid' => '184', + 'location' => 'includes/content.panels.inc:40, modules/fieldgroup/fieldgroup.panels.inc:32', + 'textgroup' => 'default', + 'source' => 'Node context', + 'version' => 'none', +)) +->values(array( + 'lid' => '185', + 'location' => 'includes/content.panels.inc:52', + 'textgroup' => 'default', + 'source' => 'Block title', + 'version' => 'none', +)) +->values(array( + 'lid' => '186', + 'location' => 'includes/content.panels.inc:55', + 'textgroup' => 'default', + 'source' => 'Hidden', + 'version' => 'none', +)) +->values(array( + 'lid' => '187', + 'location' => 'includes/content.panels.inc:57', + 'textgroup' => 'default', + 'source' => 'Configure how the label is going to be displayed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '188', + 'location' => 'includes/content.panels.inc:73', + 'textgroup' => 'default', + 'source' => 'Field / Formatter', + 'version' => 'none', +)) +->values(array( + 'lid' => '189', + 'location' => 'includes/content.panels.inc:76', + 'textgroup' => 'default', + 'source' => 'Select a field and formatter.', + 'version' => 'none', +)) +->values(array( + 'lid' => '190', + 'location' => 'includes/content.panels.inc:92', + 'textgroup' => 'default', + 'source' => '"@s" field @name', + 'version' => 'none', +)) +->values(array( + 'lid' => '191', + 'location' => 'includes/content.rules.inc:15', + 'textgroup' => 'default', + 'source' => 'Populate a field', + 'version' => 'none', +)) +->values(array( + 'lid' => '192', + 'location' => 'includes/content.rules.inc:23;212', + 'textgroup' => 'default', + 'source' => 'You should make sure that the used field exists in the given content type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '193', + 'location' => 'includes/content.admin.inc:413', + 'textgroup' => 'default', + 'source' => 'Field', + 'version' => 'none', +)) +->values(array( + 'lid' => '194', + 'location' => 'includes/content.rules.inc:56', + 'textgroup' => 'default', + 'source' => 'Select the machine-name of the field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '195', + 'location' => 'includes/content.rules.inc:84', + 'textgroup' => 'default', + 'source' => 'Advanced: Specify the fields value with PHP code', + 'version' => 'none', +)) +->values(array( + 'lid' => '196', + 'location' => 'includes/content.rules.inc:102', + 'textgroup' => 'default', + 'source' => "Advanced usage only: PHP code that returns the value to set. Should not include <?php ?> delimiters. If this field is filled out, the value returned by this code will override any value specified above. Expected format:
    !sample
    Using devel.module's 'devel load' tab on a content page might help you figure out the expected format.", + 'version' => 'none', +)) +->values(array( + 'lid' => '197', + 'location' => 'includes/content.rules.inc:130', + 'textgroup' => 'default', + 'source' => 'You have to return the default value in the expected format.', + 'version' => 'none', +)) +->values(array( + 'lid' => '198', + 'location' => 'includes/content.rules.inc:181', + 'textgroup' => 'default', + 'source' => "Populate @node's field '@field'", + 'version' => 'none', +)) +->values(array( + 'lid' => '199', + 'location' => 'includes/content.rules.inc:198', + 'textgroup' => 'default', + 'source' => 'Field has value', + 'version' => 'none', +)) +->values(array( + 'lid' => '200', + 'location' => 'includes/content.rules.inc:203', + 'textgroup' => 'default', + 'source' => 'You should make sure that the used field exists in the given content type. The condition returns TRUE, if the selected field has the given value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '201', + 'location' => 'includes/content.rules.inc:207', + 'textgroup' => 'default', + 'source' => 'Field has changed', + 'version' => 'none', +)) +->values(array( + 'lid' => '202', + 'location' => 'includes/content.rules.inc:209', + 'textgroup' => 'default', + 'source' => 'Content containing changes', + 'version' => 'none', +)) +->values(array( + 'lid' => '203', + 'location' => 'includes/content.rules.inc:210', + 'textgroup' => 'default', + 'source' => 'Content not containing changes', + 'version' => 'none', +)) +->values(array( + 'lid' => '204', + 'location' => 'includes/content.rules.inc:249', + 'textgroup' => 'default', + 'source' => "@node's field '@field' has value", + 'version' => 'none', +)) +->values(array( + 'lid' => '205', + 'location' => 'includes/content.rules.inc:269', + 'textgroup' => 'default', + 'source' => 'Select the machine-name of the field to look at.', + 'version' => 'none', +)) +->values(array( + 'lid' => '206', + 'location' => 'includes/content.rules.inc:275', + 'textgroup' => 'default', + 'source' => "@node's field '@field' has been changed", + 'version' => 'none', +)) +->values(array( + 'lid' => '207', + 'location' => 'includes/content.token.inc:12;15', + 'textgroup' => 'default', + 'source' => 'Token', + 'version' => 'none', +)) +->values(array( + 'lid' => '208', + 'location' => 'includes/content.token.inc:60', + 'textgroup' => 'default', + 'source' => 'Referenced node ID', + 'version' => 'none', +)) +->values(array( + 'lid' => '209', + 'location' => 'includes/content.token.inc:61', + 'textgroup' => 'default', + 'source' => 'Referenced node title', + 'version' => 'none', +)) +->values(array( + 'lid' => '210', + 'location' => 'includes/content.token.inc:83', + 'textgroup' => 'default', + 'source' => 'Referenced node unfiltered title. WARNING - raw user input.', + 'version' => 'none', +)) +->values(array( + 'lid' => '211', + 'location' => 'includes/content.token.inc:84', + 'textgroup' => 'default', + 'source' => 'Formatted html link to the referenced node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '212', + 'location' => 'includes/content.token.inc:85', + 'textgroup' => 'default', + 'source' => 'Relative path alias to the referenced node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '213', + 'location' => 'includes/content.token.inc:86', + 'textgroup' => 'default', + 'source' => 'Absolute path alias to the referenced node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '214', + 'location' => 'includes/content.token.inc:86', + 'textgroup' => 'default', + 'source' => 'Raw number value', + 'version' => 'none', +)) +->values(array( + 'lid' => '215', + 'location' => 'includes/content.token.inc:87', + 'textgroup' => 'default', + 'source' => 'Formatted number value', + 'version' => 'none', +)) +->values(array( + 'lid' => '216', + 'location' => 'includes/content.token.inc:110', + 'textgroup' => 'default', + 'source' => 'Raw, unfiltered text', + 'version' => 'none', +)) +->values(array( + 'lid' => '217', + 'location' => 'includes/content.token.inc:111', + 'textgroup' => 'default', + 'source' => 'Formatted and filtered text', + 'version' => 'none', +)) +->values(array( + 'lid' => '218', + 'location' => 'includes/content.token.inc:133', + 'textgroup' => 'default', + 'source' => 'Referenced user ID', + 'version' => 'none', +)) +->values(array( + 'lid' => '219', + 'location' => 'includes/content.token.inc:134', + 'textgroup' => 'default', + 'source' => 'Referenced user name', + 'version' => 'none', +)) +->values(array( + 'lid' => '220', + 'location' => 'includes/content.token.inc:135', + 'textgroup' => 'default', + 'source' => 'Formatted HTML link to referenced user', + 'version' => 'none', +)) +->values(array( + 'lid' => '221', + 'location' => 'includes/content.token.inc:164', + 'textgroup' => 'default', + 'source' => 'Relative path alias to the referenced user.', + 'version' => 'none', +)) +->values(array( + 'lid' => '222', + 'location' => 'includes/content.token.inc:165', + 'textgroup' => 'default', + 'source' => 'Absolute path alias to the referenced user.', + 'version' => 'none', +)) +->values(array( + 'lid' => '223', + 'location' => 'includes/views/content.views.inc:245;261', + 'textgroup' => 'default', + 'source' => '@label (!name)', + 'version' => 'none', +)) +->values(array( + 'lid' => '224', + 'location' => 'includes/views/content.views.inc:249', + 'textgroup' => 'default', + 'source' => '@label (!name) - !column', + 'version' => 'none', +)) +->values(array( + 'lid' => '225', + 'location' => 'includes/views/content.views.inc:250', + 'textgroup' => 'default', + 'source' => '@label-truncated - !column', + 'version' => 'none', +)) +->values(array( + 'lid' => '226', + 'location' => 'includes/content.views.inc:93', + 'textgroup' => 'default', + 'source' => 'Appears in: @types', + 'version' => 'none', +)) +->values(array( + 'lid' => '227', + 'location' => 'includes/views/handlers/content_handler_field.inc:59', + 'textgroup' => 'default', + 'source' => 'None', + 'version' => 'none', +)) +->values(array( + 'lid' => '228', + 'location' => 'includes/views/handlers/content_handler_field.inc:60', + 'textgroup' => 'default', + 'source' => 'Widget label (@label)', + 'version' => 'none', +)) +->values(array( + 'lid' => '229', + 'location' => 'includes/views/handlers/content_handler_field.inc:61', + 'textgroup' => 'default', + 'source' => 'Custom', + 'version' => 'none', +)) +->values(array( + 'lid' => '230', + 'location' => 'includes/views/handlers/content_handler_field.inc:67', + 'textgroup' => 'default', + 'source' => 'Custom label', + 'version' => 'none', +)) +->values(array( + 'lid' => '231', + 'location' => 'includes/content.views.inc:291', + 'textgroup' => 'default', + 'source' => 'Format', + 'version' => 'none', +)) +->values(array( + 'lid' => '232', + 'location' => 'includes/content.views.inc:372', + 'textgroup' => 'default', + 'source' => 'Group multiple values', + 'version' => 'none', +)) +->values(array( + 'lid' => '233', + 'location' => 'includes/views/handlers/content_handler_field_multiple.inc:61', + 'textgroup' => 'default', + 'source' => 'If unchecked, each item in the field will create a new row, which may appear to cause duplicates. This setting is not compatible with click-sorting in table displays.', + 'version' => 'none', +)) +->values(array( + 'lid' => '234', + 'location' => 'includes/content.views.inc:378', + 'textgroup' => 'default', + 'source' => 'Show @count value(s)', + 'version' => 'none', +)) +->values(array( + 'lid' => '235', + 'location' => 'includes/content.views.inc:387', + 'textgroup' => 'default', + 'source' => 'starting from @count', + 'version' => 'none', +)) +->values(array( + 'lid' => '236', + 'location' => 'includes/content.views.inc:396', + 'textgroup' => 'default', + 'source' => 'Reversed (start from last values)', + 'version' => 'none', +)) +->values(array( + 'lid' => '237', + 'location' => 'includes/views/handlers/content_handler_relationship.inc:40, includes/views/handlers/content_handler_sort.inc:41', + 'textgroup' => 'default', + 'source' => 'All', + 'version' => 'none', +)) +->values(array( + 'lid' => '238', + 'location' => 'includes/views/handlers/content_handler_relationship.inc:48, includes/views/handlers/content_handler_sort.inc:49', + 'textgroup' => 'default', + 'source' => 'Delta', + 'version' => 'none', +)) +->values(array( + 'lid' => '239', + 'location' => 'includes/views/handlers/content_handler_relationship.inc:49', + 'textgroup' => 'default', + 'source' => 'The delta allows you to select which item in a multiple value field to key the relationship off of. Select "1" to use the first item, "2" for the second item, and so on. If you select "All", each item in the field will create a new row, which may appear to cause duplicates.', + 'version' => 'none', +)) +->values(array( + 'lid' => '240', + 'location' => 'includes/views/handlers/content_handler_sort.inc:50', + 'textgroup' => 'default', + 'source' => 'The delta allows you to select which item in a multiple value field will be used for sorting. Select "1" to use the first item, "2" for the second item, and so on. If you select "All", each item in the field will create a new row, which may appear to cause duplicates.', + 'version' => 'none', +)) +->values(array( + 'lid' => '241', + 'location' => 'modules/content_copy/content_copy_export_form.tpl.php:9, modules/content_copy/content_copy.module:191;38', + 'textgroup' => 'default', + 'source' => 'Export', + 'version' => 'none', +)) +->values(array( + 'lid' => '242', + 'location' => 'modules/content_copy/content_copy.module:97', + 'textgroup' => 'default', + 'source' => 'This form will process a content type and one or more fields from that type and export the settings. The export created by this process can be copied and pasted as an import into the current or any other database. The import will add the fields to into an existing content type or create a new content type that includes the selected fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '243', + 'location' => 'modules/content_copy/content_copy.module:103', + 'textgroup' => 'default', + 'source' => 'Types', + 'version' => 'none', +)) +->values(array( + 'lid' => '244', + 'location' => 'modules/content_copy/content_copy.module:107', + 'textgroup' => 'default', + 'source' => 'Select the content type to export.', + 'version' => 'none', +)) +->values(array( + 'lid' => '245', + 'location' => 'modules/content_copy/content_copy.module:175', + 'textgroup' => 'default', + 'source' => 'Export data', + 'version' => 'none', +)) +->values(array( + 'lid' => '246', + 'location' => 'modules/content_copy/content_copy.module:180', + 'textgroup' => 'default', + 'source' => 'Copy the export text and paste it into another content type using the import function.', + 'version' => 'none', +)) +->values(array( + 'lid' => '247', + 'location' => 'modules/content_copy/content_copy.module:184', + 'textgroup' => 'default', + 'source' => 'Content types', + 'version' => 'none', +)) +->values(array( + 'lid' => '248', + 'location' => 'modules/content_copy/content_copy.module:308', + 'textgroup' => 'default', + 'source' => 'Content type', + 'version' => 'none', +)) +->values(array( + 'lid' => '249', + 'location' => 'modules/content_copy/content_copy.module:309', + 'textgroup' => 'default', + 'source' => 'Select the content type to import these fields into.
    Select <Create> to create a new content type to contain the fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '250', + 'location' => 'modules/content_copy/content_copy.module:314', + 'textgroup' => 'default', + 'source' => 'Import data', + 'version' => 'none', +)) +->values(array( + 'lid' => '251', + 'location' => 'modules/content_copy/content_copy.module:316', + 'textgroup' => 'default', + 'source' => 'Paste the text created by a content export into this field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '252', + 'location' => 'modules/content_copy/content_copy.module:320;46', + 'textgroup' => 'default', + 'source' => 'Import', + 'version' => 'none', +)) +->values(array( + 'lid' => '253', + 'location' => 'modules/content_copy/content_copy.module:328', + 'textgroup' => 'default', + 'source' => 'A file has been pre-loaded for import.', + 'version' => 'none', +)) +->values(array( + 'lid' => '254', + 'location' => 'modules/content_copy/content_copy.module:354', + 'textgroup' => 'default', + 'source' => 'The import data is not valid import text.', + 'version' => 'none', +)) +->values(array( + 'lid' => '255', + 'location' => 'modules/content_copy/content_copy.module:403', + 'textgroup' => 'default', + 'source' => 'The following modules must be enabled for this import to work: %modules.', + 'version' => 'none', +)) +->values(array( + 'lid' => '256', + 'location' => 'modules/content_copy/content_copy.module:411', + 'textgroup' => 'default', + 'source' => 'The content type %type already exists in this database.', + 'version' => 'none', +)) +->values(array( + 'lid' => '257', + 'location' => 'modules/content_copy/content_copy.module:418', + 'textgroup' => 'default', + 'source' => 'Exiting. No import performed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '258', + 'location' => 'modules/content_copy/content_copy.module:442', + 'textgroup' => 'default', + 'source' => 'An error has occurred adding the content type %type.
    Please check the errors displayed for more details.', + 'version' => 'none', +)) +->values(array( + 'lid' => '259', + 'location' => 'modules/content_copy/content_copy.module:467', + 'textgroup' => 'default', + 'source' => 'The imported field %field_label (%field_name) was not added to %type because that field already exists in %type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '260', + 'location' => 'modules/content_copy/content_copy.module:476', + 'textgroup' => 'default', + 'source' => 'The field %field_label (%field_name) was added to the content type %type.', + 'version' => 'none', +)) +->values(array( + 'lid' => '261', + 'location' => 'modules/content_copy/content_copy.module:0', + 'textgroup' => 'default', + 'source' => 'content_copy', + 'version' => 'none', +)) +->values(array( + 'lid' => '262', + 'location' => 'modules/content_copy/content_copy.info:0', + 'textgroup' => 'default', + 'source' => 'Content Copy', + 'version' => 'none', +)) +->values(array( + 'lid' => '263', + 'location' => 'modules/content_copy/content_copy.info:0', + 'textgroup' => 'default', + 'source' => 'Enables ability to import/export field definitions.', + 'version' => 'none', +)) +->values(array( + 'lid' => '264', + 'location' => 'modules/content_multigroup/content_multigroup.module:12', + 'textgroup' => 'default', + 'source' => 'The fields in a Standard group are independent of each other and each can have either single or multiple values. The fields in a Multigroup are treated as a repeating collection of single value fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '265', + 'location' => 'modules/content_multigroup/content_multigroup.module:65;135', + 'textgroup' => 'default', + 'source' => 'Multigroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '266', + 'location' => 'modules/content_multigroup/content_multigroup.module:134', + 'textgroup' => 'default', + 'source' => 'Standard', + 'version' => 'none', +)) +->values(array( + 'lid' => '267', + 'location' => 'modules/content_multigroup/content_multigroup.module:138', + 'textgroup' => 'default', + 'source' => 'Type of group.', + 'version' => 'none', +)) +->values(array( + 'lid' => '268', + 'location' => 'modules/content_multigroup/content_multigroup.module:215', + 'textgroup' => 'default', + 'source' => 'The field %field has been updated to use %multiple values, to match the multiple value setting of the Multigroup %group.', + 'version' => 'none', +)) +->values(array( + 'lid' => '269', + 'location' => 'modules/content_multigroup/content_multigroup.module:248', + 'textgroup' => 'default', + 'source' => 'This change is not allowed. The field %field already has %multiple values in the database but the group %group only allows %group_max. Making this change would result in the loss of data.', + 'version' => 'none', +)) +->values(array( + 'lid' => '270', + 'location' => 'modules/content_multigroup/content_multigroup.module:272', + 'textgroup' => 'default', + 'source' => 'This change is not allowed. The field %field handles multiple values differently than the Content module. Making this change could result in the loss of data.', + 'version' => 'none', +)) +->values(array( + 'lid' => '271', + 'location' => 'modules/content_multigroup/content_multigroup.module:287', + 'textgroup' => 'default', + 'source' => 'You are moving the field %field into a Multigroup.', + 'version' => 'none', +)) +->values(array( + 'lid' => '272', + 'location' => 'modules/content_multigroup/content_multigroup.module:320', + 'textgroup' => 'default', + 'source' => 'This change is not allowed. The field %field already has data created and uses a widget that stores data differently in a Standard group than in a Multigroup. Making this change could result in the loss of data.', + 'version' => 'none', +)) +->values(array( + 'lid' => '273', + 'location' => 'modules/content_multigroup/content_multigroup.module:334', + 'textgroup' => 'default', + 'source' => 'You are moving the field %field out of a Multigroup.', + 'version' => 'none', +)) +->values(array( + 'lid' => '274', + 'location' => 'modules/content_multigroup/content_multigroup.module:369', + 'textgroup' => 'default', + 'source' => 'Simple', + 'version' => 'none', +)) +->values(array( + 'lid' => '275', + 'location' => 'modules/content_multigroup/content_multigroup.module:370', + 'textgroup' => 'default', + 'source' => 'Fieldset', + 'version' => 'none', +)) +->values(array( + 'lid' => '276', + 'location' => 'modules/content_multigroup/content_multigroup.module:371', + 'textgroup' => 'default', + 'source' => 'Horizontal line', + 'version' => 'none', +)) +->values(array( + 'lid' => '277', + 'location' => 'modules/content_multigroup/content_multigroup.module:372', + 'textgroup' => 'default', + 'source' => 'Table - Single column', + 'version' => 'none', +)) +->values(array( + 'lid' => '278', + 'location' => 'modules/content_multigroup/content_multigroup.module:373', + 'textgroup' => 'default', + 'source' => 'Table - Multiple columns', + 'version' => 'none', +)) +->values(array( + 'lid' => '279', + 'location' => 'modules/content_multigroup/content_multigroup.module:384', + 'textgroup' => 'default', + 'source' => '[Subgroup format]', + 'version' => 'none', +)) +->values(array( + 'lid' => '280', + 'location' => 'modules/content_multigroup/content_multigroup.module:461', + 'textgroup' => 'default', + 'source' => 'Multigroup settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '281', + 'location' => 'modules/content_multigroup/content_multigroup.module:476', + 'textgroup' => 'default', + 'source' => 'Multiple columns', + 'version' => 'none', +)) +->values(array( + 'lid' => '282', + 'location' => 'modules/content_multigroup/content_multigroup.module:478', + 'textgroup' => 'default', + 'source' => 'Enable this option to render each field on a separate column on the node edit form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '283', + 'location' => 'modules/content_multigroup/content_multigroup.module:485', + 'textgroup' => 'default', + 'source' => 'Enable this option to require a minimum of one collection of fields in this Multigroup.', + 'version' => 'none', +)) +->values(array( + 'lid' => '284', + 'location' => 'modules/content_multigroup/content_multigroup.module:488', + 'textgroup' => 'default', + 'source' => 'Number of times to repeat the collection of Multigroup fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '285', + 'location' => 'modules/content_multigroup/content_multigroup.module:489', + 'textgroup' => 'default', + 'source' => "'Unlimited' will provide an 'Add more' button so the users can add items as many times as they like.", + 'version' => 'none', +)) +->values(array( + 'lid' => '286', + 'location' => 'modules/content_multigroup/content_multigroup.module:490', + 'textgroup' => 'default', + 'source' => 'All fields in this group will automatically be set to allow this number of values.', + 'version' => 'none', +)) +->values(array( + 'lid' => '287', + 'location' => 'modules/content_multigroup/content_multigroup.module:495', + 'textgroup' => 'default', + 'source' => 'Number of repeats', + 'version' => 'none', +)) +->values(array( + 'lid' => '288', + 'location' => 'modules/content_multigroup/content_multigroup.module:503', + 'textgroup' => 'default', + 'source' => 'Labels', + 'version' => 'none', +)) +->values(array( + 'lid' => '289', + 'location' => 'modules/content_multigroup/content_multigroup.module:504', + 'textgroup' => 'default', + 'source' => "Labels for each subgroup of fields. Labels can be hidden or shown in various contexts using the 'Display fields' screen.", + 'version' => 'none', +)) +->values(array( + 'lid' => '290', + 'location' => 'modules/content_multigroup/content_multigroup.module:512', + 'textgroup' => 'default', + 'source' => 'Subgroup %number label', + 'version' => 'none', +)) +->values(array( + 'lid' => '291', + 'location' => 'modules/content_multigroup/content_multigroup.module:539', + 'textgroup' => 'default', + 'source' => 'The field %field in this group already has %multiple values in the database. To prevent the loss of data you cannot set the number of Multigroup values to less than this.', + 'version' => 'none', +)) +->values(array( + 'lid' => '292', + 'location' => 'modules/content_multigroup/content_multigroup.module:932', + 'textgroup' => 'default', + 'source' => '!name field is required in group @group.', + 'version' => 'none', +)) +->values(array( + 'lid' => '293', + 'location' => 'modules/content_multigroup/content_multigroup.module:946', + 'textgroup' => 'default', + 'source' => 'Group @name requires one collection of fields minimum.', + 'version' => 'none', +)) +->values(array( + 'lid' => '294', + 'location' => 'modules/content_multigroup/content_multigroup.module:1145', + 'textgroup' => 'default', + 'source' => 'Add more values', + 'version' => 'none', +)) +->values(array( + 'lid' => '295', + 'location' => 'modules/content_multigroup/content_multigroup.module:0', + 'textgroup' => 'default', + 'source' => 'content_multigroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '296', + 'location' => 'modules/content_multigroup/content_multigroup.info:0', + 'textgroup' => 'default', + 'source' => 'Content Multigroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '297', + 'location' => 'modules/content_multigroup/content_multigroup.info:0', + 'textgroup' => 'default', + 'source' => 'Combine multiple CCK fields into repeating field collections that work in unison.', + 'version' => 'none', +)) +->values(array( + 'lid' => '298', + 'location' => 'modules/content_permissions/content_permissions.module:10', + 'textgroup' => 'default', + 'source' => 'edit ', + 'version' => 'none', +)) +->values(array( + 'lid' => '299', + 'location' => 'modules/content_permissions/content_permissions.module:10;11', + 'textgroup' => 'default', + 'source' => 'field_name', + 'version' => 'none', +)) +->values(array( + 'lid' => '300', + 'location' => 'modules/content_permissions/content_permissions.module:11', + 'textgroup' => 'default', + 'source' => 'view ', + 'version' => 'none', +)) +->values(array( + 'lid' => '301', + 'location' => 'modules/content_permissions/content_permissions.module:0', + 'textgroup' => 'default', + 'source' => 'content_permissions', + 'version' => 'none', +)) +->values(array( + 'lid' => '302', + 'location' => 'modules/content_permissions/content_permissions.install:9', + 'textgroup' => 'default', + 'source' => 'Please configure your field permissions immediately. All fields are inaccessible by default.', + 'version' => 'none', +)) +->values(array( + 'lid' => '303', + 'location' => 'modules/content_permissions/content_permissions.info:0', + 'textgroup' => 'default', + 'source' => 'Content Permissions', + 'version' => 'none', +)) +->values(array( + 'lid' => '304', + 'location' => 'modules/content_permissions/content_permissions.info:0', + 'textgroup' => 'default', + 'source' => 'Set field-level permissions for CCK fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '305', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:10;27', + 'textgroup' => 'default', + 'source' => 'Content fieldgroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '306', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:30', + 'textgroup' => 'default', + 'source' => 'All fields from a fieldgroup on the referenced node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '307', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:91', + 'textgroup' => 'default', + 'source' => '@group_label (@group_type_name)', + 'version' => 'none', +)) +->values(array( + 'lid' => '308', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:102, modules/fieldgroup/fieldgroup.info:0', + 'textgroup' => 'default', + 'source' => 'Fieldgroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '309', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:112', + 'textgroup' => 'default', + 'source' => 'Text to display if group has no data. Note that title will not display unless overridden.', + 'version' => 'none', +)) +->values(array( + 'lid' => '310', + 'location' => 'modules/fieldgroup/fieldgroup.panels.inc:128', + 'textgroup' => 'default', + 'source' => '"@s" fieldgroup @name', + 'version' => 'none', +)) +->values(array( + 'lid' => '311', + 'location' => 'modules/fieldgroup/fieldgroup.module:124', + 'textgroup' => 'default', + 'source' => 'Form settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '312', + 'location' => 'modules/fieldgroup/fieldgroup.module:125', + 'textgroup' => 'default', + 'source' => 'These settings apply to the group in the node editing form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '313', + 'location' => 'modules/fieldgroup/fieldgroup.module:129', + 'textgroup' => 'default', + 'source' => 'Style', + 'version' => 'none', +)) +->values(array( + 'lid' => '314', + 'location' => 'modules/fieldgroup/fieldgroup.module:132', + 'textgroup' => 'default', + 'source' => 'always open', + 'version' => 'none', +)) +->values(array( + 'lid' => '315', + 'location' => 'modules/fieldgroup/fieldgroup.module:133', + 'textgroup' => 'default', + 'source' => 'collapsible', + 'version' => 'none', +)) +->values(array( + 'lid' => '316', + 'location' => 'modules/fieldgroup/fieldgroup.module:134', + 'textgroup' => 'default', + 'source' => 'collapsed', + 'version' => 'none', +)) +->values(array( + 'lid' => '317', + 'location' => 'modules/fieldgroup/fieldgroup.module:142', + 'textgroup' => 'default', + 'source' => 'Instructions to present to the user on the editing form.', + 'version' => 'none', +)) +->values(array( + 'lid' => '318', + 'location' => 'modules/fieldgroup/fieldgroup.module:147', + 'textgroup' => 'default', + 'source' => 'Display settings', + 'version' => 'none', +)) +->values(array( + 'lid' => '319', + 'location' => 'modules/fieldgroup/fieldgroup.module:148', + 'textgroup' => 'default', + 'source' => 'These settings apply to the group on node display.', + 'version' => 'none', +)) +->values(array( + 'lid' => '320', + 'location' => 'modules/fieldgroup/fieldgroup.module:155', + 'textgroup' => 'default', + 'source' => 'A description of the group.', + 'version' => 'none', +)) +->values(array( + 'lid' => '321', + 'location' => 'modules/fieldgroup/fieldgroup.module:200', + 'textgroup' => 'default', + 'source' => 'Are you sure you want to remove the group %label?', + 'version' => 'none', +)) +->values(array( + 'lid' => '322', + 'location' => 'modules/fieldgroup/fieldgroup.module:202', + 'textgroup' => 'default', + 'source' => 'This action cannot be undone.', + 'version' => 'none', +)) +->values(array( + 'lid' => '323', + 'location' => 'modules/fieldgroup/fieldgroup.module:211', + 'textgroup' => 'default', + 'source' => 'The group %group_name has been removed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '324', + 'location' => 'modules/fieldgroup/fieldgroup.module:293, modules/nodereference/nodereference.module:544, modules/userreference/userreference.module:439', + 'textgroup' => 'default', + 'source' => 'none', + 'version' => 'none', +)) +->values(array( + 'lid' => '325', + 'location' => 'modules/fieldgroup/fieldgroup.module:353', + 'textgroup' => 'default', + 'source' => 'You need to provide a label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '326', + 'location' => 'modules/fieldgroup/fieldgroup.module:358', + 'textgroup' => 'default', + 'source' => 'You need to provide a group name.', + 'version' => 'none', +)) +->values(array( + 'lid' => '327', + 'location' => 'modules/fieldgroup/fieldgroup.module:372', + 'textgroup' => 'default', + 'source' => 'The group name %group_name is invalid. The name must include only lowercase unaccentuated letters, numbers, and underscores.', + 'version' => 'none', +)) +->values(array( + 'lid' => '328', + 'location' => 'modules/fieldgroup/fieldgroup.module:375', + 'textgroup' => 'default', + 'source' => "The group name %group_name is too long. The name is limited to 32 characters, including the 'group_' prefix.", + 'version' => 'none', +)) +->values(array( + 'lid' => '329', + 'location' => 'modules/fieldgroup/fieldgroup.module:381', + 'textgroup' => 'default', + 'source' => 'The group name %group_name already exists.', + 'version' => 'none', +)) +->values(array( + 'lid' => '330', + 'location' => 'modules/fieldgroup/fieldgroup.module:400;403', + 'textgroup' => 'default', + 'source' => 'Add new group:', + 'version' => 'none', +)) +->values(array( + 'lid' => '331', + 'location' => 'modules/fieldgroup/fieldgroup.module:418', + 'textgroup' => 'default', + 'source' => 'Add new group: you need to provide a label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '332', + 'location' => 'modules/fieldgroup/fieldgroup.module:419', + 'textgroup' => 'default', + 'source' => 'Add new group: you need to provide a group name.', + 'version' => 'none', +)) +->values(array( + 'lid' => '333', + 'location' => 'modules/fieldgroup/fieldgroup.module:648', + 'textgroup' => 'default', + 'source' => 'Standard group', + 'version' => 'none', +)) +->values(array( + 'lid' => '334', + 'location' => 'modules/fieldgroup/fieldgroup.module:39;46', + 'textgroup' => 'default', + 'source' => 'Edit group', + 'version' => 'none', +)) +->values(array( + 'lid' => '335', + 'location' => 'modules/fieldgroup/fieldgroup.module:0', + 'textgroup' => 'default', + 'source' => 'fieldgroup', + 'version' => 'none', +)) +->values(array( + 'lid' => '336', + 'location' => 'modules/fieldgroup/fieldgroup.info:0', + 'textgroup' => 'default', + 'source' => 'Create display groups for CCK fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '337', + 'location' => 'modules/nodereference/nodereference.rules.inc:15', + 'textgroup' => 'default', + 'source' => 'Load a referenced node', + 'version' => 'none', +)) +->values(array( + 'lid' => '338', + 'location' => 'modules/nodereference/nodereference.rules.inc:19', + 'textgroup' => 'default', + 'source' => 'Content containing the node reference field', + 'version' => 'none', +)) +->values(array( + 'lid' => '339', + 'location' => 'modules/nodereference/nodereference.rules.inc:25', + 'textgroup' => 'default', + 'source' => 'Referenced content', + 'version' => 'none', +)) +->values(array( + 'lid' => '340', + 'location' => 'modules/nodereference/nodereference.rules.inc:29', + 'textgroup' => 'default', + 'source' => 'Note that if the field has multiple values, only the first content node will be loaded.', + 'version' => 'none', +)) +->values(array( + 'lid' => '341', + 'location' => 'modules/nodereference/nodereference.rules.inc:50', + 'textgroup' => 'default', + 'source' => 'There are no nodereference fields defined.', + 'version' => 'none', +)) +->values(array( + 'lid' => '342', + 'location' => 'modules/nodereference/nodereference.module:60', + 'textgroup' => 'default', + 'source' => 'Node reference', + 'version' => 'none', +)) +->values(array( + 'lid' => '343', + 'location' => 'modules/nodereference/nodereference.module:61', + 'textgroup' => 'default', + 'source' => 'Store the ID of a related node as an integer value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '344', + 'location' => 'modules/nodereference/nodereference.module:75', + 'textgroup' => 'default', + 'source' => 'Content types that can be referenced', + 'version' => 'none', +)) +->values(array( + 'lid' => '345', + 'location' => 'modules/nodereference/nodereference.module:87, modules/userreference/userreference.module:84', + 'textgroup' => 'default', + 'source' => 'Default Views', + 'version' => 'none', +)) +->values(array( + 'lid' => '346', + 'location' => 'modules/nodereference/nodereference.module:90, modules/userreference/userreference.module:87', + 'textgroup' => 'default', + 'source' => 'Existing Views', + 'version' => 'none', +)) +->values(array( + 'lid' => '347', + 'location' => 'modules/nodereference/nodereference.module:97', + 'textgroup' => 'default', + 'source' => 'Advanced - Nodes that can be referenced (View)', + 'version' => 'none', +)) +->values(array( + 'lid' => '348', + 'location' => 'modules/nodereference/nodereference.module:104', + 'textgroup' => 'default', + 'source' => 'View used to select the nodes', + 'version' => 'none', +)) +->values(array( + 'lid' => '349', + 'location' => 'modules/nodereference/nodereference.module:107', + 'textgroup' => 'default', + 'source' => '

    Choose the "Views module" view that selects the nodes that can be referenced.
    Note:

    ', + 'version' => 'none', +)) +->values(array( + 'lid' => '350', + 'location' => 'modules/nodereference/nodereference.module:108;121', + 'textgroup' => 'default', + 'source' => "
    • Only views that have fields will work for this purpose.
    • This will discard the \"Content types\" settings above. Use the view's \"filters\" section instead.
    • Use the view's \"fields\" section to display additional informations about candidate nodes on node creation/edition form.
    • Use the view's \"sort criteria\" section to determine the order in which candidate nodes will be displayed.
    ", + 'version' => 'none', +)) +->values(array( + 'lid' => '351', + 'location' => 'modules/nodereference/nodereference.module:112, modules/userreference/userreference.module:109', + 'textgroup' => 'default', + 'source' => 'View arguments', + 'version' => 'none', +)) +->values(array( + 'lid' => '352', + 'location' => 'modules/nodereference/nodereference.module:115, modules/userreference/userreference.module:112', + 'textgroup' => 'default', + 'source' => 'Provide a comma separated list of arguments to pass to the view.', + 'version' => 'none', +)) +->values(array( + 'lid' => '353', + 'location' => 'modules/nodereference/nodereference.module:120', + 'textgroup' => 'default', + 'source' => '

    The list of nodes that can be referenced can be based on a "Views module" view but no appropriate views were found.
    Note:

    ', + 'version' => 'none', +)) +->values(array( + 'lid' => '354', + 'location' => 'modules/nodereference/nodereference.module:205, modules/userreference/userreference.module:184', + 'textgroup' => 'default', + 'source' => '%name: invalid input.', + 'version' => 'none', +)) +->values(array( + 'lid' => '355', + 'location' => 'modules/nodereference/nodereference.module:217', + 'textgroup' => 'default', + 'source' => "%name: this post can't be referenced.", + 'version' => 'none', +)) +->values(array( + 'lid' => '356', + 'location' => 'modules/nodereference/nodereference.module:242', + 'textgroup' => 'default', + 'source' => 'Title (link)', + 'version' => 'none', +)) +->values(array( + 'lid' => '357', + 'location' => 'modules/nodereference/nodereference.module:247', + 'textgroup' => 'default', + 'source' => 'Title (no link)', + 'version' => 'none', +)) +->values(array( + 'lid' => '358', + 'location' => 'modules/nodereference/nodereference.module:303, modules/optionwidgets/optionwidgets.module:62, modules/userreference/userreference.module:198', + 'textgroup' => 'default', + 'source' => 'Select list', + 'version' => 'none', +)) +->values(array( + 'lid' => '359', + 'location' => 'modules/optionwidgets/optionwidgets.module:70', + 'textgroup' => 'default', + 'source' => 'Check boxes/radio buttons', + 'version' => 'none', +)) +->values(array( + 'lid' => '360', + 'location' => 'modules/nodereference/nodereference.module:311, modules/userreference/userreference.module:206', + 'textgroup' => 'default', + 'source' => 'Autocomplete text field', + 'version' => 'none', +)) +->values(array( + 'lid' => '361', + 'location' => 'modules/nodereference/nodereference.module:417, modules/userreference/userreference.module:343', + 'textgroup' => 'default', + 'source' => 'Autocomplete matching', + 'version' => 'none', +)) +->values(array( + 'lid' => '362', + 'location' => 'modules/nodereference/nodereference.module:420, modules/userreference/userreference.module:346', + 'textgroup' => 'default', + 'source' => 'Starts with', + 'version' => 'none', +)) +->values(array( + 'lid' => '363', + 'location' => 'modules/nodereference/nodereference.module:421, modules/userreference/userreference.module:347', + 'textgroup' => 'default', + 'source' => 'Contains', + 'version' => 'none', +)) +->values(array( + 'lid' => '364', + 'location' => 'modules/nodereference/nodereference.module:423', + 'textgroup' => 'default', + 'source' => 'Select the method used to collect autocomplete suggestions. Note that Contains can cause performance issues on sites with thousands of nodes.', + 'version' => 'none', +)) +->values(array( + 'lid' => '365', + 'location' => 'modules/nodereference/nodereference.module:671', + 'textgroup' => 'default', + 'source' => '%name: title mismatch. Please check your selection.', + 'version' => 'none', +)) +->values(array( + 'lid' => '366', + 'location' => 'modules/nodereference/nodereference.module:678', + 'textgroup' => 'default', + 'source' => '%name: found no valid post with that title.', + 'version' => 'none', +)) +->values(array( + 'lid' => '367', + 'location' => 'modules/nodereference/nodereference.module:15', + 'textgroup' => 'default', + 'source' => 'Nodereference autocomplete', + 'version' => 'none', +)) +->values(array( + 'lid' => '368', + 'location' => 'modules/nodereference/nodereference.module:0', + 'textgroup' => 'default', + 'source' => 'nodereference', + 'version' => 'none', +)) +->values(array( + 'lid' => '369', + 'location' => 'modules/nodereference/nodereference.info:0', + 'textgroup' => 'default', + 'source' => 'Node Reference', + 'version' => 'none', +)) +->values(array( + 'lid' => '370', + 'location' => 'modules/nodereference/nodereference.info:0', + 'textgroup' => 'default', + 'source' => 'Defines a field type for referencing one node from another.', + 'version' => 'none', +)) +->values(array( + 'lid' => '371', + 'location' => 'modules/number/number.module:41', + 'textgroup' => 'default', + 'source' => 'Integer', + 'version' => 'none', +)) +->values(array( + 'lid' => '372', + 'location' => 'modules/number/number.module:42', + 'textgroup' => 'default', + 'source' => 'Store a number in the database as an integer.', + 'version' => 'none', +)) +->values(array( + 'lid' => '373', + 'location' => 'modules/number/number.module:49', + 'textgroup' => 'default', + 'source' => 'Decimal', + 'version' => 'none', +)) +->values(array( + 'lid' => '374', + 'location' => 'modules/number/number.module:50', + 'textgroup' => 'default', + 'source' => 'Store a number in the database in a fixed decimal format.', + 'version' => 'none', +)) +->values(array( + 'lid' => '375', + 'location' => 'modules/number/number.module:57', + 'textgroup' => 'default', + 'source' => 'Float', + 'version' => 'none', +)) +->values(array( + 'lid' => '376', + 'location' => 'modules/number/number.module:58', + 'textgroup' => 'default', + 'source' => 'Store a number in the database in a floating point format.', + 'version' => 'none', +)) +->values(array( + 'lid' => '377', + 'location' => 'modules/number/number.module:76', + 'textgroup' => 'default', + 'source' => 'Minimum', + 'version' => 'none', +)) +->values(array( + 'lid' => '378', + 'location' => 'modules/number/number.module:81', + 'textgroup' => 'default', + 'source' => 'Maximum', + 'version' => 'none', +)) +->values(array( + 'lid' => '379', + 'location' => 'modules/number/number.module:88', + 'textgroup' => 'default', + 'source' => 'Precision', + 'version' => 'none', +)) +->values(array( + 'lid' => '380', + 'location' => 'modules/number/number.module:89', + 'textgroup' => 'default', + 'source' => 'The total number of digits to store in the database, including those to the right of the decimal.', + 'version' => 'none', +)) +->values(array( + 'lid' => '381', + 'location' => 'modules/number/number.module:95', + 'textgroup' => 'default', + 'source' => 'Scale', + 'version' => 'none', +)) +->values(array( + 'lid' => '382', + 'location' => 'modules/number/number.module:96', + 'textgroup' => 'default', + 'source' => 'The number of digits to the right of the decimal.', + 'version' => 'none', +)) +->values(array( + 'lid' => '383', + 'location' => 'modules/number/number.module:102', + 'textgroup' => 'default', + 'source' => 'Decimal marker', + 'version' => 'none', +)) +->values(array( + 'lid' => '384', + 'location' => 'modules/number/number.module:103', + 'textgroup' => 'default', + 'source' => 'The character users will input to mark the decimal point in forms.', + 'version' => 'none', +)) +->values(array( + 'lid' => '385', + 'location' => 'modules/number/number.module:109', + 'textgroup' => 'default', + 'source' => 'Prefix', + 'version' => 'none', +)) +->values(array( + 'lid' => '386', + 'location' => 'modules/number/number.module:112', + 'textgroup' => 'default', + 'source' => 'Define a string that should be prefixed to the value, like $ or €. Leave blank for none. Separate singular and plural values with a pipe (pound|pounds).', + 'version' => 'none', +)) +->values(array( + 'lid' => '387', + 'location' => 'modules/number/number.module:116', + 'textgroup' => 'default', + 'source' => 'Suffix', + 'version' => 'none', +)) +->values(array( + 'lid' => '388', + 'location' => 'modules/number/number.module:119', + 'textgroup' => 'default', + 'source' => 'Define a string that should suffixed to the value, like m², m/s², kb/s. Leave blank for none. Separate singular and plural values with a pipe (pound|pounds).', + 'version' => 'none', +)) +->values(array( + 'lid' => '389', + 'location' => 'modules/number/number.module:123 modules/text/text.module:82', + 'textgroup' => 'default', + 'source' => 'Allowed values', + 'version' => 'none', +)) +->values(array( + 'lid' => '390', + 'location' => 'examples/example_field.php:174 modules/number/number.module:129, modules/text/text.module:88', + 'textgroup' => 'default', + 'source' => 'Allowed values list', + 'version' => 'none', +)) +->values(array( + 'lid' => '391', + 'location' => 'modules/number/number.module:116, modules/text/text.module:81', + 'textgroup' => 'default', + 'source' => 'The possible values this field can contain. Enter one value per line, in the format key|label. The key is the value that will be stored in the database, and it must match the field storage type (%type). The label is optional, and the key will be used as the label if no label is specified.
    Allowed HTML tags: @tags', + 'version' => 'none', +)) +->values(array( + 'lid' => '392', + 'location' => 'examples/example_field.php:191 modules/number/number.module:147, modules/text/text.module:106', + 'textgroup' => 'default', + 'source' => 'Advanced usage only: PHP code that returns a keyed array of allowed values. Should not include <?php ?> delimiters. If this field is filled out, the array returned by this code will override the allowed values list above.', + 'version' => 'none', +)) +->values(array( + 'lid' => '393', + 'location' => 'modules/number/number.module:155 modules/text/text.module:114', + 'textgroup' => 'default', + 'source' => 'This PHP code was set by an administrator and will override the allowed values list above.', + 'version' => 'none', +)) +->values(array( + 'lid' => '394', + 'location' => 'modules/number/number.module:178, modules/text/text.module:132', + 'textgroup' => 'default', + 'source' => '@label (!name) - Allowed values', + 'version' => 'none', +)) +->values(array( + 'lid' => '395', + 'location' => 'modules/number/number.module:162', + 'textgroup' => 'default', + 'source' => '"Minimum" must be a number.', + 'version' => 'none', +)) +->values(array( + 'lid' => '396', + 'location' => 'modules/number/number.module:165', + 'textgroup' => 'default', + 'source' => '"Maximum" must be a number.', + 'version' => 'none', +)) +->values(array( + 'lid' => '397', + 'location' => 'modules/number/number.module:219', + 'textgroup' => 'default', + 'source' => '%name: the value may be no smaller than %min.', + 'version' => 'none', +)) +->values(array( + 'lid' => '398', + 'location' => 'modules/number/number.module:222', + 'textgroup' => 'default', + 'source' => '%name: the value may be no larger than %max.', + 'version' => 'none', +)) +->values(array( + 'lid' => '399', + 'location' => 'modules/number/number.module:235, modules/text/text.module:156', + 'textgroup' => 'default', + 'source' => '%name: illegal value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '400', + 'location' => 'modules/number/number.module:263', + 'textgroup' => 'default', + 'source' => 'unformatted', + 'version' => 'none', +)) +->values(array( + 'lid' => '401', + 'location' => 'examples/example_field.php:476 examples/simple_field.php:400, modules/number/number.module:342 modules/text/text.module:264', + 'textgroup' => 'default', + 'source' => 'Text field', + 'version' => 'none', +)) +->values(array( + 'lid' => '402', + 'location' => 'modules/number/number.module:512', + 'textgroup' => 'default', + 'source' => 'Only numbers and decimals are allowed in %field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '403', + 'location' => 'modules/number/number.module:535', + 'textgroup' => 'default', + 'source' => 'Only numbers are allowed in %field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '404', + 'location' => 'modules/number/number.module:559', + 'textgroup' => 'default', + 'source' => 'Only numbers and the decimal character (%decimal) are allowed in %field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '405', + 'location' => 'modules/number/number.module:0', + 'textgroup' => 'default', + 'source' => 'number', + 'version' => 'none', +)) +->values(array( + 'lid' => '406', + 'location' => 'modules/number/number.info:0', + 'textgroup' => 'default', + 'source' => 'Number', + 'version' => 'none', +)) +->values(array( + 'lid' => '407', + 'location' => 'modules/number/number.info:0', + 'textgroup' => 'default', + 'source' => 'Defines numeric field types.', + 'version' => 'none', +)) +->values(array( + 'lid' => '408', + 'location' => 'modules/optionwidgets/optionwidgets.module:19', + 'textgroup' => 'default', + 'source' => 'Create a list of options as a list in Allowed values list or as an array in PHP code. These values will be the same for %field in all content types.', + 'version' => 'none', +)) +->values(array( + 'lid' => '409', + 'location' => 'modules/optionwidgets/optionwidgets.module:12', + 'textgroup' => 'default', + 'source' => "For a 'single on/off checkbox' widget, define the 'off' value first, then the 'on' value in the Allowed values section. Note that the checkbox will be labeled with the label of the 'on' value.", + 'version' => 'none', +)) +->values(array( + 'lid' => '410', + 'location' => 'modules/optionwidgets/optionwidgets.module:15', + 'textgroup' => 'default', + 'source' => "The 'checkboxes/radio buttons' widget will display checkboxes if the multiple values option is selected for this field, otherwise radios will be displayed.", + 'version' => 'none', +)) +->values(array( + 'lid' => '411', + 'location' => 'modules/optionwidgets/optionwidgets.module:37', + 'textgroup' => 'default', + 'source' => "You need to specify the 'allowed values' for this field.", + 'version' => 'none', +)) +->values(array( + 'lid' => '412', + 'location' => 'modules/optionwidgets/optionwidgets.module:78', + 'textgroup' => 'default', + 'source' => 'Single on/off checkbox', + 'version' => 'none', +)) +->values(array( + 'lid' => '413', + 'location' => 'modules/optionwidgets/optionwidgets.module:331', + 'textgroup' => 'default', + 'source' => '%name: this field cannot hold more that @count values.', + 'version' => 'none', +)) +->values(array( + 'lid' => '414', + 'location' => 'modules/optionwidgets/optionwidgets.module:364', + 'textgroup' => 'default', + 'source' => 'N/A', + 'version' => 'none', +)) +->values(array( + 'lid' => '415', + 'location' => 'modules/optionwidgets/optionwidgets.module:420', + 'textgroup' => 'default', + 'source' => '- None -', + 'version' => 'none', +)) +->values(array( + 'lid' => '416', + 'location' => 'modules/optionwidgets/optionwidgets.module:0', + 'textgroup' => 'default', + 'source' => 'optionwidgets', + 'version' => 'none', +)) +->values(array( + 'lid' => '417', + 'location' => 'modules/optionwidgets/optionwidgets.info:0', + 'textgroup' => 'default', + 'source' => 'Option Widgets', + 'version' => 'none', +)) +->values(array( + 'lid' => '418', + 'location' => 'modules/optionwidgets/optionwidgets.info:0', + 'textgroup' => 'default', + 'source' => 'Defines selection, check box and radio button widgets for text and numeric fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '419', + 'location' => 'modules/text/text.module:50', + 'textgroup' => 'default', + 'source' => 'Store text in the database.', + 'version' => 'none', +)) +->values(array( + 'lid' => '420', + 'location' => 'examples/example_field.php:158;388 examples/simple_field.php:332, modules/text/text.module:66;209, modules/userreference/userreference.module:151', + 'textgroup' => 'default', + 'source' => 'Plain text', + 'version' => 'none', +)) +->values(array( + 'lid' => '421', + 'location' => 'examples/example_field.php:158 modules/text/text.module:66', + 'textgroup' => 'default', + 'source' => 'Filtered text (user selects input format)', + 'version' => 'none', +)) +->values(array( + 'lid' => '422', + 'location' => 'examples/example_field.php:161 modules/text/text.module:69', + 'textgroup' => 'default', + 'source' => 'Text processing', + 'version' => 'none', +)) +->values(array( + 'lid' => '423', + 'location' => 'examples/example_field.php:167 examples/simple_field.php:164, modules/text/text.module:75', + 'textgroup' => 'default', + 'source' => 'Maximum length', + 'version' => 'none', +)) +->values(array( + 'lid' => '424', + 'location' => 'examples/example_field.php:170 examples/simple_field.php:167, modules/text/text.module:78', + 'textgroup' => 'default', + 'source' => 'The maximum length of the field in characters. Leave blank for an unlimited size.', + 'version' => 'none', +)) +->values(array( + 'lid' => '425', + 'location' => 'modules/text/text.module:159', + 'textgroup' => 'default', + 'source' => '%name: the value may not be longer than %max characters.', + 'version' => 'none', +)) +->values(array( + 'lid' => '426', + 'location' => 'examples/example_field.php:383 examples/simple_field.php:327, modules/text/text.module:204 modules/userreference/userreference.module:146', + 'textgroup' => 'default', + 'source' => 'Default', + 'version' => 'none', +)) +->values(array( + 'lid' => '427', + 'location' => 'examples/example_field.php:393 modules/text/text.module:214', + 'textgroup' => 'default', + 'source' => 'Trimmed', + 'version' => 'none', +)) +->values(array( + 'lid' => '428', + 'location' => 'modules/text/text.module:272', + 'textgroup' => 'default', + 'source' => 'Text area (multiple rows)', + 'version' => 'none', +)) +->values(array( + 'lid' => '429', + 'location' => 'modules/text/text.module:316', + 'textgroup' => 'default', + 'source' => 'Size of textfield', + 'version' => 'none', +)) +->values(array( + 'lid' => '430', + 'location' => 'examples/example_field.php:551 examples/simple_field.php:430, modules/text/text.module:324', + 'textgroup' => 'default', + 'source' => 'Rows', + 'version' => 'none', +)) +->values(array( + 'lid' => '431', + 'location' => 'modules/text/text.module:0', + 'textgroup' => 'default', + 'source' => 'text', + 'version' => 'none', +)) +->values(array( + 'lid' => '432', + 'location' => 'modules/text/text.info:0', + 'textgroup' => 'default', + 'source' => 'Defines simple text field types.', + 'version' => 'none', +)) +->values(array( + 'lid' => '433', + 'location' => 'modules/userreference/userreference.rules.inc:15', + 'textgroup' => 'default', + 'source' => 'Load a referenced user', + 'version' => 'none', +)) +->values(array( + 'lid' => '434', + 'location' => 'modules/userreference/userreference.rules.inc:19', + 'textgroup' => 'default', + 'source' => 'Content containing the user reference field', + 'version' => 'none', +)) +->values(array( + 'lid' => '435', + 'location' => 'modules/userreference/userreference.rules.inc:25', + 'textgroup' => 'default', + 'source' => 'Referenced user', + 'version' => 'none', +)) +->values(array( + 'lid' => '436', + 'location' => 'modules/userreference/userreference.rules.inc:29', + 'textgroup' => 'default', + 'source' => 'Note that if the field has multiple values, only the first user will be loaded.', + 'version' => 'none', +)) +->values(array( + 'lid' => '437', + 'location' => 'modules/userreference/userreference.rules.inc:52', + 'textgroup' => 'default', + 'source' => 'There are no userreference fields defined.', + 'version' => 'none', +)) +->values(array( + 'lid' => '438', + 'location' => 'modules/userreference/userreference.module:52', + 'textgroup' => 'default', + 'source' => 'User reference', + 'version' => 'none', +)) +->values(array( + 'lid' => '439', + 'location' => 'modules/userreference/userreference.module:53', + 'textgroup' => 'default', + 'source' => 'Store the ID of a related user as an integer value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '440', + 'location' => 'modules/userreference/userreference.module:67', + 'textgroup' => 'default', + 'source' => 'User roles that can be referenced', + 'version' => 'none', +)) +->values(array( + 'lid' => '441', + 'location' => 'modules/userreference/userreference.module:73', + 'textgroup' => 'default', + 'source' => 'User status that can be referenced', + 'version' => 'none', +)) +->values(array( + 'lid' => '442', + 'location' => 'modules/userreference/userreference.module:75', + 'textgroup' => 'default', + 'source' => 'Active', + 'version' => 'none', +)) +->values(array( + 'lid' => '443', + 'location' => 'modules/userreference/userreference.module:75', + 'textgroup' => 'default', + 'source' => 'Blocked', + 'version' => 'none', +)) +->values(array( + 'lid' => '444', + 'location' => 'modules/userreference/userreference.module:94', + 'textgroup' => 'default', + 'source' => 'Advanced - Users that can be referenced (View)', + 'version' => 'none', +)) +->values(array( + 'lid' => '445', + 'location' => 'modules/userreference/userreference.module:101', + 'textgroup' => 'default', + 'source' => 'View used to select the users', + 'version' => 'none', +)) +->values(array( + 'lid' => '446', + 'location' => 'modules/userreference/userreference.module:104', + 'textgroup' => 'default', + 'source' => '

    Choose the "Views module" view that selects the users that can be referenced.
    Note:

    ', + 'version' => 'none', +)) +->values(array( + 'lid' => '447', + 'location' => 'modules/userreference/userreference.module:105;118', + 'textgroup' => 'default', + 'source' => "
    • Only views that have fields will work for this purpose.
    • This will discard the \"Referenceable Roles\" and \"Referenceable Status\" settings above. Use the view's \"filters\" section instead.
    • Use the view's \"fields\" section to display additional informations about candidate users on user creation/edition form.
    • Use the view's \"sort criteria\" section to determine the order in which candidate users will be displayed.
    ", + 'version' => 'none', +)) +->values(array( + 'lid' => '448', + 'location' => 'modules/userreference/userreference.module:117', + 'textgroup' => 'default', + 'source' => '

    The list of user that can be referenced can be based on a "Views module" view but no appropriate views were found.
    Note:

    ', + 'version' => 'none', +)) +->values(array( + 'lid' => '449', + 'location' => 'modules/userreference/userreference.module:196', + 'textgroup' => 'default', + 'source' => '%name: invalid user.', + 'version' => 'none', +)) +->values(array( + 'lid' => '450', + 'location' => 'modules/userreference/userreference.module:349', + 'textgroup' => 'default', + 'source' => 'Select the method used to collect autocomplete suggestions. Note that Contains can cause performance issues on sites with thousands of users.', + 'version' => 'none', +)) +->values(array( + 'lid' => '451', + 'location' => 'modules/userreference/userreference.module:357', + 'textgroup' => 'default', + 'source' => 'Reverse link', + 'version' => 'none', +)) +->values(array( + 'lid' => '452', + 'location' => 'modules/userreference/userreference.module:359', + 'textgroup' => 'default', + 'source' => 'If selected, a reverse link back to the referencing node will displayed on the referenced user record.', + 'version' => 'none', +)) +->values(array( + 'lid' => '453', + 'location' => 'modules/userreference/userreference.module:594', + 'textgroup' => 'default', + 'source' => '%name: found no valid user with that name.', + 'version' => 'none', +)) +->values(array( + 'lid' => '454', + 'location' => 'modules/userreference/userreference.module:887', + 'textgroup' => 'default', + 'source' => 'Related content', + 'version' => 'none', +)) +->values(array( + 'lid' => '455', + 'location' => 'modules/userreference/userreference.module:15', + 'textgroup' => 'default', + 'source' => 'Userreference autocomplete', + 'version' => 'none', +)) +->values(array( + 'lid' => '456', + 'location' => 'modules/userreference/userreference.module:0', + 'textgroup' => 'default', + 'source' => 'userreference', + 'version' => 'none', +)) +->values(array( + 'lid' => '457', + 'location' => 'modules/userreference/userreference.info:0', + 'textgroup' => 'default', + 'source' => 'User Reference', + 'version' => 'none', +)) +->values(array( + 'lid' => '458', + 'location' => 'modules/userreference/userreference.info:0', + 'textgroup' => 'default', + 'source' => 'Defines a field type for referencing a user from a node.', + 'version' => 'none', +)) +->values(array( + 'lid' => '459', + 'location' => 'includes/content.admin.inc:212', + 'textgroup' => 'default', + 'source' => 'Weight', + 'version' => 'none', +)) +->values(array( + 'lid' => '460', + 'location' => 'theme/content-admin-field-overview-form.tpl.php:53', + 'textgroup' => 'default', + 'source' => 'Add', + 'version' => 'none', +)) +->values(array( + 'lid' => '461', + 'location' => 'theme/content-admin-field-overview-form.tpl.php:59', + 'textgroup' => 'default', + 'source' => 'New field', + 'version' => 'none', +)) +->values(array( + 'lid' => '462', + 'location' => 'theme/content-admin-field-overview-form.tpl.php:72', + 'textgroup' => 'default', + 'source' => 'Existing field', + 'version' => 'none', +)) +->values(array( + 'lid' => '463', + 'location' => 'theme/content-admin-field-overview-form.tpl.php:84', + 'textgroup' => 'default', + 'source' => 'New group', + 'version' => 'none', +)) +->values(array( + 'lid' => '464', + 'location' => 'theme/theme.inc:11', + 'textgroup' => 'default', + 'source' => 'Add fields and groups to the content type, and arrange them on content display and input forms.', + 'version' => 'none', +)) +->values(array( + 'lid' => '465', + 'location' => 'theme/theme.inc:13', + 'textgroup' => 'default', + 'source' => 'You can add a field to a group by dragging it below and to the right of the group.', + 'version' => 'none', +)) +->values(array( + 'lid' => '466', + 'location' => 'theme/theme.inc:16', + 'textgroup' => 'default', + 'source' => 'Note: Installing the Advanced help module will let you access more and better help.', + 'version' => 'none', +)) +->values(array( + 'lid' => '467', + 'location' => 'theme/theme.inc:116', + 'textgroup' => 'default', + 'source' => "Use the 'Exclude' checkbox to exclude an item from the !content value passed to the node template.", + 'version' => 'none', +)) +->values(array( + 'lid' => '468', + 'location' => 'theme/content-edit.js:0', + 'textgroup' => 'default', + 'source' => 'Remove this item', + 'version' => 'none', +)) +->values(array( + 'lid' => '469', + 'location' => 'content.module:156 includes/content.admin.inc:528', + 'textgroup' => 'default', + 'source' => 'Add field', + 'version' => 'none', +)) +->values(array( + 'lid' => '470', + 'location' => 'examples/example_field.php:278 modules/number/number.module:228, modules/text/text.module:160', + 'textgroup' => 'default', + 'source' => 'Illegal value for %name.', + 'version' => 'none', +)) +->values(array( + 'lid' => '471', + 'location' => 'examples/example_field.php:287 examples/simple_field.php:231, modules/text/text.module:169', + 'textgroup' => 'default', + 'source' => '%label is longer than %max characters.', + 'version' => 'none', +)) +->values(array( + 'lid' => '472', + 'location' => 'examples/example_field.php:560 examples/simple_field.php:438, modules/text/text.module:333', + 'textgroup' => 'default', + 'source' => '"Rows" must be a positive integer.', + 'version' => 'none', +)) +->values(array( + 'lid' => '473', + 'location' => 'modules/number/number.module:133 modules/text/text.module:92', + 'textgroup' => 'default', + 'source' => 'The possible values this field can contain. Enter one value per line, in the format key|label. The key is the value that will be stored in the database and it must match the field storage type, %type. The label is optional and the key will be used as the label if no label is specified.
    Allowed HTML tags: @tags', + 'version' => 'none', +)) +->values(array( + 'lid' => '474', + 'location' => 'includes/content.admin.inc:33', + 'textgroup' => 'default', + 'source' => 'add field', + 'version' => 'none', +)) +->values(array( + 'lid' => '475', + 'location' => 'includes/content.admin.inc:112;291', + 'textgroup' => 'default', + 'source' => 'There are no fields configured for this content type. You can !link.', + 'version' => 'none', +)) +->values(array( + 'lid' => '476', + 'location' => 'includes/content.admin.inc:113;292', + 'textgroup' => 'default', + 'source' => 'Add a new field', + 'version' => 'none', +)) +->values(array( + 'lid' => '477', + 'location' => 'includes/content.admin.inc:137', + 'textgroup' => 'default', + 'source' => 'To change the order of a field, grab a drag-and-drop handle under the Label column and drag the field to a new location in the list. (Grab a handle by clicking and holding the mouse while hovering over a handle icon.) Remember that your changes will not be saved until you click the Save button at the bottom of the page.', + 'version' => 'none', +)) +->values(array( + 'lid' => '478', + 'location' => 'includes/content.admin.inc:477', + 'textgroup' => 'default', + 'source' => 'No field modules are enabled. You need to enable one, such as text.module, before you can add new fields.', + 'version' => 'none', +)) +->values(array( + 'lid' => '479', + 'location' => 'includes/content.admin.inc:519', + 'textgroup' => 'default', + 'source' => 'Add existing field', + 'version' => 'none', +)) +->values(array( + 'lid' => '480', + 'location' => 'includes/content.admin.inc:590', + 'textgroup' => 'default', + 'source' => 'Create new field', + 'version' => 'none', +)) +->values(array( + 'lid' => '481', + 'location' => 'includes/content.admin.inc:606', + 'textgroup' => 'default', + 'source' => 'The machine-readable name of the field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '482', + 'location' => 'includes/content.admin.inc:610', + 'textgroup' => 'default', + 'source' => 'This name cannot be changed.', + 'version' => 'none', +)) +->values(array( + 'lid' => '483', + 'location' => 'includes/content.admin.inc:618', + 'textgroup' => 'default', + 'source' => "This name cannot be changed later! The name will be prefixed with 'field_' and can include lowercase unaccented letters, numbers, and underscores. The length of the name, including the prefix, is limited to no more than 32 letters.", + 'version' => 'none', +)) +->values(array( + 'lid' => '484', + 'location' => 'includes/content.admin.inc:636', + 'textgroup' => 'default', + 'source' => 'The type of data you would like to store in the database with this field.', + 'version' => 'none', +)) +->values(array( + 'lid' => '485', + 'location' => 'includes/content.admin.inc:692', + 'textgroup' => 'default', + 'source' => 'The field name %field_name is invalid. The name must include only lowercase unaccentuated letters, numbers, and underscores.', + 'version' => 'none', +)) +->values(array( + 'lid' => '486', + 'location' => 'includes/content.admin.inc:695', + 'textgroup' => 'default', + 'source' => "The field name %field_name is too long. The name is limited to 32 characters, including the 'field_' prefix.", + 'version' => 'none', +)) +->values(array( + 'lid' => '487', + 'location' => 'includes/content.admin.inc:706', + 'textgroup' => 'default', + 'source' => 'The field name %field_name already exists.', + 'version' => 'none', +)) +->values(array( + 'lid' => '488', + 'location' => 'includes/content.admin.inc:709', + 'textgroup' => 'default', + 'source' => "The name 'field_instance' is a reserved name.", + 'version' => 'none', +)) +->values(array( + 'lid' => '489', + 'location' => 'includes/content.admin.inc:741', + 'textgroup' => 'default', + 'source' => 'Created field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '490', + 'location' => 'includes/content.admin.inc:754', + 'textgroup' => 'default', + 'source' => 'Update field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '491', + 'location' => 'includes/content.admin.inc:758', + 'textgroup' => 'default', + 'source' => 'There was a problem updating field %label.', + 'version' => 'none', +)) +->values(array( + 'lid' => '492', + 'location' => 'includes/content.admin.inc:955', + 'textgroup' => 'default', + 'source' => "Advanced usage only: PHP code that returns a default value. Should not include <?php ?> delimiters. If this field is filled out, the value returned by this code will override any value specified above. Expected format:
    !sample
    Using !link_devel's 'devel load' tab on a %type content page might help you figure out the expected format.", + 'version' => 'none', +)) +->values(array( + 'lid' => '493', + 'location' => 'includes/content.admin.inc:986', + 'textgroup' => 'default', + 'source' => "Select a specific number of values for this field, or 'Unlimited' to provide an 'Add more' button so the users can add as many values as they like.", + 'version' => 'none', +)) +->values(array( + 'lid' => '494', + 'location' => 'includes/content.admin.inc:1131', + 'textgroup' => 'default', + 'source' => 'The default value PHP code created @value which is invalid.', + 'version' => 'none', +)) +->values(array( + 'lid' => '495', + 'location' => 'includes/content.token.inc:62', + 'textgroup' => 'default', + 'source' => 'Formatted HTML link to the node', + 'version' => 'none', +)) +->values(array( + 'lid' => '496', + 'location' => 'modules/number/number.module:222', + 'textgroup' => 'default', + 'source' => 'The value of %name may be no smaller than %min.', + 'version' => 'none', +)) +->values(array( + 'lid' => '497', + 'location' => 'modules/number/number.module:225', + 'textgroup' => 'default', + 'source' => 'The value of %name may be no larger than %max.', + 'version' => 'none', +)) +->values(array( + 'lid' => '498', + 'location' => 'modules/number/number.module:476', + 'textgroup' => 'default', + 'source' => 'Only numbers and decimals are allowed in %field. %start was changed to %value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '499', + 'location' => 'modules/number/number.module:494', + 'textgroup' => 'default', + 'source' => 'Only numbers are allowed in %field. %start was changed to %value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '500', + 'location' => 'modules/number/number.module:513', + 'textgroup' => 'default', + 'source' => 'Only numbers and the decimal character (%decimal) are allowed in %field. %start was changed to %value.', + 'version' => 'none', +)) +->values(array( + 'lid' => '501', + 'location' => 'modules/optionwidgets/optionwidgets.module:10', + 'textgroup' => 'default', + 'source' => 'Create a list of options as a list in Allowed values or as an array in PHP code. These values will be the same for %field in all content types.', + 'version' => 'none', +)) +->values(array( + 'lid' => '502', + 'location' => 'misc/tabledrag.js', + 'textgroup' => 'default', + 'source' => 'Drag to re-order', + 'version' => 'none', +)) +->values(array( + 'lid' => '503', + 'location' => 'misc/tabledrag.js', + 'textgroup' => 'default', + 'source' => 'Changes made in this table will not be saved until the form is submitted.', + 'version' => 'none', +)) +->execute(); + +$connection->schema()->createTable('locales_target', array( + 'fields' => array( + 'lid' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'translation' => array( + 'type' => 'blob', + 'not null' => TRUE, + 'size' => 'normal', + ), + 'language' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '12', + 'default' => '', + ), + 'plid' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'plural' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + ), + 'primary key' => array( + 'language', + 'lid', + 'plural', + ), + 'indexes' => array( + 'lid' => array( + 'lid', + ), + 'plid' => array( + 'plid', + ), + 'plural' => array( + 'plural', + ), + ), + 'mysql_character_set' => 'utf8', +)); + +$connection->insert('locales_target') +->fields(array( + 'lid', + 'translation', + 'language', + 'plid', + 'plural', +)) +->values(array( + 'lid' => '5', + 'translation' => "Le module Content, composant obligatoire du kit CCK (Content Construction Kit) permet aux administrateurs d'associer des champs personnalisés à des types de contenus. Au sein de Drupal, les types de contenus servent à définir les caractéristiques d'une publication, y compris le titre et la description des champs affichés sur ses pages \"ajouter\" et \"éditer\". Le module Content (et les modules auxiliaires inclus dans CCK) permet d'ajouter des champs personnalisés en plus des champs par défaut \"Titre\" et \"Corps\". Les fonctionnalités de CCK sont accessible via différents onglets sur la page d'administration des types de contenus. (Voir la page d'aide du module Node pour plus d'informations sur les types de contenus).", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '6', + 'translation' => "Lorsque vous ajoutez un champ personnalisé à un type de contenu, vous déterminez son type (c'est-à-dire s'il doit contenir du texte, des nombres ou des références à d'autres objets) et la façon dont il doit être affiché (en tant que champ ou zone de texte, liste de sélection, case à cocher, bouton radio, ou champ à auto-complètement). Un champ peut présenter plusieurs valeurs (par exemple, une \"personne\" peut disposer de plusieurs adresses courriel) ou une seule (par exemple, un \"employé\" possède un numéro d'identification unique). À mesure que vous ajoutez et modifiez des champs, CCK ajuste automatiquement la structure de la base de données en fonction. CCK propose également un certain nombre d'autres fonctionnalités, par exemple un cache intelligent pour vos données personnalisées, des fonctionnalités d'import et d'export pour les définitions de types de contenus, ainsi qu'une intégration à d'autres modules provenant des contributions.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '7', + 'translation' => "Des types de champs personnalisés sont proposés par plusieurs modules optionnels inclus dans CCK (chaque module fournissant un type différent). La page des modules vous permet d'activer ou de désactiver des composants CCK. Une installation par défaut de CCK inclut :", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '8', + 'translation' => "Number, qui ajoute des types de champs numériques (formats entier, décimal ou réel à virgule flottante). Vous pouvez définir un jeu ou un intervalle de valeurs autorisées. Divers formats sont disponibles pour l'affichage des données numériques.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '9', + 'translation' => "Text, qui ajoute des types de champs de texte. Un champ texte peut contenir du texte brut uniquement ou, optionnellement, utiliser les filtres des formats d'entrée que propose Drupal pour gérer en toute sécurité des textes enrichis. Les champs de saisie de texte peuvent être constitués d'une seule ligne (champ texte), de plusieurs lignes (zone de texte) ou, pour un meilleur contrôle des valeurs saisies, une liste de sélection, des cases à cocher ou des boutons radio. Si besoin, CCK peut valider les saisies sur la base d'un ensemble de valeurs autorisées.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '10', + 'translation' => 'Node Reference, qui crée des références personnalisées entre nœuds de Drupal. En ajoutant, par exemple, un champ nodereference et deux types de contenus différents, vous pouvez facilement créer des relations complexes de type parent/enfant entre données (par exemple plusieurs nœuds "employé" peuvent présenter un champ nodereference pointant vers un même nœud "employeur").', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '11', + 'translation' => "User reference, qui crée des références personnalisées vers les comptes des utilisateurs de votre site. En ajoutant un champ userreference, vous pouvez créer des relations complexes entre les utilisateurs de votre site et des publications. Ainsi, pour tracer l'implication d'un utilisateur dans une publication (au delà du champ Drupal standard Écrit par), vous pouvez ajouter à un type de contenu un champ userreference intitulé \"Édité par\" pour enregistrer un lien vers la page du compte utilisateur ayant édité la publication.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '12', + 'translation' => "Fieldgroup, qui crée des groupes de champs liés. Les groupe de champ peuvent être repliés, et vous pouvez choisir qu'ils soient dépliés ou repliés par défaut. L'ordre des groupes de champs, ainsi que l'ordre des champs au sein d'un groupe, est géré grâce à l'interface par glisser-déposer fournie par le module Content.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '13', + 'translation' => "Pour plus d'informations, reportez-vous à l'entrée de manuel en ligne relative à CCK ou à la page du projet CCK.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '14', + 'translation' => 'Configurez ici la manière dont les champs et étiquettes de champs de ce type de contenu doivent être affichées, lorsque le contenu est vu en mode résumé ou en pleine page.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '15', + 'translation' => "Configurez ici la façon dont les champs de ce type de contenu doivent être affichés lorsqu'il est rendu dans les contextes suivants.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '16', + 'translation' => "Contrôlez ici l'ordre des champs dans le formulaire de saisie.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '17', + 'translation' => 'Ce champ est obligatoire.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '18', + 'translation' => '!title : !required', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '19', + 'translation' => 'Ordre', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '20', + 'translation' => 'Élément de flux RSS', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '21', + 'translation' => 'Index de recherche', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '22', + 'translation' => 'Résultat de recherche', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '23', + 'translation' => 'Langue', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '24', + 'translation' => 'Taxonomie', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '25', + 'translation' => 'Fichiers attachés', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '26', + 'translation' => 'Mise à jour du type de champ %type avec le module %module.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '27', + 'translation' => 'Mise à jour du type de widget %widget avec le module %module.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '28', + 'translation' => "Utiliser du code PHP pour le paramétrage des champs (dangereux - à n'autoriser qu'avec précautions)", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '29', + 'translation' => 'Gérer les champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '30', + 'translation' => 'Afficher les champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '31', + 'translation' => 'Général', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '32', + 'translation' => 'Avancé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '33', + 'translation' => 'Supprimer un champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '34', + 'translation' => 'Content', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '35', + 'translation' => 'Permet aux administrateurs de définir des nouveaux types de contenu.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '36', + 'translation' => 'CCK', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '37', + 'translation' => 'Texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '38', + 'translation' => "Les valeurs possibles pour ce champ. Saisissez une valeur par ligne, sous la forme clé|libellé. La clé est la valeur enregistrée dans la base de données, et elle doit correspondre au type de stockage du champ, %type. Le libellé est optionnel et, s'il n'est pas spécifié, la clé sera utilisée comme libellé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '39', + 'translation' => 'Zone de texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '40', + 'translation' => 'Ôter', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '41', + 'translation' => 'Basique', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '42', + 'translation' => 'Résumé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '43', + 'translation' => 'Nœud complet', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '44', + 'translation' => 'RSS', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '45', + 'translation' => 'Recherche', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '46', + 'translation' => 'Formulaire du module node.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '47', + 'translation' => 'Formulaire du module locale.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '48', + 'translation' => 'Paramètres du menu', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '49', + 'translation' => 'Formulaire du module menu.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '50', + 'translation' => 'Formulaire du module taxonomy.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '51', + 'translation' => 'Livre', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '52', + 'translation' => 'Formulaire du module livre (book).', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '53', + 'translation' => 'Titre du sondage', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '54', + 'translation' => 'Titre du module sondage (Poll)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '55', + 'translation' => 'Choix du sondage', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '56', + 'translation' => 'Choix du module sondage (poll).', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '57', + 'translation' => 'Paramètrage du sondage', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '58', + 'translation' => 'Paramètres du module sondage (poll).', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '59', + 'translation' => 'Formulaire du module upload.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '60', + 'translation' => 'contenu', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '61', + 'translation' => 'Champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '62', + 'translation' => "Les mises à jour des modules liés à CCK ne sont pas exécutées tant que les modules ne sont pas activés sur la page d'administration des modules. Lorsque vous les activerez, vous devrez retourner sur la page update.php et exécuter les mises à jour restantes.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '63', + 'translation' => "!module.module possède des mises à jour mais ne peut pas être mis à jour car content.module n'est pas activé.
    Le cas échéant, lors de l'activation de content.module, vous devrez exécuter à nouveau le script de mise à jour. Vous continuerez à voir ce message jusqu'à ce que le module soit activé et les mises à jour exécutées.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '64', + 'translation' => "!module.module possède des mises à jour et est disponible dans le répertoire des modules, mais n'est pas activé.
    Le cas échéant, lorsque vous l'aurez activé, vous devrez ré-exécuter le script de mise à jour. Vous continuerez à voir ce message jusqu'à l'activation du module et l'exécution des mises à jour. ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '65', + 'translation' => 'Des mises à jour sont toujours en attente. Veuillez retourner sur update.php et exécuter les mises à jour restarntes.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '66', + 'translation' => 'CCK - Aucune Intégration aux Vues', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '67', + 'translation' => 'L"intégration de CCK avec le module Views requiert Views 6.x-2.0-rc2 ou une version supérieure.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '68', + 'translation' => 'Nom', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '69', + 'translation' => 'Type', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '70', + 'translation' => 'Description', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '71', + 'translation' => 'Opérations', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '72', + 'translation' => 'éditer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '73', + 'translation' => 'gérer les champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '74', + 'translation' => 'supprimer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '75', + 'translation' => 'Aucun type de contenu disponible.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '76', + 'translation' => '» Ajouter un nouveau type de contenu', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '77', + 'translation' => 'Nom du champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '78', + 'translation' => 'Type de champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '79', + 'translation' => 'Utilisé dans', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '80', + 'translation' => '@field_name (Verrouillé)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '81', + 'translation' => "Aucun champ n'est pour l'instant défini sur l'ensemble des types de contenu.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '82', + 'translation' => "Ce type de contenu possède des champs inactifs. Les champs inactifs ne sont pas inclus dans la liste de champs disponibles, jusqu'à l'activation des modules correspondants.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '83', + 'translation' => '!field (!field_name) est un champ inactif de type !field_type, qui utilise un widget de type !widget_type.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '84', + 'translation' => 'Configurer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '85', + 'translation' => 'Verrouillé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '86', + 'translation' => '- Sélectionnez un type de champ -', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '87', + 'translation' => '- Sélectionnez un widget -', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '88', + 'translation' => 'Étiquette', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '89', + 'translation' => 'Nom du champ (a-z, 0-9, _)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '90', + 'translation' => 'Type de données à stocker.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '91', + 'translation' => "Elément du formulaire pour l'édition des données.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '92', + 'translation' => '- Sélectionnez un champ existant -', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '93', + 'translation' => 'Champ à partager', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '94', + 'translation' => 'Nom du groupe (a-z, 0-9, _)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '95', + 'translation' => 'Enregistrer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '96', + 'translation' => 'Ajouter un nouveau champ : vous devez fournir une étiquette.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '97', + 'translation' => 'Ajouter un nouveau champ : vous devez fournir un nom de champ.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '98', + 'translation' => "Ajouter un nouveau champ : le nom de champ %field_name n'est pas valide. Le nom doit seulement contenir des lettre minuscules non accentuées, des nombres, et des underscores. ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '99', + 'translation' => "Ajouter un nouveau champ : le nom de champ %field_name est trop long. Le nom est limité à 32 caractères, en comptant le préfixe 'field_'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '100', + 'translation' => "Ajouter un nouveau champ : le nom 'field_instance' est un nom réservé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '101', + 'translation' => 'Ajouter un nouveau champ : le nom du champ %field_name existe déjà.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '102', + 'translation' => 'Ajouter un nouveau champ : vous devez sélectionner un type de champ.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '103', + 'translation' => 'Ajouter un nouveau champ : vous devez sélectionner un widget.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '104', + 'translation' => 'Ajouter un nouveau champ : widget non valide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '105', + 'translation' => 'Ajouter un champ existant : vous devez fournir une étiquette.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '106', + 'translation' => 'Ajouter un champ existant : vous devez sélectionner un champ.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '107', + 'translation' => 'Ajouter un champ existant: vous devez sélectionner un widget.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '108', + 'translation' => 'Ajouter un champ existant : widget non valide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '109', + 'translation' => "Un problème est survenu à la création du champ '%label'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '110', + 'translation' => "Le champ %label n'a pas pu être ajouté au type de contenu car il est verrouillé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '111', + 'translation' => "Un problème est survenu lors de l'ajout du champ '%label'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '112', + 'translation' => "Il n'y a aucun champ configuré pour ce type de contenu. Vous pouvez ajouter de nouveaux champs sur la page Gérer les champs.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '113', + 'translation' => 'Au dessus', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '114', + 'translation' => 'Sur la même ligne', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '115', + 'translation' => 'Inclure', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '116', + 'translation' => 'Exclure', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '117', + 'translation' => 'aucune mise en forme', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '118', + 'translation' => 'simple', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '119', + 'translation' => 'groupe de champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '120', + 'translation' => 'groupe de champs - repliable', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '121', + 'translation' => 'groupe de champs - replié', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '122', + 'translation' => 'Vos paramètres ont été enregistrés.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '123', + 'translation' => '@type : @field (@label)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '124', + 'translation' => 'Éditer les informations de base', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '125', + 'translation' => 'Le nom lisible par une machine du champ. Ce nom ne peut être changé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '126', + 'translation' => "Nom lisible par une personne, destiné à servir d'étiquette pour ce champ au sein du type de contenu '%type'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '127', + 'translation' => 'Type de données que vous souhaitez enregistrer, par le biais de ce champ, dans la base de données. Cette option ne peut être modifiée.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '128', + 'translation' => 'Type de widget', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '129', + 'translation' => "Type d'élément de formulaire que vous souhaitez présenter à l'utilisateur lorsqu'il renseigne ce champ dans le type de contenu '%type'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '130', + 'translation' => 'Continuer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '131', + 'translation' => 'Les paramètres basiques du champ %label ont été mis à jour.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '132', + 'translation' => 'Un problème a été rencontré lors de la mise à jour des paramètres basiques du champ %label.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '133', + 'translation' => "Êtes-vous certain de vouloir enlever le champ '%field' ?", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '134', + 'translation' => 'Si vous avez encore du contenu dans ce champ, il sera perdu. Cette action est irréversible.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '135', + 'translation' => 'Annuler', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '136', + 'translation' => 'Ce champ est verrouillé et ne peut être supprimé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '137', + 'translation' => "Le champ '%field' de '%type' a été enlevé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '138', + 'translation' => "Un problème est survenu à la suppression du champ '%field' du type '%type'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '139', + 'translation' => 'Le champ %field est verouillé et ne peut être édité.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '140', + 'translation' => "Informations de base pour '%type'", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '141', + 'translation' => 'Modifier les informations de base', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '142', + 'translation' => "Paramètres de '%type'", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '143', + 'translation' => "Ces paramètres ne s'applique qu'au champ '%field' tel qu'il apparaît dans le type contenu '%type'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '144', + 'translation' => "Texte d'aide", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '145', + 'translation' => "Instructions à présenter à l'utilisateur sous ce champ, dans le formulaire d'édition.
    Balises HTML autorisées : @tags", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '146', + 'translation' => 'Valeur par défaut', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '147', + 'translation' => 'Code PHP', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '148', + 'translation' => "'@column' => valeur de @column", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '149', + 'translation' => "return array(\n 0 => array(@columns),\n // Vous voudrez vous arrêter là dans la plupart des cas. Fournir plus de valeurs\n // si vous souhaitez que votre 'valeur par défaut' ait des valeurs multiples :\n 1 => array(@columns),\n 2 => ...\n);", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '150', + 'translation' => 'Code', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '151', + 'translation' => "Usage avancé seulement : code PHP retournant une valeur par défaut. Ne doit pas contenir les délimiteurs <?php ?>. Si ce champ est rempli, la valeur retournée par ce code écrasera toute valeur spécifiée ci-dessus. Format attendu :
    !sample
    . Pour vous faire une idée du format attendu, vous pouvez utiliser l'onglet devel load fourni par le module devel sur une page de contenu de type %type.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '152', + 'translation' => '<aucun>', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '153', + 'translation' => "Vous n'êtes pas autorisé à saisir du code PHP.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '154', + 'translation' => 'Ce code PHP a été inséré par un administrateur et supplantera toute valeur spécifiée ci-dessus.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '155', + 'translation' => 'Paramètres globaux', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '156', + 'translation' => "Ces paramètres s'appliquent au champ '%field' dans tous les types de contenu où il apparaît.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '157', + 'translation' => 'Obligatoire', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '158', + 'translation' => "Le nombre maximum de valeurs qu'un utilisateur peut entrer pour ce champ.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '159', + 'translation' => "'Illimité' fournira un bouton 'Ajouter plus' pour que les utilisateurs puissent ajouter autant de valeurs qu'ils le souhaitent.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '160', + 'translation' => 'Attention ! Changer ce paramètre alors que des données ont déjà été créées peut conduire à perdre des données !', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '161', + 'translation' => 'Nombre de valeurs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '162', + 'translation' => 'Illimité', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '163', + 'translation' => 'Enregistrer les paramètres du champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '164', + 'translation' => "Le code PHP pour la 'valeur par défaut' a retourné @value, qui n'est pas valide.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '165', + 'translation' => 'La valeur par défaut est invalide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '166', + 'translation' => "Le champ '%label' a été ajouté.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '167', + 'translation' => "Champ '%label' enregistré.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '168', + 'translation' => 'Exécution', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '169', + 'translation' => 'La mise à jour a échoué.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '170', + 'translation' => 'La base de données a été modifiée et des données ont été déplacées ou supprimées.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '171', + 'translation' => 'Une erreur est survenue et a interrompu la modification de la base de données.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '172', + 'translation' => "'%title' en cours de traitement", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '173', + 'translation' => '%name doit être un entier.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '174', + 'translation' => '%name doit être un entier positif.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '175', + 'translation' => '%name doit être un nombre.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '176', + 'translation' => '1 élément traité avec succès :', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '177', + 'translation' => '@count éléments traités avec succès :', + 'language' => 'fr', + 'plid' => '176', + 'plural' => '1', +)) +->values(array( + 'lid' => '178', + 'translation' => "La table de champs a été renommée de '%old_name' à '%new_name' et les instances des champs ont été mises à jour.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '179', + 'translation' => "La table de champs '%name' a été supprimée.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '180', + 'translation' => 'Ajouter un autre élément', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '181', + 'translation' => 'Contenu du champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '182', + 'translation' => 'Un champ de contenu du node référencé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '183', + 'translation' => 'Noeud', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '184', + 'translation' => 'Contexte du noeud', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '185', + 'translation' => 'Titre du bloc', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '186', + 'translation' => 'Caché', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '187', + 'translation' => "Configurer la manière dont l'étiquette est affichée.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '188', + 'translation' => 'Champ / Formateur', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '189', + 'translation' => 'Sélectionner un champ et un formateur.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '190', + 'translation' => '"@s" champ @name', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '191', + 'translation' => 'Remplir un champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '192', + 'translation' => 'Vous devez vous assurer que le champ existe pour le type de contenu donné.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '193', + 'translation' => 'Champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '194', + 'translation' => 'Sélectionnez le nom-machine du champ.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '195', + 'translation' => 'Avancé : Préciser les valeurs des champs avec du code PHP', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '196', + 'translation' => "Usage avancé seulement : code PHP retournant la valeur à définir. Ne doit pas contenir les délimiteurs <?php ?>. Si ce champ est rempli, la valeur retournée par ce code écrasera toute valeur spécifiée ci-dessus. Format attendu :
    !sample
    . Pour vous faire une idée du format attendu, vous pouvez utiliser l'onglet devel load fourni par le module devel sur une page de contenu de type %type.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '197', + 'translation' => 'Vous devez retourner la valeur par défaut dans le format attendu.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '198', + 'translation' => "Remplir le champ '@field' de @node", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '199', + 'translation' => 'Le champ possède une valeur', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '200', + 'translation' => 'Vous devez vous assurer que le champ utilisé existe dans le type de contenu donné. La condition retourne TRUE, si le champ sélectionné possède la valeur donnée.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '201', + 'translation' => 'Le champ a été modifié', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '202', + 'translation' => 'Contenu contenant des modifications', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '203', + 'translation' => 'Contenu ne contenant pas de modification', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '204', + 'translation' => "Le champ '@field' de @node possède une valeur", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '205', + 'translation' => 'Sélectionnez le nom-machine du champ à voir.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '206', + 'translation' => "Le champ '@field' de @node a été modifié", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '207', + 'translation' => 'Jeton (Token)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '208', + 'translation' => 'Identifiant du nœud référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '209', + 'translation' => 'Titre du nœud référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '210', + 'translation' => 'Titre non filtré du noeud référencé. ATTENTION - saisie brute utilisateur.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '211', + 'translation' => 'Lien html formaté vers le noeud référencé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '212', + 'translation' => 'Alias de chemin relatif vers le noeud référencé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '213', + 'translation' => 'Alias de chemin absolu vers le noeud référencé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '214', + 'translation' => 'Valeur numérique brute', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '215', + 'translation' => 'Valeur numérique mise en forme', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '216', + 'translation' => 'Texte brut, non filtré', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '217', + 'translation' => 'Texte filtré et mis en forme', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '218', + 'translation' => "Identifiant de l'utilisateur référencé", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '219', + 'translation' => "Nom de l'utilisateur référencé", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '220', + 'translation' => "Lien HTML mis en forme vers l'utilisateur référencé", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '221', + 'translation' => "Alias de chemin relatif vers l'utilisateur référencé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '222', + 'translation' => "Alias de chemin absolu vers l'utilisateur référencé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '223', + 'translation' => '@label (!name)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '224', + 'translation' => '@label (!name) - !column', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '225', + 'translation' => '@label-truncated - !column', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '226', + 'translation' => 'Apparaît dans : @types', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '227', + 'translation' => 'Aucun', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '228', + 'translation' => 'Étiquette du widget (@label)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '229', + 'translation' => 'Personnalisé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '230', + 'translation' => 'Étiquette personnalisée', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '231', + 'translation' => 'Format', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '232', + 'translation' => 'Grouper plusieurs valeurs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '233', + 'translation' => "Si non coché, chaque élément du champ créera une nouvelle ligne, ce qui pourrait apparemment entraîner des doublons. Ce paramètre n'est pas compatible avec le tri par clic dans l'affichage du tableau. ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '234', + 'translation' => 'Afficher @count valeur(s)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '235', + 'translation' => 'en commençant à @count', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '236', + 'translation' => 'Inversé (commencer à partir des dernières valeurs)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '237', + 'translation' => 'Tous / Toutes', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '238', + 'translation' => 'Delta', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '239', + 'translation' => "Le delta vous permet de sélectionner quel élément d'un champ à valeur multiple sera la clé de la relation. Sélectionnez \"1\" pour utiliser le premier élément, \"2\" pour le second et ainsi de suite. Si vous sélectionnez \"Tous\", chaque élément du champ créera une nouvelle ligne, ce qui pourrait causer des doublons.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '240', + 'translation' => "Le delta vous permet de sélectionner quel élément d'un champ à valeur multiple sera utilisé pour les tris. Sélectionnez \"1\" pour utiliser le premier élément, \"2\" pour le second et ainsi de suite. Si vous sélectionnez \"Tous\", chaque élément du champ créera une nouvelle ligne, ce qui pourrait causer des doublons.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '241', + 'translation' => 'Exporter', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '242', + 'translation' => "Ce formulaire traitera un type de contenu et un ou plusieurs champs de ce type, pour en exporter les paramètres. Le code d'export ainsi généré peut être copié et collé dans la page d'import, vers la base de données courante ou vers une autre base de données. L'opération d'import ajoutera les champs à un type de contenu existant ou créera un nouveau type de contenu intégrant les champs sélectionnés.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '243', + 'translation' => 'Types', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '244', + 'translation' => 'Sélectionner le type de contenu à exporter.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '245', + 'translation' => 'Données exportée', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '246', + 'translation' => "Copiez le texte exporté et collez-le dans le type de contenu de votre choix, à l'aide de la fonction d'import.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '247', + 'translation' => 'Types de contenu', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '248', + 'translation' => 'Type de contenu', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '249', + 'translation' => 'Séléctionnez le type de contenu dans lequel importer ces champs.
    Sélectionnez <Créer> pour créer un nouveau type de contenu qui contiendra ces champs.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '250', + 'translation' => 'Données à importer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '251', + 'translation' => 'Collez dans ce champ le texte créé par un export de contenu.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '252', + 'translation' => 'Importer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '253', + 'translation' => "Un fichier a été préchargé pour l'import.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '254', + 'translation' => "Les données d'import ne sont valides.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '255', + 'translation' => "Les modules suivants doivent être activés pour que l'import fonctionne : '%modules'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '256', + 'translation' => "Le type de contenu '%type' existe déjà dans cette base de données.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '257', + 'translation' => "Abandon. L'import n'a pas été réalisé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '258', + 'translation' => "Une erreur s'est produite lors de l'ajout du nouveau type de contenu %type.
    Veuillez vérifier les erreurs affichées pour plus de détails.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '259', + 'translation' => "Le champ importé '%field_label' (%field_name) n'a pas été ajouté à '%type' car ce champ existe déjà.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '260', + 'translation' => "Le champ importé '%field_label' (%field_name) a été ajouté au type de contenu '%type'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '261', + 'translation' => 'content_copy', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '262', + 'translation' => 'Content Copy', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '263', + 'translation' => "Permet d'importer et d'exporter des définitions de champs.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '264', + 'translation' => "Les champs d'un groupe Standard sont indépendants les uns des autres, et chacun peut soit avoir une valeur unique, soit des valeurs multiples. Les champs d'un Multigroupe sont traités comme une ensemble répétable de champs à valeurs uniques.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '265', + 'translation' => 'Multigroupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '266', + 'translation' => 'Standard', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '267', + 'translation' => 'Type de groupe.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '268', + 'translation' => "Le champ %field a été mis à jour pour l'utilisation de valeurs %multiple, afin de correspondre au paramètre de valeur multipe du Multigroup %group.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '269', + 'translation' => "Cette modification n'est pas autorisée. Le champ %field possède déjà des valeurs multiples dans la base de données, mais le groupe %group en autorise seulement %group_max. Effectuer cette modification pourrait entraîner la perte de données. ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '270', + 'translation' => "Cette modification n'est pas autorisée. Le champ %field manipule les valeurs multiples différemment du module Content. Effectuer cette modification pourrait entraîner la perte de données. ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '271', + 'translation' => "Vous êtes en train d'inclure le champ %field dans un Multigroupe", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '272', + 'translation' => "Cette modification n'est pas autorisée. Le champ %field possède déjà des données créées, et utilise un widget qui stocke les données différemment dans un groupe Standard que dans un Multigroupe. Effectuer ce changement pourrait entraîner la perte de données.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '273', + 'translation' => "Vous êtes en train de retirer le champ %field d'un Multigroupe", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '274', + 'translation' => 'Simple', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '275', + 'translation' => 'Groupe de champs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '276', + 'translation' => 'Ligne horizontale', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '277', + 'translation' => 'Tableau - Colonne unique', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '278', + 'translation' => 'Tableau - Colonnes multiples', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '279', + 'translation' => '[Format du sous-groupe]', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '280', + 'translation' => 'Paramètres multigroupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '281', + 'translation' => 'Colonnes multiples', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '282', + 'translation' => "Activez cette option pour rendre chaque champs dans une colonne disctincte sur le formulaire d'édition de noeud.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '283', + 'translation' => "Activez cette option pour rendre obligatoire un minimum d'une collection de champs dans ce Multigroupe.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '284', + 'translation' => "Nombre de fois où répéter l'ensemble Multigroupe de champs.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '285', + 'translation' => "'Illimité' fournira un bouton 'Ajouter plus' pour que les utilisateurs puissent ajouter des éléments autant de fois qu'ils le souhaitent.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '286', + 'translation' => 'Tous les champs de ce groupe seront automatiquement paramétrés pour autoriser ce nombre de valeurs.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '287', + 'translation' => 'Nombre de répétitions', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '288', + 'translation' => 'Etiquettes', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '289', + 'translation' => "Etiquettes pour chaque sous-groupe de champs. Les étiquettes peuvent être cachées ou affichées dans des contextes divers en utilisant l'écran 'Afficher les champs'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '290', + 'translation' => 'Etiquette du sous-groupe %number', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '291', + 'translation' => 'Le champ %field dans ce groupe possède déjà %multiple valeurs dans la base de données. Pour éviter la perte de données, vous ne pouvez définir le nombre de valeurs du Multigroupe à une valeur inférieure.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '292', + 'translation' => 'Le champ !name est obligatoire dans le groupe @group.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '293', + 'translation' => 'Le groupe @name requiert au minimum un groupe de champs.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '294', + 'translation' => 'Ajouter plus de valeurs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '295', + 'translation' => 'content_multigroup', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '296', + 'translation' => 'Contenu Multigroupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '297', + 'translation' => "Combinez de multiples champs CCK au sein de collections de champs qui fonctionnent à l'unisson.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '298', + 'translation' => 'éditer', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '299', + 'translation' => 'field_name', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '300', + 'translation' => 'voir', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '301', + 'translation' => 'content_permissions', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '302', + 'translation' => 'Veuillez configurer vos permissions sur les champs immédiatement. Tous les champs sont inaccessibles par défaut.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '303', + 'translation' => 'Permissions sur les Contenus', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '304', + 'translation' => 'Définit un niveau de permission par champ pour les champs CCK.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '305', + 'translation' => 'Contenu du groupe de champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '306', + 'translation' => "Tous les champs d'un groupe de champs sur le node référencé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '307', + 'translation' => '@group_label (@group_type_name)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '308', + 'translation' => 'Fieldgroup', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '309', + 'translation' => "Texte à afficher si un groupe n'a pas de données. Notez que le titre ne s'affichera pas sauf s'il est surclassé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '310', + 'translation' => '"@s" groupe de champs @name', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '311', + 'translation' => 'Paramètres du formulaire', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '312', + 'translation' => "Ces paramètres s'appliquent au groupe dans le formulaire d'édition de nœud.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '313', + 'translation' => 'Style', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '314', + 'translation' => 'toujours déplié', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '315', + 'translation' => 'repliable', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '316', + 'translation' => 'replié', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '317', + 'translation' => "Instructions à présenter à l'utilisateur dans le formulaire d'édition.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '318', + 'translation' => "Paramètres d'affichage", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '319', + 'translation' => "Ces paramètres s'appliquent au groupe à l'affichage du nœud.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '320', + 'translation' => 'Description du groupe.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '321', + 'translation' => "Êtes-vous sûr(e) de vouloir supprimer le groupe '%label' ?", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '322', + 'translation' => 'Cette action est irréversible.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '323', + 'translation' => "Le groupe '%group_name' a été supprimé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '324', + 'translation' => 'aucun', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '325', + 'translation' => 'Vous devez fournir une étiquette.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '326', + 'translation' => 'Vous devez fournir un nom de groupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '327', + 'translation' => "Le nom de groupe %group_name n'est pas valide. Le nom ne doit contenir que des lettres sans accents, des nombres, et des underscores.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '328', + 'translation' => "Le nom de groupe %group_name est trop long. Le nom est limité à 32 caractères, le préfixe 'group_' compris.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '329', + 'translation' => 'Le nom de groupe %group_name existe déjà.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '330', + 'translation' => 'Ajouter un nouveau groupe :', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '331', + 'translation' => 'Ajouter un nouveau groupe : vous devez fournir une étiquette.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '332', + 'translation' => 'Ajouter un nouveau groupe : vous devez fournir un nom de groupe.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '333', + 'translation' => 'Groupe standard', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '334', + 'translation' => 'Éditer le groupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '335', + 'translation' => 'fieldgroup', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '336', + 'translation' => "Créée des groupes d'affichage pour les champs CCK.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '337', + 'translation' => 'Charge un noeud référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '338', + 'translation' => 'Contenu contenant le champ node reference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '339', + 'translation' => 'Contenu référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '340', + 'translation' => 'Notez que si le champs possède des valeurs multiples, seul le premier contenu sera chargé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '341', + 'translation' => "Il n'y a aucun champ nodereference défini.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '342', + 'translation' => 'Node référence', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '343', + 'translation' => "Stocker l'ID du noeud lié en tant que valeur entière.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '344', + 'translation' => 'Types de contenu pouvant être référencés', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '345', + 'translation' => 'Vues par défaut', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '346', + 'translation' => 'Vues éxistantes', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '347', + 'translation' => 'Avancé - Nœuds pouvant être référencés (Vue)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '348', + 'translation' => 'Vue utilisée pour sélectionner les noeuds', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '349', + 'translation' => '

    Choisissez la vue du "module Views" qui sélectionne les noeuds pouvant être référencés.
    Note :

    ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '350', + 'translation' => "
    • Seules les vues qui possèdent des champs fonctionneront à cet effet.
    • Ceci annulera les paramètres \"Types de contenu\" ci-dessus. Utilisez la section \"filtres\" de la vue à la place.
    • Utilisez la section \"champs\" de la vue pour afficher des informations supplémentaires à propos des noeuds candidats sur le formulaire de création/édition.
    • Utilisez la section \"critère de tri\" de la vue pour déterminer l'ordre dans lequel les noeuds candidats seront affichés.
    ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '351', + 'translation' => 'Arguments de la vue', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '352', + 'translation' => "Fournit une liste d'arguments, séparés par des virgules, à transmettre à la vue.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '353', + 'translation' => "

    La liste des noeuds pouvant être référencés peut s'appuyer sur une vue du \"module Views\" mais aucune vue appropriée n'a été trouvée.
    Note :

    ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '354', + 'translation' => '%name : saisie non valide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '355', + 'translation' => '%name : ce contenu ne peut être référencé.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '356', + 'translation' => 'Titre (avec lien)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '357', + 'translation' => 'Titre (sans lien)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '358', + 'translation' => 'Liste de sélection', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '359', + 'translation' => 'Cases à cocher/boutons radio', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '360', + 'translation' => 'Champ texte à auto-complètement', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '361', + 'translation' => "Correspondance de l'autocomplétion", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '362', + 'translation' => 'Commence par', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '363', + 'translation' => 'Contient', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '364', + 'translation' => "Séléctionnez la méthode utilisée pour collecter les suggestions de l'autocomplétion. Notez que Contient peut engendrer des problèmes de performances sur des sites avec des milliers de noeuds", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '365', + 'translation' => '%name : différence de titre. Veuillez vérifier votre sélection.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '366', + 'translation' => "%name : aucun contenu valide n'a été trouvé pour ce titre.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '367', + 'translation' => 'Autocomplétion de nodereference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '368', + 'translation' => 'nodereference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '369', + 'translation' => 'Node Reference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '370', + 'translation' => 'Définit un type de champ pour référencer un noeud depuis un autre noeud.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '371', + 'translation' => 'Entier', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '372', + 'translation' => 'Stocke un nombre dans la base de données en format entier.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '373', + 'translation' => 'Décimal', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '374', + 'translation' => 'Stocke un nombre dans la base de données en format décimal fixe.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '375', + 'translation' => 'Réel (Float)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '376', + 'translation' => 'Stocke un nombre dans la base de données en format réel.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '377', + 'translation' => 'Minimum', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '378', + 'translation' => 'Maximum', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '379', + 'translation' => 'Précision', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '380', + 'translation' => 'Le nombre total de chiffres à stocker dans la base de données, en incluant ceux à droite de la virgule.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '381', + 'translation' => 'Echelle', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '382', + 'translation' => 'Le nombre de chiffres à droite de la virgule', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '383', + 'translation' => 'Séparateur de décimales', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '384', + 'translation' => 'Le caractère que les utilisateurs saisiront pour séparer les décimales dans les formulaires.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '385', + 'translation' => 'Préfixe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '386', + 'translation' => 'Définissez une chaîne de caractères à utiliser pour préfixer la valeur, par exemple $ ou €. Laissez vide pour ne rien afficher de plus. Séparez les valeurs singulier et pluriel par une barre verticale (euro|euros).', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '387', + 'translation' => 'Suffixe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '388', + 'translation' => 'Définissez une chaîne qui sera ajoutée en suffixe à la valeur, comme m², m/s², kb/s. Laisser vide pour aucun suffixe. Séparez les singulier et pluriel avec un pipe (mètre|mètres).', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '389', + 'translation' => 'Valeurs autorisées', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '390', + 'translation' => 'Liste des valeurs autorisées', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '391', + 'translation' => "Les valeurs possibles que ce champ peut contenir. Entrez une valeur par ligne, sous la forme clé|étiquette. La clé est une valeur qui sera stocker dans la base de données, elle doit correspondre au type de champ défini (%type). L'étiquette est optionnelle, si elle n'est pas précisée, la clé sera utilisée également comme étiquette.
    Balises HTML autorisées : @tags", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '392', + 'translation' => 'Pour usage avancé seulement : code PHP fournissant un tableau par clé des valeurs autorisées. Ne doit pas inclure les délimiteurs <?php ?>. Si ce champ est rempli, le tableau renvoyé par le code prendra le pas sur la liste des valeurs autorisées apparaissant ci-dessus.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '393', + 'translation' => 'Ce code PHP a été saisi par un administrateur et supplantera la liste des valeurs permises ci-dessus.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '394', + 'translation' => '@label (!name) - Valeurs autorisées', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '395', + 'translation' => '"Minimum" doit être un nombre.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '396', + 'translation' => '"Maximum" doit être un nombre.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '397', + 'translation' => '%name : la valeur ne peut être inférieure à %min.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '398', + 'translation' => '%name : la valeur ne peut être supérieure à %max.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '399', + 'translation' => '%name : valeur illégale.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '400', + 'translation' => 'non mis en forme', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '401', + 'translation' => 'Champ texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '402', + 'translation' => 'Seuls les nombres et les décimaux sont autorisés dans %field.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '403', + 'translation' => 'Seuls les nombres sont autorisés dans %field.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '404', + 'translation' => 'Seuls les nombres et le caractère décimal (%decimal) sont autorisés dans %field.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '405', + 'translation' => 'nombre', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '406', + 'translation' => 'Nombre', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '407', + 'translation' => 'Définit des types de champs numériques.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '408', + 'translation' => "Créez une liste d'options en tant que liste dans la Liste des valeurs autorisées, ou en tant que tableau en code PHP. Ces valeurs seront les mêmes pour le champ %field au sein de tous les types de contenu.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '409', + 'translation' => "Pour un widget 'case à cocher oui/non', définissez la valeur 'non' en premier, puis la valeur 'oui', dans la section Valeurs autorisées. Notez que la case à cocher sera étiquetée avec l'étiquette de la valeur du 'oui'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '410', + 'translation' => "Le widget 'cases à cocher/boutons radio' affichera des cases à cocher si l'option valeurs multiples est sélectionnées pour ce champ, autrement, des boutons radio seront affichés.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '411', + 'translation' => "Vous devez préciser les 'valeurs autorisées' pour ce champ.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '412', + 'translation' => 'Case à cocher on/off unique', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '413', + 'translation' => '%name : ce champ ne peut contenir plus de @count valeurs.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '414', + 'translation' => 'N/A', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '415', + 'translation' => '- Aucun -', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '416', + 'translation' => 'optionwidgets', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '417', + 'translation' => 'Option Widgets', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '418', + 'translation' => 'Définit des widgets de liste déroulante, case à cocher et bouton radio pour des champs texte et numériques.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '419', + 'translation' => 'Enregistre le texte dans la base de données.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '420', + 'translation' => 'Texte simple', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '421', + 'translation' => "Texte filtré (l'utilisateur choisit le format d'entrée)", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '422', + 'translation' => 'Traitement du texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '423', + 'translation' => 'Taille maximale', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '424', + 'translation' => 'La taille maximale des champs, en caractères. Laisser vide pour ne pas limiter la taille.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '425', + 'translation' => '%name : la valeur ne doit pas dépasser %max caractères.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '426', + 'translation' => 'Par défaut', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '427', + 'translation' => 'Coupé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '428', + 'translation' => 'Zone de texte (plusieurs lignes)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '429', + 'translation' => 'Taille du champ texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '430', + 'translation' => 'Rangées', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '431', + 'translation' => 'texte', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '432', + 'translation' => 'Définit les types de champs en texte simple.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '433', + 'translation' => 'Charge un utilisateur référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '434', + 'translation' => 'Contenu contenant le champ userrefernece', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '435', + 'translation' => 'Utilisateur référencé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '436', + 'translation' => 'Noter que si le champ possède des valeurs multiples, seul le premier utilisateur sera chargé', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '437', + 'translation' => "Il n'y a aucun champ userreference défini", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '438', + 'translation' => 'User reference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '439', + 'translation' => "Stocke l'ID d'un utilisateur lié sous forme d'entier", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '440', + 'translation' => 'Rôles utilisateur pouvant être référencés', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '441', + 'translation' => 'Statuts utilisateur pouvant être référencés', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '442', + 'translation' => 'Actif', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '443', + 'translation' => 'Bloqué', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '444', + 'translation' => 'Avancé - Utilisateurs pouvant être référencés (Vue)', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '445', + 'translation' => 'Vue utilisée pour sélectionner les utilisateurs', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '446', + 'translation' => '

    Choisissez la vue du "module Views" qui sélectionne les utilisateurs pouvant être référencés.
    Note :

    ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '447', + 'translation' => "
    • Seules les vues qui possèdent des champs fonctionneront à cet effet.
    • Ceci annulera les paramètres \"Rôles Référençables\" et \"Statut Référençable\" ci-dessus. Utilisez la section \"filtres\" de la vue à la place.
    • Utilisez la section \"champs\" de la vue pour afficher des informations supplémentaires à propos des utilisateurs candidats sur le formulaire de création/édition.
    • Utilisez la section \"critère de tri\" de la vue pour déterminer l'ordre dans lequel les utilisateurs candidats seront affichés.
    ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '448', + 'translation' => "

    La liste d'utilisateurs pouvant être référencés peut s'appueyr sur une vue du \"module Views\", mais aucune vue appropriée n'a été trouvée.
    Note :

    ", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '449', + 'translation' => '%name : utilisateur invalide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '450', + 'translation' => "Séléctionnez la méthode utilisée pour collecter les suggestions de l'autocomplétion. Notez que Contient peut engendrer des problèmes de performances sur des sites avec des milliers d'utilisateurs.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '451', + 'translation' => 'Lien retour', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '452', + 'translation' => "Si cette option est sélectionnée, un lien réciproque vers le nœud référençant sera affiché dans l'enregistrement utilisateur référencé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '453', + 'translation' => "%name : nous n'avons pas trouvé d'utilisateur valide pour ce nom.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '454', + 'translation' => 'Contenu lié', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '455', + 'translation' => 'Autocomplétion Userreference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '456', + 'translation' => 'userreference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '457', + 'translation' => 'User Reference', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '458', + 'translation' => 'Définit un type de champ pour référencer un utilisateur depuis un noeud.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '459', + 'translation' => 'Poids', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '460', + 'translation' => 'Ajouter', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '461', + 'translation' => 'Nouveau champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '462', + 'translation' => 'Champ existant', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '463', + 'translation' => 'Nouveau groupe', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '464', + 'translation' => "Ajouter des champs et des groupes au type de contenu, et les paramétrer pour l'affichage du contenu et les formulaires de saisie.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '465', + 'translation' => 'Vous pouvez ajouter un champ à un groupe en le faisant glisser ci-dessous et à la droite du groupe.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '466', + 'translation' => "Note : l'installation du module Aide avancée (Advanced help) vous permettra d'accéder à plus d'aide, et de meilleure qualité.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '467', + 'translation' => "Utiliser la case à cocher 'Exclure' pour exclure un élément de la valeur de !content transmis au gabarit du node.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '468', + 'translation' => 'Supprimer cet élément', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '469', + 'translation' => 'Ajouter un champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '470', + 'translation' => "Valeur illégale pour le champ '%name'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '471', + 'translation' => "La longueur de '%label' dépasse %max caractères.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '472', + 'translation' => "Le champ 'Rangées' doit être un entier positif.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '473', + 'translation' => "Les valeurs que ce champ peut contenir. Saisissez une valeur par ligne, au format clé|libellé. La clé est la valeur qui sera enregistrée dans la base de données et elle doit correspondre au type définit pour le champ dans la base, '%type'. Le libellé est optionnel et, si aucune valeur n'est spécifiée, la clé sera utilisée comme libellé.
    Balises HTML autorisées : @tags", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '474', + 'translation' => 'ajouter un champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '475', + 'translation' => "Il n'y a aucun champ configuré pour ce type de contenu. Vous pouvez néanmoins dès maintenant !link.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '476', + 'translation' => 'ajouter un nouveau champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '477', + 'translation' => "Pour changer l'ordre d'un champ, utilisez la poignée qui figure sous la colonne Étiquette et faites glisser le champ jusqu'à l'emplacement désiré. Pour manipuler la poignée (l'icône en forme de croix), cliquez sur l'icône et maintenez enfoncé le bouton de la souris. N'oubliez pas que vos modifications ne seront prises en compte que lorsque vous aurez cliqué sur le bouton Enregistrer qui figure en base de page.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '478', + 'translation' => "Aucun module de champs n'est activé. Vous devez en activer un, par exemple le module Text, avant de pouvoir ajouter des champs.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '479', + 'translation' => 'Ajouter un champ existant', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '480', + 'translation' => 'Créer un nouveau champ', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '481', + 'translation' => 'Nom du champ, lisible par une machine.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '482', + 'translation' => ' Ce nom ne peut être modifié.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '483', + 'translation' => " Ce nom ne pourra pas être modifié par la suite ! Le nom sera préfixé par 'field_' et peut inclure des lettres minuscules non accentués, des nombres et des caractères \"espace souligné\". La longueur du nom, y compris le préfixe, est limitée à un total de 32 caractères.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '484', + 'translation' => 'Type de données que vous souhaitez enregistrer, par le biais de ce champ, dans la base de données.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '485', + 'translation' => "Le nom de champ '%field_name' est invalide. Le nom ne doit comporter que des lettres minuscules non accentuées, des nombres ou des espaces soulignés.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '486', + 'translation' => "Le nom de champ '%field_name' est trop long. La longueur du nom est limitée à 32 caractères, y compris le préfixe 'field_'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '487', + 'translation' => "Le nom de champ '%field_name' existe déjà.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '488', + 'translation' => "Le nom 'field_instance' est un nom réservé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '489', + 'translation' => "Le champ '%label' a été créé.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '490', + 'translation' => "Mettre à jour le champ '%label'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '491', + 'translation' => "Un problème est survenu à la mise à jour du champ '%label'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '492', + 'translation' => "Réservé à une utilisation avancée : code PHP renvoyant la valeur par défaut du champ. Ne doit pas inclure les délimiteurs <?php ?>. Si ce champ est renseigné, la valeur renvoyée par le code supplante toute valeur indiquée ci-desus. Format attendu :
    !sample
    Vous pouvez utiliser l'onglet 'devel load' du module !link_devel sur un nœud de type '%type' pour mieux comprendre le format attendu.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '493', + 'translation' => "Choisissez un nombre de valeurs pour ce champ, ou 'Illimité' pour proposer un bouton 'Ajouter' aux utilisateurs, de sorte qu'ils peuvent insérer autant de valeurs qu'ils le souhaitent.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '494', + 'translation' => 'Le code PHP de valeur par défaut a créé @value, qui est invalide.', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '495', + 'translation' => 'Lien HTML mis en forme vers le nœud', + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '496', + 'translation' => "La valeur de '%name 'ne peut être plus petite que %min.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '497', + 'translation' => "La valeur de '%name' ne peut pas être plus grande que %max.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '498', + 'translation' => "Seuls des nombres et des décimaux sont autorisés dans '%field'. La valeur saisie, '%start', a été modifié en '%value'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '499', + 'translation' => "Seuls des nombres sont autorisés dans '%field'. La valeur saisie, '%start', a été modifié en '%value'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '500', + 'translation' => "Seuls des nombres et le marqueur décimal (%decimal) sont autorisés dans '%field'. La valeur saisie, '%start', a été modifié en '%value'.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->values(array( + 'lid' => '501', + 'translation' => "Créez une liste d'options en tant que liste dans les Valeurs permises ou en tant que tableau dans le code PHP. Ces valeurs seront identiques pour '%field' dans tous les types de contenus.", + 'language' => 'fr', + 'plid' => '0', + 'plural' => '0', +)) +->execute(); + +$connection->schema()->createTable('menu_custom', array( + 'fields' => array( + 'menu_name' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '32', + 'default' => '', + ), + 'title' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '255', + 'default' => '', + ), + 'description' => array( + 'type' => 'text', + 'not null' => FALSE, + 'size' => 'normal', + ), + ), + 'primary key' => array( + 'menu_name', + ), + 'mysql_character_set' => 'utf8', +)); + +$connection->insert('menu_custom') +->fields(array( + 'menu_name', + 'title', + 'description', +)) +->values(array( + 'menu_name' => 'navigation', + 'title' => 'Navigation', + 'description' => 'The navigation menu is provided by Drupal and is the main interactive menu for any site. It is usually the only menu that contains personalized links for authenticated users, and is often not even visible to anonymous users.', +)) +->values(array( + 'menu_name' => 'primary-links', + 'title' => 'Primary links', + 'description' => 'Primary links are often used at the theme layer to show the major sections of a site. A typical representation for primary links would be tabs along the top.', +)) +->values(array( + 'menu_name' => 'secondary-links', + 'title' => 'Secondary links', + 'description' => 'Secondary links are often used for pages like legal notices, contact details, and other secondary navigation items that play a lesser role than primary links', +)) +->execute(); + +$connection->schema()->createTable('menu_links', array( + 'fields' => array( + 'menu_name' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '32', + 'default' => '', + ), + 'mlid' => array( + 'type' => 'serial', + 'not null' => TRUE, + 'size' => 'normal', + 'unsigned' => TRUE, + ), + 'plid' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + 'unsigned' => TRUE, + ), + 'link_path' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '255', + 'default' => '', + ), + 'router_path' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '255', + 'default' => '', + ), + 'link_title' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '255', + 'default' => '', + ), + 'options' => array( + 'type' => 'text', + 'not null' => FALSE, + 'size' => 'normal', + ), + 'module' => array( + 'type' => 'varchar', + 'not null' => TRUE, + 'length' => '255', + 'default' => 'system', + ), + 'hidden' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'external' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'has_children' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'expanded' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'weight' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'depth' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'customized' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + ), + 'p1' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + 'unsigned' => TRUE, + ), + 'p2' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + 'unsigned' => TRUE, + ), + 'p3' => array( + 'type' => 'int', + 'not null' => TRUE, + 'size' => 'normal', + 'default' => '0', + 'unsigned' => TRUE, ), 'p4' => array( 'type' => 'int', @@ -13226,16 +20607,286 @@ 'link_title' => 'Remove field', 'options' => 'a:0:{}', 'module' => 'system', - 'hidden' => '-1', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '1', + 'customized' => '0', + 'p1' => '389', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '390', + 'plid' => '0', + 'link_path' => 'admin/content/node-type/story/fields/field_test_two/remove', + 'router_path' => 'admin/content/node-type/story/fields/field_test_two/remove', + 'link_title' => 'Remove field', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '1', + 'customized' => '0', + 'p1' => '390', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '391', + 'plid' => '0', + 'link_path' => 'admin/content/node-type/test-page/fields/field_test/remove', + 'router_path' => 'admin/content/node-type/test-page/fields/field_test/remove', + 'link_title' => 'Remove field', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '1', + 'customized' => '0', + 'p1' => '391', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '392', + 'plid' => '0', + 'link_path' => 'admin/content/node-type/test-planet/fields/field_multivalue/remove', + 'router_path' => 'admin/content/node-type/test-planet/fields/field_multivalue/remove', + 'link_title' => 'Remove field', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '1', + 'customized' => '0', + 'p1' => '392', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'secondary-links', + 'mlid' => '393', + 'plid' => '0', + 'link_path' => 'user/login', + 'router_path' => 'user/login', + 'link_title' => 'Test 3', + 'options' => 'a:0:{}', + 'module' => 'menu', + 'hidden' => '0', + 'external' => '0', + 'has_children' => '1', + 'expanded' => '0', + 'weight' => '-47', + 'depth' => '1', + 'customized' => '1', + 'p1' => '393', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '394', + 'plid' => '166', + 'link_path' => 'admin/build/path', + 'router_path' => 'admin/build/path', + 'link_title' => 'URL aliases', + 'options' => "a:1:{s:10:\"attributes\";a:1:{s:5:\"title\";s:46:\"Change your site's URL paths by aliasing them.\";}}", + 'module' => 'system', + 'hidden' => '0', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '3', + 'customized' => '0', + 'p1' => '144', + 'p2' => '166', + 'p3' => '394', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '395', + 'plid' => '394', + 'link_path' => 'admin/build/path/delete', + 'router_path' => 'admin/build/path/delete', + 'link_title' => 'Delete alias', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '4', + 'customized' => '0', + 'p1' => '144', + 'p2' => '166', + 'p3' => '394', + 'p4' => '395', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '396', + 'plid' => '394', + 'link_path' => 'admin/build/path/edit', + 'router_path' => 'admin/build/path/edit', + 'link_title' => 'Edit alias', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '4', + 'customized' => '0', + 'p1' => '144', + 'p2' => '166', + 'p3' => '394', + 'p4' => '396', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '397', + 'plid' => '0', + 'link_path' => 'system/files/imagecache', + 'router_path' => 'system/files/imagecache', + 'link_title' => '', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '1', + 'customized' => '0', + 'p1' => '397', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '398', + 'plid' => '167', + 'link_path' => 'admin/settings/imageapi', + 'router_path' => 'admin/settings/imageapi', + 'link_title' => 'ImageAPI', + 'options' => 'a:1:{s:10:"attributes";a:1:{s:5:"title";s:19:"Configure ImageAPI.";}}', + 'module' => 'system', + 'hidden' => '0', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '3', + 'customized' => '0', + 'p1' => '144', + 'p2' => '167', + 'p3' => '398', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '399', + 'plid' => '167', + 'link_path' => 'admin/settings/language', + 'router_path' => 'admin/settings/language', + 'link_title' => 'Languages', + 'options' => 'a:1:{s:10:"attributes";a:1:{s:5:"title";s:55:"Configure languages for content and the user interface.";}}', + 'module' => 'system', + 'hidden' => '0', 'external' => '0', 'has_children' => '0', 'expanded' => '0', 'weight' => '0', - 'depth' => '1', + 'depth' => '3', 'customized' => '0', - 'p1' => '389', - 'p2' => '0', - 'p3' => '0', + 'p1' => '144', + 'p2' => '167', + 'p3' => '399', 'p4' => '0', 'p5' => '0', 'p6' => '0', @@ -13246,23 +20897,23 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '390', - 'plid' => '0', - 'link_path' => 'admin/content/node-type/story/fields/field_test_two/remove', - 'router_path' => 'admin/content/node-type/story/fields/field_test_two/remove', - 'link_title' => 'Remove field', - 'options' => 'a:0:{}', + 'mlid' => '400', + 'plid' => '166', + 'link_path' => 'admin/build/translate', + 'router_path' => 'admin/build/translate', + 'link_title' => 'Translate interface', + 'options' => 'a:1:{s:10:"attributes";a:1:{s:5:"title";s:59:"Translate the built in interface and optionally other text.";}}', 'module' => 'system', - 'hidden' => '-1', + 'hidden' => '0', 'external' => '0', 'has_children' => '0', 'expanded' => '0', 'weight' => '0', - 'depth' => '1', + 'depth' => '3', 'customized' => '0', - 'p1' => '390', - 'p2' => '0', - 'p3' => '0', + 'p1' => '144', + 'p2' => '166', + 'p3' => '400', 'p4' => '0', 'p5' => '0', 'p6' => '0', @@ -13273,11 +20924,11 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '391', - 'plid' => '0', - 'link_path' => 'admin/content/node-type/test-page/fields/field_test/remove', - 'router_path' => 'admin/content/node-type/test-page/fields/field_test/remove', - 'link_title' => 'Remove field', + 'mlid' => '401', + 'plid' => '399', + 'link_path' => 'admin/settings/language/delete/%', + 'router_path' => 'admin/settings/language/delete/%', + 'link_title' => 'Confirm', 'options' => 'a:0:{}', 'module' => 'system', 'hidden' => '-1', @@ -13285,12 +20936,12 @@ 'has_children' => '0', 'expanded' => '0', 'weight' => '0', - 'depth' => '1', + 'depth' => '4', 'customized' => '0', - 'p1' => '391', - 'p2' => '0', - 'p3' => '0', - 'p4' => '0', + 'p1' => '144', + 'p2' => '167', + 'p3' => '399', + 'p4' => '401', 'p5' => '0', 'p6' => '0', 'p7' => '0', @@ -13300,11 +20951,11 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '392', + 'mlid' => '402', 'plid' => '0', - 'link_path' => 'admin/content/node-type/test-planet/fields/field_multivalue/remove', - 'router_path' => 'admin/content/node-type/test-planet/fields/field_multivalue/remove', - 'link_title' => 'Remove field', + 'link_path' => 'core/modules/simpletest/files/imagecache', + 'router_path' => 'core/modules/simpletest/files/imagecache', + 'link_title' => '', 'options' => 'a:0:{}', 'module' => 'system', 'hidden' => '-1', @@ -13314,7 +20965,7 @@ 'weight' => '0', 'depth' => '1', 'customized' => '0', - 'p1' => '392', + 'p1' => '402', 'p2' => '0', 'p3' => '0', 'p4' => '0', @@ -13326,25 +20977,25 @@ 'updated' => '0', )) ->values(array( - 'menu_name' => 'secondary-links', - 'mlid' => '393', - 'plid' => '0', - 'link_path' => 'user/login', - 'router_path' => 'user/login', - 'link_title' => 'Test 3', + 'menu_name' => 'navigation', + 'mlid' => '403', + 'plid' => '400', + 'link_path' => 'admin/build/translate/delete/%', + 'router_path' => 'admin/build/translate/delete/%', + 'link_title' => 'Delete string', 'options' => 'a:0:{}', - 'module' => 'menu', - 'hidden' => '0', + 'module' => 'system', + 'hidden' => '-1', 'external' => '0', - 'has_children' => '1', + 'has_children' => '0', 'expanded' => '0', - 'weight' => '-47', - 'depth' => '1', - 'customized' => '1', - 'p1' => '393', - 'p2' => '0', - 'p3' => '0', - 'p4' => '0', + 'weight' => '0', + 'depth' => '4', + 'customized' => '0', + 'p1' => '144', + 'p2' => '166', + 'p3' => '400', + 'p4' => '403', 'p5' => '0', 'p6' => '0', 'p7' => '0', @@ -13354,24 +21005,24 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '394', - 'plid' => '166', - 'link_path' => 'admin/build/path', - 'router_path' => 'admin/build/path', - 'link_title' => 'URL aliases', - 'options' => "a:1:{s:10:\"attributes\";a:1:{s:5:\"title\";s:46:\"Change your site's URL paths by aliasing them.\";}}", + 'mlid' => '404', + 'plid' => '399', + 'link_path' => 'admin/settings/language/edit/%', + 'router_path' => 'admin/settings/language/edit/%', + 'link_title' => 'Edit language', + 'options' => 'a:0:{}', 'module' => 'system', - 'hidden' => '0', + 'hidden' => '-1', 'external' => '0', 'has_children' => '0', 'expanded' => '0', 'weight' => '0', - 'depth' => '3', + 'depth' => '4', 'customized' => '0', 'p1' => '144', - 'p2' => '166', - 'p3' => '394', - 'p4' => '0', + 'p2' => '167', + 'p3' => '399', + 'p4' => '404', 'p5' => '0', 'p6' => '0', 'p7' => '0', @@ -13381,11 +21032,11 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '395', - 'plid' => '394', - 'link_path' => 'admin/build/path/delete', - 'router_path' => 'admin/build/path/delete', - 'link_title' => 'Delete alias', + 'mlid' => '405', + 'plid' => '400', + 'link_path' => 'admin/build/translate/edit/%', + 'router_path' => 'admin/build/translate/edit/%', + 'link_title' => 'Edit string', 'options' => 'a:0:{}', 'module' => 'system', 'hidden' => '-1', @@ -13397,8 +21048,8 @@ 'customized' => '0', 'p1' => '144', 'p2' => '166', - 'p3' => '394', - 'p4' => '395', + 'p3' => '400', + 'p4' => '405', 'p5' => '0', 'p6' => '0', 'p7' => '0', @@ -13408,11 +21059,11 @@ )) ->values(array( 'menu_name' => 'navigation', - 'mlid' => '396', - 'plid' => '394', - 'link_path' => 'admin/build/path/edit', - 'router_path' => 'admin/build/path/edit', - 'link_title' => 'Edit alias', + 'mlid' => '406', + 'plid' => '0', + 'link_path' => 'admin/content/node-type/test-planet/fields/field_test_text_single_checkbox/remove', + 'router_path' => 'admin/content/node-type/test-planet/fields/field_test_text_single_checkbox/remove', + 'link_title' => 'Remove field', 'options' => 'a:0:{}', 'module' => 'system', 'hidden' => '-1', @@ -13420,12 +21071,12 @@ 'has_children' => '0', 'expanded' => '0', 'weight' => '0', - 'depth' => '4', + 'depth' => '1', 'customized' => '0', - 'p1' => '144', - 'p2' => '166', - 'p3' => '394', - 'p4' => '396', + 'p1' => '406', + 'p2' => '0', + 'p3' => '0', + 'p4' => '0', 'p5' => '0', 'p6' => '0', 'p7' => '0', @@ -13740,7 +21391,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/bluemarine/bluemarine.info";s:4:"name";s:10:"bluemarine";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/bluemarine/bluemarine.info";s:4:"name";s:10:"bluemarine";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:10:"bluemarine";}', 'fit' => '31', @@ -13762,7 +21413,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":11:{s:8:"filename";s:31:"themes/chameleon/chameleon.info";s:4:"name";s:9:"chameleon";s:4:"type";s:5:"theme";s:5:"owner";s:32:"themes/chameleon/chameleon.theme";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":11:{s:8:"filename";s:31:"themes/chameleon/chameleon.info";s:4:"name";s:9:"chameleon";s:4:"type";s:5:"theme";s:5:"owner";s:32:"themes/chameleon/chameleon.theme";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:9:"chameleon";}', 'fit' => '31', @@ -13784,7 +21435,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:7:"garland";}', 'fit' => '31', @@ -13828,7 +21479,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:35:"themes/chameleon/marvin/marvin.info";s:4:"name";s:6:"marvin";s:4:"type";s:5:"theme";s:5:"owner";s:0:"";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:10:"base_theme";s:9:"chameleon";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:35:"themes/chameleon/marvin/marvin.info";s:4:"name";s:6:"marvin";s:4:"type";s:5:"theme";s:5:"owner";s:0:"";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:10:"base_theme";s:9:"chameleon";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:6:"marvin";}', 'fit' => '31', @@ -13850,7 +21501,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":13:{s:8:"filename";s:37:"themes/garland/minnelli/minnelli.info";s:4:"name";s:8:"minnelli";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:6:"engine";s:11:"phptemplate";s:10:"base_theme";s:7:"garland";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":13:{s:8:"filename";s:37:"themes/garland/minnelli/minnelli.info";s:4:"name";s:8:"minnelli";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:6:"engine";s:11:"phptemplate";s:10:"base_theme";s:7:"garland";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:8:"minnelli";}', 'fit' => '31', @@ -13872,7 +21523,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/pushbutton/pushbutton.info";s:4:"name";s:10:"pushbutton";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/pushbutton/pushbutton.info";s:4:"name";s:10:"pushbutton";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:10:"pushbutton";}', 'fit' => '31', @@ -14576,7 +22227,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/bluemarine/bluemarine.info";s:4:"name";s:10:"bluemarine";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/bluemarine/bluemarine.info";s:4:"name";s:10:"bluemarine";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:10:"bluemarine";}', 'fit' => '31', @@ -14598,7 +22249,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":11:{s:8:"filename";s:31:"themes/chameleon/chameleon.info";s:4:"name";s:9:"chameleon";s:4:"type";s:5:"theme";s:5:"owner";s:32:"themes/chameleon/chameleon.theme";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":11:{s:8:"filename";s:31:"themes/chameleon/chameleon.info";s:4:"name";s:9:"chameleon";s:4:"type";s:5:"theme";s:5:"owner";s:32:"themes/chameleon/chameleon.theme";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:9:"chameleon";}', 'fit' => '31', @@ -14620,7 +22271,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:7:"garland";}', 'fit' => '31', @@ -14664,7 +22315,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:35:"themes/chameleon/marvin/marvin.info";s:4:"name";s:6:"marvin";s:4:"type";s:5:"theme";s:5:"owner";s:0:"";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:10:"base_theme";s:9:"chameleon";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:35:"themes/chameleon/marvin/marvin.info";s:4:"name";s:6:"marvin";s:4:"type";s:5:"theme";s:5:"owner";s:0:"";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:10:"base_theme";s:9:"chameleon";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:6:"marvin";}', 'fit' => '31', @@ -14686,7 +22337,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":13:{s:8:"filename";s:37:"themes/garland/minnelli/minnelli.info";s:4:"name";s:8:"minnelli";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:6:"engine";s:11:"phptemplate";s:10:"base_theme";s:7:"garland";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":13:{s:8:"filename";s:37:"themes/garland/minnelli/minnelli.info";s:4:"name";s:8:"minnelli";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:6:"engine";s:11:"phptemplate";s:10:"base_theme";s:7:"garland";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:8:"minnelli";}', 'fit' => '31', @@ -14708,7 +22359,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/pushbutton/pushbutton.info";s:4:"name";s:10:"pushbutton";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:33:"themes/pushbutton/pushbutton.info";s:4:"name";s:10:"pushbutton";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:8:"throttle";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:10:"pushbutton";}', 'fit' => '31', @@ -14725,6 +22376,160 @@ 'weight' => '0', 'file' => 'modules/system/system.admin.inc', )) +->values(array( + 'path' => 'admin/build/translate', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:1:{i:0;s:32:"locale_translate_overview_screen";}', + 'fit' => '7', + 'number_parts' => '3', + 'tab_parent' => '', + 'tab_root' => 'admin/build/translate', + 'title' => 'Translate interface', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '6', + 'block_callback' => '', + 'description' => 'Translate the built in interface and optionally other text.', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/delete/%', + 'load_functions' => 'a:1:{i:4;N;}', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:2:{i:0;s:28:"locale_translate_delete_page";i:1;i:4;}', + 'fit' => '30', + 'number_parts' => '5', + 'tab_parent' => '', + 'tab_root' => 'admin/build/translate/delete/%', + 'title' => 'Delete string', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/edit/%', + 'load_functions' => 'a:1:{i:4;N;}', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:3:{i:0;s:15:"drupal_get_form";i:1;s:26:"locale_translate_edit_form";i:2;i:4;}', + 'fit' => '30', + 'number_parts' => '5', + 'tab_parent' => '', + 'tab_root' => 'admin/build/translate/edit/%', + 'title' => 'Edit string', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/export', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:1:{i:0;s:30:"locale_translate_export_screen";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/build/translate', + 'tab_root' => 'admin/build/translate', + 'title' => 'Export', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '30', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/import', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:2:{i:0;s:15:"drupal_get_form";i:1;s:28:"locale_translate_import_form";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/build/translate', + 'tab_root' => 'admin/build/translate', + 'title' => 'Import', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '20', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/overview', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:1:{i:0;s:32:"locale_translate_overview_screen";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/build/translate', + 'tab_root' => 'admin/build/translate', + 'title' => 'Overview', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '136', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/build/translate/search', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"translate interface";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:1:{i:0;s:28:"locale_translate_seek_screen";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/build/translate', + 'tab_root' => 'admin/build/translate', + 'title' => 'Search', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '10', + 'file' => '', +)) ->values(array( 'path' => 'admin/by-module', 'load_functions' => '', @@ -16706,17 +24511,61 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_integer_selectlist/remove', + 'path' => 'admin/content/node-type/story/fields/field_test_integer_selectlist/remove', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', + 'page_callback' => 'drupal_get_form', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:29:"field_test_integer_selectlist";}', + 'fit' => '127', + 'number_parts' => '7', + 'tab_parent' => '', + 'tab_root' => 'admin/content/node-type/story/fields/field_test_integer_selectlist/remove', + 'title' => 'Remove field', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => 'sites/all/modules/cck/includes/content.admin.inc', +)) +->values(array( + 'path' => 'admin/content/node-type/story/fields/field_test_link', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', + 'page_callback' => 'drupal_get_form', + 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:15:"field_test_link";}', + 'fit' => '63', + 'number_parts' => '6', + 'tab_parent' => 'admin/content/node-type/story/fields', + 'tab_root' => 'admin/content/node-type/story', + 'title' => 'Link Field', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => 'sites/all/modules/cck/includes/content.admin.inc', +)) +->values(array( + 'path' => 'admin/content/node-type/story/fields/field_test_link/remove', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:29:"field_test_integer_selectlist";}', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:15:"field_test_link";}', 'fit' => '127', 'number_parts' => '7', 'tab_parent' => '', - 'tab_root' => 'admin/content/node-type/story/fields/field_test_integer_selectlist/remove', + 'tab_root' => 'admin/content/node-type/story/fields/field_test_link/remove', 'title' => 'Remove field', 'title_callback' => 't', 'title_arguments' => '', @@ -16728,18 +24577,18 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_link', + 'path' => 'admin/content/node-type/story/fields/field_test_phone', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:15:"field_test_link";}', + 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:16:"field_test_phone";}', 'fit' => '63', 'number_parts' => '6', 'tab_parent' => 'admin/content/node-type/story/fields', 'tab_root' => 'admin/content/node-type/story', - 'title' => 'Link Field', + 'title' => 'Phone Field', 'title_callback' => 't', 'title_arguments' => '', 'type' => '128', @@ -16750,17 +24599,17 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_link/remove', + 'path' => 'admin/content/node-type/story/fields/field_test_phone/remove', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:15:"field_test_link";}', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:16:"field_test_phone";}', 'fit' => '127', 'number_parts' => '7', 'tab_parent' => '', - 'tab_root' => 'admin/content/node-type/story/fields/field_test_link/remove', + 'tab_root' => 'admin/content/node-type/story/fields/field_test_phone/remove', 'title' => 'Remove field', 'title_callback' => 't', 'title_arguments' => '', @@ -16772,18 +24621,18 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_phone', + 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:16:"field_test_phone";}', + 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:31:"field_test_text_single_checkbox";}', 'fit' => '63', 'number_parts' => '6', 'tab_parent' => 'admin/content/node-type/story/fields', 'tab_root' => 'admin/content/node-type/story', - 'title' => 'Phone Field', + 'title' => 'Text Single Checkbox Field', 'title_callback' => 't', 'title_arguments' => '', 'type' => '128', @@ -16794,17 +24643,17 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_phone/remove', + 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox/remove', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:16:"field_test_phone";}', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:31:"field_test_text_single_checkbox";}', 'fit' => '127', 'number_parts' => '7', 'tab_parent' => '', - 'tab_root' => 'admin/content/node-type/story/fields/field_test_phone/remove', + 'tab_root' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox/remove', 'title' => 'Remove field', 'title_callback' => 't', 'title_arguments' => '', @@ -16816,18 +24665,18 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox', + 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox2', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:31:"field_test_text_single_checkbox";}', + 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:5:"story";i:2;s:32:"field_test_text_single_checkbox2";}', 'fit' => '63', 'number_parts' => '6', 'tab_parent' => 'admin/content/node-type/story/fields', 'tab_root' => 'admin/content/node-type/story', - 'title' => 'Text Single Checkbox Field', + 'title' => 'Text Single Checkbox Field 2', 'title_callback' => 't', 'title_arguments' => '', 'type' => '128', @@ -16838,17 +24687,17 @@ 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) ->values(array( - 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox/remove', + 'path' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox2/remove', 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => 'user_access', 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', 'page_callback' => 'drupal_get_form', - 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:31:"field_test_text_single_checkbox";}', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:5:"story";i:2;s:32:"field_test_text_single_checkbox2";}', 'fit' => '127', 'number_parts' => '7', 'tab_parent' => '', - 'tab_root' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox/remove', + 'tab_root' => 'admin/content/node-type/story/fields/field_test_text_single_checkbox2/remove', 'title' => 'Remove field', 'title_callback' => 't', 'title_arguments' => '', @@ -17563,6 +25412,50 @@ 'weight' => '0', 'file' => 'sites/all/modules/cck/includes/content.admin.inc', )) +->values(array( + 'path' => 'admin/content/node-type/test-planet/fields/field_test_text_single_checkbox', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', + 'page_callback' => 'drupal_get_form', + 'page_arguments' => 'a:3:{i:0;s:23:"content_field_edit_form";i:1;s:11:"test_planet";i:2;s:31:"field_test_text_single_checkbox";}', + 'fit' => '63', + 'number_parts' => '6', + 'tab_parent' => 'admin/content/node-type/test-planet/fields', + 'tab_root' => 'admin/content/node-type/test-planet', + 'title' => 'Text Single Checkbox Field', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => 'sites/all/modules/cck/includes/content.admin.inc', +)) +->values(array( + 'path' => 'admin/content/node-type/test-planet/fields/field_test_text_single_checkbox/remove', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:24:"administer content types";}', + 'page_callback' => 'drupal_get_form', + 'page_arguments' => 'a:3:{i:0;s:25:"content_field_remove_form";i:1;s:11:"test_planet";i:2;s:31:"field_test_text_single_checkbox";}', + 'fit' => '127', + 'number_parts' => '7', + 'tab_parent' => '', + 'tab_root' => 'admin/content/node-type/test-planet/fields/field_test_text_single_checkbox/remove', + 'title' => 'Remove field', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => 'sites/all/modules/cck/includes/content.admin.inc', +)) ->values(array( 'path' => 'admin/content/node-type/test-story', 'load_functions' => '', @@ -18905,6 +26798,160 @@ 'weight' => '0', 'file' => 'modules/system/system.admin.inc', )) +->values(array( + 'path' => 'admin/settings/imageapi', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:19:"administer imageapi";}', + 'page_callback' => 'drupal_get_form', + 'page_arguments' => 'a:1:{i:0;s:17:"imageapi_settings";}', + 'fit' => '7', + 'number_parts' => '3', + 'tab_parent' => '', + 'tab_root' => 'admin/settings/imageapi', + 'title' => 'ImageAPI', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '6', + 'block_callback' => '', + 'description' => 'Configure ImageAPI.', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:2:{i:0;s:15:"drupal_get_form";i:1;s:30:"locale_languages_overview_form";}', + 'fit' => '7', + 'number_parts' => '3', + 'tab_parent' => '', + 'tab_root' => 'admin/settings/language', + 'title' => 'Languages', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '6', + 'block_callback' => '', + 'description' => 'Configure languages for content and the user interface.', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language/add', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:1:{i:0;s:27:"locale_languages_add_screen";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/settings/language', + 'tab_root' => 'admin/settings/language', + 'title' => 'Add language', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '5', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language/configure', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:2:{i:0;s:15:"drupal_get_form";i:1;s:31:"locale_languages_configure_form";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/settings/language', + 'tab_root' => 'admin/settings/language', + 'title' => 'Configure', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '10', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language/delete/%', + 'load_functions' => 'a:1:{i:4;N;}', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:3:{i:0;s:15:"drupal_get_form";i:1;s:28:"locale_languages_delete_form";i:2;i:4;}', + 'fit' => '30', + 'number_parts' => '5', + 'tab_parent' => '', + 'tab_root' => 'admin/settings/language/delete/%', + 'title' => 'Confirm', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language/edit/%', + 'load_functions' => 'a:1:{i:4;N;}', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:3:{i:0;s:15:"drupal_get_form";i:1;s:26:"locale_languages_edit_form";i:2;i:4;}', + 'fit' => '30', + 'number_parts' => '5', + 'tab_parent' => '', + 'tab_root' => 'admin/settings/language/edit/%', + 'title' => 'Edit language', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) +->values(array( + 'path' => 'admin/settings/language/overview', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:20:"administer languages";}', + 'page_callback' => 'locale_inc_callback', + 'page_arguments' => 'a:2:{i:0;s:15:"drupal_get_form";i:1;s:30:"locale_languages_overview_form";}', + 'fit' => '15', + 'number_parts' => '4', + 'tab_parent' => 'admin/settings/language', + 'tab_root' => 'admin/settings/language', + 'title' => 'List', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '136', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) ->values(array( 'path' => 'admin/settings/logging', 'load_functions' => '', @@ -19917,6 +27964,28 @@ 'weight' => '0', 'file' => 'sites/all/modules/cck/includes/content.node_form.inc', )) +->values(array( + 'path' => 'core/modules/simpletest/files/imagecache', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => '_imagecache_menu_access_public_files', + 'access_arguments' => 'a:0:{}', + 'page_callback' => 'imagecache_cache', + 'page_arguments' => 'a:0:{}', + 'fit' => '31', + 'number_parts' => '5', + 'tab_parent' => '', + 'tab_root' => 'core/modules/simpletest/files/imagecache', + 'title' => '', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) ->values(array( 'path' => 'email/%/%', 'load_functions' => 'a:2:{i:1;s:9:"node_load";i:2;N;}', @@ -20401,6 +28470,28 @@ 'weight' => '0', 'file' => '', )) +->values(array( + 'path' => 'node/%/translate', + 'load_functions' => 'a:1:{i:1;s:9:"node_load";}', + 'to_arg_functions' => '', + 'access_callback' => '_translation_tab_access', + 'access_arguments' => 'a:1:{i:0;i:1;}', + 'page_callback' => 'translation_node_overview', + 'page_arguments' => 'a:1:{i:0;i:1;}', + 'fit' => '5', + 'number_parts' => '3', + 'tab_parent' => 'node/%', + 'tab_root' => 'node/%', + 'title' => 'Translate', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '128', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '2', + 'file' => 'modules/translation/translation.pages.inc', +)) ->values(array( 'path' => 'node/%/view', 'load_functions' => 'a:1:{i:1;s:9:"node_load";}', @@ -20731,6 +28822,28 @@ 'weight' => '0', 'file' => '', )) +->values(array( + 'path' => 'system/files/imagecache', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => '1', + 'access_arguments' => 'a:0:{}', + 'page_callback' => 'imagecache_cache_private', + 'page_arguments' => 'a:0:{}', + 'fit' => '7', + 'number_parts' => '3', + 'tab_parent' => '', + 'tab_root' => 'system/files/imagecache', + 'title' => '', + 'title_callback' => 't', + 'title_arguments' => '', + 'type' => '4', + 'block_callback' => '', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'file' => '', +)) ->values(array( 'path' => 'taxonomy/autocomplete', 'load_functions' => '', @@ -21390,17 +29503,34 @@ 'translate' => '0', )) ->values(array( - 'nid' => '8', - 'vid' => '10', - 'type' => 'test_planet', + 'nid' => '8', + 'vid' => '10', + 'type' => 'test_planet', + 'language' => '', + 'title' => '', + 'uid' => '1', + 'status' => '1', + 'created' => '1388271527', + 'changed' => '1390096401', + 'comment' => '0', + 'promote' => '0', + 'moderate' => '0', + 'sticky' => '0', + 'tnid' => '0', + 'translate' => '0', +)) +->values(array( + 'nid' => '9', + 'vid' => '12', + 'type' => 'story', 'language' => '', - 'title' => '', + 'title' => 'Once upon a time', 'uid' => '1', 'status' => '1', - 'created' => '1388271527', - 'changed' => '1390096401', - 'comment' => '0', - 'promote' => '0', + 'created' => '1444671588', + 'changed' => '1444671588', + 'comment' => '2', + 'promote' => '1', 'moderate' => '0', 'sticky' => '0', 'tnid' => '0', @@ -21516,6 +29646,14 @@ 'primary key' => array( 'nid', ), + 'indexes' => array( + 'comment_count' => array( + 'comment_count', + ), + 'last_comment_uid' => array( + 'last_comment_uid', + ), + ), 'mysql_character_set' => 'utf8', )); @@ -21541,6 +29679,13 @@ 'last_comment_uid' => '1', 'comment_count' => '0', )) +->values(array( + 'nid' => '9', + 'last_comment_timestamp' => '1444671588', + 'last_comment_name' => NULL, + 'last_comment_uid' => '1', + 'comment_count' => '0', +)) ->execute(); $connection->schema()->createTable('node_counter', array( @@ -21773,6 +29918,17 @@ 'timestamp' => '1390095701', 'format' => '1', )) +->values(array( + 'nid' => '9', + 'vid' => '12', + 'uid' => '1', + 'title' => 'Once upon a time', + 'body' => 'Come on kid, go to sleep.', + 'teaser' => 'Come on kid, go to sleep.', + 'log' => '', + 'timestamp' => '1444671588', + 'format' => '1', +)) ->execute(); $connection->schema()->createTable('node_type', array( @@ -22777,7 +30933,7 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:10:"Aggregator";s:11:"description";s:57:"Aggregates syndicated content (RSS, RDF, and Atom feeds).";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:10:"Aggregator";s:11:"description";s:57:"Aggregates syndicated content (RSS, RDF, and Atom feeds).";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/block/block.module', @@ -22789,7 +30945,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:5:"Block";s:11:"description";s:62:"Controls the boxes that are displayed around the main content.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:5:"Block";s:11:"description";s:62:"Controls the boxes that are displayed around the main content.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/blog/blog.module', @@ -22801,7 +30957,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Blog";s:11:"description";s:69:"Enables keeping easily and regularly updated user web pages or blogs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Blog";s:11:"description";s:69:"Enables keeping easily and regularly updated user web pages or blogs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/blogapi/blogapi.module', @@ -22813,7 +30969,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:8:"Blog API";s:11:"description";s:79:"Allows users to post content using applications that support XML-RPC blog APIs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:8:"Blog API";s:11:"description";s:79:"Allows users to post content using applications that support XML-RPC blog APIs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/book/book.module', @@ -22825,7 +30981,7 @@ 'bootstrap' => '0', 'schema_version' => '6000', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Book";s:11:"description";s:63:"Allows users to structure site pages in a hierarchy or outline.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Book";s:11:"description";s:63:"Allows users to structure site pages in a hierarchy or outline.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/color/color.module', @@ -22837,7 +30993,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:5:"Color";s:11:"description";s:61:"Allows the user to change the color scheme of certain themes.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:5:"Color";s:11:"description";s:61:"Allows the user to change the color scheme of certain themes.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/comment/comment.module', @@ -22847,9 +31003,9 @@ 'status' => '1', 'throttle' => '0', 'bootstrap' => '0', - 'schema_version' => '6001', + 'schema_version' => '6005', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Comment";s:11:"description";s:57:"Allows users to comment on and discuss published content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Comment";s:11:"description";s:57:"Allows users to comment on and discuss published content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/contact/contact.module', @@ -22861,7 +31017,7 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Contact";s:11:"description";s:61:"Enables the use of both personal and site-wide contact forms.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Contact";s:11:"description";s:61:"Enables the use of both personal and site-wide contact forms.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/dblog/dblog.module', @@ -22873,7 +31029,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:16:"Database logging";s:11:"description";s:47:"Logs and records system events to the database.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:16:"Database logging";s:11:"description";s:47:"Logs and records system events to the database.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/filter/filter.module', @@ -22885,7 +31041,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Filter";s:11:"description";s:60:"Handles the filtering of content in preparation for display.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Filter";s:11:"description";s:60:"Handles the filtering of content in preparation for display.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/forum/forum.module', @@ -22897,7 +31053,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:5:"Forum";s:11:"description";s:50:"Enables threaded discussions about general topics.";s:12:"dependencies";a:2:{i:0;s:8:"taxonomy";i:1;s:7:"comment";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:5:"Forum";s:11:"description";s:50:"Enables threaded discussions about general topics.";s:12:"dependencies";a:2:{i:0;s:8:"taxonomy";i:1;s:7:"comment";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/help/help.module', @@ -22909,19 +31065,19 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Help";s:11:"description";s:35:"Manages the display of online help.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Help";s:11:"description";s:35:"Manages the display of online help.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/locale/locale.module', 'name' => 'locale', 'type' => 'module', 'owner' => '', - 'status' => '0', + 'status' => '1', 'throttle' => '0', 'bootstrap' => '0', - 'schema_version' => '-1', + 'schema_version' => '6007', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Locale";s:11:"description";s:119:"Adds language handling functionality and enables the translation of the user interface to languages other than English.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Locale";s:11:"description";s:119:"Adds language handling functionality and enables the translation of the user interface to languages other than English.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/menu/menu.module', @@ -22933,7 +31089,7 @@ 'bootstrap' => '0', 'schema_version' => '6000', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Menu";s:11:"description";s:60:"Allows administrators to customize the site navigation menu.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Menu";s:11:"description";s:60:"Allows administrators to customize the site navigation menu.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/node/node.module', @@ -22945,7 +31101,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Node";s:11:"description";s:66:"Allows content to be submitted to the site and displayed on pages.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Node";s:11:"description";s:66:"Allows content to be submitted to the site and displayed on pages.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/openid/openid.module', @@ -22957,7 +31113,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"OpenID";s:11:"description";s:48:"Allows users to log into your site using OpenID.";s:7:"version";s:4:"6.35";s:7:"package";s:15:"Core - optional";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"OpenID";s:11:"description";s:48:"Allows users to log into your site using OpenID.";s:7:"version";s:4:"6.37";s:7:"package";s:15:"Core - optional";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/path/path.module', @@ -22969,7 +31125,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Path";s:11:"description";s:28:"Allows users to rename URLs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Path";s:11:"description";s:28:"Allows users to rename URLs.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/php/php.module', @@ -22981,7 +31137,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:10:"PHP filter";s:11:"description";s:50:"Allows embedded PHP code/snippets to be evaluated.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:10:"PHP filter";s:11:"description";s:50:"Allows embedded PHP code/snippets to be evaluated.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/ping/ping.module', @@ -22993,7 +31149,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Ping";s:11:"description";s:51:"Alerts other sites when your site has been updated.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Ping";s:11:"description";s:51:"Alerts other sites when your site has been updated.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/poll/poll.module', @@ -23005,7 +31161,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Poll";s:11:"description";s:95:"Allows your site to capture votes on different topics in the form of multiple choice questions.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Poll";s:11:"description";s:95:"Allows your site to capture votes on different topics in the form of multiple choice questions.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/profile/profile.module', @@ -23017,7 +31173,7 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Profile";s:11:"description";s:36:"Supports configurable user profiles.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Profile";s:11:"description";s:36:"Supports configurable user profiles.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/search/search.module', @@ -23029,7 +31185,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Search";s:11:"description";s:36:"Enables site-wide keyword searching.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Search";s:11:"description";s:36:"Enables site-wide keyword searching.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/statistics/statistics.module', @@ -23041,7 +31197,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:10:"Statistics";s:11:"description";s:37:"Logs access statistics for your site.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:10:"Statistics";s:11:"description";s:37:"Logs access statistics for your site.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/syslog/syslog.module', @@ -23053,7 +31209,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Syslog";s:11:"description";s:41:"Logs and records system events to syslog.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Syslog";s:11:"description";s:41:"Logs and records system events to syslog.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/system/system.module', @@ -23065,7 +31221,7 @@ 'bootstrap' => '0', 'schema_version' => '6055', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"System";s:11:"description";s:54:"Handles general site configuration for administrators.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"System";s:11:"description";s:54:"Handles general site configuration for administrators.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/taxonomy/taxonomy.module', @@ -23077,7 +31233,7 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:8:"Taxonomy";s:11:"description";s:38:"Enables the categorization of content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:8:"Taxonomy";s:11:"description";s:38:"Enables the categorization of content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/throttle/throttle.module', @@ -23089,7 +31245,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:8:"Throttle";s:11:"description";s:66:"Handles the auto-throttling mechanism, to control site congestion.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:8:"Throttle";s:11:"description";s:66:"Handles the auto-throttling mechanism, to control site congestion.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/tracker/tracker.module', @@ -23101,19 +31257,19 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Tracker";s:11:"description";s:43:"Enables tracking of recent posts for users.";s:12:"dependencies";a:1:{i:0;s:7:"comment";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Tracker";s:11:"description";s:43:"Enables tracking of recent posts for users.";s:12:"dependencies";a:1:{i:0;s:7:"comment";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/translation/translation.module', 'name' => 'translation', 'type' => 'module', 'owner' => '', - 'status' => '0', + 'status' => '1', 'throttle' => '0', 'bootstrap' => '0', - 'schema_version' => '-1', + 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:19:"Content translation";s:11:"description";s:57:"Allows content to be translated into different languages.";s:12:"dependencies";a:1:{i:0;s:6:"locale";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:19:"Content translation";s:11:"description";s:57:"Allows content to be translated into different languages.";s:12:"dependencies";a:1:{i:0;s:6:"locale";}s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/trigger/trigger.module', @@ -23125,7 +31281,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Trigger";s:11:"description";s:90:"Enables actions to be fired on certain system events, such as when new content is created.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Trigger";s:11:"description";s:90:"Enables actions to be fired on certain system events, such as when new content is created.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/update/update.module', @@ -23137,7 +31293,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:13:"Update status";s:11:"description";s:88:"Checks the status of available updates for Drupal and your installed modules and themes.";s:7:"version";s:4:"6.35";s:7:"package";s:15:"Core - optional";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:13:"Update status";s:11:"description";s:88:"Checks the status of available updates for Drupal and your installed modules and themes.";s:7:"version";s:4:"6.37";s:7:"package";s:15:"Core - optional";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/upload/upload.module', @@ -23149,7 +31305,7 @@ 'bootstrap' => '0', 'schema_version' => '6000', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Upload";s:11:"description";s:51:"Allows users to upload and attach files to content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Upload";s:11:"description";s:51:"Allows users to upload and attach files to content.";s:7:"package";s:15:"Core - optional";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'modules/user/user.module', @@ -23161,7 +31317,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"User";s:11:"description";s:47:"Manages the user registration and login system.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"User";s:11:"description";s:47:"Manages the user registration and login system.";s:7:"package";s:15:"Core - required";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/content.module', @@ -23171,9 +31327,9 @@ 'status' => '1', 'throttle' => '0', 'bootstrap' => '0', - 'schema_version' => '6001', + 'schema_version' => '6010', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:7:"Content";s:11:"description";s:50:"Allows administrators to define new content types.";s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:7:"Content";s:11:"description";s:50:"Allows administrators to define new content types.";s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/content_copy/content_copy.module', @@ -23185,7 +31341,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:12:"Content Copy";s:11:"description";s:51:"Enables ability to import/export field definitions.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:12:"Content Copy";s:11:"description";s:51:"Enables ability to import/export field definitions.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/content_permissions/content_permissions.module', @@ -23197,7 +31353,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:19:"Content Permissions";s:11:"description";s:43:"Set field-level permissions for CCK fields.";s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:19:"Content Permissions";s:11:"description";s:43:"Set field-level permissions for CCK fields.";s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/fieldgroup/fieldgroup.module', @@ -23209,7 +31365,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:10:"Fieldgroup";s:11:"description";s:37:"Create display groups for CCK fields.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:10:"Fieldgroup";s:11:"description";s:37:"Create display groups for CCK fields.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/nodereference/nodereference.module', @@ -23221,7 +31377,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:14:"Node Reference";s:11:"description";s:59:"Defines a field type for referencing one node from another.";s:12:"dependencies";a:3:{i:0;s:7:"content";i:1;s:4:"text";i:2;s:13:"optionwidgets";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:14:"Node Reference";s:11:"description";s:59:"Defines a field type for referencing one node from another.";s:12:"dependencies";a:3:{i:0;s:7:"content";i:1;s:4:"text";i:2;s:13:"optionwidgets";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/number/number.module', @@ -23233,7 +31389,7 @@ 'bootstrap' => '0', 'schema_version' => '6000', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:6:"Number";s:11:"description";s:28:"Defines numeric field types.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:6:"Number";s:11:"description";s:28:"Defines numeric field types.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/optionwidgets/optionwidgets.module', @@ -23245,7 +31401,7 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:14:"Option Widgets";s:11:"description";s:82:"Defines selection, check box and radio button widgets for text and numeric fields.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:14:"Option Widgets";s:11:"description";s:82:"Defines selection, check box and radio button widgets for text and numeric fields.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/text/text.module', @@ -23257,7 +31413,7 @@ 'bootstrap' => '0', 'schema_version' => '6003', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:4:"Text";s:11:"description";s:32:"Defines simple text field types.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:4:"Text";s:11:"description";s:32:"Defines simple text field types.";s:12:"dependencies";a:1:{i:0;s:7:"content";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/cck/modules/userreference/userreference.module', @@ -23269,7 +31425,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:14:"User Reference";s:11:"description";s:56:"Defines a field type for referencing a user from a node.";s:12:"dependencies";a:3:{i:0;s:7:"content";i:1;s:4:"text";i:2;s:13:"optionwidgets";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:7:"6.x-2.9";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1294407979";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:10:{s:4:"name";s:14:"User Reference";s:11:"description";s:56:"Defines a field type for referencing a user from a node.";s:12:"dependencies";a:3:{i:0;s:7:"content";i:1;s:4:"text";i:2;s:13:"optionwidgets";}s:7:"package";s:3:"CCK";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-2.10";s:7:"project";s:3:"cck";s:9:"datestamp";s:10:"1434568159";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/date/date/date.module', @@ -23499,6 +31655,30 @@ 'weight' => '0', 'info' => 'a:10:{s:4:"name";s:8:"ImageAPI";s:11:"description";s:38:"ImageAPI supporting multiple toolkits.";s:7:"package";s:10:"ImageCache";s:4:"core";s:3:"6.x";s:3:"php";s:3:"5.1";s:7:"version";s:8:"6.x-1.10";s:7:"project";s:8:"imageapi";s:9:"datestamp";s:10:"1305563215";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}}', )) +->values(array( + 'filename' => 'sites/all/modules/imageapi/imageapi_gd.module', + 'name' => 'imageapi_gd', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'throttle' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => "a:10:{s:4:\"name\";s:12:\"ImageAPI GD2\";s:11:\"description\";s:49:\"Uses PHP's built-in GD2 image processing support.\";s:7:\"package\";s:10:\"ImageCache\";s:4:\"core\";s:3:\"6.x\";s:7:\"version\";s:8:\"6.x-1.10\";s:7:\"project\";s:8:\"imageapi\";s:9:\"datestamp\";s:10:\"1305563215\";s:12:\"dependencies\";a:0:{}s:10:\"dependents\";a:0:{}s:3:\"php\";s:5:\"4.3.5\";}", +)) +->values(array( + 'filename' => 'sites/all/modules/imageapi/imageapi_imagemagick.module', + 'name' => 'imageapi_imagemagick', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'throttle' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => 'a:10:{s:4:"name";s:20:"ImageAPI ImageMagick";s:11:"description";s:33:"Command Line ImageMagick support.";s:7:"package";s:10:"ImageCache";s:4:"core";s:3:"6.x";s:7:"version";s:8:"6.x-1.10";s:7:"project";s:8:"imageapi";s:9:"datestamp";s:10:"1305563215";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', +)) ->values(array( 'filename' => 'sites/all/modules/imagecache/imagecache.module', 'name' => 'imagecache', @@ -23509,7 +31689,19 @@ 'bootstrap' => '0', 'schema_version' => '6001', 'weight' => '0', - 'info' => 'a:10:{s:4:"name";s:8:"ImageAPI";s:11:"description";s:38:"ImageAPI supporting multiple toolkits.";s:7:"package";s:10:"ImageCache";s:4:"core";s:3:"6.x";s:3:"php";s:3:"5.1";s:7:"version";s:8:"6.x-1.10";s:7:"project";s:8:"imageapi";s:9:"datestamp";s:10:"1305563215";s:12:"dependencies";a:0:{}s:10:"dependents";a:0:{}}', + 'info' => 'a:10:{s:4:"name";s:10:"ImageCache";s:11:"description";s:36:"Dynamic image manipulator and cache.";s:7:"package";s:10:"ImageCache";s:12:"dependencies";a:1:{i:0;s:8:"imageapi";}s:4:"core";s:3:"6.x";s:7:"version";s:11:"6.x-2.0-rc1";s:7:"project";s:10:"imagecache";s:9:"datestamp";s:10:"1337742655";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', +)) +->values(array( + 'filename' => 'sites/all/modules/imagecache/imagecache_ui.module', + 'name' => 'imagecache_ui', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'throttle' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => 'a:10:{s:4:"name";s:13:"ImageCache UI";s:11:"description";s:26:"ImageCache User Interface.";s:12:"dependencies";a:2:{i:0;s:10:"imagecache";i:1;s:8:"imageapi";}s:7:"package";s:10:"ImageCache";s:4:"core";s:3:"6.x";s:7:"version";s:11:"6.x-2.0-rc1";s:7:"project";s:10:"imagecache";s:9:"datestamp";s:10:"1337742655";s:10:"dependents";a:0:{}s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'sites/all/modules/imagefield/imagefield.module', @@ -23617,7 +31809,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:13:{s:4:"name";s:10:"Bluemarine";s:11:"description";s:66:"Table-based multi-column theme with a marine and ash color scheme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/bluemarine/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/bluemarine/script.js";}s:10:"screenshot";s:32:"themes/bluemarine/screenshot.png";s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'themes/chameleon/chameleon.info', @@ -23629,7 +31821,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:12:{s:4:"name";s:9:"Chameleon";s:11:"description";s:42:"Minimalist tabled theme with light colors.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:8:"features";a:4:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";}s:11:"stylesheets";a:1:{s:3:"all";a:2:{s:9:"style.css";s:26:"themes/chameleon/style.css";s:10:"common.css";s:27:"themes/chameleon/common.css";}}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"scripts";a:1:{s:9:"script.js";s:26:"themes/chameleon/script.js";}s:10:"screenshot";s:31:"themes/chameleon/screenshot.png";s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'themes/chameleon/marvin/marvin.info', @@ -23641,7 +31833,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:13:{s:4:"name";s:6:"Marvin";s:11:"description";s:31:"Boxy tabled theme in all grays.";s:7:"regions";a:2:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";}s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:9:"chameleon";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:33:"themes/chameleon/marvin/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/chameleon/marvin/script.js";}s:10:"screenshot";s:38:"themes/chameleon/marvin/screenshot.png";s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'themes/garland/garland.info', @@ -23653,7 +31845,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:13:{s:4:"name";s:7:"Garland";s:11:"description";s:66:"Tableless, recolorable, multi-column, fluid width theme (default).";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:24:"themes/garland/script.js";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"4.3.5";}', )) ->values(array( 'filename' => 'themes/garland/minnelli/minnelli.info', @@ -23665,7 +31857,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}', + 'info' => 'a:14:{s:4:"name";s:8:"Minnelli";s:11:"description";s:56:"Tableless, recolorable, multi-column, fixed width theme.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:10:"base theme";s:7:"garland";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:12:"minnelli.css";s:36:"themes/garland/minnelli/minnelli.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:7:"scripts";a:1:{s:9:"script.js";s:33:"themes/garland/minnelli/script.js";}s:10:"screenshot";s:38:"themes/garland/minnelli/screenshot.png";s:3:"php";s:5:"4.3.5";s:6:"engine";s:11:"phptemplate";}', )) ->values(array( 'filename' => 'themes/pushbutton/pushbutton.info', @@ -23677,7 +31869,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.35";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1426707431";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}', + 'info' => 'a:13:{s:4:"name";s:10:"Pushbutton";s:11:"description";s:52:"Tabled, multi-column theme in blue and orange tones.";s:7:"version";s:4:"6.37";s:4:"core";s:3:"6.x";s:6:"engine";s:11:"phptemplate";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1440020160";s:7:"regions";a:5:{s:4:"left";s:12:"Left sidebar";s:5:"right";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";}s:8:"features";a:10:{i:0;s:20:"comment_user_picture";i:1;s:7:"favicon";i:2;s:7:"mission";i:3;s:4:"logo";i:4;s:4:"name";i:5;s:17:"node_user_picture";i:6;s:6:"search";i:7;s:6:"slogan";i:8;s:13:"primary_links";i:9;s:15:"secondary_links";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"style.css";s:27:"themes/pushbutton/style.css";}}s:7:"scripts";a:1:{s:9:"script.js";s:27:"themes/pushbutton/script.js";}s:10:"screenshot";s:32:"themes/pushbutton/screenshot.png";s:3:"php";s:5:"4.3.5";}', )) ->execute(); @@ -24287,8 +32479,8 @@ 'signature' => '', 'signature_format' => '0', 'created' => '0', - 'access' => '0', - 'login' => '0', + 'access' => '1444943005', + 'login' => '1444943005', 'status' => '1', 'timezone' => NULL, 'language' => '', @@ -24587,77 +32779,245 @@ 'name' => 'comment_anonymous_article', 'value' => 'i:0;', )) +->values(array( + 'name' => 'comment_anonymous_company', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_anonymous_employee', + 'value' => 'i:0;', +)) ->values(array( 'name' => 'comment_anonymous_page', 'value' => 'i:0;', )) +->values(array( + 'name' => 'comment_anonymous_sponsor', + 'value' => 'i:0;', +)) ->values(array( 'name' => 'comment_anonymous_story', 'value' => 'i:1;', )) +->values(array( + 'name' => 'comment_anonymous_test_event', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_anonymous_test_page', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_anonymous_test_planet', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_anonymous_test_story', + 'value' => 'i:0;', +)) ->values(array( 'name' => 'comment_article', 'value' => 's:1:"2";', )) ->values(array( 'name' => 'comment_controls_article', - 'value' => 's:1:"3";', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_company', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_employee', + 'value' => 'i:3;', )) ->values(array( 'name' => 'comment_controls_page', 'value' => 's:1:"3";', )) +->values(array( + 'name' => 'comment_controls_sponsor', + 'value' => 'i:3;', +)) ->values(array( 'name' => 'comment_controls_story', - 'value' => 's:1:"3";', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_test_event', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_test_page', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_test_planet', + 'value' => 'i:3;', +)) +->values(array( + 'name' => 'comment_controls_test_story', + 'value' => 'i:3;', )) ->values(array( 'name' => 'comment_default_mode_article', - 'value' => 's:1:"4";', + 'value' => 'i:4;', +)) +->values(array( + 'name' => 'comment_default_mode_company', + 'value' => 'i:4;', +)) +->values(array( + 'name' => 'comment_default_mode_employee', + 'value' => 'i:4;', )) ->values(array( 'name' => 'comment_default_mode_page', 'value' => 's:1:"4";', )) +->values(array( + 'name' => 'comment_default_mode_sponsor', + 'value' => 'i:4;', +)) ->values(array( 'name' => 'comment_default_mode_story', 'value' => 's:1:"2";', )) +->values(array( + 'name' => 'comment_default_mode_test_event', + 'value' => 'i:4;', +)) +->values(array( + 'name' => 'comment_default_mode_test_page', + 'value' => 'i:4;', +)) +->values(array( + 'name' => 'comment_default_mode_test_planet', + 'value' => 'i:4;', +)) +->values(array( + 'name' => 'comment_default_mode_test_story', + 'value' => 'i:4;', +)) ->values(array( 'name' => 'comment_default_order_article', - 'value' => 's:1:"1";', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_company', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_employee', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_default_order_page', 'value' => 's:1:"1";', )) +->values(array( + 'name' => 'comment_default_order_sponsor', + 'value' => 'i:1;', +)) ->values(array( 'name' => 'comment_default_order_story', - 'value' => 's:1:"1";', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_test_event', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_test_page', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_test_planet', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_default_order_test_story', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_default_per_page_article', - 'value' => 's:2:"50";', + 'value' => 'i:50;', +)) +->values(array( + 'name' => 'comment_default_per_page_company', + 'value' => 'i:50;', +)) +->values(array( + 'name' => 'comment_default_per_page_employee', + 'value' => 'i:50;', )) ->values(array( 'name' => 'comment_default_per_page_page', 'value' => 's:2:"50";', )) +->values(array( + 'name' => 'comment_default_per_page_sponsor', + 'value' => 'i:50;', +)) ->values(array( 'name' => 'comment_default_per_page_story', - 'value' => 's:2:"70";', + 'value' => 'i:70;', +)) +->values(array( + 'name' => 'comment_default_per_page_test_event', + 'value' => 'i:50;', +)) +->values(array( + 'name' => 'comment_default_per_page_test_page', + 'value' => 'i:50;', +)) +->values(array( + 'name' => 'comment_default_per_page_test_planet', + 'value' => 'i:50;', +)) +->values(array( + 'name' => 'comment_default_per_page_test_story', + 'value' => 'i:50;', )) ->values(array( 'name' => 'comment_form_location_article', - 'value' => 's:1:"0";', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_company', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_employee', + 'value' => 'i:0;', )) ->values(array( 'name' => 'comment_form_location_page', 'value' => 's:1:"0";', )) +->values(array( + 'name' => 'comment_form_location_sponsor', + 'value' => 'i:0;', +)) ->values(array( 'name' => 'comment_form_location_story', - 'value' => 's:1:"0";', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_test_event', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_test_page', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_test_planet', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_form_location_test_story', + 'value' => 'i:0;', )) ->values(array( 'name' => 'comment_page', @@ -24665,15 +33025,43 @@ )) ->values(array( 'name' => 'comment_preview_article', - 'value' => 's:1:"1";', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_preview_company', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_preview_employee', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_preview_page', 'value' => 's:1:"1";', )) +->values(array( + 'name' => 'comment_preview_sponsor', + 'value' => 'i:1;', +)) ->values(array( 'name' => 'comment_preview_story', - 'value' => 's:1:"0";', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_preview_test_event', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_preview_test_page', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_preview_test_planet', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_preview_test_story', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_story', @@ -24681,15 +33069,43 @@ )) ->values(array( 'name' => 'comment_subject_field_article', - 'value' => 's:1:"1";', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_company', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_employee', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_subject_field_page', - 'value' => 's:1:"1";', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_sponsor', + 'value' => 'i:1;', )) ->values(array( 'name' => 'comment_subject_field_story', - 'value' => 's:1:"0";', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'comment_subject_field_test_event', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_test_page', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_test_planet', + 'value' => 'i:1;', +)) +->values(array( + 'name' => 'comment_subject_field_test_story', + 'value' => 'i:1;', )) ->values(array( 'name' => 'configurable_timezones', @@ -24713,7 +33129,7 @@ )) ->values(array( 'name' => 'content_schema_version', - 'value' => 's:4:"6010";', + 'value' => 'i:6009;', )) ->values(array( 'name' => 'cron_threshold_error', @@ -24725,7 +33141,7 @@ )) ->values(array( 'name' => 'css_js_query_string', - 'value' => 's:20:"AkMTxRZndiw700000000";', + 'value' => 's:20:"SAkMTxRZndiw70000000";', )) ->values(array( 'name' => 'date:story:4:field_test_datestamp_fromto', @@ -25015,6 +33431,10 @@ 'name' => 'error_level', 'value' => 'i:1;', )) +->values(array( + 'name' => 'event_nodeapi_article', + 'value' => 's:5:"never";', +)) ->values(array( 'name' => 'event_nodeapi_event', 'value' => 's:3:"all";', @@ -25073,7 +33493,7 @@ )) ->values(array( 'name' => 'form_build_id_article', - 'value' => 's:48:"form-uujdfNoFjx9PnvEkSoFnanxF1waDx_AikUQLRTGGdvQ";', + 'value' => 's:48:"form-mXZfFJxcCFGB80PPYtNOuwYbho6-xKTvrRLb3TAMkic";', )) ->values(array( 'name' => 'forum_block_num_0', @@ -25107,6 +33527,22 @@ 'name' => 'image_toolkit', 'value' => 's:2:"gd";', )) +->values(array( + 'name' => 'javascript_parsed', + 'value' => 'a:0:{}', +)) +->values(array( + 'name' => 'language_content_type_article', + 'value' => 's:1:"2";', +)) +->values(array( + 'name' => 'language_count', + 'value' => 'i:2;', +)) +->values(array( + 'name' => 'language_default', + 'value' => 'O:8:"stdClass":11:{s:8:"language";s:2:"en";s:4:"name";s:7:"English";s:6:"native";s:7:"English";s:9:"direction";s:1:"0";s:7:"enabled";i:1;s:7:"plurals";s:1:"0";s:7:"formula";s:0:"";s:6:"domain";s:0:"";s:6:"prefix";s:0:"";s:6:"weight";s:1:"0";s:10:"javascript";s:0:"";}', +)) ->values(array( 'name' => 'locale_cache_strings', 'value' => 'i:1;', diff --git a/core/modules/migrate_drupal/tests/fixtures/drupal7.php b/core/modules/migrate_drupal/tests/fixtures/drupal7.php index 3a9d266cf..09d81cfa1 100644 --- a/core/modules/migrate_drupal/tests/fixtures/drupal7.php +++ b/core/modules/migrate_drupal/tests/fixtures/drupal7.php @@ -84,37 +84,290 @@ 'timestamp', )) ->values(array( - 'aid' => '89', - 'sid' => 's12XgEKLqGr998aW8pzRB4dCX5SkOVoDm4YO76PPv7g', - 'title' => 'Appearance', - 'path' => 'admin/appearance', - 'url' => 'http://localhost/sandbox7/node/1', - 'hostname' => '::1', + 'aid' => '92', + 'sid' => 'a8ksMY2GH4yXK0-PsLNAlCv4zNnapnyCpx4lryZDEfk', + 'title' => '', + 'path' => 'node', + 'url' => 'http://drupal7.local/?q=user/register', + 'hostname' => '127.0.0.1', + 'uid' => '0', + 'timer' => '655', + 'timestamp' => '1444944970', +)) +->values(array( + 'aid' => '93', + 'sid' => 'e89G2redQpxRTIndbV3qH8snVR621DqSQ2s4vciJedA', + 'title' => '', + 'path' => 'node', + 'url' => 'http://drupal7.local/', + 'hostname' => '127.0.0.1', + 'uid' => '0', + 'timer' => '214', + 'timestamp' => '1444944974', +)) +->values(array( + 'aid' => '94', + 'sid' => 'KkVxQTCiKqKEGNcRs7GYrmXXbEk4szXCHVTknFkbiG0', + 'title' => 'User account', + 'path' => 'user/login', + 'url' => '', + 'hostname' => '127.0.0.1', + 'uid' => '0', + 'timer' => '259', + 'timestamp' => '1444945094', +)) +->values(array( + 'aid' => '95', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'My account', + 'path' => 'user/login', + 'url' => 'http://drupal7.local/?q=user/login', + 'hostname' => '127.0.0.1', 'uid' => '1', - 'timer' => '922', - 'timestamp' => '1421843462', + 'timer' => '217', + 'timestamp' => '1444945097', )) ->values(array( - 'aid' => '90', - 'sid' => 's12XgEKLqGr998aW8pzRB4dCX5SkOVoDm4YO76PPv7g', + 'aid' => '96', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'root', + 'path' => 'user/1', + 'url' => 'http://drupal7.local/?q=user/login', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '211', + 'timestamp' => '1444945097', +)) +->values(array( + 'aid' => '97', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', 'title' => 'Modules', 'path' => 'admin/modules', - 'url' => 'http://localhost/sandbox7/admin/appearance', - 'hostname' => '::1', + 'url' => 'http://drupal7.local/user/1', + 'hostname' => '127.0.0.1', 'uid' => '1', - 'timer' => '492', - 'timestamp' => '1421843474', + 'timer' => '619', + 'timestamp' => '1444945104', )) ->values(array( - 'aid' => '91', - 'sid' => 's12XgEKLqGr998aW8pzRB4dCX5SkOVoDm4YO76PPv7g', + 'aid' => '98', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', 'title' => 'Configuration', 'path' => 'admin/config', - 'url' => 'http://localhost/sandbox7/admin/modules', - 'hostname' => '::1', + 'url' => 'http://drupal7.local/admin/modules', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '273', + 'timestamp' => '1444945114', +)) +->values(array( + 'aid' => '99', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language', + 'url' => 'http://drupal7.local/admin/config', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '213', + 'timestamp' => '1444945121', +)) +->values(array( + 'aid' => '100', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language/add', + 'url' => 'http://drupal7.local/admin/config/regional/language', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '148', + 'timestamp' => '1444945122', +)) +->values(array( + 'aid' => '101', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language/add', + 'url' => 'http://drupal7.local/admin/config/regional/language/add', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '260', + 'timestamp' => '1444945153', +)) +->values(array( + 'aid' => '102', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language/add', + 'url' => '', + 'hostname' => '127.0.0.1', 'uid' => '1', - 'timer' => '180', - 'timestamp' => '1421843480', + 'timer' => '195', + 'timestamp' => '1444945160', +)) +->values(array( + 'aid' => '103', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language/add', + 'url' => 'http://drupal7.local/?q=admin/config/regional/language/add', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '177', + 'timestamp' => '1444945168', +)) +->values(array( + 'aid' => '104', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language', + 'url' => 'http://drupal7.local/?q=admin/config/regional/language/add', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '145', + 'timestamp' => '1444945168', +)) +->values(array( + 'aid' => '105', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language', + 'url' => '', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '159', + 'timestamp' => '1444945175', +)) +->values(array( + 'aid' => '106', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language', + 'url' => 'http://drupal7.local/?q=admin/config/regional/language', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '152', + 'timestamp' => '1444945176', +)) +->values(array( + 'aid' => '107', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Languages', + 'path' => 'admin/config/regional/language', + 'url' => 'http://drupal7.local/?q=admin/config/regional/language', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '148', + 'timestamp' => '1444945176', +)) +->values(array( + 'aid' => '108', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Structure', + 'path' => 'admin/structure', + 'url' => 'http://drupal7.local/admin/config/regional/language', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '156', + 'timestamp' => '1444945206', +)) +->values(array( + 'aid' => '109', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Content types', + 'path' => 'admin/structure/types', + 'url' => 'http://drupal7.local/admin/structure', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '154', + 'timestamp' => '1444945208', +)) +->values(array( + 'aid' => '110', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Blog entry', + 'path' => 'admin/structure/types/manage/blog', + 'url' => 'http://drupal7.local/admin/structure/types', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '203', + 'timestamp' => '1444945211', +)) +->values(array( + 'aid' => '111', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Parent menu items', + 'path' => 'admin/structure/menu/parents', + 'url' => 'http://drupal7.local/admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '211', + 'timestamp' => '1444945211', +)) +->values(array( + 'aid' => '112', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Blog entry', + 'path' => 'admin/structure/types/manage/blog', + 'url' => 'http://drupal7.local/admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '224', + 'timestamp' => '1444945236', +)) +->values(array( + 'aid' => '113', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Parent menu items', + 'path' => 'admin/structure/menu/parents', + 'url' => 'http://drupal7.local/admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '165', + 'timestamp' => '1444945237', +)) +->values(array( + 'aid' => '114', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Blog entry', + 'path' => 'admin/structure/types/manage/blog', + 'url' => '', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '155', + 'timestamp' => '1444945242', +)) +->values(array( + 'aid' => '115', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Parent menu items', + 'path' => 'admin/structure/menu/parents', + 'url' => 'http://drupal7.local/?q=admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '217', + 'timestamp' => '1444945242', +)) +->values(array( + 'aid' => '116', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Blog entry', + 'path' => 'admin/structure/types/manage/blog', + 'url' => 'http://drupal7.local/?q=admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '667', + 'timestamp' => '1444945246', +)) +->values(array( + 'aid' => '117', + 'sid' => 'FA1BMWZvsAAE1G-OBMzfiJyA12sh588cOKSmEmxFQiA', + 'title' => 'Content types', + 'path' => 'admin/structure/types', + 'url' => 'http://drupal7.local/?q=admin/structure/types/manage/blog', + 'hostname' => '127.0.0.1', + 'uid' => '1', + 'timer' => '149', + 'timestamp' => '1444945246', )) ->execute(); @@ -428,13 +681,13 @@ 'title' => 'Know Your Meme', 'url' => 'http://knowyourmeme.com/newsfeed.rss', 'refresh' => '900', - 'checked' => '1387659487', + 'checked' => '1444944970', 'queued' => '0', 'link' => 'http://knowyourmeme.com', 'description' => 'New items added to the News Feed', - 'image' => 'http://b.thumbs.redditmedia.com/harEHsUUZVajabtC.png', - 'hash' => '1c1e3b6c10ce02f226882aca11709051bba61df2b8eac17ceec5bf74048f1954', - 'etag' => '"213cc1365b96c310e92053c5551f0504"', + 'image' => '', + 'hash' => 'e6295b3ba81b24db62b41515494a7e9fb87979ff45045a1c946de5fa5abc9c52', + 'etag' => '"bad5e20e4993f31c869cffd22f1645b9"', 'modified' => '0', 'block' => '5', )) @@ -504,14 +757,104 @@ 'guid', )) ->values(array( - 'iid' => '1', + 'iid' => '2', + 'fid' => '1', + 'title' => 'Fido, Take the Wheel', + 'link' => 'http://knowyourmeme.com/videos/127817-dogs', + 'author' => '', + 'description' => 'D70olsu

    When little Timmy had too much to drink, the family dog was forced into the role of designated driver.

    ', + 'timestamp' => '1444860534', + 'guid' => 'post:18816', +)) +->values(array( + 'iid' => '3', + 'fid' => '1', + 'title' => 'One Punch Man Anime Premieres in Japan', + 'link' => 'http://knowyourmeme.com/memes/subcultures/one-punch-man', + 'author' => '', + 'description' => '49b

    The first two episodes of the much anticipated anime adaptation of One Punch Man were finally aired in Japan this month.

    ', + 'timestamp' => '1444863415', + 'guid' => 'post:18819', +)) +->values(array( + 'iid' => '4', + 'fid' => '1', + 'title' => '’Tis the Season to Be Forever Alone', + 'link' => 'http://knowyourmeme.com/photos/1029494-forever-alone', + 'author' => '', + 'description' => '336', + 'timestamp' => '1444864413', + 'guid' => 'post:18821', +)) +->values(array( + 'iid' => '5', 'fid' => '1', - 'title' => 'This (three) weeks in Drupal Core - January 10th 2014', - 'link' => 'https://groups.drupal.org/node/395218', - 'author' => 'larowlan', - 'description' => "

    What's new with Drupal 8?

    ", - 'timestamp' => '1389297196', - 'guid' => '395218 at https://groups.drupal.org', + 'title' => 'Legend of Zelda: Symphony of The Goddesses', + 'link' => 'http://knowyourmeme.com/videos/128124-the-legend-of-zelda', + 'author' => '', + 'description' => '1a9

    Rejoice, nerds! This is the music that awaits you in heaven. Check out The Legend of Zelda: Symphony of the Goddesses’ performance on the Late Show with Stephen Colbert.

    ', + 'timestamp' => '1444934645', + 'guid' => 'post:18824', +)) +->values(array( + 'iid' => '6', + 'fid' => '1', + 'title' => '“Your Mom” Jokes', + 'link' => 'http://knowyourmeme.com/memes/your-mom-jokes', + 'author' => '', + 'description' => '3bc

    The earliest recorded example of a maternal insult joke comes from an ancient Babylonian tablet dated back to 1,500 BCE, which contains an incomplete riddle about a promiscuous mother.

    ', + 'timestamp' => '1444928716', + 'guid' => 'post:18823', +)) +->values(array( + 'iid' => '7', + 'fid' => '1', + 'title' => 'DBZ Voice Actors Dub Over Classic Movies', + 'link' => 'http://knowyourmeme.com/videos/128169-dragon-ball', + 'author' => '', + 'description' => 'D8c

    Some of the most recognizable voices behind the characters of Dragon Ball Z gather at The Nerdist studio for a parody dub of famous film scenes from Ace Ventura and Independence Day to Zoolander and Meet the Parents.

    ', + 'timestamp' => '1444939569', + 'guid' => 'post:18826', +)) +->values(array( + 'iid' => '8', + 'fid' => '1', + 'title' => 'Happy Birthday, Cure-chan!', + 'link' => 'http://knowyourmeme.com/memes/cure-chan', + 'author' => '', + 'description' => 'E8c

    The archnemesis of Ebola-chan was born one year ago this week.

    ', + 'timestamp' => '1444938083', + 'guid' => 'post:18825', +)) +->values(array( + 'iid' => '9', + 'fid' => '1', + 'title' => 'That Face When Retweets Ain’t Coming In', + 'link' => 'http://knowyourmeme.com/photos/1029430-my-face-when', + 'author' => '', + 'description' => 'C51', + 'timestamp' => '1444940736', + 'guid' => 'post:18827', +)) +->values(array( + 'iid' => '10', + 'fid' => '1', + 'title' => 'Back to the Future Stars Talk Film’s Predictions', + 'link' => 'http://knowyourmeme.com/videos/128173-back-to-the-future-day', + 'author' => '', + 'description' => '944

    In honor of next week being the real Back to the Future Day, Christopher Lloyd and Michael J. Fox recently got together (at the prompting of Toyota) to discuss which of the film’s predictions have come to pass in 2015.

    ', + 'timestamp' => '1444943309', + 'guid' => 'post:18828', +)) +->values(array( + 'iid' => '11', + 'fid' => '1', + 'title' => 'Chad Says Beta Things', + 'link' => 'http://knowyourmeme.com/memes/chad-says-beta-things', + 'author' => '', + 'description' => '937

    This series of awkward Tinder messages sent by a fake Chad Tinder profile has caused a recent surge in popularity of the corn emoji.

    ', + 'timestamp' => '1444944831', + 'guid' => 'post:18829', )) ->execute(); @@ -1309,13 +1652,41 @@ 'theme' => 'seven', 'status' => '0', 'weight' => '0', - 'region' => '', + 'region' => '-1', 'custom' => '0', 'visibility' => '0', 'pages' => '', 'title' => 'Mildly amusing limerick of the day', 'cache' => '-1', )) +->values(array( + 'bid' => '47', + 'module' => 'aggregator', + 'delta' => 'feed-1', + 'theme' => 'bartik', + 'status' => '0', + 'weight' => '0', + 'region' => '-1', + 'custom' => '0', + 'visibility' => '0', + 'pages' => '', + 'title' => '', + 'cache' => '1', +)) +->values(array( + 'bid' => '48', + 'module' => 'aggregator', + 'delta' => 'feed-1', + 'theme' => 'seven', + 'status' => '0', + 'weight' => '0', + 'region' => '-1', + 'custom' => '0', + 'visibility' => '0', + 'pages' => '', + 'title' => '', + 'cache' => '1', +)) ->execute(); $connection->schema()->createTable('block_custom', array( @@ -2245,6 +2616,7 @@ 'type' => 'varchar', 'not null' => TRUE, 'length' => '100', + 'binary' => TRUE, ), 'type' => array( 'type' => 'varchar', @@ -7422,19 +7794,6 @@ 'mysql_character_set' => 'utf8', )); -$connection->insert('history') -->fields(array( - 'uid', - 'nid', - 'timestamp', -)) -->values(array( - 'uid' => '1', - 'nid' => '1', - 'timestamp' => '1421727536', -)) -->execute(); - $connection->schema()->createTable('image_effects', array( 'fields' => array( 'ieid' => array( @@ -7676,6 +8035,19 @@ 'weight' => '0', 'javascript' => '', )) +->values(array( + 'language' => 'is', + 'name' => 'Icelandic', + 'native' => 'Íslenska', + 'direction' => '0', + 'enabled' => '1', + 'plurals' => '0', + 'formula' => '', + 'domain' => '', + 'prefix' => 'is', + 'weight' => '0', + 'javascript' => '', +)) ->execute(); $connection->schema()->createTable('locales_source', array( @@ -8105,6 +8477,14 @@ 'context' => '', 'version' => 'none', )) +->values(array( + 'lid' => '48', + 'location' => 'misc/drupal.js', + 'textgroup' => 'default', + 'source' => 'CustomMessage: !customMessage', + 'context' => '', + 'version' => 'none', +)) ->execute(); $connection->schema()->createTable('locales_target', array( @@ -8494,7 +8874,7 @@ 'module' => 'system', 'hidden' => '1', 'external' => '0', - 'has_children' => '0', + 'has_children' => '1', 'expanded' => '0', 'weight' => '0', 'depth' => '1', @@ -18581,6 +18961,60 @@ 'p9' => '0', 'updated' => '0', )) +->values(array( + 'menu_name' => 'navigation', + 'mlid' => '474', + 'plid' => '4', + 'link_path' => 'filter/tips/%', + 'router_path' => 'filter/tips/%', + 'link_title' => 'Compose tips', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '0', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '2', + 'customized' => '0', + 'p1' => '4', + 'p2' => '474', + 'p3' => '0', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) +->values(array( + 'menu_name' => 'management', + 'mlid' => '475', + 'plid' => '175', + 'link_path' => 'admin/help/php', + 'router_path' => 'admin/help/php', + 'link_title' => 'php', + 'options' => 'a:0:{}', + 'module' => 'system', + 'hidden' => '-1', + 'external' => '0', + 'has_children' => '0', + 'expanded' => '0', + 'weight' => '0', + 'depth' => '3', + 'customized' => '0', + 'p1' => '1', + 'p2' => '175', + 'p3' => '475', + 'p4' => '0', + 'p5' => '0', + 'p6' => '0', + 'p7' => '0', + 'p8' => '0', + 'p9' => '0', + 'updated' => '0', +)) ->execute(); $connection->schema()->createTable('menu_router', array( @@ -18955,7 +19389,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:6:"bartik";}', 'delivery_callback' => '', @@ -18980,7 +19414,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:7:"garland";}', 'delivery_callback' => '', @@ -19030,7 +19464,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:5:"seven";}', 'delivery_callback' => '', @@ -19055,7 +19489,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_system_themes_access', - 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.34\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1416429488\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1416429488;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", + 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1444866674;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", 'page_callback' => 'drupal_get_form', 'page_arguments' => 'a:2:{i:0;s:21:"system_theme_settings";i:1;s:5:"stark";}', 'delivery_callback' => '', @@ -22875,6 +23309,31 @@ 'weight' => '0', 'include_file' => 'modules/help/help.admin.inc', )) +->values(array( + 'path' => 'admin/help/php', + 'load_functions' => '', + 'to_arg_functions' => '', + 'access_callback' => 'user_access', + 'access_arguments' => 'a:1:{i:0;s:27:"access administration pages";}', + 'page_callback' => 'help_page', + 'page_arguments' => 'a:1:{i:0;i:2;}', + 'delivery_callback' => '', + 'fit' => '7', + 'number_parts' => '3', + 'context' => '0', + 'tab_parent' => '', + 'tab_root' => 'admin/help/php', + 'title' => 'php', + 'title_callback' => 't', + 'title_arguments' => '', + 'theme_callback' => '', + 'theme_arguments' => 'a:0:{}', + 'type' => '4', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'include_file' => 'modules/help/help.admin.inc', +)) ->values(array( 'path' => 'admin/help/rdf', 'load_functions' => '', @@ -24280,7 +24739,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_demo', 'page_arguments' => 'a:1:{i:0;s:6:"bartik";}', 'delivery_callback' => '', @@ -24305,7 +24764,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_demo', 'page_arguments' => 'a:1:{i:0;s:7:"garland";}', 'delivery_callback' => '', @@ -24330,7 +24789,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_demo', 'page_arguments' => 'a:1:{i:0;s:5:"seven";}', 'delivery_callback' => '', @@ -24355,7 +24814,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.34\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1416429488\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1416429488;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", + 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1444866674;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", 'page_callback' => 'block_admin_demo', 'page_arguments' => 'a:1:{i:0;s:5:"stark";}', 'delivery_callback' => '', @@ -24380,7 +24839,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:25:"themes/bartik/bartik.info";s:4:"name";s:6:"bartik";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:6:"bartik";}', 'delivery_callback' => '', @@ -24405,7 +24864,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:27:"themes/garland/garland.info";s:4:"name";s:7:"garland";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"0";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:7:"garland";}', 'delivery_callback' => '', @@ -24455,7 +24914,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.34";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1416429488";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1416429488;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', + 'access_arguments' => 'a:1:{i:0;O:8:"stdClass":12:{s:8:"filename";s:23:"themes/seven/seven.info";s:4:"name";s:5:"seven";s:4:"type";s:5:"theme";s:5:"owner";s:45:"themes/engines/phptemplate/phptemplate.engine";s:6:"status";s:1:"1";s:9:"bootstrap";s:1:"0";s:14:"schema_version";s:2:"-1";s:6:"weight";s:1:"0";s:4:"info";a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}s:6:"prefix";s:11:"phptemplate";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:6:"engine";s:11:"phptemplate";}}', 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:5:"seven";}', 'delivery_callback' => '', @@ -24505,7 +24964,7 @@ 'load_functions' => '', 'to_arg_functions' => '', 'access_callback' => '_block_themes_access', - 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.34\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1416429488\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1416429488;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", + 'access_arguments' => "a:1:{i:0;O:8:\"stdClass\":12:{s:8:\"filename\";s:23:\"themes/stark/stark.info\";s:4:\"name\";s:5:\"stark\";s:4:\"type\";s:5:\"theme\";s:5:\"owner\";s:45:\"themes/engines/phptemplate/phptemplate.engine\";s:6:\"status\";s:1:\"0\";s:9:\"bootstrap\";s:1:\"0\";s:14:\"schema_version\";s:2:\"-1\";s:6:\"weight\";s:1:\"0\";s:4:\"info\";a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1444866674;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}s:6:\"prefix\";s:11:\"phptemplate\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:6:\"engine\";s:11:\"phptemplate\";}}", 'page_callback' => 'block_admin_display', 'page_arguments' => 'a:1:{i:0;s:5:"stark";}', 'delivery_callback' => '', @@ -27350,6 +27809,31 @@ 'weight' => '0', 'include_file' => 'modules/filter/filter.pages.inc', )) +->values(array( + 'path' => 'filter/tips/%', + 'load_functions' => 'a:1:{i:2;s:18:"filter_format_load";}', + 'to_arg_functions' => '', + 'access_callback' => 'filter_access', + 'access_arguments' => 'a:1:{i:0;i:2;}', + 'page_callback' => 'filter_tips_long', + 'page_arguments' => 'a:1:{i:0;i:2;}', + 'delivery_callback' => '', + 'fit' => '6', + 'number_parts' => '3', + 'context' => '0', + 'tab_parent' => '', + 'tab_root' => 'filter/tips/%', + 'title' => 'Compose tips', + 'title_callback' => 't', + 'title_arguments' => '', + 'theme_callback' => '', + 'theme_arguments' => 'a:0:{}', + 'type' => '6', + 'description' => '', + 'position' => '', + 'weight' => '0', + 'include_file' => 'modules/filter/filter.pages.inc', +)) ->values(array( 'path' => 'forum', 'load_functions' => '', @@ -29545,30 +30029,6 @@ 'mysql_character_set' => 'utf8', )); -$connection->insert('queue') -->fields(array( - 'item_id', - 'name', - 'data', - 'expire', - 'created', -)) -->values(array( - 'item_id' => '45', - 'name' => 'update_fetch_tasks', - 'data' => 'a:8:{s:4:"name";s:4:"date";s:4:"info";a:6:{s:4:"name";s:4:"Date";s:7:"package";s:9:"Date/Time";s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:16:"_info_file_ctime";i:1421694394;}s:9:"datestamp";s:10:"1406653438";s:8:"includes";a:2:{s:4:"date";s:4:"Date";s:8:"date_api";s:8:"Date API";}s:12:"project_type";s:6:"module";s:14:"project_status";b:1;s:10:"sub_themes";a:0:{}s:11:"base_themes";a:0:{}}', - 'expire' => '0', - 'created' => '1421843480', -)) -->values(array( - 'item_id' => '46', - 'name' => 'update_fetch_tasks', - 'data' => 'a:8:{s:4:"name";s:5:"email";s:4:"info";a:6:{s:4:"name";s:5:"Email";s:7:"package";s:6:"Fields";s:7:"version";s:7:"7.x-1.3";s:7:"project";s:5:"email";s:9:"datestamp";s:10:"1397134155";s:16:"_info_file_ctime";i:1421694395;}s:9:"datestamp";s:10:"1397134155";s:8:"includes";a:1:{s:5:"email";s:5:"Email";}s:12:"project_type";s:6:"module";s:14:"project_status";b:1;s:10:"sub_themes";a:0:{}s:11:"base_themes";a:0:{}}', - 'expire' => '0', - 'created' => '1421843480', -)) -->execute(); - $connection->schema()->createTable('rdf_mapping', array( 'fields' => array( 'type' => array( @@ -29903,63 +30363,63 @@ 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockCacheTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockHashTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockHiddenRegionTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockHTMLIdTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockInvalidRegionTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockTemplateSuggestionsUnitTest', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockTestCase', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlockViewModuleDeltaAlterWebTest', 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'BlogTestCase', @@ -29975,6 +30435,20 @@ 'module' => 'book', 'weight' => '0', )) +->values(array( + 'name' => 'BootstrapAutoloadTestCase', + 'type' => 'class', + 'filename' => 'modules/simpletest/tests/bootstrap.test', + 'module' => 'simpletest', + 'weight' => '0', +)) +->values(array( + 'name' => 'BootstrapDestinationTestCase', + 'type' => 'class', + 'filename' => 'modules/simpletest/tests/bootstrap.test', + 'module' => 'simpletest', + 'weight' => '0', +)) ->values(array( 'name' => 'BootstrapGetFilenameTestCase', 'type' => 'class', @@ -30276,6 +30750,13 @@ 'module' => 'simpletest', 'weight' => '0', )) +->values(array( + 'name' => 'ConfirmFormTest', + 'type' => 'class', + 'filename' => 'modules/system/system.test', + 'module' => 'system', + 'weight' => '0', +)) ->values(array( 'name' => 'ConnectionUnitTest', 'type' => 'class', @@ -30885,6 +31366,13 @@ 'module' => 'date', 'weight' => '0', )) +->values(array( + 'name' => 'DateViewsPopupTestCase', + 'type' => 'class', + 'filename' => 'sites/all/modules/date/tests/date_views_popup.test', + 'module' => 'date', + 'weight' => '0', +)) ->values(array( 'name' => 'date_sql_handler', 'type' => 'class', @@ -31130,6 +31618,13 @@ 'module' => 'simpletest', 'weight' => '0', )) +->values(array( + 'name' => 'DrupalSetMessageTest', + 'type' => 'class', + 'filename' => 'modules/system/system.test', + 'module' => 'system', + 'weight' => '0', +)) ->values(array( 'name' => 'DrupalStreamWrapperInterface', 'type' => 'interface', @@ -31193,6 +31688,13 @@ 'module' => 'simpletest', 'weight' => '0', )) +->values(array( + 'name' => 'EarlyBootstrapTestCase', + 'type' => 'class', + 'filename' => 'modules/simpletest/tests/boot.test', + 'module' => 'simpletest', + 'weight' => '0', +)) ->values(array( 'name' => 'EGPhoneNumberTestCase', 'type' => 'class', @@ -31767,6 +32269,13 @@ 'module' => 'filter', 'weight' => '0', )) +->values(array( + 'name' => 'FilterDOMSerializeTestCase', + 'type' => 'class', + 'filename' => 'modules/filter/filter.test', + 'module' => 'filter', + 'weight' => '0', +)) ->values(array( 'name' => 'FilterFormatAccessTestCase', 'type' => 'class', @@ -32047,6 +32556,13 @@ 'module' => 'image', 'weight' => '0', )) +->values(array( + 'name' => 'ImageAdminUiTestCase', + 'type' => 'class', + 'filename' => 'modules/image/image.test', + 'module' => 'image', + 'weight' => '0', +)) ->values(array( 'name' => 'ImageDimensionsScaleTestCase', 'type' => 'class', @@ -32649,6 +33165,13 @@ 'module' => 'system', 'weight' => '0', )) +->values(array( + 'name' => 'ModuleImplementsAlterTestCase', + 'type' => 'class', + 'filename' => 'modules/simpletest/tests/module.test', + 'module' => 'simpletest', + 'weight' => '0', +)) ->values(array( 'name' => 'ModuleInstallTestCase', 'type' => 'class', @@ -32710,7 +33233,7 @@ 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'NLPhoneNumberTestCase', @@ -32955,7 +33478,7 @@ 'type' => 'class', 'filename' => 'modules/block/block.test', 'module' => 'block', - 'weight' => '0', + 'weight' => '-5', )) ->values(array( 'name' => 'NumberFieldTestCase', @@ -33636,6 +34159,13 @@ 'module' => 'search', 'weight' => '0', )) +->values(array( + 'name' => 'SearchNodeTagTest', + 'type' => 'class', + 'filename' => 'modules/search/search.test', + 'module' => 'search', + 'weight' => '0', +)) ->values(array( 'name' => 'SearchNumberMatchingTestCase', 'type' => 'class', @@ -35029,6 +35559,13 @@ 'module' => 'views', 'weight' => '0', )) +->values(array( + 'name' => 'ViewsPagerTestCase', + 'type' => 'class', + 'filename' => 'sites/all/modules/date/tests/date_views_pager.test', + 'module' => 'date', + 'weight' => '0', +)) ->values(array( 'name' => 'ViewsPluginDisplayTestCase', 'type' => 'class', @@ -35264,7 +35801,7 @@ )) ->values(array( 'filename' => 'includes/ajax.inc', - 'hash' => 'f5d608554c6b42b976d6a97e1efffe53c657e9fbb77eabb858935bfdf4276491', + 'hash' => 'a22c8f7345c1f714ea40bbaa1385fa0e3763b389c82656cf6ff3e4d051532ee4', )) ->values(array( 'filename' => 'includes/archiver.inc', @@ -35276,7 +35813,7 @@ )) ->values(array( 'filename' => 'includes/batch.inc', - 'hash' => '059da9e36e1f3717f27840aae73f10dea7d6c8daf16f6520401cc1ca3b4c0388', + 'hash' => '1fe00f9a25481cd43e19fbd6bd37b7ff9dca79f8405ec3e55ffb011be12ec2c3', )) ->values(array( 'filename' => 'includes/batch.queue.inc', @@ -35284,7 +35821,7 @@ )) ->values(array( 'filename' => 'includes/bootstrap.inc', - 'hash' => '1433438e685f5b982c2259cd3306508c274d6065f63e3e43b6b120f1f7add621', + 'hash' => '245deaa370fa492dae401e2eee215f771f9ffbba14c1ff50631a6a4b2b3c771e', )) ->values(array( 'filename' => 'includes/cache-install.inc', @@ -35292,15 +35829,15 @@ )) ->values(array( 'filename' => 'includes/cache.inc', - 'hash' => 'd01e10e4c18010b6908026f3d71b72717e3272cfb91a528490eba7f339f8dd1b', + 'hash' => 'ee0bf13c7e067695dffcb9ade3b79fea82a3a8db9e9a422ebfcc91c383aa4b4c', )) ->values(array( 'filename' => 'includes/common.inc', - 'hash' => '91bf90492c571dba1f6ef7db54a96d360579f933d0f3637b5aa33dff1eeda56a', + 'hash' => 'd64557e1027136d80e66c329133336412c8301b48c6703943494cff1309f934c', )) ->values(array( 'filename' => 'includes/database/database.inc', - 'hash' => '24afaff6e1026bfe315205212cba72951240a16154250e405c4c64724e6e07cc', + 'hash' => '27f874fb21e1a85c86e0317669e2e26c1c6611a5e913c5bbce4c7aa62734edfe', )) ->values(array( 'filename' => 'includes/database/log.inc', @@ -35308,7 +35845,7 @@ )) ->values(array( 'filename' => 'includes/database/mysql/database.inc', - 'hash' => 'd62a2d8ca103cb3b085e7f8b894a7db14c02f20d0b1ed0bd32f6534a45b4527f', + 'hash' => 'f021edd0e2b5e315336eb6b5e481b9516c12de78dff2c468be3d7fd0d3672665', )) ->values(array( 'filename' => 'includes/database/mysql/install.inc', @@ -35348,11 +35885,11 @@ )) ->values(array( 'filename' => 'includes/database/query.inc', - 'hash' => '9171653e9710c6c0d20cff865fdead5a580367137ad4cdf81059ecc2eea61c74', + 'hash' => '4016a397f10f071cac338fd0a9b004296106e42ab2b9db8c7ff0db341658e88f', )) ->values(array( 'filename' => 'includes/database/schema.inc', - 'hash' => 'a98b69d33975e75f7d99cb85b20c36b7fc10e35a588e07b20c1b37500f5876ca', + 'hash' => '9fecfd13fc1d4056a62d385840dccd052ea0e184dc47101f4bd8f57f10b68174', )) ->values(array( 'filename' => 'includes/database/select.inc', @@ -35364,7 +35901,7 @@ )) ->values(array( 'filename' => 'includes/database/sqlite/install.inc', - 'hash' => '381f3db8c59837d961978ba3097bb6443534ed1659fd713aa563963fa0c42cc5', + 'hash' => '6620f354aa175a116ba3a0562c980d86cc3b8b481042fc3cc5ed6a4d1a7a6d74', )) ->values(array( 'filename' => 'includes/database/sqlite/query.inc', @@ -35384,7 +35921,7 @@ )) ->values(array( 'filename' => 'includes/entity.inc', - 'hash' => '3080fe3c30991a48f1f314a60d02e841d263a8f222337e5bde3be61afe41ee7a', + 'hash' => 'e4fc9ff21b165a804d7ac4f036b3b5bd1d3c73da7029bf3f761d4bdee9ae3c96', )) ->values(array( 'filename' => 'includes/errors.inc', @@ -35392,7 +35929,7 @@ )) ->values(array( 'filename' => 'includes/file.inc', - 'hash' => '5ee60833470d5e8d5f2c6c8e7b978ec2e1f3cbf291cb611db1ca560dea98d888', + 'hash' => '9de0398940bf2db560902736f1832d8b72b3e8b49dbbaba5f94c9331425ee04a', )) ->values(array( 'filename' => 'includes/file.mimetypes.inc', @@ -35416,7 +35953,7 @@ )) ->values(array( 'filename' => 'includes/form.inc', - 'hash' => 'ead5e56f116ba31898d1b73f1dfc19ea57a9a528f87c9497fd60ad5caedfee2b', + 'hash' => '9b37fe7e5d04b25604bbc63abb6b6d332be14926011533b4449de52d45a86765', )) ->values(array( 'filename' => 'includes/graph.inc', @@ -35428,11 +35965,11 @@ )) ->values(array( 'filename' => 'includes/install.core.inc', - 'hash' => 'a0585c85002e6f3d702dc505584f48b55bc13e24bee749bfe5b718fbce4847e1', + 'hash' => '733ec6fac8e51747d1c83f266a42e4a0cb6bf31ac50f17f06e37c9e0865f4a38', )) ->values(array( 'filename' => 'includes/install.inc', - 'hash' => '480c3cfd065d3ec00f4465e1b0a0d55d6a8927e78fd6774001c30163a5c648e3', + 'hash' => '781c54771c14b067bb38d222096f981121d479222fbdea9c433405de561a2881', )) ->values(array( 'filename' => 'includes/iso.inc', @@ -35444,11 +35981,11 @@ )) ->values(array( 'filename' => 'includes/language.inc', - 'hash' => '4dd521af07e0ca7bf97ff145f4bd3a218acf0d8b94964e72f11212bb8af8d66e', + 'hash' => '4e08f30843a7ccaeea5c041083e9f77d33d57ff002f1ab4f66168e2c683ce128', )) ->values(array( 'filename' => 'includes/locale.inc', - 'hash' => 'b250f375b93ffe3749f946e0ad475065c914af23e388d68e5c5df161590f086a', + 'hash' => 'f8a3ba7868698e9b43c2ceaebe2cbdcb92d6c68427e817a6e10a76b937b5a127', )) ->values(array( 'filename' => 'includes/lock.inc', @@ -35460,11 +35997,11 @@ )) ->values(array( 'filename' => 'includes/menu.inc', - 'hash' => 'c9ff3c7db04b7e01d0d19b5e47d9fb209799f2ae6584167235b957d22542e526', + 'hash' => '2ecc6f990dc2d987425c680e27a4ddeec2e8376a2be408b00a144131f41a59ea', )) ->values(array( 'filename' => 'includes/module.inc', - 'hash' => 'ca3f2e6129181bbbc67e5e6058a882047f2152174ec8e95c0ea99ce610ace4d7', + 'hash' => 'a18bc92e5fc1f2a31a79eace8c6f2436bc15c8f0b332c8b7aaafa3a223746861', )) ->values(array( 'filename' => 'includes/pager.inc', @@ -35480,7 +36017,7 @@ )) ->values(array( 'filename' => 'includes/registry.inc', - 'hash' => 'c225de772f86eebd21b0b52fa8fcc6671e05fa2374cedb3164f7397f27d3c88d', + 'hash' => 'f47b20859f0fc80bf4bb2849a1282d6c54006957b69da0e5f4691de585ca4cdf', )) ->values(array( 'filename' => 'includes/session.inc', @@ -35496,7 +36033,7 @@ )) ->values(array( 'filename' => 'includes/theme.inc', - 'hash' => '0465fb4ed937123c4bed4a4463601055f9b8fc39ca7787d9952b4f4e300db2b3', + 'hash' => '507932af124871dd2639ab8eafbbd68f962ef70f44ef1c4fd1a14daf04c53b5e', )) ->values(array( 'filename' => 'includes/theme.maintenance.inc', @@ -35516,7 +36053,7 @@ )) ->values(array( 'filename' => 'includes/update.inc', - 'hash' => '177ce24362efc7f28b384c90a09c3e485396bbd18c3721d4b21e57dd1733bd92', + 'hash' => '77403195059de797422d9d9202f18548a38558995120c7f9ffb9bd044730a3bc', )) ->values(array( 'filename' => 'includes/updater.inc', @@ -35540,7 +36077,7 @@ )) ->values(array( 'filename' => 'modules/block/block.test', - 'hash' => 'df1b364688b46345523dfcb95c0c48352d6a4edbc66597890d29b9b0d7866e86', + 'hash' => '40d9de00589211770a85c47d38c8ad61c598ec65d9332128a882eb8750e65a16', )) ->values(array( 'filename' => 'modules/blog/blog.test', @@ -35556,11 +36093,11 @@ )) ->values(array( 'filename' => 'modules/comment/comment.module', - 'hash' => '5a81f5e4b3a35973b3d39ccb9efaee7a8f8cf4ac43e9353e87f2d17a3bed4747', + 'hash' => 'db858137ff6ce06d87cb3b8f5275bed90c33a6d9aa7d46e7a74524cc2f052309', )) ->values(array( 'filename' => 'modules/comment/comment.test', - 'hash' => '083d47035d3e64d1f6f9f1e12bc13d056511019a9de84183088e58a359ea58b9', + 'hash' => '0443a4dbc5aef3d64405a7cabf462c8c5e0b24517d89410d261027b85292cd4b', )) ->values(array( 'filename' => 'modules/contact/contact.test', @@ -35584,15 +36121,15 @@ )) ->values(array( 'filename' => 'modules/field/field.info.class.inc', - 'hash' => 'a6f2f418552dba0e03f57ee812a6f0f63bbfe4bf81fe805d51ecec47ef84b845', + 'hash' => 'cf18178e119d43897d3abd882ba3acc0cf59d1ad747663437c57b1ec4d0a4322', )) ->values(array( 'filename' => 'modules/field/field.module', - 'hash' => '2ec1a3ec060504467c3065426a5a1eca8e2c894cb4d4480616bca60fe4b2faf2', + 'hash' => 'e9359f8cac64b2d81ac067d7da22972116dc10b9b346752a8ef8292943a958c9', )) ->values(array( 'filename' => 'modules/field/modules/field_sql_storage/field_sql_storage.test', - 'hash' => '24b4d2596016ff86071ff3f00d63ff854e847dc58ab64a0afc539bdc1f682ac5', + 'hash' => '315eedaf2022afc884c35efd3b7c400eddab6ea30bec91924bc82ab5cd3e79f2', )) ->values(array( 'filename' => 'modules/field/modules/list/tests/list.test', @@ -35612,19 +36149,19 @@ )) ->values(array( 'filename' => 'modules/field/tests/field.test', - 'hash' => '0c9c6f9396ab8e0685951f4e90f298629c31d2f7970e5b288e674bc146fefa90', + 'hash' => '5eaad7a933ef8ea05b958056492ce17858cd542111f0fe81dd1a5949ad8f966e', )) ->values(array( 'filename' => 'modules/field_ui/field_ui.test', - 'hash' => 'da42e28d6f32d447b4a6e5b463a2f7d87d6ce32f149de04a98fa8e3f286c9f68', + 'hash' => 'ded58a83a37cf111834f68fde9c34cddc7f4d36b91f31281e41ed5220c65dac4', )) ->values(array( 'filename' => 'modules/file/tests/file.test', - 'hash' => '5cb7a7a6cc14a6d4269bf4d406a304f77052be7691e0ec9b8e7c5262316d7539', + 'hash' => '51d79794cbe647b2f5635ca9193b4d63bb9f99db4d9074676a80c55582b02985', )) ->values(array( 'filename' => 'modules/filter/filter.test', - 'hash' => '13330238c7b8d280ff2dd8cfee1c001d5a994ad45e3c9b9c5fdcd963c6080926', + 'hash' => '268488be9d8e6a4bfa906bbb5bbf1f0df5881c04a421cbefcd7aa4f05fb63ba0', )) ->values(array( 'filename' => 'modules/forum/forum.test', @@ -35636,19 +36173,19 @@ )) ->values(array( 'filename' => 'modules/image/image.test', - 'hash' => 'd6ea03d1e3df0e150ed3500b9896984e5c3cd5f28248f2aebecce5b9926eb23b', + 'hash' => '19459f5be2fb58058a984ef302d6f6defca20207324db25726d06a7743cc2960', )) ->values(array( 'filename' => 'modules/locale/locale.test', - 'hash' => '59fe99927c790699e0d5a7047df7c05eb9ba3ef4c1363a929e7a65115da24f1a', + 'hash' => '61c6a80ba44ff92e6ba4a350b7c95890368e2f9e029b8f84563df2490a8e93b1', )) ->values(array( 'filename' => 'modules/menu/menu.test', - 'hash' => 'cd187c84aa97dcc228d8a1556ea10640c62f86083034533b6ac6830be610ca2a', + 'hash' => '51817d6c591c28cf268145c2d39b41f66e453edf42c86472e61b7081da1d86bb', )) ->values(array( 'filename' => 'modules/node/node.module', - 'hash' => '3489bbd7e909b21c54a1bd5e4d4daeafb9bebc6606e48fe1d5e7a6ed935a1a3e', + 'hash' => 'b594aa316e7d74024d633fb95a6e89a2c6c14cb108a481fd0b2521ec0e3316de', )) ->values(array( 'filename' => 'modules/node/node.test', @@ -35656,7 +36193,7 @@ )) ->values(array( 'filename' => 'modules/openid/openid.test', - 'hash' => '16661e3a940c69cfdabf6ba28ad8f99ae3854dcf43bbac0e823d2f1d32f7cb09', + 'hash' => '3decf7faf3a9396671d52c6065a31f0ef81828015e0348a0ba9358b618e737a1', )) ->values(array( 'filename' => 'modules/path/path.test', @@ -35672,7 +36209,7 @@ )) ->values(array( 'filename' => 'modules/profile/profile.test', - 'hash' => '6dcc39fcc5b07b56c2aab3eebd8432ffd33ee1d33fe1574ec9e665f8acb15330', + 'hash' => 'afc23aa58769a84d94c4a6cef7b0ea2c9aa0edfdf2563a34757a1fb4d3d58233', )) ->values(array( 'filename' => 'modules/rdf/rdf.test', @@ -35680,11 +36217,11 @@ )) ->values(array( 'filename' => 'modules/search/search.extender.inc', - 'hash' => 'c40f6569769ff581dbe11d29935c611320178f9a076977423e1d93e7d98013fa', + 'hash' => '013a6a841cc48a6dc991153fb692b8d1546e56b78d9c95e97e0d7e92296d3481', )) ->values(array( 'filename' => 'modules/search/search.test', - 'hash' => '71ffda1d5c81823aa6f557ca35ba451df2f684856174e25e917f8bf4f0c72453', + 'hash' => '6512521f8de3a54238c8f337ae0aa105cab2bbc9a1addb5b1ccb755842656913', )) ->values(array( 'filename' => 'modules/shortcut/shortcut.test', @@ -35692,11 +36229,11 @@ )) ->values(array( 'filename' => 'modules/simpletest/drupal_web_test_case.php', - 'hash' => '2eb60780f843a6713fc2856f601b811ccd26b38f2b5afd845c113f093d97a138', + 'hash' => 'a4c07ab08d578cc9c4adfb39aaa98270cacc58885c1d61f3a71f207142f4fc0b', )) ->values(array( 'filename' => 'modules/simpletest/simpletest.test', - 'hash' => '8af29b4eaa4942baf69d3210220d855743411ad2b575c9fb12e1b220aa45e3e0', + 'hash' => '8112284b928297e326a2cb2a029a8ee35490732ce73ab0b54a91e9613a84e951', )) ->values(array( 'filename' => 'modules/simpletest/tests/actions.test', @@ -35704,15 +36241,19 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/ajax.test', - 'hash' => '692a582ca0164c4374c7567d4c23b2f2c6638f7f88fd16d3a709c7af5e8744de', + 'hash' => '0581306ba076da005db073036806a4d393a166221cd7171e3e3b1974b7082106', )) ->values(array( 'filename' => 'modules/simpletest/tests/batch.test', 'hash' => '665a621f4d5f819295ca7c53158d586ed98c42d8a8e6db1e67fb332032ec07d5', )) +->values(array( + 'filename' => 'modules/simpletest/tests/boot.test', + 'hash' => '1a7cf3c120a8e544cb251ba049ae598f8b25c0a9c3283e15df07a3a562641799', +)) ->values(array( 'filename' => 'modules/simpletest/tests/bootstrap.test', - 'hash' => '5c6a25807ace61032eb7c5f59b4d57dd426bdd58490629ca37f70954dce33a32', + 'hash' => '4ccb0841905a34438e5b3acd712d0a1b52b6aa41535d3a64d3e50eff355a5dbe', )) ->values(array( 'filename' => 'modules/simpletest/tests/cache.test', @@ -35720,11 +36261,11 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/common.test', - 'hash' => 'fd42e79d21a6807b889f70ec2feaa6034cbe98d947795cd2c0e11c592ada19aa', + 'hash' => 'aa2449d4ce5109bc9593901f34f74ce9caeea6450539a120afdf7a71f1e35276', )) ->values(array( 'filename' => 'modules/simpletest/tests/database_test.test', - 'hash' => '681e7c84278793f0b0146c89e2e78a3d3705193faab5b98bc88d4b43539a2584', + 'hash' => '64baa1520d815e049310ae697fa79390b6b0a02fb03d47c64d3caec8d40ab8e9', )) ->values(array( 'filename' => 'modules/simpletest/tests/entity_crud.test', @@ -35744,7 +36285,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/file.test', - 'hash' => '403e9020898f051c467fe54d72bc0bc0aefb784aabc90849dcf765f09694ead1', + 'hash' => '25fdee40ceb8c84f08677224db941e251906f2caa185b351de80eba76f20c90b', )) ->values(array( 'filename' => 'modules/simpletest/tests/filetransfer.test', @@ -35752,7 +36293,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/form.test', - 'hash' => 'b9af9565dbb10327c07365b7cc8c1da394085d1e1fc92d4f7e79fa1d17978a4f', + 'hash' => '1d932031c1b2e33947c1cb480457f9f6c95b1ee93bab6eab785c2cde290fd9d7', )) ->values(array( 'filename' => 'modules/simpletest/tests/graph.test', @@ -35760,7 +36301,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/image.test', - 'hash' => '0c0331b7239519aa2ce6cafe4bff8ee078875222531e5bbe1d60e131baaa0eb0', + 'hash' => 'fbad58b83e40aec654bf66835e30f81b83a76714efc560d73e7be3841ab5e996', )) ->values(array( 'filename' => 'modules/simpletest/tests/lock.test', @@ -35776,7 +36317,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/module.test', - 'hash' => '35cf0c46b1129a45229fc7b03f7229a99ded19d57dcd751a3a8858d7422ae84e', + 'hash' => '056de988f33d43c39e62f067af8f449f5192cd27bbbcf358a6e3b0d34d94167c', )) ->values(array( 'filename' => 'modules/simpletest/tests/pager.test', @@ -35800,7 +36341,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/session.test', - 'hash' => '2619d36051b1cfa9ff53b1960b784a998943167018952e4e11832f2f0324d19c', + 'hash' => '6416694ef7c79680f99e405468401567357c38abead1e0ce9e232a15e7dcd823', )) ->values(array( 'filename' => 'modules/simpletest/tests/tablesort.test', @@ -35808,7 +36349,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/theme.test', - 'hash' => '4843ff803a403ceff29ebf6c59ae9175cb0237b91d52305a52501610078ce1c4', + 'hash' => 'f542bdf4efc342609b8804767b793521c6641ab5cd31a7130865feeef5f2cfa1', )) ->values(array( 'filename' => 'modules/simpletest/tests/unicode.test', @@ -35876,7 +36417,7 @@ )) ->values(array( 'filename' => 'modules/simpletest/tests/upgrade/upgrade.upload.test', - 'hash' => 'a825081089f33a77a797fa6482e923a17fd90f2696267711a4c0d8a0792b9389', + 'hash' => '8fc15f53a5ef54b48133a8525fcd384729563ba2d9bd49ab035549d07fabf3c4', )) ->values(array( 'filename' => 'modules/simpletest/tests/upgrade/upgrade.user.test', @@ -35888,7 +36429,7 @@ )) ->values(array( 'filename' => 'modules/statistics/statistics.test', - 'hash' => '3fc1617038ab69ce32a666def03cac5f80532d2e71bad811b4e8b0f75250736c', + 'hash' => '3fd921d3cc26f9363bba0d6f29efb96c49c88ca51e2e2376b6554afaff8ceeb5', )) ->values(array( 'filename' => 'modules/syslog/syslog.test', @@ -35904,7 +36445,7 @@ )) ->values(array( 'filename' => 'modules/system/system.queue.inc', - 'hash' => 'ef00fd41ca86de386fa134d5bc1d816f9af550cf0e1334a5c0ade3119688ca3c', + 'hash' => 'a60cff401fc410cd81dc1d105ed66f79396ed7b15fdc3a5c5b80593ad5d4352a', )) ->values(array( 'filename' => 'modules/system/system.tar.inc', @@ -35912,7 +36453,7 @@ )) ->values(array( 'filename' => 'modules/system/system.test', - 'hash' => 'ad3c68f2cacfe6a99c065edc9aca05a22bdbc74ff6158e9918255b4633134ab4', + 'hash' => 'b53fdc9f28a49d9bdd819721a6bc4ae0e8a7b023a415e98672a99453187c1f1e', )) ->values(array( 'filename' => 'modules/system/system.updater.inc', @@ -35944,23 +36485,23 @@ )) ->values(array( 'filename' => 'modules/user/user.module', - 'hash' => 'b658c75c17b263a0aa6be903429c14e0fb1c308dd4e9024e369b7e7feb2b5dce', + 'hash' => '88bb508e0eb658281b085cd07c81808bd9634bba8a2271515c1d68079d58817d', )) ->values(array( 'filename' => 'modules/user/user.test', - 'hash' => 'd27160f1fd04cfb497ff080c7266fcebcd310d2224cfc6aef70035b275d65573', + 'hash' => '178320fdb9a0c8754f1fa7272f68f536dcb94ae82ce7d0fc6a0f8a476c1f6922', )) ->values(array( 'filename' => 'sites/all/modules/date/date.migrate.inc', - 'hash' => '6e44d2f6c8ae81a42dc545951663f13e22c914efcaaa9c7c7d7da77ee06d4ecd', + 'hash' => '47ffb48daf97c13ef154cf2ffff577018f02a7091b85dfb39e9c2c89e1da6a5d', )) ->values(array( 'filename' => 'sites/all/modules/date/date_api/date_api.module', - 'hash' => '107f1668a3a75f9b18e834f8494fc52d8ccf0d6b231c98bd10b9313cfbe18776', + 'hash' => 'af2124c5727d839871309b31fe288fe3945d6ef67eb469ddcc02839be98860dc', )) ->values(array( 'filename' => 'sites/all/modules/date/date_api/date_api_sql.inc', - 'hash' => '89e92bdb4eb9b348a57d70ddb933c86e81f6e7a7047cd9e77c83a454c00c5a11', + 'hash' => '5a484b487c13fd6094348e2011c19e72d6c6c9ceb0b0a4143ef5542cd1c495fa', )) ->values(array( 'filename' => 'sites/all/modules/date/date_repeat/tests/date_repeat.test', @@ -35980,11 +36521,11 @@ )) ->values(array( 'filename' => 'sites/all/modules/date/tests/date_api.test', - 'hash' => 'ebaf0427701be69bd3dc8a766528d7347a87ee15c2f69b240188aa5ab1182cbd', + 'hash' => '280148ca742592a1e22f663fe4d810532b95d09975db0182347a0bbd6917f996', )) ->values(array( 'filename' => 'sites/all/modules/date/tests/date_field.test', - 'hash' => '785a6cf0afcd4619a58263487e27e130ae0724f532018a5a127f24be1dbb4871', + 'hash' => 'bae59aee63ed204e27909709e59eeae1a6192e5f7456de2ce2cce06c49732dc4', )) ->values(array( 'filename' => 'sites/all/modules/date/tests/date_migrate.test', @@ -35992,12 +36533,20 @@ )) ->values(array( 'filename' => 'sites/all/modules/date/tests/date_timezone.test', - 'hash' => '760c3e761d122bafd2fab2056362f33424416a1407e7a1423df42acd03f84495', + 'hash' => '598ac52aa82f79fe90faa401c2c6dc7114295c0321800ea9a9b4058717d00409', )) ->values(array( 'filename' => 'sites/all/modules/date/tests/date_validation.test', 'hash' => '2e4d27c29192c9d55eb27b985d7e9838702c4324d36ed6e3a85999e9f25ada99', )) +->values(array( + 'filename' => 'sites/all/modules/date/tests/date_views_pager.test', + 'hash' => 'aceff66e11dd3ea418e9905b28384432f4fe7cf9746e711cf56add73e64336dd', +)) +->values(array( + 'filename' => 'sites/all/modules/date/tests/date_views_popup.test', + 'hash' => '0684ad4977093fd7338eb045f85ceda195e82f50bd33fecbf0dca00e42b0385e', +)) ->values(array( 'filename' => 'sites/all/modules/email/email.migrate.inc', 'hash' => 'bf3859ca39a3e5570e4ac862858f066668caab33841d65bdfa229c8445e12d5a', @@ -36964,6 +37513,12 @@ 'data' => ' a node 1 default examplecom another examplecom 99999999 monday january 19 2015 2215 monday january 19 2015 2215 prefix value120suffix value abc5xyz click here some more text 9 a comment permalink submitted by admin on mon 1192015 2218 this is a comment log in or register to post comments ', 'reindex' => '0', )) +->values(array( + 'sid' => '2', + 'type' => 'node', + 'data' => ' the thing about deep space 9 is that it s the absolute best show ever trust me i would know benjamin sisko odo quark ', + 'reindex' => '0', +)) ->execute(); $connection->schema()->createTable('search_index', array( @@ -37194,6 +37749,102 @@ 'type' => 'node', 'score' => '1', )) +->values(array( + 'word' => '9', + 'sid' => '2', + 'type' => 'node', + 'score' => '26', +)) +->values(array( + 'word' => 'about', + 'sid' => '2', + 'type' => 'node', + 'score' => '26', +)) +->values(array( + 'word' => 'absolute', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'benjamin', + 'sid' => '2', + 'type' => 'node', + 'score' => '11', +)) +->values(array( + 'word' => 'best', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'deep', + 'sid' => '2', + 'type' => 'node', + 'score' => '26', +)) +->values(array( + 'word' => 'ever', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'know', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'quark', + 'sid' => '2', + 'type' => 'node', + 'score' => '11', +)) +->values(array( + 'word' => 'show', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'sisko', + 'sid' => '2', + 'type' => 'node', + 'score' => '11', +)) +->values(array( + 'word' => 'space', + 'sid' => '2', + 'type' => 'node', + 'score' => '26', +)) +->values(array( + 'word' => 'that', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'thing', + 'sid' => '2', + 'type' => 'node', + 'score' => '26', +)) +->values(array( + 'word' => 'trust', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) +->values(array( + 'word' => 'would', + 'sid' => '2', + 'type' => 'node', + 'score' => '1', +)) ->execute(); $connection->schema()->createTable('search_node_links', array( @@ -37294,6 +37945,14 @@ 'word' => 'abc5xyz', 'count' => '0', )) +->values(array( + 'word' => 'about', + 'count' => '0', +)) +->values(array( + 'word' => 'absolute', + 'count' => '0', +)) ->values(array( 'word' => 'admin', 'count' => '0', @@ -37302,6 +37961,14 @@ 'word' => 'another', 'count' => '0', )) +->values(array( + 'word' => 'benjamin', + 'count' => '0', +)) +->values(array( + 'word' => 'best', + 'count' => '0', +)) ->values(array( 'word' => 'click', 'count' => '0', @@ -37314,10 +37981,18 @@ 'word' => 'comments', 'count' => '0', )) +->values(array( + 'word' => 'deep', + 'count' => '0', +)) ->values(array( 'word' => 'default', 'count' => '0', )) +->values(array( + 'word' => 'ever', + 'count' => '0', +)) ->values(array( 'word' => 'examplecom', 'count' => '0', @@ -37330,6 +38005,10 @@ 'word' => 'january', 'count' => '0', )) +->values(array( + 'word' => 'know', + 'count' => '0', +)) ->values(array( 'word' => 'monday', 'count' => '0', @@ -37354,14 +38033,30 @@ 'word' => 'prefix', 'count' => '0', )) +->values(array( + 'word' => 'quark', + 'count' => '0', +)) ->values(array( 'word' => 'register', 'count' => '0', )) +->values(array( + 'word' => 'show', + 'count' => '0', +)) +->values(array( + 'word' => 'sisko', + 'count' => '0', +)) ->values(array( 'word' => 'some', 'count' => '0', )) +->values(array( + 'word' => 'space', + 'count' => '0', +)) ->values(array( 'word' => 'submitted', 'count' => '0', @@ -37370,10 +38065,22 @@ 'word' => 'text', 'count' => '0', )) +->values(array( + 'word' => 'that', + 'count' => '0', +)) +->values(array( + 'word' => 'thing', + 'count' => '0', +)) ->values(array( 'word' => 'this', 'count' => '0', )) +->values(array( + 'word' => 'trust', + 'count' => '0', +)) ->values(array( 'word' => 'value', 'count' => '0', @@ -37382,6 +38089,10 @@ 'word' => 'value120suffix', 'count' => '0', )) +->values(array( + 'word' => 'would', + 'count' => '0', +)) ->execute(); $connection->schema()->createTable('semaphore', array( @@ -37431,7 +38142,7 @@ 'value', )) ->values(array( - 'value' => '1', + 'value' => '2', )) ->execute(); @@ -37698,7 +38409,7 @@ 'bootstrap' => '0', 'schema_version' => '7004', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:10:"Aggregator";s:11:"description";s:57:"Aggregates syndicated content (RSS, RDF, and Atom feeds).";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"aggregator.test";}s:9:"configure";s:41:"admin/config/services/aggregator/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:14:"aggregator.css";s:33:"modules/aggregator/aggregator.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:10:"Aggregator";s:11:"description";s:57:"Aggregates syndicated content (RSS, RDF, and Atom feeds).";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"aggregator.test";}s:9:"configure";s:41:"admin/config/services/aggregator/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:14:"aggregator.css";s:33:"modules/aggregator/aggregator.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/aggregator/tests/aggregator_test.module', @@ -37709,7 +38420,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:23:"Aggregator module tests";s:11:"description";s:46:"Support module for aggregator related testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:23:"Aggregator module tests";s:11:"description";s:46:"Support module for aggregator related testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/block/block.module', @@ -37720,7 +38431,7 @@ 'bootstrap' => '0', 'schema_version' => '7009', 'weight' => '-5', - 'info' => 'a:13:{s:4:"name";s:5:"Block";s:11:"description";s:140:"Controls the visual building blocks a page is constructed with. Blocks are boxes of content rendered into an area, or region, of a web page.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"block.test";}s:9:"configure";s:21:"admin/structure/block";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:5:"Block";s:11:"description";s:140:"Controls the visual building blocks a page is constructed with. Blocks are boxes of content rendered into an area, or region, of a web page.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"block.test";}s:9:"configure";s:21:"admin/structure/block";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/block/tests/block_test.module', @@ -37731,7 +38442,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Block test";s:11:"description";s:21:"Provides test blocks.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Block test";s:11:"description";s:21:"Provides test blocks.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/blog/blog.module', @@ -37742,7 +38453,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:4:"Blog";s:11:"description";s:25:"Enables multi-user blogs.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"blog.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:4:"Blog";s:11:"description";s:25:"Enables multi-user blogs.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"blog.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/book/book.module', @@ -37753,7 +38464,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"Book";s:11:"description";s:66:"Allows users to create and organize related content in an outline.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"book.test";}s:9:"configure";s:27:"admin/content/book/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"book.css";s:21:"modules/book/book.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:4:"Book";s:11:"description";s:66:"Allows users to create and organize related content in an outline.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"book.test";}s:9:"configure";s:27:"admin/content/book/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"book.css";s:21:"modules/book/book.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/color/color.module', @@ -37764,7 +38475,7 @@ 'bootstrap' => '0', 'schema_version' => '7001', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:5:"Color";s:11:"description";s:70:"Allows administrators to change the color scheme of compatible themes.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"color.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:5:"Color";s:11:"description";s:70:"Allows administrators to change the color scheme of compatible themes.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"color.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/comment/comment.module', @@ -37775,7 +38486,7 @@ 'bootstrap' => '0', 'schema_version' => '7009', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:7:"Comment";s:11:"description";s:57:"Allows users to comment on and discuss published content.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:4:"text";}s:5:"files";a:2:{i:0;s:14:"comment.module";i:1;s:12:"comment.test";}s:9:"configure";s:21:"admin/content/comment";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:11:"comment.css";s:27:"modules/comment/comment.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:7:"Comment";s:11:"description";s:57:"Allows users to comment on and discuss published content.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:4:"text";}s:5:"files";a:2:{i:0;s:14:"comment.module";i:1;s:12:"comment.test";}s:9:"configure";s:21:"admin/content/comment";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:11:"comment.css";s:27:"modules/comment/comment.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/contact/contact.module', @@ -37786,7 +38497,7 @@ 'bootstrap' => '0', 'schema_version' => '7003', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:7:"Contact";s:11:"description";s:61:"Enables the use of both personal and site-wide contact forms.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"contact.test";}s:9:"configure";s:23:"admin/structure/contact";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:7:"Contact";s:11:"description";s:61:"Enables the use of both personal and site-wide contact forms.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"contact.test";}s:9:"configure";s:23:"admin/structure/contact";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/contextual/contextual.module', @@ -37797,7 +38508,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:16:"Contextual links";s:11:"description";s:75:"Provides contextual links to perform actions related to elements on a page.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"contextual.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:16:"Contextual links";s:11:"description";s:75:"Provides contextual links to perform actions related to elements on a page.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"contextual.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/dashboard/dashboard.module', @@ -37808,7 +38519,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:9:"Dashboard";s:11:"description";s:136:"Provides a dashboard page in the administrative interface for organizing administrative tasks and tracking information within your site.";s:4:"core";s:3:"7.x";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:5:"files";a:1:{i:0;s:14:"dashboard.test";}s:12:"dependencies";a:1:{i:0;s:5:"block";}s:9:"configure";s:25:"admin/dashboard/customize";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:9:"Dashboard";s:11:"description";s:136:"Provides a dashboard page in the administrative interface for organizing administrative tasks and tracking information within your site.";s:4:"core";s:3:"7.x";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:5:"files";a:1:{i:0;s:14:"dashboard.test";}s:12:"dependencies";a:1:{i:0;s:5:"block";}s:9:"configure";s:25:"admin/dashboard/customize";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/dblog/dblog.module', @@ -37819,7 +38530,7 @@ 'bootstrap' => '1', 'schema_version' => '7002', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:16:"Database logging";s:11:"description";s:47:"Logs and records system events to the database.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"dblog.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:16:"Database logging";s:11:"description";s:47:"Logs and records system events to the database.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"dblog.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field/field.module', @@ -37830,7 +38541,7 @@ 'bootstrap' => '0', 'schema_version' => '7003', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:5:"Field";s:11:"description";s:57:"Field API to add fields to entities like nodes and users.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:4:{i:0;s:12:"field.module";i:1;s:16:"field.attach.inc";i:2;s:20:"field.info.class.inc";i:3;s:16:"tests/field.test";}s:12:"dependencies";a:1:{i:0;s:17:"field_sql_storage";}s:8:"required";b:1;s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:15:"theme/field.css";s:29:"modules/field/theme/field.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:5:"Field";s:11:"description";s:57:"Field API to add fields to entities like nodes and users.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:4:{i:0;s:12:"field.module";i:1;s:16:"field.attach.inc";i:2;s:20:"field.info.class.inc";i:3;s:16:"tests/field.test";}s:12:"dependencies";a:1:{i:0;s:17:"field_sql_storage";}s:8:"required";b:1;s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:15:"theme/field.css";s:29:"modules/field/theme/field.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field/modules/field_sql_storage/field_sql_storage.module', @@ -37841,7 +38552,7 @@ 'bootstrap' => '0', 'schema_version' => '7002', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:17:"Field SQL storage";s:11:"description";s:37:"Stores field data in an SQL database.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:22:"field_sql_storage.test";}s:8:"required";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:17:"Field SQL storage";s:11:"description";s:37:"Stores field data in an SQL database.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:22:"field_sql_storage.test";}s:8:"required";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field/modules/list/list.module', @@ -37852,7 +38563,7 @@ 'bootstrap' => '0', 'schema_version' => '7002', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"List";s:11:"description";s:69:"Defines list field types. Use with Options to create selection lists.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:2:{i:0;s:5:"field";i:1;s:7:"options";}s:5:"files";a:1:{i:0;s:15:"tests/list.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:4:"List";s:11:"description";s:69:"Defines list field types. Use with Options to create selection lists.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:2:{i:0;s:5:"field";i:1;s:7:"options";}s:5:"files";a:1:{i:0;s:15:"tests/list.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/field/modules/list/tests/list_test.module', @@ -37863,7 +38574,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:9:"List test";s:11:"description";s:41:"Support module for the List module tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:9:"List test";s:11:"description";s:41:"Support module for the List module tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field/modules/number/number.module', @@ -37874,7 +38585,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:6:"Number";s:11:"description";s:28:"Defines numeric field types.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:11:"number.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:6:"Number";s:11:"description";s:28:"Defines numeric field types.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:11:"number.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/field/modules/options/options.module', @@ -37885,7 +38596,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:7:"Options";s:11:"description";s:82:"Defines selection, check box and radio button widgets for text and numeric fields.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:12:"options.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:7:"Options";s:11:"description";s:82:"Defines selection, check box and radio button widgets for text and numeric fields.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:12:"options.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field/modules/text/text.module', @@ -37896,7 +38607,7 @@ 'bootstrap' => '0', 'schema_version' => '7000', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"Text";s:11:"description";s:32:"Defines simple text field types.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:9:"text.test";}s:8:"required";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:4:"Text";s:11:"description";s:32:"Defines simple text field types.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:9:"text.test";}s:8:"required";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/field/tests/field_test.module', @@ -37907,7 +38618,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:14:"Field API Test";s:11:"description";s:39:"Support module for the Field API tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:5:"files";a:1:{i:0;s:21:"field_test.entity.inc";}s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:14:"Field API Test";s:11:"description";s:39:"Support module for the Field API tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:5:"files";a:1:{i:0;s:21:"field_test.entity.inc";}s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/field_ui/field_ui.module', @@ -37918,7 +38629,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:8:"Field UI";s:11:"description";s:33:"User interface for the Field API.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:13:"field_ui.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:8:"Field UI";s:11:"description";s:33:"User interface for the Field API.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:13:"field_ui.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/file/file.module', @@ -37929,7 +38640,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"File";s:11:"description";s:26:"Defines a file field type.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:15:"tests/file.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:4:"File";s:11:"description";s:26:"Defines a file field type.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:5:"field";}s:5:"files";a:1:{i:0;s:15:"tests/file.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/file/tests/file_module_test.module', @@ -37940,7 +38651,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:9:"File test";s:11:"description";s:53:"Provides hooks for testing File module functionality.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:9:"File test";s:11:"description";s:53:"Provides hooks for testing File module functionality.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/filter/filter.module', @@ -37951,7 +38662,7 @@ 'bootstrap' => '0', 'schema_version' => '7010', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:6:"Filter";s:11:"description";s:43:"Filters content in preparation for display.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"filter.test";}s:8:"required";b:1;s:9:"configure";s:28:"admin/config/content/formats";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:6:"Filter";s:11:"description";s:43:"Filters content in preparation for display.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"filter.test";}s:8:"required";b:1;s:9:"configure";s:28:"admin/config/content/formats";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/forum/forum.module', @@ -37962,7 +38673,7 @@ 'bootstrap' => '0', 'schema_version' => '7012', 'weight' => '1', - 'info' => 'a:14:{s:4:"name";s:5:"Forum";s:11:"description";s:27:"Provides discussion forums.";s:12:"dependencies";a:2:{i:0;s:8:"taxonomy";i:1;s:7:"comment";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"forum.test";}s:9:"configure";s:21:"admin/structure/forum";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"forum.css";s:23:"modules/forum/forum.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:5:"Forum";s:11:"description";s:27:"Provides discussion forums.";s:12:"dependencies";a:2:{i:0;s:8:"taxonomy";i:1;s:7:"comment";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:10:"forum.test";}s:9:"configure";s:21:"admin/structure/forum";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:9:"forum.css";s:23:"modules/forum/forum.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/help/help.module', @@ -37973,7 +38684,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:4:"Help";s:11:"description";s:35:"Manages the display of online help.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"help.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:4:"Help";s:11:"description";s:35:"Manages the display of online help.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"help.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/image/image.module', @@ -37984,7 +38695,7 @@ 'bootstrap' => '0', 'schema_version' => '7005', 'weight' => '0', - 'info' => 'a:15:{s:4:"name";s:5:"Image";s:11:"description";s:34:"Provides image manipulation tools.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:4:"file";}s:5:"files";a:1:{i:0;s:10:"image.test";}s:9:"configure";s:31:"admin/config/media/image-styles";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:15:{s:4:"name";s:5:"Image";s:11:"description";s:34:"Provides image manipulation tools.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:4:"file";}s:5:"files";a:1:{i:0;s:10:"image.test";}s:9:"configure";s:31:"admin/config/media/image-styles";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/image/tests/image_module_test.module', @@ -37995,7 +38706,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Image test";s:11:"description";s:69:"Provides hook implementations for testing Image module functionality.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:24:"image_module_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Image test";s:11:"description";s:69:"Provides hook implementations for testing Image module functionality.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:24:"image_module_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/locale/locale.module', @@ -38006,7 +38717,7 @@ 'bootstrap' => '0', 'schema_version' => '7005', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:6:"Locale";s:11:"description";s:119:"Adds language handling functionality and enables the translation of the user interface to languages other than English.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"locale.test";}s:9:"configure";s:30:"admin/config/regional/language";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:6:"Locale";s:11:"description";s:119:"Adds language handling functionality and enables the translation of the user interface to languages other than English.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"locale.test";}s:9:"configure";s:30:"admin/config/regional/language";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/locale/tests/locale_test.module', @@ -38017,7 +38728,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Locale Test";s:11:"description";s:42:"Support module for the locale layer tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Locale Test";s:11:"description";s:42:"Support module for the locale layer tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/menu/menu.module', @@ -38028,7 +38739,7 @@ 'bootstrap' => '0', 'schema_version' => '7003', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:4:"Menu";s:11:"description";s:60:"Allows administrators to customize the site navigation menu.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"menu.test";}s:9:"configure";s:20:"admin/structure/menu";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:4:"Menu";s:11:"description";s:60:"Allows administrators to customize the site navigation menu.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"menu.test";}s:9:"configure";s:20:"admin/structure/menu";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/node/node.module', @@ -38037,9 +38748,9 @@ 'owner' => '', 'status' => '1', 'bootstrap' => '0', - 'schema_version' => '7014', + 'schema_version' => '7015', 'weight' => '0', - 'info' => 'a:15:{s:4:"name";s:4:"Node";s:11:"description";s:66:"Allows content to be submitted to the site and displayed on pages.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:11:"node.module";i:1;s:9:"node.test";}s:8:"required";b:1;s:9:"configure";s:21:"admin/structure/types";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"node.css";s:21:"modules/node/node.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:15:{s:4:"name";s:4:"Node";s:11:"description";s:66:"Allows content to be submitted to the site and displayed on pages.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:11:"node.module";i:1;s:9:"node.test";}s:8:"required";b:1;s:9:"configure";s:21:"admin/structure/types";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"node.css";s:21:"modules/node/node.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/node/tests/node_access_test.module', @@ -38050,7 +38761,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:24:"Node module access tests";s:11:"description";s:43:"Support module for node permission testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:24:"Node module access tests";s:11:"description";s:43:"Support module for node permission testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/node/tests/node_test.module', @@ -38061,7 +38772,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:17:"Node module tests";s:11:"description";s:40:"Support module for node related testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:17:"Node module tests";s:11:"description";s:40:"Support module for node related testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/node/tests/node_test_exception.module', @@ -38072,7 +38783,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:27:"Node module exception tests";s:11:"description";s:50:"Support module for node related exception testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:27:"Node module exception tests";s:11:"description";s:50:"Support module for node related exception testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/openid/openid.module', @@ -38083,7 +38794,7 @@ 'bootstrap' => '0', 'schema_version' => '7000', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:6:"OpenID";s:11:"description";s:48:"Allows users to log into your site using OpenID.";s:7:"version";s:4:"7.37";s:7:"package";s:4:"Core";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"openid.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:6:"OpenID";s:11:"description";s:48:"Allows users to log into your site using OpenID.";s:7:"version";s:4:"7.40";s:7:"package";s:4:"Core";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"openid.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/openid/tests/openid_test.module', @@ -38094,7 +38805,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:21:"OpenID dummy provider";s:11:"description";s:33:"OpenID provider used for testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:6:"openid";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:21:"OpenID dummy provider";s:11:"description";s:33:"OpenID provider used for testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:6:"openid";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/overlay/overlay.module', @@ -38105,7 +38816,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:7:"Overlay";s:11:"description";s:59:"Displays the Drupal administration interface in an overlay.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:7:"Overlay";s:11:"description";s:59:"Displays the Drupal administration interface in an overlay.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/path/path.module', @@ -38116,7 +38827,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:4:"Path";s:11:"description";s:28:"Allows users to rename URLs.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"path.test";}s:9:"configure";s:24:"admin/config/search/path";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:4:"Path";s:11:"description";s:28:"Allows users to rename URLs.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"path.test";}s:9:"configure";s:24:"admin/config/search/path";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/php/php.module', @@ -38127,7 +38838,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:10:"PHP filter";s:11:"description";s:50:"Allows embedded PHP code/snippets to be evaluated.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:8:"php.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:10:"PHP filter";s:11:"description";s:50:"Allows embedded PHP code/snippets to be evaluated.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:8:"php.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/poll/poll.module', @@ -38138,7 +38849,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:4:"Poll";s:11:"description";s:95:"Allows your site to capture votes on different topics in the form of multiple choice questions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"poll.test";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"poll.css";s:21:"modules/poll/poll.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:4:"Poll";s:11:"description";s:95:"Allows your site to capture votes on different topics in the form of multiple choice questions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:9:"poll.test";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"poll.css";s:21:"modules/poll/poll.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/profile/profile.module', @@ -38149,7 +38860,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:7:"Profile";s:11:"description";s:36:"Supports configurable user profiles.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"profile.test";}s:9:"configure";s:27:"admin/config/people/profile";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:7:"Profile";s:11:"description";s:36:"Supports configurable user profiles.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"profile.test";}s:9:"configure";s:27:"admin/config/people/profile";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/rdf/rdf.module', @@ -38160,7 +38871,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:3:"RDF";s:11:"description";s:148:"Enriches your content with metadata to let other applications (e.g. search engines, aggregators) better understand its relationships and attributes.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:8:"rdf.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:3:"RDF";s:11:"description";s:148:"Enriches your content with metadata to let other applications (e.g. search engines, aggregators) better understand its relationships and attributes.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:8:"rdf.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/rdf/tests/rdf_test.module', @@ -38171,7 +38882,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:16:"RDF module tests";s:11:"description";s:38:"Support module for RDF module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:16:"RDF module tests";s:11:"description";s:38:"Support module for RDF module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/search/search.module', @@ -38182,7 +38893,7 @@ 'bootstrap' => '0', 'schema_version' => '7000', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:6:"Search";s:11:"description";s:36:"Enables site-wide keyword searching.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:19:"search.extender.inc";i:1;s:11:"search.test";}s:9:"configure";s:28:"admin/config/search/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:10:"search.css";s:25:"modules/search/search.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:6:"Search";s:11:"description";s:36:"Enables site-wide keyword searching.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:19:"search.extender.inc";i:1;s:11:"search.test";}s:9:"configure";s:28:"admin/config/search/settings";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:10:"search.css";s:25:"modules/search/search.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/search/tests/search_embedded_form.module', @@ -38193,7 +38904,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:20:"Search embedded form";s:11:"description";s:59:"Support module for search module testing of embedded forms.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:20:"Search embedded form";s:11:"description";s:59:"Support module for search module testing of embedded forms.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/search/tests/search_extra_type.module', @@ -38204,7 +38915,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:16:"Test search type";s:11:"description";s:41:"Support module for search module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:16:"Test search type";s:11:"description";s:41:"Support module for search module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/search/tests/search_node_tags.module', @@ -38215,7 +38926,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:21:"Test search node tags";s:11:"description";s:44:"Support module for Node search tags testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:21:"Test search node tags";s:11:"description";s:44:"Support module for Node search tags testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/shortcut/shortcut.module', @@ -38226,7 +38937,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:8:"Shortcut";s:11:"description";s:60:"Allows users to manage customizable lists of shortcut links.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:13:"shortcut.test";}s:9:"configure";s:36:"admin/config/user-interface/shortcut";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:8:"Shortcut";s:11:"description";s:60:"Allows users to manage customizable lists of shortcut links.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:13:"shortcut.test";}s:9:"configure";s:36:"admin/config/user-interface/shortcut";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/simpletest.module', @@ -38237,7 +38948,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:7:"Testing";s:11:"description";s:53:"Provides a framework for unit and functional testing.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:49:{i:0;s:15:"simpletest.test";i:1;s:24:"drupal_web_test_case.php";i:2;s:18:"tests/actions.test";i:3;s:15:"tests/ajax.test";i:4;s:16:"tests/batch.test";i:5;s:20:"tests/bootstrap.test";i:6;s:16:"tests/cache.test";i:7;s:17:"tests/common.test";i:8;s:24:"tests/database_test.test";i:9;s:22:"tests/entity_crud.test";i:10;s:32:"tests/entity_crud_hook_test.test";i:11;s:23:"tests/entity_query.test";i:12;s:16:"tests/error.test";i:13;s:15:"tests/file.test";i:14;s:23:"tests/filetransfer.test";i:15;s:15:"tests/form.test";i:16;s:16:"tests/graph.test";i:17;s:16:"tests/image.test";i:18;s:15:"tests/lock.test";i:19;s:15:"tests/mail.test";i:20;s:15:"tests/menu.test";i:21;s:17:"tests/module.test";i:22;s:16:"tests/pager.test";i:23;s:19:"tests/password.test";i:24;s:15:"tests/path.test";i:25;s:19:"tests/registry.test";i:26;s:17:"tests/schema.test";i:27;s:18:"tests/session.test";i:28;s:20:"tests/tablesort.test";i:29;s:16:"tests/theme.test";i:30;s:18:"tests/unicode.test";i:31;s:17:"tests/update.test";i:32;s:17:"tests/xmlrpc.test";i:33;s:26:"tests/upgrade/upgrade.test";i:34;s:34:"tests/upgrade/upgrade.comment.test";i:35;s:33:"tests/upgrade/upgrade.filter.test";i:36;s:32:"tests/upgrade/upgrade.forum.test";i:37;s:33:"tests/upgrade/upgrade.locale.test";i:38;s:31:"tests/upgrade/upgrade.menu.test";i:39;s:31:"tests/upgrade/upgrade.node.test";i:40;s:35:"tests/upgrade/upgrade.taxonomy.test";i:41;s:34:"tests/upgrade/upgrade.trigger.test";i:42;s:39:"tests/upgrade/upgrade.translatable.test";i:43;s:33:"tests/upgrade/upgrade.upload.test";i:44;s:31:"tests/upgrade/upgrade.user.test";i:45;s:36:"tests/upgrade/update.aggregator.test";i:46;s:33:"tests/upgrade/update.trigger.test";i:47;s:31:"tests/upgrade/update.field.test";i:48;s:30:"tests/upgrade/update.user.test";}s:9:"configure";s:41:"admin/config/development/testing/settings";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:7:"Testing";s:11:"description";s:53:"Provides a framework for unit and functional testing.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:50:{i:0;s:15:"simpletest.test";i:1;s:24:"drupal_web_test_case.php";i:2;s:18:"tests/actions.test";i:3;s:15:"tests/ajax.test";i:4;s:16:"tests/batch.test";i:5;s:15:"tests/boot.test";i:6;s:20:"tests/bootstrap.test";i:7;s:16:"tests/cache.test";i:8;s:17:"tests/common.test";i:9;s:24:"tests/database_test.test";i:10;s:22:"tests/entity_crud.test";i:11;s:32:"tests/entity_crud_hook_test.test";i:12;s:23:"tests/entity_query.test";i:13;s:16:"tests/error.test";i:14;s:15:"tests/file.test";i:15;s:23:"tests/filetransfer.test";i:16;s:15:"tests/form.test";i:17;s:16:"tests/graph.test";i:18;s:16:"tests/image.test";i:19;s:15:"tests/lock.test";i:20;s:15:"tests/mail.test";i:21;s:15:"tests/menu.test";i:22;s:17:"tests/module.test";i:23;s:16:"tests/pager.test";i:24;s:19:"tests/password.test";i:25;s:15:"tests/path.test";i:26;s:19:"tests/registry.test";i:27;s:17:"tests/schema.test";i:28;s:18:"tests/session.test";i:29;s:20:"tests/tablesort.test";i:30;s:16:"tests/theme.test";i:31;s:18:"tests/unicode.test";i:32;s:17:"tests/update.test";i:33;s:17:"tests/xmlrpc.test";i:34;s:26:"tests/upgrade/upgrade.test";i:35;s:34:"tests/upgrade/upgrade.comment.test";i:36;s:33:"tests/upgrade/upgrade.filter.test";i:37;s:32:"tests/upgrade/upgrade.forum.test";i:38;s:33:"tests/upgrade/upgrade.locale.test";i:39;s:31:"tests/upgrade/upgrade.menu.test";i:40;s:31:"tests/upgrade/upgrade.node.test";i:41;s:35:"tests/upgrade/upgrade.taxonomy.test";i:42;s:34:"tests/upgrade/upgrade.trigger.test";i:43;s:39:"tests/upgrade/upgrade.translatable.test";i:44;s:33:"tests/upgrade/upgrade.upload.test";i:45;s:31:"tests/upgrade/upgrade.user.test";i:46;s:36:"tests/upgrade/update.aggregator.test";i:47;s:33:"tests/upgrade/update.trigger.test";i:48;s:31:"tests/upgrade/update.field.test";i:49;s:30:"tests/upgrade/update.user.test";}s:9:"configure";s:41:"admin/config/development/testing/settings";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/actions_loop_test.module', @@ -38248,7 +38959,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:17:"Actions loop test";s:11:"description";s:39:"Support module for action loop testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:17:"Actions loop test";s:11:"description";s:39:"Support module for action loop testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/ajax_forms_test.module', @@ -38259,7 +38970,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:26:"AJAX form test mock module";s:11:"description";s:25:"Test for AJAX form calls.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:26:"AJAX form test mock module";s:11:"description";s:25:"Test for AJAX form calls.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/ajax_test.module', @@ -38270,7 +38981,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:9:"AJAX Test";s:11:"description";s:40:"Support module for AJAX framework tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:9:"AJAX Test";s:11:"description";s:40:"Support module for AJAX framework tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/batch_test.module', @@ -38281,7 +38992,29 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:14:"Batch API test";s:11:"description";s:35:"Support module for Batch API tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:14:"Batch API test";s:11:"description";s:35:"Support module for Batch API tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', +)) +->values(array( + 'filename' => 'modules/simpletest/tests/boot_test_1.module', + 'name' => 'boot_test_1', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => 'a:13:{s:4:"name";s:21:"Early bootstrap tests";s:11:"description";s:39:"A support module for hook_boot testing.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', +)) +->values(array( + 'filename' => 'modules/simpletest/tests/boot_test_2.module', + 'name' => 'boot_test_2', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => 'a:13:{s:4:"name";s:21:"Early bootstrap tests";s:11:"description";s:44:"A support module for hook_boot hook testing.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/common_test.module', @@ -38292,7 +39025,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:11:"Common Test";s:11:"description";s:32:"Support module for Common tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:15:"common_test.css";s:40:"modules/simpletest/tests/common_test.css";}s:5:"print";a:1:{s:21:"common_test.print.css";s:46:"modules/simpletest/tests/common_test.print.css";}}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:11:"Common Test";s:11:"description";s:32:"Support module for Common tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:15:"common_test.css";s:40:"modules/simpletest/tests/common_test.css";}s:5:"print";a:1:{s:21:"common_test.print.css";s:46:"modules/simpletest/tests/common_test.print.css";}}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/common_test_cron_helper.module', @@ -38303,7 +39036,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:23:"Common Test Cron Helper";s:11:"description";s:56:"Helper module for CronRunTestCase::testCronExceptions().";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:23:"Common Test Cron Helper";s:11:"description";s:56:"Helper module for CronRunTestCase::testCronExceptions().";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/database_test.module', @@ -38314,7 +39047,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:13:"Database Test";s:11:"description";s:40:"Support module for Database layer tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:13:"Database Test";s:11:"description";s:40:"Support module for Database layer tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/drupal_autoload_test/drupal_autoload_test.module', @@ -38325,7 +39058,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:25:"Drupal code registry test";s:11:"description";s:45:"Support module for testing the code registry.";s:5:"files";a:2:{i:0;s:34:"drupal_autoload_test_interface.inc";i:1;s:30:"drupal_autoload_test_class.inc";}s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:25:"Drupal code registry test";s:11:"description";s:45:"Support module for testing the code registry.";s:5:"files";a:2:{i:0;s:34:"drupal_autoload_test_interface.inc";i:1;s:30:"drupal_autoload_test_class.inc";}s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/drupal_system_listing_compatible_test/drupal_system_listing_compatible_test.module', @@ -38336,7 +39069,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:37:"Drupal system listing compatible test";s:11:"description";s:62:"Support module for testing the drupal_system_listing function.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:37:"Drupal system listing compatible test";s:11:"description";s:62:"Support module for testing the drupal_system_listing function.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/drupal_system_listing_incompatible_test/drupal_system_listing_incompatible_test.module', @@ -38347,7 +39080,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:39:"Drupal system listing incompatible test";s:11:"description";s:62:"Support module for testing the drupal_system_listing function.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:39:"Drupal system listing incompatible test";s:11:"description";s:62:"Support module for testing the drupal_system_listing function.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/entity_cache_test.module', @@ -38358,7 +39091,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:17:"Entity cache test";s:11:"description";s:40:"Support module for testing entity cache.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:28:"entity_cache_test_dependency";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:17:"Entity cache test";s:11:"description";s:40:"Support module for testing entity cache.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:28:"entity_cache_test_dependency";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/entity_cache_test_dependency.module', @@ -38369,7 +39102,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:28:"Entity cache test dependency";s:11:"description";s:51:"Support dependency module for testing entity cache.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:28:"Entity cache test dependency";s:11:"description";s:51:"Support dependency module for testing entity cache.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/entity_crud_hook_test.module', @@ -38380,7 +39113,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:22:"Entity CRUD Hooks Test";s:11:"description";s:35:"Support module for CRUD hook tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:22:"Entity CRUD Hooks Test";s:11:"description";s:35:"Support module for CRUD hook tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/entity_query_access_test.module', @@ -38391,7 +39124,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:24:"Entity query access test";s:11:"description";s:49:"Support module for checking entity query results.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:24:"Entity query access test";s:11:"description";s:49:"Support module for checking entity query results.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/error_test.module', @@ -38402,7 +39135,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Error test";s:11:"description";s:47:"Support module for error and exception testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Error test";s:11:"description";s:47:"Support module for error and exception testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/file_test.module', @@ -38413,7 +39146,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:9:"File test";s:11:"description";s:39:"Support module for file handling tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:16:"file_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:9:"File test";s:11:"description";s:39:"Support module for file handling tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:16:"file_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/filter_test.module', @@ -38424,7 +39157,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:18:"Filter test module";s:11:"description";s:33:"Tests filter hooks and functions.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:18:"Filter test module";s:11:"description";s:33:"Tests filter hooks and functions.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/form_test.module', @@ -38435,7 +39168,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:12:"FormAPI Test";s:11:"description";s:34:"Support module for Form API tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:12:"FormAPI Test";s:11:"description";s:34:"Support module for Form API tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/image_test.module', @@ -38446,7 +39179,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Image test";s:11:"description";s:39:"Support module for image toolkit tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Image test";s:11:"description";s:39:"Support module for image toolkit tests.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/menu_test.module', @@ -38457,7 +39190,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"Hook menu tests";s:11:"description";s:37:"Support module for menu hook testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"Hook menu tests";s:11:"description";s:37:"Support module for menu hook testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/module_test.module', @@ -38468,7 +39201,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Module test";s:11:"description";s:41:"Support module for module system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Module test";s:11:"description";s:41:"Support module for module system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/path_test.module', @@ -38479,7 +39212,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"Hook path tests";s:11:"description";s:37:"Support module for path hook testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"Hook path tests";s:11:"description";s:37:"Support module for path hook testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/psr_0_test/psr_0_test.module', @@ -38490,7 +39223,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:16:"PSR-0 Test cases";s:11:"description";s:44:"Test classes to be discovered by simpletest.";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:16:"PSR-0 Test cases";s:11:"description";s:44:"Test classes to be discovered by simpletest.";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/psr_4_test/psr_4_test.module', @@ -38501,7 +39234,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:16:"PSR-4 Test cases";s:11:"description";s:44:"Test classes to be discovered by simpletest.";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:16:"PSR-4 Test cases";s:11:"description";s:44:"Test classes to be discovered by simpletest.";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/requirements1_test.module', @@ -38512,7 +39245,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => "a:13:{s:4:\"name\";s:19:\"Requirements 1 Test\";s:11:\"description\";s:80:\"Tests that a module is not installed when it fails hook_requirements('install').\";s:7:\"package\";s:7:\"Testing\";s:7:\"version\";s:4:\"7.37\";s:4:\"core\";s:3:\"7.x\";s:6:\"hidden\";b:1;s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1430973154\";s:5:\"mtime\";i:1437399662;s:12:\"dependencies\";a:0:{}s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", + 'info' => "a:13:{s:4:\"name\";s:19:\"Requirements 1 Test\";s:11:\"description\";s:80:\"Tests that a module is not installed when it fails hook_requirements('install').\";s:7:\"package\";s:7:\"Testing\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:6:\"hidden\";b:1;s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:5:\"mtime\";i:1444866674;s:12:\"dependencies\";a:0:{}s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", )) ->values(array( 'filename' => 'modules/simpletest/tests/requirements2_test.module', @@ -38523,7 +39256,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => "a:13:{s:4:\"name\";s:19:\"Requirements 2 Test\";s:11:\"description\";s:98:\"Tests that a module is not installed when the one it depends on fails hook_requirements('install).\";s:12:\"dependencies\";a:2:{i:0;s:18:\"requirements1_test\";i:1;s:7:\"comment\";}s:7:\"package\";s:7:\"Testing\";s:7:\"version\";s:4:\"7.37\";s:4:\"core\";s:3:\"7.x\";s:6:\"hidden\";b:1;s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1430973154\";s:5:\"mtime\";i:1437399662;s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", + 'info' => "a:13:{s:4:\"name\";s:19:\"Requirements 2 Test\";s:11:\"description\";s:98:\"Tests that a module is not installed when the one it depends on fails hook_requirements('install).\";s:12:\"dependencies\";a:2:{i:0;s:18:\"requirements1_test\";i:1;s:7:\"comment\";}s:7:\"package\";s:7:\"Testing\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:6:\"hidden\";b:1;s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:5:\"mtime\";i:1444866674;s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", )) ->values(array( 'filename' => 'modules/simpletest/tests/session_test.module', @@ -38534,7 +39267,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:12:"Session test";s:11:"description";s:40:"Support module for session data testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:12:"Session test";s:11:"description";s:40:"Support module for session data testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_dependencies_test.module', @@ -38545,7 +39278,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:22:"System dependency test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:19:"_missing_dependency";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:22:"System dependency test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:19:"_missing_dependency";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_incompatible_core_version_dependencies_test.module', @@ -38556,7 +39289,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:50:"System incompatible core version dependencies test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:37:"system_incompatible_core_version_test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:50:"System incompatible core version dependencies test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:37:"system_incompatible_core_version_test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_incompatible_core_version_test.module', @@ -38567,7 +39300,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:37:"System incompatible core version test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"5.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:37:"System incompatible core version test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"5.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_incompatible_module_version_dependencies_test.module', @@ -38578,7 +39311,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:52:"System incompatible module version dependencies test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:46:"system_incompatible_module_version_test (>2.0)";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:52:"System incompatible module version dependencies test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:46:"system_incompatible_module_version_test (>2.0)";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_incompatible_module_version_test.module', @@ -38589,7 +39322,18 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:39:"System incompatible module version test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:39:"System incompatible module version test";s:11:"description";s:47:"Support module for testing system dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', +)) +->values(array( + 'filename' => 'modules/simpletest/tests/system_project_namespace_test.module', + 'name' => 'system_project_namespace_test', + 'type' => 'module', + 'owner' => '', + 'status' => '0', + 'bootstrap' => '0', + 'schema_version' => '-1', + 'weight' => '0', + 'info' => 'a:13:{s:4:"name";s:29:"System project namespace test";s:11:"description";s:58:"Support module for testing project namespace dependencies.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:13:"drupal:filter";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/system_test.module', @@ -38600,7 +39344,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"System test";s:11:"description";s:34:"Support module for system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:18:"system_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399662;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"System test";s:11:"description";s:34:"Support module for system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:18:"system_test.module";}s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/taxonomy_test.module', @@ -38611,7 +39355,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:20:"Taxonomy test module";s:11:"description";s:45:""Tests functions and hooks not used in core".";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:8:"taxonomy";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:20:"Taxonomy test module";s:11:"description";s:45:""Tests functions and hooks not used in core".";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:12:"dependencies";a:1:{i:0;s:8:"taxonomy";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/theme_test.module', @@ -38622,7 +39366,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Theme test";s:11:"description";s:40:"Support module for theme system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Theme test";s:11:"description";s:40:"Support module for theme system testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/update_script_test.module', @@ -38633,7 +39377,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:18:"Update script test";s:11:"description";s:41:"Support module for update script testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:18:"Update script test";s:11:"description";s:41:"Support module for update script testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/update_test_1.module', @@ -38644,7 +39388,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/update_test_2.module', @@ -38655,7 +39399,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/update_test_3.module', @@ -38666,7 +39410,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:34:"Support module for update testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/url_alter_test.module', @@ -38677,7 +39421,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"Url_alter tests";s:11:"description";s:45:"A support modules for url_alter hook testing.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"Url_alter tests";s:11:"description";s:45:"A support modules for url_alter hook testing.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/simpletest/tests/xmlrpc_test.module', @@ -38688,7 +39432,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:12:"XML-RPC Test";s:11:"description";s:75:"Support module for XML-RPC tests according to the validator1 specification.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:12:"XML-RPC Test";s:11:"description";s:75:"Support module for XML-RPC tests according to the validator1 specification.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/statistics/statistics.module', @@ -38699,7 +39443,7 @@ 'bootstrap' => '1', 'schema_version' => '7000', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Statistics";s:11:"description";s:37:"Logs access statistics for your site.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"statistics.test";}s:9:"configure";s:30:"admin/config/system/statistics";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Statistics";s:11:"description";s:37:"Logs access statistics for your site.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:15:"statistics.test";}s:9:"configure";s:30:"admin/config/system/statistics";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/syslog/syslog.module', @@ -38710,7 +39454,7 @@ 'bootstrap' => '1', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:6:"Syslog";s:11:"description";s:41:"Logs and records system events to syslog.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"syslog.test";}s:9:"configure";s:32:"admin/config/development/logging";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:6:"Syslog";s:11:"description";s:41:"Logs and records system events to syslog.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"syslog.test";}s:9:"configure";s:32:"admin/config/development/logging";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/system/system.module', @@ -38718,10 +39462,10 @@ 'type' => 'module', 'owner' => '', 'status' => '1', - 'bootstrap' => '0', - 'schema_version' => '7079', + 'bootstrap' => '1', + 'schema_version' => '7080', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:6:"System";s:11:"description";s:54:"Handles general site configuration for administrators.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:6:{i:0;s:19:"system.archiver.inc";i:1;s:15:"system.mail.inc";i:2;s:16:"system.queue.inc";i:3;s:14:"system.tar.inc";i:4;s:18:"system.updater.inc";i:5;s:11:"system.test";}s:8:"required";b:1;s:9:"configure";s:19:"admin/config/system";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:6:"System";s:11:"description";s:54:"Handles general site configuration for administrators.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:6:{i:0;s:19:"system.archiver.inc";i:1;s:15:"system.mail.inc";i:2;s:16:"system.queue.inc";i:3;s:14:"system.tar.inc";i:4;s:18:"system.updater.inc";i:5;s:11:"system.test";}s:8:"required";b:1;s:9:"configure";s:19:"admin/config/system";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/system/tests/cron_queue_test.module', @@ -38732,7 +39476,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"Cron Queue test";s:11:"description";s:41:"Support module for the cron queue runner.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"Cron Queue test";s:11:"description";s:41:"Support module for the cron queue runner.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/taxonomy/taxonomy.module', @@ -38743,7 +39487,7 @@ 'bootstrap' => '0', 'schema_version' => '7011', 'weight' => '0', - 'info' => 'a:15:{s:4:"name";s:8:"Taxonomy";s:11:"description";s:38:"Enables the categorization of content.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:7:"options";}s:5:"files";a:2:{i:0;s:15:"taxonomy.module";i:1;s:13:"taxonomy.test";}s:9:"configure";s:24:"admin/structure/taxonomy";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:15:{s:4:"name";s:8:"Taxonomy";s:11:"description";s:38:"Enables the categorization of content.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:1:{i:0;s:7:"options";}s:5:"files";a:2:{i:0;s:15:"taxonomy.module";i:1;s:13:"taxonomy.test";}s:9:"configure";s:24:"admin/structure/taxonomy";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'modules/toolbar/toolbar.module', @@ -38754,7 +39498,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:7:"Toolbar";s:11:"description";s:99:"Provides a toolbar that shows the top-level administration menu items and links from other modules.";s:4:"core";s:3:"7.x";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:7:"Toolbar";s:11:"description";s:99:"Provides a toolbar that shows the top-level administration menu items and links from other modules.";s:4:"core";s:3:"7.x";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/tracker/tracker.module', @@ -38765,7 +39509,7 @@ 'bootstrap' => '0', 'schema_version' => '7000', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:7:"Tracker";s:11:"description";s:45:"Enables tracking of recent content for users.";s:12:"dependencies";a:1:{i:0;s:7:"comment";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"tracker.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:7:"Tracker";s:11:"description";s:45:"Enables tracking of recent content for users.";s:12:"dependencies";a:1:{i:0;s:7:"comment";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"tracker.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/translation/tests/translation_test.module', @@ -38776,7 +39520,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:24:"Content Translation Test";s:11:"description";s:49:"Support module for the content translation tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:24:"Content Translation Test";s:11:"description";s:49:"Support module for the content translation tests.";s:4:"core";s:3:"7.x";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/translation/translation.module', @@ -38787,7 +39531,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:19:"Content translation";s:11:"description";s:57:"Allows content to be translated into different languages.";s:12:"dependencies";a:1:{i:0;s:6:"locale";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:16:"translation.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:19:"Content translation";s:11:"description";s:57:"Allows content to be translated into different languages.";s:12:"dependencies";a:1:{i:0;s:6:"locale";}s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:16:"translation.test";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/trigger/tests/trigger_test.module', @@ -38798,7 +39542,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:12:"Trigger Test";s:11:"description";s:33:"Support module for Trigger tests.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:12:"Trigger Test";s:11:"description";s:33:"Support module for Trigger tests.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/trigger/trigger.module', @@ -38809,7 +39553,7 @@ 'bootstrap' => '0', 'schema_version' => '7002', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:7:"Trigger";s:11:"description";s:90:"Enables actions to be fired on certain system events, such as when new content is created.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"trigger.test";}s:9:"configure";s:23:"admin/structure/trigger";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:7:"Trigger";s:11:"description";s:90:"Enables actions to be fired on certain system events, such as when new content is created.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:12:"trigger.test";}s:9:"configure";s:23:"admin/structure/trigger";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/update/tests/aaa_update_test.module', @@ -38820,7 +39564,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"AAA Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"AAA Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/update/tests/bbb_update_test.module', @@ -38831,7 +39575,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"BBB Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"BBB Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/update/tests/ccc_update_test.module', @@ -38842,7 +39586,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:15:"CCC Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.37";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:15:"CCC Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"version";s:4:"7.40";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/update/tests/update_test.module', @@ -38853,7 +39597,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:11:"Update test";s:11:"description";s:41:"Support module for update module testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/update/update.module', @@ -38864,7 +39608,7 @@ 'bootstrap' => '0', 'schema_version' => '7001', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:14:"Update manager";s:11:"description";s:104:"Checks for available updates, and can securely install or update modules and themes via a web interface.";s:7:"version";s:4:"7.37";s:7:"package";s:4:"Core";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"update.test";}s:9:"configure";s:30:"admin/reports/updates/settings";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:14:"Update manager";s:11:"description";s:104:"Checks for available updates, and can securely install or update modules and themes via a web interface.";s:7:"version";s:4:"7.40";s:7:"package";s:4:"Core";s:4:"core";s:3:"7.x";s:5:"files";a:1:{i:0;s:11:"update.test";}s:9:"configure";s:30:"admin/reports/updates/settings";s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/user/tests/user_form_test.module', @@ -38875,7 +39619,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:22:"User module form tests";s:11:"description";s:37:"Support module for user form testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:22:"User module form tests";s:11:"description";s:37:"Support module for user form testing.";s:7:"package";s:7:"Testing";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:6:"hidden";b:1;s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'modules/user/user.module', @@ -38886,7 +39630,7 @@ 'bootstrap' => '0', 'schema_version' => '7018', 'weight' => '0', - 'info' => 'a:15:{s:4:"name";s:4:"User";s:11:"description";s:47:"Manages the user registration and login system.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:11:"user.module";i:1;s:9:"user.test";}s:8:"required";b:1;s:9:"configure";s:19:"admin/config/people";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"user.css";s:21:"modules/user/user.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:15:{s:4:"name";s:4:"User";s:11:"description";s:47:"Manages the user registration and login system.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:5:"files";a:2:{i:0;s:11:"user.module";i:1;s:9:"user.test";}s:8:"required";b:1;s:9:"configure";s:19:"admin/config/people";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"user.css";s:21:"modules/user/user.css";}}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'profiles/standard/standard.profile', @@ -38897,7 +39641,7 @@ 'bootstrap' => '0', 'schema_version' => '0', 'weight' => '1000', - 'info' => 'a:15:{s:4:"name";s:8:"Standard";s:11:"description";s:51:"Install with commonly used features pre-configured.";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:12:"dependencies";a:21:{i:0;s:5:"block";i:1;s:5:"color";i:2;s:7:"comment";i:3;s:10:"contextual";i:4;s:9:"dashboard";i:5;s:4:"help";i:6;s:5:"image";i:7;s:4:"list";i:8;s:4:"menu";i:9;s:6:"number";i:10;s:7:"options";i:11;s:4:"path";i:12;s:8:"taxonomy";i:13;s:5:"dblog";i:14;s:6:"search";i:15;s:8:"shortcut";i:16;s:7:"toolbar";i:17;s:7:"overlay";i:18;s:8:"field_ui";i:19;s:4:"file";i:20;s:3:"rdf";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:5:"mtime";i:1437399663;s:7:"package";s:5:"Other";s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;s:6:"hidden";b:1;s:8:"required";b:1;s:17:"distribution_name";s:6:"Drupal";}', + 'info' => 'a:15:{s:4:"name";s:8:"Standard";s:11:"description";s:51:"Install with commonly used features pre-configured.";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:12:"dependencies";a:21:{i:0;s:5:"block";i:1;s:5:"color";i:2;s:7:"comment";i:3;s:10:"contextual";i:4;s:9:"dashboard";i:5;s:4:"help";i:6;s:5:"image";i:7;s:4:"list";i:8;s:4:"menu";i:9;s:6:"number";i:10;s:7:"options";i:11;s:4:"path";i:12;s:8:"taxonomy";i:13;s:5:"dblog";i:14;s:6:"search";i:15;s:8:"shortcut";i:16;s:7:"toolbar";i:17;s:7:"overlay";i:18;s:8:"field_ui";i:19;s:4:"file";i:20;s:3:"rdf";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:5:"mtime";i:1444866674;s:7:"package";s:5:"Other";s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;s:6:"hidden";b:1;s:8:"required";b:1;s:17:"distribution_name";s:6:"Drupal";}', )) ->values(array( 'filename' => 'sites/all/modules/ctools/ctools.module', @@ -38919,7 +39663,7 @@ 'bootstrap' => '0', 'schema_version' => '7004', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"Date";s:11:"description";s:33:"Makes date/time fields available.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:7:{i:0;s:16:"date.migrate.inc";i:1;s:19:"tests/date_api.test";i:2;s:15:"tests/date.test";i:3;s:21:"tests/date_field.test";i:4;s:23:"tests/date_migrate.test";i:5;s:26:"tests/date_validation.test";i:6;s:24:"tests/date_timezone.test";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:4:"Date";s:11:"description";s:33:"Makes date/time fields available.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:9:{i:0;s:16:"date.migrate.inc";i:1;s:19:"tests/date_api.test";i:2;s:15:"tests/date.test";i:3;s:21:"tests/date_field.test";i:4;s:23:"tests/date_migrate.test";i:5;s:26:"tests/date_validation.test";i:6;s:24:"tests/date_timezone.test";i:7;s:27:"tests/date_views_pager.test";i:8;s:27:"tests/date_views_popup.test";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_all_day/date_all_day.module', @@ -38930,7 +39674,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => "a:12:{s:4:\"name\";s:12:\"Date All Day\";s:11:\"description\";s:142:\"Adds 'All Day' functionality to date fields, including an 'All Day' theme and 'All Day' checkboxes for the Date select and Date popup widgets.\";s:12:\"dependencies\";a:2:{i:0;s:8:\"date_api\";i:1;s:4:\"date\";}s:7:\"package\";s:9:\"Date/Time\";s:4:\"core\";s:3:\"7.x\";s:7:\"version\";s:7:\"7.x-2.8\";s:7:\"project\";s:4:\"date\";s:9:\"datestamp\";s:10:\"1406653438\";s:5:\"mtime\";i:1406653438;s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", + 'info' => "a:12:{s:4:\"name\";s:12:\"Date All Day\";s:11:\"description\";s:142:\"Adds 'All Day' functionality to date fields, including an 'All Day' theme and 'All Day' checkboxes for the Date select and Date popup widgets.\";s:12:\"dependencies\";a:2:{i:0;s:8:\"date_api\";i:1;s:4:\"date\";}s:7:\"package\";s:9:\"Date/Time\";s:4:\"core\";s:3:\"7.x\";s:7:\"version\";s:7:\"7.x-2.9\";s:7:\"project\";s:4:\"date\";s:9:\"datestamp\";s:10:\"1441727353\";s:5:\"mtime\";i:1441727353;s:3:\"php\";s:5:\"5.2.4\";s:5:\"files\";a:0:{}s:9:\"bootstrap\";i:0;}", )) ->values(array( 'filename' => 'sites/all/modules/date/date_api/date_api.module', @@ -38941,7 +39685,7 @@ 'bootstrap' => '0', 'schema_version' => '7001', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:8:"Date API";s:11:"description";s:45:"A Date API that can be used by other modules.";s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"date.css";s:40:"sites/all/modules/date/date_api/date.css";}}s:5:"files";a:2:{i:0;s:15:"date_api.module";i:1;s:16:"date_api_sql.inc";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:12:"dependencies";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:8:"Date API";s:11:"description";s:45:"A Date API that can be used by other modules.";s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:8:"date.css";s:40:"sites/all/modules/date/date_api/date.css";}}s:5:"files";a:2:{i:0;s:15:"date_api.module";i:1;s:16:"date_api_sql.inc";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:12:"dependencies";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_context/date_context.module', @@ -38952,7 +39696,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:12:"Date Context";s:11:"description";s:99:"Adds an option to the Context module to set a context condition based on the value of a date field.";s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:12:"dependencies";a:2:{i:0;s:4:"date";i:1;s:7:"context";}s:5:"files";a:2:{i:0;s:19:"date_context.module";i:1;s:39:"plugins/date_context_date_condition.inc";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:12:"Date Context";s:11:"description";s:99:"Adds an option to the Context module to set a context condition based on the value of a date field.";s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:12:"dependencies";a:2:{i:0;s:4:"date";i:1;s:7:"context";}s:5:"files";a:2:{i:0;s:19:"date_context.module";i:1;s:39:"plugins/date_context_date_condition.inc";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_migrate/date_migrate.module', @@ -38963,7 +39707,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:14:"Date Migration";s:11:"description";s:73:"Obsolete data migration module. Disable if no other modules depend on it.";s:4:"core";s:3:"7.x";s:7:"package";s:9:"Date/Time";s:6:"hidden";b:1;s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:14:"Date Migration";s:11:"description";s:73:"Obsolete data migration module. Disable if no other modules depend on it.";s:4:"core";s:3:"7.x";s:7:"package";s:9:"Date/Time";s:6:"hidden";b:1;s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_migrate/date_migrate_example/date_migrate_example.module', @@ -38974,7 +39718,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"core";s:3:"7.x";s:12:"dependencies";a:5:{i:0;s:4:"date";i:1;s:11:"date_repeat";i:2;s:17:"date_repeat_field";i:3;s:8:"features";i:4;s:7:"migrate";}s:11:"description";s:42:"Examples of migrating with the Date module";s:8:"features";a:2:{s:5:"field";a:8:{i:0;s:30:"node-date_migrate_example-body";i:1;s:36:"node-date_migrate_example-field_date";i:2;s:42:"node-date_migrate_example-field_date_range";i:3;s:43:"node-date_migrate_example-field_date_repeat";i:4;s:41:"node-date_migrate_example-field_datestamp";i:5;s:47:"node-date_migrate_example-field_datestamp_range";i:6;s:40:"node-date_migrate_example-field_datetime";i:7;s:46:"node-date_migrate_example-field_datetime_range";}s:4:"node";a:1:{i:0;s:20:"date_migrate_example";}}s:5:"files";a:1:{i:0;s:32:"date_migrate_example.migrate.inc";}s:4:"name";s:22:"Date Migration Example";s:7:"package";s:8:"Features";s:7:"project";s:4:"date";s:7:"version";s:7:"7.x-2.8";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"core";s:3:"7.x";s:12:"dependencies";a:5:{i:0;s:4:"date";i:1;s:11:"date_repeat";i:2;s:17:"date_repeat_field";i:3;s:8:"features";i:4;s:7:"migrate";}s:11:"description";s:42:"Examples of migrating with the Date module";s:8:"features";a:2:{s:5:"field";a:8:{i:0;s:30:"node-date_migrate_example-body";i:1;s:36:"node-date_migrate_example-field_date";i:2;s:42:"node-date_migrate_example-field_date_range";i:3;s:43:"node-date_migrate_example-field_date_repeat";i:4;s:41:"node-date_migrate_example-field_datestamp";i:5;s:47:"node-date_migrate_example-field_datestamp_range";i:6;s:40:"node-date_migrate_example-field_datetime";i:7;s:46:"node-date_migrate_example-field_datetime_range";}s:4:"node";a:1:{i:0;s:20:"date_migrate_example";}}s:5:"files";a:1:{i:0;s:32:"date_migrate_example.migrate.inc";}s:4:"name";s:22:"Date Migration Example";s:7:"package";s:8:"Features";s:7:"project";s:4:"date";s:7:"version";s:7:"7.x-2.9";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_popup/date_popup.module', @@ -38985,7 +39729,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:10:"Date Popup";s:11:"description";s:84:"Enables jquery popup calendars and time entry widgets for selecting dates and times.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:9:"configure";s:28:"admin/config/date/date_popup";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:25:"themes/datepicker.1.7.css";s:59:"sites/all/modules/date/date_popup/themes/datepicker.1.7.css";}}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:14:{s:4:"name";s:10:"Date Popup";s:11:"description";s:84:"Enables jquery popup calendars and time entry widgets for selecting dates and times.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:9:"configure";s:28:"admin/config/date/date_popup";s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:25:"themes/datepicker.1.7.css";s:59:"sites/all/modules/date/date_popup/themes/datepicker.1.7.css";}}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_repeat/date_repeat.module', @@ -38996,7 +39740,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:15:"Date Repeat API";s:11:"description";s:73:"A Date Repeat API to calculate repeating dates and times from iCal rules.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:2:{i:0;s:22:"tests/date_repeat.test";i:1;s:27:"tests/date_repeat_form.test";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:15:"Date Repeat API";s:11:"description";s:73:"A Date Repeat API to calculate repeating dates and times from iCal rules.";s:12:"dependencies";a:1:{i:0;s:8:"date_api";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:2:{i:0;s:22:"tests/date_repeat.test";i:1;s:27:"tests/date_repeat_form.test";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_repeat_field/date_repeat_field.module', @@ -39007,7 +39751,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:17:"Date Repeat Field";s:11:"description";s:97:"Creates the option of Repeating date fields and manages Date fields that use the Date Repeat API.";s:12:"dependencies";a:3:{i:0;s:8:"date_api";i:1;s:4:"date";i:2;s:11:"date_repeat";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:21:"date_repeat_field.css";s:62:"sites/all/modules/date/date_repeat_field/date_repeat_field.css";}}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:17:"Date Repeat Field";s:11:"description";s:97:"Creates the option of Repeating date fields and manages Date fields that use the Date Repeat API.";s:12:"dependencies";a:3:{i:0;s:8:"date_api";i:1;s:4:"date";i:2;s:11:"date_repeat";}s:11:"stylesheets";a:1:{s:3:"all";a:1:{s:21:"date_repeat_field.css";s:62:"sites/all/modules/date/date_repeat_field/date_repeat_field.css";}}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:3:"php";s:5:"5.2.4";s:5:"files";a:0:{}s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_tools/date_tools.module', @@ -39018,7 +39762,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:13:{s:4:"name";s:10:"Date Tools";s:11:"description";s:52:"Tools to import and auto-create dates and calendars.";s:12:"dependencies";a:1:{i:0;s:4:"date";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:9:"configure";s:23:"admin/config/date/tools";s:5:"files";a:1:{i:0;s:21:"tests/date_tools.test";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', + 'info' => 'a:13:{s:4:"name";s:10:"Date Tools";s:11:"description";s:52:"Tools to import and auto-create dates and calendars.";s:12:"dependencies";a:1:{i:0;s:4:"date";}s:7:"package";s:9:"Date/Time";s:4:"core";s:3:"7.x";s:9:"configure";s:23:"admin/config/date/tools";s:5:"files";a:1:{i:0;s:21:"tests/date_tools.test";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/date/date_views/date_views.module', @@ -39029,7 +39773,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:12:{s:4:"name";s:10:"Date Views";s:11:"description";s:57:"Views integration for date fields and date functionality.";s:7:"package";s:9:"Date/Time";s:12:"dependencies";a:2:{i:0;s:8:"date_api";i:1;s:5:"views";}s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:6:{i:0;s:40:"includes/date_views_argument_handler.inc";i:1;s:47:"includes/date_views_argument_handler_simple.inc";i:2;s:38:"includes/date_views_filter_handler.inc";i:3;s:45:"includes/date_views_filter_handler_simple.inc";i:4;s:29:"includes/date_views.views.inc";i:5;s:36:"includes/date_views_plugin_pager.inc";}s:7:"version";s:7:"7.x-2.8";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1406653438";s:5:"mtime";i:1406653438;s:9:"bootstrap";i:0;}', + 'info' => 'a:12:{s:4:"name";s:10:"Date Views";s:11:"description";s:57:"Views integration for date fields and date functionality.";s:7:"package";s:9:"Date/Time";s:12:"dependencies";a:2:{i:0;s:8:"date_api";i:1;s:5:"views";}s:4:"core";s:3:"7.x";s:3:"php";s:3:"5.2";s:5:"files";a:6:{i:0;s:40:"includes/date_views_argument_handler.inc";i:1;s:47:"includes/date_views_argument_handler_simple.inc";i:2;s:38:"includes/date_views_filter_handler.inc";i:3;s:45:"includes/date_views_filter_handler_simple.inc";i:4;s:29:"includes/date_views.views.inc";i:5;s:36:"includes/date_views_plugin_pager.inc";}s:7:"version";s:7:"7.x-2.9";s:7:"project";s:4:"date";s:9:"datestamp";s:10:"1441727353";s:5:"mtime";i:1441727353;s:9:"bootstrap";i:0;}', )) ->values(array( 'filename' => 'sites/all/modules/email/email.module', @@ -39051,7 +39795,7 @@ 'bootstrap' => '0', 'schema_version' => '7001', 'weight' => '0', - 'info' => 'a:14:{s:4:"name";s:4:"Link";s:11:"description";s:32:"Defines simple link field types.";s:4:"core";s:3:"7.x";s:7:"package";s:6:"Fields";s:5:"files";a:10:{i:0;s:11:"link.module";i:1;s:16:"link.migrate.inc";i:2;s:15:"tests/link.test";i:3;s:25:"tests/link.attribute.test";i:4;s:20:"tests/link.crud.test";i:5;s:28:"tests/link.crud_browser.test";i:6;s:21:"tests/link.token.test";i:7;s:24:"tests/link.validate.test";i:8;s:44:"views/link_views_handler_argument_target.inc";i:9;s:44:"views/link_views_handler_filter_protocol.inc";}s:7:"version";s:7:"7.x-1.3";s:7:"project";s:4:"link";s:9:"datestamp";s:10:"1413924830";s:5:"mtime";i:1437399663;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', + 'info' => 'a:14:{s:4:"name";s:4:"Link";s:11:"description";s:32:"Defines simple link field types.";s:4:"core";s:3:"7.x";s:7:"package";s:6:"Fields";s:5:"files";a:10:{i:0;s:11:"link.module";i:1;s:16:"link.migrate.inc";i:2;s:15:"tests/link.test";i:3;s:25:"tests/link.attribute.test";i:4;s:20:"tests/link.crud.test";i:5;s:28:"tests/link.crud_browser.test";i:6;s:21:"tests/link.token.test";i:7;s:24:"tests/link.validate.test";i:8;s:44:"views/link_views_handler_argument_target.inc";i:9;s:44:"views/link_views_handler_filter_protocol.inc";}s:7:"version";s:7:"7.x-1.3";s:7:"project";s:4:"link";s:9:"datestamp";s:10:"1413924830";s:5:"mtime";i:1413924830;s:12:"dependencies";a:0:{}s:3:"php";s:5:"5.2.4";s:9:"bootstrap";i:0;s:8:"required";b:1;s:11:"explanation";s:73:"Field type(s) in use - see Field list";}', )) ->values(array( 'filename' => 'sites/all/modules/phone/phone.module', @@ -39095,7 +39839,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1437399663;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', + 'info' => 'a:18:{s:4:"name";s:6:"Bartik";s:11:"description";s:48:"A flexible, recolorable theme with many regions.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:3:{s:14:"css/layout.css";s:28:"themes/bartik/css/layout.css";s:13:"css/style.css";s:27:"themes/bartik/css/style.css";s:14:"css/colors.css";s:28:"themes/bartik/css/colors.css";}s:5:"print";a:1:{s:13:"css/print.css";s:27:"themes/bartik/css/print.css";}}s:7:"regions";a:17:{s:6:"header";s:6:"Header";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:11:"highlighted";s:11:"Highlighted";s:8:"featured";s:8:"Featured";s:7:"content";s:7:"Content";s:13:"sidebar_first";s:13:"Sidebar first";s:14:"sidebar_second";s:14:"Sidebar second";s:14:"triptych_first";s:14:"Triptych first";s:15:"triptych_middle";s:15:"Triptych middle";s:13:"triptych_last";s:13:"Triptych last";s:18:"footer_firstcolumn";s:19:"Footer first column";s:19:"footer_secondcolumn";s:20:"Footer second column";s:18:"footer_thirdcolumn";s:19:"Footer third column";s:19:"footer_fourthcolumn";s:20:"Footer fourth column";s:6:"footer";s:6:"Footer";}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"0";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:28:"themes/bartik/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', )) ->values(array( 'filename' => 'themes/garland/garland.info', @@ -39106,7 +39850,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1437399663;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', + 'info' => 'a:18:{s:4:"name";s:7:"Garland";s:11:"description";s:111:"A multi-column theme which can be configured to modify colors and switch between fixed and fluid width layouts.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:2:{s:3:"all";a:1:{s:9:"style.css";s:24:"themes/garland/style.css";}s:5:"print";a:1:{s:9:"print.css";s:24:"themes/garland/print.css";}}s:8:"settings";a:1:{s:13:"garland_width";s:5:"fluid";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:7:"regions";a:9:{s:13:"sidebar_first";s:12:"Left sidebar";s:14:"sidebar_second";s:13:"Right sidebar";s:7:"content";s:7:"Content";s:6:"header";s:6:"Header";s:6:"footer";s:6:"Footer";s:11:"highlighted";s:11:"Highlighted";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";}s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:29:"themes/garland/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:14:"regions_hidden";a:2:{i:0;s:8:"page_top";i:1;s:11:"page_bottom";}s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', )) ->values(array( 'filename' => 'themes/seven/seven.info', @@ -39117,7 +39861,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => 'a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.37";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1430973154";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1437399663;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', + 'info' => 'a:18:{s:4:"name";s:5:"Seven";s:11:"description";s:65:"A simple one-column, tableless, fluid width administration theme.";s:7:"package";s:4:"Core";s:7:"version";s:4:"7.40";s:4:"core";s:3:"7.x";s:11:"stylesheets";a:1:{s:6:"screen";a:2:{s:9:"reset.css";s:22:"themes/seven/reset.css";s:9:"style.css";s:22:"themes/seven/style.css";}}s:8:"settings";a:1:{s:20:"shortcut_module_link";s:1:"1";}s:7:"regions";a:5:{s:7:"content";s:7:"Content";s:4:"help";s:4:"Help";s:8:"page_top";s:8:"Page top";s:11:"page_bottom";s:11:"Page bottom";s:13:"sidebar_first";s:13:"First sidebar";}s:14:"regions_hidden";a:3:{i:0;s:13:"sidebar_first";i:1;s:8:"page_top";i:2;s:11:"page_bottom";}s:7:"project";s:6:"drupal";s:9:"datestamp";s:10:"1444866674";s:6:"engine";s:11:"phptemplate";s:8:"features";a:9:{i:0;s:4:"logo";i:1;s:7:"favicon";i:2;s:4:"name";i:3;s:6:"slogan";i:4;s:17:"node_user_picture";i:5;s:20:"comment_user_picture";i:6;s:25:"comment_user_verification";i:7;s:9:"main_menu";i:8;s:14:"secondary_menu";}s:10:"screenshot";s:27:"themes/seven/screenshot.png";s:3:"php";s:5:"5.2.4";s:7:"scripts";a:0:{}s:5:"mtime";i:1444866674;s:28:"overlay_supplemental_regions";a:1:{i:0;s:8:"page_top";}}', )) ->values(array( 'filename' => 'themes/stark/stark.info', @@ -39128,7 +39872,7 @@ 'bootstrap' => '0', 'schema_version' => '-1', 'weight' => '0', - 'info' => "a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.37\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1430973154\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1437399663;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}", + 'info' => "a:17:{s:4:\"name\";s:5:\"Stark\";s:11:\"description\";s:208:\"This theme demonstrates Drupal's default HTML markup and CSS styles. To learn how to build your own theme and override Drupal's default code, see the Theming Guide.\";s:7:\"package\";s:4:\"Core\";s:7:\"version\";s:4:\"7.40\";s:4:\"core\";s:3:\"7.x\";s:11:\"stylesheets\";a:1:{s:3:\"all\";a:1:{s:10:\"layout.css\";s:23:\"themes/stark/layout.css\";}}s:7:\"project\";s:6:\"drupal\";s:9:\"datestamp\";s:10:\"1444866674\";s:6:\"engine\";s:11:\"phptemplate\";s:7:\"regions\";a:9:{s:13:\"sidebar_first\";s:12:\"Left sidebar\";s:14:\"sidebar_second\";s:13:\"Right sidebar\";s:7:\"content\";s:7:\"Content\";s:6:\"header\";s:6:\"Header\";s:6:\"footer\";s:6:\"Footer\";s:11:\"highlighted\";s:11:\"Highlighted\";s:4:\"help\";s:4:\"Help\";s:8:\"page_top\";s:8:\"Page top\";s:11:\"page_bottom\";s:11:\"Page bottom\";}s:8:\"features\";a:9:{i:0;s:4:\"logo\";i:1;s:7:\"favicon\";i:2;s:4:\"name\";i:3;s:6:\"slogan\";i:4;s:17:\"node_user_picture\";i:5;s:20:\"comment_user_picture\";i:6;s:25:\"comment_user_verification\";i:7;s:9:\"main_menu\";i:8;s:14:\"secondary_menu\";}s:10:\"screenshot\";s:27:\"themes/stark/screenshot.png\";s:3:\"php\";s:5:\"5.2.4\";s:7:\"scripts\";a:0:{}s:5:\"mtime\";i:1444866674;s:14:\"regions_hidden\";a:2:{i:0;s:8:\"page_top\";i:1;s:11:\"page_bottom\";}s:28:\"overlay_supplemental_regions\";a:1:{i:0;s:8:\"page_top\";}}", )) ->execute(); @@ -39895,15 +40639,15 @@ )) ->values(array( 'uid' => '1', - 'name' => 'root', + 'name' => 'admin', 'pass' => '$S$D/HVkgCg1Hvi7DN5KVSgNl.2C5g8W6oe/OoIRMUlyjkmPugQRhoB', - 'mail' => '', + 'mail' => 'admin@local.host', 'theme' => '', 'signature' => '', 'signature_format' => NULL, 'created' => '0', - 'access' => '0', - 'login' => '0', + 'access' => '1444945097', + 'login' => '1444945097', 'status' => '1', 'timezone' => NULL, 'language' => '', @@ -39997,7 +40741,7 @@ )) ->values(array( 'name' => 'additional_settings__active_tab_blog', - 'value' => 's:15:"edit-submission";', + 'value' => 's:13:"edit-workflow";', )) ->values(array( 'name' => 'additional_settings__active_tab_book', @@ -40067,6 +40811,42 @@ 'name' => 'book_child_type', 'value' => 's:4:"book";', )) +->values(array( + 'name' => 'cache_flush_cache', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_block', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'cache_flush_cache_field', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_filter', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_form', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_image', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_menu', + 'value' => 'i:1444944970;', +)) +->values(array( + 'name' => 'cache_flush_cache_page', + 'value' => 'i:0;', +)) +->values(array( + 'name' => 'cache_flush_cache_path', + 'value' => 'i:1444944970;', +)) ->values(array( 'name' => 'cache_lifetime', 'value' => 's:3:"300";', @@ -40261,11 +41041,11 @@ )) ->values(array( 'name' => 'cron_last', - 'value' => 'i:1441286523;', + 'value' => 'i:1444944970;', )) ->values(array( 'name' => 'css_js_query_string', - 'value' => 's:6:"nu3rtz";', + 'value' => 's:6:"nwa6nq";', )) ->values(array( 'name' => 'ctools_last_cron', @@ -40287,6 +41067,10 @@ 'name' => 'default_nodes_main', 'value' => 's:2:"10";', )) +->values(array( + 'name' => 'drupal_css_cache_files', + 'value' => 'a:10:{s:64:"823ba1006db72809515d2221cd02ec1075d7b49b0c07f49307b3a7930bfdd9e4";s:64:"public://css/css_xE-rWrJf-fncB6ztZfd2huxqgxu4WO-qwma6Xer30m4.css";s:64:"039ba69b25efd672767c5ee21b686a2cdaa496c5fb210693b88f81cc556db518";s:64:"public://css/css_M8BpLSgFJ1ipHW-ZwVd6p7yRHsT3q23ohYErZrFJ1xA.css";s:64:"568f3bca87830de88c7b44e71808ac7f33f4cdf273ed3bf3d2532bd48f084b06";s:64:"public://css/css_NRg0AX3iY_x0OX3_WzcWp90JnwurHRvZn6i75GL0rRI.css";s:64:"586e4d641f74d0fbdea2ecffe62294e983c5961df8d0128aab1c561505f6b35a";s:64:"public://css/css_2THG1eGiBIizsWFeexsNe1iDifJ00QRS9uSd03rY9co.css";s:64:"cb9f93e666a396bb3eb14c5fd16f7ebd1cdd0067733eb0a2ab1b294b6f14f76f";s:64:"public://css/css_1kF33EODTO5gDyEbdpAfYzMKbjG3ottD1s5np0BNI8U.css";s:64:"35337ea541d4968f58917d83eaa9e495d5a38bb0aaf23bc714650d3c71fc275a";s:64:"public://css/css_LJ87GFKz9ZFt2bWZ4pMV8e2o8w_790Mbwcd7C-RKri0.css";s:64:"592db66916e1dd3416cbe95bcb34a5a68775eb0b7cf95e4c858671de35290cc9";s:64:"public://css/css_LS9OUalDR9-d_lCAvF3yUWjNU6yF8ZBm84jEPRvoyuQ.css";s:64:"fe9fca5a618e55058e69458a65b2edb4e958c16c13e1d1526c4dc0c0e782b483";s:64:"public://css/css_WWafHiT44xXp69Ucog34hgXKsZRScJzl3S17Xg7evtM.css";s:64:"ebb3f433ad4107b1ac31e9d7de0f9a5d399040e9f82b6364211dcfaadea158c0";s:64:"public://css/css_Nv0ct-zkzztuah_LbaPFF8ZkdSEk-LxBtTWMm9mN_F8.css";s:64:"032d72e2b3124645b11e59c23005327dc2b450af6aaa6bf3cad34a6a65a9d774";s:64:"public://css/css_ZDWl28hdmeinIcKg-HMrN6uKD0nTMld5NlXLmm5MH2U.css";}', +)) ->values(array( 'name' => 'drupal_http_request_fails', 'value' => 'b:0;', @@ -40375,13 +41159,17 @@ 'name' => 'install_time', 'value' => 'i:1421694923;', )) +->values(array( + 'name' => 'javascript_parsed', + 'value' => 'a:17:{i:0;s:14:"misc/drupal.js";i:1;s:14:"misc/jquery.js";i:2;s:19:"misc/jquery.once.js";i:3;s:32:"modules/contextual/contextual.js";i:4;s:21:"misc/jquery.cookie.js";i:5;s:26:"modules/toolbar/toolbar.js";i:6;s:19:"misc/tableheader.js";i:7;s:12:"misc/form.js";i:8;s:16:"misc/collapse.js";i:9;s:17:"misc/tabledrag.js";s:10:"refresh:is";s:7:"waiting";i:10;s:20:"misc/machine-name.js";i:11;s:16:"misc/textarea.js";i:12;s:36:"modules/comment/comment-node-form.js";i:13;s:26:"modules/menu/menu.admin.js";i:14;s:21:"misc/vertical-tabs.js";i:15;s:29:"modules/node/content_types.js";}', +)) ->values(array( 'name' => 'language_content_type_article', 'value' => 's:1:"0";', )) ->values(array( 'name' => 'language_content_type_blog', - 'value' => 's:1:"0";', + 'value' => 's:1:"2";', )) ->values(array( 'name' => 'language_content_type_book', @@ -40399,6 +41187,14 @@ 'name' => 'language_content_type_test_content_type', 'value' => 's:1:"0";', )) +->values(array( + 'name' => 'language_count', + 'value' => 'i:2;', +)) +->values(array( + 'name' => 'language_default', + 'value' => 'O:8:"stdClass":11:{s:8:"language";s:2:"en";s:4:"name";s:7:"English";s:6:"native";s:7:"English";s:9:"direction";s:1:"0";s:7:"enabled";i:1;s:7:"plurals";s:1:"0";s:7:"formula";s:0:"";s:6:"domain";s:0:"";s:6:"prefix";s:0:"";s:6:"weight";s:1:"0";s:10:"javascript";s:0:"";}', +)) ->values(array( 'name' => 'language_negotiation_language', 'value' => 'a:0:{}', @@ -40501,7 +41297,7 @@ )) ->values(array( 'name' => 'node_cron_last', - 'value' => 's:10:"1421727515";', + 'value' => 's:10:"1441306832";', )) ->values(array( 'name' => 'node_options_article', @@ -40699,6 +41495,10 @@ 'name' => 'statistics_count_content_views_ajax', 'value' => 'i:0;', )) +->values(array( + 'name' => 'statistics_day_timestamp', + 'value' => 'i:1444944970;', +)) ->values(array( 'name' => 'statistics_enable_access_log', 'value' => 'i:1;', @@ -40735,6 +41535,10 @@ 'name' => 'tracker_batch_size', 'value' => 'i:999;', )) +->values(array( + 'name' => 'update_last_check', + 'value' => 'i:1444944973;', +)) ->values(array( 'name' => 'user_admin_role', 'value' => 's:1:"3";', diff --git a/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migrate_overwrite_test.info.yml b/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migrate_overwrite_test.info.yml new file mode 100644 index 000000000..503c6cec7 --- /dev/null +++ b/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migrate_overwrite_test.info.yml @@ -0,0 +1,6 @@ +name: 'Migrate property overwrite test' +type: module +description: 'Example module demonstrating property overwrite support in the Migrate API.' +package: Testing +version: VERSION +core: 8.x diff --git a/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migration_templates/users.yml b/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migration_templates/users.yml new file mode 100644 index 000000000..e23d90d9d --- /dev/null +++ b/core/modules/migrate_drupal/tests/modules/migrate_overwrite_test/migration_templates/users.yml @@ -0,0 +1,31 @@ +id: users +label: User migration +migration_tags: + - Drupal 6 + - Drupal 7 +source: + plugin: d6_user +process: + # If the entity's ID is migrated, the Migrate API will try to update + # an existing entity with that ID. If no entity with that ID already + # exists, it will be created. + uid: uid + name: name + mail: mail + password: password + 'signature/value': + plugin: default_value + default_value: 'The answer is 42.' +destination: + plugin: entity:user + # If the destination is going to update an existing user, you can optionally + # specify the properties that should be overwritten. For example, if the + # migration tries to import user 31 and user 31 already exists in the + # destination database, only the 'name' and 'mail' properties of the user + # will be overwritten. If user 31 doesn't exist, it will be created and + # the overwrite_properties list will be ignored. + overwrite_properties: + - name + - mail + # It's possible to overwrite nested properties too. + - 'signature/value' diff --git a/core/modules/node/content_types.js b/core/modules/node/content_types.js index 912bdc991..96733a214 100644 --- a/core/modules/node/content_types.js +++ b/core/modules/node/content_types.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Behaviors for setting summaries on content type form. @@ -26,7 +26,7 @@ }); $context.find('#edit-workflow').drupalSetSummary(function (context) { var vals = []; - $(context).find("input[name^='options']:checked").parent().each(function () { + $(context).find('input[name^="options"]:checked').parent().each(function () { vals.push(Drupal.checkPlain($(this).text())); }); if (!$(context).find('#edit-options-status').is(':checked')) { @@ -37,7 +37,7 @@ $('#edit-language', context).drupalSetSummary(function (context) { var vals = []; - vals.push($(".js-form-item-language-configuration-langcode select option:selected", context).text()); + vals.push($('.js-form-item-language-configuration-langcode select option:selected', context).text()); $('input:checked', context).next('label').each(function () { vals.push(Drupal.checkPlain($(this).text())); diff --git a/core/modules/node/migration_templates/d6_node_revision.yml b/core/modules/node/migration_templates/d6_node_revision.yml index c22e62a85..e7f3b544b 100644 --- a/core/modules/node/migration_templates/d6_node_revision.yml +++ b/core/modules/node/migration_templates/d6_node_revision.yml @@ -39,6 +39,3 @@ process: destination: plugin: entity_revision:node -migration_dependencies: - required: - - d6_node:* diff --git a/core/modules/node/node.admin.inc b/core/modules/node/node.admin.inc index 280fd81c8..55665662b 100644 --- a/core/modules/node/node.admin.inc +++ b/core/modules/node/node.admin.inc @@ -5,7 +5,6 @@ * Content administration and module settings user interface. */ -use Drupal\Core\Language\Language; use Drupal\node\NodeInterface; use Drupal\node\Entity\Node; diff --git a/core/modules/node/node.js b/core/modules/node/node.js index c1244c8eb..1f6752818 100644 --- a/core/modules/node/node.js +++ b/core/modules/node/node.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Behaviors for tabs in the node edit form. diff --git a/core/modules/node/node.module b/core/modules/node/node.module index 0eaab5d95..8a2498b9a 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -8,7 +8,6 @@ * API pattern. */ -use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Xss; use Drupal\Core\Access\AccessResult; use Drupal\Core\Cache\Cache; @@ -317,7 +316,8 @@ function node_type_load($name) { * @param string $label * (optional) The label for the body instance. * - * @return \Drupal\field\Entity\FieldConfig Body field. + * @return \Drupal\field\Entity\FieldConfig + * A Body field object. */ function node_add_body_field(NodeTypeInterface $type, $label = 'Body') { // Add or remove the body field, as needed. diff --git a/core/modules/node/node.preview.js b/core/modules/node/node.preview.js index ec4883279..4054183a1 100644 --- a/core/modules/node/node.preview.js +++ b/core/modules/node/node.preview.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Disables all non-relevant links in node previews. diff --git a/core/modules/node/node.views.inc b/core/modules/node/node.views.inc index 511d72ef2..e353fc07d 100644 --- a/core/modules/node/node.views.inc +++ b/core/modules/node/node.views.inc @@ -5,9 +5,6 @@ * Provide views data for node.module. */ -use Drupal\views\Analyzer; -use Drupal\views\ViewExecutable; - /** * Implements hook_views_wizard(). */ diff --git a/core/modules/node/src/Access/NodeRevisionAccessCheck.php b/core/modules/node/src/Access/NodeRevisionAccessCheck.php index 82c495474..aa654a2bb 100644 --- a/core/modules/node/src/Access/NodeRevisionAccessCheck.php +++ b/core/modules/node/src/Access/NodeRevisionAccessCheck.php @@ -47,8 +47,6 @@ class NodeRevisionAccessCheck implements AccessInterface { * * @param \Drupal\Core\Entity\EntityManagerInterface $entity_manager * The entity manager. - * @param \Drupal\Core\Database\Connection $connection - * The database connection. */ public function __construct(EntityManagerInterface $entity_manager) { $this->nodeStorage = $entity_manager->getStorage('node'); diff --git a/core/modules/node/src/ConfigTranslation/NodeTypeMapper.php b/core/modules/node/src/ConfigTranslation/NodeTypeMapper.php index be0cdb866..d11364a03 100644 --- a/core/modules/node/src/ConfigTranslation/NodeTypeMapper.php +++ b/core/modules/node/src/ConfigTranslation/NodeTypeMapper.php @@ -23,7 +23,10 @@ public function setEntity(ConfigEntityInterface $entity) { // Adds the title label to the translation form. $node_type = $entity->id(); - $this->addConfigName("core.base_field_override.node.$node_type.title"); + $config = $this->configFactory->get("core.base_field_override.node.$node_type.title"); + if (!$config->isNew()) { + $this->addConfigName($config->getName()); + } } } diff --git a/core/modules/node/src/Controller/NodeViewController.php b/core/modules/node/src/Controller/NodeViewController.php index fc43770f7..ee84e6bba 100644 --- a/core/modules/node/src/Controller/NodeViewController.php +++ b/core/modules/node/src/Controller/NodeViewController.php @@ -7,7 +7,6 @@ namespace Drupal\node\Controller; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\Controller\EntityViewController; diff --git a/core/modules/node/src/Entity/Node.php b/core/modules/node/src/Entity/Node.php index 861a0d1c7..118e86252 100644 --- a/core/modules/node/src/Entity/Node.php +++ b/core/modules/node/src/Entity/Node.php @@ -12,7 +12,6 @@ use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Session\AccountInterface; use Drupal\node\NodeInterface; use Drupal\user\UserInterface; diff --git a/core/modules/node/src/Form/NodeRevisionDeleteForm.php b/core/modules/node/src/Form/NodeRevisionDeleteForm.php index 352cef0bf..6780e2472 100644 --- a/core/modules/node/src/Form/NodeRevisionDeleteForm.php +++ b/core/modules/node/src/Form/NodeRevisionDeleteForm.php @@ -12,7 +12,6 @@ use Drupal\Core\Form\ConfirmFormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; -use Drupal\node\NodeInterface; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/node/src/NodeAccessControlHandler.php b/core/modules/node/src/NodeAccessControlHandler.php index b7c349ad1..490846f86 100644 --- a/core/modules/node/src/NodeAccessControlHandler.php +++ b/core/modules/node/src/NodeAccessControlHandler.php @@ -12,7 +12,6 @@ use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldItemListInterface; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Entity\EntityAccessControlHandler; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Session\AccountInterface; diff --git a/core/modules/node/src/NodeForm.php b/core/modules/node/src/NodeForm.php index 36cfc74c5..bb6c49d72 100644 --- a/core/modules/node/src/NodeForm.php +++ b/core/modules/node/src/NodeForm.php @@ -10,7 +10,6 @@ use Drupal\Core\Entity\ContentEntityForm; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\user\Entity\User; use Drupal\user\PrivateTempStoreFactory; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/node/src/NodeGrantDatabaseStorage.php b/core/modules/node/src/NodeGrantDatabaseStorage.php index f6c56dbd4..6b6f2806a 100644 --- a/core/modules/node/src/NodeGrantDatabaseStorage.php +++ b/core/modules/node/src/NodeGrantDatabaseStorage.php @@ -11,12 +11,9 @@ use Drupal\Core\Database\Connection; use Drupal\Core\Database\Query\SelectInterface; use Drupal\Core\Database\Query\Condition; -use Drupal\Core\Entity\ContentEntityBase; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\user\Entity\User; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Defines a controller class that handles the node grants system. diff --git a/core/modules/node/src/NodeInterface.php b/core/modules/node/src/NodeInterface.php index 839c3d2cb..241fb1ae7 100644 --- a/core/modules/node/src/NodeInterface.php +++ b/core/modules/node/src/NodeInterface.php @@ -10,7 +10,6 @@ use Drupal\user\EntityOwnerInterface; use Drupal\Core\Entity\EntityChangedInterface; use Drupal\Core\Entity\ContentEntityInterface; -use Drupal\user\UserInterface; /** * Provides an interface defining a node entity. diff --git a/core/modules/node/src/NodeViewBuilder.php b/core/modules/node/src/NodeViewBuilder.php index dd7c04566..1ee05f6af 100644 --- a/core/modules/node/src/NodeViewBuilder.php +++ b/core/modules/node/src/NodeViewBuilder.php @@ -11,7 +11,6 @@ use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityViewBuilder; use Drupal\node\Entity\Node; -use Drupal\user\Entity\User; /** * Render controller for nodes. diff --git a/core/modules/node/src/ParamConverter/NodePreviewConverter.php b/core/modules/node/src/ParamConverter/NodePreviewConverter.php index 6746fae26..adbf2afb2 100644 --- a/core/modules/node/src/ParamConverter/NodePreviewConverter.php +++ b/core/modules/node/src/ParamConverter/NodePreviewConverter.php @@ -7,7 +7,6 @@ namespace Drupal\node\ParamConverter; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\user\PrivateTempStoreFactory; use Symfony\Component\Routing\Route; use Drupal\Core\ParamConverter\ParamConverterInterface; diff --git a/core/modules/node/src/Plugin/Block/SyndicateBlock.php b/core/modules/node/src/Plugin/Block/SyndicateBlock.php index 1e40332e0..c72389612 100644 --- a/core/modules/node/src/Plugin/Block/SyndicateBlock.php +++ b/core/modules/node/src/Plugin/Block/SyndicateBlock.php @@ -9,8 +9,6 @@ use Drupal\Core\Access\AccessResult; use Drupal\Core\Block\BlockBase; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Session\AccountInterface; /** diff --git a/core/modules/node/src/Plugin/Search/NodeSearch.php b/core/modules/node/src/Plugin/Search/NodeSearch.php index 8861521f5..0fa464ec0 100644 --- a/core/modules/node/src/Plugin/Search/NodeSearch.php +++ b/core/modules/node/src/Plugin/Search/NodeSearch.php @@ -97,7 +97,7 @@ class NodeSearch extends ConfigurableSearchPluginBase implements AccessibleInter /** * The list of options and info for advanced search filters. * - * Each entry in the array has the option as the key and and for its value, an + * Each entry in the array has the option as the key and for its value, an * array that determines how the value is matched in the database query. The * possible keys in that array are: * - column: (required) Name of the database column to match against. diff --git a/core/modules/node/src/Plugin/migrate/builder/d6/Node.php b/core/modules/node/src/Plugin/migrate/builder/d6/Node.php index ca978426b..99f8d45a6 100644 --- a/core/modules/node/src/Plugin/migrate/builder/d6/Node.php +++ b/core/modules/node/src/Plugin/migrate/builder/d6/Node.php @@ -41,9 +41,17 @@ public function buildMigrations(array $template) { $node_type = $row->getSourceProperty('type'); $values = $template; $values['id'] = $template['id'] . '__' . $node_type; + $label = $template['label']; $values['label'] = $this->t("@label (@type)", ['@label' => $label, '@type' => $node_type]); $values['source']['node_type'] = $node_type; + + // If this migration is based on the d6_node_revision template, it should + // explicitly depend on the corresponding d6_node variant. + if ($template['id'] == 'd6_node_revision') { + $values['migration_dependencies']['required'][] = 'd6_node__' . $node_type; + } + $migration = Migration::create($values); if (isset($fields[$node_type])) { diff --git a/core/modules/node/src/Plugin/views/field/NodeBulkForm.php b/core/modules/node/src/Plugin/views/field/NodeBulkForm.php index 1f8a247c2..5f8e04ee8 100644 --- a/core/modules/node/src/Plugin/views/field/NodeBulkForm.php +++ b/core/modules/node/src/Plugin/views/field/NodeBulkForm.php @@ -7,7 +7,6 @@ namespace Drupal\node\Plugin\views\field; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\system\Plugin\views\field\BulkForm; /** diff --git a/core/modules/node/src/Plugin/views/row/Rss.php b/core/modules/node/src/Plugin/views/row/Rss.php index 2967cceca..ae2b8712d 100644 --- a/core/modules/node/src/Plugin/views/row/Rss.php +++ b/core/modules/node/src/Plugin/views/row/Rss.php @@ -9,8 +9,6 @@ use Drupal\Core\Entity\EntityManagerInterface; use Drupal\views\Plugin\views\row\RssPluginBase; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Drupal\node\NodeStorageInterface; /** * Plugin which performs a node_view on the resulting object diff --git a/core/modules/node/src/Tests/Migrate/d6/MigrateNodeRevisionTest.php b/core/modules/node/src/Tests/Migrate/d6/MigrateNodeRevisionTest.php index 73d55a31d..b8ee0c2ae 100644 --- a/core/modules/node/src/Tests/Migrate/d6/MigrateNodeRevisionTest.php +++ b/core/modules/node/src/Tests/Migrate/d6/MigrateNodeRevisionTest.php @@ -7,8 +7,6 @@ namespace Drupal\node\Tests\Migrate\d6; -use Drupal\migrate\Entity\Migration; - /** * Node content revisions migration. * diff --git a/core/modules/node/src/Tests/Migrate/d6/MigrateNodeTestBase.php b/core/modules/node/src/Tests/Migrate/d6/MigrateNodeTestBase.php index 9bf182eee..f88fba27f 100644 --- a/core/modules/node/src/Tests/Migrate/d6/MigrateNodeTestBase.php +++ b/core/modules/node/src/Tests/Migrate/d6/MigrateNodeTestBase.php @@ -7,7 +7,6 @@ namespace Drupal\node\Tests\Migrate\d6; -use Drupal\migrate\Entity\MigrationInterface; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; use Drupal\user\Entity\User; diff --git a/core/modules/node/src/Tests/Migrate/d7/MigrateNodeTest.php b/core/modules/node/src/Tests/Migrate/d7/MigrateNodeTest.php index b2537f573..9a9024bab 100644 --- a/core/modules/node/src/Tests/Migrate/d7/MigrateNodeTest.php +++ b/core/modules/node/src/Tests/Migrate/d7/MigrateNodeTest.php @@ -123,7 +123,7 @@ protected function assertRevision($id, $title, $uid, $log, $timestamp) { */ public function testNode() { $this->assertEntity(1, 'test_content_type', 'en', 'A Node', '2', TRUE, '1421727515', '1441032132', TRUE, FALSE); - $this->assertRevision(1, 'A Node', '2', NULL, '1441032132'); + $this->assertRevision(1, 'A Node', '1', NULL, '1441032132'); $node = Node::load(1); $this->assertTrue($node->field_boolean->value); diff --git a/core/modules/node/src/Tests/NodeBodyFieldStorageTest.php b/core/modules/node/src/Tests/NodeBodyFieldStorageTest.php index 33aa98ef8..ddf7559f4 100644 --- a/core/modules/node/src/Tests/NodeBodyFieldStorageTest.php +++ b/core/modules/node/src/Tests/NodeBodyFieldStorageTest.php @@ -7,13 +7,10 @@ namespace Drupal\node\Tests; -use Drupal\Core\Field\Entity\BaseFieldOverride; use Drupal\field\Entity\FieldConfig; use Drupal\field\Entity\FieldStorageConfig; -use Drupal\node\Entity\Node; use Drupal\node\Entity\NodeType; use Drupal\simpletest\KernelTestBase; -use Drupal\system\Tests\Entity\EntityUnitTestBase; /** * Tests node body field storage. diff --git a/core/modules/node/src/Tests/NodeCacheTagsTest.php b/core/modules/node/src/Tests/NodeCacheTagsTest.php index 8144ba283..5940d4c5e 100644 --- a/core/modules/node/src/Tests/NodeCacheTagsTest.php +++ b/core/modules/node/src/Tests/NodeCacheTagsTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Entity\EntityInterface; use Drupal\system\Tests\Entity\EntityWithUriCacheTagsTestBase; -use Drupal\user\Entity\Role; /** * Tests the Node entity's cache tags. diff --git a/core/modules/node/src/Tests/NodeTypeTranslationTest.php b/core/modules/node/src/Tests/NodeTypeTranslationTest.php index 99c15581a..10c686584 100644 --- a/core/modules/node/src/Tests/NodeTypeTranslationTest.php +++ b/core/modules/node/src/Tests/NodeTypeTranslationTest.php @@ -28,12 +28,19 @@ class NodeTypeTranslationTest extends WebTestBase { 'node', ); + /** + * The default language code to use in this test. + * + * @var array + */ + protected $defaultLangcode = 'fr'; + /** * Languages to enable. * * @var array */ - protected $langcodes = array('fr'); + protected $additionalLangcodes = ['es']; /** * Administrator user for tests. @@ -56,11 +63,26 @@ protected function setUp() { $this->adminUser = $this->drupalCreateUser($admin_permissions); // Add languages. - foreach ($this->langcodes as $langcode) { + foreach ($this->additionalLangcodes as $langcode) { ConfigurableLanguage::createFromLangcode($langcode)->save(); } } + /** + * {@inheritdoc} + * + * Install Drupal in a language other than English for this test. This is not + * needed to test the node type translation itself but acts as a regression + * test. + * + * @see https://www.drupal.org/node/2584603 + */ + protected function installParameters() { + $parameters = parent::installParameters(); + $parameters['parameters']['langcode'] = $this->defaultLangcode; + return $parameters; + } + /** * Tests the node type translation. */ @@ -71,14 +93,13 @@ public function testNodeTypeTranslation() { $this->drupalCreateContentType(array('type' => $type, 'name' => $name)); // Translate the node type name. - $langcode = $this->langcodes[0]; + $langcode = $this->additionalLangcodes[0]; $translated_name = $langcode . '-' . $name; $edit = array( "translation[config_names][node.type.$type][name]" => $translated_name, ); // Edit the title label to avoid having an exception when we save the translation. - $this->drupalPostForm("admin/structure/types/manage/$type", array('title_label' => 'Edited title'), t('Save content type')); $this->drupalPostForm("admin/structure/types/manage/$type/translate/$langcode/add", $edit, t('Save translation')); // Check the name is translated without admin theme for editing. @@ -100,7 +121,7 @@ public function testNodeTypeTitleLabelTranslation() { $name = $this->randomString(); $this->drupalLogin($this->adminUser); $this->drupalCreateContentType(array('type' => $type, 'name' => $name)); - $langcode = $this->langcodes[0]; + $langcode = $this->additionalLangcodes[0]; // Edit the title label for it to be displayed on the translation form. $this->drupalPostForm("admin/structure/types/manage/$type", array('title_label' => 'Edited title'), t('Save content type')); diff --git a/core/modules/node/src/Tests/Views/NodeFieldTokensTest.php b/core/modules/node/src/Tests/Views/NodeFieldTokensTest.php index 3aef9b22b..16a52bf7c 100644 --- a/core/modules/node/src/Tests/Views/NodeFieldTokensTest.php +++ b/core/modules/node/src/Tests/Views/NodeFieldTokensTest.php @@ -7,9 +7,6 @@ namespace Drupal\node\Tests\Views; -use Drupal\views\Views; -use Drupal\node\Tests\Views\NodeTestBase; - /** * Tests replacement of Views tokens supplied by the Node module. * diff --git a/core/modules/options/src/Plugin/views/argument/StringListField.php b/core/modules/options/src/Plugin/views/argument/StringListField.php index ee26d43b5..abd02e40f 100644 --- a/core/modules/options/src/Plugin/views/argument/StringListField.php +++ b/core/modules/options/src/Plugin/views/argument/StringListField.php @@ -14,7 +14,6 @@ use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\argument\StringArgument; -use Drupal\Component\Utility\SafeMarkup; /** * Argument handler for list field to show the human readable name in summary. diff --git a/core/modules/options/src/Tests/OptionsSelectDynamicValuesTest.php b/core/modules/options/src/Tests/OptionsSelectDynamicValuesTest.php index f6a661a70..2b9c0bb53 100644 --- a/core/modules/options/src/Tests/OptionsSelectDynamicValuesTest.php +++ b/core/modules/options/src/Tests/OptionsSelectDynamicValuesTest.php @@ -25,7 +25,7 @@ function testSelectListDynamic() { $this->drupalLogin($web_user); // Display form. - $this->drupalGet('entity_test_rev/manage/' . $this->entity->id()); + $this->drupalGet('entity_test_rev/manage/' . $this->entity->id() . '/edit'); $options = $this->xpath('//select[@id="edit-test-options"]/option'); $this->assertEqual(count($options), count($this->test) + 1); foreach ($options as $option) { diff --git a/core/modules/options/src/Tests/OptionsWidgetsTest.php b/core/modules/options/src/Tests/OptionsWidgetsTest.php index f1d2ca327..93293cac3 100644 --- a/core/modules/options/src/Tests/OptionsWidgetsTest.php +++ b/core/modules/options/src/Tests/OptionsWidgetsTest.php @@ -108,7 +108,7 @@ function testRadioButtons() { $entity_init = clone $entity; // With no field data, no buttons are checked. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertNoFieldChecked('edit-card-1-0'); $this->assertNoFieldChecked('edit-card-1-1'); $this->assertNoFieldChecked('edit-card-1-2'); @@ -121,7 +121,7 @@ function testRadioButtons() { $this->assertFieldValues($entity_init, 'card_1', array(0)); // Check that the selected button is checked. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFieldChecked('edit-card-1-0'); $this->assertNoFieldChecked('edit-card-1-1'); $this->assertNoFieldChecked('edit-card-1-2'); @@ -136,7 +136,7 @@ function testRadioButtons() { $this->card1->save(); $field->setRequired(TRUE); $field->save(); - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFieldChecked('edit-card-1-99'); } @@ -165,7 +165,7 @@ function testCheckBoxes() { $entity_init = clone $entity; // Display form: with no field data, nothing is checked. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertNoFieldChecked('edit-card-2-0'); $this->assertNoFieldChecked('edit-card-2-1'); $this->assertNoFieldChecked('edit-card-2-2'); @@ -181,7 +181,7 @@ function testCheckBoxes() { $this->assertFieldValues($entity_init, 'card_2', array(0, 2)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFieldChecked('edit-card-2-0'); $this->assertNoFieldChecked('edit-card-2-1'); $this->assertFieldChecked('edit-card-2-2'); @@ -196,7 +196,7 @@ function testCheckBoxes() { $this->assertFieldValues($entity_init, 'card_2', array(0)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFieldChecked('edit-card-2-0'); $this->assertNoFieldChecked('edit-card-2-1'); $this->assertNoFieldChecked('edit-card-2-2'); @@ -225,7 +225,7 @@ function testCheckBoxes() { $this->card2->save(); $field->setRequired(TRUE); $field->save(); - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFieldChecked('edit-card-2-99'); } @@ -255,7 +255,7 @@ function testSelectListSingle() { $entity_init = clone $entity; // Display form. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); // A required field without any value has a "none" option. $this->assertTrue($this->xpath('//select[@id=:id]//option[@value="_none" and text()=:label]', array(':id' => 'edit-card-1', ':label' => t('- Select a value -'))), 'A required select list has a "Select a value" choice.'); @@ -277,7 +277,7 @@ function testSelectListSingle() { $this->assertFieldValues($entity_init, 'card_1', array(0)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); // A required field with a value has no 'none' option. $this->assertFalse($this->xpath('//select[@id=:id]//option[@value="_none"]', array(':id' => 'edit-card-1')), 'A required select list with an actual value has no "none" choice.'); $this->assertOptionSelected('edit-card-1', 0); @@ -289,12 +289,12 @@ function testSelectListSingle() { $field->save(); // Display form. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); // A non-required field has a 'none' option. $this->assertTrue($this->xpath('//select[@id=:id]//option[@value="_none" and text()=:label]', array(':id' => 'edit-card-1', ':label' => t('- None -'))), 'A non-required select list has a "None" choice.'); // Submit form: Unselect the option. $edit = array('card_1' => '_none'); - $this->drupalPostForm('entity_test/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $entity->id() . '/edit', $edit, t('Save')); $this->assertFieldValues($entity_init, 'card_1', array()); // Test optgroups. @@ -304,7 +304,7 @@ function testSelectListSingle() { $this->card1->save(); // Display form: with no field data, nothing is selected - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertNoOptionSelected('edit-card-1', 0); $this->assertNoOptionSelected('edit-card-1', 1); $this->assertNoOptionSelected('edit-card-1', 2); @@ -318,14 +318,14 @@ function testSelectListSingle() { $this->assertFieldValues($entity_init, 'card_1', array(0)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertOptionSelected('edit-card-1', 0); $this->assertNoOptionSelected('edit-card-1', 1); $this->assertNoOptionSelected('edit-card-1', 2); // Submit form: Unselect the option. $edit = array('card_1' => '_none'); - $this->drupalPostForm('entity_test/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $entity->id() . '/edit', $edit, t('Save')); $this->assertFieldValues($entity_init, 'card_1', array()); } @@ -354,7 +354,7 @@ function testSelectListMultiple() { $entity_init = clone $entity; // Display form: with no field data, nothing is selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertOptionSelected("edit-card-2", '_none'); $this->assertNoOptionSelected('edit-card-2', 0); $this->assertNoOptionSelected('edit-card-2', 1); @@ -367,7 +367,7 @@ function testSelectListMultiple() { $this->assertFieldValues($entity_init, 'card_2', array(0, 2)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertOptionSelected('edit-card-2', 0); $this->assertNoOptionSelected('edit-card-2', 1); $this->assertOptionSelected('edit-card-2', 2); @@ -378,7 +378,7 @@ function testSelectListMultiple() { $this->assertFieldValues($entity_init, 'card_2', array(0)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertOptionSelected('edit-card-2', 0); $this->assertNoOptionSelected('edit-card-2', 1); $this->assertNoOptionSelected('edit-card-2', 2); @@ -398,18 +398,18 @@ function testSelectListMultiple() { // Check that the 'none' option has no effect if actual options are selected // as well. $edit = array('card_2[]' => array('_none' => '_none', 0 => 0)); - $this->drupalPostForm('entity_test/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $entity->id() . '/edit', $edit, t('Save')); $this->assertFieldValues($entity_init, 'card_2', array(0)); // Check that selecting the 'none' option empties the field. $edit = array('card_2[]' => array('_none' => '_none')); - $this->drupalPostForm('entity_test/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $entity->id() . '/edit', $edit, t('Save')); $this->assertFieldValues($entity_init, 'card_2', array()); // A required select list does not have an empty key. $field->setRequired(TRUE); $field->save(); - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertFalse($this->xpath('//select[@id=:id]//option[@value=""]', array(':id' => 'edit-card-2')), 'A required select list does not have an empty key.'); // We do not have to test that a required select list with one option is @@ -425,7 +425,7 @@ function testSelectListMultiple() { $field->save(); // Display form: with no field data, nothing is selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertNoOptionSelected('edit-card-2', 0); $this->assertNoOptionSelected('edit-card-2', 1); $this->assertNoOptionSelected('edit-card-2', 2); @@ -439,14 +439,14 @@ function testSelectListMultiple() { $this->assertFieldValues($entity_init, 'card_2', array(0)); // Display form: check that the right options are selected. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertOptionSelected('edit-card-2', 0); $this->assertNoOptionSelected('edit-card-2', 1); $this->assertNoOptionSelected('edit-card-2', 2); // Submit form: Unselect the option. $edit = array('card_2[]' => array('_none' => '_none')); - $this->drupalPostForm('entity_test/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('entity_test/manage/' . $entity->id() . '/edit', $edit, t('Save')); $this->assertFieldValues($entity_init, 'card_2', array()); } @@ -476,7 +476,7 @@ function testEmptyValue() { $entity->save(); // Display form: check that _none options are present and has label. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); $this->assertTrue($this->xpath('//div[@id=:id]//input[@value=:value]', array(':id' => 'edit-card-1', ':value' => '_none')), 'A test radio button has a "None" choice.'); $this->assertTrue($this->xpath('//div[@id=:id]//label[@for=:for and text()=:label]', array(':id' => 'edit-card-1', ':for' => 'edit-card-1-none', ':label' => 'N/A')), 'A test radio button has a "N/A" choice.'); @@ -488,7 +488,7 @@ function testEmptyValue() { ->save(); // Display form: check that _none options are present and has label. - $this->drupalGet('entity_test/manage/' . $entity->id()); + $this->drupalGet('entity_test/manage/' . $entity->id() . '/edit'); // A required field without any value has a "none" option. $this->assertTrue($this->xpath('//select[@id=:id]//option[@value="_none" and text()=:label]', array(':id' => 'edit-card-1', ':label' => t('- None -'))), 'A test select has a "None" choice.'); } diff --git a/core/modules/options/src/Tests/Views/OptionsTestBase.php b/core/modules/options/src/Tests/Views/OptionsTestBase.php index b204d1bb5..972c00bad 100644 --- a/core/modules/options/src/Tests/Views/OptionsTestBase.php +++ b/core/modules/options/src/Tests/Views/OptionsTestBase.php @@ -11,7 +11,6 @@ use Drupal\field\Entity\FieldStorageConfig; use Drupal\node\Entity\Node; use Drupal\node\Entity\NodeType; -use Drupal\views\Tests\ViewTestBase; use Drupal\views\Tests\ViewTestData; use Drupal\views\Tests\ViewKernelTestBase; diff --git a/core/modules/page_cache/src/StackMiddleware/PageCache.php b/core/modules/page_cache/src/StackMiddleware/PageCache.php index 1629c14c3..f25c685e4 100644 --- a/core/modules/page_cache/src/StackMiddleware/PageCache.php +++ b/core/modules/page_cache/src/StackMiddleware/PageCache.php @@ -7,12 +7,11 @@ namespace Drupal\page_cache\StackMiddleware; -use Drupal\Component\Utility\UserAgent; use Drupal\Core\Cache\Cache; +use Drupal\Core\Cache\CacheableResponseInterface; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\PageCache\RequestPolicyInterface; use Drupal\Core\PageCache\ResponsePolicyInterface; -use Drupal\Core\Site\Settings; use Symfony\Component\HttpFoundation\BinaryFileResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; @@ -208,25 +207,55 @@ protected function lookup(Request $request, $type = self::MASTER_REQUEST, $catch * A response object. */ protected function fetch(Request $request, $type = self::MASTER_REQUEST, $catch = TRUE) { + /** @var \Symfony\Component\HttpFoundation\Response $response */ $response = $this->httpKernel->handle($request, $type, $catch); - // Currently it is not possible to cache some types of responses. Therefore - // exclude binary file responses (generated files, e.g. images with image - // styles) and streamed responses (files directly read from the disk). - // see: https://github.com/symfony/symfony/issues/9128#issuecomment-25088678 + // Drupal's primary cache invalidation architecture is cache tags: any + // response that varies by a configuration value or data in a content + // entity should have cache tags, to allow for instant cache invalidation + // when that data is updated. However, HTTP does not standardize how to + // encode cache tags in a response. Different CDNs implement their own + // approaches, and configurable reverse proxies (e.g., Varnish) allow for + // custom implementations. To keep Drupal's internal page cache simple, we + // only cache CacheableResponseInterface responses, since those provide a + // defined API for retrieving cache tags. For responses that do not + // implement CacheableResponseInterface, there's no easy way to distinguish + // responses that truly don't depend on any site data from responses that + // contain invalidation information customized to a particular proxy or + // CDN. + // - Drupal modules are encouraged to use CacheableResponseInterface + // responses where possible and to leave the encoding of that information + // into response headers to the corresponding proxy/CDN integration + // modules. + // - Custom applications that wish to provide internal page cache support + // for responses that do not implement CacheableResponseInterface may do + // so by replacing/extending this middleware service or adding another + // one. + if (!$response instanceof CacheableResponseInterface) { + return $response; + } + + // Currently it is not possible to cache binary file or streamed responses: + // https://github.com/symfony/symfony/issues/9128#issuecomment-25088678. + // Therefore exclude them, even for subclasses that implement + // CacheableResponseInterface. if ($response instanceof BinaryFileResponse || $response instanceof StreamedResponse) { return $response; } + // Allow policy rules to further restrict which responses to cache. if ($this->responsePolicy->check($response, $request) === ResponsePolicyInterface::DENY) { return $response; } - // Use the actual timestamp from an Expires header, if available. + // The response passes all of the above checks, so cache it. + // - Get the tags from CacheableResponseInterface per the earlier comments. + // - Get the time expiration from the Expires header, rather than the + // interface, but see https://www.drupal.org/node/2352009 about possibly + // changing that. + $tags = $response->getCacheableMetadata()->getCacheTags(); $date = $response->getExpires()->getTimestamp(); $expire = ($date > time()) ? $date : Cache::PERMANENT; - - $tags = explode(' ', $response->headers->get('X-Drupal-Cache-Tags')); $this->set($request, $response, $expire, $tags); // Mark response as a cache miss. diff --git a/core/modules/page_cache/src/Tests/PageCacheTest.php b/core/modules/page_cache/src/Tests/PageCacheTest.php index a2278e75f..0183b3163 100644 --- a/core/modules/page_cache/src/Tests/PageCacheTest.php +++ b/core/modules/page_cache/src/Tests/PageCacheTest.php @@ -79,6 +79,37 @@ function testPageCacheTags() { $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS'); } + /** + * Test that the page cache doesn't depend on cacheability headers. + */ + function testPageCacheTagsIndependentFromCacheabilityHeaders() { + $this->setHttpResponseDebugCacheabilityHeaders(FALSE); + + $path = 'system-test/cache_tags_page'; + $tags = array('system_test_cache_tags_page'); + $this->drupalGet($path); + $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS'); + + // Verify a cache hit, but also the presence of the correct cache tags. + $this->drupalGet($path); + $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'HIT'); + $cid_parts = array(\Drupal::url('system_test.cache_tags_page', array(), array('absolute' => TRUE)), 'html'); + $cid = implode(':', $cid_parts); + $cache_entry = \Drupal::cache('render')->get($cid); + sort($cache_entry->tags); + $expected_tags = array( + 'config:user.role.anonymous', + 'pre_render', + 'rendered', + 'system_test_cache_tags_page', + ); + $this->assertIdentical($cache_entry->tags, $expected_tags); + + Cache::invalidateTags($tags); + $this->drupalGet($path); + $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS'); + } + /** * Tests support for different cache items with different request formats * specified via a query parameter. @@ -418,22 +449,32 @@ public function testCacheableResponseResponses() { $config->set('cache.page.max_age', 300); $config->save(); - // Try to fill the cache. + // GET a URL, which would be marked as a cache miss if it were cacheable. $this->drupalGet('/system-test/respond-reponse'); - $this->assertFalse(in_array('X-Drupal-Cache', $this->drupalGetHeaders()), 'Drupal page cache header not found'); + $this->assertFalse($this->drupalGetHeader('X-Drupal-Cache'), 'Drupal page cache header not found.'); $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'must-revalidate, no-cache, post-check=0, pre-check=0, private', 'Cache-Control header was sent'); - // Still not cached, uncacheable response. + // GET it again, verify it's still not cached. $this->drupalGet('/system-test/respond-reponse'); - $this->assertFalse(in_array('X-Drupal-Cache', $this->drupalGetHeaders()), 'Drupal page cache header not found'); + $this->assertFalse($this->drupalGetHeader('X-Drupal-Cache'), 'Drupal page cache header not found.'); $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'must-revalidate, no-cache, post-check=0, pre-check=0, private', 'Cache-Control header was sent'); - // Try to fill the cache. + // GET a URL, which would be marked as a cache miss if it were cacheable. + $this->drupalGet('/system-test/respond-public-response'); + $this->assertFalse($this->drupalGetHeader('X-Drupal-Cache'), 'Drupal page cache header not found.'); + $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'max-age=60, public', 'Cache-Control header was sent'); + + // GET it again, verify it's still not cached. + $this->drupalGet('/system-test/respond-public-response'); + $this->assertFalse($this->drupalGetHeader('X-Drupal-Cache'), 'Drupal page cache header not found.'); + $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'max-age=60, public', 'Cache-Control header was sent'); + + // GET a URL, which should be marked as a cache miss. $this->drupalGet('/system-test/respond-cacheable-reponse'); $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS', 'Page was not cached.'); $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'max-age=300, public', 'Cache-Control header was sent.'); - // Should be cached now. + // GET it again, it should now be a cache hit. $this->drupalGet('/system-test/respond-cacheable-reponse'); $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'HIT', 'Page was cached.'); $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'max-age=300, public', 'Cache-Control header was sent.'); @@ -443,13 +484,9 @@ public function testCacheableResponseResponses() { $this->container->get('module_installer') ->uninstall(['page_cache']); - // Try to fill the cache. - $this->drupalGet('/system-test/respond-reponse'); - $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'must-revalidate, no-cache, post-check=0, pre-check=0, private', 'Cache-Control header was sent'); - - // Still not cached, uncacheable response. - $this->drupalGet('/system-test/respond-reponse'); - $this->assertEqual($this->drupalGetHeader('Cache-Control'), 'must-revalidate, no-cache, post-check=0, pre-check=0, private', 'Cache-Control header was sent'); + // GET a URL that was cached by Page Cache before, it should not be now. + $this->drupalGet('/respond-cacheable-reponse'); + $this->assertFalse($this->drupalGetHeader('X-Drupal-Cache'), 'Drupal page cache header not found.'); } } diff --git a/core/modules/path/path.js b/core/modules/path/path.js index 2a7f48c8b..4cca889b1 100644 --- a/core/modules/path/path.js +++ b/core/modules/path/path.js @@ -4,7 +4,7 @@ */ (function ($) { - "use strict"; + 'use strict'; /** * Behaviors for settings summaries on path edit forms. diff --git a/core/modules/quickedit/js/editors/formEditor.js b/core/modules/quickedit/js/editors/formEditor.js index c612a2862..49fc6f0cd 100644 --- a/core/modules/quickedit/js/editors/formEditor.js +++ b/core/modules/quickedit/js/editors/formEditor.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * @constructor diff --git a/core/modules/quickedit/js/editors/plainTextEditor.js b/core/modules/quickedit/js/editors/plainTextEditor.js index 656d444f9..71f9b74e5 100644 --- a/core/modules/quickedit/js/editors/plainTextEditor.js +++ b/core/modules/quickedit/js/editors/plainTextEditor.js @@ -5,7 +5,7 @@ (function ($, _, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.editors.plain_text = Drupal.quickedit.EditorView.extend(/** @lends Drupal.quickedit.editors.plain_text# */{ diff --git a/core/modules/quickedit/js/models/AppModel.js b/core/modules/quickedit/js/models/AppModel.js index bce8aaec3..6c473ac97 100644 --- a/core/modules/quickedit/js/models/AppModel.js +++ b/core/modules/quickedit/js/models/AppModel.js @@ -7,7 +7,7 @@ (function (Backbone, Drupal) { - "use strict"; + 'use strict'; /** * @constructor diff --git a/core/modules/quickedit/js/models/BaseModel.js b/core/modules/quickedit/js/models/BaseModel.js index 718efae88..f1c31d797 100644 --- a/core/modules/quickedit/js/models/BaseModel.js +++ b/core/modules/quickedit/js/models/BaseModel.js @@ -5,7 +5,7 @@ (function (Backbone) { - "use strict"; + 'use strict'; Drupal.quickedit.BaseModel = Backbone.Model.extend(/** @lends Drupal.quickedit.BaseModel# */{ diff --git a/core/modules/quickedit/js/models/EditorModel.js b/core/modules/quickedit/js/models/EditorModel.js index 142c9ccb6..4b6177bc4 100644 --- a/core/modules/quickedit/js/models/EditorModel.js +++ b/core/modules/quickedit/js/models/EditorModel.js @@ -7,7 +7,7 @@ (function (Backbone, Drupal) { - "use strict"; + 'use strict'; /** * @constructor diff --git a/core/modules/quickedit/js/models/EntityModel.js b/core/modules/quickedit/js/models/EntityModel.js index 322acb32e..f444fbb91 100644 --- a/core/modules/quickedit/js/models/EntityModel.js +++ b/core/modules/quickedit/js/models/EntityModel.js @@ -5,7 +5,7 @@ (function (_, $, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.EntityModel = Drupal.quickedit.BaseModel.extend(/** @lends Drupal.quickedit.EntityModel# */{ @@ -536,7 +536,7 @@ } } else if (currentIsCommitting === true && nextIsCommitting === true) { - return "isCommitting is a mutex, hence only changes are allowed"; + return 'isCommitting is a mutex, hence only changes are allowed'; } }, diff --git a/core/modules/quickedit/js/models/FieldModel.js b/core/modules/quickedit/js/models/FieldModel.js index 392540173..8aeff107d 100644 --- a/core/modules/quickedit/js/models/FieldModel.js +++ b/core/modules/quickedit/js/models/FieldModel.js @@ -5,7 +5,7 @@ (function (_, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.FieldModel = Drupal.quickedit.BaseModel.extend(/** @lends Drupal.quickedit.FieldModel# */{ @@ -138,7 +138,7 @@ */ destroy: function (options) { if (this.get('state') !== 'inactive') { - throw new Error("FieldModel cannot be destroyed if it is not inactive state."); + throw new Error('FieldModel cannot be destroyed if it is not inactive state.'); } Drupal.quickedit.BaseModel.prototype.destroy.call(this, options); }, diff --git a/core/modules/quickedit/js/quickedit.js b/core/modules/quickedit/js/quickedit.js index 5504e444a..40bdd3e60 100644 --- a/core/modules/quickedit/js/quickedit.js +++ b/core/modules/quickedit/js/quickedit.js @@ -19,7 +19,7 @@ (function ($, _, Backbone, Drupal, drupalSettings, JSON, storage) { - "use strict"; + 'use strict'; var options = $.extend(drupalSettings.quickedit, // Merge strings on top of drupalSettings so that they are not mutable. diff --git a/core/modules/quickedit/js/theme.js b/core/modules/quickedit/js/theme.js index 8ea7a310e..93dc3f238 100644 --- a/core/modules/quickedit/js/theme.js +++ b/core/modules/quickedit/js/theme.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Theme function for a "backstage" for the Quick Edit module. diff --git a/core/modules/quickedit/js/util.js b/core/modules/quickedit/js/util.js index 8ef371e13..4b0a4c43e 100644 --- a/core/modules/quickedit/js/util.js +++ b/core/modules/quickedit/js/util.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * @namespace @@ -21,7 +21,7 @@ * * @type {string} */ - Drupal.quickedit.util.constants.transitionEnd = "transitionEnd.quickedit webkitTransitionEnd.quickedit transitionend.quickedit msTransitionEnd.quickedit oTransitionEnd.quickedit"; + Drupal.quickedit.util.constants.transitionEnd = 'transitionEnd.quickedit webkitTransitionEnd.quickedit transitionend.quickedit msTransitionEnd.quickedit oTransitionEnd.quickedit'; /** * Converts a field id into a formatted url path. diff --git a/core/modules/quickedit/js/views/AppView.js b/core/modules/quickedit/js/views/AppView.js index dbffdd684..b09a110b8 100644 --- a/core/modules/quickedit/js/views/AppView.js +++ b/core/modules/quickedit/js/views/AppView.js @@ -7,7 +7,7 @@ (function ($, _, Backbone, Drupal) { - "use strict"; + 'use strict'; // Indicates whether the page should be reloaded after in-place editing has // shut down. A page reload is necessary to re-instate the original HTML of diff --git a/core/modules/quickedit/js/views/ContextualLinkView.js b/core/modules/quickedit/js/views/ContextualLinkView.js index 288101a31..bf50f616c 100644 --- a/core/modules/quickedit/js/views/ContextualLinkView.js +++ b/core/modules/quickedit/js/views/ContextualLinkView.js @@ -5,7 +5,7 @@ (function ($, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.ContextualLinkView = Backbone.View.extend(/** @lends Drupal.quickedit.ContextualLinkView# */{ diff --git a/core/modules/quickedit/js/views/EditorView.js b/core/modules/quickedit/js/views/EditorView.js index 31ec5a587..5e041db0d 100644 --- a/core/modules/quickedit/js/views/EditorView.js +++ b/core/modules/quickedit/js/views/EditorView.js @@ -5,7 +5,7 @@ (function ($, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.EditorView = Backbone.View.extend(/** @lends Drupal.quickedit.EditorView# */{ diff --git a/core/modules/quickedit/js/views/EntityDecorationView.js b/core/modules/quickedit/js/views/EntityDecorationView.js index e4607ef84..ff090fe4c 100644 --- a/core/modules/quickedit/js/views/EntityDecorationView.js +++ b/core/modules/quickedit/js/views/EntityDecorationView.js @@ -5,7 +5,7 @@ (function (Drupal, $, Backbone) { - "use strict"; + 'use strict'; Drupal.quickedit.EntityDecorationView = Backbone.View.extend(/** @lends Drupal.quickedit.EntityDecorationView# */{ diff --git a/core/modules/quickedit/js/views/EntityToolbarView.js b/core/modules/quickedit/js/views/EntityToolbarView.js index 61de7bbca..4e8e913dd 100644 --- a/core/modules/quickedit/js/views/EntityToolbarView.js +++ b/core/modules/quickedit/js/views/EntityToolbarView.js @@ -5,7 +5,7 @@ (function ($, _, Backbone, Drupal, debounce) { - "use strict"; + 'use strict'; Drupal.quickedit.EntityToolbarView = Backbone.View.extend(/** @lends Drupal.quickedit.EntityToolbarView# */{ diff --git a/core/modules/quickedit/js/views/FieldDecorationView.js b/core/modules/quickedit/js/views/FieldDecorationView.js index b098f7fd4..966e2b9fb 100644 --- a/core/modules/quickedit/js/views/FieldDecorationView.js +++ b/core/modules/quickedit/js/views/FieldDecorationView.js @@ -5,7 +5,7 @@ (function ($, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.FieldDecorationView = Backbone.View.extend(/** @lends Drupal.quickedit.FieldDecorationView# */{ @@ -237,7 +237,7 @@ // width and *then* add 5px padding, hence ensuring the padding is added // "on the outside". // 1) Freeze the width (if it's not already set); don't use animations. - if (this.$el[0].style.width === "") { + if (this.$el[0].style.width === '') { this._widthAttributeIsEmpty = true; this.$el .addClass('quickedit-animate-disable-width') diff --git a/core/modules/quickedit/js/views/FieldToolbarView.js b/core/modules/quickedit/js/views/FieldToolbarView.js index 232f702f9..dbd531f44 100644 --- a/core/modules/quickedit/js/views/FieldToolbarView.js +++ b/core/modules/quickedit/js/views/FieldToolbarView.js @@ -5,7 +5,7 @@ (function ($, _, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.quickedit.FieldToolbarView = Backbone.View.extend(/** @lends Drupal.quickedit.FieldToolbarView# */{ diff --git a/core/modules/quickedit/src/MetadataGenerator.php b/core/modules/quickedit/src/MetadataGenerator.php index 1de5fc64c..289ad53eb 100644 --- a/core/modules/quickedit/src/MetadataGenerator.php +++ b/core/modules/quickedit/src/MetadataGenerator.php @@ -8,7 +8,6 @@ namespace Drupal\quickedit; use Drupal\Component\Plugin\PluginManagerInterface; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Field\FieldItemListInterface; use Drupal\quickedit\Access\EditEntityFieldAccessCheckInterface; diff --git a/core/modules/quickedit/src/Tests/MetadataGeneratorTest.php b/core/modules/quickedit/src/Tests/MetadataGeneratorTest.php index 0cf21e0c0..033570323 100644 --- a/core/modules/quickedit/src/Tests/MetadataGeneratorTest.php +++ b/core/modules/quickedit/src/Tests/MetadataGeneratorTest.php @@ -9,7 +9,6 @@ use Drupal\quickedit\EditorSelector; use Drupal\quickedit\MetadataGenerator; -use Drupal\quickedit\Plugin\InPlaceEditorManager; use Drupal\quickedit_test\MockEditEntityFieldAccessCheck; /** diff --git a/core/modules/quickedit/tests/modules/quickedit_test.module b/core/modules/quickedit/tests/modules/quickedit_test.module index 4a1a2ef31..39c4f041c 100644 --- a/core/modules/quickedit/tests/modules/quickedit_test.module +++ b/core/modules/quickedit/tests/modules/quickedit_test.module @@ -6,8 +6,6 @@ */ use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Entity\Display\EntityViewDisplayInterface; -use Drupal\Core\Language\LanguageInterface; /** * Implements hook_quickedit_render_field(). diff --git a/core/modules/rdf/src/Tests/Field/DateTimeFieldRdfaTest.php b/core/modules/rdf/src/Tests/Field/DateTimeFieldRdfaTest.php index 337644e95..1b47b404b 100644 --- a/core/modules/rdf/src/Tests/Field/DateTimeFieldRdfaTest.php +++ b/core/modules/rdf/src/Tests/Field/DateTimeFieldRdfaTest.php @@ -6,8 +6,6 @@ namespace Drupal\rdf\Tests\Field; -use Drupal\rdf\Tests\Field\FieldRdfaTestBase; - /** * Tests RDFa output by datetime field formatters. * diff --git a/core/modules/rdf/src/Tests/Field/EmailFieldRdfaTest.php b/core/modules/rdf/src/Tests/Field/EmailFieldRdfaTest.php index a5067fc74..cda7ee7f6 100644 --- a/core/modules/rdf/src/Tests/Field/EmailFieldRdfaTest.php +++ b/core/modules/rdf/src/Tests/Field/EmailFieldRdfaTest.php @@ -6,8 +6,6 @@ namespace Drupal\rdf\Tests\Field; -use Drupal\rdf\Tests\Field\FieldRdfaTestBase; - /** * Tests RDFa output by email field formatters. * diff --git a/core/modules/rdf/src/Tests/Field/LinkFieldRdfaTest.php b/core/modules/rdf/src/Tests/Field/LinkFieldRdfaTest.php index 4d643d0b1..3a58b80da 100644 --- a/core/modules/rdf/src/Tests/Field/LinkFieldRdfaTest.php +++ b/core/modules/rdf/src/Tests/Field/LinkFieldRdfaTest.php @@ -6,9 +6,6 @@ namespace Drupal\rdf\Tests\Field; -use Drupal\Component\Utility\Unicode; -use Drupal\rdf\Tests\Field\FieldRdfaTestBase; - /** * Tests the placement of RDFa in link field formatters. * diff --git a/core/modules/rdf/src/Tests/Field/TextFieldRdfaTest.php b/core/modules/rdf/src/Tests/Field/TextFieldRdfaTest.php index b54bd7305..0e97b2722 100644 --- a/core/modules/rdf/src/Tests/Field/TextFieldRdfaTest.php +++ b/core/modules/rdf/src/Tests/Field/TextFieldRdfaTest.php @@ -6,8 +6,6 @@ namespace Drupal\rdf\Tests\Field; -use Drupal\rdf\Tests\Field\FieldRdfaTestBase; - /** * Tests RDFa output by text field formatters. * diff --git a/core/modules/responsive_image/js/responsive_image.ajax.js b/core/modules/responsive_image/js/responsive_image.ajax.js index 2c12b71f4..52093193e 100644 --- a/core/modules/responsive_image/js/responsive_image.ajax.js +++ b/core/modules/responsive_image/js/responsive_image.ajax.js @@ -1,6 +1,6 @@ (function (Drupal) { - "use strict"; + 'use strict'; /** * Call picturefill so newly added responsive images are processed. diff --git a/core/modules/responsive_image/responsive_image.module b/core/modules/responsive_image/responsive_image.module index 806049896..af87c5bfa 100644 --- a/core/modules/responsive_image/responsive_image.module +++ b/core/modules/responsive_image/responsive_image.module @@ -7,9 +7,7 @@ use Drupal\Component\Utility\Unicode; use Drupal\Core\Routing\RouteMatchInterface; -use \Drupal\Core\Template\Attribute; use Drupal\image\Entity\ImageStyle; -use Drupal\Core\Url; use Drupal\responsive_image\Entity\ResponsiveImageStyle; use Drupal\Core\Image\ImageInterface; use Drupal\breakpoint\BreakpointInterface; diff --git a/core/modules/rest/src/LinkManager/LinkManagerBase.php b/core/modules/rest/src/LinkManager/LinkManagerBase.php index f93f6fdd5..82bce0bc8 100644 --- a/core/modules/rest/src/LinkManager/LinkManagerBase.php +++ b/core/modules/rest/src/LinkManager/LinkManagerBase.php @@ -6,7 +6,6 @@ */ namespace Drupal\rest\LinkManager; -use Drupal\Core\Url; /** * Defines an abstract base-class for REST link manager objects. diff --git a/core/modules/rest/src/Plugin/ResourceBase.php b/core/modules/rest/src/Plugin/ResourceBase.php index 5f8065e11..5506f0096 100644 --- a/core/modules/rest/src/Plugin/ResourceBase.php +++ b/core/modules/rest/src/Plugin/ResourceBase.php @@ -7,7 +7,6 @@ namespace Drupal\rest\Plugin; -use Drupal\Core\Access\AccessManagerInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Plugin\PluginBase; use Psr\Log\LoggerInterface; diff --git a/core/modules/rest/src/Plugin/views/row/DataEntityRow.php b/core/modules/rest/src/Plugin/views/row/DataEntityRow.php index 1d96d2b30..a8bf13969 100644 --- a/core/modules/rest/src/Plugin/views/row/DataEntityRow.php +++ b/core/modules/rest/src/Plugin/views/row/DataEntityRow.php @@ -7,7 +7,6 @@ namespace Drupal\rest\Plugin\views\row; -use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\row\RowPluginBase; /** diff --git a/core/modules/rest/src/Plugin/views/style/Serializer.php b/core/modules/rest/src/Plugin/views/style/Serializer.php index 895f00cfb..7b8ded90e 100644 --- a/core/modules/rest/src/Plugin/views/style/Serializer.php +++ b/core/modules/rest/src/Plugin/views/style/Serializer.php @@ -10,8 +10,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\ViewExecutable; -use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\style\StylePluginBase; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\Serializer\SerializerInterface; diff --git a/core/modules/rest/src/RequestHandler.php b/core/modules/rest/src/RequestHandler.php index ee4b890aa..5a04cd88b 100644 --- a/core/modules/rest/src/RequestHandler.php +++ b/core/modules/rest/src/RequestHandler.php @@ -14,7 +14,6 @@ use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\HttpKernel\Exception\HttpException; -use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; use Symfony\Component\HttpKernel\Exception\UnsupportedMediaTypeHttpException; use Symfony\Component\Serializer\Exception\UnexpectedValueException; diff --git a/core/modules/rest/src/Routing/ResourceRoutes.php b/core/modules/rest/src/Routing/ResourceRoutes.php index f975f2773..b6f94e3b4 100644 --- a/core/modules/rest/src/Routing/ResourceRoutes.php +++ b/core/modules/rest/src/Routing/ResourceRoutes.php @@ -8,12 +8,9 @@ namespace Drupal\rest\Routing; use Drupal\Core\Config\ConfigFactoryInterface; -use Drupal\Core\DependencyInjection\ContainerInjectionInterface; use Drupal\Core\Routing\RouteSubscriberBase; use Drupal\rest\Plugin\Type\ResourcePluginManager; use Psr\Log\LoggerInterface; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\Routing\RouteCollection; /** diff --git a/core/modules/rest/src/Tests/AuthTest.php b/core/modules/rest/src/Tests/AuthTest.php index 8d4601a09..ab0b3b1ec 100644 --- a/core/modules/rest/src/Tests/AuthTest.php +++ b/core/modules/rest/src/Tests/AuthTest.php @@ -8,7 +8,6 @@ namespace Drupal\rest\Tests; use Drupal\Core\Url; -use Drupal\rest\Tests\RESTTestBase; /** * Tests authentication provider restrictions. diff --git a/core/modules/rest/src/Tests/RESTTestBase.php b/core/modules/rest/src/Tests/RESTTestBase.php index b6eb46a77..db7d1236e 100644 --- a/core/modules/rest/src/Tests/RESTTestBase.php +++ b/core/modules/rest/src/Tests/RESTTestBase.php @@ -7,7 +7,6 @@ namespace Drupal\rest\Tests; -use Drupal\Component\Utility\SafeMarkup; use Drupal\node\NodeInterface; use Drupal\simpletest\WebTestBase; diff --git a/core/modules/rest/src/Tests/ReadTest.php b/core/modules/rest/src/Tests/ReadTest.php index c59d64f68..eb3f22295 100644 --- a/core/modules/rest/src/Tests/ReadTest.php +++ b/core/modules/rest/src/Tests/ReadTest.php @@ -9,7 +9,6 @@ use Drupal\Component\Serialization\Json; use Drupal\Core\Url; -use Drupal\rest\Tests\RESTTestBase; /** * Tests the retrieval of resources. diff --git a/core/modules/rest/src/Tests/UpdateTest.php b/core/modules/rest/src/Tests/UpdateTest.php index 2081012d4..a15d8f785 100644 --- a/core/modules/rest/src/Tests/UpdateTest.php +++ b/core/modules/rest/src/Tests/UpdateTest.php @@ -8,7 +8,6 @@ namespace Drupal\rest\Tests; use Drupal\Component\Serialization\Json; -use Drupal\rest\Tests\RESTTestBase; /** * Tests the update of resources. diff --git a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php index 8fdbec46d..5f378ee2f 100644 --- a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php +++ b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php @@ -7,7 +7,6 @@ namespace Drupal\rest\Tests\Views; -use Drupal\Component\Utility\Html; use Drupal\Core\Cache\Cache; use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\entity_test\Entity\EntityTest; diff --git a/core/modules/search/src/Controller/SearchController.php b/core/modules/search/src/Controller/SearchController.php index f108bcdaa..08932593e 100644 --- a/core/modules/search/src/Controller/SearchController.php +++ b/core/modules/search/src/Controller/SearchController.php @@ -7,9 +7,7 @@ namespace Drupal\search\Controller; -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheableDependencyInterface; -use Drupal\Core\Config\ConfigFactory; use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Render\RendererInterface; use Drupal\search\SearchPageInterface; diff --git a/core/modules/search/src/Entity/SearchPage.php b/core/modules/search/src/Entity/SearchPage.php index 8991cde91..e2c21bb72 100644 --- a/core/modules/search/src/Entity/SearchPage.php +++ b/core/modules/search/src/Entity/SearchPage.php @@ -10,7 +10,6 @@ use Drupal\Core\Config\Entity\ConfigEntityBase; use Drupal\Core\Config\Entity\ConfigEntityInterface; use Drupal\Core\Entity\EntityStorageInterface; -use Drupal\Component\Plugin\ConfigurablePluginInterface; use Drupal\Core\Entity\EntityWithPluginCollectionInterface; use Drupal\search\Plugin\SearchIndexingInterface; use Drupal\search\Plugin\SearchPluginCollection; diff --git a/core/modules/search/src/Plugin/Block/SearchBlock.php b/core/modules/search/src/Plugin/Block/SearchBlock.php index 955929148..799a9c542 100644 --- a/core/modules/search/src/Plugin/Block/SearchBlock.php +++ b/core/modules/search/src/Plugin/Block/SearchBlock.php @@ -10,7 +10,6 @@ use Drupal\Core\Access\AccessResult; use Drupal\Core\Session\AccountInterface; use Drupal\Core\Block\BlockBase; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Provides a 'Search form' block. diff --git a/core/modules/search/src/SearchQuery.php b/core/modules/search/src/SearchQuery.php index 164aa3b18..cf66820e2 100644 --- a/core/modules/search/src/SearchQuery.php +++ b/core/modules/search/src/SearchQuery.php @@ -12,7 +12,6 @@ use Drupal\Component\Utility\Unicode; use Drupal\Core\Database\Query\SelectExtender; use Drupal\Core\Database\Query\SelectInterface; -use Drupal\Core\Database\StatementEmpty; /** * Performs a query on the full-text search index for a word or words. diff --git a/core/modules/serialization/src/Normalizer/ComplexDataNormalizer.php b/core/modules/serialization/src/Normalizer/ComplexDataNormalizer.php index a2c96979d..00774133f 100644 --- a/core/modules/serialization/src/Normalizer/ComplexDataNormalizer.php +++ b/core/modules/serialization/src/Normalizer/ComplexDataNormalizer.php @@ -7,8 +7,6 @@ namespace Drupal\serialization\Normalizer; -use Symfony\Component\Serializer\Exception\RuntimeException; - /** * Converts the Drupal entity object structures to a normalized array. * diff --git a/core/modules/serialization/src/Normalizer/ListNormalizer.php b/core/modules/serialization/src/Normalizer/ListNormalizer.php index 4fc2d00e9..fed97904a 100644 --- a/core/modules/serialization/src/Normalizer/ListNormalizer.php +++ b/core/modules/serialization/src/Normalizer/ListNormalizer.php @@ -7,8 +7,6 @@ namespace Drupal\serialization\Normalizer; -use Symfony\Component\Serializer\Exception\RuntimeException; - /** * Converts list objects to arrays. * diff --git a/core/modules/serialization/src/Normalizer/TypedDataNormalizer.php b/core/modules/serialization/src/Normalizer/TypedDataNormalizer.php index 69f9aeb63..ca5524694 100644 --- a/core/modules/serialization/src/Normalizer/TypedDataNormalizer.php +++ b/core/modules/serialization/src/Normalizer/TypedDataNormalizer.php @@ -7,8 +7,6 @@ namespace Drupal\serialization\Normalizer; -use Symfony\Component\Serializer\Exception\RuntimeException; - /** * Converts typed data objects to arrays. */ diff --git a/core/modules/serialization/src/Tests/EntitySerializationTest.php b/core/modules/serialization/src/Tests/EntitySerializationTest.php index 3a9daf84a..1dbc51ce0 100644 --- a/core/modules/serialization/src/Tests/EntitySerializationTest.php +++ b/core/modules/serialization/src/Tests/EntitySerializationTest.php @@ -7,9 +7,7 @@ namespace Drupal\serialization\Tests; -use Drupal\Core\Language\LanguageInterface; use Drupal\Component\Utility\SafeMarkup; -use Drupal\user\Entity\User; /** * Tests that entities can be serialized to supported core formats. diff --git a/core/modules/shortcut/src/Controller/ShortcutController.php b/core/modules/shortcut/src/Controller/ShortcutController.php index 5e4bc68b3..f9480f8a7 100644 --- a/core/modules/shortcut/src/Controller/ShortcutController.php +++ b/core/modules/shortcut/src/Controller/ShortcutController.php @@ -10,7 +10,6 @@ use Drupal\Core\Controller\ControllerBase; use Drupal\shortcut\ShortcutSetInterface; use Drupal\shortcut\ShortcutInterface; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Provides route responses for taxonomy.module. diff --git a/core/modules/shortcut/src/Controller/ShortcutSetController.php b/core/modules/shortcut/src/Controller/ShortcutSetController.php index 6a30d7ca2..56b4f555c 100644 --- a/core/modules/shortcut/src/Controller/ShortcutSetController.php +++ b/core/modules/shortcut/src/Controller/ShortcutSetController.php @@ -11,7 +11,6 @@ use Drupal\Core\Path\PathValidatorInterface; use Drupal\shortcut\ShortcutSetInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; diff --git a/core/modules/shortcut/src/Form/SetCustomize.php b/core/modules/shortcut/src/Form/SetCustomize.php index 31a574fbc..44c0b66bb 100644 --- a/core/modules/shortcut/src/Form/SetCustomize.php +++ b/core/modules/shortcut/src/Form/SetCustomize.php @@ -8,10 +8,8 @@ namespace Drupal\shortcut\Form; use Drupal\Core\Entity\EntityForm; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Element; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Builds the shortcut set customize form. diff --git a/core/modules/shortcut/src/Form/SwitchShortcutSet.php b/core/modules/shortcut/src/Form/SwitchShortcutSet.php index 9faa922b7..e27da6d0f 100644 --- a/core/modules/shortcut/src/Form/SwitchShortcutSet.php +++ b/core/modules/shortcut/src/Form/SwitchShortcutSet.php @@ -9,7 +9,6 @@ use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Routing\RouteMatchInterface; use Drupal\shortcut\Entity\ShortcutSet; use Drupal\shortcut\ShortcutSetStorageInterface; use Drupal\user\UserInterface; diff --git a/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php b/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php index a63cf6fcc..a33d8cde1 100644 --- a/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php +++ b/core/modules/shortcut/src/Plugin/migrate/destination/EntityShortcutSet.php @@ -8,7 +8,6 @@ namespace Drupal\shortcut\Plugin\migrate\destination; use Drupal\migrate\Row; -use Drupal\Core\Entity\EntityInterface; use Drupal\migrate\Plugin\migrate\destination\EntityConfigBase; /** diff --git a/core/modules/simpletest/css/simpletest.module.css b/core/modules/simpletest/css/simpletest.module.css index 71f7eea13..c0079b6ec 100644 --- a/core/modules/simpletest/css/simpletest.module.css +++ b/core/modules/simpletest/css/simpletest.module.css @@ -46,24 +46,28 @@ div.simpletest-pass { color: #981010; } +tr.simpletest-pass, tr.simpletest-pass.odd { background-color: #b6ffb6; } tr.simpletest-pass.even { background-color: #9bff9b; } +tr.simpletest-fail, tr.simpletest-fail.odd { background-color: #ffc9c9; } tr.simpletest-fail.even { background-color: #ffacac; } +tr.simpletest-exception, tr.simpletest-exception.odd { background-color: #f4ea71; } tr.simpletest-exception.even { background-color: #f5e742; } +tr.simpletest-debug, tr.simpletest-debug.odd { background-color: #eee; } diff --git a/core/modules/simpletest/simpletest.js b/core/modules/simpletest/simpletest.js index ed67ff504..dfe5fba3c 100644 --- a/core/modules/simpletest/simpletest.js +++ b/core/modules/simpletest/simpletest.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Collapses table rows followed by group rows on the test listing page. @@ -83,7 +83,7 @@ * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach - * Attaches the filter behavior the the text input element. + * Attaches the filter behavior to the text input element. */ Drupal.behaviors.simpletestTableFilterByText = { attach: function (context) { diff --git a/core/modules/simpletest/simpletest.module b/core/modules/simpletest/simpletest.module index 57b7f080f..7a0638695 100644 --- a/core/modules/simpletest/simpletest.module +++ b/core/modules/simpletest/simpletest.module @@ -2,7 +2,6 @@ use Drupal\Core\Asset\AttachedAssetsInterface; use Drupal\Core\Database\Database; -use Drupal\Core\Extension\ExtensionDiscovery; use Drupal\Core\Render\Element; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\simpletest\TestBase; @@ -179,7 +178,9 @@ function simpletest_run_tests($test_list) { function simpletest_run_phpunit_tests($test_id, array $unescaped_test_classnames) { $phpunit_file = simpletest_phpunit_xml_filepath($test_id); $ret = simpletest_phpunit_run_command($unescaped_test_classnames, $phpunit_file); - if ($ret) { + // A return value of 0 = passed test, 1 = failed test, > 1 indicates segfault + // timeout, or other type of failure. + if ($ret > 1) { // Something broke during the execution of phpunit. // Return an error record of all failed classes. $rows[] = [ diff --git a/core/modules/simpletest/src/BrowserTestBase.php b/core/modules/simpletest/src/BrowserTestBase.php index e15078ca5..ed64f0833 100644 --- a/core/modules/simpletest/src/BrowserTestBase.php +++ b/core/modules/simpletest/src/BrowserTestBase.php @@ -182,6 +182,33 @@ abstract class BrowserTestBase extends \PHPUnit_Framework_TestCase { */ protected $customTranslations; + /* + * Mink class for the default driver to use. + * + * Shoud be a fully qualified class name that implements + * Behat\Mink\Driver\DriverInterface. + * + * Value can be overridden using the environment variable MINK_DRIVER_CLASS. + * + * @var string. + */ + protected $minkDefaultDriverClass = '\Behat\Mink\Driver\GoutteDriver'; + + /* + * Mink default driver params. + * + * If it's an array its contents are used as constructor params when default + * Mink driver class is instantiated. + * + * Can be overridden using the environment variable MINK_DRIVER_ARGS. In this + * case that variable should be a JSON array, for example: + * '["firefox", null, "http://localhost:4444/wd/hub"]'. + * + * + * @var array + */ + protected $minkDefaultDriverArgs; + /** * Mink session manager. * @@ -193,15 +220,51 @@ abstract class BrowserTestBase extends \PHPUnit_Framework_TestCase { * Initializes Mink sessions. */ protected function initMink() { - $driver = new GoutteDriver(); + $driver = $this->getDefaultDriverInstance(); $session = new Session($driver); $this->mink = new Mink(); - $this->mink->registerSession('goutte', $session); - $this->mink->setDefaultSessionName('goutte'); + $this->mink->registerSession('default', $session); + $this->mink->setDefaultSessionName('default'); $this->registerSessions(); return $session; } + /** + * Gets an instance of the default Mink driver. + * + * @return Behat\Mink\Driver\DriverInterface + * Instance of default Mink driver. + * + * @throws \InvalidArgumentException + * When provided default Mink driver class can't be instantiated. + */ + protected function getDefaultDriverInstance() { + // Get default driver params from environment if availables. + if ($arg_json = getenv('MINK_DRIVER_ARGS')) { + $this->minkDefaultDriverArgs = json_decode($arg_json); + } + + // Get and check default driver class from environment if availables. + if ($minkDriverClass = getenv('MINK_DRIVER_CLASS')) { + if (class_exists($minkDriverClass)) { + $this->minkDefaultDriverClass = $minkDriverClass; + } + else { + throw new \InvalidArgumentException("Can't instantiate provided $minkDriverClass class by environment as default driver class."); + } + } + + if (is_array($this->minkDefaultDriverArgs)) { + // Use ReflectionClass to instantiate class with received params. + $reflector = new ReflectionClass($this->minkDefaultDriverClass); + $driver = $reflector->newInstanceArgs($this->minkDefaultDriverArgs); + } + else { + $driver = new $this->minkDefaultDriverClass(); + } + return $driver; + } + /** * Registers additional Mink sessions. * @@ -1194,7 +1257,7 @@ protected function prepareRequestForGenerator($clean_urls = TRUE, $override_serv $server = array_merge($server, $override_server_vars); $request = Request::create($request_path, 'GET', array(), array(), array(), $server); - // Ensure the the request time is REQUEST_TIME to ensure that API calls + // Ensure the request time is REQUEST_TIME to ensure that API calls // in the test use the right timestamp. $request->server->set('REQUEST_TIME', REQUEST_TIME); $this->container->get('request_stack')->push($request); diff --git a/core/modules/simpletest/src/Form/SimpletestResultsForm.php b/core/modules/simpletest/src/Form/SimpletestResultsForm.php index 58e9d2cd1..c5bf35223 100644 --- a/core/modules/simpletest/src/Form/SimpletestResultsForm.php +++ b/core/modules/simpletest/src/Form/SimpletestResultsForm.php @@ -7,7 +7,6 @@ namespace Drupal\simpletest\Form; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Database\Connection; use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormState; diff --git a/core/modules/simpletest/src/Form/SimpletestTestForm.php b/core/modules/simpletest/src/Form/SimpletestTestForm.php index f63e8bed5..c325a8ab5 100644 --- a/core/modules/simpletest/src/Form/SimpletestTestForm.php +++ b/core/modules/simpletest/src/Form/SimpletestTestForm.php @@ -7,7 +7,6 @@ namespace Drupal\simpletest\Form; -use Drupal\Component\Utility\SortArray; use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\RendererInterface; diff --git a/core/modules/simpletest/src/KernelTestBase.php b/core/modules/simpletest/src/KernelTestBase.php index f11b5670a..56c800e46 100644 --- a/core/modules/simpletest/src/KernelTestBase.php +++ b/core/modules/simpletest/src/KernelTestBase.php @@ -322,6 +322,7 @@ public function containerBuild(ContainerBuilder $container) { $container ->register('simpletest.config_schema_checker', 'Drupal\Core\Config\Testing\ConfigSchemaChecker') ->addArgument(new Reference('config.typed')) + ->addArgument($this->getConfigSchemaExclusions()) ->addTag('event_subscriber'); } diff --git a/core/modules/simpletest/src/TestBase.php b/core/modules/simpletest/src/TestBase.php index 22709580f..a4c115f10 100644 --- a/core/modules/simpletest/src/TestBase.php +++ b/core/modules/simpletest/src/TestBase.php @@ -9,7 +9,6 @@ use Drupal\Component\Render\MarkupInterface; use Drupal\Component\Utility\Crypt; -use Drupal\Component\Utility\Random; use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Database\Database; use Drupal\Core\Config\ConfigImporter; @@ -295,6 +294,22 @@ abstract class TestBase { */ protected $strictConfigSchema = TRUE; + /** + * An array of config object names that are excluded from schema checking. + * + * @var string[] + */ + protected static $configSchemaCheckerExclusions = array( + // Following are used to test lack of or partial schema. Where partial + // schema is provided, that is explicitly tested in specific tests. + 'config_schema_test.noschema', + 'config_schema_test.someschema', + 'config_schema_test.schema_data_types', + 'config_schema_test.no_schema_data_types', + // Used to test application of schema to filtering of configuration. + 'config_test.dynamic.system', + ); + /** * HTTP authentication method (specified as a CURLAUTH_* constant). * @@ -1586,4 +1601,23 @@ public function getTempFilesDirectory() { return $this->tempFilesDirectory; } + /** + * Gets the config schema exclusions for this test. + * + * @return string[] + * An array of config object names that are excluded from schema checking. + */ + protected function getConfigSchemaExclusions() { + $class = get_class($this); + $exceptions = []; + while ($class) { + if (property_exists($class, 'configSchemaCheckerExclusions')) { + $exceptions = array_merge($exceptions, $class::$configSchemaCheckerExclusions); + } + $class = get_parent_class($class); + } + // Filter out any duplicates. + return array_unique($exceptions); + } + } diff --git a/core/modules/simpletest/src/WebTestBase.php b/core/modules/simpletest/src/WebTestBase.php index 5b62c50d5..4de845d96 100644 --- a/core/modules/simpletest/src/WebTestBase.php +++ b/core/modules/simpletest/src/WebTestBase.php @@ -680,14 +680,11 @@ protected function setUp() { // Initialize user 1 and session name. $this->initUserSession(); - // Get parameters for install_drupal() before removing global variables. - $parameters = $this->installParameters(); - // Prepare the child site settings. $this->prepareSettings(); // Execute the non-interactive installer. - $this->doInstall($parameters); + $this->doInstall(); // Import new settings.php written by the installer. $this->initSettings(); @@ -711,12 +708,9 @@ protected function setUp() { /** * Execute the non-interactive installer. * - * @param array $parameters - * Parameters to pass to install_drupal(). - * * @see install_drupal() */ - protected function doInstall(array $parameters = []) { + protected function doInstall() { require_once DRUPAL_ROOT . '/core/includes/install.core.inc'; install_drupal($this->classLoader, $this->installParameters()); } @@ -785,7 +779,7 @@ protected function prepareSettings() { $services = $yaml->parse($content); $services['services']['simpletest.config_schema_checker'] = [ 'class' => 'Drupal\Core\Config\Testing\ConfigSchemaChecker', - 'arguments' => ['@config.typed'], + 'arguments' => ['@config.typed', $this->getConfigSchemaExclusions()], 'tags' => [['name' => 'event_subscriber']] ]; file_put_contents($directory . '/services.yml', $yaml->dump($services)); @@ -812,6 +806,10 @@ protected function initSettings() { // TestBase::restoreEnvironment() will delete the entire site directory. // Not using File API; a potential error must trigger a PHP warning. chmod(DRUPAL_ROOT . '/' . $this->siteDirectory, 0777); + + // During tests, cacheable responses should get the debugging cacheability + // headers by default. + $this->setContainerParameter('http.response.debug_cacheability_headers', TRUE); } /** @@ -2921,7 +2919,7 @@ protected function prepareRequestForGenerator($clean_urls = TRUE, $override_serv $server = array_merge($server, $override_server_vars); $request = Request::create($request_path, 'GET', array(), array(), array(), $server); - // Ensure the the request time is REQUEST_TIME to ensure that API calls + // Ensure the request time is REQUEST_TIME to ensure that API calls // in the test use the right timestamp. $request->server->set('REQUEST_TIME', REQUEST_TIME); $this->container->get('request_stack')->push($request); @@ -3019,4 +3017,18 @@ protected function assertNoCacheTag($cache_tag) { $this->assertFalse(in_array($cache_tag, $cache_tags), "'" . $cache_tag . "' is absent in the X-Drupal-Cache-Tags header."); } + /** + * Enables/disables the cacheability headers. + * + * Sets the http.response.debug_cacheability_headers container parameter. + * + * @param bool $value + * (optional) Whether the debugging cacheability headers should be sent. + */ + protected function setHttpResponseDebugCacheabilityHeaders($value = TRUE) { + $this->setContainerParameter('http.response.debug_cacheability_headers', $value); + $this->rebuildContainer(); + $this->resetAll(); + } + } diff --git a/core/modules/simpletest/tests/fixtures/simpletest_phpunit_run_command_test.php b/core/modules/simpletest/tests/fixtures/simpletest_phpunit_run_command_test.php index bfed619e6..872753e84 100644 --- a/core/modules/simpletest/tests/fixtures/simpletest_phpunit_run_command_test.php +++ b/core/modules/simpletest/tests/fixtures/simpletest_phpunit_run_command_test.php @@ -15,7 +15,7 @@ class SimpletestPhpunitRunCommandTestWillDie extends UnitTestCase { public function testWillDie() { if (getenv('SimpletestPhpunitRunCommandTestWillDie') === 'fail') { - exit(1); + exit(2); } } } diff --git a/core/modules/statistics/statistics.js b/core/modules/statistics/statistics.js index f892dd403..572cd456f 100644 --- a/core/modules/statistics/statistics.js +++ b/core/modules/statistics/statistics.js @@ -5,11 +5,11 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; $(document).ready(function () { $.ajax({ - type: "POST", + type: 'POST', cache: false, url: drupalSettings.statistics.url, data: drupalSettings.statistics.data diff --git a/core/modules/system/css/components/tabledrag.module.css b/core/modules/system/css/components/tabledrag.module.css index 5b872cb0b..a4f0f2008 100644 --- a/core/modules/system/css/components/tabledrag.module.css +++ b/core/modules/system/css/components/tabledrag.module.css @@ -47,25 +47,25 @@ a.tabledrag-handle:hover .handle, a.tabledrag-handle:focus .handle { background-image: url(../../../../misc/icons/000000/move.svg); } -.touch .draggable td { +.touchevents .draggable td { padding: 0 10px; } -.touch .draggable .menu-item__link { +.touchevents .draggable .menu-item__link { display: inline-block; padding: 10px 0; } -.touch a.tabledrag-handle { +.touchevents a.tabledrag-handle { height: 44px; width: 40px; } -.touch a.tabledrag-handle .handle { +.touchevents a.tabledrag-handle .handle { background-position: 40% 19px; /* LTR */ height: 21px; } [dir="rtl"] .touch a.tabledrag-handle .handle { background-position: right 40% top 19px; } -.touch .draggable.drag a.tabledrag-handle .handle { +.touchevents .draggable.drag a.tabledrag-handle .handle { background-position: 50% -32px; } .tabledrag-toggle-weight-wrapper { diff --git a/core/modules/system/js/system.date.js b/core/modules/system/js/system.date.js index 75a7869b3..678614d98 100644 --- a/core/modules/system/js/system.date.js +++ b/core/modules/system/js/system.date.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; var dateFormats = drupalSettings.dateFormats; diff --git a/core/modules/system/js/system.js b/core/modules/system/js/system.js index cbfe4ea7b..82f0de668 100644 --- a/core/modules/system/js/system.js +++ b/core/modules/system/js/system.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; // Cache IDs in an array for ease of use. var ids = []; diff --git a/core/modules/system/js/system.modules.js b/core/modules/system/js/system.modules.js index f9c08e476..d47ca7031 100644 --- a/core/modules/system/js/system.modules.js +++ b/core/modules/system/js/system.modules.js @@ -5,7 +5,7 @@ (function ($, Drupal, debounce) { - "use strict"; + 'use strict'; /** * Filters the module list table by a text input search string. diff --git a/core/modules/system/src/Controller/SystemController.php b/core/modules/system/src/Controller/SystemController.php index 8f6b58aa1..84e6ac57c 100644 --- a/core/modules/system/src/Controller/SystemController.php +++ b/core/modules/system/src/Controller/SystemController.php @@ -7,7 +7,6 @@ namespace Drupal\system\Controller; -use Drupal\Component\Serialization\Json; use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Entity\Query\QueryFactory; diff --git a/core/modules/system/src/Entity/Menu.php b/core/modules/system/src/Entity/Menu.php index fa738f309..df2b08d7a 100644 --- a/core/modules/system/src/Entity/Menu.php +++ b/core/modules/system/src/Entity/Menu.php @@ -8,7 +8,6 @@ namespace Drupal\system\Entity; use Drupal\Core\Config\Entity\ConfigEntityBase; -use Drupal\Core\Entity\EntityStorageInterface; use Drupal\system\MenuInterface; /** diff --git a/core/modules/system/src/EventSubscriber/ConfigCacheTag.php b/core/modules/system/src/EventSubscriber/ConfigCacheTag.php index 7705056bd..1df8423a4 100644 --- a/core/modules/system/src/EventSubscriber/ConfigCacheTag.php +++ b/core/modules/system/src/EventSubscriber/ConfigCacheTag.php @@ -7,7 +7,6 @@ namespace Drupal\system\EventSubscriber; -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheTagsInvalidatorInterface; use Drupal\Core\Config\ConfigCrudEvent; use Drupal\Core\Config\ConfigEvents; diff --git a/core/modules/system/src/Form/ModulesListForm.php b/core/modules/system/src/Form/ModulesListForm.php index e86ba0a60..e8a6ceafd 100644 --- a/core/modules/system/src/Form/ModulesListForm.php +++ b/core/modules/system/src/Form/ModulesListForm.php @@ -10,7 +10,6 @@ use Drupal\Component\Utility\Unicode; use Drupal\Core\Config\PreExistingConfigException; use Drupal\Core\Config\UnmetDependenciesException; -use Drupal\Core\Controller\TitleResolverInterface; use Drupal\Core\Access\AccessManagerInterface; use Drupal\Core\Extension\Extension; use Drupal\Core\Extension\ModuleHandlerInterface; @@ -18,15 +17,11 @@ use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\KeyValueStore\KeyValueStoreExpirableInterface; -use Drupal\Core\Menu\MenuLinkManagerInterface; use Drupal\Core\Render\Element; -use Drupal\Core\Routing\RouteMatchInterface; -use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\Session\AccountInterface; use Drupal\user\PermissionHandlerInterface; use Drupal\Core\Url; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Provides module installation interface. diff --git a/core/modules/system/src/Form/ModulesUninstallConfirmForm.php b/core/modules/system/src/Form/ModulesUninstallConfirmForm.php index 0208e7c49..69e32396d 100644 --- a/core/modules/system/src/Form/ModulesUninstallConfirmForm.php +++ b/core/modules/system/src/Form/ModulesUninstallConfirmForm.php @@ -14,7 +14,6 @@ use Drupal\Core\Form\ConfirmFormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; -use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\DependencyInjection\ContainerInterface; use Drupal\Core\KeyValueStore\KeyValueStoreExpirableInterface; diff --git a/core/modules/system/src/Form/ThemeSettingsForm.php b/core/modules/system/src/Form/ThemeSettingsForm.php index 978ca80e5..395c74359 100644 --- a/core/modules/system/src/Form/ThemeSettingsForm.php +++ b/core/modules/system/src/Form/ThemeSettingsForm.php @@ -14,7 +14,6 @@ use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\File\MimeType\MimeTypeGuesserInterface; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; -use Drupal\Core\Cache\Cache; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Form\ConfigFormBase; @@ -429,34 +428,32 @@ public function submitForm(array &$form, FormStateInterface $form_state) { // If the user uploaded a new logo or favicon, save it to a permanent location // and use it in place of the default theme-provided file. - if ($this->moduleHandler->moduleExists('file')) { - if ($file = $values['logo_upload']) { - $filename = file_unmanaged_copy($file->getFileUri()); - $values['default_logo'] = 0; - $values['logo_path'] = $filename; - $values['toggle_logo'] = 1; - } - if ($file = $values['favicon_upload']) { - $filename = file_unmanaged_copy($file->getFileUri()); - $values['default_favicon'] = 0; - $values['favicon_path'] = $filename; - $values['toggle_favicon'] = 1; - } - unset($values['logo_upload']); - unset($values['favicon_upload']); + if (!empty($values['logo_upload'])) { + $filename = file_unmanaged_copy($values['logo_upload']->getFileUri()); + $values['default_logo'] = 0; + $values['logo_path'] = $filename; + $values['toggle_logo'] = 1; + } + if (!empty($values['favicon_upload'])) { + $filename = file_unmanaged_copy($values['favicon_upload']->getFileUri()); + $values['default_favicon'] = 0; + $values['favicon_path'] = $filename; + $values['toggle_favicon'] = 1; + } + unset($values['logo_upload']); + unset($values['favicon_upload']); - // If the user entered a path relative to the system files directory for - // a logo or favicon, store a public:// URI so the theme system can handle it. - if (!empty($values['logo_path'])) { - $values['logo_path'] = $this->validatePath($values['logo_path']); - } - if (!empty($values['favicon_path'])) { - $values['favicon_path'] = $this->validatePath($values['favicon_path']); - } + // If the user entered a path relative to the system files directory for + // a logo or favicon, store a public:// URI so the theme system can handle it. + if (!empty($values['logo_path'])) { + $values['logo_path'] = $this->validatePath($values['logo_path']); + } + if (!empty($values['favicon_path'])) { + $values['favicon_path'] = $this->validatePath($values['favicon_path']); + } - if (empty($values['default_favicon']) && !empty($values['favicon_path'])) { - $values['favicon_mimetype'] = $this->mimeTypeGuesser->guess($values['favicon_path']); - } + if (empty($values['default_favicon']) && !empty($values['favicon_path'])) { + $values['favicon_mimetype'] = $this->mimeTypeGuesser->guess($values['favicon_path']); } theme_settings_convert_to_config($values, $config)->save(); diff --git a/core/modules/system/src/Plugin/Block/SystemBrandingBlock.php b/core/modules/system/src/Plugin/Block/SystemBrandingBlock.php index c45b739cb..3adcd1896 100644 --- a/core/modules/system/src/Plugin/Block/SystemBrandingBlock.php +++ b/core/modules/system/src/Plugin/Block/SystemBrandingBlock.php @@ -7,13 +7,11 @@ namespace Drupal\system\Plugin\Block; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Block\BlockBase; use Drupal\Core\Cache\Cache; use Drupal\Core\Config\ConfigFactoryInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; -use Drupal\Component\Utility\Xss; use Drupal\Core\Url; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/system/src/Plugin/Block/SystemMainBlock.php b/core/modules/system/src/Plugin/Block/SystemMainBlock.php index 92475ab14..2bb2479e1 100644 --- a/core/modules/system/src/Plugin/Block/SystemMainBlock.php +++ b/core/modules/system/src/Plugin/Block/SystemMainBlock.php @@ -9,8 +9,6 @@ use Drupal\Core\Block\BlockBase; use Drupal\Core\Block\MainContentBlockPluginInterface; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Form\FormStateInterface; /** * Provides a 'Main page content' block. diff --git a/core/modules/system/src/Plugin/Block/SystemMessagesBlock.php b/core/modules/system/src/Plugin/Block/SystemMessagesBlock.php index c1d78fb84..17ab4e491 100644 --- a/core/modules/system/src/Plugin/Block/SystemMessagesBlock.php +++ b/core/modules/system/src/Plugin/Block/SystemMessagesBlock.php @@ -10,7 +10,6 @@ use Drupal\Core\Block\BlockBase; use Drupal\Core\Block\MessagesBlockPluginInterface; use Drupal\Core\Cache\Cache; -use Drupal\Core\Form\FormStateInterface; /** * Provides a block to display the messages. diff --git a/core/modules/system/src/Plugin/Block/SystemPoweredByBlock.php b/core/modules/system/src/Plugin/Block/SystemPoweredByBlock.php index db76b802e..25ea051ef 100644 --- a/core/modules/system/src/Plugin/Block/SystemPoweredByBlock.php +++ b/core/modules/system/src/Plugin/Block/SystemPoweredByBlock.php @@ -8,8 +8,6 @@ namespace Drupal\system\Plugin\Block; use Drupal\Core\Block\BlockBase; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Form\FormStateInterface; /** * Provides a 'Powered by Drupal' block. diff --git a/core/modules/system/src/Plugin/Condition/RequestPath.php b/core/modules/system/src/Plugin/Condition/RequestPath.php index 4cd92de72..074d42f0e 100644 --- a/core/modules/system/src/Plugin/Condition/RequestPath.php +++ b/core/modules/system/src/Plugin/Condition/RequestPath.php @@ -14,7 +14,6 @@ use Drupal\Core\Path\CurrentPathStack; use Drupal\Core\Path\PathMatcherInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; -use Drupal\Core\StringTranslation\StringTranslationTrait; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/core/modules/system/src/SystemManager.php b/core/modules/system/src/SystemManager.php index 1ea232bb7..f61fd4153 100644 --- a/core/modules/system/src/SystemManager.php +++ b/core/modules/system/src/SystemManager.php @@ -11,8 +11,6 @@ use Drupal\Core\Menu\MenuLinkTreeInterface; use Drupal\Core\Menu\MenuLinkInterface; use Drupal\Core\Menu\MenuTreeParameters; -use Symfony\Cmf\Component\Routing\RouteObjectInterface; -use Drupal\Core\Database\Connection; use Drupal\Core\Extension\ModuleHandlerInterface; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/core/modules/system/src/Tests/Block/SystemMenuBlockTest.php b/core/modules/system/src/Tests/Block/SystemMenuBlockTest.php index 25e5dc1f6..e10a6af85 100644 --- a/core/modules/system/src/Tests/Block/SystemMenuBlockTest.php +++ b/core/modules/system/src/Tests/Block/SystemMenuBlockTest.php @@ -295,7 +295,7 @@ public function testConfigLevelDepth() { * Converts the result of MenuLinkTree::build() in a "menu link ID tree". * * @param array $build - * The return value of of MenuLinkTree::build() + * The return value of MenuLinkTree::build() * * @return array * The "menu link ID tree" representation of the given render array. diff --git a/core/modules/system/src/Tests/Cache/ApcuBackendUnitTest.php b/core/modules/system/src/Tests/Cache/ApcuBackendUnitTest.php index fcb55779c..fafac7ed4 100644 --- a/core/modules/system/src/Tests/Cache/ApcuBackendUnitTest.php +++ b/core/modules/system/src/Tests/Cache/ApcuBackendUnitTest.php @@ -87,6 +87,15 @@ public function testSetGet() { return; } parent::testSetGet(); + + // Make sure entries are permanent (i.e. no TTL). + $backend = $this->getCacheBackend($this->getTestBin()); + $key = $backend->getApcuKey('TEST8'); + foreach (new \APCIterator('user', '/^' . $key . '/') as $item) { + $this->assertEqual(0, $item['ttl']); + $found = TRUE; + } + $this->assertTrue($found); } /** diff --git a/core/modules/system/src/Tests/Common/AttachedAssetsTest.php b/core/modules/system/src/Tests/Common/AttachedAssetsTest.php index 7bbcafbe5..7440d995d 100644 --- a/core/modules/system/src/Tests/Common/AttachedAssetsTest.php +++ b/core/modules/system/src/Tests/Common/AttachedAssetsTest.php @@ -9,7 +9,6 @@ use Drupal\Component\Serialization\Json; use Drupal\Component\Utility\Unicode; -use Drupal\Component\Utility\Crypt; use Drupal\Core\Asset\AttachedAssets; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/system/src/Tests/Common/PageRenderTest.php b/core/modules/system/src/Tests/Common/PageRenderTest.php index ec16e3621..1b4c387d7 100644 --- a/core/modules/system/src/Tests/Common/PageRenderTest.php +++ b/core/modules/system/src/Tests/Common/PageRenderTest.php @@ -7,7 +7,6 @@ namespace Drupal\system\Tests\Common; -use Drupal\Core\Render\MainContent\HtmlRenderer; use Drupal\simpletest\KernelTestBase; /** diff --git a/core/modules/system/src/Tests/Common/RenderTest.php b/core/modules/system/src/Tests/Common/RenderTest.php index df0278b82..98de2b548 100644 --- a/core/modules/system/src/Tests/Common/RenderTest.php +++ b/core/modules/system/src/Tests/Common/RenderTest.php @@ -7,10 +7,7 @@ namespace Drupal\system\Tests\Common; -use Drupal\Component\Serialization\Json; -use Drupal\Component\Utility\Html; use Drupal\Core\Render\Element; -use Drupal\Core\Url; use Drupal\simpletest\KernelTestBase; /** diff --git a/core/modules/system/src/Tests/Database/ConnectionUnitTest.php b/core/modules/system/src/Tests/Database/ConnectionUnitTest.php index 0593ce8c9..4327ac5e0 100644 --- a/core/modules/system/src/Tests/Database/ConnectionUnitTest.php +++ b/core/modules/system/src/Tests/Database/ConnectionUnitTest.php @@ -7,9 +7,7 @@ namespace Drupal\system\Tests\Database; -use Doctrine\Common\Reflection\StaticReflectionProperty; use Drupal\Core\Database\Database; -use Drupal\Core\Site\Settings; use Drupal\simpletest\KernelTestBase; /** diff --git a/core/modules/system/src/Tests/DrupalKernel/ServiceDestructionTest.php b/core/modules/system/src/Tests/DrupalKernel/ServiceDestructionTest.php index 68e28a2e8..339f7fef7 100644 --- a/core/modules/system/src/Tests/DrupalKernel/ServiceDestructionTest.php +++ b/core/modules/system/src/Tests/DrupalKernel/ServiceDestructionTest.php @@ -9,7 +9,6 @@ use Drupal\simpletest\KernelTestBase; use Symfony\Component\HttpFoundation\Response; -use Symfony\Component\HttpKernel\Event\PostResponseEvent; /** * Tests that services are correctly destructed. diff --git a/core/modules/system/src/Tests/Entity/ConfigEntityQueryTest.php b/core/modules/system/src/Tests/Entity/ConfigEntityQueryTest.php index a854df9f6..d3b779550 100644 --- a/core/modules/system/src/Tests/Entity/ConfigEntityQueryTest.php +++ b/core/modules/system/src/Tests/Entity/ConfigEntityQueryTest.php @@ -569,7 +569,7 @@ public function testDotted() { ->condition('array.level1.level2', 3) ->execute(); $this->assertResults(array('5')); - // Make sure that values on the wildcard level do not match if if there are + // Make sure that values on the wildcard level do not match if there are // sub-keys defined. This must not find anything even if entity 2 has a // top-level key number with value 41. $this->queryResults = $this->factory->get('config_query_test') diff --git a/core/modules/system/src/Tests/Entity/ContentEntityChangedTest.php b/core/modules/system/src/Tests/Entity/ContentEntityChangedTest.php index 6f7e69247..564245b67 100644 --- a/core/modules/system/src/Tests/Entity/ContentEntityChangedTest.php +++ b/core/modules/system/src/Tests/Entity/ContentEntityChangedTest.php @@ -390,7 +390,7 @@ public function testRevisionChanged() { $this->assertFalse( $this->getRevisionTranslationAffectedFlag($german), - 'Changed flag of of the German translation is not set for new revision without changes.' + 'Changed flag of the German translation is not set for new revision without changes.' ); $entity->setNewRevision(); diff --git a/core/modules/system/src/Tests/Entity/EntityFormTest.php b/core/modules/system/src/Tests/Entity/EntityFormTest.php index ffa5cca84..4b2647a5f 100644 --- a/core/modules/system/src/Tests/Entity/EntityFormTest.php +++ b/core/modules/system/src/Tests/Entity/EntityFormTest.php @@ -26,7 +26,7 @@ class EntityFormTest extends WebTestBase { protected function setUp() { parent::setUp(); - $web_user = $this->drupalCreateUser(array('administer entity_test content')); + $web_user = $this->drupalCreateUser(array('administer entity_test content', 'view test entity')); $this->drupalLogin($web_user); // Add a language. @@ -84,14 +84,14 @@ protected function doTestFormCRUD($entity_type) { $this->assertTrue($entity, format_string('%entity_type: Entity found in the database.', array('%entity_type' => $entity_type))); $edit['name[0][value]'] = $name2; - $this->drupalPostForm($entity_type . '/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm($entity_type . '/manage/' . $entity->id() . '/edit', $edit, t('Save')); $entity = $this->loadEntityByName($entity_type, $name1); $this->assertFalse($entity, format_string('%entity_type: The entity has been modified.', array('%entity_type' => $entity_type))); $entity = $this->loadEntityByName($entity_type, $name2); $this->assertTrue($entity, format_string('%entity_type: Modified entity found in the database.', array('%entity_type' => $entity_type))); $this->assertNotEqual($entity->name->value, $name1, format_string('%entity_type: The entity name has been modified.', array('%entity_type' => $entity_type))); - $this->drupalGet($entity_type . '/manage/' . $entity->id()); + $this->drupalGet($entity_type . '/manage/' . $entity->id() . '/edit'); $this->clickLink(t('Delete')); $this->drupalPostForm(NULL, array(), t('Delete')); $entity = $this->loadEntityByName($entity_type, $name2); @@ -125,12 +125,12 @@ protected function doTestMultilingualFormCRUD($entity_type_id) { $this->assertEqual($translated_entity->name->value, $name1_ro, format_string('%entity_type: The translation has been added.', array('%entity_type' => $entity_type_id))); $edit['name[0][value]'] = $name2_ro; - $this->drupalPostForm('ro/' . $entity_type_id . '/manage/' . $entity->id(), $edit, t('Save')); + $this->drupalPostForm('ro/' . $entity_type_id . '/manage/' . $entity->id() . '/edit', $edit, t('Save')); $translated_entity = $this->loadEntityByName($entity_type_id, $name1)->getTranslation('ro'); $this->assertTrue($translated_entity, format_string('%entity_type: Modified translation found in the database.', array('%entity_type' => $entity_type_id))); $this->assertEqual($translated_entity->name->value, $name2_ro, format_string('%entity_type: The name of the translation has been modified.', array('%entity_type' => $entity_type_id))); - $this->drupalGet('ro/' . $entity_type_id . '/manage/' . $entity->id()); + $this->drupalGet('ro/' . $entity_type_id . '/manage/' . $entity->id() . '/edit'); $this->clickLink(t('Delete')); $this->drupalPostForm(NULL, array(), t('Delete Romanian translation')); $entity = $this->loadEntityByName($entity_type_id, $name1); diff --git a/core/modules/system/src/Tests/Entity/EntityRevisionsTest.php b/core/modules/system/src/Tests/Entity/EntityRevisionsTest.php index 53f5288e2..39f04c32d 100644 --- a/core/modules/system/src/Tests/Entity/EntityRevisionsTest.php +++ b/core/modules/system/src/Tests/Entity/EntityRevisionsTest.php @@ -37,6 +37,7 @@ protected function setUp() { // Create and login user. $this->webUser = $this->drupalCreateUser(array( 'administer entity_test content', + 'view test entity', )); $this->drupalLogin($this->webUser); } @@ -110,7 +111,7 @@ protected function runRevisionsTests($entity_type) { // Confirm the correct revision text appears in the edit form. $entity = entity_load($entity_type, $entity->id->value); - $this->drupalGet($entity_type . '/manage/' . $entity->id->value); + $this->drupalGet($entity_type . '/manage/' . $entity->id->value . '/edit'); $this->assertFieldById('edit-name-0-value', $entity->name->value, format_string('%entity_type: Name matches in UI.', array('%entity_type' => $entity_type))); $this->assertFieldById('edit-field-test-text-0-value', $entity->field_test_text->value, format_string('%entity_type: Text matches in UI.', array('%entity_type' => $entity_type))); } diff --git a/core/modules/system/src/Tests/Entity/EntityTypeConstraintValidatorTest.php b/core/modules/system/src/Tests/Entity/EntityTypeConstraintValidatorTest.php index 3d6ecc67d..b9ebee288 100644 --- a/core/modules/system/src/Tests/Entity/EntityTypeConstraintValidatorTest.php +++ b/core/modules/system/src/Tests/Entity/EntityTypeConstraintValidatorTest.php @@ -7,7 +7,6 @@ namespace Drupal\system\Tests\Entity; -use Drupal\system\Tests\Entity\EntityUnitTestBase; use Drupal\system\Tests\TypedData; use Drupal\Core\TypedData\DataDefinition; diff --git a/core/modules/system/src/Tests/Form/ElementsTableSelectTest.php b/core/modules/system/src/Tests/Form/ElementsTableSelectTest.php index 22622e74d..f9ce925b5 100644 --- a/core/modules/system/src/Tests/Form/ElementsTableSelectTest.php +++ b/core/modules/system/src/Tests/Form/ElementsTableSelectTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Form\FormState; use Drupal\simpletest\WebTestBase; -use Drupal\Core\Form\FormStateInterface; /** * Tests the tableselect form element for expected behavior. diff --git a/core/modules/system/src/Tests/Path/UrlAlterFunctionalTest.php b/core/modules/system/src/Tests/Path/UrlAlterFunctionalTest.php index d9a8228f1..71915ac86 100644 --- a/core/modules/system/src/Tests/Path/UrlAlterFunctionalTest.php +++ b/core/modules/system/src/Tests/Path/UrlAlterFunctionalTest.php @@ -7,7 +7,6 @@ namespace Drupal\system\Tests\Path; -use Drupal\Core\Url; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/system/src/Tests/Theme/TableTest.php b/core/modules/system/src/Tests/Render/Element/TableTest.php similarity index 98% rename from core/modules/system/src/Tests/Theme/TableTest.php rename to core/modules/system/src/Tests/Render/Element/TableTest.php index a874a1111..725f339b6 100644 --- a/core/modules/system/src/Tests/Theme/TableTest.php +++ b/core/modules/system/src/Tests/Render/Element/TableTest.php @@ -2,10 +2,10 @@ /** * @file - * Contains \Drupal\system\Tests\Theme\TableTest. + * Contains \Drupal\system\Tests\Render\Element\TableTest. */ -namespace Drupal\system\Tests\Theme; +namespace Drupal\system\Tests\Render\Element; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/system/src/Tests/Routing/RouterPermissionTest.php b/core/modules/system/src/Tests/Routing/RouterPermissionTest.php index 048982c25..b3d5706b8 100644 --- a/core/modules/system/src/Tests/Routing/RouterPermissionTest.php +++ b/core/modules/system/src/Tests/Routing/RouterPermissionTest.php @@ -7,9 +7,7 @@ namespace Drupal\system\Tests\Routing; -use Drupal\Core\Routing\RequestHelper; use Drupal\simpletest\WebTestBase; -use Symfony\Component\Routing\Exception\ResourceNotFoundException; /** * Function Tests for the routing permission system. diff --git a/core/modules/system/src/Tests/Routing/RouterTest.php b/core/modules/system/src/Tests/Routing/RouterTest.php index 076d0cebe..5db3230e2 100644 --- a/core/modules/system/src/Tests/Routing/RouterTest.php +++ b/core/modules/system/src/Tests/Routing/RouterTest.php @@ -11,7 +11,6 @@ use Drupal\Core\EventSubscriber\MainContentViewSubscriber; use Drupal\Core\Language\LanguageInterface; use Drupal\simpletest\WebTestBase; -use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\Exception\RouteNotFoundException; use Drupal\Core\Url; @@ -92,6 +91,18 @@ public function testFinishResponseSubscriber() { $headers = $this->drupalGetHeaders(); $this->assertEqual($headers['x-drupal-cache-contexts'], 'user.roles'); $this->assertEqual($headers['x-drupal-cache-tags'], ''); + + // Finally, verify that the X-Drupal-Cache-Contexts and X-Drupal-Cache-Tags + // headers are not sent when their container parameter is set to FALSE. + $this->drupalGet('router_test/test18'); + $headers = $this->drupalGetHeaders(); + $this->assertTrue(isset($headers['x-drupal-cache-contexts'])); + $this->assertTrue(isset($headers['x-drupal-cache-tags'])); + $this->setHttpResponseDebugCacheabilityHeaders(FALSE); + $this->drupalGet('router_test/test18'); + $headers = $this->drupalGetHeaders(); + $this->assertFalse(isset($headers['x-drupal-cache-contexts'])); + $this->assertFalse(isset($headers['x-drupal-cache-tags'])); } /** diff --git a/core/modules/system/src/Tests/System/ThemeTest.php b/core/modules/system/src/Tests/System/ThemeTest.php index 557a05cc8..8b2836b75 100644 --- a/core/modules/system/src/Tests/System/ThemeTest.php +++ b/core/modules/system/src/Tests/System/ThemeTest.php @@ -184,6 +184,12 @@ function testThemeSettings() { ) ); $this->assertEqual($elements[0]['src'], file_create_url($uploaded_filename)); + + $this->container->get('theme_handler')->install(array('bartik')); + $this->drupalGet('admin/appearance/settings/bartik'); + // The logo field should only be present on the global theme settings form. + $this->assertNoFieldByName('logo_path'); + $this->drupalPostForm(NULL, [], t('Save configuration')); } /** diff --git a/core/modules/system/src/Tests/System/TokenReplaceUnitTest.php b/core/modules/system/src/Tests/System/TokenReplaceUnitTest.php index f89d1fab9..cbffff75d 100644 --- a/core/modules/system/src/Tests/System/TokenReplaceUnitTest.php +++ b/core/modules/system/src/Tests/System/TokenReplaceUnitTest.php @@ -70,7 +70,7 @@ public function testClear() { // Non-existing token. $source .= '[bogus:token]'; - // Replace with with the clear parameter, only the valid token should remain. + // Replace with the clear parameter, only the valid token should remain. $target = Html::escape($this->config('system.site')->get('name')); $result = $this->tokenService->replace($source, array(), array('langcode' => $this->interfaceLanguage->getId(), 'clear' => TRUE)); $this->assertEqual($target, $result, 'Valid tokens replaced while invalid tokens ignored.'); diff --git a/core/modules/system/src/Tests/System/TrustedHostsTest.php b/core/modules/system/src/Tests/System/TrustedHostsTest.php index e54decc35..a3b08b8eb 100644 --- a/core/modules/system/src/Tests/System/TrustedHostsTest.php +++ b/core/modules/system/src/Tests/System/TrustedHostsTest.php @@ -7,11 +7,7 @@ namespace Drupal\system\Tests\System; -use Drupal\Core\Site\Settings; -use Drupal\Core\Url; use Drupal\simpletest\WebTestBase; -use Drupal\user\Entity\User; -use Symfony\Component\HttpFoundation\Request; /** * Tests output on the status overview page. diff --git a/core/modules/system/src/Tests/Theme/TwigFilterTest.php b/core/modules/system/src/Tests/Theme/TwigFilterTest.php index 2adc8c92a..aab1676ac 100644 --- a/core/modules/system/src/Tests/Theme/TwigFilterTest.php +++ b/core/modules/system/src/Tests/Theme/TwigFilterTest.php @@ -8,7 +8,6 @@ namespace Drupal\system\Tests\Theme; use Drupal\simpletest\WebTestBase; -use Drupal\Core\Template\Attribute; /** * Tests Drupal's Twig filters. diff --git a/core/modules/system/src/Tests/Theme/TwigTransTest.php b/core/modules/system/src/Tests/Theme/TwigTransTest.php index ac970cd26..6bfe4421b 100644 --- a/core/modules/system/src/Tests/Theme/TwigTransTest.php +++ b/core/modules/system/src/Tests/Theme/TwigTransTest.php @@ -7,10 +7,7 @@ namespace Drupal\system\Tests\Theme; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Language\LanguageInterface; -use Drupal\Core\Url; -use Drupal\language\Entity\ConfigurableLanguage; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/system/src/Tests/Update/FilterHtmlUpdateTest.php b/core/modules/system/src/Tests/Update/FilterHtmlUpdateTest.php index c9585920f..c71143d3b 100644 --- a/core/modules/system/src/Tests/Update/FilterHtmlUpdateTest.php +++ b/core/modules/system/src/Tests/Update/FilterHtmlUpdateTest.php @@ -8,7 +8,6 @@ namespace Drupal\system\Tests\Update; use Drupal\filter\Entity\FilterFormat; -use Drupal\system\Tests\Update\UpdatePathTestBase; /** * Tests that the allowed html configutations are updated with attributes. diff --git a/core/modules/system/src/Tests/Update/SevenSecondaryLocalTasksConvertedIntoBlockUpdateTest.php b/core/modules/system/src/Tests/Update/SevenSecondaryLocalTasksConvertedIntoBlockUpdateTest.php index 1a15213d7..79086b34d 100644 --- a/core/modules/system/src/Tests/Update/SevenSecondaryLocalTasksConvertedIntoBlockUpdateTest.php +++ b/core/modules/system/src/Tests/Update/SevenSecondaryLocalTasksConvertedIntoBlockUpdateTest.php @@ -7,8 +7,6 @@ namespace Drupal\system\Tests\Update; -use Drupal\node\Entity\Node; - /** * Tests the upgrade path for converting seven secondary local tasks into a block. * diff --git a/core/modules/system/src/Tests/Update/SiteBrandingConvertedIntoBlockUpdateTest.php b/core/modules/system/src/Tests/Update/SiteBrandingConvertedIntoBlockUpdateTest.php index 86a34d7d8..a5e24ce92 100644 --- a/core/modules/system/src/Tests/Update/SiteBrandingConvertedIntoBlockUpdateTest.php +++ b/core/modules/system/src/Tests/Update/SiteBrandingConvertedIntoBlockUpdateTest.php @@ -7,8 +7,6 @@ namespace Drupal\system\Tests\Update; -use Drupal\node\Entity\Node; - /** * Tests the upgrade path for local actions/tasks being converted into blocks. * diff --git a/core/modules/system/src/Tests/Update/UpdatePostUpdateTest.php b/core/modules/system/src/Tests/Update/UpdatePostUpdateTest.php index 67b2ba2a9..85f3247ff 100644 --- a/core/modules/system/src/Tests/Update/UpdatePostUpdateTest.php +++ b/core/modules/system/src/Tests/Update/UpdatePostUpdateTest.php @@ -7,6 +7,8 @@ namespace Drupal\system\Tests\Update; +use Drupal\Component\Render\FormattableMarkup; + /** * Tests hook_post_update(). * @@ -32,7 +34,7 @@ protected function doSelectionTest() { // Ensure that normal and post_update updates are merged together on the // selection page. - $this->assertRaw('
    • 8001 - Normal update_N() function.
    • First update.
    • Second update.
    • Test1 update.
    • Test0 update.
    '); + $this->assertRaw('
    • 8001 - Normal update_N() function.
    • First update.
    • Second update.
    • Test1 update.
    • Test0 update.
    • Testing batch processing in post updates update.
    '); } /** @@ -49,24 +51,34 @@ public function testPostUpdate() { $this->assertRaw('Test1 update'); $this->assertRaw('

    Update test0

    '); $this->assertRaw('Test0 update'); + $this->assertRaw('

    Update test_batch

    '); + $this->assertRaw('Test post update batches'); + // Test state value set by each post update. $updates = [ 'update_test_postupdate_post_update_first', 'update_test_postupdate_post_update_second', 'update_test_postupdate_post_update_test1', 'update_test_postupdate_post_update_test0', + 'update_test_postupdate_post_update_test_batch-1', + 'update_test_postupdate_post_update_test_batch-2', + 'update_test_postupdate_post_update_test_batch-3', ]; $this->assertIdentical($updates, \Drupal::state()->get('post_update_test_execution', [])); - $key_value = \Drupal::keyValue('post_update'); - $updates = array_merge([ - 'block_post_update_disable_blocks_with_missing_contexts', - 'field_post_update_save_custom_storage_property', - 'field_post_update_entity_reference_handler_setting', - 'system_post_update_recalculate_configuration_entity_dependencies', - 'views_post_update_update_cacheability_metadata', - ], $updates); - $this->assertEqual($updates, $key_value->get('existing_updates')); + // Test post_update key value stores contains a list of the update functions + // that have run. + $existing_updates = array_count_values(\Drupal::keyValue('post_update')->get('existing_updates')); + $expected_updates = [ + 'update_test_postupdate_post_update_first', + 'update_test_postupdate_post_update_second', + 'update_test_postupdate_post_update_test1', + 'update_test_postupdate_post_update_test0', + 'update_test_postupdate_post_update_test_batch', + ]; + foreach ($expected_updates as $expected_update) { + $this->assertEqual($existing_updates[$expected_update], 1, new FormattableMarkup("@expected_update exists in 'existing_updates' key and only appears once.", ['@expected_update' => $expected_update])); + } $this->drupalGet('update.php/selection'); $this->assertText('No pending updates.'); diff --git a/core/modules/system/system.admin.inc b/core/modules/system/system.admin.inc index 5b391e713..704b2dc7e 100644 --- a/core/modules/system/system.admin.inc +++ b/core/modules/system/system.admin.inc @@ -5,11 +5,7 @@ * Admin page callbacks for the system module. */ -use Drupal\Component\Utility\SafeMarkup; -use Drupal\Component\Utility\Xss; use Drupal\Component\Utility\Html; -use Drupal\Core\Cache\Cache; -use Drupal\Core\Extension\Extension; use Drupal\Core\Render\Element; use Drupal\Core\Template\Attribute; diff --git a/core/modules/system/system.install b/core/modules/system/system.install index d5686dc83..8addfd1b6 100644 --- a/core/modules/system/system.install +++ b/core/modules/system/system.install @@ -7,11 +7,9 @@ use Drupal\Component\Utility\Crypt; use Drupal\Component\Utility\Environment; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Url; use Drupal\Core\Database\Database; use Drupal\Core\DrupalKernel; -use Drupal\Core\Language\Language; use Drupal\Core\Site\Settings; use Drupal\Core\StreamWrapper\PrivateStream; use Drupal\Core\StreamWrapper\PublicStream; diff --git a/core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php b/core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php index f47c05733..5c294bd85 100644 --- a/core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php +++ b/core/modules/system/tests/modules/cache_test/src/Controller/CacheTestController.php @@ -7,8 +7,6 @@ namespace Drupal\cache_test\Controller; -use Drupal\Component\Utility\SafeMarkup; -use Drupal\Core\Render\HtmlResponse; use Drupal\Core\Url; /** diff --git a/core/modules/system/tests/modules/database_test/database_test.module b/core/modules/system/tests/modules/database_test/database_test.module index d06545316..b5ee9c8c1 100644 --- a/core/modules/system/tests/modules/database_test/database_test.module +++ b/core/modules/system/tests/modules/database_test/database_test.module @@ -1,7 +1,6 @@ getParameter($entity_type_id); - $form = $this->entityFormBuilder()->getForm($entity); - $form['#title'] = $entity->label(); - return $form; - } - /** * Returns an empty page. * diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTest.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTest.php index 89b4c2040..1197c2cd3 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTest.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTest.php @@ -28,10 +28,14 @@ * "default" = "Drupal\entity_test\EntityTestForm", * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", * "views_data" = "Drupal\entity_test\EntityTestViewsData" * }, * base_table = "entity_test", + * admin_permission = "administer entity_test content", * persistent_cache = FALSE, * list_cache_contexts = { "entity_test_view_grants" }, * entity_keys = { @@ -43,7 +47,7 @@ * }, * links = { * "canonical" = "/entity_test/{entity_test}", - * "edit-form" = "/entity_test/manage/{entity_test}", + * "edit-form" = "/entity_test/manage/{entity_test}/edit", * "delete-form" = "/entity_test/delete/entity_test/{entity_test}", * }, * field_ui_base_route = "entity.entity_test.admin_form", diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestAdminRoutes.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestAdminRoutes.php new file mode 100644 index 000000000..2660412ac --- /dev/null +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestAdminRoutes.php @@ -0,0 +1,49 @@ + 11, )); + $fields['test_display_multiple'] = BaseFieldDefinition::create('text') + ->setLabel(t('A field with multiple values')) + ->setCardinality(FieldStorageDefinition::CARDINALITY_UNLIMITED) + ->setDisplayOptions('view', array( + 'type' => 'text_default', + 'weight' => 12, + )) + ->setDisplayOptions('form', array( + 'type' => 'text_textfield', + 'weight' => 12, + )); + return $fields; } diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMul.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMul.php index 334ff94ee..d1908d35b 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMul.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMul.php @@ -7,10 +7,6 @@ namespace Drupal\entity_test\Entity; -use Drupal\Core\Entity\EntityTypeInterface; -use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\entity_test\Entity\EntityTest; - /** * Defines the test entity class. * @@ -25,10 +21,14 @@ * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", - * "views_data" = "Drupal\views\EntityViewsData" + * "views_data" = "Drupal\views\EntityViewsData", + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * }, * base_table = "entity_test_mul", * data_table = "entity_test_mul_property_data", + * admin_permission = "administer entity_test content", * translatable = TRUE, * entity_keys = { * "id" = "id", @@ -39,7 +39,7 @@ * }, * links = { * "canonical" = "/entity_test_mul/manage/{entity_test_mul}", - * "edit-form" = "/entity_test_mul/manage/{entity_test_mul}", + * "edit-form" = "/entity_test_mul/manage/{entity_test_mul}/edit", * "delete-form" = "/entity_test/delete/entity_test_mul/{entity_test_mul}", * }, * field_ui_base_route = "entity.entity_test_mul.admin_form", diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulChanged.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulChanged.php index 67811ac92..055e2906c 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulChanged.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulChanged.php @@ -25,6 +25,9 @@ * "default" = "Drupal\entity_test\EntityTestForm", * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", * "views_data" = "Drupal\views\EntityViewsData" * }, @@ -40,7 +43,7 @@ * }, * links = { * "canonical" = "/entity_test_mul_changed/manage/{entity_test_mul_changed}", - * "edit-form" = "/entity_test_mul_changed/manage/{entity_test_mul_changed}", + * "edit-form" = "/entity_test_mul_changed/manage/{entity_test_mul_changed}/edit", * "delete-form" = "/entity_test/delete/entity_test_mul_changed/{entity_test_mul_changed}", * }, * field_ui_base_route = "entity.entity_test_mul_changed.admin_form", diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulLangcodeKey.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulLangcodeKey.php index 3be6a903e..3f794e5b0 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulLangcodeKey.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulLangcodeKey.php @@ -23,10 +23,14 @@ * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", - * "views_data" = "Drupal\views\EntityViewsData" + * "views_data" = "Drupal\views\EntityViewsData", + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * }, * base_table = "entity_test_mul_langcode_key", * data_table = "entity_test_mul_langcode_key_field_data", + * admin_permission = "administer entity_test content", * translatable = TRUE, * entity_keys = { * "id" = "id", @@ -38,7 +42,7 @@ * }, * links = { * "canonical" = "/entity_test_mul_langcode_key/manage/{entity_test_mul_langcode_key}", - * "edit-form" = "/entity_test_mul_langcode_key/manage/{entity_test_mul_langcode_key}", + * "edit-form" = "/entity_test_mul_langcode_key/manage/{entity_test_mul_langcode_key}/edit", * "delete-form" = "/entity_test/delete/entity_test_mul_langcode_key/{entity_test_mul_langcode_key}", * }, * field_ui_base_route = "entity.entity_test_mul_langcode_key.admin_form", diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRev.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRev.php index 83dd0edc2..1eb7715cf 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRev.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRev.php @@ -7,10 +7,6 @@ namespace Drupal\entity_test\Entity; -use Drupal\Core\Entity\EntityTypeInterface; -use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\entity_test\Entity\EntityTestRev; - /** * Defines the test entity class. * @@ -25,12 +21,16 @@ * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", - * "views_data" = "Drupal\views\EntityViewsData" + * "views_data" = "Drupal\views\EntityViewsData", + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * }, * base_table = "entity_test_mulrev", * data_table = "entity_test_mulrev_property_data", * revision_table = "entity_test_mulrev_revision", * revision_data_table = "entity_test_mulrev_property_revision", + * admin_permission = "administer entity_test content", * translatable = TRUE, * entity_keys = { * "id" = "id", @@ -43,7 +43,7 @@ * links = { * "canonical" = "/entity_test_mulrev/manage/{entity_test_mulrev}", * "delete-form" = "/entity_test/delete/entity_test_mulrev/{entity_test_mulrev}", - * "edit-form" = "/entity_test_mulrev/manage/{entity_test_mulrev}", + * "edit-form" = "/entity_test_mulrev/manage/{entity_test_mulrev}/edit", * "revision" = "/entity_test_mulrev/{entity_test_mulrev}/revision/{entity_test_mulrev_revision}/view", * } * ) diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRevChanged.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRevChanged.php index 933e55adb..f2a9667d2 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRevChanged.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulRevChanged.php @@ -23,6 +23,9 @@ * "default" = "Drupal\entity_test\EntityTestForm", * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * "translation" = "Drupal\content_translation\ContentTranslationHandler", * "views_data" = "Drupal\views\EntityViewsData" * }, @@ -42,7 +45,7 @@ * links = { * "canonical" = "/entity_test_mulrev_changed/manage/{entity_test_mulrev_changed}", * "delete-form" = "/entity_test/delete/entity_test_mulrev_changed/{entity_test_mulrev_changed}", - * "edit-form" = "/entity_test_mulrev_changed/manage/{entity_test_mulrev_changed}", + * "edit-form" = "/entity_test_mulrev_changed/manage/{entity_test_mulrev_changed}/edit", * "revision" = "/entity_test_mulrev_changed/{entity_test_mulrev_changed}/revision/{entity_test_mulrev_changed_revision}/view", * } * ) diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRev.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRev.php index 79140325a..047b85dc7 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRev.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRev.php @@ -9,7 +9,6 @@ use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\entity_test\Entity\EntityTest; /** * Defines the test entity class. @@ -19,16 +18,21 @@ * label = @Translation("Test entity - revisions"), * handlers = { * "access" = "Drupal\entity_test\EntityTestAccessControlHandler", + * "view_builder" = "Drupal\entity_test\EntityTestViewBuilder", * "form" = { * "default" = "Drupal\entity_test\EntityTestForm", * "delete" = "Drupal\entity_test\EntityTestDeleteForm" * }, * "view_builder" = "Drupal\entity_test\EntityTestViewBuilder", * "translation" = "Drupal\content_translation\ContentTranslationHandler", - * "views_data" = "Drupal\views\EntityViewsData" + * "views_data" = "Drupal\views\EntityViewsData", + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * }, * base_table = "entity_test_rev", * revision_table = "entity_test_rev_revision", + * admin_permission = "administer entity_test content", * entity_keys = { * "id" = "id", * "uuid" = "uuid", @@ -40,7 +44,7 @@ * links = { * "canonical" = "/entity_test_rev/manage/{entity_test_rev}", * "delete-form" = "/entity_test/delete/entity_test_rev/{entity_test_rev}", - * "edit-form" = "/entity_test_rev/manage/{entity_test_rev}", + * "edit-form" = "/entity_test_rev/manage/{entity_test_rev}/edit", * "revision" = "/entity_test_rev/{entity_test_rev}/revision/{entity_test_rev_revision}/view", * } * ) diff --git a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestStringId.php b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestStringId.php index d6b6c59ea..1f53e044f 100644 --- a/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestStringId.php +++ b/core/modules/system/tests/modules/entity_test/src/Entity/EntityTestStringId.php @@ -20,9 +20,13 @@ * "form" = { * "default" = "Drupal\entity_test\EntityTestForm" * }, - * "translation" = "Drupal\content_translation\ContentTranslationHandler" + * "translation" = "Drupal\content_translation\ContentTranslationHandler", + * "route_provider" = { + * "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider", + * }, * }, * base_table = "entity_test_string", + * admin_permission = "administer entity_test content", * entity_keys = { * "id" = "id", * "uuid" = "uuid", diff --git a/core/modules/system/tests/modules/entity_test/src/EntityTestAccessControlHandler.php b/core/modules/system/tests/modules/entity_test/src/EntityTestAccessControlHandler.php index fb0e41897..bdc3785ab 100644 --- a/core/modules/system/tests/modules/entity_test/src/EntityTestAccessControlHandler.php +++ b/core/modules/system/tests/modules/entity_test/src/EntityTestAccessControlHandler.php @@ -10,7 +10,6 @@ use Drupal\Core\Access\AccessResult; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityAccessControlHandler; -use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Session\AccountInterface; /** diff --git a/core/modules/system/tests/modules/entity_test/src/EntityTestForm.php b/core/modules/system/tests/modules/entity_test/src/EntityTestForm.php index 59e798b5b..164557bd1 100644 --- a/core/modules/system/tests/modules/entity_test/src/EntityTestForm.php +++ b/core/modules/system/tests/modules/entity_test/src/EntityTestForm.php @@ -9,7 +9,6 @@ use Drupal\Component\Utility\Random; use Drupal\Core\Entity\ContentEntityForm; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Language\LanguageInterface; /** * Form controller for the test entity edit forms. diff --git a/core/modules/system/tests/modules/entity_test/src/Plugin/Validation/Constraint/EntityTestCompositeConstraintValidator.php b/core/modules/system/tests/modules/entity_test/src/Plugin/Validation/Constraint/EntityTestCompositeConstraintValidator.php index d643b7499..511122da5 100644 --- a/core/modules/system/tests/modules/entity_test/src/Plugin/Validation/Constraint/EntityTestCompositeConstraintValidator.php +++ b/core/modules/system/tests/modules/entity_test/src/Plugin/Validation/Constraint/EntityTestCompositeConstraintValidator.php @@ -7,7 +7,6 @@ namespace Drupal\entity_test\Plugin\Validation\Constraint; -use Drupal\Core\Entity\EntityTypeInterface; use Symfony\Component\Validator\Constraint; use Symfony\Component\Validator\ConstraintValidator; diff --git a/core/modules/system/tests/modules/entity_test/src/Routing/EntityTestRoutes.php b/core/modules/system/tests/modules/entity_test/src/Routing/EntityTestRoutes.php index 09d677f18..8992550f3 100644 --- a/core/modules/system/tests/modules/entity_test/src/Routing/EntityTestRoutes.php +++ b/core/modules/system/tests/modules/entity_test/src/Routing/EntityTestRoutes.php @@ -33,30 +33,6 @@ public function routes() { array('_permission' => 'administer entity_test content') ); - $routes["entity.$entity_type_id.canonical"] = new Route( - $entity_type_id . '/manage/{' . $entity_type_id . '}', - array('_controller' => '\Drupal\entity_test\Controller\EntityTestController::testEdit', 'entity_type_id' => $entity_type_id), - array('_permission' => 'administer entity_test content'), - array('parameters' => array( - $entity_type_id => array('type' => 'entity:' . $entity_type_id), - )) - ); - - $routes["entity.$entity_type_id.edit_form"] = new Route( - $entity_type_id . '/manage/{' . $entity_type_id . '}', - array('_controller' => '\Drupal\entity_test\Controller\EntityTestController::testEdit', 'entity_type_id' => $entity_type_id), - array('_permission' => 'administer entity_test content'), - array('parameters' => array( - $entity_type_id => array('type' => 'entity:' . $entity_type_id), - )) - ); - - $routes["entity.$entity_type_id.delete_form"] = new Route( - 'entity_test/delete/' . $entity_type_id . '/{' . $entity_type_id . '}', - array('_entity_form' => $entity_type_id . '.delete'), - array('_permission' => 'administer entity_test content') - ); - $routes["entity.$entity_type_id.admin_form"] = new Route( "$entity_type_id/structure/{bundle}", array('_controller' => '\Drupal\entity_test\Controller\EntityTestController::testAdmin'), diff --git a/core/modules/system/tests/modules/menu_test/src/TestControllers.php b/core/modules/system/tests/modules/menu_test/src/TestControllers.php index 364c77b01..a7e39e4b5 100644 --- a/core/modules/system/tests/modules/menu_test/src/TestControllers.php +++ b/core/modules/system/tests/modules/menu_test/src/TestControllers.php @@ -8,7 +8,6 @@ namespace Drupal\menu_test; use Drupal\Component\Utility\SafeMarkup; -use Drupal\Core\Entity\EntityInterface; /** * Controllers for testing the menu integration routing system. diff --git a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockComplexContextBlock.php b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockComplexContextBlock.php index 8041c3a59..1cb657a4a 100644 --- a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockComplexContextBlock.php +++ b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockComplexContextBlock.php @@ -7,7 +7,6 @@ namespace Drupal\plugin_test\Plugin\plugin_test\mock_block; -use Drupal\Core\Plugin\Context\ContextDefinition; use Drupal\Core\Plugin\ContextAwarePluginBase; /** diff --git a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockMenuBlock.php b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockMenuBlock.php index 375b784c7..7ca628fc0 100644 --- a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockMenuBlock.php +++ b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockMenuBlock.php @@ -7,8 +7,6 @@ namespace Drupal\plugin_test\Plugin\plugin_test\mock_block; -use Drupal\Component\Plugin\PluginBase; - /** * Mock implementation of a menu block plugin used by Plugin API unit tests. * diff --git a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockUserNameBlock.php b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockUserNameBlock.php index 07c7a7983..9150167e5 100644 --- a/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockUserNameBlock.php +++ b/core/modules/system/tests/modules/plugin_test/src/Plugin/plugin_test/mock_block/MockUserNameBlock.php @@ -7,7 +7,6 @@ namespace Drupal\plugin_test\Plugin\plugin_test\mock_block; -use Drupal\Core\Plugin\Context\ContextDefinition; use Drupal\Core\Plugin\ContextAwarePluginBase; /** diff --git a/core/modules/system/tests/modules/session_test/src/Controller/SessionTestController.php b/core/modules/system/tests/modules/session_test/src/Controller/SessionTestController.php index 4e4954fbd..3af2ea5c8 100644 --- a/core/modules/system/tests/modules/session_test/src/Controller/SessionTestController.php +++ b/core/modules/system/tests/modules/session_test/src/Controller/SessionTestController.php @@ -8,7 +8,6 @@ namespace Drupal\session_test\Controller; use Drupal\Core\Controller\ControllerBase; -use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\JsonResponse; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; diff --git a/core/modules/system/tests/modules/system_test/src/Controller/SystemTestController.php b/core/modules/system/tests/modules/system_test/src/Controller/SystemTestController.php index abd90229b..9d3510272 100644 --- a/core/modules/system/tests/modules/system_test/src/Controller/SystemTestController.php +++ b/core/modules/system/tests/modules/system_test/src/Controller/SystemTestController.php @@ -275,6 +275,13 @@ public function respondWithReponse(Request $request) { return new Response('test'); } + /** + * A plain Symfony reponse with Cache-Control: public, max-age=60. + */ + public function respondWithPublicResponse() { + return (new Response('test'))->setPublic()->setMaxAge(60); + } + /** * A simple page callback that uses a CacheableResponse object. */ diff --git a/core/modules/system/tests/modules/system_test/system_test.routing.yml b/core/modules/system/tests/modules/system_test/system_test.routing.yml index 94a1bef41..1fb4069c1 100644 --- a/core/modules/system/tests/modules/system_test/system_test.routing.yml +++ b/core/modules/system/tests/modules/system_test/system_test.routing.yml @@ -137,6 +137,13 @@ system_test.respond_response: requirements: _access: 'TRUE' +system_test.respond_public_response: + path: '/system-test/respond-public-response' + defaults: + _controller: '\Drupal\system_test\Controller\SystemTestController::respondWithPublicResponse' + requirements: + _access: 'TRUE' + system_test.respond_cacheable_response: path: '/system-test/respond-cacheable-reponse' defaults: diff --git a/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php b/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php index 934e6a2be..5e2835e6a 100644 --- a/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php +++ b/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php @@ -7,8 +7,6 @@ namespace Drupal\test_page_test\Controller; -use Drupal\Component\Utility\Html; - /** * Defines a test controller for page titles. */ diff --git a/core/modules/system/tests/modules/update_test_postupdate/update_test_postupdate.post_update.php b/core/modules/system/tests/modules/update_test_postupdate/update_test_postupdate.post_update.php index e914cac8c..ece8b7e8b 100644 --- a/core/modules/system/tests/modules/update_test_postupdate/update_test_postupdate.post_update.php +++ b/core/modules/system/tests/modules/update_test_postupdate/update_test_postupdate.post_update.php @@ -43,3 +43,22 @@ function update_test_postupdate_post_update_test0() { return 'Test0 update'; } + +/** + * Testing batch processing in post updates update. + */ +function update_test_postupdate_post_update_test_batch(&$sandbox = NULL) { + if (!isset($sandbox['steps'])) { + $sandbox['current_step'] = 0; + $sandbox['steps'] = 3; + } + + $sandbox['current_step']++; + + $execution = \Drupal::state()->get('post_update_test_execution', []); + $execution[] = __FUNCTION__ . '-' . $sandbox['current_step']; + \Drupal::state()->set('post_update_test_execution', $execution); + + $sandbox['#finished'] = $sandbox['current_step'] / $sandbox['steps']; + return 'Test post update batches'; +} diff --git a/core/modules/system/tests/src/Kernel/Entity/EntityReferenceSelectionReferenceableTest.php b/core/modules/system/tests/src/Kernel/Entity/EntityReferenceSelectionReferenceableTest.php index c9062afbd..30c52a9c7 100644 --- a/core/modules/system/tests/src/Kernel/Entity/EntityReferenceSelectionReferenceableTest.php +++ b/core/modules/system/tests/src/Kernel/Entity/EntityReferenceSelectionReferenceableTest.php @@ -153,7 +153,7 @@ public function providerTestCases() { // Referenceables containing '_', limited to 3. Expecting 3 limited items // ('Xyz_', 'xyabz_', 'foo_') and 5 total. ['_', 'CONTAINS', 3, 3, ['Xyz_', 'xyabz_', 'foo_'], 6], - // Referenceables ending with with 'z_', limited to 3. Expecting 3 limited + // Referenceables ending with 'z_', limited to 3. Expecting 3 limited // items ('Xyz_', 'xyabz_', 'baz_') and 4 total. ['z_', 'ENDS_WITH', 3, 3, ['Xyz_', 'xyabz_', 'baz_'], 4], // Referenceables identical with 'xyabz_', no limit. Expecting 1 item diff --git a/core/modules/system/tests/src/Kernel/Extension/ModuleHandlerTest.php b/core/modules/system/tests/src/Kernel/Extension/ModuleHandlerTest.php index e9eb7a7c1..5265b8e58 100644 --- a/core/modules/system/tests/src/Kernel/Extension/ModuleHandlerTest.php +++ b/core/modules/system/tests/src/Kernel/Extension/ModuleHandlerTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\system\Kernel\Extension; -use Drupal\Component\FileCache\FileCacheFactory; use Drupal\Core\DependencyInjection\ContainerBuilder; use \Drupal\Core\Extension\ModuleUninstallValidatorException; use Drupal\KernelTests\KernelTestBase; diff --git a/core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php b/core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php index 64e61c7d8..29f0cea3b 100644 --- a/core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php +++ b/core/modules/system/tests/src/Unit/Breadcrumbs/PathBasedBreadcrumbBuilderTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\Link; use Drupal\Core\Access\AccessResultAllowed; -use Drupal\Core\Session\AccountInterface; use Drupal\Core\StringTranslation\TranslationInterface; use Drupal\Core\Url; use Drupal\Core\Utility\LinkGeneratorInterface; @@ -21,7 +20,6 @@ use Symfony\Component\DependencyInjection\Container; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\Routing\RequestContext; use Symfony\Component\Routing\Route; /** diff --git a/core/modules/taxonomy/migration_templates/d6_term_node.yml b/core/modules/taxonomy/migration_templates/d6_term_node.yml index 01578b1f5..349bcd304 100644 --- a/core/modules/taxonomy/migration_templates/d6_term_node.yml +++ b/core/modules/taxonomy/migration_templates/d6_term_node.yml @@ -7,7 +7,14 @@ builder: source: plugin: d6_term_node process: - nid: nid + nid: + - + plugin: migration + migration: d6_node:* + source: nid + - + plugin: skip_on_empty + method: row type: type # The actual field name is dynamic and will be added by the builder. destination: diff --git a/core/modules/taxonomy/migration_templates/d6_term_node_revision.yml b/core/modules/taxonomy/migration_templates/d6_term_node_revision.yml index e9ceadd53..06e801afb 100644 --- a/core/modules/taxonomy/migration_templates/d6_term_node_revision.yml +++ b/core/modules/taxonomy/migration_templates/d6_term_node_revision.yml @@ -7,7 +7,14 @@ builder: source: plugin: d6_term_node_revision process: - vid: vid + vid: + - + plugin: migration + migration: d6_node:* + source: vid + - + plugin: skip_on_empty + method: row type: type # The actual field name is dynamic and will be added by the builder. destination: diff --git a/core/modules/taxonomy/src/Plugin/migrate/builder/d6/TermNode.php b/core/modules/taxonomy/src/Plugin/migrate/builder/d6/TermNode.php index 39ba5eb54..36458acde 100644 --- a/core/modules/taxonomy/src/Plugin/migrate/builder/d6/TermNode.php +++ b/core/modules/taxonomy/src/Plugin/migrate/builder/d6/TermNode.php @@ -13,7 +13,6 @@ use Drupal\migrate\MigrateMessage; use Drupal\migrate\MigrateTemplateStorage; use Drupal\migrate\Plugin\migrate\builder\BuilderBase; -use Drupal\migrate\Row; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/taxonomy/src/Plugin/views/argument/IndexTid.php b/core/modules/taxonomy/src/Plugin/views/argument/IndexTid.php index 89a31f778..6018b06b7 100644 --- a/core/modules/taxonomy/src/Plugin/views/argument/IndexTid.php +++ b/core/modules/taxonomy/src/Plugin/views/argument/IndexTid.php @@ -9,7 +9,6 @@ use Drupal\taxonomy\Entity\Term; use Drupal\views\Plugin\views\argument\ManyToOne; -use Drupal\Component\Utility\SafeMarkup; /** * Allow taxonomy term ID(s) as argument. diff --git a/core/modules/taxonomy/src/Plugin/views/argument/IndexTidDepth.php b/core/modules/taxonomy/src/Plugin/views/argument/IndexTidDepth.php index e2df37fad..c63e444bd 100644 --- a/core/modules/taxonomy/src/Plugin/views/argument/IndexTidDepth.php +++ b/core/modules/taxonomy/src/Plugin/views/argument/IndexTidDepth.php @@ -11,7 +11,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\views\Plugin\views\argument\ArgumentPluginBase; -use Drupal\taxonomy\Entity\Term; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/taxonomy/src/Plugin/views/argument_default/Tid.php b/core/modules/taxonomy/src/Plugin/views/argument_default/Tid.php index 07dca4cde..f52e264a3 100644 --- a/core/modules/taxonomy/src/Plugin/views/argument_default/Tid.php +++ b/core/modules/taxonomy/src/Plugin/views/argument_default/Tid.php @@ -17,8 +17,6 @@ use Drupal\views\Plugin\views\argument_default\ArgumentDefaultPluginBase; use Drupal\node\NodeInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; -use Drupal\taxonomy\Entity\Vocabulary; use Drupal\taxonomy\VocabularyStorageInterface; /** diff --git a/core/modules/taxonomy/src/Plugin/views/argument_validator/TermName.php b/core/modules/taxonomy/src/Plugin/views/argument_validator/TermName.php index 0a8c081ab..d5a7a7e2d 100644 --- a/core/modules/taxonomy/src/Plugin/views/argument_validator/TermName.php +++ b/core/modules/taxonomy/src/Plugin/views/argument_validator/TermName.php @@ -8,8 +8,6 @@ namespace Drupal\taxonomy\Plugin\views\argument_validator; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\ViewExecutable; -use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\views\Plugin\views\argument_validator\Entity; diff --git a/core/modules/taxonomy/src/Plugin/views/field/TaxonomyIndexTid.php b/core/modules/taxonomy/src/Plugin/views/field/TaxonomyIndexTid.php index 3049f6f7f..845f3524b 100644 --- a/core/modules/taxonomy/src/Plugin/views/field/TaxonomyIndexTid.php +++ b/core/modules/taxonomy/src/Plugin/views/field/TaxonomyIndexTid.php @@ -11,7 +11,6 @@ use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\field\PrerenderList; -use Drupal\taxonomy\Entity\Vocabulary; use Symfony\Component\DependencyInjection\ContainerInterface; use Drupal\taxonomy\VocabularyStorageInterface; diff --git a/core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php b/core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php index 01086b08b..9bb575c4e 100644 --- a/core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php +++ b/core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php @@ -8,7 +8,6 @@ namespace Drupal\taxonomy\Plugin\views\filter; use Drupal\Core\Entity\Element\EntityAutocomplete; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\taxonomy\Entity\Term; use Drupal\taxonomy\TermStorageInterface; @@ -16,7 +15,6 @@ use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\filter\ManyToOne; -use Drupal\Component\Utility\Tags; use Symfony\Component\DependencyInjection\ContainerInterface; /** diff --git a/core/modules/taxonomy/src/TermStorage.php b/core/modules/taxonomy/src/TermStorage.php index 8cc5be862..1876b721d 100644 --- a/core/modules/taxonomy/src/TermStorage.php +++ b/core/modules/taxonomy/src/TermStorage.php @@ -9,7 +9,6 @@ use Drupal\Core\Entity\Sql\SqlContentEntityStorage; use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Entity\Query\QueryInterface; /** * Defines a Controller class for taxonomy terms. diff --git a/core/modules/taxonomy/src/Tests/EfqTest.php b/core/modules/taxonomy/src/Tests/EfqTest.php index f2fd1bece..bb94033c9 100644 --- a/core/modules/taxonomy/src/Tests/EfqTest.php +++ b/core/modules/taxonomy/src/Tests/EfqTest.php @@ -7,8 +7,6 @@ namespace Drupal\taxonomy\Tests; -use Drupal\Core\Entity\Query\QueryFactory; - /** * Verifies operation of a taxonomy-based Entity Query. * diff --git a/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateTermNodeTest.php b/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateTermNodeTest.php index 7c4ad1823..8bf9e1728 100644 --- a/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateTermNodeTest.php +++ b/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateTermNodeTest.php @@ -7,6 +7,9 @@ namespace Drupal\taxonomy\Tests\Migrate\d6; +use Drupal\migrate\Entity\Migration; +use Drupal\migrate\Plugin\MigrateIdMapInterface; +use Drupal\migrate\Row; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; use Drupal\node\Entity\Node; @@ -30,13 +33,14 @@ protected function setUp() { $this->installSchema('node', ['node_access']); $this->migrateContent(); $this->migrateTaxonomy(); - $this->executeMigrations(['d6_term_node:*']); } /** * Tests the Drupal 6 term-node association to Drupal 8 migration. */ public function testTermNode() { + $this->executeMigrations(['d6_term_node:*']); + $this->container->get('entity.manager') ->getStorage('node') ->resetCache([1, 2]); @@ -51,4 +55,20 @@ public function testTermNode() { $this->assertIdentical('3', $node->vocabulary_2_i_1_[1]->target_id); } + /** + * Tests that term associations are ignored when they belong to nodes which + * were not migrated. + */ + public function testSkipNonExistentNode() { + // Node 2 is migrated by d6_node__story, but we need to pretend that it + // failed, so record that in the map table. + $this->mockFailure('d6_node__story', ['nid' => 2]); + + // d6_term_node__2 should skip over node 2 (a.k.a. revision 3) because, + // according to the map table, it failed. + $migration = Migration::load('d6_term_node__2'); + $this->executeMigration($migration); + $this->assertNull($migration->getIdMap()->lookupDestinationId(['vid' => 3])[0]); + } + } diff --git a/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateVocabularyFieldInstanceTest.php b/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateVocabularyFieldInstanceTest.php index a1f0c5be6..903957fc3 100644 --- a/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateVocabularyFieldInstanceTest.php +++ b/core/modules/taxonomy/src/Tests/Migrate/d6/MigrateVocabularyFieldInstanceTest.php @@ -7,7 +7,6 @@ namespace Drupal\taxonomy\Tests\Migrate\d6; -use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\field\Entity\FieldConfig; use Drupal\migrate\Entity\Migration; use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase; diff --git a/core/modules/taxonomy/src/Tests/TermKernelTest.php b/core/modules/taxonomy/src/Tests/TermKernelTest.php index 907437572..549dcea77 100644 --- a/core/modules/taxonomy/src/Tests/TermKernelTest.php +++ b/core/modules/taxonomy/src/Tests/TermKernelTest.php @@ -8,7 +8,6 @@ namespace Drupal\taxonomy\Tests; use Drupal\taxonomy\Entity\Term; -use Drupal\taxonomy\Tests\TaxonomyTestTrait; use Drupal\simpletest\KernelTestBase; /** diff --git a/core/modules/taxonomy/src/Tests/Views/TaxonomyIndexTidUiTest.php b/core/modules/taxonomy/src/Tests/Views/TaxonomyIndexTidUiTest.php index 95b64a2c2..c2a0bcdc1 100644 --- a/core/modules/taxonomy/src/Tests/Views/TaxonomyIndexTidUiTest.php +++ b/core/modules/taxonomy/src/Tests/Views/TaxonomyIndexTidUiTest.php @@ -7,7 +7,6 @@ namespace Drupal\taxonomy\Tests\Views; -use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\field\Tests\EntityReference\EntityReferenceTestTrait; use Drupal\taxonomy\Entity\Term; use Drupal\taxonomy\Entity\Vocabulary; diff --git a/core/modules/taxonomy/src/Tests/Views/TaxonomyRelationshipTest.php b/core/modules/taxonomy/src/Tests/Views/TaxonomyRelationshipTest.php index ae065cf30..5889debb7 100644 --- a/core/modules/taxonomy/src/Tests/Views/TaxonomyRelationshipTest.php +++ b/core/modules/taxonomy/src/Tests/Views/TaxonomyRelationshipTest.php @@ -9,7 +9,6 @@ use Drupal\node\NodeInterface; use Drupal\taxonomy\TermInterface; -use Drupal\views\Tests\ViewTestData; use Drupal\views\Views; /** diff --git a/core/modules/taxonomy/src/Tests/Views/TaxonomyViewsFieldAccessTest.php b/core/modules/taxonomy/src/Tests/Views/TaxonomyViewsFieldAccessTest.php index c16b10a78..132e8ed52 100644 --- a/core/modules/taxonomy/src/Tests/Views/TaxonomyViewsFieldAccessTest.php +++ b/core/modules/taxonomy/src/Tests/Views/TaxonomyViewsFieldAccessTest.php @@ -9,7 +9,6 @@ use Drupal\taxonomy\Entity\Term; use Drupal\taxonomy\Entity\Vocabulary; -use Drupal\user\Entity\User; use Drupal\views\Tests\Handler\FieldFieldAccessTestBase; /** diff --git a/core/modules/taxonomy/src/Tests/VocabularyCrudTest.php b/core/modules/taxonomy/src/Tests/VocabularyCrudTest.php index a46a47e54..6596b8e2e 100644 --- a/core/modules/taxonomy/src/Tests/VocabularyCrudTest.php +++ b/core/modules/taxonomy/src/Tests/VocabularyCrudTest.php @@ -8,7 +8,6 @@ namespace Drupal\taxonomy\Tests; use Drupal\Component\Utility\Unicode; -use Drupal\field\Entity\FieldConfig; use Drupal\taxonomy\Entity\Vocabulary; /** diff --git a/core/modules/taxonomy/src/VocabularyStorage.php b/core/modules/taxonomy/src/VocabularyStorage.php index 85fd4a629..b761bcc22 100644 --- a/core/modules/taxonomy/src/VocabularyStorage.php +++ b/core/modules/taxonomy/src/VocabularyStorage.php @@ -7,7 +7,6 @@ namespace Drupal\taxonomy; -use Drupal\Core\Cache\Cache; use Drupal\Core\Config\Entity\ConfigEntityStorage; /** diff --git a/core/modules/taxonomy/taxonomy.js b/core/modules/taxonomy/taxonomy.js index 58c8b4378..09e5b464b 100644 --- a/core/modules/taxonomy/taxonomy.js +++ b/core/modules/taxonomy/taxonomy.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Move a block in the blocks table from one region to another. diff --git a/core/modules/text/src/Plugin/Field/FieldWidget/TextareaWithSummaryWidget.php b/core/modules/text/src/Plugin/Field/FieldWidget/TextareaWithSummaryWidget.php index d3c9cd38b..8bfb7134d 100644 --- a/core/modules/text/src/Plugin/Field/FieldWidget/TextareaWithSummaryWidget.php +++ b/core/modules/text/src/Plugin/Field/FieldWidget/TextareaWithSummaryWidget.php @@ -8,7 +8,6 @@ namespace Drupal\text\Plugin\Field\FieldWidget; use Drupal\Core\Form\FormStateInterface; -use Drupal\text\Plugin\Field\FieldWidget\TextareaWidget; use Symfony\Component\Validator\ConstraintViolationInterface; use Drupal\Core\Field\FieldItemListInterface; diff --git a/core/modules/text/src/Plugin/migrate/cckfield/TextField.php b/core/modules/text/src/Plugin/migrate/cckfield/TextField.php index ba3fdacdf..71e811224 100644 --- a/core/modules/text/src/Plugin/migrate/cckfield/TextField.php +++ b/core/modules/text/src/Plugin/migrate/cckfield/TextField.php @@ -38,35 +38,55 @@ public function getFieldFormatterMap() { /** * {@inheritdoc} */ - public function processCckFieldValues(MigrationInterface $migration, $field_name, $data) { - $process = array( - array( - 'plugin' => 'iterator', - 'source' => $field_name, - // See \Drupal\migrate_drupal\Plugin\migrate\source\d6\User::baseFields(), - // signature_format for an example of the YAML that represents this - // process array. - 'process' => [ - 'value' => 'value', - 'format' => [ - [ - 'plugin' => 'static_map', - 'bypass' => TRUE, - 'source' => 'format', - 'map' => [0 => NULL], - ], - [ - 'plugin' => 'skip_on_empty', - 'method' => 'process', - ], - [ - 'plugin' => 'migration', - 'migration' => 'd6_filter_format', - 'source' => 'format', + public function processCckFieldValues(MigrationInterface $migration, $field_name, $field_info) { + if ($field_info['widget_type'] == 'optionwidgets_onoff') { + $process = [ + 'value' => [ + 'plugin' => 'static_map', + 'source' => 'value', + 'default_value' => 0, + ], + ]; + + $checked_value = explode("\n", $field_info['global_settings']['allowed_values'])[1]; + if (strpos($checked_value, '|') !== FALSE) { + $checked_value = substr($checked_value, 0, strpos($checked_value, '|')); + } + $process['value']['map'][$checked_value] = 1; + } + else { + // See \Drupal\migrate_drupal\Plugin\migrate\source\d6\User::baseFields(), + // signature_format for an example of the YAML that represents this + // process array. + $process = [ + 'value' => 'value', + 'format' => [ + [ + 'plugin' => 'static_map', + 'bypass' => TRUE, + 'source' => 'format', + 'map' => [0 => NULL], + ], + [ + 'plugin' => 'skip_on_empty', + 'method' => 'process', + ], + [ + 'plugin' => 'migration', + 'migration' => [ + 'd6_filter_format', + 'd7_filter_format', ], + 'source' => 'format', ], ], - ), + ]; + } + + $process = array( + 'plugin' => 'iterator', + 'source' => $field_name, + 'process' => $process, ); $migration->setProcessOfProperty($field_name, $process); } diff --git a/core/modules/text/src/Tests/TextFieldTest.php b/core/modules/text/src/Tests/TextFieldTest.php index a1c9ec326..8279a6ded 100644 --- a/core/modules/text/src/Tests/TextFieldTest.php +++ b/core/modules/text/src/Tests/TextFieldTest.php @@ -223,7 +223,7 @@ function _testTextfieldWidgetsFormatted($field_type, $widget_type) { // Display edition form. // We should now have a 'text format' selector. - $this->drupalGet('entity_test/manage/' . $id); + $this->drupalGet('entity_test/manage/' . $id . '/edit'); $this->assertFieldByName("{$field_name}[0][value]", NULL, 'Widget is displayed'); $this->assertFieldByName("{$field_name}[0][format]", NULL, 'Format selector is displayed'); diff --git a/core/modules/text/src/TextProcessed.php b/core/modules/text/src/TextProcessed.php index 197b28c65..57b36f42f 100644 --- a/core/modules/text/src/TextProcessed.php +++ b/core/modules/text/src/TextProcessed.php @@ -7,7 +7,6 @@ namespace Drupal\text; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\TypedData\DataDefinitionInterface; use Drupal\Core\TypedData\TypedDataInterface; use Drupal\Core\TypedData\TypedData; diff --git a/core/modules/text/tests/src/Unit/Migrate/TextFieldTest.php b/core/modules/text/tests/src/Unit/Migrate/TextFieldTest.php new file mode 100644 index 000000000..89b8c2619 --- /dev/null +++ b/core/modules/text/tests/src/Unit/Migrate/TextFieldTest.php @@ -0,0 +1,124 @@ +plugin = new TextField([], 'text', []); + + $migration = $this->prophesize(MigrationInterface::class); + + // The plugin's processCckFieldValues() method will call + // setProcessOfProperty() and return nothing. So, in order to examine the + // process pipeline created by the plugin, we need to ensure that + // getProcess() always returns the last input to setProcessOfProperty(). + $migration->setProcessOfProperty(Argument::type('string'), Argument::type('array')) + ->will(function($arguments) use ($migration) { + $migration->getProcess()->willReturn($arguments[1]); + }); + + $this->migration = $migration->reveal(); + } + + /** + * @covers ::processCckFieldValues + */ + public function testProcessFilteredTextFieldValues() { + $field_info = [ + 'widget_type' => 'text_textfield', + ]; + $this->plugin->processCckFieldValues($this->migration, 'body', $field_info); + + $process = $this->migration->getProcess(); + $this->assertSame('iterator', $process['plugin']); + $this->assertSame('body', $process['source']); + $this->assertSame('value', $process['process']['value']); + + // Ensure that filter format IDs will be looked up in the filter format + // migrations. + $lookup = $process['process']['format'][2]; + $this->assertSame('migration', $lookup['plugin']); + $this->assertContains('d6_filter_format', $lookup['migration']); + $this->assertContains('d7_filter_format', $lookup['migration']); + $this->assertSame('format', $lookup['source']); + } + + /** + * @covers ::processCckFieldValues + */ + public function testProcessBooleanTextImplicitValues() { + $info = array( + 'widget_type' => 'optionwidgets_onoff', + 'global_settings' => array( + 'allowed_values' => "foo\nbar", + ) + ); + $this->plugin->processCckFieldValues($this->migration, 'field', $info); + + $expected = [ + 'value' => [ + 'plugin' => 'static_map', + 'source' => 'value', + 'default_value' => 0, + 'map' => [ + 'bar' => 1, + ], + ], + ]; + $this->assertSame($expected, $this->migration->getProcess()['process']); + } + + /** + * @covers ::processCckFieldValues + */ + public function testProcessBooleanTextExplicitValues() { + $info = array( + 'widget_type' => 'optionwidgets_onoff', + 'global_settings' => array( + 'allowed_values' => "foo|Foo\nbaz|Baz", + ) + ); + $this->plugin->processCckFieldValues($this->migration, 'field', $info); + + $expected = [ + 'value' => [ + 'plugin' => 'static_map', + 'source' => 'value', + 'default_value' => 0, + 'map' => [ + 'baz' => 1, + ], + ], + ]; + $this->assertSame($expected, $this->migration->getProcess()['process']); + } + +} diff --git a/core/modules/text/text.js b/core/modules/text/text.js index 54da56c5e..615a1e601 100644 --- a/core/modules/text/text.js +++ b/core/modules/text/text.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Auto-hide summary textarea if empty and show hide and unhide links. diff --git a/core/modules/text/text.module b/core/modules/text/text.module index f30acf71c..1d2fdcc82 100644 --- a/core/modules/text/text.module +++ b/core/modules/text/text.module @@ -7,7 +7,6 @@ use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Unicode; -use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Routing\RouteMatchInterface; /** diff --git a/core/modules/toolbar/js/escapeAdmin.js b/core/modules/toolbar/js/escapeAdmin.js index 26b8a2686..6e8f992fd 100644 --- a/core/modules/toolbar/js/escapeAdmin.js +++ b/core/modules/toolbar/js/escapeAdmin.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; var pathInfo = drupalSettings.path; var escapeAdminPath = sessionStorage.getItem('escapeAdminPath'); diff --git a/core/modules/toolbar/js/models/MenuModel.js b/core/modules/toolbar/js/models/MenuModel.js index 5f302bb06..072a4f141 100644 --- a/core/modules/toolbar/js/models/MenuModel.js +++ b/core/modules/toolbar/js/models/MenuModel.js @@ -5,7 +5,7 @@ (function (Backbone, Drupal) { - "use strict"; + 'use strict'; /** * Backbone Model for collapsible menus. diff --git a/core/modules/toolbar/js/models/ToolbarModel.js b/core/modules/toolbar/js/models/ToolbarModel.js index 357692c0e..537601d8f 100644 --- a/core/modules/toolbar/js/models/ToolbarModel.js +++ b/core/modules/toolbar/js/models/ToolbarModel.js @@ -5,7 +5,7 @@ (function (Backbone, Drupal) { - "use strict"; + 'use strict'; /** * Backbone model for the toolbar. diff --git a/core/modules/toolbar/js/toolbar.js b/core/modules/toolbar/js/toolbar.js index 9a19205e6..8accad975 100644 --- a/core/modules/toolbar/js/toolbar.js +++ b/core/modules/toolbar/js/toolbar.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; // Merge run-time settings with the defaults. var options = $.extend( diff --git a/core/modules/toolbar/js/toolbar.menu.js b/core/modules/toolbar/js/toolbar.menu.js index 7d300e15d..0ca25a9b0 100644 --- a/core/modules/toolbar/js/toolbar.menu.js +++ b/core/modules/toolbar/js/toolbar.menu.js @@ -10,7 +10,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Store the open menu tray. diff --git a/core/modules/toolbar/js/views/BodyVisualView.js b/core/modules/toolbar/js/views/BodyVisualView.js index 74996467c..64593c9cf 100644 --- a/core/modules/toolbar/js/views/BodyVisualView.js +++ b/core/modules/toolbar/js/views/BodyVisualView.js @@ -5,7 +5,7 @@ (function ($, Drupal, Backbone) { - "use strict"; + 'use strict'; Drupal.toolbar.BodyVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.BodyVisualView# */{ diff --git a/core/modules/toolbar/js/views/MenuVisualView.js b/core/modules/toolbar/js/views/MenuVisualView.js index f75bb7185..92dea215b 100644 --- a/core/modules/toolbar/js/views/MenuVisualView.js +++ b/core/modules/toolbar/js/views/MenuVisualView.js @@ -5,7 +5,7 @@ (function ($, Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.toolbar.MenuVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.MenuVisualView# */{ diff --git a/core/modules/toolbar/js/views/ToolbarAuralView.js b/core/modules/toolbar/js/views/ToolbarAuralView.js index 00f5aa5ff..3cc9adaf4 100644 --- a/core/modules/toolbar/js/views/ToolbarAuralView.js +++ b/core/modules/toolbar/js/views/ToolbarAuralView.js @@ -5,7 +5,7 @@ (function (Backbone, Drupal) { - "use strict"; + 'use strict'; Drupal.toolbar.ToolbarAuralView = Backbone.View.extend(/** @lends Drupal.toolbar.ToolbarAuralView# */{ diff --git a/core/modules/toolbar/js/views/ToolbarVisualView.js b/core/modules/toolbar/js/views/ToolbarVisualView.js index be7ab06f1..7e0401926 100644 --- a/core/modules/toolbar/js/views/ToolbarVisualView.js +++ b/core/modules/toolbar/js/views/ToolbarVisualView.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings, Backbone) { - "use strict"; + 'use strict'; Drupal.toolbar.ToolbarVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.ToolbarVisualView# */{ diff --git a/core/modules/toolbar/src/Tests/ToolbarAdminMenuTest.php b/core/modules/toolbar/src/Tests/ToolbarAdminMenuTest.php index 4ce22e657..96670199b 100644 --- a/core/modules/toolbar/src/Tests/ToolbarAdminMenuTest.php +++ b/core/modules/toolbar/src/Tests/ToolbarAdminMenuTest.php @@ -7,7 +7,6 @@ namespace Drupal\toolbar\Tests; -use Drupal\Core\Cache\Cache; use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Url; use Drupal\language\Entity\ConfigurableLanguage; diff --git a/core/modules/toolbar/toolbar.module b/core/modules/toolbar/toolbar.module index 02b3f8531..a8eeef4d4 100644 --- a/core/modules/toolbar/toolbar.module +++ b/core/modules/toolbar/toolbar.module @@ -5,13 +5,11 @@ * Administration toolbar for quick access to top level administration items. */ -use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Menu\MenuTreeParameters; use Drupal\Core\Render\Element; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Template\Attribute; -use Drupal\Component\Datetime\DateTimePlus; use Drupal\Component\Utility\Crypt; use Drupal\Core\Url; diff --git a/core/modules/tour/js/tour.js b/core/modules/tour/js/tour.js index c75132939..2c7050f75 100644 --- a/core/modules/tour/js/tour.js +++ b/core/modules/tour/js/tour.js @@ -5,7 +5,7 @@ (function ($, Backbone, Drupal, document) { - "use strict"; + 'use strict'; var queryString = decodeURI(window.location.search); diff --git a/core/modules/tour/src/Entity/Tour.php b/core/modules/tour/src/Entity/Tour.php index 8a4576c7d..5d42e0b04 100644 --- a/core/modules/tour/src/Entity/Tour.php +++ b/core/modules/tour/src/Entity/Tour.php @@ -8,7 +8,6 @@ namespace Drupal\tour\Entity; use Drupal\Core\Config\Entity\ConfigEntityBase; -use Drupal\Core\Entity\EntityStorageInterface; use Drupal\tour\TipsPluginCollection; use Drupal\tour\TourInterface; diff --git a/core/modules/tour/src/TipPluginBase.php b/core/modules/tour/src/TipPluginBase.php index 2c226f58a..5c4a98158 100644 --- a/core/modules/tour/src/TipPluginBase.php +++ b/core/modules/tour/src/TipPluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\tour; use Drupal\Core\Plugin\PluginBase; -use Drupal\tour\TipPluginInterface; /** * Defines a base tour item implementation. diff --git a/core/modules/tour/src/TourViewBuilder.php b/core/modules/tour/src/TourViewBuilder.php index caccf1573..e5a6d9d64 100644 --- a/core/modules/tour/src/TourViewBuilder.php +++ b/core/modules/tour/src/TourViewBuilder.php @@ -8,7 +8,6 @@ namespace Drupal\tour; use Drupal\Core\Entity\EntityViewBuilder; -use Drupal\Core\Entity\EntityInterface; use Drupal\Component\Utility\Html; /** diff --git a/core/modules/tour/tour.module b/core/modules/tour/tour.module index 3b153e21b..ed53f25db 100644 --- a/core/modules/tour/tour.module +++ b/core/modules/tour/tour.module @@ -5,7 +5,6 @@ * Main functions of the module. */ -use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Routing\RouteMatchInterface; /** diff --git a/core/modules/tracker/js/tracker-history.js b/core/modules/tracker/js/tracker-history.js index fa6af55b8..877a9caec 100644 --- a/core/modules/tracker/js/tracker-history.js +++ b/core/modules/tracker/js/tracker-history.js @@ -5,7 +5,7 @@ */ (function ($, Drupal, window) { - "use strict"; + 'use strict'; /** * Render "new" and "updated" node indicators, as well as "X new" replies links. diff --git a/core/modules/update/tests/modules/update_test/update_test.module b/core/modules/update/tests/modules/update_test/update_test.module index fe01b21a6..f8de3cd8b 100644 --- a/core/modules/update/tests/modules/update_test/update_test.module +++ b/core/modules/update/tests/modules/update_test/update_test.module @@ -1,8 +1,6 @@ select('users', 'u') ->fields('u', array_keys($this->baseFields())) - ->condition('uid', 1, '>'); + ->condition('uid', 0, '>'); } /** diff --git a/core/modules/user/src/Plugin/migrate/source/d7/User.php b/core/modules/user/src/Plugin/migrate/source/d7/User.php index fc05bf3cd..fa872c638 100755 --- a/core/modules/user/src/Plugin/migrate/source/d7/User.php +++ b/core/modules/user/src/Plugin/migrate/source/d7/User.php @@ -25,7 +25,7 @@ class User extends FieldableEntity { public function query() { return $this->select('users', 'u') ->fields('u') - ->condition('uid', 1, '>'); + ->condition('uid', 0, '>'); } /** diff --git a/core/modules/user/src/Plugin/views/access/Role.php b/core/modules/user/src/Plugin/views/access/Role.php index b7bbf509b..ad779d63c 100644 --- a/core/modules/user/src/Plugin/views/access/Role.php +++ b/core/modules/user/src/Plugin/views/access/Role.php @@ -7,7 +7,6 @@ namespace Drupal\user\Plugin\views\access; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Cache\Cache; use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/user/src/Plugin/views/argument_default/User.php b/core/modules/user/src/Plugin/views/argument_default/User.php index faeb4b7b0..7d1e39c28 100644 --- a/core/modules/user/src/Plugin/views/argument_default/User.php +++ b/core/modules/user/src/Plugin/views/argument_default/User.php @@ -13,7 +13,6 @@ use Drupal\Core\Routing\RouteMatchInterface; use Drupal\views\Plugin\views\argument_default\ArgumentDefaultPluginBase; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; use Drupal\user\UserInterface; use Drupal\node\NodeInterface; diff --git a/core/modules/user/src/Plugin/views/field/UserBulkForm.php b/core/modules/user/src/Plugin/views/field/UserBulkForm.php index b5f008b73..4167a3b99 100644 --- a/core/modules/user/src/Plugin/views/field/UserBulkForm.php +++ b/core/modules/user/src/Plugin/views/field/UserBulkForm.php @@ -7,7 +7,6 @@ namespace Drupal\user\Plugin\views\field; -use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\system\Plugin\views\field\BulkForm; use Drupal\user\UserInterface; diff --git a/core/modules/user/src/Plugin/views/field/UserData.php b/core/modules/user/src/Plugin/views/field/UserData.php index 7c001868b..948cbae53 100644 --- a/core/modules/user/src/Plugin/views/field/UserData.php +++ b/core/modules/user/src/Plugin/views/field/UserData.php @@ -9,10 +9,8 @@ use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\field\FieldPluginBase; use Drupal\views\ResultRow; -use Drupal\views\ViewExecutable; use Drupal\user\UserDataInterface; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/user/src/Plugin/views/filter/Name.php b/core/modules/user/src/Plugin/views/filter/Name.php index 5794b627f..a4be2f547 100644 --- a/core/modules/user/src/Plugin/views/filter/Name.php +++ b/core/modules/user/src/Plugin/views/filter/Name.php @@ -7,7 +7,6 @@ namespace Drupal\user\Plugin\views\filter; -use Drupal\Component\Utility\Tags; use Drupal\Core\Entity\Element\EntityAutocomplete; use Drupal\Core\Form\FormStateInterface; use Drupal\user\Entity\User; diff --git a/core/modules/user/src/RoleForm.php b/core/modules/user/src/RoleForm.php index bb801eadd..ada54dd34 100644 --- a/core/modules/user/src/RoleForm.php +++ b/core/modules/user/src/RoleForm.php @@ -7,7 +7,6 @@ namespace Drupal\user; -use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityForm; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/user/src/SharedTempStoreFactory.php b/core/modules/user/src/SharedTempStoreFactory.php index c5f11e890..1a537e37d 100644 --- a/core/modules/user/src/SharedTempStoreFactory.php +++ b/core/modules/user/src/SharedTempStoreFactory.php @@ -7,7 +7,6 @@ namespace Drupal\user; -use Drupal\Component\Serialization\SerializationInterface; use Drupal\Core\KeyValueStore\KeyValueExpirableFactoryInterface; use Drupal\Core\Lock\LockBackendInterface; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/core/modules/user/src/Tests/TempStoreDatabaseTest.php b/core/modules/user/src/Tests/TempStoreDatabaseTest.php index 6e897000c..6e4d837ff 100644 --- a/core/modules/user/src/Tests/TempStoreDatabaseTest.php +++ b/core/modules/user/src/Tests/TempStoreDatabaseTest.php @@ -7,7 +7,6 @@ namespace Drupal\user\Tests; -use Drupal\Component\Serialization\PhpSerialize; use Drupal\Core\KeyValueStore\KeyValueExpirableFactory; use Drupal\simpletest\KernelTestBase; use Drupal\user\SharedTempStoreFactory; diff --git a/core/modules/user/src/Tests/UserAccountLinksTest.php b/core/modules/user/src/Tests/UserAccountLinksTest.php index cb3ea8871..5686fbea0 100644 --- a/core/modules/user/src/Tests/UserAccountLinksTest.php +++ b/core/modules/user/src/Tests/UserAccountLinksTest.php @@ -7,7 +7,6 @@ namespace Drupal\user\Tests; -use Drupal\Core\Menu\MenuTreeParameters; use Drupal\simpletest\WebTestBase; /** diff --git a/core/modules/user/src/Tests/UserEntityTest.php b/core/modules/user/src/Tests/UserEntityTest.php index a4601ef69..a9954f6b8 100644 --- a/core/modules/user/src/Tests/UserEntityTest.php +++ b/core/modules/user/src/Tests/UserEntityTest.php @@ -7,7 +7,6 @@ namespace Drupal\user\Tests; -use Drupal\Core\Language\LanguageInterface; use Drupal\simpletest\KernelTestBase; use Drupal\user\Entity\User; use Drupal\user\RoleInterface; diff --git a/core/modules/user/src/Tests/UserLoginTest.php b/core/modules/user/src/Tests/UserLoginTest.php index 610692772..39ffed57b 100644 --- a/core/modules/user/src/Tests/UserLoginTest.php +++ b/core/modules/user/src/Tests/UserLoginTest.php @@ -8,7 +8,6 @@ namespace Drupal\user\Tests; use Drupal\simpletest\WebTestBase; -use Drupal\Core\Password\PhpassHashedPassword; use Drupal\user\Entity\User; /** diff --git a/core/modules/user/src/Tests/UserPermissionsTest.php b/core/modules/user/src/Tests/UserPermissionsTest.php index e5baa49b2..42bbad12e 100644 --- a/core/modules/user/src/Tests/UserPermissionsTest.php +++ b/core/modules/user/src/Tests/UserPermissionsTest.php @@ -10,7 +10,6 @@ use Drupal\simpletest\WebTestBase; use Drupal\user\RoleInterface; use Drupal\user\Entity\Role; -use Drupal\user\RoleStorage; /** * Verify that role permissions can be added and removed via the permissions diff --git a/core/modules/user/src/Tests/UserTokenReplaceTest.php b/core/modules/user/src/Tests/UserTokenReplaceTest.php index 5a472f453..b7877d879 100644 --- a/core/modules/user/src/Tests/UserTokenReplaceTest.php +++ b/core/modules/user/src/Tests/UserTokenReplaceTest.php @@ -157,7 +157,7 @@ function testUserTokenReplacement() { foreach ($tests as $input => $expected) { foreach (array($user1, $user2) as $account) { $output = $token_service->replace($input, ['user' => $account], ['langcode' => 'de', 'callback' => 'user_mail_tokens', 'clear' => TRUE]); - $this->assertTrue(strpos($output, $link) === 0, "Generated URL in in the requested language."); + $this->assertTrue(strpos($output, $link) === 0, "Generated URL in the requested language."); } } diff --git a/core/modules/user/src/Tests/UserValidationTest.php b/core/modules/user/src/Tests/UserValidationTest.php index f39e11ee2..4891d5a15 100644 --- a/core/modules/user/src/Tests/UserValidationTest.php +++ b/core/modules/user/src/Tests/UserValidationTest.php @@ -7,9 +7,7 @@ namespace Drupal\user\Tests; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Entity\EntityInterface; -use Drupal\Core\Field\Plugin\Field\FieldType\EmailItem; use Drupal\Core\Language\Language; use Drupal\Core\Render\Element\Email; use Drupal\simpletest\KernelTestBase; diff --git a/core/modules/user/src/Tests/Views/AccessRoleTest.php b/core/modules/user/src/Tests/Views/AccessRoleTest.php index 043971a26..a6230b3ab 100644 --- a/core/modules/user/src/Tests/Views/AccessRoleTest.php +++ b/core/modules/user/src/Tests/Views/AccessRoleTest.php @@ -11,7 +11,6 @@ use Drupal\user\Plugin\views\access\Role; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Views; -use Symfony\Component\HttpFoundation\Request; /** * Tests views role access plugin. diff --git a/core/modules/user/src/Tests/Views/HandlerFieldRoleTest.php b/core/modules/user/src/Tests/Views/HandlerFieldRoleTest.php index 9434925d5..5f15e7122 100644 --- a/core/modules/user/src/Tests/Views/HandlerFieldRoleTest.php +++ b/core/modules/user/src/Tests/Views/HandlerFieldRoleTest.php @@ -8,7 +8,6 @@ namespace Drupal\user\Tests\Views; use Drupal\Component\Utility\Html; -use Drupal\views\Views; use Drupal\user\Entity\User; /** diff --git a/core/modules/user/src/Tests/Views/HandlerFilterRolesTest.php b/core/modules/user/src/Tests/Views/HandlerFilterRolesTest.php index 3268eecf5..b105583d6 100644 --- a/core/modules/user/src/Tests/Views/HandlerFilterRolesTest.php +++ b/core/modules/user/src/Tests/Views/HandlerFilterRolesTest.php @@ -9,7 +9,6 @@ use Drupal\user\Entity\Role; use Drupal\views\Entity\View; -use Drupal\views\Views; /** * Tests the roles filter handler. diff --git a/core/modules/user/src/UserDataInterface.php b/core/modules/user/src/UserDataInterface.php index e32c4fb39..d7305285f 100644 --- a/core/modules/user/src/UserDataInterface.php +++ b/core/modules/user/src/UserDataInterface.php @@ -7,8 +7,6 @@ namespace Drupal\user; -use Drupal\Core\Database\Connection; - /** * Defines the user data service interface. */ diff --git a/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php b/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php index 4f004a0e3..56c9a6da1 100644 --- a/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php +++ b/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php @@ -8,8 +8,7 @@ namespace Drupal\Tests\user\Unit\Plugin\Core\Entity; use Drupal\Tests\Core\Session\UserSessionTest; -use Drupal\user\Entity\User; - use Drupal\user\RoleInterface; +use Drupal\user\RoleInterface; /** * @coversDefaultClass \Drupal\user\Entity\User diff --git a/core/modules/user/user.api.php b/core/modules/user/user.api.php index 26e7f5a67..d0716c90b 100644 --- a/core/modules/user/user.api.php +++ b/core/modules/user/user.api.php @@ -1,7 +1,5 @@ condition('uid', $user->id()) + ->condition('uid', $account->id()) ->execute(); node_mass_update($nodes, array('status' => 0), NULL, TRUE); break; @@ -53,7 +51,7 @@ function hook_user_cancel($edit, $account, $method) { // Anonymize nodes (current revisions). module_load_include('inc', 'node', 'node.admin'); $nodes = \Drupal::entityQuery('node') - ->condition('uid', $user->id()) + ->condition('uid', $account->id()) ->execute(); node_mass_update($nodes, array('uid' => 0), NULL, TRUE); // Anonymize old revisions. diff --git a/core/modules/user/user.js b/core/modules/user/user.js index 7c829b14c..f4602c676 100644 --- a/core/modules/user/user.js +++ b/core/modules/user/user.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Attach handlers to evaluate the strength of any password fields and to diff --git a/core/modules/user/user.module b/core/modules/user/user.module index 7782954f1..3b80af6d7 100644 --- a/core/modules/user/user.module +++ b/core/modules/user/user.module @@ -7,7 +7,6 @@ use Drupal\Core\Asset\AttachedAssetsInterface; use Drupal\Core\Cache\Cache; use Drupal\Core\Entity\Display\EntityViewDisplayInterface; use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Element; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; @@ -888,7 +887,7 @@ function user_view($account, $view_mode = 'full', $langcode = NULL) { /** * Constructs a drupal_render() style array from an array of loaded users. * - * @param \Drupal\user\UserInterface[] $account + * @param \Drupal\user\UserInterface[] $accounts * An array of user accounts as returned by User::loadMultiple(). * @param string $view_mode * (optional) View mode, e.g., 'full', 'teaser', etc. Defaults to 'teaser.' @@ -1190,7 +1189,7 @@ function user_role_revoke_permissions($rid, array $permissions = array()) { * language. * * @return array - * An array containint various information about the message. + * An array containing various information about the message. * See \Drupal\Core\Mail\MailManagerInterface::mail() for details. * * @see user_mail_tokens() diff --git a/core/modules/user/user.permissions.js b/core/modules/user/user.permissions.js index abdffa75f..ec90b3837 100644 --- a/core/modules/user/user.permissions.js +++ b/core/modules/user/user.permissions.js @@ -5,7 +5,7 @@ (function ($) { - "use strict"; + 'use strict'; /** * Shows checked and disabled checkboxes for inherited permissions. @@ -43,7 +43,7 @@ // permission table would be polluted with redundant entries. This // is deliberate, but desirable when we automatically check them. var $dummy = $('') - .attr('title', Drupal.t("This permission is inherited from the authenticated user role.")) + .attr('title', Drupal.t('This permission is inherited from the authenticated user role.')) .hide(); $table diff --git a/core/modules/views/js/ajax_view.js b/core/modules/views/js/ajax_view.js index 9145ea929..57bbb45c7 100644 --- a/core/modules/views/js/ajax_view.js +++ b/core/modules/views/js/ajax_view.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Attaches the AJAX behavior to exposed filters forms and key View links. @@ -56,7 +56,7 @@ // If there are multiple views this might've ended up showing up multiple // times. - if (ajax_path.constructor.toString().indexOf("Array") !== -1) { + if (ajax_path.constructor.toString().indexOf('Array') !== -1) { ajax_path = ajax_path[0]; } diff --git a/core/modules/views/js/base.js b/core/modules/views/js/base.js index 2fa7f79b8..ae06b76c0 100644 --- a/core/modules/views/js/base.js +++ b/core/modules/views/js/base.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * @namespace diff --git a/core/modules/views/src/Analyzer.php b/core/modules/views/src/Analyzer.php index 7a2999eb7..bd0b6ac1c 100644 --- a/core/modules/views/src/Analyzer.php +++ b/core/modules/views/src/Analyzer.php @@ -8,7 +8,6 @@ namespace Drupal\views; use Drupal\Core\Extension\ModuleHandlerInterface; -use Drupal\views\ViewExecutable; /** * This tool is a small plugin manager to perform analysis on a view and diff --git a/core/modules/views/src/Annotation/ViewsAccess.php b/core/modules/views/src/Annotation/ViewsAccess.php index dcc33b34e..7458f2759 100644 --- a/core/modules/views/src/Annotation/ViewsAccess.php +++ b/core/modules/views/src/Annotation/ViewsAccess.php @@ -7,7 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; /** * Defines a Plugin annotation object for views access plugins. diff --git a/core/modules/views/src/Annotation/ViewsArgumentDefault.php b/core/modules/views/src/Annotation/ViewsArgumentDefault.php index 1e6215f5e..54da51888 100644 --- a/core/modules/views/src/Annotation/ViewsArgumentDefault.php +++ b/core/modules/views/src/Annotation/ViewsArgumentDefault.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views argument default plugins. * diff --git a/core/modules/views/src/Annotation/ViewsArgumentValidator.php b/core/modules/views/src/Annotation/ViewsArgumentValidator.php index a5f1ee396..f9fd20cfb 100644 --- a/core/modules/views/src/Annotation/ViewsArgumentValidator.php +++ b/core/modules/views/src/Annotation/ViewsArgumentValidator.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views argument validator plugins. * diff --git a/core/modules/views/src/Annotation/ViewsCache.php b/core/modules/views/src/Annotation/ViewsCache.php index 6a89799ff..4b5bfdf45 100644 --- a/core/modules/views/src/Annotation/ViewsCache.php +++ b/core/modules/views/src/Annotation/ViewsCache.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views cache plugins. * diff --git a/core/modules/views/src/Annotation/ViewsDisplay.php b/core/modules/views/src/Annotation/ViewsDisplay.php index 42f436175..4cda70291 100644 --- a/core/modules/views/src/Annotation/ViewsDisplay.php +++ b/core/modules/views/src/Annotation/ViewsDisplay.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views display plugins. * diff --git a/core/modules/views/src/Annotation/ViewsExposedForm.php b/core/modules/views/src/Annotation/ViewsExposedForm.php index f0b06b576..0fa318e03 100644 --- a/core/modules/views/src/Annotation/ViewsExposedForm.php +++ b/core/modules/views/src/Annotation/ViewsExposedForm.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views exposed form plugins. * diff --git a/core/modules/views/src/Annotation/ViewsPager.php b/core/modules/views/src/Annotation/ViewsPager.php index cfde42526..3541f2825 100644 --- a/core/modules/views/src/Annotation/ViewsPager.php +++ b/core/modules/views/src/Annotation/ViewsPager.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views pager plugins. * diff --git a/core/modules/views/src/Annotation/ViewsQuery.php b/core/modules/views/src/Annotation/ViewsQuery.php index b759ccf9d..2dc0f4cbb 100644 --- a/core/modules/views/src/Annotation/ViewsQuery.php +++ b/core/modules/views/src/Annotation/ViewsQuery.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views query plugins. * diff --git a/core/modules/views/src/Annotation/ViewsRow.php b/core/modules/views/src/Annotation/ViewsRow.php index 57c86a70a..1d4c89472 100644 --- a/core/modules/views/src/Annotation/ViewsRow.php +++ b/core/modules/views/src/Annotation/ViewsRow.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views row plugins. * diff --git a/core/modules/views/src/Annotation/ViewsStyle.php b/core/modules/views/src/Annotation/ViewsStyle.php index 07d2a167b..5c6a0b002 100644 --- a/core/modules/views/src/Annotation/ViewsStyle.php +++ b/core/modules/views/src/Annotation/ViewsStyle.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views style plugins. * diff --git a/core/modules/views/src/Annotation/ViewsWizard.php b/core/modules/views/src/Annotation/ViewsWizard.php index f31e18d37..f76440ba3 100644 --- a/core/modules/views/src/Annotation/ViewsWizard.php +++ b/core/modules/views/src/Annotation/ViewsWizard.php @@ -7,8 +7,6 @@ namespace Drupal\views\Annotation; -use Drupal\views\Annotation\ViewsPluginAnnotationBase; - /** * Defines a Plugin annotation object for views wizard plugins. * diff --git a/core/modules/views/src/Controller/ViewAjaxController.php b/core/modules/views/src/Controller/ViewAjaxController.php index 01e69ef05..bd2f3c18e 100644 --- a/core/modules/views/src/Controller/ViewAjaxController.php +++ b/core/modules/views/src/Controller/ViewAjaxController.php @@ -8,7 +8,6 @@ namespace Drupal\views\Controller; use Drupal\Component\Utility\UrlHelper; -use Drupal\Core\Ajax\AjaxResponse; use Drupal\Core\Ajax\ReplaceCommand; use Drupal\Core\DependencyInjection\ContainerInjectionInterface; use Drupal\Core\Entity\EntityStorageInterface; diff --git a/core/modules/views/src/Entity/Render/EntityFieldRenderer.php b/core/modules/views/src/Entity/Render/EntityFieldRenderer.php index 9e94a6389..f2a3778d4 100644 --- a/core/modules/views/src/Entity/Render/EntityFieldRenderer.php +++ b/core/modules/views/src/Entity/Render/EntityFieldRenderer.php @@ -8,7 +8,6 @@ namespace Drupal\views\Entity\Render; use Drupal\Core\Entity\Entity\EntityViewDisplay; -use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Entity\EntityTypeInterface; use Drupal\Core\Language\LanguageManagerInterface; diff --git a/core/modules/views/src/EventSubscriber/RouteSubscriber.php b/core/modules/views/src/EventSubscriber/RouteSubscriber.php index db0714039..aed4bc12f 100644 --- a/core/modules/views/src/EventSubscriber/RouteSubscriber.php +++ b/core/modules/views/src/EventSubscriber/RouteSubscriber.php @@ -15,8 +15,6 @@ use Drupal\views\ViewExecutable; use Drupal\views\Views; use Symfony\Component\Routing\RouteCollection; -use Symfony\Component\HttpKernel\Event\GetResponseForControllerResultEvent; -use Symfony\Component\HttpKernel\KernelEvents; /** * Builds up the routes of all views. diff --git a/core/modules/views/src/Form/ViewsExposedForm.php b/core/modules/views/src/Form/ViewsExposedForm.php index aee99d672..e2b91a570 100644 --- a/core/modules/views/src/Form/ViewsExposedForm.php +++ b/core/modules/views/src/Form/ViewsExposedForm.php @@ -8,7 +8,6 @@ namespace Drupal\views\Form; use Drupal\Component\Utility\Html; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Form\FormBase; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; diff --git a/core/modules/views/src/Plugin/Block/ViewsBlock.php b/core/modules/views/src/Plugin/Block/ViewsBlock.php index 4c8a8b4ad..20dbace38 100644 --- a/core/modules/views/src/Plugin/Block/ViewsBlock.php +++ b/core/modules/views/src/Plugin/Block/ViewsBlock.php @@ -8,10 +8,8 @@ namespace Drupal\views\Plugin\Block; use Drupal\Component\Utility\Xss; -use Drupal\Core\Config\Entity\Query\Query; use Drupal\Core\Form\FormStateInterface; use Drupal\views\Element\View; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * Provides a generic Views block. diff --git a/core/modules/views/src/Plugin/Derivative/ViewsLocalTask.php b/core/modules/views/src/Plugin/Derivative/ViewsLocalTask.php index 343dc76dc..b0527ee58 100644 --- a/core/modules/views/src/Plugin/Derivative/ViewsLocalTask.php +++ b/core/modules/views/src/Plugin/Derivative/ViewsLocalTask.php @@ -12,7 +12,6 @@ use Drupal\Component\Plugin\Derivative\DeriverBase; use Drupal\Core\Plugin\Discovery\ContainerDeriverInterface; use Drupal\Core\Routing\RouteProviderInterface; -use Drupal\views\ViewEntityInterface; use Drupal\views\Views; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/views/src/Plugin/views/HandlerBase.php b/core/modules/views/src/Plugin/views/HandlerBase.php index 47e0c13c7..b5bb16d6f 100644 --- a/core/modules/views/src/Plugin/views/HandlerBase.php +++ b/core/modules/views/src/Plugin/views/HandlerBase.php @@ -18,7 +18,6 @@ use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Render\ViewsRenderPipelineMarkup; use Drupal\views\ViewExecutable; -use Drupal\Core\Database\Database; use Drupal\views\Views; use Drupal\views\ViewsData; diff --git a/core/modules/views/src/Plugin/views/area/Entity.php b/core/modules/views/src/Plugin/views/area/Entity.php index ed172329d..eb2f0f30e 100644 --- a/core/modules/views/src/Plugin/views/area/Entity.php +++ b/core/modules/views/src/Plugin/views/area/Entity.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\area; -use Drupal\Component\Uuid\Uuid; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\display\DisplayPluginBase; diff --git a/core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php b/core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php index adb9126e4..2a9fe84ae 100644 --- a/core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php +++ b/core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php @@ -14,7 +14,6 @@ use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Element; -use Drupal\views\Plugin\views\PluginBase; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\HandlerBase; diff --git a/core/modules/views/src/Plugin/views/argument/Date.php b/core/modules/views/src/Plugin/views/argument/Date.php index c737d38b0..2186fa1af 100644 --- a/core/modules/views/src/Plugin/views/argument/Date.php +++ b/core/modules/views/src/Plugin/views/argument/Date.php @@ -7,13 +7,11 @@ namespace Drupal\views\Plugin\views\argument; -use Drupal\Core\Database\Database; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\node\NodeInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Abstract argument handler for dates. diff --git a/core/modules/views/src/Plugin/views/argument_default/ArgumentDefaultPluginBase.php b/core/modules/views/src/Plugin/views/argument_default/ArgumentDefaultPluginBase.php index b9ebbbc2e..ff58784df 100644 --- a/core/modules/views/src/Plugin/views/argument_default/ArgumentDefaultPluginBase.php +++ b/core/modules/views/src/Plugin/views/argument_default/ArgumentDefaultPluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\views\Plugin\views\argument_default; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\argument\ArgumentPluginBase; use Drupal\views\Plugin\views\PluginBase; diff --git a/core/modules/views/src/Plugin/views/argument_default/Raw.php b/core/modules/views/src/Plugin/views/argument_default/Raw.php index 77299fd39..d3295c15a 100644 --- a/core/modules/views/src/Plugin/views/argument_default/Raw.php +++ b/core/modules/views/src/Plugin/views/argument_default/Raw.php @@ -13,7 +13,6 @@ use Drupal\Core\Path\AliasManagerInterface; use Drupal\Core\Path\CurrentPathStack; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Default argument plugin to use the raw value from the URL. diff --git a/core/modules/views/src/Plugin/views/argument_validator/ArgumentValidatorPluginBase.php b/core/modules/views/src/Plugin/views/argument_validator/ArgumentValidatorPluginBase.php index 7a6cf67f4..a21dfb058 100644 --- a/core/modules/views/src/Plugin/views/argument_validator/ArgumentValidatorPluginBase.php +++ b/core/modules/views/src/Plugin/views/argument_validator/ArgumentValidatorPluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\views\Plugin\views\argument_validator; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\argument\ArgumentPluginBase; use Drupal\views\Plugin\views\PluginBase; diff --git a/core/modules/views/src/Plugin/views/argument_validator/Entity.php b/core/modules/views/src/Plugin/views/argument_validator/Entity.php index b5362b014..4f918e4c5 100644 --- a/core/modules/views/src/Plugin/views/argument_validator/Entity.php +++ b/core/modules/views/src/Plugin/views/argument_validator/Entity.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\argument_validator; -use Drupal\Core\Config\Entity\ConfigEntityInterface; use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; diff --git a/core/modules/views/src/Plugin/views/cache/CachePluginBase.php b/core/modules/views/src/Plugin/views/cache/CachePluginBase.php index 9b3112639..f04232e4f 100644 --- a/core/modules/views/src/Plugin/views/cache/CachePluginBase.php +++ b/core/modules/views/src/Plugin/views/cache/CachePluginBase.php @@ -12,7 +12,6 @@ use Drupal\views\Plugin\views\PluginBase; use Drupal\Core\Database\Query\Select; use Drupal\views\ResultRow; -use Symfony\Component\DependencyInjection\ContainerInterface; /** * @defgroup views_cache_plugins Views cache plugins diff --git a/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php b/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php index 54121c5c1..21ea4d25a 100644 --- a/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php +++ b/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php @@ -17,15 +17,12 @@ use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Plugin\PluginDependencyTrait; use Drupal\Core\Session\AccountInterface; -use Drupal\Core\Theme\Registry; use Drupal\Core\Url; use Drupal\views\Form\ViewsForm; use Drupal\views\Plugin\views\area\AreaPluginBase; use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\PluginBase; use Drupal\views\Views; -use Symfony\Cmf\Component\Routing\RouteObjectInterface; -use Symfony\Component\DependencyInjection\Exception\RuntimeException as DependencyInjectionRuntimeException; /** * Base class for views display plugins. diff --git a/core/modules/views/src/Plugin/views/display/DisplayPluginInterface.php b/core/modules/views/src/Plugin/views/display/DisplayPluginInterface.php index 5380c21a9..659b3bb61 100644 --- a/core/modules/views/src/Plugin/views/display/DisplayPluginInterface.php +++ b/core/modules/views/src/Plugin/views/display/DisplayPluginInterface.php @@ -37,8 +37,21 @@ */ interface DisplayPluginInterface { + /** + * Initializes the display plugin. + * + * @param \Drupal\views\ViewExecutable $view + * The views executable. + * @param array $display + * The display that will be populated and attached to the view. + * @param array $options + * (optional) The options for the display plugin. Defaults to NULL. + */ public function initDisplay(ViewExecutable $view, array &$display, array &$options = NULL); + /** + * Destroys the display's components and the display itself. + */ public function destroy(); /** diff --git a/core/modules/views/src/Plugin/views/display/Feed.php b/core/modules/views/src/Plugin/views/display/Feed.php index 9a02de093..d01cbb8db 100644 --- a/core/modules/views/src/Plugin/views/display/Feed.php +++ b/core/modules/views/src/Plugin/views/display/Feed.php @@ -12,7 +12,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\views\ViewExecutable; use Drupal\views\Views; -use Symfony\Component\HttpFoundation\Response; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; /** diff --git a/core/modules/views/src/Plugin/views/display/Page.php b/core/modules/views/src/Plugin/views/display/Page.php index 656105c82..2c45ccfa5 100644 --- a/core/modules/views/src/Plugin/views/display/Page.php +++ b/core/modules/views/src/Plugin/views/display/Page.php @@ -13,8 +13,6 @@ use Drupal\Core\State\StateInterface; use Drupal\Core\Routing\RouteProviderInterface; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; -use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; use Symfony\Component\Routing\Route; /** diff --git a/core/modules/views/src/Plugin/views/display/PathPluginBase.php b/core/modules/views/src/Plugin/views/display/PathPluginBase.php index 599e7f083..aab4f6d0e 100644 --- a/core/modules/views/src/Plugin/views/display/PathPluginBase.php +++ b/core/modules/views/src/Plugin/views/display/PathPluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\views\Plugin\views\display; use Drupal\Component\Utility\UrlHelper; -use Drupal\Core\Access\AccessManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Language\LanguageInterface; use Drupal\Core\Routing\UrlGeneratorTrait; @@ -17,7 +16,6 @@ use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\Url; use Drupal\views\Views; - use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; diff --git a/core/modules/views/src/Plugin/views/display_extender/DisplayExtenderPluginBase.php b/core/modules/views/src/Plugin/views/display_extender/DisplayExtenderPluginBase.php index aebc61442..760df48b6 100644 --- a/core/modules/views/src/Plugin/views/display_extender/DisplayExtenderPluginBase.php +++ b/core/modules/views/src/Plugin/views/display_extender/DisplayExtenderPluginBase.php @@ -8,7 +8,6 @@ namespace Drupal\views\Plugin\views\display_extender; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\PluginBase; /** diff --git a/core/modules/views/src/Plugin/views/exposed_form/ExposedFormPluginBase.php b/core/modules/views/src/Plugin/views/exposed_form/ExposedFormPluginBase.php index c30f89922..99a5ad031 100644 --- a/core/modules/views/src/Plugin/views/exposed_form/ExposedFormPluginBase.php +++ b/core/modules/views/src/Plugin/views/exposed_form/ExposedFormPluginBase.php @@ -12,9 +12,6 @@ use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormState; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\Form\ViewsExposedForm; -use Drupal\views\ViewExecutable; -use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\PluginBase; /** diff --git a/core/modules/views/src/Plugin/views/field/EntityLabel.php b/core/modules/views/src/Plugin/views/field/EntityLabel.php index 58b968734..dc2dd2eb5 100644 --- a/core/modules/views/src/Plugin/views/field/EntityLabel.php +++ b/core/modules/views/src/Plugin/views/field/EntityLabel.php @@ -9,7 +9,6 @@ use Drupal\Core\Entity\EntityManagerInterface; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\Plugin\views\field\FieldPluginBase; use Drupal\views\ResultRow; use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; diff --git a/core/modules/views/src/Plugin/views/field/FieldPluginBase.php b/core/modules/views/src/Plugin/views/field/FieldPluginBase.php index 7275bc44c..fb2ec961a 100644 --- a/core/modules/views/src/Plugin/views/field/FieldPluginBase.php +++ b/core/modules/views/src/Plugin/views/field/FieldPluginBase.php @@ -8,13 +8,11 @@ namespace Drupal\views\Plugin\views\field; use Drupal\Component\Utility\Html; -use Drupal\Component\Utility\NestedArray; use Drupal\Component\Utility\SafeMarkup; use Drupal\Component\Render\MarkupInterface; use Drupal\Component\Utility\Unicode; use Drupal\Component\Utility\UrlHelper; use Drupal\Component\Utility\Xss; -use Drupal\Core\Cache\Cache; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Renderer; use Drupal\Core\Url as CoreUrl; diff --git a/core/modules/views/src/Plugin/views/field/LinkBase.php b/core/modules/views/src/Plugin/views/field/LinkBase.php index f57710a49..6ffc30469 100644 --- a/core/modules/views/src/Plugin/views/field/LinkBase.php +++ b/core/modules/views/src/Plugin/views/field/LinkBase.php @@ -8,8 +8,6 @@ namespace Drupal\views\Plugin\views\field; use Drupal\Core\Access\AccessManagerInterface; -use Drupal\Core\Access\AccessResultInterface; -use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Routing\RedirectDestinationTrait; diff --git a/core/modules/views/src/Plugin/views/field/MachineName.php b/core/modules/views/src/Plugin/views/field/MachineName.php index a31d7f255..d6f980337 100644 --- a/core/modules/views/src/Plugin/views/field/MachineName.php +++ b/core/modules/views/src/Plugin/views/field/MachineName.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\field; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Form\FormStateInterface; use Drupal\views\ResultRow; diff --git a/core/modules/views/src/Plugin/views/filter/Bundle.php b/core/modules/views/src/Plugin/views/filter/Bundle.php index e328dfc55..cfea7a84c 100644 --- a/core/modules/views/src/Plugin/views/filter/Bundle.php +++ b/core/modules/views/src/Plugin/views/filter/Bundle.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\filter; -use Drupal\Core\Config\Entity\ConfigEntityInterface; use Drupal\Core\Entity\EntityManagerInterface; use Drupal\views\ViewExecutable; use Drupal\views\Plugin\views\display\DisplayPluginBase; diff --git a/core/modules/views/src/Plugin/views/filter/NumericFilter.php b/core/modules/views/src/Plugin/views/filter/NumericFilter.php index 51bd8f791..116402843 100644 --- a/core/modules/views/src/Plugin/views/filter/NumericFilter.php +++ b/core/modules/views/src/Plugin/views/filter/NumericFilter.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\filter; -use Drupal\Core\Database\Database; use Drupal\Core\Form\FormStateInterface; /** diff --git a/core/modules/views/src/Plugin/views/filter/StringFilter.php b/core/modules/views/src/Plugin/views/filter/StringFilter.php index ffa2a00ea..406823745 100644 --- a/core/modules/views/src/Plugin/views/filter/StringFilter.php +++ b/core/modules/views/src/Plugin/views/filter/StringFilter.php @@ -7,7 +7,6 @@ namespace Drupal\views\Plugin\views\filter; -use Drupal\Core\Database\Database; use Drupal\Core\Form\FormStateInterface; /** diff --git a/core/modules/views/src/Plugin/views/pager/PagerPluginBase.php b/core/modules/views/src/Plugin/views/pager/PagerPluginBase.php index 72b578a60..68f856752 100644 --- a/core/modules/views/src/Plugin/views/pager/PagerPluginBase.php +++ b/core/modules/views/src/Plugin/views/pager/PagerPluginBase.php @@ -9,7 +9,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\PluginBase; -use Drupal\views\ViewExecutable; /** * @defgroup views_pager_plugins Views pager plugins diff --git a/core/modules/views/src/Plugin/views/pager/SqlBase.php b/core/modules/views/src/Plugin/views/pager/SqlBase.php index 0372bd6f0..854018c3f 100644 --- a/core/modules/views/src/Plugin/views/pager/SqlBase.php +++ b/core/modules/views/src/Plugin/views/pager/SqlBase.php @@ -140,7 +140,7 @@ public function buildOptionsForm(&$form, FormStateInterface $form_state) { $form['expose']['items_per_page_options_all'] = array( '#type' => 'checkbox', - '#title' => $this->t('Allow user to to display all items'), + '#title' => $this->t('Allow user to display all items'), '#default_value' => $this->options['expose']['items_per_page_options_all'], ); diff --git a/core/modules/views/src/Plugin/views/query/QueryPluginBase.php b/core/modules/views/src/Plugin/views/query/QueryPluginBase.php index f73f16f70..e16b37be0 100644 --- a/core/modules/views/src/Plugin/views/query/QueryPluginBase.php +++ b/core/modules/views/src/Plugin/views/query/QueryPluginBase.php @@ -11,7 +11,6 @@ use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\PluginBase; -use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\ViewExecutable; use Drupal\views\Views; diff --git a/core/modules/views/src/Plugin/views/relationship/EntityReverse.php b/core/modules/views/src/Plugin/views/relationship/EntityReverse.php index 49d552791..ffc0cb997 100644 --- a/core/modules/views/src/Plugin/views/relationship/EntityReverse.php +++ b/core/modules/views/src/Plugin/views/relationship/EntityReverse.php @@ -8,9 +8,6 @@ namespace Drupal\views\Plugin\views\relationship; use Drupal\views\Plugin\ViewsHandlerManager; -use Drupal\views\Plugin\views\display\DisplayPluginBase; -use Drupal\views\Plugin\views\relationship\RelationshipPluginBase; -use Drupal\views\ViewExecutable; use Drupal\views\Views; use Symfony\Component\DependencyInjection\ContainerInterface; diff --git a/core/modules/views/src/Plugin/views/row/RowPluginBase.php b/core/modules/views/src/Plugin/views/row/RowPluginBase.php index 059a41586..931fd5239 100644 --- a/core/modules/views/src/Plugin/views/row/RowPluginBase.php +++ b/core/modules/views/src/Plugin/views/row/RowPluginBase.php @@ -9,7 +9,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\PluginBase; -use Drupal\views\ViewExecutable; use Drupal\views\Views; /** diff --git a/core/modules/views/src/Plugin/views/style/DefaultSummary.php b/core/modules/views/src/Plugin/views/style/DefaultSummary.php index 63cf9dc5b..db62f0e93 100644 --- a/core/modules/views/src/Plugin/views/style/DefaultSummary.php +++ b/core/modules/views/src/Plugin/views/style/DefaultSummary.php @@ -8,7 +8,6 @@ namespace Drupal\views\Plugin\views\style; use Drupal\Core\Form\FormStateInterface; -use Drupal\views\Plugin\views\style\StylePluginBase; /** * The default style plugin for summaries. diff --git a/core/modules/views/src/Plugin/views/style/Table.php b/core/modules/views/src/Plugin/views/style/Table.php index 92cd120a2..7e9c2e3cc 100644 --- a/core/modules/views/src/Plugin/views/style/Table.php +++ b/core/modules/views/src/Plugin/views/style/Table.php @@ -7,13 +7,10 @@ namespace Drupal\views\Plugin\views\style; -use Drupal\Component\Plugin\Discovery\DiscoveryInterface; use Drupal\Component\Utility\Html; use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\views\Plugin\views\wizard\WizardInterface; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\HttpFoundation\Request; /** * Style plugin to render each item as a row in a table. diff --git a/core/modules/views/src/Plugin/views/wizard/WizardPluginBase.php b/core/modules/views/src/Plugin/views/wizard/WizardPluginBase.php index 946d752b8..4632db4db 100644 --- a/core/modules/views/src/Plugin/views/wizard/WizardPluginBase.php +++ b/core/modules/views/src/Plugin/views/wizard/WizardPluginBase.php @@ -15,7 +15,6 @@ use Drupal\views_ui\ViewUI; use Drupal\views\Plugin\views\display\DisplayPluginBase; use Drupal\views\Plugin\views\PluginBase; -use Drupal\views\Plugin\views\wizard\WizardInterface; /** * @defgroup views_wizard_plugins Views wizard plugins diff --git a/core/modules/views/src/Tests/EventSubscriber/ViewsEntitySchemaSubscriberIntegrationTest.php b/core/modules/views/src/Tests/EventSubscriber/ViewsEntitySchemaSubscriberIntegrationTest.php index b7e29b54d..1f8491a3d 100644 --- a/core/modules/views/src/Tests/EventSubscriber/ViewsEntitySchemaSubscriberIntegrationTest.php +++ b/core/modules/views/src/Tests/EventSubscriber/ViewsEntitySchemaSubscriberIntegrationTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Entity\EntityTypeEvent; use Drupal\Core\Entity\EntityTypeEvents; use Drupal\system\Tests\Entity\EntityDefinitionTestTrait; -use Drupal\views\Entity\View; use Drupal\views\Tests\ViewKernelTestBase; /** diff --git a/core/modules/views/src/Tests/Handler/FieldDropButtonTest.php b/core/modules/views/src/Tests/Handler/FieldDropButtonTest.php index 5de614bc3..574f7e4dc 100644 --- a/core/modules/views/src/Tests/Handler/FieldDropButtonTest.php +++ b/core/modules/views/src/Tests/Handler/FieldDropButtonTest.php @@ -7,8 +7,6 @@ namespace Drupal\views\Tests\Handler; -use Drupal\views\Tests\ViewTestData; - /** * Tests the dropbutton field handler. * diff --git a/core/modules/views/src/Tests/Handler/FieldEntityOperationsTest.php b/core/modules/views/src/Tests/Handler/FieldEntityOperationsTest.php index e92b0249b..665c01620 100644 --- a/core/modules/views/src/Tests/Handler/FieldEntityOperationsTest.php +++ b/core/modules/views/src/Tests/Handler/FieldEntityOperationsTest.php @@ -8,7 +8,6 @@ namespace Drupal\views\Tests\Handler; use Drupal\Core\Url; -use Drupal\entity_test\Entity\EntityTest; use Drupal\language\Entity\ConfigurableLanguage; use Drupal\node\Entity\Node; diff --git a/core/modules/views/src/Tests/Plugin/AccessTest.php b/core/modules/views/src/Tests/Plugin/AccessTest.php index 5ee6c98f8..b16603d8f 100644 --- a/core/modules/views/src/Tests/Plugin/AccessTest.php +++ b/core/modules/views/src/Tests/Plugin/AccessTest.php @@ -7,7 +7,6 @@ namespace Drupal\views\Tests\Plugin; -use Drupal\Core\Cache\Cache; use Drupal\views\Tests\ViewTestData; use Drupal\views\Views; diff --git a/core/modules/views/src/Tests/Plugin/DisplayExtenderTest.php b/core/modules/views/src/Tests/Plugin/DisplayExtenderTest.php index 37ce57def..019fb44e3 100644 --- a/core/modules/views/src/Tests/Plugin/DisplayExtenderTest.php +++ b/core/modules/views/src/Tests/Plugin/DisplayExtenderTest.php @@ -7,7 +7,6 @@ namespace Drupal\views\Tests\Plugin; -use Drupal\views\Tests\Plugin\PluginTestBase; use Drupal\views\Views; /** diff --git a/core/modules/views/src/Tests/Plugin/DisplayPageTest.php b/core/modules/views/src/Tests/Plugin/DisplayPageTest.php index d04d95125..5ce2d3f2a 100644 --- a/core/modules/views/src/Tests/Plugin/DisplayPageTest.php +++ b/core/modules/views/src/Tests/Plugin/DisplayPageTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Session\AnonymousUserSession; use Drupal\views\Views; use Drupal\views\Tests\ViewKernelTestBase; -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\HttpKernelInterface; diff --git a/core/modules/views/src/Tests/Plugin/StyleGridTest.php b/core/modules/views/src/Tests/Plugin/StyleGridTest.php index ea212ddde..6dbac6bd9 100644 --- a/core/modules/views/src/Tests/Plugin/StyleGridTest.php +++ b/core/modules/views/src/Tests/Plugin/StyleGridTest.php @@ -9,7 +9,6 @@ use Drupal\views\Views; use Drupal\views\ViewExecutable; -use Symfony\Component\HttpFoundation\Request; /** * Tests the grid style plugin. diff --git a/core/modules/views/src/Tests/Plugin/ViewsBlockTest.php b/core/modules/views/src/Tests/Plugin/ViewsBlockTest.php index 9e056a244..1cb8b0962 100644 --- a/core/modules/views/src/Tests/Plugin/ViewsBlockTest.php +++ b/core/modules/views/src/Tests/Plugin/ViewsBlockTest.php @@ -7,7 +7,6 @@ namespace Drupal\views\Tests\Plugin; -use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\views\Plugin\Block\ViewsBlock; use Drupal\views\Tests\ViewTestData; use Drupal\views\Tests\ViewKernelTestBase; diff --git a/core/modules/views/src/Tests/Plugin/ViewsFormTest.php b/core/modules/views/src/Tests/Plugin/ViewsFormTest.php index bbdd42a6c..eabecb194 100644 --- a/core/modules/views/src/Tests/Plugin/ViewsFormTest.php +++ b/core/modules/views/src/Tests/Plugin/ViewsFormTest.php @@ -8,7 +8,6 @@ namespace Drupal\views\Tests\Plugin; use Drupal\simpletest\WebTestBase; -use Drupal\views\Views; /** * Tests Views forms functionality. diff --git a/core/modules/views/src/Tests/ViewKernelTestBase.php b/core/modules/views/src/Tests/ViewKernelTestBase.php index 61036e02f..fe794ea7d 100644 --- a/core/modules/views/src/Tests/ViewKernelTestBase.php +++ b/core/modules/views/src/Tests/ViewKernelTestBase.php @@ -8,10 +8,8 @@ namespace Drupal\views\Tests; use Drupal\Core\Database\Query\SelectInterface; -use Drupal\views\ViewExecutable; use Drupal\views\ViewsBundle; use Drupal\simpletest\KernelTestBase; -use Symfony\Component\HttpFoundation\Request; /** * Defines a base class for Views unit testing. diff --git a/core/modules/views/src/Tests/ViewRenderTest.php b/core/modules/views/src/Tests/ViewRenderTest.php index bbf3fe14f..5c42cce8e 100644 --- a/core/modules/views/src/Tests/ViewRenderTest.php +++ b/core/modules/views/src/Tests/ViewRenderTest.php @@ -7,7 +7,6 @@ namespace Drupal\views\Tests; -use Drupal\views\Tests\ViewTestBase; use Drupal\views\Views; /** diff --git a/core/modules/views/src/Tests/ViewResultAssertionTrait.php b/core/modules/views/src/Tests/ViewResultAssertionTrait.php index 8525e80b9..66685fa9b 100644 --- a/core/modules/views/src/Tests/ViewResultAssertionTrait.php +++ b/core/modules/views/src/Tests/ViewResultAssertionTrait.php @@ -8,7 +8,6 @@ namespace Drupal\views\Tests; use Drupal\views\Plugin\views\field\Field; -use Drupal\views\ViewExecutable; /** * Provides a class for assertions to check for the expected result of a View. diff --git a/core/modules/views/src/Tests/ViewStorageTest.php b/core/modules/views/src/Tests/ViewStorageTest.php index 08432c4fb..7728b1f5c 100644 --- a/core/modules/views/src/Tests/ViewStorageTest.php +++ b/core/modules/views/src/Tests/ViewStorageTest.php @@ -8,11 +8,8 @@ namespace Drupal\views\Tests; use Drupal\Core\Entity\EntityTypeInterface; -use Drupal\Core\Config\Entity\ConfigEntityStorage; use Drupal\views\Entity\View; use Drupal\views\Plugin\views\display\Page; -use Drupal\views\Plugin\views\display\DefaultDisplay; -use Drupal\views\Plugin\views\display\Feed; use Drupal\views\Views; /** diff --git a/core/modules/views/src/Tests/ViewsTemplateTest.php b/core/modules/views/src/Tests/ViewsTemplateTest.php index c67befef1..17c2cdfcf 100644 --- a/core/modules/views/src/Tests/ViewsTemplateTest.php +++ b/core/modules/views/src/Tests/ViewsTemplateTest.php @@ -7,7 +7,6 @@ namespace Drupal\views\Tests; -use Drupal\views\Tests\ViewTestBase; use Drupal\views\Views; /** diff --git a/core/modules/views/src/ViewExecutable.php b/core/modules/views/src/ViewExecutable.php index d2d1fa575..2646c5616 100644 --- a/core/modules/views/src/ViewExecutable.php +++ b/core/modules/views/src/ViewExecutable.php @@ -8,15 +8,11 @@ namespace Drupal\views; use Drupal\Component\Utility\Html; -use Drupal\Core\Cache\Cache; use Drupal\Core\DependencyInjection\DependencySerializationTrait; use Drupal\Core\Form\FormState; use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\Core\Url; use Drupal\views\Plugin\views\display\DisplayRouterInterface; -use Drupal\views\Plugin\views\query\QueryPluginBase; -use Drupal\views\ViewEntityInterface; use Drupal\Component\Utility\Tags; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; diff --git a/core/modules/views/src/ViewExecutableFactory.php b/core/modules/views/src/ViewExecutableFactory.php index 0975a48d2..0d91100f4 100644 --- a/core/modules/views/src/ViewExecutableFactory.php +++ b/core/modules/views/src/ViewExecutableFactory.php @@ -9,7 +9,6 @@ use Drupal\Core\Routing\RouteProviderInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\views\ViewEntityInterface; use Symfony\Component\HttpFoundation\RequestStack; /** diff --git a/core/modules/views/tests/modules/views_test_data/views_test_data.module b/core/modules/views/tests/modules/views_test_data/views_test_data.module index ecf65b1e4..5853fd5eb 100644 --- a/core/modules/views/tests/modules/views_test_data/views_test_data.module +++ b/core/modules/views/tests/modules/views_test_data/views_test_data.module @@ -5,8 +5,6 @@ * Helper module for Views tests. */ -use Drupal\views\ViewExecutable; - /** * Access callback for the generic handler test. * diff --git a/core/modules/views/tests/src/Unit/Plugin/field/FieldPluginBaseTest.php b/core/modules/views/tests/src/Unit/Plugin/field/FieldPluginBaseTest.php index d285021ae..98dcb1de6 100644 --- a/core/modules/views/tests/src/Unit/Plugin/field/FieldPluginBaseTest.php +++ b/core/modules/views/tests/src/Unit/Plugin/field/FieldPluginBaseTest.php @@ -9,7 +9,6 @@ use Drupal\Core\GeneratedUrl; use Drupal\Core\Language\Language; -use Drupal\Core\Render\RendererInterface; use Drupal\Core\Render\Markup; use Drupal\Core\Url; use Drupal\Core\Utility\LinkGenerator; diff --git a/core/modules/views/views.module b/core/modules/views/views.module index 30c92f3da..7ee7671bd 100644 --- a/core/modules/views/views.module +++ b/core/modules/views/views.module @@ -11,17 +11,13 @@ use Drupal\Component\Utility\Html; use Drupal\Component\Utility\SafeMarkup; -use Drupal\Core\Cache\Cache; use Drupal\Core\Database\Query\AlterableInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\Element; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Url; use Drupal\views\Plugin\Derivative\ViewsLocalTask; -use Drupal\Core\Template\AttributeArray; -use Drupal\views\Plugin\views\display\Page; use Drupal\views\ViewExecutable; -use Drupal\Component\Plugin\Exception\PluginException; use Drupal\views\Entity\View; use Drupal\views\Render\ViewsRenderPipelineMarkup; use Drupal\views\Views; diff --git a/core/modules/views/views.theme.inc b/core/modules/views/views.theme.inc index 8990584a9..96d4c7ba0 100644 --- a/core/modules/views/views.theme.inc +++ b/core/modules/views/views.theme.inc @@ -998,7 +998,7 @@ function template_preprocess_views_mini_pager(&$variables) { $variables['items']['next']['attributes'] = new Attribute(); } - // This is is based on the entire current query string. We need to ensure + // This is based on the entire current query string. We need to ensure // cacheability is affected accordingly. $variables['#cache']['contexts'][] = 'url.query_args'; } diff --git a/core/modules/views_ui/admin.inc b/core/modules/views_ui/admin.inc index 6170ed4f8..01bcf7a66 100644 --- a/core/modules/views_ui/admin.inc +++ b/core/modules/views_ui/admin.inc @@ -6,12 +6,8 @@ */ use Drupal\Component\Utility\NestedArray; -use Drupal\Component\Utility\Tags; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; -use Drupal\views\ViewExecutable; -use Drupal\views\Views; -use Drupal\taxonomy\Entity\Vocabulary; /** * Converts a form element in the add view wizard to be AJAX-enabled. diff --git a/core/modules/views_ui/js/ajax.js b/core/modules/views_ui/js/ajax.js index 1e376076e..0dc0a74d3 100644 --- a/core/modules/views_ui/js/ajax.js +++ b/core/modules/views_ui/js/ajax.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * Ajax command for highlighting elements. @@ -81,7 +81,7 @@ var oldTitle = doc.title; // Escape the site name, in case it has special characters in it, so we can // use it in our regex. - var escapedSiteName = response.siteName.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"); + var escapedSiteName = response.siteName.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&'); var re = new RegExp('.+ (.) ' + escapedSiteName); doc.title = oldTitle.replace(re, response.title + ' $1 ' + response.siteName); @@ -127,12 +127,12 @@ */ Drupal.behaviors.syncPreviewDisplay = { attach: function (context) { - $("#views-tabset a").once('views-ajax').on('click', function () { + $('#views-tabset a').once('views-ajax').on('click', function () { var href = $(this).attr('href'); // Cut of #views-tabset. var display_id = href.substr(11); // Set the form element. - $("#views-live-preview #preview-display-id").val(display_id); + $('#views-live-preview #preview-display-id').val(display_id); }); } }; diff --git a/core/modules/views_ui/js/dialog.views.js b/core/modules/views_ui/js/dialog.views.js index b68039a51..3f40b4ad5 100644 --- a/core/modules/views_ui/js/dialog.views.js +++ b/core/modules/views_ui/js/dialog.views.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; function handleDialogResize(e) { var $modal = $(e.currentTarget); diff --git a/core/modules/views_ui/js/views-admin.js b/core/modules/views_ui/js/views-admin.js index 8e35c4708..aebff07aa 100644 --- a/core/modules/views_ui/js/views-admin.js +++ b/core/modules/views_ui/js/views-admin.js @@ -5,7 +5,7 @@ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; /** * @namespace @@ -494,7 +494,7 @@ $description = $option.find('.description'); options[i] = { // Search on the lowercase version of the label text + description. - searchText: $label.text().toLowerCase() + " " + $description.text().toLowerCase(), + searchText: $label.text().toLowerCase() + ' ' + $description.text().toLowerCase(), // Maintain a reference to the jQuery object for each row, so we don't // have to create a new object inside the performance-sensitive keyup // handler. diff --git a/core/modules/views_ui/js/views_ui.listing.js b/core/modules/views_ui/js/views_ui.listing.js index ee2199f1f..1dc807a0a 100644 --- a/core/modules/views_ui/js/views_ui.listing.js +++ b/core/modules/views_ui/js/views_ui.listing.js @@ -5,7 +5,7 @@ (function ($, Drupal) { - "use strict"; + 'use strict'; /** * Filters the view listing tables by a text input search string. diff --git a/core/modules/views_ui/src/Form/Ajax/Analyze.php b/core/modules/views_ui/src/Form/Ajax/Analyze.php index b53800dfb..7daddce23 100644 --- a/core/modules/views_ui/src/Form/Ajax/Analyze.php +++ b/core/modules/views_ui/src/Form/Ajax/Analyze.php @@ -9,8 +9,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\views\Views; -use Drupal\views_ui\ViewUI; -use Drupal\views\Analyzer; /** * Displays analysis information for a view. diff --git a/core/modules/views_ui/src/Form/Ajax/EditDetails.php b/core/modules/views_ui/src/Form/Ajax/EditDetails.php index 6790029c9..9e25ecebd 100644 --- a/core/modules/views_ui/src/Form/Ajax/EditDetails.php +++ b/core/modules/views_ui/src/Form/Ajax/EditDetails.php @@ -9,7 +9,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\views\Views; -use Drupal\views_ui\ViewUI; /** * Provides a form for editing the details of a View. diff --git a/core/modules/views_ui/src/Form/Ajax/ReorderDisplays.php b/core/modules/views_ui/src/Form/Ajax/ReorderDisplays.php index d3db3dd59..62746378e 100644 --- a/core/modules/views_ui/src/Form/Ajax/ReorderDisplays.php +++ b/core/modules/views_ui/src/Form/Ajax/ReorderDisplays.php @@ -10,7 +10,6 @@ use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Url; -use Drupal\views_ui\ViewUI; /** * Displays the display reorder form. diff --git a/core/modules/views_ui/src/Form/Ajax/ViewsFormBase.php b/core/modules/views_ui/src/Form/Ajax/ViewsFormBase.php index 565329f67..b3edb6471 100644 --- a/core/modules/views_ui/src/Form/Ajax/ViewsFormBase.php +++ b/core/modules/views_ui/src/Form/Ajax/ViewsFormBase.php @@ -14,7 +14,6 @@ use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Core\Render\RenderContext; -use Drupal\views_ui\ViewUI; use Drupal\views\ViewEntityInterface; use Drupal\views\Ajax; use Drupal\Core\Ajax\AjaxResponse; diff --git a/core/modules/views_ui/src/ParamConverter/ViewUIConverter.php b/core/modules/views_ui/src/ParamConverter/ViewUIConverter.php old mode 100644 new mode 100755 index c31a61572..a8c51510d --- a/core/modules/views_ui/src/ParamConverter/ViewUIConverter.php +++ b/core/modules/views_ui/src/ParamConverter/ViewUIConverter.php @@ -42,6 +42,8 @@ class ViewUIConverter extends EntityConverter implements ParamConverterInterface /** * Constructs a new ViewUIConverter. * + * @param \Drupal\Core\Entity\EntityManagerInterface $entity_manager + * The entity manager. * @param \Drupal\user\SharedTempStoreFactory $temp_store_factory * The factory for the temp store object. */ diff --git a/core/modules/views_ui/src/Tests/QueryTest.php b/core/modules/views_ui/src/Tests/QueryTest.php index bed04223c..cda040c96 100644 --- a/core/modules/views_ui/src/Tests/QueryTest.php +++ b/core/modules/views_ui/src/Tests/QueryTest.php @@ -9,8 +9,6 @@ use Drupal\views\Views; use Drupal\views\Entity\View; -use Drupal\views\Tests\ViewTestBase; -use Drupal\views_test_data\Plugin\views\query\QueryTest as QueryTestPlugin; /** * Tests query plugins. diff --git a/core/modules/views_ui/src/Tests/ViewEditTest.php b/core/modules/views_ui/src/Tests/ViewEditTest.php index ee5cc6014..71dcaa006 100644 --- a/core/modules/views_ui/src/Tests/ViewEditTest.php +++ b/core/modules/views_ui/src/Tests/ViewEditTest.php @@ -9,7 +9,6 @@ use Drupal\language\Entity\ConfigurableLanguage; use Drupal\views\Entity\View; -use Drupal\views\Views; /** * Tests some general functionality of editing views, like deleting a view. diff --git a/core/modules/views_ui/tests/src/Unit/ViewUIObjectTest.php b/core/modules/views_ui/tests/src/Unit/ViewUIObjectTest.php index cb26b5890..c6d7726e9 100644 --- a/core/modules/views_ui/tests/src/Unit/ViewUIObjectTest.php +++ b/core/modules/views_ui/tests/src/Unit/ViewUIObjectTest.php @@ -10,9 +10,7 @@ use Drupal\Core\Language\LanguageInterface; use Drupal\Tests\UnitTestCase; use Drupal\views\Entity\View; -use Drupal\views\ViewExecutable; use Drupal\views_ui\ViewUI; -use Symfony\Component\DependencyInjection\Container; use Symfony\Component\DependencyInjection\ContainerBuilder; /** diff --git a/core/modules/views_ui/views_ui.module b/core/modules/views_ui/views_ui.module index 57a84ed3c..60fdc51a6 100644 --- a/core/modules/views_ui/views_ui.module +++ b/core/modules/views_ui/views_ui.module @@ -10,7 +10,6 @@ use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Url; use Drupal\views\ViewExecutable; use Drupal\views\Analyzer; -use Drupal\Component\Utility\Xss; /** * Implements hook_help(). diff --git a/core/profiles/standard/config/install/field.field.node.article.field_image.yml b/core/profiles/standard/config/install/field.field.node.article.field_image.yml index b69d60319..b4b1c1466 100644 --- a/core/profiles/standard/config/install/field.field.node.article.field_image.yml +++ b/core/profiles/standard/config/install/field.field.node.article.field_image.yml @@ -17,7 +17,7 @@ translatable: true default_value: { } default_value_callback: '' settings: - file_directory: field/image + file_directory: '[date:custom:Y]-[date:custom:m]' file_extensions: 'png gif jpg jpeg' max_filesize: '' max_resolution: '' diff --git a/core/profiles/standard/config/install/field.field.user.user.user_picture.yml b/core/profiles/standard/config/install/field.field.user.user.user_picture.yml index 514508500..b2e61f661 100644 --- a/core/profiles/standard/config/install/field.field.user.user.user_picture.yml +++ b/core/profiles/standard/config/install/field.field.user.user.user_picture.yml @@ -18,7 +18,7 @@ default_value: { } default_value_callback: '' settings: file_extensions: 'png gif jpg jpeg' - file_directory: pictures + file_directory: 'pictures/[date:custom:Y]-[date:custom:m]' max_filesize: '30 KB' alt_field: false title_field: false diff --git a/core/profiles/standard/standard.install b/core/profiles/standard/standard.install index fa8c7560b..744963a08 100644 --- a/core/profiles/standard/standard.install +++ b/core/profiles/standard/standard.install @@ -4,7 +4,6 @@ * Install, update and uninstall functions for the standard installation profile. */ -use Drupal\comment\Plugin\Field\FieldType\CommentItemInterface; use Drupal\user\Entity\User; use Drupal\user\RoleInterface; diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh index 1b931488f..9ca309f48 100755 --- a/core/scripts/run-tests.sh +++ b/core/scripts/run-tests.sh @@ -9,8 +9,6 @@ use Drupal\Component\Utility\Html; use Drupal\Component\Utility\Timer; use Drupal\Component\Uuid\Php; use Drupal\Core\Database\Database; -use Drupal\Core\Form\FormState; -use Drupal\Core\Site\Settings; use Drupal\Core\StreamWrapper\PublicStream; use Drupal\Core\Test\TestRunnerKernel; use Drupal\simpletest\Form\SimpletestResultsForm; diff --git a/core/tests/Drupal/KernelTests/Component/Utility/SafeMarkupKernelTest.php b/core/tests/Drupal/KernelTests/Component/Utility/SafeMarkupKernelTest.php index 273a240fa..c337f75be 100644 --- a/core/tests/Drupal/KernelTests/Component/Utility/SafeMarkupKernelTest.php +++ b/core/tests/Drupal/KernelTests/Component/Utility/SafeMarkupKernelTest.php @@ -7,9 +7,7 @@ namespace Drupal\KernelTests\Component\Utility; -use Drupal\Component\FileCache\FileCacheFactory; use Drupal\Component\Utility\SafeMarkup; -use Drupal\Core\Site\Settings; use Drupal\Core\Url; use Drupal\KernelTests\KernelTestBase; diff --git a/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php b/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php index 77270c34f..25577371e 100644 --- a/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php +++ b/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php @@ -7,11 +7,9 @@ namespace Drupal\KernelTests\Config; -use Drupal\Component\FileCache\FileCacheFactory; use Drupal\Core\Config\FileStorage; use Drupal\Core\Config\InstallStorage; use Drupal\Core\Config\StorageInterface; -use Drupal\Core\Site\Settings; use Drupal\KernelTests\AssertConfigTrait; use Drupal\KernelTests\KernelTestBase; diff --git a/core/tests/Drupal/KernelTests/Core/Entity/RouteProviderTest.php b/core/tests/Drupal/KernelTests/Core/Entity/RouteProviderTest.php new file mode 100644 index 000000000..3b7af4156 --- /dev/null +++ b/core/tests/Drupal/KernelTests/Core/Entity/RouteProviderTest.php @@ -0,0 +1,148 @@ +installEntitySchema('user'); + $this->installEntitySchema('entity_test_mul'); + $this->installEntitySchema('entity_test_admin_routes'); + $this->installSchema('system', 'router'); + + $router_builder = \Drupal::service('router.builder'); + $router_builder->rebuild(); + + /** @var \Drupal\Core\Routing\RouteBuilderInterface $router_builder */ + $router_builder = \Drupal::service('router.builder'); + $router_builder->rebuild(); + + /** @var \Drupal\user\RoleInterface $role */ + $role = Role::create([ + 'id' => RoleInterface::ANONYMOUS_ID + ]); + $role + ->grantPermission('administer entity_test content') + ->grantPermission('view test entity'); + $role->save(); + } + + protected function httpKernelHandle($url) { + $request = Request::create($url); + /** @var \Symfony\Component\HttpKernel\HttpKernelInterface $http_kernel */ + $http_kernel = \Drupal::service('http_kernel'); + return $http_kernel->handle($request, HttpKernelInterface::SUB_REQUEST)->getContent(); + } + + /** + * @covers \Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider::getRoutes + */ + public function testHtmlRoutes() { + /** @var \Drupal\Core\Routing\RouteProviderInterface $route_provider */ + $route_provider = \Drupal::service('router.route_provider'); + + $route = $route_provider->getRouteByName('entity.entity_test_mul.canonical'); + $this->assertEquals('entity_test_mul.full', $route->getDefault('_entity_view')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::title', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_mul.view', $route->getRequirement('_entity_access')); + $this->assertFalse($route->hasOption('_admin_route')); + + $route = $route_provider->getRouteByName('entity.entity_test_mul.edit_form'); + $this->assertEquals('entity_test_mul.default', $route->getDefault('_entity_form')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::editTitle', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_mul.update', $route->getRequirement('_entity_access')); + $this->assertFalse($route->hasOption('_admin_route')); + + $route = $route_provider->getRouteByName('entity.entity_test_mul.delete_form'); + $this->assertEquals('entity_test_mul.delete', $route->getDefault('_entity_form')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::deleteTitle', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_mul.delete', $route->getRequirement('_entity_access')); + $this->assertFalse($route->hasOption('_admin_route')); + + $entity = EntityTestMul::create([ + 'name' => 'Test title', + ]); + $entity->save(); + + $this->setRawContent($this->httpKernelHandle($entity->url())); + $this->assertTitle('Test title | '); + + $this->setRawContent($this->httpKernelHandle($entity->url('edit-form'))); + $this->assertTitle('Edit Test title | '); + + $this->setRawContent($this->httpKernelHandle($entity->url('delete-form'))); + $this->assertTitle('Are you sure you want to delete the test entity - data table Test title? | '); + } + + /** + * @covers \Drupal\Core\Entity\Routing\AdminHtmlRouteProvider::getEditFormRoute + * @covers \Drupal\Core\Entity\Routing\AdminHtmlRouteProvider::getDeleteFormRoute + */ + public function testAdminHtmlRoutes() { + /** @var \Drupal\Core\Routing\RouteProviderInterface $route_provider */ + $route_provider = \Drupal::service('router.route_provider'); + + $route = $route_provider->getRouteByName('entity.entity_test_admin_routes.canonical'); + $this->assertEquals('entity_test_admin_routes.full', $route->getDefault('_entity_view')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::title', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_admin_routes.view', $route->getRequirement('_entity_access')); + $this->assertFalse($route->hasOption('_admin_route')); + + $route = $route_provider->getRouteByName('entity.entity_test_admin_routes.edit_form'); + $this->assertEquals('entity_test_admin_routes.default', $route->getDefault('_entity_form')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::editTitle', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_admin_routes.update', $route->getRequirement('_entity_access')); + $this->assertTrue($route->hasOption('_admin_route')); + $this->assertTrue($route->getOption('_admin_route')); + + $route = $route_provider->getRouteByName('entity.entity_test_admin_routes.delete_form'); + $this->assertEquals('entity_test_admin_routes.delete', $route->getDefault('_entity_form')); + $this->assertEquals('\Drupal\Core\Entity\Controller\EntityController::deleteTitle', $route->getDefault('_title_callback')); + $this->assertEquals('entity_test_admin_routes.delete', $route->getRequirement('_entity_access')); + $this->assertTrue($route->hasOption('_admin_route')); + $this->assertTrue($route->getOption('_admin_route')); + + $entity = EntityTestAdminRoutes::create([ + 'name' => 'Test title', + ]); + $entity->save(); + + $this->setRawContent($this->httpKernelHandle($entity->url())); + $this->assertTitle('Test title | '); + + $this->setRawContent($this->httpKernelHandle($entity->url('edit-form'))); + $this->assertTitle('Edit Test title | '); + + $this->setRawContent($this->httpKernelHandle($entity->url('delete-form'))); + $this->assertTitle('Are you sure you want to delete the test entity - admin routes Test title? | '); + } + +} diff --git a/core/tests/Drupal/Tests/Component/DependencyInjection/PhpArrayContainerTest.php b/core/tests/Drupal/Tests/Component/DependencyInjection/PhpArrayContainerTest.php index 8ad93b3ac..3a9f4fc86 100644 --- a/core/tests/Drupal/Tests/Component/DependencyInjection/PhpArrayContainerTest.php +++ b/core/tests/Drupal/Tests/Component/DependencyInjection/PhpArrayContainerTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Component\DependencyInjection; use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\Exception\LogicException; /** * @coversDefaultClass \Drupal\Component\DependencyInjection\PhpArrayContainer diff --git a/core/tests/Drupal/Tests/Component/EventDispatcher/ContainerAwareEventDispatcherTest.php b/core/tests/Drupal/Tests/Component/EventDispatcher/ContainerAwareEventDispatcherTest.php index 6009e6543..f36d8368f 100644 --- a/core/tests/Drupal/Tests/Component/EventDispatcher/ContainerAwareEventDispatcherTest.php +++ b/core/tests/Drupal/Tests/Component/EventDispatcher/ContainerAwareEventDispatcherTest.php @@ -10,8 +10,6 @@ use Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher; use Symfony\Component\DependencyInjection\Container; use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\EventDispatcher\Event; -use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\EventDispatcher\Tests\AbstractEventDispatcherTest; use Symfony\Component\EventDispatcher\Tests\CallableClass; use Symfony\Component\EventDispatcher\Tests\TestEventListener; diff --git a/core/tests/Drupal/Tests/Component/Utility/XssTest.php b/core/tests/Drupal/Tests/Component/Utility/XssTest.php index 7ca4be8d8..a8ab15732 100644 --- a/core/tests/Drupal/Tests/Component/Utility/XssTest.php +++ b/core/tests/Drupal/Tests/Component/Utility/XssTest.php @@ -489,7 +489,7 @@ public function testQuestionSign() { } /** - * Check that strings in HTML attributes are are correctly processed. + * Check that strings in HTML attributes are correctly processed. * * @covers ::attributes * @dataProvider providerTestAttributes diff --git a/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php b/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php index 3a03535e6..b0c4b98df 100644 --- a/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php +++ b/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Access\AccessCheckInterface; use Drupal\Core\Access\AccessResult; -use Drupal\Core\Access\AccessManagerInterface; use Drupal\Core\Access\CheckProvider; use Drupal\Core\Cache\Context\CacheContextsManager; use Drupal\Core\Routing\RouteMatch; diff --git a/core/tests/Drupal/Tests/Core/Access/CsrfTokenGeneratorTest.php b/core/tests/Drupal/Tests/Core/Access/CsrfTokenGeneratorTest.php index ec2abec46..7a41edcd2 100644 --- a/core/tests/Drupal/Tests/Core/Access/CsrfTokenGeneratorTest.php +++ b/core/tests/Drupal/Tests/Core/Access/CsrfTokenGeneratorTest.php @@ -11,7 +11,6 @@ use Drupal\Tests\UnitTestCase; use Drupal\Core\Access\CsrfTokenGenerator; use Drupal\Component\Utility\Crypt; -use Symfony\Component\HttpFoundation\Request; /** * Tests the CsrfTokenGenerator class. diff --git a/core/tests/Drupal/Tests/Core/Ajax/AjaxResponseTest.php b/core/tests/Drupal/Tests/Core/Ajax/AjaxResponseTest.php index acf3290b4..ddb9c24f0 100644 --- a/core/tests/Drupal/Tests/Core/Ajax/AjaxResponseTest.php +++ b/core/tests/Drupal/Tests/Core/Ajax/AjaxResponseTest.php @@ -9,7 +9,6 @@ use Drupal\Core\Ajax\AjaxResponse; use Drupal\Core\EventSubscriber\AjaxResponseSubscriber; -use Drupal\Core\Render\Element\Ajax; use Drupal\Tests\UnitTestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Event\FilterResponseEvent; diff --git a/core/tests/Drupal/Tests/Core/Cache/CacheTest.php b/core/tests/Drupal/Tests/Core/Cache/CacheTest.php index 6c30996cc..5c84745c7 100644 --- a/core/tests/Drupal/Tests/Core/Cache/CacheTest.php +++ b/core/tests/Drupal/Tests/Core/Cache/CacheTest.php @@ -7,10 +7,8 @@ namespace Drupal\Tests\Core\Cache; -use Drupal\Component\Assertion\Inspector; use Drupal\Core\Cache\Cache; use Drupal\Tests\UnitTestCase; -use Symfony\Component\DependencyInjection\ContainerBuilder; /** * @coversDefaultClass \Drupal\Core\Cache\Cache diff --git a/core/tests/Drupal/Tests/Core/Condition/ConditionAccessResolverTraitTest.php b/core/tests/Drupal/Tests/Core/Condition/ConditionAccessResolverTraitTest.php index b3c4706bb..e8b4a2ffa 100644 --- a/core/tests/Drupal/Tests/Core/Condition/ConditionAccessResolverTraitTest.php +++ b/core/tests/Drupal/Tests/Core/Condition/ConditionAccessResolverTraitTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Condition; use Drupal\Component\Plugin\Exception\ContextException; -use Drupal\Core\Condition\ConditionAccessResolverTrait; use Drupal\Tests\UnitTestCase; /** diff --git a/core/tests/Drupal/Tests/Core/Config/ConfigTest.php b/core/tests/Drupal/Tests/Core/Config/ConfigTest.php index 06c2cbb0c..a7ff94b79 100644 --- a/core/tests/Drupal/Tests/Core/Config/ConfigTest.php +++ b/core/tests/Drupal/Tests/Core/Config/ConfigTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Render\Markup; use Drupal\Tests\UnitTestCase; use Drupal\Core\Config\Config; -use Drupal\Component\Utility\SafeMarkup; /** * Tests the Config. diff --git a/core/tests/Drupal/Tests/Core/Database/ConnectionTest.php b/core/tests/Drupal/Tests/Core/Database/ConnectionTest.php index 24ba469ae..a91e241c6 100644 --- a/core/tests/Drupal/Tests/Core/Database/ConnectionTest.php +++ b/core/tests/Drupal/Tests/Core/Database/ConnectionTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Database; use Drupal\Tests\Core\Database\Stub\StubConnection; -use Drupal\Tests\Core\Database\Stub\StubPDO; use Drupal\Tests\UnitTestCase; /** diff --git a/core/tests/Drupal/Tests/Core/Database/Driver/pgsql/PostgresqlConnectionTest.php b/core/tests/Drupal/Tests/Core/Database/Driver/pgsql/PostgresqlConnectionTest.php index b17726146..34a59fecc 100644 --- a/core/tests/Drupal/Tests/Core/Database/Driver/pgsql/PostgresqlConnectionTest.php +++ b/core/tests/Drupal/Tests/Core/Database/Driver/pgsql/PostgresqlConnectionTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\Core\Database\Driver\pgsql; use Drupal\Core\Database\Driver\pgsql\Connection; -use Drupal\Tests\Core\Database\Stub\StubPDO; use Drupal\Tests\UnitTestCase; /** diff --git a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/BackendCompilerPassTest.php b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/BackendCompilerPassTest.php index ae11ee562..2efb13f28 100644 --- a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/BackendCompilerPassTest.php +++ b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/BackendCompilerPassTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\Core\DependencyInjection\Compiler; -use Drupal\Core\Database\Driver\sqlite\Connection; use Drupal\Core\DependencyInjection\Compiler\BackendCompilerPass; use Drupal\Tests\UnitTestCase; use Symfony\Component\DependencyInjection\Alias; diff --git a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php index 2567513ce..320ce70bf 100644 --- a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php +++ b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php @@ -11,7 +11,6 @@ use Drupal\Core\DependencyInjection\Compiler\ProxyServicesPass; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Tests\UnitTestCase; -use Symfony\Component\DependencyInjection\Reference; /** * @coversDefaultClass \Drupal\Core\DependencyInjection\Compiler\ProxyServicesPass diff --git a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/StackedKernelPassTest.php b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/StackedKernelPassTest.php index 5bd600128..cbcae164d 100644 --- a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/StackedKernelPassTest.php +++ b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/StackedKernelPassTest.php @@ -98,7 +98,7 @@ public function testProcessWithHttpKernel() { * Creates a middleware definition. * * @param bool $tag - * Whether ot not to set the http_middleware tag. + * Whether or not to set the http_middleware tag. * @param int $priority * The priority to be used for the tag. * diff --git a/core/tests/Drupal/Tests/Core/Entity/EntityUnitTest.php b/core/tests/Drupal/Tests/Core/Entity/EntityUnitTest.php index 3a2121193..3f1e2e0f2 100644 --- a/core/tests/Drupal/Tests/Core/Entity/EntityUnitTest.php +++ b/core/tests/Drupal/Tests/Core/Entity/EntityUnitTest.php @@ -11,9 +11,7 @@ use Drupal\Core\Cache\Cache; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Core\Entity\Entity; -use Drupal\Core\Entity\Exception\NoCorrespondingEntityClassException; use Drupal\Core\Language\Language; -use Drupal\entity_test\Entity\EntityTest; use Drupal\entity_test\Entity\EntityTestMul; use Drupal\Tests\UnitTestCase; diff --git a/core/tests/Drupal/Tests/Core/Entity/Sql/DefaultTableMappingTest.php b/core/tests/Drupal/Tests/Core/Entity/Sql/DefaultTableMappingTest.php index 330695ec6..32c8d5ee3 100644 --- a/core/tests/Drupal/Tests/Core/Entity/Sql/DefaultTableMappingTest.php +++ b/core/tests/Drupal/Tests/Core/Entity/Sql/DefaultTableMappingTest.php @@ -6,8 +6,8 @@ */ namespace Drupal\Tests\Core\Entity\Sql; + use Drupal\Core\Entity\Sql\DefaultTableMapping; -use Drupal\Core\Entity\Sql\SqlContentEntityStorageException; use Drupal\Tests\UnitTestCase; /** diff --git a/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php b/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php index 16f66c385..34013c488 100644 --- a/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php +++ b/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php @@ -11,10 +11,7 @@ use Drupal\Core\Entity\EntityInterface; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\Sql\SqlContentEntityStorage; -use Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema; -use Drupal\Core\Field\BaseFieldDefinition; use Drupal\Core\Language\Language; -use Drupal\Core\Language\LanguageManagerInterface; use Drupal\Tests\UnitTestCase; use Symfony\Component\DependencyInjection\ContainerBuilder; diff --git a/core/tests/Drupal/Tests/Core/Entity/TypedData/EntityAdapterUnitTest.php b/core/tests/Drupal/Tests/Core/Entity/TypedData/EntityAdapterUnitTest.php index 672e20bf7..863ae628c 100644 --- a/core/tests/Drupal/Tests/Core/Entity/TypedData/EntityAdapterUnitTest.php +++ b/core/tests/Drupal/Tests/Core/Entity/TypedData/EntityAdapterUnitTest.php @@ -7,11 +7,9 @@ namespace Drupal\Tests\Core\Entity\TypedData; -use Drupal\Core\Access\AccessResult; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Core\Entity\Plugin\DataType\EntityAdapter; use Drupal\Core\Field\BaseFieldDefinition; -use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Language\LanguageInterface; use Drupal\Tests\UnitTestCase; use Drupal\Core\Language\Language; diff --git a/core/tests/Drupal/Tests/Core/Form/EventSubscriber/FormAjaxSubscriberTest.php b/core/tests/Drupal/Tests/Core/Form/EventSubscriber/FormAjaxSubscriberTest.php index 8d0f6bbfc..035965f38 100644 --- a/core/tests/Drupal/Tests/Core/Form/EventSubscriber/FormAjaxSubscriberTest.php +++ b/core/tests/Drupal/Tests/Core/Form/EventSubscriber/FormAjaxSubscriberTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\Core\Form\EventSubscriber; -use Drupal\Core\Ajax\AjaxResponse; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Core\Form\EventSubscriber\FormAjaxSubscriber; use Drupal\Core\Form\Exception\BrokenPostRequestException; @@ -18,7 +17,6 @@ use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent; -use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; use Symfony\Component\HttpKernel\Exception\HttpException; use Symfony\Component\HttpKernel\HttpKernelInterface; diff --git a/core/tests/Drupal/Tests/Core/Form/FormCacheTest.php b/core/tests/Drupal/Tests/Core/Form/FormCacheTest.php index c6032f0d9..71c90bf5f 100644 --- a/core/tests/Drupal/Tests/Core/Form/FormCacheTest.php +++ b/core/tests/Drupal/Tests/Core/Form/FormCacheTest.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\Core\Form; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Form\FormCache; use Drupal\Core\Form\FormState; use Drupal\Tests\UnitTestCase; diff --git a/core/tests/Drupal/Tests/Core/Form/FormTestBase.php b/core/tests/Drupal/Tests/Core/Form/FormTestBase.php index 83aec87c5..54f6366d3 100644 --- a/core/tests/Drupal/Tests/Core/Form/FormTestBase.php +++ b/core/tests/Drupal/Tests/Core/Form/FormTestBase.php @@ -12,11 +12,9 @@ use Drupal\Core\Form\FormInterface; use Drupal\Core\Form\FormState; use Drupal\Core\Form\FormStateInterface; -use Drupal\Core\Session\AccountInterface; use Drupal\Tests\UnitTestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; -use Symfony\Component\HttpFoundation\Response; /** * Provides a base class for testing form functionality. diff --git a/core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php b/core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php index 6e8fe4956..00bce3f7c 100644 --- a/core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php +++ b/core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php @@ -8,9 +8,7 @@ namespace Drupal\Tests\Core\Logger; use Drupal\Core\Logger\LoggerChannelFactory; -use Drupal\Core\Session\AccountInterface; use Drupal\Tests\UnitTestCase; -use Symfony\Component\HttpFoundation\Request; /** * @coversDefaultClass \Drupal\Core\Logger\LoggerChannelFactory diff --git a/core/tests/Drupal/Tests/Core/Menu/ContextualLinkDefaultTest.php b/core/tests/Drupal/Tests/Core/Menu/ContextualLinkDefaultTest.php index 7a90abb04..fddfff24b 100644 --- a/core/tests/Drupal/Tests/Core/Menu/ContextualLinkDefaultTest.php +++ b/core/tests/Drupal/Tests/Core/Menu/ContextualLinkDefaultTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Menu\ContextualLinkDefault; use Drupal\Core\StringTranslation\TranslatableMarkup; use Drupal\Tests\UnitTestCase; -use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; /** diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalActionDefaultTest.php b/core/tests/Drupal/Tests/Core/Menu/LocalActionDefaultTest.php index 1d1c4dd72..f4854bbf4 100644 --- a/core/tests/Drupal/Tests/Core/Menu/LocalActionDefaultTest.php +++ b/core/tests/Drupal/Tests/Core/Menu/LocalActionDefaultTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Menu\LocalActionDefault; use Drupal\Core\StringTranslation\TranslatableMarkup; use Drupal\Tests\UnitTestCase; -use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; /** diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php b/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php index 24a09f25c..dcc4f55dd 100644 --- a/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php +++ b/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php @@ -14,7 +14,6 @@ use Drupal\Core\Access\AccessResultForbidden; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Extension\ModuleHandlerInterface; -use Drupal\Core\Language\Language; use Drupal\Core\Menu\LocalActionManager; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Routing\RouteProviderInterface; diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalTaskIntegrationTestBase.php b/core/tests/Drupal/Tests/Core/Menu/LocalTaskIntegrationTestBase.php index 69cc9c586..3a2388d13 100644 --- a/core/tests/Drupal/Tests/Core/Menu/LocalTaskIntegrationTestBase.php +++ b/core/tests/Drupal/Tests/Core/Menu/LocalTaskIntegrationTestBase.php @@ -7,7 +7,6 @@ namespace Drupal\Tests\Core\Menu; -use Drupal\Core\Language\Language; use Drupal\Core\Plugin\Discovery\ContainerDerivativeDiscoveryDecorator; use Drupal\Core\Plugin\Discovery\YamlDiscovery; use Drupal\Tests\UnitTestCase; diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php b/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php index c69dcf2be..04f1b162a 100644 --- a/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php +++ b/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php @@ -21,7 +21,6 @@ use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; -use Zend\Stdlib\ArrayObject; /** * @coversDefaultClass \Drupal\Core\Menu\LocalTaskManager diff --git a/core/tests/Drupal/Tests/Core/Path/AliasManagerTest.php b/core/tests/Drupal/Tests/Core/Path/AliasManagerTest.php index 01290c42e..cc041ce6d 100644 --- a/core/tests/Drupal/Tests/Core/Path/AliasManagerTest.php +++ b/core/tests/Drupal/Tests/Core/Path/AliasManagerTest.php @@ -339,14 +339,10 @@ public function testGetAliasByPathCachedMissLanguage() { // Call it twice to test the static cache. $this->assertEquals($alias, $this->aliasManager->getAliasByPath($path)); - // This needs to write out the cache. - $expected_new_cache = array( - $cached_language->getId() => array($path), - $language->getId() => array($path), - ); - $this->cache->expects($this->once()) - ->method('set') - ->with($this->cacheKey, $expected_new_cache, (int) $_SERVER['REQUEST_TIME'] + (60 * 60 * 24)); + // There is already a cache entry, so this should not write out to the + // cache. + $this->cache->expects($this->never()) + ->method('set'); $this->aliasManager->writeCache(); } @@ -441,13 +437,10 @@ public function testGetAliasByPathUncachedMissNoAlias() { // Call it twice to test the static cache. $this->assertEquals($path, $this->aliasManager->getAliasByPath($path)); - // This needs to write out the cache. - $expected_new_cache = array( - $language->getId() => array($cached_path, $path), - ); - $this->cache->expects($this->once()) - ->method('set') - ->with($this->cacheKey, $expected_new_cache, (int) $_SERVER['REQUEST_TIME'] + (60 * 60 * 24)); + // There is already a cache entry, so this should not write out to the + // cache. + $this->cache->expects($this->never()) + ->method('set'); $this->aliasManager->writeCache(); } @@ -533,13 +526,10 @@ public function testGetAliasByPathUncachedMissWithAlias() { // Call it twice to test the static cache. $this->assertEquals($new_alias, $this->aliasManager->getAliasByPath($path)); - // This needs to write out the cache. - $expected_new_cache = array( - $language->getId() => array($cached_path, $path, $cached_no_alias_path), - ); - $this->cache->expects($this->once()) - ->method('set') - ->with($this->cacheKey, $expected_new_cache, (int) $_SERVER['REQUEST_TIME'] + (60 * 60 * 24)); + // There is already a cache entry, so this should not write out to the + // cache. + $this->cache->expects($this->never()) + ->method('set'); $this->aliasManager->writeCache(); } diff --git a/core/tests/Drupal/Tests/Core/Plugin/Discovery/DerivativeDiscoveryDecoratorTest.php b/core/tests/Drupal/Tests/Core/Plugin/Discovery/DerivativeDiscoveryDecoratorTest.php index 4cc05ad71..70d01ec11 100644 --- a/core/tests/Drupal/Tests/Core/Plugin/Discovery/DerivativeDiscoveryDecoratorTest.php +++ b/core/tests/Drupal/Tests/Core/Plugin/Discovery/DerivativeDiscoveryDecoratorTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Plugin\Discovery; use Drupal\Component\Plugin\Discovery\DerivativeDiscoveryDecorator; -use Drupal\Component\Plugin\Exception\InvalidDeriverException; use Drupal\Tests\UnitTestCase; /** diff --git a/core/tests/Drupal/Tests/Core/Render/BubbleableMetadataTest.php b/core/tests/Drupal/Tests/Core/Render/BubbleableMetadataTest.php index 72e589375..34eec8a35 100644 --- a/core/tests/Drupal/Tests/Core/Render/BubbleableMetadataTest.php +++ b/core/tests/Drupal/Tests/Core/Render/BubbleableMetadataTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Render; use Drupal\Core\Cache\Cache; -use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Render\BubbleableMetadata; use Drupal\Tests\UnitTestCase; diff --git a/core/tests/Drupal/Tests/Core/Render/Element/TableSelectTest.php b/core/tests/Drupal/Tests/Core/Render/Element/TableSelectTest.php index 649a57f9d..2040ab64d 100644 --- a/core/tests/Drupal/Tests/Core/Render/Element/TableSelectTest.php +++ b/core/tests/Drupal/Tests/Core/Render/Element/TableSelectTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Link; use Drupal\Core\Render\Element\Tableselect; use Drupal\Core\StringTranslation\TranslatableMarkup; -use Drupal\Core\StringTranslation\TranslationWrapper; use Drupal\Core\Url; use Drupal\Tests\UnitTestCase; diff --git a/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php b/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php index c621e6265..5867b2bea 100644 --- a/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php +++ b/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php @@ -10,7 +10,6 @@ use Drupal\Core\Cache\MemoryBackend; use Drupal\Core\KeyValueStore\KeyValueMemoryFactory; use Drupal\Core\Render\Element; -use Drupal\Core\Render\Renderer; use Drupal\Core\State\State; use Drupal\Core\Cache\Cache; diff --git a/core/tests/Drupal/Tests/Core/Render/RendererTest.php b/core/tests/Drupal/Tests/Core/Render/RendererTest.php index 145a8ab65..48b394e94 100644 --- a/core/tests/Drupal/Tests/Core/Render/RendererTest.php +++ b/core/tests/Drupal/Tests/Core/Render/RendererTest.php @@ -11,7 +11,6 @@ use Drupal\Core\Access\AccessResult; use Drupal\Core\Access\AccessResultInterface; use Drupal\Core\Cache\Cache; -use Drupal\Core\Cache\CacheableDependencyInterface; use Drupal\Core\Render\Element; use Drupal\Core\Render\Markup; use Drupal\Core\Template\Attribute; @@ -97,7 +96,7 @@ public function providerTestRenderBasic() { '#plain_text' => 'foo', '#markup' => 'bar', ], '<em>foo</em>']; - // Safe strings in #plain_text are are still escaped. + // Safe strings in #plain_text are still escaped. $data[] = [[ '#plain_text' => Markup::create('foo'), ], '<em>foo</em>']; diff --git a/core/tests/Drupal/Tests/Core/Routing/ContentTypeHeaderMatcherTest.php b/core/tests/Drupal/Tests/Core/Routing/ContentTypeHeaderMatcherTest.php index 02775850f..1f734e7af 100644 --- a/core/tests/Drupal/Tests/Core/Routing/ContentTypeHeaderMatcherTest.php +++ b/core/tests/Drupal/Tests/Core/Routing/ContentTypeHeaderMatcherTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Routing; use Drupal\Core\Routing\ContentTypeHeaderMatcher; -use Drupal\Tests\Core\Routing\RoutingFixtures; use Drupal\Tests\UnitTestCase; use Symfony\Component\HttpFoundation\Request; diff --git a/core/tests/Drupal/Tests/Core/Routing/CurrentRouteMatchTest.php b/core/tests/Drupal/Tests/Core/Routing/CurrentRouteMatchTest.php index cba533ca6..b0ad0402c 100644 --- a/core/tests/Drupal/Tests/Core/Routing/CurrentRouteMatchTest.php +++ b/core/tests/Drupal/Tests/Core/Routing/CurrentRouteMatchTest.php @@ -8,8 +8,6 @@ namespace Drupal\Tests\Core\Routing; use Drupal\Core\Routing\CurrentRouteMatch; -use Drupal\Core\Routing\RouteMatch; -use Drupal\Tests\UnitTestCase; use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; diff --git a/core/tests/Drupal/Tests/Core/Routing/RouteMatchTest.php b/core/tests/Drupal/Tests/Core/Routing/RouteMatchTest.php index a2ca66555..f475ec0c3 100644 --- a/core/tests/Drupal/Tests/Core/Routing/RouteMatchTest.php +++ b/core/tests/Drupal/Tests/Core/Routing/RouteMatchTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Routing; use Drupal\Core\Routing\RouteMatch; -use Drupal\Tests\UnitTestCase; use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; diff --git a/core/tests/Drupal/Tests/Core/Routing/RouteMatchTestBase.php b/core/tests/Drupal/Tests/Core/Routing/RouteMatchTestBase.php index 519ae4e6a..846d46a9e 100644 --- a/core/tests/Drupal/Tests/Core/Routing/RouteMatchTestBase.php +++ b/core/tests/Drupal/Tests/Core/Routing/RouteMatchTestBase.php @@ -9,9 +9,6 @@ use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Tests\UnitTestCase; -use Symfony\Cmf\Component\Routing\RouteObjectInterface; -use Symfony\Component\HttpFoundation\ParameterBag; -use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\Route; /** diff --git a/core/tests/Drupal/Tests/Core/Routing/TrustedRedirectResponseTest.php b/core/tests/Drupal/Tests/Core/Routing/TrustedRedirectResponseTest.php index 4ac1333fa..241479888 100644 --- a/core/tests/Drupal/Tests/Core/Routing/TrustedRedirectResponseTest.php +++ b/core/tests/Drupal/Tests/Core/Routing/TrustedRedirectResponseTest.php @@ -7,10 +7,14 @@ namespace Drupal\Tests\Core\Routing; +use Drupal\Core\Cache\CacheableMetadata; +use Drupal\Core\Cache\CacheableRedirectResponse; +use Drupal\Core\Cache\CacheableResponseInterface; use Drupal\Core\Routing\RequestContext; use Drupal\Core\Routing\TrustedRedirectResponse; use Drupal\Tests\UnitTestCase; use Symfony\Component\DependencyInjection\ContainerBuilder; +use Symfony\Component\HttpFoundation\RedirectResponse; /** * @coversDefaultClass \Drupal\Core\Routing\TrustedRedirectResponse @@ -54,4 +58,32 @@ public function testSetTargetUrlWithTrustedUrl() { $this->assertEquals('http://good-external-url.com/example', $redirect_response->getTargetUrl()); } + /** + * @covers ::createFromRedirectResponse + * @dataProvider providerCreateFromRedirectResponse + */ + public function testCreateFromRedirectResponse($redirect_response) { + $trusted_redirect_response = TrustedRedirectResponse::createFromRedirectResponse($redirect_response); + + // The trusted redirect response is always a CacheableResponseInterface instance. + $this->assertTrue($trusted_redirect_response instanceof CacheableResponseInterface); + + // But it is only actually cacheable (non-zero max-age) if the redirect + // response passed to TrustedRedirectResponse::createFromRedirectResponse() + // is itself cacheable. + $expected_cacheability = ($redirect_response instanceof CacheableResponseInterface) ? $redirect_response->getCacheableMetadata() : (new CacheableMetadata())->setCacheMaxAge(0); + $this->assertEquals($expected_cacheability, $trusted_redirect_response->getCacheableMetadata()); + } + + /** + * @return array + */ + public function providerCreateFromRedirectResponse() { + return [ + 'cacheable-with-tags' => [(new CacheableRedirectResponse('/example'))->addCacheableDependency((new CacheableMetadata())->addCacheTags(['foo']))], + 'cacheable-with-max-age-0' => [(new CacheableRedirectResponse('/example'))->addCacheableDependency((new CacheableMetadata())->setCacheMaxAge(0))], + 'uncacheable' => [new RedirectResponse('/example')], + ]; + } + } diff --git a/core/tests/Drupal/Tests/Core/Session/AnonymousUserSessionTest.php b/core/tests/Drupal/Tests/Core/Session/AnonymousUserSessionTest.php index 043e17ecf..c3cabec1e 100644 --- a/core/tests/Drupal/Tests/Core/Session/AnonymousUserSessionTest.php +++ b/core/tests/Drupal/Tests/Core/Session/AnonymousUserSessionTest.php @@ -9,11 +9,7 @@ use Drupal\Tests\UnitTestCase; use Drupal\Core\Session\AnonymousUserSession; - use Drupal\user\RoleInterface; - use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Scope; -use Symfony\Component\HttpFoundation\RequestStack; +use Drupal\user\RoleInterface; /** * @coversDefaultClass \Drupal\Core\Session\AnonymousUserSession diff --git a/core/tests/Drupal/Tests/Core/Session/PermissionsHashGeneratorTest.php b/core/tests/Drupal/Tests/Core/Session/PermissionsHashGeneratorTest.php index 925c3109b..0fffbb9f9 100644 --- a/core/tests/Drupal/Tests/Core/Session/PermissionsHashGeneratorTest.php +++ b/core/tests/Drupal/Tests/Core/Session/PermissionsHashGeneratorTest.php @@ -12,7 +12,6 @@ use Drupal\Core\Site\Settings; use Drupal\Tests\UnitTestCase; - /** * @coversDefaultClass \Drupal\Core\Session\PermissionsHashGenerator * @group Session diff --git a/core/tests/Drupal/Tests/Core/Session/SessionConfigurationTest.php b/core/tests/Drupal/Tests/Core/Session/SessionConfigurationTest.php index 59325eb1e..27f61771c 100644 --- a/core/tests/Drupal/Tests/Core/Session/SessionConfigurationTest.php +++ b/core/tests/Drupal/Tests/Core/Session/SessionConfigurationTest.php @@ -8,7 +8,6 @@ namespace Drupal\Tests\Core\Session; use Drupal\Tests\UnitTestCase; -use Drupal\Core\Session\SessionConfiguration; use Symfony\Component\HttpFoundation\Request; /** diff --git a/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php b/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php index f92109b42..df5729088 100644 --- a/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php +++ b/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php @@ -66,13 +66,11 @@ public function reverseProxyEnabledProvider() { return array( array( array( - 'reverse_proxy_header' => 'HTTP_X_FORWARDED_FOR', - 'reverse_proxy_addresses' => array(), - ), - ), - array( - array( - 'reverse_proxy_header' => 'X_FORWARDED_HOST', + 'reverse_proxy_header' => 'X_FORWARDED_FOR_CUSTOMIZED', + 'reverse_proxy_proto_header' => 'X_FORWARDED_PROTO_CUSTOMIZED', + 'reverse_proxy_host_header' => 'X_FORWARDED_HOST_CUSTOMIZED', + 'reverse_proxy_port_header' => 'X_FORWARDED_PORT_CUSTOMIZED', + 'reverse_proxy_forwarded_header' => 'FORWARDED_CUSTOMIZED', 'reverse_proxy_addresses' => array('127.0.0.2', '127.0.0.3'), ), ), @@ -95,6 +93,10 @@ protected function trustedHeadersAreSet(Settings $settings) { $middleware->handle($request); $this->assertSame($settings->get('reverse_proxy_header'), $request->getTrustedHeaderName($request::HEADER_CLIENT_IP)); + $this->assertSame($settings->get('reverse_proxy_proto_header'), $request->getTrustedHeaderName($request::HEADER_CLIENT_PROTO)); + $this->assertSame($settings->get('reverse_proxy_host_header'), $request->getTrustedHeaderName($request::HEADER_CLIENT_HOST)); + $this->assertSame($settings->get('reverse_proxy_port_header'), $request->getTrustedHeaderName($request::HEADER_CLIENT_PORT)); + $this->assertSame($settings->get('reverse_proxy_forwarded_header'), $request->getTrustedHeaderName($request::HEADER_FORWARDED)); $this->assertSame($settings->get('reverse_proxy_addresses'), $request->getTrustedProxies()); } } diff --git a/core/tests/Drupal/Tests/Core/Theme/ThemeNegotiatorTest.php b/core/tests/Drupal/Tests/Core/Theme/ThemeNegotiatorTest.php index 55a6f7f44..0234ded98 100644 --- a/core/tests/Drupal/Tests/Core/Theme/ThemeNegotiatorTest.php +++ b/core/tests/Drupal/Tests/Core/Theme/ThemeNegotiatorTest.php @@ -10,8 +10,6 @@ use Drupal\Core\Routing\RouteMatch; use Drupal\Core\Theme\ThemeNegotiator; use Drupal\Tests\UnitTestCase; -use Symfony\Component\HttpFoundation\Request; -use Symfony\Component\HttpFoundation\RequestStack; use Symfony\Component\Routing\Route; /** diff --git a/core/tests/Drupal/Tests/UnitTestCase.php b/core/tests/Drupal/Tests/UnitTestCase.php index a956d1960..f2c6f4c62 100644 --- a/core/tests/Drupal/Tests/UnitTestCase.php +++ b/core/tests/Drupal/Tests/UnitTestCase.php @@ -9,7 +9,6 @@ use Drupal\Component\FileCache\FileCacheFactory; use Drupal\Component\Utility\Random; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Cache\CacheTagsInvalidatorInterface; use Drupal\Core\DependencyInjection\ContainerBuilder; use Drupal\Core\StringTranslation\TranslatableMarkup; diff --git a/core/themes/bartik/bartik.theme b/core/themes/bartik/bartik.theme index 03dc8b443..3d3ca1297 100644 --- a/core/themes/bartik/bartik.theme +++ b/core/themes/bartik/bartik.theme @@ -5,7 +5,6 @@ * Functions to support theming in the Bartik theme. */ -use Drupal\Component\Utility\Xss; use Drupal\Core\Template\Attribute; /** diff --git a/core/themes/bartik/color/preview.js b/core/themes/bartik/color/preview.js index 7520f299e..cee0e0ec3 100644 --- a/core/themes/bartik/color/preview.js +++ b/core/themes/bartik/color/preview.js @@ -4,7 +4,7 @@ */ (function ($, Drupal, drupalSettings) { - "use strict"; + 'use strict'; Drupal.color = { logoChanged: false, @@ -37,7 +37,7 @@ var gradient_start = form.find('.js-color-palette input[name="palette[top]"]').val(); var gradient_end = form.find('.js-color-palette input[name="palette[bottom]"]').val(); - form.find('.color-preview .color-preview-header').attr('style', "background-color: " + gradient_start + "; background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from(" + gradient_start + "), to(" + gradient_end + ")); background-image: -moz-linear-gradient(-90deg, " + gradient_start + ", " + gradient_end + ");"); + form.find('.color-preview .color-preview-header').attr('style', 'background-color: ' + gradient_start + '; background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from(' + gradient_start + '), to(' + gradient_end + ')); background-image: -moz-linear-gradient(-90deg, ' + gradient_start + ', ' + gradient_end + ');'); form.find('.color-preview .color-preview-site-name').css('color', form.find('.js-color-palette input[name="palette[titleslogan]"]').val()); } diff --git a/core/themes/engines/twig/twig.engine b/core/themes/engines/twig/twig.engine index 44ee5ac6b..30ec511f1 100644 --- a/core/themes/engines/twig/twig.engine +++ b/core/themes/engines/twig/twig.engine @@ -6,7 +6,6 @@ */ use Drupal\Component\Utility\Html; -use Drupal\Component\Utility\SafeMarkup; use Drupal\Core\Render\Markup; use Drupal\Core\Extension\Extension; diff --git a/core/themes/seven/css/components/buttons.css b/core/themes/seven/css/components/buttons.css index a4855af04..479ca9cfc 100644 --- a/core/themes/seven/css/components/buttons.css +++ b/core/themes/seven/css/components/buttons.css @@ -127,7 +127,7 @@ /** * 1. Use px units to ensure button text is centered vertically. */ -.no-touch .button--small { +.no-touchevents .button--small { font-size: 13px; font-size: 0.813rem; padding: 2px 1em; /* 1 */ diff --git a/core/themes/seven/js/mobile.install.js b/core/themes/seven/js/mobile.install.js index 43196cb9b..e7a0b5c18 100644 --- a/core/themes/seven/js/mobile.install.js +++ b/core/themes/seven/js/mobile.install.js @@ -1,6 +1,6 @@ (function () { - "use strict"; + 'use strict'; function findActiveStep(steps) { for (var i = 0; i < steps.length; i++) { diff --git a/core/themes/seven/js/nav-tabs.js b/core/themes/seven/js/nav-tabs.js index 8518c9bd5..ba44ffb94 100644 --- a/core/themes/seven/js/nav-tabs.js +++ b/core/themes/seven/js/nav-tabs.js @@ -7,7 +7,7 @@ */ (function ($, Drupal) { - "use strict"; + 'use strict'; function init(i, tab) { var $tab = $(tab); diff --git a/core/themes/seven/seven.theme b/core/themes/seven/seven.theme index 29aaf6203..9afa603b2 100644 --- a/core/themes/seven/seven.theme +++ b/core/themes/seven/seven.theme @@ -5,7 +5,6 @@ * Functions to support theming in the Seven theme. */ -use Drupal\Component\Utility\Xss; use Drupal\Core\Form\FormStateInterface; /** diff --git a/sites/default/default.services.yml b/sites/default/default.services.yml index 4ab0662e6..23f6483cc 100644 --- a/sites/default/default.services.yml +++ b/sites/default/default.services.yml @@ -115,6 +115,17 @@ parameters: # # @default [] tags: [] + # Cacheability debugging: + # + # Responses with cacheability metadata (CacheableResponseInterface instances) + # get X-Drupal-Cache-Tags and X-Drupal-Cache-Contexts headers. + # + # For more information about debugging cacheable responses, see + # https://www.drupal.org/developing/api/8/response/cacheable-response-interface + # + # Not recommended in production environments + # @default false + http.response.debug_cacheability_headers: false factory.keyvalue: {} # Default key/value storage service to use. diff --git a/sites/default/default.settings.php b/sites/default/default.settings.php index 6a45d2540..b1f95e201 100644 --- a/sites/default/default.settings.php +++ b/sites/default/default.settings.php @@ -369,7 +369,31 @@ * Set this value if your proxy server sends the client IP in a header * other than X-Forwarded-For. */ -# $settings['reverse_proxy_header'] = 'HTTP_X_CLUSTER_CLIENT_IP'; +# $settings['reverse_proxy_header'] = 'X_CLUSTER_CLIENT_IP'; + +/** + * Set this value if your proxy server sends the client protocol in a header + * other than X-Forwarded-Proto. + */ +# $settings['reverse_proxy_proto_header'] = 'X_FORWARDED_PROTO'; + +/** + * Set this value if your proxy server sends the client protocol in a header + * other than X-Forwarded-Host. + */ +# $settings['reverse_proxy_host_header'] = 'X_FORWARDED_HOST'; + +/** + * Set this value if your proxy server sends the client protocol in a header + * other than X-Forwarded-Port. + */ +# $settings['reverse_proxy_port_header'] = 'X_FORWARDED_PORT'; + +/** + * Set this value if your proxy server sends the client protocol in a header + * other than Forwarded. + */ +# $settings['reverse_proxy_forwarded_header'] = 'FORWARDED'; /** * Page caching: @@ -446,7 +470,7 @@ # $settings['allow_authorize_operations'] = FALSE; /** - * Default mode for for directories and files written by Drupal. + * Default mode for directories and files written by Drupal. * * Value should be in PHP Octal Notation, with leading zero. */ diff --git a/vendor/behat/mink-browserkit-driver/README.md b/vendor/behat/mink-browserkit-driver/README.md old mode 100755 new mode 100644 diff --git a/vendor/behat/mink-browserkit-driver/tests/BrowserKitConfig.php b/vendor/behat/mink-browserkit-driver/tests/BrowserKitConfig.php deleted file mode 100644 index b80a2fbea..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/BrowserKitConfig.php +++ /dev/null @@ -1,37 +0,0 @@ -visit('http://localhost/foo/index.html'); - $this->assertEquals(200, $session->getStatusCode()); - $this->assertEquals('http://localhost/foo/index.html', $session->getCurrentUrl()); - } -} diff --git a/vendor/behat/mink-browserkit-driver/tests/Custom/ErrorHandlingTest.php b/vendor/behat/mink-browserkit-driver/tests/Custom/ErrorHandlingTest.php deleted file mode 100644 index 9e2643c14..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/Custom/ErrorHandlingTest.php +++ /dev/null @@ -1,181 +0,0 @@ -client = new TestClient(); - } - - public function testGetClient() - { - $this->assertSame($this->client, $this->getDriver()->getClient()); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage Unable to access the response before visiting a page - */ - public function testGetResponseHeaderWithoutVisit() - { - $this->getDriver()->getResponseHeaders(); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage Unable to access the response content before visiting a page - */ - public function testFindWithoutVisit() - { - $this->getDriver()->find('//html'); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage Unable to access the request before visiting a page - */ - public function testGetCurrentUrlWithoutVisit() - { - $this->getDriver()->getCurrentUrl(); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage The selected node has an invalid form attribute (foo) - */ - public function testNotMatchingHtml5FormId() - { - $html = <<<'HTML' - - -
    - - -
    - - -HTML; - - $this->client->setNextResponse(new Response($html)); - - $driver = $this->getDriver(); - $driver->visit('/index.php'); - $driver->setValue('//input[./@name="test"]', 'bar'); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage The selected node has an invalid form attribute (foo) - */ - public function testInvalidHtml5FormId() - { - $html = <<<'HTML' - - -
    - - -
    -
    - - -HTML; - - $this->client->setNextResponse(new Response($html)); - - $driver = $this->getDriver(); - $driver->visit('/index.php'); - $driver->setValue('//input[./@name="test"]', 'bar'); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage The selected node does not have a form ancestor. - */ - public function testManipulateInputWithoutForm() - { - $html = <<<'HTML' - - -
    - -
    -
    - -
    - - -HTML; - - $this->client->setNextResponse(new Response($html)); - - $driver = $this->getDriver(); - $driver->visit('/index.php'); - $driver->setValue('//input[./@name="test"]', 'bar'); - } - - /** - * @expectedException \Behat\Mink\Exception\DriverException - * @expectedExceptionMessage Behat\Mink\Driver\BrowserKitDriver supports clicking on links and submit or reset buttons only. But "div" provided - */ - public function testClickOnUnsupportedElement() - { - $html = <<<'HTML' - - -
    - - -HTML; - - $this->client->setNextResponse(new Response($html)); - - $driver = $this->getDriver(); - $driver->visit('/index.php'); - $driver->click('//div'); - } - - private function getDriver() - { - return new BrowserKitDriver($this->client); - } -} - -class TestClient extends Client -{ - protected $nextResponse = null; - protected $nextScript = null; - - public function setNextResponse(Response $response) - { - $this->nextResponse = $response; - } - - public function setNextScript($script) - { - $this->nextScript = $script; - } - - protected function doRequest($request) - { - if (null === $this->nextResponse) { - return new Response(); - } - - $response = $this->nextResponse; - $this->nextResponse = null; - - return $response; - } -} diff --git a/vendor/behat/mink-browserkit-driver/tests/app.php b/vendor/behat/mink-browserkit-driver/tests/app.php deleted file mode 100644 index d3f123627..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/app.php +++ /dev/null @@ -1,37 +0,0 @@ -register(new \Silex\Provider\SessionServiceProvider()); - -$def = realpath(__DIR__.'/../vendor/behat/mink/driver-testsuite/web-fixtures'); -$ovr = realpath(__DIR__.'/web-fixtures'); -$cbk = function ($file) use ($app, $def, $ovr) { - $file = str_replace('.file', '.php', $file); - $path = file_exists($ovr.'/'.$file) ? $ovr.'/'.$file : $def.'/'.$file; - $resp = null; - - ob_start(); - include($path); - $content = ob_get_clean(); - - if ($resp) { - if ('' === $resp->getContent()) { - $resp->setContent($content); - } - - return $resp; - } - - return $content; -}; - -$app->get('/{file}', $cbk)->assert('file', '.*'); -$app->post('/{file}', $cbk)->assert('file', '.*'); - -$app['debug'] = true; -$app['exception_handler']->disable(); -$app['session.test'] = true; - -return $app; diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/404.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/404.php deleted file mode 100644 index 2ae1ff94a..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/404.php +++ /dev/null @@ -1,3 +0,0 @@ - - - - Advanced form save - - - -request->all(); -$FILES = $request->files->all(); - -if (isset($POST['select_multiple_numbers']) && false !== strpos($POST['select_multiple_numbers'][0], ',')) { - $POST['select_multiple_numbers'] = explode(',', $POST['select_multiple_numbers'][0]); -} - -// checkbox can have any value and will be successful in case "on" -// http://www.w3.org/TR/html401/interact/forms.html#checkbox -$POST['agreement'] = isset($POST['agreement']) ? 'on' : 'off'; -ksort($POST); -echo str_replace('>', '', var_export($POST, true)) . "\n"; -if (isset($FILES['about']) && file_exists($FILES['about']->getPathname())) { - echo $FILES['about']->getClientOriginalName() . "\n"; - echo file_get_contents($FILES['about']->getPathname()); -} else { - echo "no file"; -} -?> - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_auth.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_auth.php deleted file mode 100644 index 48132b6f1..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_auth.php +++ /dev/null @@ -1,15 +0,0 @@ -server->all(); - -$username = isset($SERVER['PHP_AUTH_USER']) ? $SERVER['PHP_AUTH_USER'] : false; -$password = isset($SERVER['PHP_AUTH_PW']) ? $SERVER['PHP_AUTH_PW'] : false; - -if ($username == 'mink-user' && $password == 'mink-password') { - echo 'is authenticated'; -} else { - $resp = new \Symfony\Component\HttpFoundation\Response(); - $resp->setStatusCode(401); - $resp->headers->set('WWW-Authenticate', 'Basic realm="Mink Testing Area"'); - - echo 'is not authenticated'; -} diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_form_post.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_form_post.php deleted file mode 100644 index 1efe45ee8..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_form_post.php +++ /dev/null @@ -1,14 +0,0 @@ - - - - - Basic Form Saving - - - -

    Anket for request->get('first_name') ?>

    - - Firstname: request->get('first_name') ?> - Lastname: request->get('last_name') ?> - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_get_form.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_get_form.php deleted file mode 100644 index fd2817d33..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/basic_get_form.php +++ /dev/null @@ -1,23 +0,0 @@ - - - - Basic Get Form - - - -

    Basic Get Form Page

    - -
    - query->all(); - echo isset($GET['q']) && $GET['q'] ? $GET['q'] : 'No search query' - ?> -
    - -
    - - - -
    - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page1.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page1.php deleted file mode 100644 index a928b2f37..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page1.php +++ /dev/null @@ -1,17 +0,0 @@ -headers->setCookie($cook); -?> - - - - basic form - - - - - basic page with cookie set from server side - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page2.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page2.php deleted file mode 100644 index ab5424304..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page2.php +++ /dev/null @@ -1,14 +0,0 @@ - - - - Basic Form - - - - - Previous cookie: cookies->has('srvr_cookie') ? $app['request']->cookies->get('srvr_cookie') : 'NO'; - ?> - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page3.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page3.php deleted file mode 100644 index f24d5870d..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/cookie_page3.php +++ /dev/null @@ -1,20 +0,0 @@ -cookies->has('foo'); -$resp = new Symfony\Component\HttpFoundation\Response(); -$cook = new Symfony\Component\HttpFoundation\Cookie('foo', 'bar'); -$resp->headers->setCookie($cook); - -?> - - - - HttpOnly Cookie Test - - - - - - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/headers.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/headers.php deleted file mode 100644 index b829425c5..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/headers.php +++ /dev/null @@ -1,10 +0,0 @@ - - - - Headers page - - - - server->all()); ?> - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue130.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue130.php deleted file mode 100644 index 207967389..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue130.php +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - query->get('p')) { - echo 'Go to 2'; - } else { - echo ''.$app['request']->headers->get('referer').''; - } - ?> - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue140.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue140.php deleted file mode 100644 index 42d8437c6..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/issue140.php +++ /dev/null @@ -1,20 +0,0 @@ - - - - - -isMethod('POST')) { - $resp = new Symfony\Component\HttpFoundation\Response(); - $cook = new Symfony\Component\HttpFoundation\Cookie('tc', $app['request']->request->get('cookie_value')); - $resp->headers->setCookie($cook); -} elseif ($app['request']->query->has('show_value')) { - echo $app['request']->cookies->get('tc'); - return; -} -?> -
    - - -
    - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/print_cookies.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/print_cookies.php deleted file mode 100644 index ac6f07810..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/print_cookies.php +++ /dev/null @@ -1,25 +0,0 @@ - - - - Cookies page - - - - cookies->all(); - unset($cookies['MOCKSESSID']); - - if (isset($cookies['srvr_cookie'])) { - $srvrCookie = $cookies['srvr_cookie']; - unset($cookies['srvr_cookie']); - $cookies['_SESS'] = ''; - $cookies['srvr_cookie'] = $srvrCookie; - } - - foreach ($cookies as $name => $val) { - $cookies[$name] = (string)$val; - } - echo str_replace(array('>'), '', var_export($cookies, true)); - ?> - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/redirector.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/redirector.php deleted file mode 100644 index 39e8a5308..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/redirector.php +++ /dev/null @@ -1,3 +0,0 @@ -headers->set('X-Mink-Test', 'response-headers'); -?> - - - - Response headers - - - -

    Response headers

    - - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/session_test.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/session_test.php deleted file mode 100644 index 58576e3da..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/session_test.php +++ /dev/null @@ -1,19 +0,0 @@ -getSession(); - -if ($app['request']->query->has('login')) { - $session->migrate(); -} -?> - - - - Session Test - - - - -
    getId() ?>
    - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page1.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page1.php deleted file mode 100644 index 807c23ea4..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page1.php +++ /dev/null @@ -1,18 +0,0 @@ -server->get('REQUEST_URI'); - $resp = new Symfony\Component\HttpFoundation\Response(); - $cook = new Symfony\Component\HttpFoundation\Cookie('srvr_cookie', 'srv_var_is_set_sub_folder', 0, dirname($requestUri)); - $resp->headers->setCookie($cook); -?> - - - - basic form - - - - - basic page with cookie set from server side - - diff --git a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page2.php b/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page2.php deleted file mode 100644 index 22a7dab06..000000000 --- a/vendor/behat/mink-browserkit-driver/tests/web-fixtures/sub-folder/cookie_page2.php +++ /dev/null @@ -1,18 +0,0 @@ - - - - Basic Form - - - - - Previous cookie: cookies->has('srvr_cookie')) { - echo $app['request']->cookies->get('srvr_cookie'); - } else { - echo 'NO'; - } - ?> - - diff --git a/vendor/behat/mink-goutte-driver/tests/Custom/InstantiationTest.php b/vendor/behat/mink-goutte-driver/tests/Custom/InstantiationTest.php deleted file mode 100644 index db75a184b..000000000 --- a/vendor/behat/mink-goutte-driver/tests/Custom/InstantiationTest.php +++ /dev/null @@ -1,27 +0,0 @@ -getMockBuilder('Goutte\Client')->disableOriginalConstructor()->getMock(); - $client->expects($this->once()) - ->method('followRedirects') - ->with(true); - - $driver = new GoutteDriver($client); - - $this->assertSame($client, $driver->getClient()); - } - - public function testInstantiateWithoutClient() - { - $driver = new GoutteDriver(); - - $this->assertInstanceOf('Behat\Mink\Driver\Goutte\Client', $driver->getClient()); - } -} diff --git a/vendor/behat/mink-goutte-driver/tests/GoutteConfig.php b/vendor/behat/mink-goutte-driver/tests/GoutteConfig.php deleted file mode 100644 index bbe90f774..000000000 --- a/vendor/behat/mink-goutte-driver/tests/GoutteConfig.php +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - vendor/behat/mink/driver-testsuite/tests - - - - ./tests/ - - - - - - ./src - - - -``` - -Then create the driver config for the testsuite: - -```php -// tests/Config.php - -namespace Acme\MyDriver\Tests; - -use Behat\Mink\Tests\Driver\AbstractConfig; - -class Config extends AbstractConfig -{ - /** - * Creates an instance of the config. - * - * This is the callable registered as a php variable in the phpunit.xml config file. - * It could be outside the class but this is convenient. - */ - public static function getInstance() - { - return new self(); - } - - /** - * Creates driver instance. - * - * @return \Behat\Mink\Driver\DriverInterface - */ - public function createDriver() - { - return new \Acme\MyDriver\MyDriver(); - } -} -``` - -Some other methods are available in the AbstractConfig which can be overwritten to adapt the testsuite to -the needs of the driver (skipping some tests for instance). - -Adding Driver-specific Tests ----------------------------- - -When adding extra test cases specific to the driver, either use your own namespace or put them in the -``Behat\Mink\Tests\Driver\Custom`` subnamespace to ensure that you will not create conflicts with test cases -added in the driver testsuite in the future. diff --git a/vendor/behat/mink/driver-testsuite/bootstrap.php b/vendor/behat/mink/driver-testsuite/bootstrap.php deleted file mode 100644 index f69a45bd3..000000000 --- a/vendor/behat/mink/driver-testsuite/bootstrap.php +++ /dev/null @@ -1,28 +0,0 @@ -addPsr4('Behat\Mink\Tests\Driver\\', __DIR__.'/tests'); - -// Clean the global variables -unset($file); -unset($loader); - -// Check the definition of the driverLoaderFactory - -if (!isset($GLOBALS['driver_config_factory'])) { - echo PHP_EOL.'The "driver_config_factory" global variable must be set.'.PHP_EOL; - exit(1); -} -if (!is_callable($GLOBALS['driver_config_factory'])) { - echo PHP_EOL.'The "driver_config_factory" global variable must be a callable.'.PHP_EOL; - exit(1); -} diff --git a/vendor/behat/mink/driver-testsuite/tests/AbstractConfig.php b/vendor/behat/mink/driver-testsuite/tests/AbstractConfig.php deleted file mode 100644 index 057e6fd48..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/AbstractConfig.php +++ /dev/null @@ -1,83 +0,0 @@ -supportsCss() && 0 === strpos($testCase, 'Behat\Mink\Tests\Driver\Css\\')) { - return 'This driver does not support CSS.'; - } - - if (!$this->supportsJs() && 0 === strpos($testCase, 'Behat\Mink\Tests\Driver\Js\\')) { - return 'This driver does not support JavaScript.'; - } - - return null; - } - - /** - * Whether the JS tests should run or no. - * - * @return bool - */ - protected function supportsJs() - { - return true; - } - - /** - * Whether the CSS tests should run or no. - * - * @return bool - */ - protected function supportsCss() - { - return false; - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/BasicAuthTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/BasicAuthTest.php deleted file mode 100644 index 40d932d0d..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/BasicAuthTest.php +++ /dev/null @@ -1,64 +0,0 @@ -getSession(); - - $session->setBasicAuth($user, $pass); - - $session->visit($this->pathTo('/basic_auth.php')); - - $this->assertContains($pageText, $session->getPage()->getContent()); - } - - public function setBasicAuthDataProvider() - { - return array( - array('mink-user', 'mink-password', 'is authenticated'), - array('', '', 'is not authenticated'), - ); - } - - public function testResetBasicAuth() - { - $session = $this->getSession(); - - $session->setBasicAuth('mink-user', 'mink-password'); - - $session->visit($this->pathTo('/basic_auth.php')); - - $this->assertContains('is authenticated', $session->getPage()->getContent()); - - $session->setBasicAuth(false); - - $session->visit($this->pathTo('/headers.php')); - - $this->assertNotContains('PHP_AUTH_USER', $session->getPage()->getContent()); - } - - public function testResetWithBasicAuth() - { - $session = $this->getSession(); - - $session->setBasicAuth('mink-user', 'mink-password'); - - $session->visit($this->pathTo('/basic_auth.php')); - - $this->assertContains('is authenticated', $session->getPage()->getContent()); - - $session->reset(); - - $session->visit($this->pathTo('/headers.php')); - - $this->assertNotContains('PHP_AUTH_USER', $session->getPage()->getContent()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/BestPracticesTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/BestPracticesTest.php deleted file mode 100644 index d6cda7db6..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/BestPracticesTest.php +++ /dev/null @@ -1,84 +0,0 @@ -createDriver(); - - $this->assertInstanceOf('Behat\Mink\Driver\CoreDriver', $driver); - - return $driver; - } - - /** - * @depends testExtendsCoreDriver - */ - public function testImplementFindXpath() - { - $driver = $this->createDriver(); - - $this->assertNotImplementMethod('find', $driver, 'The driver should overwrite `findElementXpaths` rather than `find` for forward compatibility with Mink 2.'); - $this->assertImplementMethod('findElementXpaths', $driver, 'The driver must be able to find elements.'); - $this->assertNotImplementMethod('setSession', $driver, 'The driver should not deal with the Session directly for forward compatibility with Mink 2.'); - } - - /** - * @dataProvider provideRequiredMethods - */ - public function testImplementBasicApi($method) - { - $driver = $this->createDriver(); - - $this->assertImplementMethod($method, $driver, 'The driver is unusable when this method is not implemented.'); - } - - public function provideRequiredMethods() - { - return array( - array('start'), - array('isStarted'), - array('stop'), - array('reset'), - array('visit'), - array('getCurrentUrl'), - array('getContent'), - array('click'), - ); - } - - private function assertImplementMethod($method, $object, $reason = '') - { - $ref = new \ReflectionClass(get_class($object)); - $refMethod = $ref->getMethod($method); - - $message = sprintf('The driver should implement the `%s` method.', $method); - - if ('' !== $reason) { - $message .= ' '.$reason; - } - - $this->assertSame($ref->name, $refMethod->getDeclaringClass()->name, $message); - } - - private function assertNotImplementMethod($method, $object, $reason = '') - { - $ref = new \ReflectionClass(get_class($object)); - $refMethod = $ref->getMethod($method); - - $message = sprintf('The driver should not implement the `%s` method.', $method); - - if ('' !== $reason) { - $message .= ' '.$reason; - } - - $this->assertNotSame($ref->name, $refMethod->getDeclaringClass()->name, $message); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/ContentTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/ContentTest.php deleted file mode 100644 index fdd0ffacd..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/ContentTest.php +++ /dev/null @@ -1,86 +0,0 @@ -getSession()->visit($this->pathTo('/index.html')); - - $element = $this->getAssertSession()->elementExists('css', '.travers'); - - $this->assertEquals( - "
    \n
    el1
    \n". - "
    el2
    \n
    \n". - " some deep url\n". - "
    \n
    ", - $element->getOuterHtml() - ); - } - - public function testDumpingEmptyElements() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $element = $this->getAssertSession()->elementExists('css', '#empty'); - - $this->assertEquals( - 'An empty tag should be rendered with both open and close tags.', - trim($element->getHtml()) - ); - } - - /** - * @dataProvider getAttributeDataProvider - */ - public function testGetAttribute($attributeName, $attributeValue) - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $element = $this->getSession()->getPage()->findById('attr-elem['.$attributeName.']'); - - $this->assertNotNull($element); - $this->assertSame($attributeValue, $element->getAttribute($attributeName)); - } - - public function getAttributeDataProvider() - { - return array( - array('with-value', 'some-value'), - array('without-value', ''), - array('with-empty-value', ''), - array('with-missing', null), - ); - } - - public function testJson() - { - $this->getSession()->visit($this->pathTo('/json.php')); - $this->assertContains( - '{"key1":"val1","key2":234,"key3":[1,2,3]}', - $this->getSession()->getPage()->getContent() - ); - } - - public function testHtmlDecodingNotPerformed() - { - $session = $this->getSession(); - $webAssert = $this->getAssertSession(); - $session->visit($this->pathTo('/html_decoding.html')); - $page = $session->getPage(); - - $span = $webAssert->elementExists('css', 'span'); - $input = $webAssert->elementExists('css', 'input'); - - $expectedHtml = 'some text'; - $this->assertContains($expectedHtml, $page->getHtml(), '.innerHTML is returned as-is'); - $this->assertContains($expectedHtml, $page->getContent(), '.outerHTML is returned as-is'); - - $this->assertEquals('&', $span->getAttribute('custom-attr'), '.getAttribute value is decoded'); - $this->assertEquals('&', $input->getAttribute('value'), '.getAttribute value is decoded'); - $this->assertEquals('&', $input->getValue(), 'node value is decoded'); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/CookieTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/CookieTest.php deleted file mode 100644 index 5636c1194..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/CookieTest.php +++ /dev/null @@ -1,168 +0,0 @@ -getSession()->visit($this->pathTo('/issue140.php')); - - $this->getSession()->getPage()->fillField('cookie_value', 'some:value;'); - $this->getSession()->getPage()->pressButton('Set cookie'); - - $this->getSession()->visit($this->pathTo('/issue140.php?show_value')); - $this->assertEquals('some:value;', $this->getSession()->getCookie('tc')); - $this->assertEquals('some:value;', $this->getSession()->getPage()->getText()); - } - - public function testCookie() - { - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - $this->assertContains('Previous cookie: NO', $this->getSession()->getPage()->getText()); - $this->assertNull($this->getSession()->getCookie('srvr_cookie')); - - $this->getSession()->setCookie('srvr_cookie', 'client cookie set'); - $this->getSession()->reload(); - $this->assertContains('Previous cookie: client cookie set', $this->getSession()->getPage()->getText()); - $this->assertEquals('client cookie set', $this->getSession()->getCookie('srvr_cookie')); - - $this->getSession()->setCookie('srvr_cookie', null); - $this->getSession()->reload(); - $this->assertContains('Previous cookie: NO', $this->getSession()->getPage()->getText()); - - $this->getSession()->visit($this->pathTo('/cookie_page1.php')); - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - - $this->assertContains('Previous cookie: srv_var_is_set', $this->getSession()->getPage()->getText()); - $this->getSession()->setCookie('srvr_cookie', null); - $this->getSession()->reload(); - $this->assertContains('Previous cookie: NO', $this->getSession()->getPage()->getText()); - } - - /** - * @dataProvider cookieWithPathsDataProvider - */ - public function testCookieWithPaths($cookieRemovalMode) - { - // start clean - $session = $this->getSession(); - $session->visit($this->pathTo('/sub-folder/cookie_page2.php')); - $this->assertContains('Previous cookie: NO', $session->getPage()->getText()); - - // cookie from root path is accessible in sub-folder - $session->visit($this->pathTo('/cookie_page1.php')); - $session->visit($this->pathTo('/sub-folder/cookie_page2.php')); - $this->assertContains('Previous cookie: srv_var_is_set', $session->getPage()->getText()); - - // cookie from sub-folder overrides cookie from root path - $session->visit($this->pathTo('/sub-folder/cookie_page1.php')); - $session->visit($this->pathTo('/sub-folder/cookie_page2.php')); - $this->assertContains('Previous cookie: srv_var_is_set_sub_folder', $session->getPage()->getText()); - - if ($cookieRemovalMode == 'session_reset') { - $session->reset(); - } elseif ($cookieRemovalMode == 'cookie_delete') { - $session->setCookie('srvr_cookie', null); - } - - // cookie is removed from all paths - $session->visit($this->pathTo('/sub-folder/cookie_page2.php')); - $this->assertContains('Previous cookie: NO', $session->getPage()->getText()); - } - - public function cookieWithPathsDataProvider() - { - return array( - array('session_reset'), - array('cookie_delete'), - ); - } - - public function testReset() - { - $this->getSession()->visit($this->pathTo('/cookie_page1.php')); - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - $this->assertContains('Previous cookie: srv_var_is_set', $this->getSession()->getPage()->getText()); - - $this->getSession()->reset(); - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - - $this->assertContains('Previous cookie: NO', $this->getSession()->getPage()->getText()); - - $this->getSession()->setCookie('srvr_cookie', 'test_cookie'); - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - $this->assertContains('Previous cookie: test_cookie', $this->getSession()->getPage()->getText()); - $this->getSession()->reset(); - $this->getSession()->visit($this->pathTo('/cookie_page2.php')); - $this->assertContains('Previous cookie: NO', $this->getSession()->getPage()->getText()); - - $this->getSession()->setCookie('client_cookie1', 'some_val'); - $this->getSession()->setCookie('client_cookie2', 123); - $this->getSession()->visit($this->pathTo('/session_test.php')); - $this->getSession()->visit($this->pathTo('/cookie_page1.php')); - - $this->getSession()->visit($this->pathTo('/print_cookies.php')); - $this->assertContains( - "'client_cookie1' = 'some_val'", - $this->getSession()->getPage()->getText() - ); - $this->assertContains( - "'client_cookie2' = '123'", - $this->getSession()->getPage()->getText() - ); - $this->assertContains( - "_SESS' = ", - $this->getSession()->getPage()->getText() - ); - $this->assertContains( - " 'srvr_cookie' = 'srv_var_is_set'", - $this->getSession()->getPage()->getText() - ); - - $this->getSession()->reset(); - $this->getSession()->visit($this->pathTo('/print_cookies.php')); - $this->assertContains('array ( )', $this->getSession()->getPage()->getText()); - } - - public function testHttpOnlyCookieIsDeleted() - { - $this->getSession()->restart(); - $this->getSession()->visit($this->pathTo('/cookie_page3.php')); - $this->assertEquals('Has Cookie: false', $this->findById('cookie-status')->getText()); - - $this->getSession()->reload(); - $this->assertEquals('Has Cookie: true', $this->findById('cookie-status')->getText()); - - $this->getSession()->restart(); - $this->getSession()->visit($this->pathTo('/cookie_page3.php')); - $this->assertEquals('Has Cookie: false', $this->findById('cookie-status')->getText()); - } - - public function testSessionPersistsBetweenRequests() - { - $this->getSession()->visit($this->pathTo('/session_test.php')); - $webAssert = $this->getAssertSession(); - $node = $webAssert->elementExists('css', '#session-id'); - $sessionId = $node->getText(); - - $this->getSession()->visit($this->pathTo('/session_test.php')); - $node = $webAssert->elementExists('css', '#session-id'); - $this->assertEquals($sessionId, $node->getText()); - - $this->getSession()->visit($this->pathTo('/session_test.php?login')); - $node = $webAssert->elementExists('css', '#session-id'); - $this->assertNotEquals($sessionId, $newSessionId = $node->getText()); - - $this->getSession()->visit($this->pathTo('/session_test.php')); - $node = $webAssert->elementExists('css', '#session-id'); - $this->assertEquals($newSessionId, $node->getText()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/ErrorHandlingTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/ErrorHandlingTest.php deleted file mode 100644 index bb4bb2dbe..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/ErrorHandlingTest.php +++ /dev/null @@ -1,265 +0,0 @@ -getSession()->visit($this->pathTo('/500.php')); - - $this->assertContains( - 'Sorry, a server error happened', - $this->getSession()->getPage()->getContent(), - 'Drivers allow loading pages with a 500 status code' - ); - } - - public function testCheckInvalidElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - $element = $this->findById('user-name'); - - $this->setExpectedException(self::INVALID_EXCEPTION); - $this->getSession()->getDriver()->check($element->getXpath()); - } - - public function testCheckNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->check(self::NOT_FOUND_XPATH); - } - - public function testUncheckInvalidElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - $element = $this->findById('user-name'); - - $this->setExpectedException(self::INVALID_EXCEPTION); - $this->getSession()->getDriver()->uncheck($element->getXpath()); - } - - public function testUncheckNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->uncheck(self::NOT_FOUND_XPATH); - } - - public function testSelectOptionInvalidElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - $element = $this->findById('user-name'); - - $this->setExpectedException(self::INVALID_EXCEPTION); - $this->getSession()->getDriver()->selectOption($element->getXpath(), 'test'); - } - - public function testSelectOptionNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->selectOption(self::NOT_FOUND_XPATH, 'test'); - } - - public function testAttachFileInvalidElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - $element = $this->findById('user-name'); - - $this->setExpectedException(self::INVALID_EXCEPTION); - $this->getSession()->getDriver()->attachFile($element->getXpath(), __FILE__); - } - - public function testAttachFileNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->attachFile(self::NOT_FOUND_XPATH, __FILE__); - } - - public function testSubmitFormInvalidElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - $element = $this->findById('core'); - - $this->setExpectedException(self::INVALID_EXCEPTION); - $this->getSession()->getDriver()->submitForm($element->getXpath()); - } - - public function testSubmitFormNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->submitForm(self::NOT_FOUND_XPATH); - } - - public function testGetTagNameNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getTagName(self::NOT_FOUND_XPATH); - } - - public function testGetTextNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getText(self::NOT_FOUND_XPATH); - } - - public function testGetHtmlNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getHtml(self::NOT_FOUND_XPATH); - } - - public function testGetOuterHtmlNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getOuterHtml(self::NOT_FOUND_XPATH); - } - - public function testGetValueNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getValue(self::NOT_FOUND_XPATH); - } - - public function testSetValueNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->setValue(self::NOT_FOUND_XPATH, 'test'); - } - - public function testIsSelectedNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->isSelected(self::NOT_FOUND_XPATH); - } - - public function testIsCheckedNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->isChecked(self::NOT_FOUND_XPATH); - } - - public function testIsVisibleNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->isVisible(self::NOT_FOUND_XPATH); - } - - public function testClickNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->click(self::NOT_FOUND_XPATH); - } - - public function testDoubleClickNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->doubleClick(self::NOT_FOUND_XPATH); - } - - public function testRightClickNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->rightClick(self::NOT_FOUND_XPATH); - } - - public function testGetAttributeNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->getAttribute(self::NOT_FOUND_XPATH, 'id'); - } - - public function testMouseOverNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->mouseOver(self::NOT_FOUND_XPATH); - } - - public function testFocusNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->focus(self::NOT_FOUND_XPATH); - } - - public function testBlurNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->blur(self::NOT_FOUND_XPATH); - } - - public function testKeyPressNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->keyPress(self::NOT_FOUND_XPATH, 'a'); - } - - public function testKeyDownNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->keyDown(self::NOT_FOUND_XPATH, 'a'); - } - - public function testKeyUpNotFoundElement() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $this->setExpectedException(self::NOT_FOUND_EXCEPTION); - $this->getSession()->getDriver()->keyUp(self::NOT_FOUND_XPATH, 'a'); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/HeaderTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/HeaderTest.php deleted file mode 100644 index 072ceb418..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/HeaderTest.php +++ /dev/null @@ -1,78 +0,0 @@ -getSession()->visit($this->pathTo('/issue130.php?p=1')); - $page = $this->getSession()->getPage(); - - $page->clickLink('Go to 2'); - $this->assertEquals($this->pathTo('/issue130.php?p=1'), $page->getText()); - } - - public function testHeaders() - { - $this->getSession()->setRequestHeader('Accept-Language', 'fr'); - $this->getSession()->visit($this->pathTo('/headers.php')); - - $this->assertContains('[HTTP_ACCEPT_LANGUAGE] => fr', $this->getSession()->getPage()->getContent()); - } - - public function testSetUserAgent() - { - $session = $this->getSession(); - - $session->setRequestHeader('user-agent', 'foo bar'); - $session->visit($this->pathTo('/headers.php')); - $this->assertContains('[HTTP_USER_AGENT] => foo bar', $session->getPage()->getContent()); - } - - public function testResetHeaders() - { - $session = $this->getSession(); - - $session->setRequestHeader('X-Mink-Test', 'test'); - $session->visit($this->pathTo('/headers.php')); - - $this->assertContains( - '[HTTP_X_MINK_TEST] => test', - $session->getPage()->getContent(), - 'The custom header should be sent', - true - ); - - $session->reset(); - $session->visit($this->pathTo('/headers.php')); - - $this->assertNotContains( - '[HTTP_X_MINK_TEST] => test', - $session->getPage()->getContent(), - 'The custom header should not be sent after resetting', - true - ); - } - - public function testResponseHeaders() - { - $this->getSession()->visit($this->pathTo('/response_headers.php')); - - $headers = $this->getSession()->getResponseHeaders(); - - $lowercasedHeaders = array(); - foreach ($headers as $name => $value) { - $lowercasedHeaders[str_replace('_', '-', strtolower($name))] = $value; - } - - $this->assertArrayHasKey('x-mink-test', $lowercasedHeaders); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/IFrameTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/IFrameTest.php deleted file mode 100644 index 0ed0f9ef5..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/IFrameTest.php +++ /dev/null @@ -1,27 +0,0 @@ -getSession()->visit($this->pathTo('/iframe.html')); - $webAssert = $this->getAssertSession(); - - $el = $webAssert->elementExists('css', '#text'); - $this->assertSame('Main window div text', $el->getText()); - - $this->getSession()->switchToIFrame('subframe'); - - $el = $webAssert->elementExists('css', '#text'); - $this->assertSame('iFrame div text', $el->getText()); - - $this->getSession()->switchToIFrame(); - - $el = $webAssert->elementExists('css', '#text'); - $this->assertSame('Main window div text', $el->getText()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/NavigationTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/NavigationTest.php deleted file mode 100644 index 7056316a4..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/NavigationTest.php +++ /dev/null @@ -1,69 +0,0 @@ -getSession()->visit($this->pathTo('/redirector.php')); - $this->assertEquals($this->pathTo('/redirect_destination.html'), $this->getSession()->getCurrentUrl()); - } - - public function testPageControls() - { - $this->getSession()->visit($this->pathTo('/randomizer.php')); - $number1 = $this->getAssertSession()->elementExists('css', '#number')->getText(); - - $this->getSession()->reload(); - $number2 = $this->getAssertSession()->elementExists('css', '#number')->getText(); - - $this->assertNotEquals($number1, $number2); - - $this->getSession()->visit($this->pathTo('/links.html')); - $this->getSession()->getPage()->clickLink('Random number page'); - - $this->assertEquals($this->pathTo('/randomizer.php'), $this->getSession()->getCurrentUrl()); - - $this->getSession()->back(); - $this->assertEquals($this->pathTo('/links.html'), $this->getSession()->getCurrentUrl()); - - $this->getSession()->forward(); - $this->assertEquals($this->pathTo('/randomizer.php'), $this->getSession()->getCurrentUrl()); - } - - public function testLinks() - { - $this->getSession()->visit($this->pathTo('/links.html')); - $page = $this->getSession()->getPage(); - $link = $page->findLink('Redirect me to'); - - $this->assertNotNull($link); - $this->assertRegExp('/redirector\.php$/', $link->getAttribute('href')); - $link->click(); - - $this->assertEquals($this->pathTo('/redirect_destination.html'), $this->getSession()->getCurrentUrl()); - - $this->getSession()->visit($this->pathTo('/links.html')); - $page = $this->getSession()->getPage(); - $link = $page->findLink('basic form image'); - - $this->assertNotNull($link); - $this->assertRegExp('/basic_form\.html$/', $link->getAttribute('href')); - $link->click(); - - $this->assertEquals($this->pathTo('/basic_form.html'), $this->getSession()->getCurrentUrl()); - - $this->getSession()->visit($this->pathTo('/links.html')); - $page = $this->getSession()->getPage(); - $link = $page->findLink('Link with a '); - - $this->assertNotNull($link); - $this->assertRegExp('/links\.html\?quoted$/', $link->getAttribute('href')); - $link->click(); - - $this->assertEquals($this->pathTo('/links.html?quoted'), $this->getSession()->getCurrentUrl()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/ScreenshotTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/ScreenshotTest.php deleted file mode 100644 index 329f2d3e1..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/ScreenshotTest.php +++ /dev/null @@ -1,30 +0,0 @@ -markTestSkipped('Testing screenshots requires the GD extension'); - } - - $this->getSession()->visit($this->pathTo('/index.html')); - - $screenShot = $this->getSession()->getScreenshot(); - - $this->assertInternalType('string', $screenShot); - $this->assertFalse(base64_decode($screenShot, true), 'The returned screenshot should not be base64-encoded'); - - $img = imagecreatefromstring($screenShot); - - if (false === $img) { - $this->fail('The screenshot should be a valid image'); - } - - imagedestroy($img); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/StatusCodeTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/StatusCodeTest.php deleted file mode 100644 index 34ca7f0f1..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/StatusCodeTest.php +++ /dev/null @@ -1,22 +0,0 @@ -getSession()->visit($this->pathTo('/index.html')); - - $this->assertEquals(200, $this->getSession()->getStatusCode()); - $this->assertEquals($this->pathTo('/index.html'), $this->getSession()->getCurrentUrl()); - - $this->getSession()->visit($this->pathTo('/404.php')); - - $this->assertEquals($this->pathTo('/404.php'), $this->getSession()->getCurrentUrl()); - $this->assertEquals(404, $this->getSession()->getStatusCode()); - $this->assertEquals('Sorry, page not found', $this->getSession()->getPage()->getContent()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/TraversingTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/TraversingTest.php deleted file mode 100644 index 6f1ebcbca..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/TraversingTest.php +++ /dev/null @@ -1,143 +0,0 @@ -getSession()->visit($this->pathTo('/issue211.html')); - $field = $this->getSession()->getPage()->findField('Téléphone'); - - $this->assertNotNull($field); - } - - public function testElementsTraversing() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $page = $this->getSession()->getPage(); - - $title = $page->find('css', 'h1'); - $this->assertNotNull($title); - $this->assertEquals('Extremely useless page', $title->getText()); - $this->assertEquals('h1', $title->getTagName()); - - $strong = $page->find('xpath', '//div/strong[3]'); - $this->assertNotNull($strong); - $this->assertEquals('pariatur', $strong->getText()); - $this->assertEquals('super-duper', $strong->getAttribute('class')); - $this->assertTrue($strong->hasAttribute('class')); - - $strong2 = $page->find('xpath', '//div/strong[2]'); - $this->assertNotNull($strong2); - $this->assertEquals('veniam', $strong2->getText()); - $this->assertEquals('strong', $strong2->getTagName()); - $this->assertNull($strong2->getAttribute('class')); - $this->assertFalse($strong2->hasAttribute('class')); - - $strongs = $page->findAll('css', 'div#core > strong'); - $this->assertCount(3, $strongs); - $this->assertEquals('Lorem', $strongs[0]->getText()); - $this->assertEquals('pariatur', $strongs[2]->getText()); - - $element = $page->find('css', '#some-element'); - - $this->assertNotNull($element); - $this->assertEquals('some very interesting text', $element->getText()); - $this->assertEquals( - "\n some
    very\n
    \n". - "interesting text\n ", - $element->getHtml() - ); - - $this->assertTrue($element->hasAttribute('data-href')); - $this->assertFalse($element->hasAttribute('data-url')); - $this->assertEquals('http://mink.behat.org', $element->getAttribute('data-href')); - $this->assertNull($element->getAttribute('data-url')); - $this->assertEquals('div', $element->getTagName()); - } - - public function testVeryDeepElementsTraversing() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $page = $this->getSession()->getPage(); - - $footer = $page->find('css', 'footer'); - $this->assertNotNull($footer); - - $searchForm = $footer->find('css', 'form#search-form'); - $this->assertNotNull($searchForm); - $this->assertEquals('search-form', $searchForm->getAttribute('id')); - - $searchInput = $searchForm->findField('Search site...'); - $this->assertNotNull($searchInput); - $this->assertEquals('text', $searchInput->getAttribute('type')); - - $searchInput = $searchForm->findField('Search site...'); - $this->assertNotNull($searchInput); - $this->assertEquals('text', $searchInput->getAttribute('type')); - - $profileForm = $footer->find('css', '#profile'); - $this->assertNotNull($profileForm); - - $profileFormDiv = $profileForm->find('css', 'div'); - $this->assertNotNull($profileFormDiv); - - $profileFormDivLabel = $profileFormDiv->find('css', 'label'); - $this->assertNotNull($profileFormDivLabel); - - $profileFormDivParent = $profileFormDivLabel->getParent(); - $this->assertNotNull($profileFormDivParent); - - $profileFormDivParent = $profileFormDivLabel->getParent(); - $this->assertEquals('something', $profileFormDivParent->getAttribute('data-custom')); - - $profileFormInput = $profileFormDivLabel->findField('user-name'); - $this->assertNotNull($profileFormInput); - $this->assertEquals('username', $profileFormInput->getAttribute('name')); - } - - public function testDeepTraversing() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $traversDivs = $this->getSession()->getPage()->findAll('css', 'div.travers'); - - $this->assertCount(1, $traversDivs); - - $subDivs = $traversDivs[0]->findAll('css', 'div.sub'); - $this->assertCount(3, $subDivs); - - $this->assertTrue($subDivs[2]->hasLink('some deep url')); - $this->assertFalse($subDivs[2]->hasLink('come deep url')); - $subUrl = $subDivs[2]->findLink('some deep url'); - $this->assertNotNull($subUrl); - - $this->assertRegExp('/some_url$/', $subUrl->getAttribute('href')); - $this->assertEquals('some deep url', $subUrl->getText()); - $this->assertEquals('some deep url', $subUrl->getHtml()); - - $this->assertTrue($subUrl->has('css', 'strong')); - $this->assertFalse($subUrl->has('css', 'em')); - $this->assertEquals('deep', $subUrl->find('css', 'strong')->getText()); - } - - public function testFindingChild() - { - $this->getSession()->visit($this->pathTo('/index.html')); - - $form = $this->getSession()->getPage()->find('css', 'footer form'); - $this->assertNotNull($form); - - $this->assertCount(1, $form->findAll('css', 'input'), 'Elements are searched only in the element, not in all previous matches'); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Basic/VisibilityTest.php b/vendor/behat/mink/driver-testsuite/tests/Basic/VisibilityTest.php deleted file mode 100644 index bb5634e2e..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Basic/VisibilityTest.php +++ /dev/null @@ -1,20 +0,0 @@ -getSession()->visit($this->pathTo('/js_test.html')); - $webAssert = $this->getAssertSession(); - - $clicker = $webAssert->elementExists('css', '.elements div#clicker'); - $invisible = $webAssert->elementExists('css', '#invisible'); - - $this->assertFalse($invisible->isVisible()); - $this->assertTrue($clicker->isVisible()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Css/HoverTest.php b/vendor/behat/mink/driver-testsuite/tests/Css/HoverTest.php deleted file mode 100644 index 87041d4f2..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Css/HoverTest.php +++ /dev/null @@ -1,76 +0,0 @@ -getSession()->visit($this->pathTo('/css_mouse_events.html')); - - $this->findById('reset-square')->mouseOver(); - $this->assertActionSquareHeight(100); - - $this->findById('action-square')->mouseOver(); - $this->assertActionSquareHeight(200); - } - - /** - * @group mouse-events - * @depends testMouseOverHover - */ - public function testClickHover() - { - $this->getSession()->visit($this->pathTo('/css_mouse_events.html')); - - $this->findById('reset-square')->mouseOver(); - $this->assertActionSquareHeight(100); - - $this->findById('action-square')->click(); - $this->assertActionSquareHeight(200); - } - - /** - * @group mouse-events - * @depends testMouseOverHover - */ - public function testDoubleClickHover() - { - $this->getSession()->visit($this->pathTo('/css_mouse_events.html')); - - $this->findById('reset-square')->mouseOver(); - $this->assertActionSquareHeight(100); - - $this->findById('action-square')->doubleClick(); - $this->assertActionSquareHeight(200); - } - - /** - * @group mouse-events - * @depends testMouseOverHover - */ - public function testRightClickHover() - { - $this->getSession()->visit($this->pathTo('/css_mouse_events.html')); - - $this->findById('reset-square')->mouseOver(); - $this->assertActionSquareHeight(100); - - $this->findById('action-square')->rightClick(); - $this->assertActionSquareHeight(200); - } - - private function assertActionSquareHeight($expected) - { - $this->assertEquals( - $expected, - $this->getSession()->evaluateScript("return window.$('#action-square').height();"), - 'Mouse is located over the object when mouse-related action is performed' - ); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Form/CheckboxTest.php b/vendor/behat/mink/driver-testsuite/tests/Form/CheckboxTest.php deleted file mode 100644 index 18c4088cd..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Form/CheckboxTest.php +++ /dev/null @@ -1,73 +0,0 @@ -getSession()->visit($this->pathTo('advanced_form.html')); - - $checkbox = $this->getAssertSession()->fieldExists('agreement'); - - $this->assertNull($checkbox->getValue()); - $this->assertFalse($checkbox->isChecked()); - - $checkbox->check(); - - $this->assertEquals('yes', $checkbox->getValue()); - $this->assertTrue($checkbox->isChecked()); - - $checkbox->uncheck(); - - $this->assertNull($checkbox->getValue()); - $this->assertFalse($checkbox->isChecked()); - } - - public function testSetValue() - { - $this->getSession()->visit($this->pathTo('advanced_form.html')); - - $checkbox = $this->getAssertSession()->fieldExists('agreement'); - - $this->assertNull($checkbox->getValue()); - $this->assertFalse($checkbox->isChecked()); - - $checkbox->setValue(true); - - $this->assertEquals('yes', $checkbox->getValue()); - $this->assertTrue($checkbox->isChecked()); - - $checkbox->setValue(false); - - $this->assertNull($checkbox->getValue()); - $this->assertFalse($checkbox->isChecked()); - } - - public function testCheckboxMultiple() - { - $this->getSession()->visit($this->pathTo('/multicheckbox_form.html')); - $webAssert = $this->getAssertSession(); - - $this->assertEquals('Multicheckbox Test', $webAssert->elementExists('css', 'h1')->getText()); - - $updateMail = $webAssert->elementExists('css', '[name="mail_types[]"][value="update"]'); - $spamMail = $webAssert->elementExists('css', '[name="mail_types[]"][value="spam"]'); - - $this->assertEquals('update', $updateMail->getValue()); - $this->assertNull($spamMail->getValue()); - - $this->assertTrue($updateMail->isChecked()); - $this->assertFalse($spamMail->isChecked()); - - $updateMail->uncheck(); - $this->assertFalse($updateMail->isChecked()); - $this->assertFalse($spamMail->isChecked()); - - $spamMail->check(); - $this->assertFalse($updateMail->isChecked()); - $this->assertTrue($spamMail->isChecked()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php b/vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php deleted file mode 100644 index 0e08d34eb..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php +++ /dev/null @@ -1,312 +0,0 @@ -getSession(); - - $session->visit($this->pathTo('/issue212.html')); - - $field = $this->findById('poney-button'); - $this->assertEquals('poney', $field->getValue()); - } - - public function testBasicForm() - { - $this->getSession()->visit($this->pathTo('/basic_form.html')); - - $webAssert = $this->getAssertSession(); - $page = $this->getSession()->getPage(); - $this->assertEquals('Basic Form Page', $webAssert->elementExists('css', 'h1')->getText()); - - $firstname = $webAssert->fieldExists('first_name'); - $lastname = $webAssert->fieldExists('lastn'); - - $this->assertEquals('Firstname', $firstname->getValue()); - $this->assertEquals('Lastname', $lastname->getValue()); - - $firstname->setValue('Konstantin'); - $page->fillField('last_name', 'Kudryashov'); - - $this->assertEquals('Konstantin', $firstname->getValue()); - $this->assertEquals('Kudryashov', $lastname->getValue()); - - $page->findButton('Reset')->click(); - - $this->assertEquals('Firstname', $firstname->getValue()); - $this->assertEquals('Lastname', $lastname->getValue()); - - $firstname->setValue('Konstantin'); - $page->fillField('last_name', 'Kudryashov'); - - $page->findButton('Save')->click(); - - if ($this->safePageWait(5000, 'document.getElementById("first") !== null')) { - $this->assertEquals('Anket for Konstantin', $webAssert->elementExists('css', 'h1')->getText()); - $this->assertEquals('Firstname: Konstantin', $webAssert->elementExists('css', '#first')->getText()); - $this->assertEquals('Lastname: Kudryashov', $webAssert->elementExists('css', '#last')->getText()); - } - } - - /** - * @dataProvider formSubmitWaysDataProvider - */ - public function testFormSubmitWays($submitVia) - { - $session = $this->getSession(); - $session->visit($this->pathTo('/basic_form.html')); - $page = $session->getPage(); - $webAssert = $this->getAssertSession(); - - $firstname = $webAssert->fieldExists('first_name'); - $firstname->setValue('Konstantin'); - - $page->findButton($submitVia)->click(); - - if ($this->safePageWait(5000, 'document.getElementById("first") !== null')) { - $this->assertEquals('Firstname: Konstantin', $webAssert->elementExists('css', '#first')->getText()); - } else { - $this->fail('Form was never submitted'); - } - } - - public function formSubmitWaysDataProvider() - { - return array( - array('Save'), - array('input-type-image'), - array('button-without-type'), - array('button-type-submit'), - ); - } - - public function testFormSubmit() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/basic_form.html')); - - $webAssert = $this->getAssertSession(); - $webAssert->fieldExists('first_name')->setValue('Konstantin'); - - $webAssert->elementExists('xpath', 'descendant-or-self::form[1]')->submit(); - - if ($this->safePageWait(5000, 'document.getElementById("first") !== null')) { - $this->assertEquals('Firstname: Konstantin', $webAssert->elementExists('css', '#first')->getText()); - }; - } - - public function testFormSubmitWithoutButton() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/form_without_button.html')); - - $webAssert = $this->getAssertSession(); - $webAssert->fieldExists('first_name')->setValue('Konstantin'); - - $webAssert->elementExists('xpath', 'descendant-or-self::form[1]')->submit(); - - if ($this->safePageWait(5000, 'document.getElementById("first") !== null')) { - $this->assertEquals('Firstname: Konstantin', $webAssert->elementExists('css', '#first')->getText()); - }; - } - - public function testBasicGetForm() - { - $this->getSession()->visit($this->pathTo('/basic_get_form.php')); - $webAssert = $this->getAssertSession(); - - $page = $this->getSession()->getPage(); - $this->assertEquals('Basic Get Form Page', $webAssert->elementExists('css', 'h1')->getText()); - - $search = $webAssert->fieldExists('q'); - $search->setValue('some#query'); - $page->pressButton('Find'); - - $div = $webAssert->elementExists('css', 'div'); - $this->assertEquals('some#query', $div->getText()); - } - - public function testAdvancedForm() - { - $this->getSession()->visit($this->pathTo('/advanced_form.html')); - $page = $this->getSession()->getPage(); - - $page->fillField('first_name', 'ever'); - $page->fillField('last_name', 'zet'); - - $page->pressButton('Register'); - - $this->assertContains('no file', $page->getContent()); - - $this->getSession()->visit($this->pathTo('/advanced_form.html')); - - $webAssert = $this->getAssertSession(); - $page = $this->getSession()->getPage(); - $this->assertEquals('ADvanced Form Page', $webAssert->elementExists('css', 'h1')->getText()); - - $firstname = $webAssert->fieldExists('first_name'); - $lastname = $webAssert->fieldExists('lastn'); - $email = $webAssert->fieldExists('Your email:'); - $select = $webAssert->fieldExists('select_number'); - $sex = $webAssert->fieldExists('sex'); - $maillist = $webAssert->fieldExists('mail_list'); - $agreement = $webAssert->fieldExists('agreement'); - $notes = $webAssert->fieldExists('notes'); - $about = $webAssert->fieldExists('about'); - - $this->assertEquals('Firstname', $firstname->getValue()); - $this->assertEquals('Lastname', $lastname->getValue()); - $this->assertEquals('your@email.com', $email->getValue()); - $this->assertEquals('20', $select->getValue()); - $this->assertEquals('w', $sex->getValue()); - $this->assertEquals('original notes', $notes->getValue()); - - $this->assertEquals('on', $maillist->getValue()); - $this->assertNull($agreement->getValue()); - - $this->assertTrue($maillist->isChecked()); - $this->assertFalse($agreement->isChecked()); - - $agreement->check(); - $this->assertTrue($agreement->isChecked()); - - $maillist->uncheck(); - $this->assertFalse($maillist->isChecked()); - - $select->selectOption('thirty'); - $this->assertEquals('30', $select->getValue()); - - $sex->selectOption('m'); - $this->assertEquals('m', $sex->getValue()); - - $notes->setValue('new notes'); - $this->assertEquals('new notes', $notes->getValue()); - - $about->attachFile($this->mapRemoteFilePath(__DIR__.'/../../web-fixtures/some_file.txt')); - - $button = $page->findButton('Register'); - $this->assertNotNull($button); - - $page->fillField('first_name', 'Foo "item"'); - $page->fillField('last_name', 'Bar'); - $page->fillField('Your email:', 'ever.zet@gmail.com'); - - $this->assertEquals('Foo "item"', $firstname->getValue()); - $this->assertEquals('Bar', $lastname->getValue()); - - $button->press(); - - if ($this->safePageWait(5000, 'document.getElementsByTagName("title") !== null')) { - $out = <<assertContains($out, $page->getContent()); - } - } - - public function testMultiInput() - { - $this->getSession()->visit($this->pathTo('/multi_input_form.html')); - $page = $this->getSession()->getPage(); - $webAssert = $this->getAssertSession(); - $this->assertEquals('Multi input Test', $webAssert->elementExists('css', 'h1')->getText()); - - $first = $webAssert->fieldExists('First'); - $second = $webAssert->fieldExists('Second'); - $third = $webAssert->fieldExists('Third'); - - $this->assertEquals('tag1', $first->getValue()); - $this->assertSame('tag2', $second->getValue()); - $this->assertEquals('tag1', $third->getValue()); - - $first->setValue('tag2'); - $this->assertEquals('tag2', $first->getValue()); - $this->assertSame('tag2', $second->getValue()); - $this->assertEquals('tag1', $third->getValue()); - - $second->setValue('one'); - - $this->assertEquals('tag2', $first->getValue()); - $this->assertSame('one', $second->getValue()); - - $third->setValue('tag3'); - - $this->assertEquals('tag2', $first->getValue()); - $this->assertSame('one', $second->getValue()); - $this->assertEquals('tag3', $third->getValue()); - - $button = $page->findButton('Register'); - $this->assertNotNull($button); - $button->press(); - - $space = ' '; - $out = <<assertContains($out, $page->getContent()); - } - - public function testAdvancedFormSecondSubmit() - { - $this->getSession()->visit($this->pathTo('/advanced_form.html')); - $page = $this->getSession()->getPage(); - - $button = $page->findButton('Login'); - $this->assertNotNull($button); - $button->press(); - - $toSearch = array( - "'agreement' = 'off',", - "'submit' = 'Login',", - 'no file', - ); - - $pageContent = $page->getContent(); - - foreach ($toSearch as $searchString) { - $this->assertContains($searchString, $pageContent); - } - } - - public function testSubmitEmptyTextarea() - { - $this->getSession()->visit($this->pathTo('/empty_textarea.html')); - $page = $this->getSession()->getPage(); - - $page->pressButton('Save'); - - $toSearch = array( - "'textarea' = '',", - "'submit' = 'Save',", - 'no file', - ); - - $pageContent = $page->getContent(); - - foreach ($toSearch as $searchString) { - $this->assertContains($searchString, $pageContent); - } - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Form/Html5Test.php b/vendor/behat/mink/driver-testsuite/tests/Form/Html5Test.php deleted file mode 100644 index b7f4716d3..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Form/Html5Test.php +++ /dev/null @@ -1,128 +0,0 @@ -getSession()->visit($this->pathTo('/html5_form.html')); - $page = $this->getSession()->getPage(); - $webAssert = $this->getAssertSession(); - - $firstName = $webAssert->fieldExists('first_name'); - $lastName = $webAssert->fieldExists('last_name'); - - $this->assertEquals('not set', $lastName->getValue()); - $firstName->setValue('John'); - $lastName->setValue('Doe'); - - $this->assertEquals('Doe', $lastName->getValue()); - - $page->pressButton('Submit in form'); - - if ($this->safePageWait(5000, 'document.getElementsByTagName("title") !== null')) { - $out = <<assertContains($out, $page->getContent()); - $this->assertNotContains('other_field', $page->getContent()); - } - } - - public function testHtml5FormRadioAttribute() - { - $this->getSession()->visit($this->pathTo('html5_radio.html')); - $page = $this->getSession()->getPage(); - - $radio = $this->findById('sex_f'); - $otherRadio = $this->findById('sex_invalid'); - - $this->assertEquals('f', $radio->getValue()); - $this->assertEquals('invalid', $otherRadio->getValue()); - - $radio->selectOption('m'); - - $this->assertEquals('m', $radio->getValue()); - $this->assertEquals('invalid', $otherRadio->getValue()); - - $page->pressButton('Submit in form'); - - $out = <<assertContains($out, $page->getContent()); - } - - public function testHtml5FormButtonAttribute() - { - $this->getSession()->visit($this->pathTo('/html5_form.html')); - $page = $this->getSession()->getPage(); - $webAssert = $this->getAssertSession(); - - $firstName = $webAssert->fieldExists('first_name'); - $lastName = $webAssert->fieldExists('last_name'); - - $firstName->setValue('John'); - $lastName->setValue('Doe'); - - $page->pressButton('Submit outside form'); - - if ($this->safePageWait(5000, 'document.getElementsByTagName("title") !== null')) { - $out = <<assertContains($out, $page->getContent()); - } - } - - public function testHtml5FormOutside() - { - $this->getSession()->visit($this->pathTo('/html5_form.html')); - $page = $this->getSession()->getPage(); - - $page->fillField('other_field', 'hello'); - - $page->pressButton('Submit separate form'); - - if ($this->safePageWait(5000, 'document.getElementsByTagName("title") !== null')) { - $out = <<assertContains($out, $page->getContent()); - $this->assertNotContains('first_name', $page->getContent()); - } - } - - public function testHtml5Types() - { - $this->getSession()->visit($this->pathTo('html5_types.html')); - $page = $this->getSession()->getPage(); - - $page->fillField('url', 'http://mink.behat.org/'); - $page->fillField('email', 'mink@example.org'); - $page->fillField('number', '6'); - $page->fillField('search', 'mink'); - $page->fillField('date', '2014-05-19'); - $page->fillField('color', '#ff00aa'); - - $page->pressButton('Submit'); - - $out = <<assertContains($out, $page->getContent()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Form/RadioTest.php b/vendor/behat/mink/driver-testsuite/tests/Form/RadioTest.php deleted file mode 100644 index b21ab7d61..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Form/RadioTest.php +++ /dev/null @@ -1,84 +0,0 @@ -getSession()->visit($this->pathTo('radio.html')); - } - - public function testIsChecked() - { - $option = $this->findById('first'); - $option2 = $this->findById('second'); - - $this->assertTrue($option->isChecked()); - $this->assertFalse($option2->isChecked()); - - $option2->selectOption('updated'); - - $this->assertFalse($option->isChecked()); - $this->assertTrue($option2->isChecked()); - } - - public function testSelectOption() - { - $option = $this->findById('first'); - - $this->assertEquals('set', $option->getValue()); - - $option->selectOption('updated'); - - $this->assertEquals('updated', $option->getValue()); - - $option->selectOption('set'); - - $this->assertEquals('set', $option->getValue()); - } - - public function testSetValue() - { - $option = $this->findById('first'); - - $this->assertEquals('set', $option->getValue()); - - $option->setValue('updated'); - - $this->assertEquals('updated', $option->getValue()); - $this->assertFalse($option->isChecked()); - } - - public function testSameNameInMultipleForms() - { - $option1 = $this->findById('reused_form1'); - $option2 = $this->findById('reused_form2'); - - $this->assertEquals('test2', $option1->getValue()); - $this->assertEquals('test3', $option2->getValue()); - - $option1->selectOption('test'); - - $this->assertEquals('test', $option1->getValue()); - $this->assertEquals('test3', $option2->getValue()); - } - - /** - * @see https://github.com/Behat/MinkSahiDriver/issues/32 - */ - public function testSetValueXPathEscaping() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/advanced_form.html')); - $page = $session->getPage(); - - $sex = $page->find('xpath', '//*[@name = "sex"]'."\n|\n".'//*[@id = "sex"]'); - $this->assertNotNull($sex, 'xpath with line ending works'); - - $sex->setValue('m'); - $this->assertEquals('m', $sex->getValue(), 'no double xpath escaping during radio button value change'); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Form/SelectTest.php b/vendor/behat/mink/driver-testsuite/tests/Form/SelectTest.php deleted file mode 100644 index f06d5f02f..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Form/SelectTest.php +++ /dev/null @@ -1,134 +0,0 @@ -getSession()->visit($this->pathTo('/multiselect_form.html')); - $webAssert = $this->getAssertSession(); - $page = $this->getSession()->getPage(); - $this->assertEquals('Multiselect Test', $webAssert->elementExists('css', 'h1')->getText()); - - $select = $webAssert->fieldExists('select_number'); - $multiSelect = $webAssert->fieldExists('select_multiple_numbers[]'); - $secondMultiSelect = $webAssert->fieldExists('select_multiple_values[]'); - - $this->assertEquals('20', $select->getValue()); - $this->assertSame(array(), $multiSelect->getValue()); - $this->assertSame(array('2', '3'), $secondMultiSelect->getValue()); - - $select->selectOption('thirty'); - $this->assertEquals('30', $select->getValue()); - - $multiSelect->selectOption('one', true); - - $this->assertSame(array('1'), $multiSelect->getValue()); - - $multiSelect->selectOption('three', true); - - $this->assertEquals(array('1', '3'), $multiSelect->getValue()); - - $secondMultiSelect->selectOption('two'); - $this->assertSame(array('2'), $secondMultiSelect->getValue()); - - $button = $page->findButton('Register'); - $this->assertNotNull($button); - $button->press(); - - $space = ' '; - $out = <<assertContains($out, $page->getContent()); - } - - /** - * @dataProvider testElementSelectedStateCheckDataProvider - */ - public function testElementSelectedStateCheck($selectName, $optionValue, $optionText) - { - $session = $this->getSession(); - $webAssert = $this->getAssertSession(); - $session->visit($this->pathTo('/multiselect_form.html')); - $select = $webAssert->fieldExists($selectName); - - $option = $webAssert->elementExists('named', array('option', $optionValue)); - - $this->assertFalse($option->isSelected()); - $select->selectOption($optionText); - $this->assertTrue($option->isSelected()); - } - - public function testElementSelectedStateCheckDataProvider() - { - return array( - array('select_number', '30', 'thirty'), - array('select_multiple_numbers[]', '2', 'two'), - ); - } - - public function testSetValueSingleSelect() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/multiselect_form.html')); - $select = $this->getAssertSession()->fieldExists('select_number'); - - $select->setValue('10'); - $this->assertEquals('10', $select->getValue()); - } - - public function testSetValueMultiSelect() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/multiselect_form.html')); - $select = $this->getAssertSession()->fieldExists('select_multiple_values[]'); - - $select->setValue(array('1', '2')); - $this->assertEquals(array('1', '2'), $select->getValue()); - } - - /** - * @see https://github.com/Behat/Mink/issues/193 - */ - public function testOptionWithoutValue() - { - $session = $this->getSession(); - $session->visit($this->pathTo('/issue193.html')); - - $session->getPage()->selectFieldOption('options-without-values', 'Two'); - $this->assertEquals('Two', $this->findById('options-without-values')->getValue()); - - $this->assertTrue($this->findById('two')->isSelected()); - $this->assertFalse($this->findById('one')->isSelected()); - - $session->getPage()->selectFieldOption('options-with-values', 'two'); - $this->assertEquals('two', $this->findById('options-with-values')->getValue()); - } - - /** - * @see https://github.com/Behat/Mink/issues/131 - */ - public function testAccentuatedOption() - { - $this->getSession()->visit($this->pathTo('/issue131.html')); - $page = $this->getSession()->getPage(); - - $page->selectFieldOption('foobar', 'Gimme some accentués characters'); - - $this->assertEquals('1', $page->findField('foobar')->getValue()); - } -} diff --git a/vendor/behat/mink/driver-testsuite/tests/Js/ChangeEventTest.php b/vendor/behat/mink/driver-testsuite/tests/Js/ChangeEventTest.php deleted file mode 100644 index 4c8a30fcf..000000000 --- a/vendor/behat/mink/driver-testsuite/tests/Js/ChangeEventTest.php +++ /dev/null @@ -1,155 +0,0 @@ - in a - - - - - - - - - - - - - - - - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/advanced_form_post.php b/vendor/behat/mink/driver-testsuite/web-fixtures/advanced_form_post.php deleted file mode 100644 index 755806dc6..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/advanced_form_post.php +++ /dev/null @@ -1,26 +0,0 @@ - - - - Advanced form save - - - -', '', var_export($_POST, true)) . "\n"; -if (isset($_FILES['about']) && file_exists($_FILES['about']['tmp_name'])) { - echo $_FILES['about']['name'] . "\n"; - echo file_get_contents($_FILES['about']['tmp_name']); -} else { - echo "no file"; -} -?> - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/aria_roles.html b/vendor/behat/mink/driver-testsuite/web-fixtures/aria_roles.html deleted file mode 100644 index 7074e8536..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/aria_roles.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - ARIA roles test - - - - This page tests selected ARIA roles
    - (see http://www.w3.org/TR/wai-aria/) - -
    Toggle
    - - - - - - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_auth.php b/vendor/behat/mink/driver-testsuite/web-fixtures/basic_auth.php deleted file mode 100644 index 9620a0e51..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_auth.php +++ /dev/null @@ -1,12 +0,0 @@ - - - - Basic Form - - - -

    Basic Form Page

    - -
    - - - - - - - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_form_post.php b/vendor/behat/mink/driver-testsuite/web-fixtures/basic_form_post.php deleted file mode 100644 index 8a5e340ef..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_form_post.php +++ /dev/null @@ -1,13 +0,0 @@ - - - - Basic Form Saving - - - -

    Anket for

    - - Firstname: - Lastname: - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_get_form.php b/vendor/behat/mink/driver-testsuite/web-fixtures/basic_get_form.php deleted file mode 100644 index a0b35166e..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/basic_get_form.php +++ /dev/null @@ -1,20 +0,0 @@ - - - - Basic Get Form - - - -

    Basic Get Form Page

    - -
    - -
    - -
    - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page1.php b/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page1.php deleted file mode 100644 index 7f128cae8..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page1.php +++ /dev/null @@ -1,21 +0,0 @@ - - - - - Basic Form - - - - Basic Page With Cookie Set from Server Side - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page2.php b/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page2.php deleted file mode 100644 index 22bcd1be1..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page2.php +++ /dev/null @@ -1,10 +0,0 @@ - - - - Basic Form - - - - Previous cookie: - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page3.php b/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page3.php deleted file mode 100644 index caa28bcc1..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/cookie_page3.php +++ /dev/null @@ -1,16 +0,0 @@ - - - - - HttpOnly Cookie Test - - - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/css_mouse_events.html b/vendor/behat/mink/driver-testsuite/web-fixtures/css_mouse_events.html deleted file mode 100644 index 750ca54ec..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/css_mouse_events.html +++ /dev/null @@ -1,36 +0,0 @@ - - - - CSS Mouse Events Testing - - - - - - -
    -
    reset
    -
    mouse action
    -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/element_change_detector.html b/vendor/behat/mink/driver-testsuite/web-fixtures/element_change_detector.html deleted file mode 100644 index c309baefa..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/element_change_detector.html +++ /dev/null @@ -1,65 +0,0 @@ - - - - ADvanced Form - - - - -

    ADvanced Form Page

    - -
    - - - - - - - - - - - - - - -
    - -
      -
    • for easy element location
    • -
    - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/empty_textarea.html b/vendor/behat/mink/driver-testsuite/web-fixtures/empty_textarea.html deleted file mode 100644 index f0779ee85..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/empty_textarea.html +++ /dev/null @@ -1,14 +0,0 @@ - - - - Empty textarea submission - - - -

    Empty textarea submission

    -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/form_without_button.html b/vendor/behat/mink/driver-testsuite/web-fixtures/form_without_button.html deleted file mode 100644 index 806302636..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/form_without_button.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - - Form submission without button test - - -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/headers.php b/vendor/behat/mink/driver-testsuite/web-fixtures/headers.php deleted file mode 100644 index 25d9b90ec..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/headers.php +++ /dev/null @@ -1,10 +0,0 @@ - - - - Headers page - - - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_form.html b/vendor/behat/mink/driver-testsuite/web-fixtures/html5_form.html deleted file mode 100644 index 90703531f..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_form.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - HTML5 form attribute test - - -
    - - - - -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_radio.html b/vendor/behat/mink/driver-testsuite/web-fixtures/html5_radio.html deleted file mode 100644 index fd54c2dbf..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_radio.html +++ /dev/null @@ -1,16 +0,0 @@ - - - - - HTML5 form attribute test - - -
    - - - -
    - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_types.html b/vendor/behat/mink/driver-testsuite/web-fixtures/html5_types.html deleted file mode 100644 index bd46cfa6f..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/html5_types.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - HTML5 form attribute test - - -
    - - - - - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/html_decoding.html b/vendor/behat/mink/driver-testsuite/web-fixtures/html_decoding.html deleted file mode 100644 index 341f22691..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/html_decoding.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - HTML Decoding Test - - -
    - some text - -
    - - - -
    -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/iframe.html b/vendor/behat/mink/driver-testsuite/web-fixtures/iframe.html deleted file mode 100644 index c54797fa7..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/iframe.html +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - -
    - Main window div text -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/iframe_inner.html b/vendor/behat/mink/driver-testsuite/web-fixtures/iframe_inner.html deleted file mode 100644 index 512f058e2..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/iframe_inner.html +++ /dev/null @@ -1,10 +0,0 @@ - - - - -
    - iFrame div text -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/index.html b/vendor/behat/mink/driver-testsuite/web-fixtures/index.html deleted file mode 100644 index cc8c821ce..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/index.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - Index page - - - -

    Extremely useless page

    -
    - Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. - -
    - An empty tag should be rendered with both open and close tags. -
    - -
    - some
    very -
    -interesting text -
    - -
    - - - - -
    - -
    -
    el1
    -
    el2
    - -
    - -
    el4
    - -
    - -
    -
    - -
    -
    -
    - -
    - -
    -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue130.php b/vendor/behat/mink/driver-testsuite/web-fixtures/issue130.php deleted file mode 100644 index 201d9826e..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue130.php +++ /dev/null @@ -1,11 +0,0 @@ - - - - Go to 2'; - } else { - echo ''.$_SERVER['HTTP_REFERER'].''; - } - ?> - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue131.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue131.html deleted file mode 100644 index fa3427a98..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue131.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - Issue 131 - - - -

    There is a non breaking space

    -
    Some accentués characters
    -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue140.php b/vendor/behat/mink/driver-testsuite/web-fixtures/issue140.php deleted file mode 100644 index 04a4cafb7..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue140.php +++ /dev/null @@ -1,16 +0,0 @@ - - - - -
    - - -
    - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue178.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue178.html deleted file mode 100644 index 3efc74324..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue178.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - - Index page - - - -
    -
    - -
    -
    - -
    - - - \ No newline at end of file diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue193.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue193.html deleted file mode 100644 index e722a4303..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue193.html +++ /dev/null @@ -1,26 +0,0 @@ - - - - Index page - - - - -
    - - - -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue211.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue211.html deleted file mode 100644 index bb977ec21..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue211.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - Index page - - - - -
    -

    - - -

    -

    - - -

    - - -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue212.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue212.html deleted file mode 100644 index 24ae62f06..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue212.html +++ /dev/null @@ -1,9 +0,0 @@ - - - -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue215.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue215.html deleted file mode 100644 index adff3fbba..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue215.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - - Index page - - - -
    - -
    - - - \ No newline at end of file diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue225.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue225.html deleted file mode 100644 index 13214631f..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue225.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - Index page - - - - - - - -
    - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/issue255.html b/vendor/behat/mink/driver-testsuite/web-fixtures/issue255.html deleted file mode 100644 index d56a4279a..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/issue255.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - Issue 255 - - - - -
    - - - - -

    -

    -
    - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-1.6.2-min.js b/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-1.6.2-min.js deleted file mode 100644 index 8cdc80eb8..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-1.6.2-min.js +++ /dev/null @@ -1,18 +0,0 @@ -/*! - * jQuery JavaScript Library v1.6.2 - * http://jquery.com/ - * - * Copyright 2011, John Resig - * Dual licensed under the MIT or GPL Version 2 licenses. - * http://jquery.org/license - * - * Includes Sizzle.js - * http://sizzlejs.com/ - * Copyright 2011, The Dojo Foundation - * Released under the MIT, BSD, and GPL Licenses. - * - * Date: Thu Jun 30 14:16:56 2011 -0400 - */ -(function(a,b){function cv(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cs(a){if(!cg[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ch||(ch=c.createElement("iframe"),ch.frameBorder=ch.width=ch.height=0),b.appendChild(ch);if(!ci||!ch.createElement)ci=(ch.contentWindow||ch.contentDocument).document,ci.write((c.compatMode==="CSS1Compat"?"":"")+""),ci.close();d=ci.createElement(a),ci.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ch)}cg[a]=e}return cg[a]}function cr(a,b){var c={};f.each(cm.concat.apply([],cm.slice(0,b)),function(){c[this]=a});return c}function cq(){cn=b}function cp(){setTimeout(cq,0);return cn=f.now()}function cf(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ce(){try{return new a.XMLHttpRequest}catch(b){}}function b$(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bx(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function bm(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(be,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bl(a){f.nodeName(a,"input")?bk(a):"getElementsByTagName"in a&&f.grep(a.getElementsByTagName("input"),bk)}function bk(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bj(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bi(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bh(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i=0===c})}function V(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function N(a,b){return(a&&a!=="*"?a+".":"")+b.replace(z,"`").replace(A,"&")}function M(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;ic)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function K(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function E(){return!0}function D(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(j,"$1-$2").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(g){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function J(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(J,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=/-([a-z])/ig,x=function(a,b){return b.toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6.2",length:0,size:function(){return this.length},toArray:function(){return F.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?E.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),A.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(F.apply(this,arguments),"slice",F.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:E,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j0)return;A.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!A){A=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1;var c;for(c in a);return c===b||D.call(a,c)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(b,c,d){a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b)),d=c.documentElement,(!d||!d.nodeName||d.nodeName==="parsererror")&&e.error("Invalid XML: "+b);return c},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,x)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c
    a",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55$/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.firstChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0},m&&f.extend(p,{position:"absolute",left:-1e3,top:-1e3});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="
    ",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="
    t
    ",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0),o.innerHTML="",n.removeChild(o);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([a-z])([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g=f.expando,h=typeof c=="string",i,j=a.nodeType,k=j?f.cache:a,l=j?a[f.expando]:a[f.expando]&&f.expando;if((!l||e&&l&&!k[l][g])&&h&&d===b)return;l||(j?a[f.expando]=l=++f.uuid:l=f.expando),k[l]||(k[l]={},j||(k[l].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?k[l][g]=f.extend(k[l][g],c):k[l]=f.extend(k[l],c);i=k[l],e&&(i[g]||(i[g]={}),i=i[g]),d!==b&&(i[f.camelCase(c)]=d);if(c==="events"&&!i[c])return i[g]&&i[g].events;return h?i[f.camelCase(c)]||i[c]:i}},removeData:function(b,c,d){if(!!f.acceptData(b)){var e=f.expando,g=b.nodeType,h=g?f.cache:b,i=g?b[f.expando]:f.expando;if(!h[i])return;if(c){var j=d?h[i][e]:h[i];if(j){delete j[c];if(!l(j))return}}if(d){delete h[i][e];if(!l(h[i]))return}var k=h[i][e];f.support.deleteExpando||h!=a?delete h[i]:h[i]=null,k?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=k):g&&(f.support.deleteExpando?delete b[f.expando]:b.removeAttribute?b.removeAttribute(f.expando):b[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;d=e.value;return typeof d=="string"?d.replace(p,""):d==null?"":d}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c=a.selectedIndex,d=[],e=a.options,g=a.type==="select-one";if(c<0)return null;for(var h=g?c:0,i=g?c+1:e.length;h=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);var h,i,j=g!==1||!f.isXMLDoc(a);j&&(c=f.attrFix[c]||c,i=f.attrHooks[c],i||(t.test(c)?i=w:v&&c!=="className"&&(f.nodeName(a,"form")||u.test(c))&&(i=v)));if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j&&(h=i.get(a,c))!==null)return h;h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.support.getSetAttribute?a.removeAttribute(b):(f.attr(a,b,""),a.removeAttributeNode(a.getAttributeNode(b))),t.test(b)&&(c=f.propFix[b]||b)in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;a.setAttribute("type",b),c&&(a.value=c);return b}}},tabIndex:{get:function(a){var c=a.getAttributeNode("tabIndex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}},value:{get:function(a,b){if(v&&f.nodeName(a,"button"))return v.get(a,b);return b in a?a.value:null},set:function(a,b,c){if(v&&f.nodeName(a,"button"))return v.set(a,b,c);a.value=b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);i&&(c=f.propFix[c]||c,h=f.propHooks[c]);return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==b?g:a[c]},propHooks:{}}),w={get:function(a,c){return f.prop(a,c)?c.toLowerCase():b},set:function(a,b,c){var d;b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase()));return c}},f.support.getSetAttribute||(f.attrFix=f.propFix,v=f.attrHooks.name=f.attrHooks.title=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,c){var d=a.getAttributeNode(c);if(d){d.nodeValue=b;return b}}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var x=/\.(.*)$/,y=/^(?:textarea|input|select)$/i,z=/\./g,A=/ /g,B=/[^\w\s.|`]/g,C=function(a){return a.replace(B,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=D;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=D);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),C).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i. -shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem)});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d!=null?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},J=function(c){var d=c.target,e,g;if(!!y.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=I(d),(c.type!=="focusout"||d.type!=="radio")&&f._data(d,"_change_data",g);if(e===b||g===e)return;if(e!=null||g)c.type="change",c.liveFired=b,f.event.trigger(c,arguments[1],d)}};f.event.special.change={filters:{focusout:J,beforedeactivate:J,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&J.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&J.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",I(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in H)f.event.add(this,c+".specialChange",H[c]);return y.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return y.test(this.nodeName)}},H=f.event.special.change.filters,H.focus=H.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return bc[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

    ";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="
    ";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g0)for(h=g;h0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=T.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a||typeof a=="string")return f.inArray(this[0],a?f(a):this.parent().children());return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(V(c[0])||V(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=S.call(arguments);O.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!U[a]?f.unique(e):e,(this.length>1||Q.test(d))&&P.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var X=/ jQuery\d+="(?:\d+|null)"/g,Y=/^\s+/,Z=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,$=/<([\w:]+)/,_=/",""],legend:[1,"
    ","
    "],thead:[1,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],col:[2,"","
    "],area:[1,"",""],_default:[0,"",""]};bf.optgroup=bf.option,bf.tbody=bf.tfoot=bf.colgroup=bf.caption=bf.thead,bf.th=bf.td,f.support.htmlSerialize||(bf._default=[1,"div
    ","
    "]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){f(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f(arguments[0]).toArray());return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(X,""):null;if(typeof a=="string"&&!bb.test(a)&&(f.support.leadingWhitespace||!Y.test(a))&&!bf[($.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Z,"<$1>");try{for(var c=0,d=this.length;c1&&l0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j -)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d=a.cloneNode(!0),e,g,h;if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bi(a,d),e=bj(a),g=bj(d);for(h=0;e[h];++h)bi(e[h],g[h])}if(b){bh(a,d);if(c){e=bj(a),g=bj(d);for(h=0;e[h];++h)bh(e[h],g[h])}}e=g=null;return d},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);var h=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!ba.test(k))k=b.createTextNode(k);else{k=k.replace(Z,"<$1>");var l=($.exec(k)||["",""])[1].toLowerCase(),m=bf[l]||bf._default,n=m[0],o=b.createElement("div");o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=_.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]===""&&!p?o.childNodes:[];for(i=q.length-1;i>=0;--i)f.nodeName(q[i],"tbody")&&!q[i].childNodes.length&&q[i].parentNode.removeChild(q[i])}!f.support.leadingWhitespace&&Y.test(k)&&o.insertBefore(b.createTextNode(Y.exec(k)[0]),o.firstChild),k=o.childNodes}var r;if(!f.support.appendChecked)if(k[0]&&typeof (r=k.length)=="number")for(i=0;i=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bo.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle;c.zoom=1;var e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.filter=bn.test(g)?g.replace(bn,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bx(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(by=function(a,c){var d,e,g;c=c.replace(bp,"-$1").toLowerCase();if(!(e=a.ownerDocument.defaultView))return b;if(g=e.getComputedStyle(a,null))d=g.getPropertyValue(c),d===""&&!f.contains(a.ownerDocument.documentElement,a)&&(d=f.style(a,c));return d}),c.documentElement.currentStyle&&(bz=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bq.test(d)&&br.test(d)&&(c=f.left,e&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":d||0,d=f.pixelLeft+"px",f.left=c,e&&(a.runtimeStyle.left=e));return d===""?"auto":d}),bx=by||bz,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bB=/%20/g,bC=/\[\]$/,bD=/\r?\n/g,bE=/#.*$/,bF=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bG=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bH=/^(?:about|app|app\-storage|.+\-extension|file|widget):$/,bI=/^(?:GET|HEAD)$/,bJ=/^\/\//,bK=/\?/,bL=/)<[^<]*)*<\/script>/gi,bM=/^(?:select|textarea)/i,bN=/\s+/,bO=/([?&])_=[^&]*/,bP=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bQ=f.fn.load,bR={},bS={},bT,bU;try{bT=e.href}catch(bV){bT=c.createElement("a"),bT.href="",bT=bT.href}bU=bP.exec(bT.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bQ)return bQ.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("
    ").append(c.replace(bL,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bM.test(this.nodeName)||bG.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bD,"\r\n")}}):{name:b.name,value:c.replace(bD,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.bind(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?f.extend(!0,a,f.ajaxSettings,b):(b=a,a=f.extend(!0,f.ajaxSettings,b));for(var c in{context:1,url:1})c in b?a[c]=b[c]:c in f.ajaxSettings&&(a[c]=f.ajaxSettings[c]);return a},ajaxSettings:{url:bT,isLocal:bH.test(bU[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":"*/*"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML}},ajaxPrefilter:bW(bR),ajaxTransport:bW(bS),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a?4:0;var o,r,u,w=l?bZ(d,v,l):b,x,y;if(a>=200&&a<300||a===304){if(d.ifModified){if(x=v.getResponseHeader("Last-Modified"))f.lastModified[k]=x;if(y=v.getResponseHeader("Etag"))f.etag[k]=y}if(a===304)c="notmodified",o=!0;else try{r=b$(d,w),c="success",o=!0}catch(z){c="parsererror",u=z}}else{u=c;if(!c||a)c="error",a<0&&(a=0)}v.status=a,v.statusText=c,o?h.resolveWith(e,[r,c,v]):h.rejectWith(e,[v,c,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,c]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f._Deferred(),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bF.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.done,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bE,"").replace(bJ,bU[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bN),d.crossDomain==null&&(r=bP.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bU[1]&&r[2]==bU[2]&&(r[3]||(r[1]==="http:"?80:443))==(bU[3]||(bU[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bX(bR,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bI.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bK.test(d.url)?"&":"?")+d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bO,"$1_="+x);d.url=y+(y===d.url?(bK.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", */*; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=bX(bS,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){status<2?w(-1,z):f.error(z)}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)bY(g,a[g],c,e);return d.join("&").replace(bB,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var b_=f.now(),ca=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+b_++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(ca.test(b.url)||e&&ca.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(ca,l),b.url===j&&(e&&(k=k.replace(ca,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var cb=a.ActiveXObject?function(){for(var a in cd)cd[a](0,1)}:!1,cc=0,cd;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ce()||cf()}:ce,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,cb&&delete cd[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cc,cb&&(cd||(cd={},f(a).unload(cb)),cd[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cg={},ch,ci,cj=/^(?:toggle|show|hide)$/,ck=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cl,cm=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cn,co=a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||a.oRequestAnimationFrame;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cr("show",3),a,b,c);for(var g=0,h=this.length;g=e.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),e.animatedProperties[this.prop]=!0;for(g in e.animatedProperties)e.animatedProperties[g]!==!0&&(c=!1);if(c){e.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){d.style["overflow"+b]=e.overflow[a]}),e.hide&&f(d).hide();if(e.hide||e.show)for(var i in e.animatedProperties)f.style(d,i,e.orig[i]);e.complete.call(d)}return!1}e.duration==Infinity?this.now=b:(h=b-this.startTime,this.state=h/e.duration,this.pos=f.easing[e.animatedProperties[this.prop]](this.state,h,0,1,e.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){for(var a=f.timers,b=0;b
    ";f.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"}),b.innerHTML=j,a.insertBefore(b,a.firstChild),d=b.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,this.doesNotAddBorder=e.offsetTop!==5,this.doesAddBorderForTableAndCells=h.offsetTop===5,e.style.position="fixed",e.style.top="20px",this.supportsFixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",this.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i,a.removeChild(b),f.offset.initialize=f.noop},bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;f.offset.initialize(),f.offset.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0);return{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=cu.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!cu.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cv(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cv(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){var a=this[0];return a&&a.style?parseFloat(f.css(a,d,"padding")):null},f.fn["outer"+c]=function(a){var b=this[0];return b&&b.style?parseFloat(f.css(b,d,a?"margin":"border")):null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c];return e.document.compatMode==="CSS1Compat"&&g||e.document.body["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var h=f.css(e,d),i=parseFloat(h);return f.isNaN(i)?h:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window); \ No newline at end of file diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-ui-1.8.14.custom.min.js b/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-ui-1.8.14.custom.min.js deleted file mode 100644 index 1764e1129..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/js/jquery-ui-1.8.14.custom.min.js +++ /dev/null @@ -1,127 +0,0 @@ -/*! - * jQuery UI 1.8.14 - * - * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT or GPL Version 2 licenses. - * http://jquery.org/license - * - * http://docs.jquery.com/UI - */ -(function(c,j){function k(a,b){var d=a.nodeName.toLowerCase();if("area"===d){b=a.parentNode;d=b.name;if(!a.href||!d||b.nodeName.toLowerCase()!=="map")return false;a=c("img[usemap=#"+d+"]")[0];return!!a&&l(a)}return(/input|select|textarea|button|object/.test(d)?!a.disabled:"a"==d?a.href||b:b)&&l(a)}function l(a){return!c(a).parents().andSelf().filter(function(){return c.curCSS(this,"visibility")==="hidden"||c.expr.filters.hidden(this)}).length}c.ui=c.ui||{};if(!c.ui.version){c.extend(c.ui,{version:"1.8.14", -keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}});c.fn.extend({_focus:c.fn.focus,focus:function(a,b){return typeof a==="number"?this.each(function(){var d=this;setTimeout(function(){c(d).focus(); -b&&b.call(d)},a)}):this._focus.apply(this,arguments)},scrollParent:function(){var a;a=c.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(c.curCSS(this,"position",1))&&/(auto|scroll)/.test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(c.curCSS(this,"overflow",1)+c.curCSS(this, -"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0);return/fixed/.test(this.css("position"))||!a.length?c(document):a},zIndex:function(a){if(a!==j)return this.css("zIndex",a);if(this.length){a=c(this[0]);for(var b;a.length&&a[0]!==document;){b=a.css("position");if(b==="absolute"||b==="relative"||b==="fixed"){b=parseInt(a.css("zIndex"),10);if(!isNaN(b)&&b!==0)return b}a=a.parent()}}return 0},disableSelection:function(){return this.bind((c.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection", -function(a){a.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}});c.each(["Width","Height"],function(a,b){function d(f,g,m,n){c.each(e,function(){g-=parseFloat(c.curCSS(f,"padding"+this,true))||0;if(m)g-=parseFloat(c.curCSS(f,"border"+this+"Width",true))||0;if(n)g-=parseFloat(c.curCSS(f,"margin"+this,true))||0});return g}var e=b==="Width"?["Left","Right"]:["Top","Bottom"],h=b.toLowerCase(),i={innerWidth:c.fn.innerWidth,innerHeight:c.fn.innerHeight,outerWidth:c.fn.outerWidth, -outerHeight:c.fn.outerHeight};c.fn["inner"+b]=function(f){if(f===j)return i["inner"+b].call(this);return this.each(function(){c(this).css(h,d(this,f)+"px")})};c.fn["outer"+b]=function(f,g){if(typeof f!=="number")return i["outer"+b].call(this,f);return this.each(function(){c(this).css(h,d(this,f,true,g)+"px")})}});c.extend(c.expr[":"],{data:function(a,b,d){return!!c.data(a,d[3])},focusable:function(a){return k(a,!isNaN(c.attr(a,"tabindex")))},tabbable:function(a){var b=c.attr(a,"tabindex"),d=isNaN(b); -return(d||b>=0)&&k(a,!d)}});c(function(){var a=document.body,b=a.appendChild(b=document.createElement("div"));c.extend(b.style,{minHeight:"100px",height:"auto",padding:0,borderWidth:0});c.support.minHeight=b.offsetHeight===100;c.support.selectstart="onselectstart"in b;a.removeChild(b).style.display="none"});c.extend(c.ui,{plugin:{add:function(a,b,d){a=c.ui[a].prototype;for(var e in d){a.plugins[e]=a.plugins[e]||[];a.plugins[e].push([b,d[e]])}},call:function(a,b,d){if((b=a.plugins[b])&&a.element[0].parentNode)for(var e= -0;e0)return true;a[b]=1;d=a[b]>0;a[b]=0;return d},isOverAxis:function(a,b,d){return a>b&&a=9)&&!a.button)return this._mouseUp(a);if(this._mouseStarted){this._mouseDrag(a);return a.preventDefault()}if(this._mouseDistanceMet(a)&&this._mouseDelayMet(a))(this._mouseStarted=this._mouseStart(this._mouseDownEvent,a)!==false)?this._mouseDrag(a):this._mouseUp(a);return!this._mouseStarted},_mouseUp:function(a){b(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted= -false;a.target==this._mouseDownEvent.target&&b.data(a.target,this.widgetName+".preventClickEvent",true);this._mouseStop(a)}return false},_mouseDistanceMet:function(a){return Math.max(Math.abs(this._mouseDownEvent.pageX-a.pageX),Math.abs(this._mouseDownEvent.pageY-a.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return true}})})(jQuery); -;/* - * jQuery UI Draggable 1.8.14 - * - * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT or GPL Version 2 licenses. - * http://jquery.org/license - * - * http://docs.jquery.com/UI/Draggables - * - * Depends: - * jquery.ui.core.js - * jquery.ui.mouse.js - * jquery.ui.widget.js - */ -(function(d){d.widget("ui.draggable",d.ui.mouse,{widgetEventPrefix:"drag",options:{addClasses:true,appendTo:"parent",axis:false,connectToSortable:false,containment:false,cursor:"auto",cursorAt:false,grid:false,handle:false,helper:"original",iframeFix:false,opacity:false,refreshPositions:false,revert:false,revertDuration:500,scope:"default",scroll:true,scrollSensitivity:20,scrollSpeed:20,snap:false,snapMode:"both",snapTolerance:20,stack:false,zIndex:false},_create:function(){if(this.options.helper== -"original"&&!/^(?:r|a|f)/.test(this.element.css("position")))this.element[0].style.position="relative";this.options.addClasses&&this.element.addClass("ui-draggable");this.options.disabled&&this.element.addClass("ui-draggable-disabled");this._mouseInit()},destroy:function(){if(this.element.data("draggable")){this.element.removeData("draggable").unbind(".draggable").removeClass("ui-draggable ui-draggable-dragging ui-draggable-disabled");this._mouseDestroy();return this}},_mouseCapture:function(a){var b= -this.options;if(this.helper||b.disabled||d(a.target).is(".ui-resizable-handle"))return false;this.handle=this._getHandle(a);if(!this.handle)return false;d(b.iframeFix===true?"iframe":b.iframeFix).each(function(){d('
    ').css({width:this.offsetWidth+"px",height:this.offsetHeight+"px",position:"absolute",opacity:"0.001",zIndex:1E3}).css(d(this).offset()).appendTo("body")});return true},_mouseStart:function(a){var b=this.options;this.helper= -this._createHelper(a);this._cacheHelperProportions();if(d.ui.ddmanager)d.ui.ddmanager.current=this;this._cacheMargins();this.cssPosition=this.helper.css("position");this.scrollParent=this.helper.scrollParent();this.offset=this.positionAbs=this.element.offset();this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left};d.extend(this.offset,{click:{left:a.pageX-this.offset.left,top:a.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}); -this.originalPosition=this.position=this._generatePosition(a);this.originalPageX=a.pageX;this.originalPageY=a.pageY;b.cursorAt&&this._adjustOffsetFromHelper(b.cursorAt);b.containment&&this._setContainment();if(this._trigger("start",a)===false){this._clear();return false}this._cacheHelperProportions();d.ui.ddmanager&&!b.dropBehaviour&&d.ui.ddmanager.prepareOffsets(this,a);this.helper.addClass("ui-draggable-dragging");this._mouseDrag(a,true);d.ui.ddmanager&&d.ui.ddmanager.dragStart(this,a);return true}, -_mouseDrag:function(a,b){this.position=this._generatePosition(a);this.positionAbs=this._convertPositionTo("absolute");if(!b){b=this._uiHash();if(this._trigger("drag",a,b)===false){this._mouseUp({});return false}this.position=b.position}if(!this.options.axis||this.options.axis!="y")this.helper[0].style.left=this.position.left+"px";if(!this.options.axis||this.options.axis!="x")this.helper[0].style.top=this.position.top+"px";d.ui.ddmanager&&d.ui.ddmanager.drag(this,a);return false},_mouseStop:function(a){var b= -false;if(d.ui.ddmanager&&!this.options.dropBehaviour)b=d.ui.ddmanager.drop(this,a);if(this.dropped){b=this.dropped;this.dropped=false}if((!this.element[0]||!this.element[0].parentNode)&&this.options.helper=="original")return false;if(this.options.revert=="invalid"&&!b||this.options.revert=="valid"&&b||this.options.revert===true||d.isFunction(this.options.revert)&&this.options.revert.call(this.element,b)){var c=this;d(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration, -10),function(){c._trigger("stop",a)!==false&&c._clear()})}else this._trigger("stop",a)!==false&&this._clear();return false},_mouseUp:function(a){this.options.iframeFix===true&&d("div.ui-draggable-iframeFix").each(function(){this.parentNode.removeChild(this)});d.ui.ddmanager&&d.ui.ddmanager.dragStop(this,a);return d.ui.mouse.prototype._mouseUp.call(this,a)},cancel:function(){this.helper.is(".ui-draggable-dragging")?this._mouseUp({}):this._clear();return this},_getHandle:function(a){var b=!this.options.handle|| -!d(this.options.handle,this.element).length?true:false;d(this.options.handle,this.element).find("*").andSelf().each(function(){if(this==a.target)b=true});return b},_createHelper:function(a){var b=this.options;a=d.isFunction(b.helper)?d(b.helper.apply(this.element[0],[a])):b.helper=="clone"?this.element.clone().removeAttr("id"):this.element;a.parents("body").length||a.appendTo(b.appendTo=="parent"?this.element[0].parentNode:b.appendTo);a[0]!=this.element[0]&&!/(fixed|absolute)/.test(a.css("position"))&& -a.css("position","absolute");return a},_adjustOffsetFromHelper:function(a){if(typeof a=="string")a=a.split(" ");if(d.isArray(a))a={left:+a[0],top:+a[1]||0};if("left"in a)this.offset.click.left=a.left+this.margins.left;if("right"in a)this.offset.click.left=this.helperProportions.width-a.right+this.margins.left;if("top"in a)this.offset.click.top=a.top+this.margins.top;if("bottom"in a)this.offset.click.top=this.helperProportions.height-a.bottom+this.margins.top},_getParentOffset:function(){this.offsetParent= -this.helper.offsetParent();var a=this.offsetParent.offset();if(this.cssPosition=="absolute"&&this.scrollParent[0]!=document&&d.ui.contains(this.scrollParent[0],this.offsetParent[0])){a.left+=this.scrollParent.scrollLeft();a.top+=this.scrollParent.scrollTop()}if(this.offsetParent[0]==document.body||this.offsetParent[0].tagName&&this.offsetParent[0].tagName.toLowerCase()=="html"&&d.browser.msie)a={top:0,left:0};return{top:a.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:a.left+(parseInt(this.offsetParent.css("borderLeftWidth"), -10)||0)}},_getRelativeOffset:function(){if(this.cssPosition=="relative"){var a=this.element.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}else return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"), -10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var a=this.options;if(a.containment=="parent")a.containment=this.helper[0].parentNode;if(a.containment=="document"||a.containment=="window")this.containment=[a.containment=="document"?0:d(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,a.containment=="document"?0:d(window).scrollTop()-this.offset.relative.top-this.offset.parent.top, -(a.containment=="document"?0:d(window).scrollLeft())+d(a.containment=="document"?document:window).width()-this.helperProportions.width-this.margins.left,(a.containment=="document"?0:d(window).scrollTop())+(d(a.containment=="document"?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top];if(!/^(document|window|parent)$/.test(a.containment)&&a.containment.constructor!=Array){a=d(a.containment);var b=a[0];if(b){a.offset();var c=d(b).css("overflow")!= -"hidden";this.containment=[(parseInt(d(b).css("borderLeftWidth"),10)||0)+(parseInt(d(b).css("paddingLeft"),10)||0),(parseInt(d(b).css("borderTopWidth"),10)||0)+(parseInt(d(b).css("paddingTop"),10)||0),(c?Math.max(b.scrollWidth,b.offsetWidth):b.offsetWidth)-(parseInt(d(b).css("borderLeftWidth"),10)||0)-(parseInt(d(b).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(c?Math.max(b.scrollHeight,b.offsetHeight):b.offsetHeight)-(parseInt(d(b).css("borderTopWidth"), -10)||0)-(parseInt(d(b).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom];this.relative_container=a}}else if(a.containment.constructor==Array)this.containment=a.containment},_convertPositionTo:function(a,b){if(!b)b=this.position;a=a=="absolute"?1:-1;var c=this.cssPosition=="absolute"&&!(this.scrollParent[0]!=document&&d.ui.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,f=/(html|body)/i.test(c[0].tagName);return{top:b.top+ -this.offset.relative.top*a+this.offset.parent.top*a-(d.browser.safari&&d.browser.version<526&&this.cssPosition=="fixed"?0:(this.cssPosition=="fixed"?-this.scrollParent.scrollTop():f?0:c.scrollTop())*a),left:b.left+this.offset.relative.left*a+this.offset.parent.left*a-(d.browser.safari&&d.browser.version<526&&this.cssPosition=="fixed"?0:(this.cssPosition=="fixed"?-this.scrollParent.scrollLeft():f?0:c.scrollLeft())*a)}},_generatePosition:function(a){var b=this.options,c=this.cssPosition=="absolute"&& -!(this.scrollParent[0]!=document&&d.ui.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,f=/(html|body)/i.test(c[0].tagName),e=a.pageX,h=a.pageY;if(this.originalPosition){var g;if(this.containment){if(this.relative_container){g=this.relative_container.offset();g=[this.containment[0]+g.left,this.containment[1]+g.top,this.containment[2]+g.left,this.containment[3]+g.top]}else g=this.containment;if(a.pageX-this.offset.click.leftg[2])e=g[2]+this.offset.click.left;if(a.pageY-this.offset.click.top>g[3])h=g[3]+this.offset.click.top}if(b.grid){h=b.grid[1]?this.originalPageY+Math.round((h-this.originalPageY)/b.grid[1])*b.grid[1]:this.originalPageY;h=g?!(h-this.offset.click.topg[3])?h:!(h-this.offset.click.topg[2])?e:!(e-this.offset.click.left=0;i--){var j=c.snapElements[i].left,l=j+c.snapElements[i].width,k=c.snapElements[i].top,m=k+c.snapElements[i].height;if(j-e=j&&f<=l||h>=j&&h<=l||fl)&&(e>= -i&&e<=k||g>=i&&g<=k||ek);default:return false}};d.ui.ddmanager={current:null,droppables:{"default":[]},prepareOffsets:function(a,b){var c=d.ui.ddmanager.droppables[a.options.scope]||[],e=b?b.type:null,g=(a.currentItem||a.element).find(":data(droppable)").andSelf(),f=0;a:for(;f - - - JS elements test - - - - - -
    -
    not clicked
    -
    no mouse action detected
    - - - - - -
    -
    - -
    - -
    -

    Drop here

    -
    - -
    - - - - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/json.php b/vendor/behat/mink/driver-testsuite/web-fixtures/json.php deleted file mode 100644 index 173d35820..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/json.php +++ /dev/null @@ -1,7 +0,0 @@ - 'val1', - 'key2' => 234, - 'key3' => array(1, 2, 3) -)); diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/links.html b/vendor/behat/mink/driver-testsuite/web-fixtures/links.html deleted file mode 100644 index ec626bfa9..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/links.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - Links page - - - - Redirect me to - Random number page - Link with a ' - - basic form image - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/multi_input_form.html b/vendor/behat/mink/driver-testsuite/web-fixtures/multi_input_form.html deleted file mode 100644 index 600a500c2..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/multi_input_form.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - Multi input Test - - - -

    Multi input Test

    - -
    - - - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/multicheckbox_form.html b/vendor/behat/mink/driver-testsuite/web-fixtures/multicheckbox_form.html deleted file mode 100644 index a2ae37522..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/multicheckbox_form.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - Multicheckbox Test - - - -

    Multicheckbox Test

    - -
    - - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/multiselect_form.html b/vendor/behat/mink/driver-testsuite/web-fixtures/multiselect_form.html deleted file mode 100644 index 0d2898609..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/multiselect_form.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - Multiselect Test - - - -

    Multiselect Test

    - -
    - - - - - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/popup1.html b/vendor/behat/mink/driver-testsuite/web-fixtures/popup1.html deleted file mode 100644 index b8e3fe2ab..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/popup1.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - popup_1 - - - -
    - Popup#1 div text -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/popup2.html b/vendor/behat/mink/driver-testsuite/web-fixtures/popup2.html deleted file mode 100644 index dae1932c3..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/popup2.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - popup_2 - - - -
    - Popup#2 div text -
    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/print_cookies.php b/vendor/behat/mink/driver-testsuite/web-fixtures/print_cookies.php deleted file mode 100644 index eef496ec5..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/print_cookies.php +++ /dev/null @@ -1,10 +0,0 @@ - - - - Cookies page - - - - ', '', var_export($_COOKIE, true)); ?> - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/radio.html b/vendor/behat/mink/driver-testsuite/web-fixtures/radio.html deleted file mode 100644 index 69a916a53..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/radio.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - Radio group - - -
    - - - - - -
    - -
    - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/randomizer.php b/vendor/behat/mink/driver-testsuite/web-fixtures/randomizer.php deleted file mode 100644 index 07a73ec7a..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/randomizer.php +++ /dev/null @@ -1,12 +0,0 @@ - - - - Index page - - - - -

    - - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/redirect_destination.html b/vendor/behat/mink/driver-testsuite/web-fixtures/redirect_destination.html deleted file mode 100644 index 3de7481af..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/redirect_destination.html +++ /dev/null @@ -1,10 +0,0 @@ - - - - Redirect destination - - - - You were redirected! - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/redirector.php b/vendor/behat/mink/driver-testsuite/web-fixtures/redirector.php deleted file mode 100644 index 44ac8f320..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/redirector.php +++ /dev/null @@ -1,3 +0,0 @@ - - - - - Response headers - - - -

    Response headers

    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/session_test.php b/vendor/behat/mink/driver-testsuite/web-fixtures/session_test.php deleted file mode 100644 index df1af6f14..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/session_test.php +++ /dev/null @@ -1,18 +0,0 @@ - - - - - Session Test - - - -
    - - diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/some_file.txt b/vendor/behat/mink/driver-testsuite/web-fixtures/some_file.txt deleted file mode 100644 index d515a02fe..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/some_file.txt +++ /dev/null @@ -1 +0,0 @@ -1 uploaded file diff --git a/vendor/behat/mink/driver-testsuite/web-fixtures/sub-folder/cookie_page1.php b/vendor/behat/mink/driver-testsuite/web-fixtures/sub-folder/cookie_page1.php deleted file mode 100644 index 750249b99..000000000 --- a/vendor/behat/mink/driver-testsuite/web-fixtures/sub-folder/cookie_page1.php +++ /dev/null @@ -1,4 +0,0 @@ - - - - - - - - Popup #1 - - - - Popup #2 - - -
    - Main window div text -
    - - - diff --git a/vendor/behat/mink/tests/Driver/CoreDriverTest.php b/vendor/behat/mink/tests/Driver/CoreDriverTest.php deleted file mode 100644 index cd1fe6436..000000000 --- a/vendor/behat/mink/tests/Driver/CoreDriverTest.php +++ /dev/null @@ -1,110 +0,0 @@ -getMethods(\ReflectionMethod::IS_PUBLIC) as $method) { - $this->assertTrue( - $interfaceRef->hasMethod($method->getName()), - sprintf('CoreDriver should not implement methods which are not part of the DriverInterface but %s found', $method->getName()) - ); - } - } - - public function testCreateNodeElements() - { - $driver = $this->getMockBuilder('Behat\Mink\Driver\CoreDriver') - ->setMethods(array('findElementXpaths')) - ->getMockForAbstractClass(); - - $session = $this->getMockBuilder('Behat\Mink\Session') - ->disableOriginalConstructor() - ->getMock(); - - $driver->setSession($session); - - $driver->expects($this->once()) - ->method('findElementXpaths') - ->with('xpath') - ->willReturn(array('xpath1', 'xpath2')); - - /** @var NodeElement[] $elements */ - $elements = $driver->find('xpath'); - - $this->assertInternalType('array', $elements); - $this->assertCount(2, $elements); - $this->assertContainsOnlyInstancesOf('Behat\Mink\Element\NodeElement', $elements); - - $this->assertSame('xpath1', $elements[0]->getXpath()); - $this->assertSame('xpath2', $elements[1]->getXpath()); - } - - /** - * @dataProvider getDriverInterfaceMethods - */ - public function testInterfaceMethods(\ReflectionMethod $method) - { - $refl = new \ReflectionClass('Behat\Mink\Driver\CoreDriver'); - - $this->assertFalse( - $refl->getMethod($method->getName())->isAbstract(), - sprintf('CoreDriver should implement a dummy %s method', $method->getName()) - ); - - if ('setSession' === $method->getName()) { - return; // setSession is actually implemented, so we don't expect an exception here. - } - - $driver = $this->getMockForAbstractClass('Behat\Mink\Driver\CoreDriver'); - - $this->setExpectedException('Behat\Mink\Exception\UnsupportedDriverActionException'); - call_user_func_array(array($driver, $method->getName()), $this->getArguments($method)); - } - - public function getDriverInterfaceMethods() - { - $ref = new \ReflectionClass('Behat\Mink\Driver\DriverInterface'); - - return array_map(function ($method) { - return array($method); - }, $ref->getMethods()); - } - - private function getArguments(\ReflectionMethod $method) - { - $arguments = array(); - - foreach ($method->getParameters() as $parameter) { - $arguments[] = $this->getArgument($parameter); - } - - return $arguments; - } - - private function getArgument(\ReflectionParameter $argument) - { - if ($argument->isOptional()) { - return $argument->getDefaultValue(); - } - - if ($argument->allowsNull()) { - return null; - } - - if ($argument->getClass()) { - return $this->getMockBuilder($argument->getClass()->getName()) - ->disableOriginalConstructor() - ->getMock(); - } - - return null; - } -} diff --git a/vendor/behat/mink/tests/Element/DocumentElementTest.php b/vendor/behat/mink/tests/Element/DocumentElementTest.php deleted file mode 100644 index 2105ab785..000000000 --- a/vendor/behat/mink/tests/Element/DocumentElementTest.php +++ /dev/null @@ -1,449 +0,0 @@ -document = new DocumentElement($this->session); - } - - /** - * @group legacy - */ - public function testGetSession() - { - $this->assertEquals($this->session, $this->document->getSession()); - } - - public function testFindAll() - { - $xpath = 'h3[a]'; - $css = 'h3 > a'; - - $this->driver - ->expects($this->exactly(2)) - ->method('find') - ->will($this->returnValueMap(array( - array('//html/'.$xpath, array(2, 3, 4)), - array('//html/'.$css, array(1, 2)), - ))); - - $this->selectors - ->expects($this->exactly(2)) - ->method('selectorToXpath') - ->will($this->returnValueMap(array( - array('xpath', $xpath, $xpath), - array('css', $css, $css), - ))); - - $this->assertEquals(3, count($this->document->findAll('xpath', $xpath))); - $this->assertEquals(2, count($this->document->findAll('css', $css))); - } - - public function testFind() - { - $this->driver - ->expects($this->exactly(3)) - ->method('find') - ->with('//html/h3[a]') - ->will($this->onConsecutiveCalls(array(2, 3, 4), array(1, 2), array())); - - $xpath = 'h3[a]'; - $css = 'h3 > a'; - - $this->selectors - ->expects($this->exactly(3)) - ->method('selectorToXpath') - ->will($this->returnValueMap(array( - array('xpath', $xpath, $xpath), - array('xpath', $xpath, $xpath), - array('css', $css, $xpath), - ))); - - $this->assertEquals(2, $this->document->find('xpath', $xpath)); - $this->assertEquals(1, $this->document->find('css', $css)); - $this->assertNull($this->document->find('xpath', $xpath)); - } - - public function testFindField() - { - $this->mockNamedFinder( - '//field', - array('field1', 'field2', 'field3'), - array('field', 'some field') - ); - - $this->assertEquals('field1', $this->document->findField('some field')); - $this->assertEquals(null, $this->document->findField('some field')); - } - - public function testFindLink() - { - $this->mockNamedFinder( - '//link', - array('link1', 'link2', 'link3'), - array('link', 'some link') - ); - - $this->assertEquals('link1', $this->document->findLink('some link')); - $this->assertEquals(null, $this->document->findLink('some link')); - } - - public function testFindButton() - { - $this->mockNamedFinder( - '//button', - array('button1', 'button2', 'button3'), - array('button', 'some button') - ); - - $this->assertEquals('button1', $this->document->findButton('some button')); - $this->assertEquals(null, $this->document->findButton('some button')); - } - - public function testFindById() - { - $xpath = '//*[@id=some-item-2]'; - - $this->mockNamedFinder($xpath, array(array('id2', 'id3'), array()), array('id', 'some-item-2')); - - $this->assertEquals('id2', $this->document->findById('some-item-2')); - $this->assertEquals(null, $this->document->findById('some-item-2')); - } - - public function testHasSelector() - { - $this->driver - ->expects($this->exactly(2)) - ->method('find') - ->with('//html/some xpath') - ->will($this->onConsecutiveCalls(array('id2', 'id3'), array())); - - $this->selectors - ->expects($this->exactly(2)) - ->method('selectorToXpath') - ->with('xpath', 'some xpath') - ->will($this->returnValue('some xpath')); - - $this->assertTrue($this->document->has('xpath', 'some xpath')); - $this->assertFalse($this->document->has('xpath', 'some xpath')); - } - - public function testHasContent() - { - $this->mockNamedFinder( - '//some content', - array('item1', 'item2'), - array('content', 'some content') - ); - - $this->assertTrue($this->document->hasContent('some content')); - $this->assertFalse($this->document->hasContent('some content')); - } - - public function testHasLink() - { - $this->mockNamedFinder( - '//link', - array('link1', 'link2', 'link3'), - array('link', 'some link') - ); - - $this->assertTrue($this->document->hasLink('some link')); - $this->assertFalse($this->document->hasLink('some link')); - } - - public function testHasButton() - { - $this->mockNamedFinder( - '//button', - array('button1', 'button2', 'button3'), - array('button', 'some button') - ); - - $this->assertTrue($this->document->hasButton('some button')); - $this->assertFalse($this->document->hasButton('some button')); - } - - public function testHasField() - { - $this->mockNamedFinder( - '//field', - array('field1', 'field2', 'field3'), - array('field', 'some field') - ); - - $this->assertTrue($this->document->hasField('some field')); - $this->assertFalse($this->document->hasField('some field')); - } - - public function testHasCheckedField() - { - $checkbox = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $checkbox - ->expects($this->exactly(2)) - ->method('isChecked') - ->will($this->onConsecutiveCalls(true, false)); - - $this->mockNamedFinder( - '//field', - array(array($checkbox), array(), array($checkbox)), - array('field', 'some checkbox'), - 3 - ); - - $this->assertTrue($this->document->hasCheckedField('some checkbox')); - $this->assertFalse($this->document->hasCheckedField('some checkbox')); - $this->assertFalse($this->document->hasCheckedField('some checkbox')); - } - - public function testHasUncheckedField() - { - $checkbox = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $checkbox - ->expects($this->exactly(2)) - ->method('isChecked') - ->will($this->onConsecutiveCalls(true, false)); - - $this->mockNamedFinder( - '//field', - array(array($checkbox), array(), array($checkbox)), - array('field', 'some checkbox'), - 3 - ); - - $this->assertFalse($this->document->hasUncheckedField('some checkbox')); - $this->assertFalse($this->document->hasUncheckedField('some checkbox')); - $this->assertTrue($this->document->hasUncheckedField('some checkbox')); - } - - public function testHasSelect() - { - $this->mockNamedFinder( - '//select', - array('select'), - array('select', 'some select field') - ); - - $this->assertTrue($this->document->hasSelect('some select field')); - $this->assertFalse($this->document->hasSelect('some select field')); - } - - public function testHasTable() - { - $this->mockNamedFinder( - '//table', - array('table'), - array('table', 'some table') - ); - - $this->assertTrue($this->document->hasTable('some table')); - $this->assertFalse($this->document->hasTable('some table')); - } - - public function testClickLink() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('click'); - - $this->mockNamedFinder( - '//link', - array($node), - array('link', 'some link') - ); - - $this->document->clickLink('some link'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->clickLink('some link'); - } - - public function testClickButton() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('press'); - - $this->mockNamedFinder( - '//button', - array($node), - array('button', 'some button') - ); - - $this->document->pressButton('some button'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->pressButton('some button'); - } - - public function testFillField() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('setValue') - ->with('some val'); - - $this->mockNamedFinder( - '//field', - array($node), - array('field', 'some field') - ); - - $this->document->fillField('some field', 'some val'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->fillField('some field', 'some val'); - } - - public function testCheckField() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('check'); - - $this->mockNamedFinder( - '//field', - array($node), - array('field', 'some field') - ); - - $this->document->checkField('some field'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->checkField('some field'); - } - - public function testUncheckField() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('uncheck'); - - $this->mockNamedFinder( - '//field', - array($node), - array('field', 'some field') - ); - - $this->document->uncheckField('some field'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->uncheckField('some field'); - } - - public function testSelectField() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('selectOption') - ->with('option2'); - - $this->mockNamedFinder( - '//field', - array($node), - array('field', 'some field') - ); - - $this->document->selectFieldOption('some field', 'option2'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->selectFieldOption('some field', 'option2'); - } - - public function testAttachFileToField() - { - $node = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $node - ->expects($this->once()) - ->method('attachFile') - ->with('/path/to/file'); - - $this->mockNamedFinder( - '//field', - array($node), - array('field', 'some field') - ); - - $this->document->attachFileToField('some field', '/path/to/file'); - $this->setExpectedException('Behat\Mink\Exception\ElementNotFoundException'); - $this->document->attachFileToField('some field', '/path/to/file'); - } - - public function testGetContent() - { - $expects = 'page content'; - $this->driver - ->expects($this->once()) - ->method('getContent') - ->will($this->returnValue($expects)); - - $this->assertEquals($expects, $this->document->getContent()); - } - - public function testGetText() - { - $expects = 'val1'; - $this->driver - ->expects($this->once()) - ->method('getText') - ->with('//html') - ->will($this->returnValue($expects)); - - $this->assertEquals($expects, $this->document->getText()); - } - - public function testGetHtml() - { - $expects = 'val1'; - $this->driver - ->expects($this->once()) - ->method('getHtml') - ->with('//html') - ->will($this->returnValue($expects)); - - $this->assertEquals($expects, $this->document->getHtml()); - } - - public function testGetOuterHtml() - { - $expects = 'val1'; - $this->driver - ->expects($this->once()) - ->method('getOuterHtml') - ->with('//html') - ->will($this->returnValue($expects)); - - $this->assertEquals($expects, $this->document->getOuterHtml()); - } -} diff --git a/vendor/behat/mink/tests/Element/ElementTest.php b/vendor/behat/mink/tests/Element/ElementTest.php deleted file mode 100644 index 650284c87..000000000 --- a/vendor/behat/mink/tests/Element/ElementTest.php +++ /dev/null @@ -1,71 +0,0 @@ -driver = $this->getMockBuilder('Behat\Mink\Driver\DriverInterface')->getMock(); - $this->driver - ->expects($this->once()) - ->method('setSession'); - - $this->selectors = $this->getMockBuilder('Behat\Mink\Selector\SelectorsHandler')->getMock(); - $this->session = new Session($this->driver, $this->selectors); - } - - protected function mockNamedFinder($xpath, array $results, $locator, $times = 2) - { - if (!is_array($results[0])) { - $results = array($results, array()); - } - - // In case of empty results, a second call will be done using the partial selector - $processedResults = array(); - foreach ($results as $result) { - $processedResults[] = $result; - if (empty($result)) { - $processedResults[] = $result; - ++$times; - } - } - - $returnValue = call_user_func_array(array($this, 'onConsecutiveCalls'), $processedResults); - - $this->driver - ->expects($this->exactly($times)) - ->method('find') - ->with('//html'.$xpath) - ->will($returnValue); - - $this->selectors - ->expects($this->exactly($times)) - ->method('selectorToXpath') - ->with($this->logicalOr('named_exact', 'named_partial'), $locator) - ->will($this->returnValue($xpath)); - } -} diff --git a/vendor/behat/mink/tests/Element/NodeElementTest.php b/vendor/behat/mink/tests/Element/NodeElementTest.php deleted file mode 100644 index f769dddb9..000000000 --- a/vendor/behat/mink/tests/Element/NodeElementTest.php +++ /dev/null @@ -1,598 +0,0 @@ -session); - - $this->assertEquals('some custom xpath', $node->getXpath()); - $this->assertNotEquals('not some custom xpath', $node->getXpath()); - } - - public function testGetText() - { - $expected = 'val1'; - $node = new NodeElement('text_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getText') - ->with('text_tag') - ->will($this->returnValue($expected)); - - $this->assertEquals($expected, $node->getText()); - } - - public function testGetOuterHtml() - { - $expected = 'val1'; - $node = new NodeElement('text_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getOuterHtml') - ->with('text_tag') - ->will($this->returnValue($expected)); - - $this->assertEquals($expected, $node->getOuterHtml()); - } - - public function testElementIsValid() - { - $elementXpath = 'some xpath'; - $node = new NodeElement($elementXpath, $this->session); - - $this->driver - ->expects($this->once()) - ->method('find') - ->with($elementXpath) - ->will($this->returnValue(array($elementXpath))); - - $this->assertTrue($node->isValid()); - } - - public function testElementIsNotValid() - { - $node = new NodeElement('some xpath', $this->session); - - $this->driver - ->expects($this->exactly(2)) - ->method('find') - ->with('some xpath') - ->will($this->onConsecutiveCalls(array(), array('xpath1', 'xpath2'))); - - $this->assertFalse($node->isValid(), 'no elements found is invalid element'); - $this->assertFalse($node->isValid(), 'more then 1 element found is invalid element'); - } - - public function testWaitForSuccess() - { - $callCounter = 0; - $node = new NodeElement('some xpath', $this->session); - - $result = $node->waitFor(5, function ($givenNode) use (&$callCounter) { - ++$callCounter; - - if (1 === $callCounter) { - return null; - } elseif (2 === $callCounter) { - return false; - } elseif (3 === $callCounter) { - return array(); - } - - return $givenNode; - }); - - $this->assertEquals(4, $callCounter, '->waitFor() tries to locate element several times before failing'); - $this->assertSame($node, $result, '->waitFor() returns node found in callback'); - } - - /** - * @medium - */ - public function testWaitForTimeout() - { - $node = new NodeElement('some xpath', $this->session); - - $expectedTimeout = 2; - $startTime = microtime(true); - $result = $node->waitFor($expectedTimeout, function () { - return null; - }); - $endTime = microtime(true); - - $this->assertNull($result, '->waitFor() returns whatever callback gives'); - $this->assertEquals($expectedTimeout, round($endTime - $startTime)); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testWaitForFailure() - { - $node = new NodeElement('some xpath', $this->session); - $node->waitFor(5, 'not a callable'); - } - - public function testHasAttribute() - { - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->exactly(2)) - ->method('getAttribute') - ->with('input_tag', 'href') - ->will($this->onConsecutiveCalls(null, 'http://...')); - - $this->assertFalse($node->hasAttribute('href')); - $this->assertTrue($node->hasAttribute('href')); - } - - public function testGetAttribute() - { - $expected = 'http://...'; - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getAttribute') - ->with('input_tag', 'href') - ->will($this->returnValue($expected)); - - $this->assertEquals($expected, $node->getAttribute('href')); - } - - public function testHasClass() - { - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->exactly(6)) - ->method('getAttribute') - ->with('input_tag', 'class') - ->will($this->returnValue(' - class1 class2 - ')); - - $this->assertTrue($node->hasClass('class1'), 'The "class1" was found'); - $this->assertTrue($node->hasClass('class2'), 'The "class2" was found'); - $this->assertFalse($node->hasClass('class3'), 'The "class3" was not found'); - } - - public function testHasClassWithoutArgument() - { - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getAttribute') - ->with('input_tag', 'class') - ->will($this->returnValue(null)); - - $this->assertFalse($node->hasClass('class3')); - } - - public function testGetValue() - { - $expected = 'val1'; - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getValue') - ->with('input_tag') - ->will($this->returnValue($expected)); - - $this->assertEquals($expected, $node->getValue()); - } - - public function testSetValue() - { - $expected = 'new_val'; - $node = new NodeElement('input_tag', $this->session); - - $this->driver - ->expects($this->once()) - ->method('setValue') - ->with('input_tag', $expected); - - $node->setValue($expected); - } - - public function testClick() - { - $node = new NodeElement('link_or_button', $this->session); - - $this->driver - ->expects($this->once()) - ->method('click') - ->with('link_or_button'); - - $node->click(); - } - - public function testPress() - { - $node = new NodeElement('link_or_button', $this->session); - - $this->driver - ->expects($this->once()) - ->method('click') - ->with('link_or_button'); - - $node->press(); - } - - public function testRightClick() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('rightClick') - ->with('elem'); - - $node->rightClick(); - } - - public function testDoubleClick() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('doubleClick') - ->with('elem'); - - $node->doubleClick(); - } - - public function testCheck() - { - $node = new NodeElement('checkbox_or_radio', $this->session); - - $this->driver - ->expects($this->once()) - ->method('check') - ->with('checkbox_or_radio'); - - $node->check(); - } - - public function testUncheck() - { - $node = new NodeElement('checkbox_or_radio', $this->session); - - $this->driver - ->expects($this->once()) - ->method('uncheck') - ->with('checkbox_or_radio'); - - $node->uncheck(); - } - - public function testSelectOption() - { - $node = new NodeElement('select', $this->session); - $option = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - $option - ->expects($this->once()) - ->method('getValue') - ->will($this->returnValue('item1')); - - $this->driver - ->expects($this->once()) - ->method('getTagName') - ->with('select') - ->will($this->returnValue('select')); - - $this->driver - ->expects($this->once()) - ->method('find') - ->with('select/option') - ->will($this->returnValue(array($option))); - - $this->selectors - ->expects($this->once()) - ->method('selectorToXpath') - ->with('named_exact', array('option', 'item1')) - ->will($this->returnValue('option')); - - $this->driver - ->expects($this->once()) - ->method('selectOption') - ->with('select', 'item1', false); - - $node->selectOption('item1'); - } - - /** - * @expectedException \Behat\Mink\Exception\ElementNotFoundException - */ - public function testSelectOptionNotFound() - { - $node = new NodeElement('select', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getTagName') - ->with('select') - ->will($this->returnValue('select')); - - $this->driver - ->expects($this->exactly(2)) - ->method('find') - ->with('select/option') - ->will($this->returnValue(array())); - - $this->selectors - ->expects($this->exactly(2)) - ->method('selectorToXpath') - ->with($this->logicalOr('named_exact', 'named_partial'), array('option', 'item1')) - ->will($this->returnValue('option')); - - $node->selectOption('item1'); - } - - public function testSelectOptionOtherTag() - { - $node = new NodeElement('div', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getTagName') - ->with('div') - ->will($this->returnValue('div')); - - $this->driver - ->expects($this->once()) - ->method('selectOption') - ->with('div', 'item1', false); - - $node->selectOption('item1'); - } - - public function testGetTagName() - { - $node = new NodeElement('html//h3', $this->session); - - $this->driver - ->expects($this->once()) - ->method('getTagName') - ->with('html//h3') - ->will($this->returnValue('h3')); - - $this->assertEquals('h3', $node->getTagName()); - } - - public function testGetParent() - { - $node = new NodeElement('elem', $this->session); - $parent = $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - - $this->driver - ->expects($this->once()) - ->method('find') - ->with('elem/..') - ->will($this->returnValue(array($parent))); - - $this->selectors - ->expects($this->once()) - ->method('selectorToXpath') - ->with('xpath', '..') - ->will($this->returnValue('..')); - - $this->assertSame($parent, $node->getParent()); - } - - public function testAttachFile() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('attachFile') - ->with('elem', 'path'); - - $node->attachFile('path'); - } - - public function testIsVisible() - { - $node = new NodeElement('some_xpath', $this->session); - - $this->driver - ->expects($this->exactly(2)) - ->method('isVisible') - ->with('some_xpath') - ->will($this->onConsecutiveCalls(true, false)); - - $this->assertTrue($node->isVisible()); - $this->assertFalse($node->isVisible()); - } - - public function testIsChecked() - { - $node = new NodeElement('some_xpath', $this->session); - - $this->driver - ->expects($this->exactly(2)) - ->method('isChecked') - ->with('some_xpath') - ->will($this->onConsecutiveCalls(true, false)); - - $this->assertTrue($node->isChecked()); - $this->assertFalse($node->isChecked()); - } - - public function testIsSelected() - { - $node = new NodeElement('some_xpath', $this->session); - - $this->driver - ->expects($this->exactly(2)) - ->method('isSelected') - ->with('some_xpath') - ->will($this->onConsecutiveCalls(true, false)); - - $this->assertTrue($node->isSelected()); - $this->assertFalse($node->isSelected()); - } - - public function testFocus() - { - $node = new NodeElement('some-element', $this->session); - - $this->driver - ->expects($this->once()) - ->method('focus') - ->with('some-element'); - - $node->focus(); - } - - public function testBlur() - { - $node = new NodeElement('some-element', $this->session); - - $this->driver - ->expects($this->once()) - ->method('blur') - ->with('some-element'); - - $node->blur(); - } - - public function testMouseOver() - { - $node = new NodeElement('some-element', $this->session); - - $this->driver - ->expects($this->once()) - ->method('mouseOver') - ->with('some-element'); - - $node->mouseOver(); - } - - public function testDragTo() - { - $node = new NodeElement('some_tag1', $this->session); - - $target = $this->getMock('Behat\Mink\Element\ElementInterface'); - $target->expects($this->any()) - ->method('getXPath') - ->will($this->returnValue('some_tag2')); - - $this->driver - ->expects($this->once()) - ->method('dragTo') - ->with('some_tag1', 'some_tag2'); - - $node->dragTo($target); - } - - public function testKeyPress() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('keyPress') - ->with('elem', 'key'); - - $node->keyPress('key'); - } - - public function testKeyDown() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('keyDown') - ->with('elem', 'key'); - - $node->keyDown('key'); - } - - public function testKeyUp() - { - $node = new NodeElement('elem', $this->session); - - $this->driver - ->expects($this->once()) - ->method('keyUp') - ->with('elem', 'key'); - - $node->keyUp('key'); - } - - public function testSubmitForm() - { - $node = new NodeElement('some_xpath', $this->session); - - $this->driver - ->expects($this->once()) - ->method('submitForm') - ->with('some_xpath'); - - $node->submit(); - } - - public function testFindAllUnion() - { - $node = new NodeElement('some_xpath', $this->session); - $xpath = "some_tag1 | some_tag2[@foo =\n 'bar|'']\n | some_tag3[foo | bar]"; - $expected = "some_xpath/some_tag1 | some_xpath/some_tag2[@foo =\n 'bar|''] | some_xpath/some_tag3[foo | bar]"; - - $this->driver - ->expects($this->exactly(1)) - ->method('find') - ->will($this->returnValueMap(array( - array($expected, array(2, 3, 4)), - ))); - - $this->selectors - ->expects($this->exactly(1)) - ->method('selectorToXpath') - ->will($this->returnValueMap(array( - array('xpath', $xpath, $xpath), - ))); - - $this->assertEquals(3, count($node->findAll('xpath', $xpath))); - } - - public function testFindAllParentUnion() - { - $node = new NodeElement('some_xpath | another_xpath', $this->session); - $xpath = 'some_tag1 | some_tag2'; - $expectedPrefixed = '(some_xpath | another_xpath)/some_tag1 | (some_xpath | another_xpath)/some_tag2'; - - $this->driver - ->expects($this->exactly(1)) - ->method('find') - ->will($this->returnValueMap(array( - array($expectedPrefixed, array(2, 3, 4)), - ))); - - $this->selectors - ->expects($this->exactly(1)) - ->method('selectorToXpath') - ->will($this->returnValueMap(array( - array('xpath', $xpath, $xpath), - ))); - - $this->assertEquals(3, count($node->findAll('xpath', $xpath))); - } -} diff --git a/vendor/behat/mink/tests/Exception/ElementExceptionTest.php b/vendor/behat/mink/tests/Exception/ElementExceptionTest.php deleted file mode 100644 index 87bf2ca46..000000000 --- a/vendor/behat/mink/tests/Exception/ElementExceptionTest.php +++ /dev/null @@ -1,42 +0,0 @@ -getElementMock(), new \Exception('Something went wrong')); - - $expectedMessage = "Exception thrown by element XPath\nSomething went wrong"; - $this->assertEquals($expectedMessage, $exception->getMessage()); - $this->assertEquals($expectedMessage, (string) $exception); - } - - public function testElement() - { - $element = $this->getElementMock(); - - $exception = new ElementException($element, new \Exception('Something went wrong')); - - $this->assertSame($element, $exception->getElement()); - } - - private function getElementMock() - { - $mock = $this->getMockBuilder('Behat\Mink\Element\Element') - ->disableOriginalConstructor() - ->getMock(); - - $mock->expects($this->any()) - ->method('getXPath') - ->will($this->returnValue('element XPath')); - - return $mock; - } -} diff --git a/vendor/behat/mink/tests/Exception/ElementHtmlExceptionTest.php b/vendor/behat/mink/tests/Exception/ElementHtmlExceptionTest.php deleted file mode 100644 index 7d6ea8252..000000000 --- a/vendor/behat/mink/tests/Exception/ElementHtmlExceptionTest.php +++ /dev/null @@ -1,50 +0,0 @@ -getMock('Behat\Mink\Driver\DriverInterface'); - $element = $this->getElementMock(); - - $driver->expects($this->any()) - ->method('getStatusCode') - ->will($this->returnValue(200)); - $driver->expects($this->any()) - ->method('getCurrentUrl') - ->will($this->returnValue('http://localhost/test')); - - $element->expects($this->any()) - ->method('getOuterHtml') - ->will($this->returnValue("
    \n

    Hello world

    \n

    Test

    \n
    ")); - - $expected = <<<'TXT' -Html error - -+--[ HTTP/1.1 200 | http://localhost/test | %s ] -| -|
    -|

    Hello world

    -|

    Test

    -|
    -| -TXT; - - $expected = sprintf($expected.' ', get_class($driver)); - - $exception = new ElementHtmlException('Html error', $driver, $element); - - $this->assertEquals($expected, $exception->__toString()); - } - - private function getElementMock() - { - return $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - } -} diff --git a/vendor/behat/mink/tests/Exception/ElementNotFoundExceptionTest.php b/vendor/behat/mink/tests/Exception/ElementNotFoundExceptionTest.php deleted file mode 100644 index 6faa55c53..000000000 --- a/vendor/behat/mink/tests/Exception/ElementNotFoundExceptionTest.php +++ /dev/null @@ -1,50 +0,0 @@ -getMock('Behat\Mink\Driver\DriverInterface'); - - $exception = new ElementNotFoundException($driver, $type, $selector, $locator); - - $this->assertEquals($message, $exception->getMessage()); - } - - public function provideExceptionMessage() - { - return array( - array('Tag not found.', null), - array('Field not found.', 'field'), - array('Tag matching locator "foobar" not found.', null, null, 'foobar'), - array('Tag matching css "foobar" not found.', null, 'css', 'foobar'), - array('Field matching xpath "foobar" not found.', 'Field', 'xpath', 'foobar'), - array('Tag with name "foobar" not found.', null, 'name', 'foobar'), - ); - } - - /** - * @group legacy - */ - public function testConstructWithSession() - { - $driver = $this->getMock('Behat\Mink\Driver\DriverInterface'); - $session = $this->getMockBuilder('Behat\Mink\Session') - ->disableOriginalConstructor() - ->getMock(); - $session->expects($this->any()) - ->method('getDriver') - ->will($this->returnValue($driver)); - - $exception = new ElementNotFoundException($session); - - $this->assertEquals('Tag not found.', $exception->getMessage()); - } -} diff --git a/vendor/behat/mink/tests/Exception/ElementTextExceptionTest.php b/vendor/behat/mink/tests/Exception/ElementTextExceptionTest.php deleted file mode 100644 index f8d5e4c8e..000000000 --- a/vendor/behat/mink/tests/Exception/ElementTextExceptionTest.php +++ /dev/null @@ -1,48 +0,0 @@ -getMock('Behat\Mink\Driver\DriverInterface'); - $element = $this->getElementMock(); - - $driver->expects($this->any()) - ->method('getStatusCode') - ->will($this->returnValue(200)); - $driver->expects($this->any()) - ->method('getCurrentUrl') - ->will($this->returnValue('http://localhost/test')); - - $element->expects($this->any()) - ->method('getText') - ->will($this->returnValue("Hello world\nTest\n")); - - $expected = <<<'TXT' -Text error - -+--[ HTTP/1.1 200 | http://localhost/test | %s ] -| -| Hello world -| Test -| -TXT; - - $expected = sprintf($expected.' ', get_class($driver)); - - $exception = new ElementTextException('Text error', $driver, $element); - - $this->assertEquals($expected, $exception->__toString()); - } - - private function getElementMock() - { - return $this->getMockBuilder('Behat\Mink\Element\NodeElement') - ->disableOriginalConstructor() - ->getMock(); - } -} diff --git a/vendor/behat/mink/tests/Exception/ExpectationExceptionTest.php b/vendor/behat/mink/tests/Exception/ExpectationExceptionTest.php deleted file mode 100644 index a327fcbd6..000000000 --- a/vendor/behat/mink/tests/Exception/ExpectationExceptionTest.php +++ /dev/null @@ -1,114 +0,0 @@ -getMock('Behat\Mink\Driver\DriverInterface'), new \Exception('Something failed')); - - $this->assertEquals('Something failed', $exception->getMessage()); - } - - public function testExceptionToString() - { - $driver = $this->getMock('Behat\Mink\Driver\DriverInterface'); - - $driver->expects($this->any()) - ->method('getStatusCode') - ->will($this->returnValue(200)); - $driver->expects($this->any()) - ->method('getCurrentUrl') - ->will($this->returnValue('http://localhost/test')); - - $html = "Hello\n\n

    Hello world

    \n

    Test

    \n"; - $driver->expects($this->any()) - ->method('getContent') - ->will($this->returnValue($html)); - - $expected = <<<'TXT' -Expectation failure - -+--[ HTTP/1.1 200 | http://localhost/test | %s ] -| -| -|

    Hello world

    -|

    Test

    -| -| -TXT; - - $expected = sprintf($expected.' ', get_class($driver)); - - $exception = new ExpectationException('Expectation failure', $driver); - - $this->assertEquals($expected, $exception->__toString()); - } - - public function testBigContent() - { - $driver = $this->getMock('Behat\Mink\Driver\DriverInterface'); - - $driver->expects($this->any()) - ->method('getStatusCode') - ->will($this->returnValue(200)); - $driver->expects($this->any()) - ->method('getCurrentUrl') - ->will($this->returnValue('http://localhost/test')); - - $body = str_repeat('a', 1001 - strlen('')); - - $html = sprintf("Hello\n%s", $body); - $driver->expects($this->any()) - ->method('getContent') - ->will($this->returnValue($html)); - - $expected = <<<'TXT' -Expectation failure - -+--[ HTTP/1.1 200 | http://localhost/test | %s ] -| -| %sassertEquals($expected, $exception->__toString()); - } - - public function testExceptionWhileRenderingString() - { - $driver = $this->getMock('Behat\Mink\Driver\DriverInterface'); - $driver->expects($this->any()) - ->method('getContent') - ->will($this->throwException(new \Exception('Broken page'))); - - $exception = new ExpectationException('Expectation failure', $driver); - - $this->assertEquals('Expectation failure', $exception->__toString()); - } - - /** - * @group legacy - */ - public function testConstructWithSession() - { - $driver = $this->getMock('Behat\Mink\Driver\DriverInterface'); - $session = $this->getMockBuilder('Behat\Mink\Session') - ->disableOriginalConstructor() - ->getMock(); - $session->expects($this->any()) - ->method('getDriver') - ->will($this->returnValue($driver)); - - $exception = new ExpectationException('', $session, new \Exception('Something failed')); - - $this->assertEquals('Something failed', $exception->getMessage()); - } -} diff --git a/vendor/behat/mink/tests/Exception/ResponseTextExceptionTest.php b/vendor/behat/mink/tests/Exception/ResponseTextExceptionTest.php deleted file mode 100644 index 429721dd9..000000000 --- a/vendor/behat/mink/tests/Exception/ResponseTextExceptionTest.php +++ /dev/null @@ -1,40 +0,0 @@ -getMock('Behat\Mink\Driver\DriverInterface'); - - $driver->expects($this->any()) - ->method('getStatusCode') - ->will($this->returnValue(200)); - $driver->expects($this->any()) - ->method('getCurrentUrl') - ->will($this->returnValue('http://localhost/test')); - $driver->expects($this->any()) - ->method('getText') - ->with('//html') - ->will($this->returnValue("Hello world\nTest\n")); - - $expected = <<<'TXT' -Text error - -+--[ HTTP/1.1 200 | http://localhost/test | %s ] -| -| Hello world -| Test -| -TXT; - - $expected = sprintf($expected.' ', get_class($driver)); - - $exception = new ResponseTextException('Text error', $driver); - - $this->assertEquals($expected, $exception->__toString()); - } -} diff --git a/vendor/behat/mink/tests/MinkTest.php b/vendor/behat/mink/tests/MinkTest.php deleted file mode 100644 index 11d6466ae..000000000 --- a/vendor/behat/mink/tests/MinkTest.php +++ /dev/null @@ -1,246 +0,0 @@ -mink = new Mink(); - } - - public function testRegisterSession() - { - $session = $this->getSessionMock(); - - $this->assertFalse($this->mink->hasSession('not_registered')); - $this->assertFalse($this->mink->hasSession('js')); - $this->assertFalse($this->mink->hasSession('my')); - - $this->mink->registerSession('my', $session); - - $this->assertTrue($this->mink->hasSession('my')); - $this->assertFalse($this->mink->hasSession('not_registered')); - $this->assertFalse($this->mink->hasSession('js')); - } - - public function testRegisterSessionThroughConstructor() - { - $mink = new Mink(array('my' => $this->getSessionMock())); - - $this->assertTrue($mink->hasSession('my')); - } - - public function testSessionAutostop() - { - $session1 = $this->getSessionMock(); - $session2 = $this->getSessionMock(); - $this->mink->registerSession('my1', $session1); - $this->mink->registerSession('my2', $session2); - - $session1 - ->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(true)); - $session1 - ->expects($this->once()) - ->method('stop'); - $session2 - ->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(false)); - $session2 - ->expects($this->never()) - ->method('stop'); - - unset($this->mink); - } - - public function testNotStartedSession() - { - $session = $this->getSessionMock(); - - $session - ->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(false)); - $session - ->expects($this->once()) - ->method('start'); - - $this->mink->registerSession('mock_session', $session); - $this->assertSame($session, $this->mink->getSession('mock_session')); - - $this->setExpectedException('InvalidArgumentException'); - - $this->mink->getSession('not_registered'); - } - - public function testGetAlreadyStartedSession() - { - $session = $this->getSessionMock(); - - $session - ->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(true)); - $session - ->expects($this->never()) - ->method('start'); - - $this->mink->registerSession('mock_session', $session); - $this->assertSame($session, $this->mink->getSession('mock_session')); - } - - public function testSetDefaultSessionName() - { - $this->assertNull($this->mink->getDefaultSessionName()); - - $session = $this->getSessionMock(); - $this->mink->registerSession('session_name', $session); - $this->mink->setDefaultSessionName('session_name'); - - $this->assertEquals('session_name', $this->mink->getDefaultSessionName()); - - $this->setExpectedException('InvalidArgumentException'); - - $this->mink->setDefaultSessionName('not_registered'); - } - - public function testGetDefaultSession() - { - $session1 = $this->getSessionMock(); - $session2 = $this->getSessionMock(); - - $this->assertNotSame($session1, $session2); - - $this->mink->registerSession('session_1', $session1); - $this->mink->registerSession('session_2', $session2); - $this->mink->setDefaultSessionName('session_2'); - - $this->assertSame($session1, $this->mink->getSession('session_1')); - $this->assertSame($session2, $this->mink->getSession('session_2')); - $this->assertSame($session2, $this->mink->getSession()); - - $this->mink->setDefaultSessionName('session_1'); - - $this->assertSame($session1, $this->mink->getSession()); - } - - public function testGetNoDefaultSession() - { - $session1 = $this->getSessionMock(); - - $this->mink->registerSession('session_1', $session1); - - $this->setExpectedException('InvalidArgumentException'); - - $this->mink->getSession(); - } - - public function testIsSessionStarted() - { - $session_1 = $this->getSessionMock(); - $session_2 = $this->getSessionMock(); - - $session_1 - ->expects($this->any()) - ->method('isStarted') - ->will($this->returnValue(false)); - $session_1 - ->expects($this->never()) - ->method('start'); - - $session_2 - ->expects($this->any()) - ->method('isStarted') - ->will($this->returnValue(true)); - $session_2 - ->expects($this->never()) - ->method('start'); - - $this->mink->registerSession('not_started', $session_1); - $this->assertFalse($this->mink->isSessionStarted('not_started')); - - $this->mink->registerSession('started', $session_2); - $this->assertTrue($this->mink->isSessionStarted('started')); - - $this->setExpectedException('InvalidArgumentException'); - - $this->mink->getSession('not_registered'); - } - - public function testAssertSession() - { - $session = $this->getSessionMock(); - - $this->mink->registerSession('my', $session); - - $this->assertInstanceOf('Behat\Mink\WebAssert', $this->mink->assertSession('my')); - } - - public function testAssertSessionNotRegistered() - { - $session = $this->getSessionMock(); - - $this->assertInstanceOf('Behat\Mink\WebAssert', $this->mink->assertSession($session)); - } - - public function testResetSessions() - { - $session1 = $this->getSessionMock(); - $session1->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(false)); - $session1->expects($this->never()) - ->method('reset'); - - $session2 = $this->getSessionMock(); - $session2->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(true)); - $session2->expects($this->once()) - ->method('reset'); - - $this->mink->registerSession('not started', $session1); - $this->mink->registerSession('started', $session2); - - $this->mink->resetSessions(); - } - - public function testRestartSessions() - { - $session1 = $this->getSessionMock(); - $session1->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(false)); - $session1->expects($this->never()) - ->method('restart'); - - $session2 = $this->getSessionMock(); - $session2->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(true)); - $session2->expects($this->once()) - ->method('restart'); - - $this->mink->registerSession('not started', $session1); - $this->mink->registerSession('started', $session2); - - $this->mink->restartSessions(); - } - - private function getSessionMock() - { - return $this->getMockBuilder('Behat\Mink\Session') - ->disableOriginalConstructor() - ->getMock(); - } -} diff --git a/vendor/behat/mink/tests/Selector/CssSelectorTest.php b/vendor/behat/mink/tests/Selector/CssSelectorTest.php deleted file mode 100644 index ea80d93fa..000000000 --- a/vendor/behat/mink/tests/Selector/CssSelectorTest.php +++ /dev/null @@ -1,41 +0,0 @@ -markTestSkipped('Symfony2 CssSelector component not installed'); - } - } - - public function testSelector() - { - $selector = new CssSelector(); - - $this->assertEquals('descendant-or-self::h3', $selector->translateToXPath('h3')); - $this->assertEquals('descendant-or-self::h3/span', $selector->translateToXPath('h3 > span')); - - if (interface_exists('Symfony\Component\CssSelector\XPath\TranslatorInterface')) { - // The rewritten component of Symfony 2.3 checks for attribute existence first for the class. - $expectation = "descendant-or-self::h3/*[@class and contains(concat(' ', normalize-space(@class), ' '), ' my_div ')]"; - } else { - $expectation = "descendant-or-self::h3/*[contains(concat(' ', normalize-space(@class), ' '), ' my_div ')]"; - } - $this->assertEquals($expectation, $selector->translateToXPath('h3 > .my_div')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testThrowsForArrayLocator() - { - $selector = new CssSelector(); - - $selector->translateToXPath(array('h3')); - } -} diff --git a/vendor/behat/mink/tests/Selector/ExactNamedSelectorTest.php b/vendor/behat/mink/tests/Selector/ExactNamedSelectorTest.php deleted file mode 100644 index df51f0fd7..000000000 --- a/vendor/behat/mink/tests/Selector/ExactNamedSelectorTest.php +++ /dev/null @@ -1,18 +0,0 @@ -getSelector(); - - $selector->registerNamedXpath('some', 'my_xpath'); - $this->assertEquals('my_xpath', $selector->translateToXPath('some')); - - $this->setExpectedException('InvalidArgumentException'); - - $selector->translateToXPath('custom'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testInvalidLocator() - { - $namedSelector = $this->getSelector(); - - $namedSelector->translateToXPath(array('foo', 'bar', 'baz')); - } - - /** - * @dataProvider getSelectorTests - */ - public function testSelectors($fixtureFile, $selector, $locator, $expectedExactCount, $expectedPartialCount = null) - { - $expectedCount = $this->allowPartialMatch() && null !== $expectedPartialCount - ? $expectedPartialCount - : $expectedExactCount; - - // Don't use "loadHTMLFile" due HHVM 3.3.0 issue. - $dom = new \DOMDocument('1.0', 'UTF-8'); - $dom->loadHTML(file_get_contents(__DIR__.'/fixtures/'.$fixtureFile)); - - $namedSelector = $this->getSelector(); - - $xpath = $namedSelector->translateToXPath(array($selector, $locator)); - - $domXpath = new \DOMXPath($dom); - $nodeList = $domXpath->query($xpath); - - $this->assertEquals($expectedCount, $nodeList->length); - } - - /** - * @dataProvider getSelectorTests - * @group legacy - */ - public function testEscapedSelectors($fixtureFile, $selector, $locator, $expectedExactCount, $expectedPartialCount = null) - { - // Escape the locator as Mink 1.x expects the caller of the NamedSelector to handle it - $escaper = new Escaper(); - $locator = $escaper->escapeLiteral($locator); - - $this->testSelectors($fixtureFile, $selector, $locator, $expectedExactCount, $expectedPartialCount); - } - - public function getSelectorTests() - { - $fieldCount = 8; // fields without `type` attribute - $fieldCount += 4; // fields with `type=checkbox` attribute - $fieldCount += 4; // fields with `type=radio` attribute - $fieldCount += 4; // fields with `type=file` attribute - - // Fixture file, selector name, locator, expected number of exact matched elements, expected number of partial matched elements if different - return array( - 'fieldset' => array('test.html', 'fieldset', 'fieldset-text', 2, 3), - - 'field (name/placeholder/label)' => array('test.html', 'field', 'the-field', $fieldCount), - 'field (input, with-id)' => array('test.html', 'field', 'the-field-input', 1), - 'field (textarea, with-id)' => array('test.html', 'field', 'the-field-textarea', 1), - 'field (select, with-id)' => array('test.html', 'field', 'the-field-select', 1), - 'field (input type=submit, with-id) ignored' => array('test.html', 'field', 'the-field-submit-button', 0), - 'field (input type=image, with-id) ignored' => array('test.html', 'field', 'the-field-image-button', 0), - 'field (input type=button, with-id) ignored' => array('test.html', 'field', 'the-field-button-button', 0), - 'field (input type=reset, with-id) ignored' => array('test.html', 'field', 'the-field-reset-button', 0), - 'field (input type=hidden, with-id) ignored' => array('test.html', 'field', 'the-field-hidden', 0), - - 'link (with-href)' => array('test.html', 'link', 'link-text', 5, 9), - 'link (without-href) ignored' => array('test.html', 'link', 'bad-link-text', 0), - 'link* (role=link)' => array('test.html', 'link', 'link-role-text', 4, 7), - - 'button (input, name/value/title)' => array('test.html', 'button', 'button-text', 25, 42), - 'button (type=image, with-alt)' => array('test.html', 'button', 'button-alt-text', 1, 2), - 'button (input type=submit, with-id)' => array('test.html', 'button', 'input-submit-button', 1), - 'button (input type=image, with-id)' => array('test.html', 'button', 'input-image-button', 1), - 'button (input type=button, with-id)' => array('test.html', 'button', 'input-button-button', 1), - 'button (input type=reset, with-id)' => array('test.html', 'button', 'input-reset-button', 1), - 'button (button type=submit, with-id)' => array('test.html', 'button', 'button-submit-button', 1), - 'button (button type=image, with-id)' => array('test.html', 'button', 'button-image-button', 1), - 'button (button type=button, with-id)' => array('test.html', 'button', 'button-button-button', 1), - 'button (button type=reset, with-id)' => array('test.html', 'button', 'button-reset-button', 1), - 'button* (role=button, name/value/title)' => array('test.html', 'button', 'button-role-text', 12, 20), - 'button* (role=button type=submit, with-id)' => array('test.html', 'button', 'role-button-submit-button', 1), - 'button* (role=button type=image, with-id)' => array('test.html', 'button', 'role-button-image-button', 1), - 'button* (role=button type=button, with-id)' => array('test.html', 'button', 'role-button-button-button', 1), - 'button* (role=button type=reset, with-id)' => array('test.html', 'button', 'role-button-reset-button', 1), - - 'link_or_button (with-href)' => array('test.html', 'link_or_button', 'link-text', 5, 9), - 'link_or_button (without-href) ignored' => array('test.html', 'link_or_button', 'bad-link-text', 0), - 'link_or_button* (role=link)' => array('test.html', 'link_or_button', 'link-role-text', 4, 7), - - // bug in selector: 17 instead of 25 and 34 instead of 42, because 8 buttons with `name` attribute were not matched - 'link_or_button (input, name/value/title)' => array('test.html', 'link_or_button', 'button-text', 17, 34), - 'link_or_button (type=image, with-alt)' => array('test.html', 'link_or_button', 'button-alt-text', 1, 2), - 'link_or_button (input type=submit, with-id)' => array('test.html', 'link_or_button', 'input-submit-button', 1), - 'link_or_button (input type=image, with-id)' => array('test.html', 'link_or_button', 'input-image-button', 1), - 'link_or_button (input type=button, with-id)' => array('test.html', 'link_or_button', 'input-button-button', 1), - 'link_or_button (input type=reset, with-id)' => array('test.html', 'link_or_button', 'input-reset-button', 1), - 'link_or_button (button type=submit, with-id)' => array('test.html', 'link_or_button', 'button-submit-button', 1), - 'link_or_button (button type=image, with-id)' => array('test.html', 'link_or_button', 'button-image-button', 1), - 'link_or_button (button type=button, with-id)' => array('test.html', 'link_or_button', 'button-button-button', 1), - 'link_or_button (button type=reset, with-id)' => array('test.html', 'link_or_button', 'button-reset-button', 1), - - // bug in selector: 8 instead of 12 and 16 instead of 20, because 4 buttons with `name` attribute were not matched - 'link_or_button* (role=button, name/value/title)' => array('test.html', 'link_or_button', 'button-role-text', 8, 16), - 'link_or_button* (role=button type=submit, with-id)' => array('test.html', 'link_or_button', 'role-button-submit-button', 1), - 'link_or_button* (role=button type=image, with-id)' => array('test.html', 'link_or_button', 'role-button-image-button', 1), - 'link_or_button* (role=button type=button, with-id)' => array('test.html', 'link_or_button', 'role-button-button-button', 1), - 'link_or_button* (role=button type=reset, with-id)' => array('test.html', 'link_or_button', 'role-button-reset-button', 1), - - // 3 matches, because matches every HTML node in path: html > body > div - 'content' => array('test.html', 'content', 'content-text', 1, 4), - 'content with quotes' => array('test.html', 'content', 'some "quoted" content', 1, 3), - - 'select (name/label)' => array('test.html', 'select', 'the-field', 3), - 'select (with-id)' => array('test.html', 'select', 'the-field-select', 1), - - 'checkbox (name/label)' => array('test.html', 'checkbox', 'the-field', 3), - 'checkbox (with-id)' => array('test.html', 'checkbox', 'the-field-checkbox', 1), - - 'radio (name/label)' => array('test.html', 'radio', 'the-field', 3), - 'radio (with-id)' => array('test.html', 'radio', 'the-field-radio', 1), - - 'file (name/label)' => array('test.html', 'file', 'the-field', 3), - 'file (with-id)' => array('test.html', 'file', 'the-field-file', 1), - - 'optgroup' => array('test.html', 'optgroup', 'group-label', 1, 2), - - 'option' => array('test.html', 'option', 'option-value', 2, 3), - - 'table' => array('test.html', 'table', 'the-table', 2, 3), - - 'id' => array('test.html', 'id', 'bad-link-text', 1), - 'id or name' => array('test.html', 'id_or_name', 'the-table', 2), - ); - } - - /** - * @return NamedSelector - */ - abstract protected function getSelector(); - - /** - * @return bool - */ - abstract protected function allowPartialMatch(); -} diff --git a/vendor/behat/mink/tests/Selector/PartialNamedSelectorTest.php b/vendor/behat/mink/tests/Selector/PartialNamedSelectorTest.php deleted file mode 100644 index c3e631a11..000000000 --- a/vendor/behat/mink/tests/Selector/PartialNamedSelectorTest.php +++ /dev/null @@ -1,18 +0,0 @@ -getMockBuilder('Behat\Mink\Selector\SelectorInterface')->getMock(); - $handler = new SelectorsHandler(); - - $this->assertFalse($handler->isSelectorRegistered('custom')); - - $handler->registerSelector('custom', $selector); - - $this->assertTrue($handler->isSelectorRegistered('custom')); - $this->assertSame($selector, $handler->getSelector('custom')); - } - - public function testRegisterSelectorThroughConstructor() - { - $selector = $this->getMockBuilder('Behat\Mink\Selector\SelectorInterface')->getMock(); - $handler = new SelectorsHandler(array('custom' => $selector)); - - $this->assertTrue($handler->isSelectorRegistered('custom')); - $this->assertSame($selector, $handler->getSelector('custom')); - } - - public function testRegisterDefaultSelectors() - { - $handler = new SelectorsHandler(); - - $this->assertTrue($handler->isSelectorRegistered('css')); - $this->assertTrue($handler->isSelectorRegistered('named_exact')); - $this->assertTrue($handler->isSelectorRegistered('named_partial')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testXpathSelectorThrowsExceptionForArrayLocator() - { - $handler = new SelectorsHandler(); - $handler->selectorToXpath('xpath', array('some_xpath')); - } - - public function testXpathSelectorIsReturnedAsIs() - { - $handler = new SelectorsHandler(); - $this->assertEquals('some_xpath', $handler->selectorToXpath('xpath', 'some_xpath')); - } - - public function testSelectorToXpath() - { - $selector = $this->getMockBuilder('Behat\Mink\Selector\SelectorInterface')->getMock(); - $handler = new SelectorsHandler(); - - $handler->registerSelector('custom_selector', $selector); - - $selector - ->expects($this->once()) - ->method('translateToXPath') - ->with($locator = 'some[locator]') - ->will($this->returnValue($ret = '[]some[]locator')); - - $this->assertEquals($ret, $handler->selectorToXpath('custom_selector', $locator)); - - $this->setExpectedException('InvalidArgumentException'); - $handler->selectorToXpath('undefined', 'asd'); - } - - /** - * @group legacy - */ - public function testXpathLiteral() - { - $handler = new SelectorsHandler(); - - $this->assertEquals("'some simple string'", $handler->xpathLiteral('some simple string')); - } - - /** - * @group legacy - */ - public function testBcLayer() - { - $selector = $this->getMockBuilder('Behat\Mink\Selector\SelectorInterface')->getMock(); - $handler = new SelectorsHandler(); - - $handler->registerSelector('named_partial', $selector); - - $this->assertSame($selector, $handler->getSelector('named')); - } -} diff --git a/vendor/behat/mink/tests/Selector/Xpath/EscaperTest.php b/vendor/behat/mink/tests/Selector/Xpath/EscaperTest.php deleted file mode 100644 index 535dac608..000000000 --- a/vendor/behat/mink/tests/Selector/Xpath/EscaperTest.php +++ /dev/null @@ -1,31 +0,0 @@ -assertEquals($expected, $escaper->escapeLiteral($string)); - } - - public function getXpathLiterals() - { - return array( - array('some simple string', "'some simple string'"), - array('some "d-brackets" string', "'some \"d-brackets\" string'"), - array('some \'s-brackets\' string', "\"some 's-brackets' string\""), - array( - 'some \'s-brackets\' and "d-brackets" string', - 'concat(\'some \',"\'",\'s-brackets\',"\'",\' and "d-brackets" string\')', - ), - ); - } -} diff --git a/vendor/behat/mink/tests/Selector/Xpath/ManipulatorTest.php b/vendor/behat/mink/tests/Selector/Xpath/ManipulatorTest.php deleted file mode 100644 index 7c205616e..000000000 --- a/vendor/behat/mink/tests/Selector/Xpath/ManipulatorTest.php +++ /dev/null @@ -1,64 +0,0 @@ -assertEquals($expectedXpath, $manipulator->prepend($xpath, $prefix)); - } - - public function getPrependedXpath() - { - return array( - 'simple' => array( - 'some_xpath', - 'some_tag1', - 'some_xpath/some_tag1', - ), - 'with slash' => array( - 'some_xpath', - '/some_tag1', - 'some_xpath/some_tag1', - ), - 'union' => array( - 'some_xpath', - 'some_tag1 | some_tag2', - 'some_xpath/some_tag1 | some_xpath/some_tag2', - ), - 'wrapped union' => array( - 'some_xpath', - '(some_tag1 | some_tag2)/some_child', - '(some_xpath/some_tag1 | some_xpath/some_tag2)/some_child', - ), - 'multiple wrapped union' => array( - 'some_xpath', - '( ( some_tag1 | some_tag2)/some_child | some_tag3)/leaf', - '( ( some_xpath/some_tag1 | some_xpath/some_tag2)/some_child | some_xpath/some_tag3)/leaf', - ), - 'parent union' => array( - 'some_xpath | another_xpath', - 'some_tag1 | some_tag2', - '(some_xpath | another_xpath)/some_tag1 | (some_xpath | another_xpath)/some_tag2', - ), - 'complex condition' => array( - 'some_xpath', - 'some_tag1 | some_tag2[@foo = "bar|"] | some_tag3[foo | bar]', - 'some_xpath/some_tag1 | some_xpath/some_tag2[@foo = "bar|"] | some_xpath/some_tag3[foo | bar]', - ), - 'multiline' => array( - 'some_xpath', - "some_tag1 | some_tag2[@foo =\n 'bar|'']\n | some_tag3[foo | bar]", - "some_xpath/some_tag1 | some_xpath/some_tag2[@foo =\n 'bar|''] | some_xpath/some_tag3[foo | bar]", - ), - ); - } -} diff --git a/vendor/behat/mink/tests/Selector/fixtures/test.html b/vendor/behat/mink/tests/Selector/fixtures/test.html deleted file mode 100644 index 1190e9ea6..000000000 --- a/vendor/behat/mink/tests/Selector/fixtures/test.html +++ /dev/null @@ -1,312 +0,0 @@ - - - - - - - - -
    - -
    - -
    - fieldset-text -
    - -
    - fieldset-text sample -
    - - -
    fieldset-text
    -
    -
    - -
    - content-text -
    - -
    - some content-text -
    - -
    some "quoted" content
    - -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    - -
    - - - - - -
    - -
    - - - - - -
    - -
    - - - - - -
    - - -
    - -
    - -
    - - -
    the-table
    - - - -
    some the-table
    - - - - - - - -
    the-tablethe-table
    -
    - - - - diff --git a/vendor/behat/mink/tests/SessionTest.php b/vendor/behat/mink/tests/SessionTest.php deleted file mode 100644 index 3e0104a71..000000000 --- a/vendor/behat/mink/tests/SessionTest.php +++ /dev/null @@ -1,312 +0,0 @@ -driver = $this->getMockBuilder('Behat\Mink\Driver\DriverInterface')->getMock(); - $this->selectorsHandler = $this->getMockBuilder('Behat\Mink\Selector\SelectorsHandler')->getMock(); - $this->session = new Session($this->driver, $this->selectorsHandler); - } - - public function testGetDriver() - { - $this->assertSame($this->driver, $this->session->getDriver()); - } - - public function testGetPage() - { - $this->assertInstanceOf('Behat\Mink\Element\DocumentElement', $this->session->getPage()); - } - - public function testGetSelectorsHandler() - { - $this->assertSame($this->selectorsHandler, $this->session->getSelectorsHandler()); - } - - public function testInstantiateWithoutOptionalDeps() - { - $session = new Session($this->driver); - - $this->assertInstanceOf('Behat\Mink\Selector\SelectorsHandler', $session->getSelectorsHandler()); - } - - public function testIsStarted() - { - $this->driver->expects($this->once()) - ->method('isStarted') - ->will($this->returnValue(true)); - - $this->assertTrue($this->session->isStarted()); - } - - public function testStart() - { - $this->driver->expects($this->once()) - ->method('start'); - - $this->session->start(); - } - - public function testStop() - { - $this->driver->expects($this->once()) - ->method('stop'); - - $this->session->stop(); - } - - public function testRestart() - { - $this->driver->expects($this->at(0)) - ->method('stop'); - $this->driver->expects($this->at(1)) - ->method('start'); - - $this->session->restart(); - } - - public function testVisit() - { - $this->driver - ->expects($this->once()) - ->method('visit') - ->with($url = 'some_url'); - - $this->session->visit($url); - } - - public function testReset() - { - $this->driver - ->expects($this->once()) - ->method('reset'); - - $this->session->reset(); - } - - public function testSetBasicAuth() - { - $this->driver->expects($this->once()) - ->method('setBasicAuth') - ->with('user', 'pass'); - - $this->session->setBasicAuth('user', 'pass'); - } - - public function testSetRequestHeader() - { - $this->driver->expects($this->once()) - ->method('setRequestHeader') - ->with('name', 'value'); - - $this->session->setRequestHeader('name', 'value'); - } - - public function testGetResponseHeaders() - { - $this->driver - ->expects($this->once()) - ->method('getResponseHeaders') - ->will($this->returnValue($ret = array(2, 3, 4))); - - $this->assertEquals($ret, $this->session->getResponseHeaders()); - } - - /** - * @dataProvider provideResponseHeader - */ - public function testGetResponseHeader($expected, $name, array $headers) - { - $this->driver->expects($this->once()) - ->method('getResponseHeaders') - ->willReturn($headers); - - $this->assertSame($expected, $this->session->getResponseHeader($name)); - } - - public function provideResponseHeader() - { - return array( - array('test', 'Mink', array('Mink' => 'test')), - array('test', 'mink', array('Mink' => 'test')), - array('test', 'Mink', array('mink' => 'test')), - array('test', 'Mink', array('Mink' => array('test', 'test2'))), - array(null, 'other', array('Mink' => 'test')), - ); - } - - public function testSetCookie() - { - $this->driver->expects($this->once()) - ->method('setCookie') - ->with('name', 'value'); - - $this->session->setCookie('name', 'value'); - } - - public function testGetCookie() - { - $this->driver->expects($this->once()) - ->method('getCookie') - ->with('name') - ->will($this->returnValue('value')); - - $this->assertEquals('value', $this->session->getCookie('name')); - } - - public function testGetStatusCode() - { - $this->driver - ->expects($this->once()) - ->method('getStatusCode') - ->will($this->returnValue($ret = 404)); - - $this->assertEquals($ret, $this->session->getStatusCode()); - } - - public function testGetCurrentUrl() - { - $this->driver - ->expects($this->once()) - ->method('getCurrentUrl') - ->will($this->returnValue($ret = 'http://some.url')); - - $this->assertEquals($ret, $this->session->getCurrentUrl()); - } - - public function testGetScreenshot() - { - $this->driver->expects($this->once()) - ->method('getScreenshot') - ->will($this->returnValue('screenshot')); - - $this->assertEquals('screenshot', $this->session->getScreenshot()); - } - - public function testGetWindowNames() - { - $this->driver->expects($this->once()) - ->method('getWindowNames') - ->will($this->returnValue($names = array('window 1', 'window 2'))); - - $this->assertEquals($names, $this->session->getWindowNames()); - } - - public function testGetWindowName() - { - $this->driver->expects($this->once()) - ->method('getWindowName') - ->will($this->returnValue('name')); - - $this->assertEquals('name', $this->session->getWindowName()); - } - - public function testReload() - { - $this->driver->expects($this->once()) - ->method('reload'); - - $this->session->reload(); - } - - public function testBack() - { - $this->driver->expects($this->once()) - ->method('back'); - - $this->session->back(); - } - - public function testForward() - { - $this->driver->expects($this->once()) - ->method('forward'); - - $this->session->forward(); - } - - public function testSwitchToWindow() - { - $this->driver->expects($this->once()) - ->method('switchToWindow') - ->with('test'); - - $this->session->switchToWindow('test'); - } - - public function testSwitchToIFrame() - { - $this->driver->expects($this->once()) - ->method('switchToIFrame') - ->with('test'); - - $this->session->switchToIFrame('test'); - } - - public function testExecuteScript() - { - $this->driver - ->expects($this->once()) - ->method('executeScript') - ->with($arg = 'JS'); - - $this->session->executeScript($arg); - } - - public function testEvaluateScript() - { - $this->driver - ->expects($this->once()) - ->method('evaluateScript') - ->with($arg = 'JS func') - ->will($this->returnValue($ret = '23')); - - $this->assertEquals($ret, $this->session->evaluateScript($arg)); - } - - public function testWait() - { - $this->driver - ->expects($this->once()) - ->method('wait') - ->with(1000, 'function () {}'); - - $this->session->wait(1000, 'function () {}'); - } - - public function testResizeWindow() - { - $this->driver->expects($this->once()) - ->method('resizeWindow') - ->with(800, 600, 'test'); - - $this->session->resizeWindow(800, 600, 'test'); - } - - public function testMaximizeWindow() - { - $this->driver->expects($this->once()) - ->method('maximizeWindow') - ->with('test'); - - $this->session->maximizeWindow('test'); - } -} diff --git a/vendor/behat/mink/tests/WebAssertTest.php b/vendor/behat/mink/tests/WebAssertTest.php deleted file mode 100644 index ef55d2d2e..000000000 --- a/vendor/behat/mink/tests/WebAssertTest.php +++ /dev/null @@ -1,1297 +0,0 @@ -session = $this->getMockBuilder('Behat\\Mink\\Session') - ->disableOriginalConstructor() - ->getMock(); - $this->session->expects($this->any()) - ->method('getDriver') - ->will($this->returnValue($this->getMock('Behat\Mink\Driver\DriverInterface'))); - - $this->assert = new WebAssert($this->session); - } - - public function testAddressEquals() - { - $this->session - ->expects($this->exactly(2)) - ->method('getCurrentUrl') - ->will($this->returnValue('http://example.com/script.php/sub/url?param=true#webapp/nav')) - ; - - $this->assertCorrectAssertion('addressEquals', array('/sub/url#webapp/nav')); - $this->assertWrongAssertion( - 'addressEquals', - array('sub_url'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current page is "/sub/url#webapp/nav", but "sub_url" expected.' - ); - } - - public function testAddressEqualsEmptyPath() - { - $this->session - ->expects($this->once()) - ->method('getCurrentUrl') - ->willReturn('http://example.com') - ; - - $this->assertCorrectAssertion('addressEquals', array('/')); - } - - public function testAddressEqualsEndingInScript() - { - $this->session - ->expects($this->exactly(2)) - ->method('getCurrentUrl') - ->will($this->returnValue('http://example.com/script.php')) - ; - - $this->assertCorrectAssertion('addressEquals', array('/script.php')); - $this->assertWrongAssertion( - 'addressEquals', - array('/'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current page is "/script.php", but "/" expected.' - ); - } - - public function testAddressNotEquals() - { - $this->session - ->expects($this->exactly(2)) - ->method('getCurrentUrl') - ->will($this->returnValue('http://example.com/script.php/sub/url')) - ; - - $this->assertCorrectAssertion('addressNotEquals', array('sub_url')); - $this->assertWrongAssertion( - 'addressNotEquals', - array('/sub/url'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current page is "/sub/url", but should not be.' - ); - } - - public function testAddressNotEqualsEndingInScript() - { - $this->session - ->expects($this->exactly(2)) - ->method('getCurrentUrl') - ->will($this->returnValue('http://example.com/script.php')) - ; - - $this->assertCorrectAssertion('addressNotEquals', array('/')); - $this->assertWrongAssertion( - 'addressNotEquals', - array('/script.php'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current page is "/script.php", but should not be.' - ); - } - - public function testAddressMatches() - { - $this->session - ->expects($this->exactly(2)) - ->method('getCurrentUrl') - ->will($this->returnValue('http://example.com/script.php/sub/url')) - ; - - $this->assertCorrectAssertion('addressMatches', array('/su.*rl/')); - $this->assertWrongAssertion( - 'addressMatches', - array('/suburl/'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current page "/sub/url" does not match the regex "/suburl/".' - ); - } - - public function testCookieEquals() - { - $this->session-> - expects($this->any())-> - method('getCookie')-> - will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('cookieEquals', array('foo', 'bar')); - $this->assertWrongAssertion( - 'cookieEquals', - array('bar', 'foo'), - 'Behat\Mink\Exception\ExpectationException', - 'Cookie "bar" value is "baz", but should be "foo".' - ); - } - - public function testCookieExists() - { - $this->session-> - expects($this->any())-> - method('getCookie')-> - will($this->returnValueMap( - array( - array('foo', '1'), - array('bar', null), - ) - )); - - $this->assertCorrectAssertion('cookieExists', array('foo')); - $this->assertWrongAssertion( - 'cookieExists', - array('bar'), - 'Behat\Mink\Exception\ExpectationException', - 'Cookie "bar" is not set, but should be.' - ); - } - - public function testStatusCodeEquals() - { - $this->session - ->expects($this->exactly(2)) - ->method('getStatusCode') - ->will($this->returnValue(200)) - ; - - $this->assertCorrectAssertion('statusCodeEquals', array(200)); - $this->assertWrongAssertion( - 'statusCodeEquals', - array(404), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current response status code is 200, but 404 expected.' - ); - } - - public function testStatusCodeNotEquals() - { - $this->session - ->expects($this->exactly(2)) - ->method('getStatusCode') - ->will($this->returnValue(404)) - ; - - $this->assertCorrectAssertion('statusCodeNotEquals', array(200)); - $this->assertWrongAssertion( - 'statusCodeNotEquals', - array(404), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current response status code is 404, but should not be.' - ); - } - - public function testResponseHeaderEquals() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderEquals', array('foo', 'bar')); - $this->assertWrongAssertion( - 'responseHeaderEquals', - array('bar', 'foo'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current response header "bar" is "baz", but "foo" expected.' - ); - } - - public function testResponseHeaderNotEquals() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderNotEquals', array('foo', 'baz')); - $this->assertWrongAssertion( - 'responseHeaderNotEquals', - array('bar', 'baz'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Current response header "bar" is "baz", but should not be.' - ); - } - - public function testResponseHeaderContains() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderContains', array('foo', 'ba')); - $this->assertWrongAssertion( - 'responseHeaderContains', - array('bar', 'bz'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The text "bz" was not found anywhere in the "bar" response header.' - ); - } - - public function testResponseHeaderNotContains() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderNotContains', array('foo', 'bz')); - $this->assertWrongAssertion( - 'responseHeaderNotContains', - array('bar', 'ba'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The text "ba" was found in the "bar" response header, but it should not.' - ); - } - - public function testResponseHeaderMatches() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderMatches', array('foo', '/ba(.*)/')); - $this->assertWrongAssertion( - 'responseHeaderMatches', - array('bar', '/b[^a]/'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The pattern "/b[^a]/" was not found anywhere in the "bar" response header.' - ); - } - - public function testResponseHeaderNotMatches() - { - $this->session - ->expects($this->any()) - ->method('getResponseHeader') - ->will($this->returnValueMap( - array( - array('foo', 'bar'), - array('bar', 'baz'), - ) - )); - - $this->assertCorrectAssertion('responseHeaderNotMatches', array('foo', '/bz/')); - $this->assertWrongAssertion( - 'responseHeaderNotMatches', - array('bar', '/b[ab]z/'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The pattern "/b[ab]z/" was found in the text of the "bar" response header, but it should not.' - ); - } - - public function testPageTextContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue("Some page\n\ttext")) - ; - - $this->assertCorrectAssertion('pageTextContains', array('PAGE text')); - $this->assertWrongAssertion( - 'pageTextContains', - array('html text'), - 'Behat\\Mink\\Exception\\ResponseTextException', - 'The text "html text" was not found anywhere in the text of the current page.' - ); - } - - public function testPageTextNotContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue("Some html\n\ttext")) - ; - - $this->assertCorrectAssertion('pageTextNotContains', array('PAGE text')); - $this->assertWrongAssertion( - 'pageTextNotContains', - array('HTML text'), - 'Behat\\Mink\\Exception\\ResponseTextException', - 'The text "HTML text" appears in the text of this page, but it should not.' - ); - } - - public function testPageTextMatches() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue('Some page text')) - ; - - $this->assertCorrectAssertion('pageTextMatches', array('/PA.E/i')); - $this->assertWrongAssertion( - 'pageTextMatches', - array('/html/'), - 'Behat\\Mink\\Exception\\ResponseTextException', - 'The pattern /html/ was not found anywhere in the text of the current page.' - ); - } - - public function testPageTextNotMatches() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue('Some html text')) - ; - - $this->assertCorrectAssertion('pageTextNotMatches', array('/PA.E/i')); - $this->assertWrongAssertion( - 'pageTextNotMatches', - array('/HTML/i'), - 'Behat\\Mink\\Exception\\ResponseTextException', - 'The pattern /HTML/i was found in the text of the current page, but it should not.' - ); - } - - public function testResponseContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getContent') - ->will($this->returnValue('Some page text')) - ; - - $this->assertCorrectAssertion('responseContains', array('PAGE text')); - $this->assertWrongAssertion( - 'responseContains', - array('html text'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The string "html text" was not found anywhere in the HTML response of the current page.' - ); - } - - public function testResponseNotContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getContent') - ->will($this->returnValue('Some html text')) - ; - - $this->assertCorrectAssertion('responseNotContains', array('PAGE text')); - $this->assertWrongAssertion( - 'responseNotContains', - array('HTML text'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The string "HTML text" appears in the HTML response of this page, but it should not.' - ); - } - - public function testResponseMatches() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getContent') - ->will($this->returnValue('Some page text')) - ; - - $this->assertCorrectAssertion('responseMatches', array('/PA.E/i')); - $this->assertWrongAssertion( - 'responseMatches', - array('/html/'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The pattern /html/ was not found anywhere in the HTML response of the page.' - ); - } - - public function testResponseNotMatches() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('getContent') - ->will($this->returnValue('Some html text')) - ; - - $this->assertCorrectAssertion('responseNotMatches', array('/PA.E/i')); - $this->assertWrongAssertion( - 'responseNotMatches', - array('/HTML/i'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The pattern /HTML/i was found in the HTML response of the page, but it should not.' - ); - } - - public function testElementsCount() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('findAll') - ->with('css', 'h2 > span') - ->will($this->returnValue(array(1, 2))) - ; - - $this->assertCorrectAssertion('elementsCount', array('css', 'h2 > span', 2)); - $this->assertWrongAssertion( - 'elementsCount', - array('css', 'h2 > span', 3), - 'Behat\\Mink\\Exception\\ExpectationException', - '2 elements matching css "h2 > span" found on the page, but should be 3.' - ); - } - - public function testElementExists() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(4)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->onConsecutiveCalls(1, null, 1, null)) - ; - - $this->assertCorrectAssertion('elementExists', array('css', 'h2 > span')); - $this->assertWrongAssertion( - 'elementExists', - array('css', 'h2 > span'), - 'Behat\\Mink\\Exception\\ElementNotFoundException', - 'Element matching css "h2 > span" not found.' - ); - - $this->assertCorrectAssertion('elementExists', array('css', 'h2 > span', $page)); - $this->assertWrongAssertion( - 'elementExists', - array('css', 'h2 > span', $page), - 'Behat\\Mink\\Exception\\ElementNotFoundException', - 'Element matching css "h2 > span" not found.' - ); - } - - public function testElementExistsWithArrayLocator() - { - $container = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session->expects($this->never()) - ->method('getPage') - ; - - $container - ->expects($this->exactly(2)) - ->method('find') - ->with('named', array('element', 'Test')) - ->will($this->onConsecutiveCalls(1, null)) - ; - - $this->assertCorrectAssertion('elementExists', array('named', array('element', 'Test'), $container)); - $this->assertWrongAssertion( - 'elementExists', - array('named', array('element', 'Test'), $container), - 'Behat\\Mink\\Exception\\ElementNotFoundException', - 'Element with named "element Test" not found.' - ); - } - - public function testElementNotExists() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(4)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->onConsecutiveCalls(null, 1, null, 1)) - ; - - $this->assertCorrectAssertion('elementNotExists', array('css', 'h2 > span')); - $this->assertWrongAssertion( - 'elementNotExists', - array('css', 'h2 > span'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'An element matching css "h2 > span" appears on this page, but it should not.' - ); - - $this->assertCorrectAssertion('elementNotExists', array('css', 'h2 > span', $page)); - $this->assertWrongAssertion( - 'elementNotExists', - array('css', 'h2 > span', $page), - 'Behat\\Mink\\Exception\\ExpectationException', - 'An element matching css "h2 > span" appears on this page, but it should not.' - ); - } - - /** - * @dataProvider getArrayLocatorFormats - */ - public function testElementNotExistsArrayLocator($selector, $locator, $expectedMessage) - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->once()) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->once()) - ->method('find') - ->with($selector, $locator) - ->will($this->returnValue(1)) - ; - - $this->assertWrongAssertion( - 'elementNotExists', - array($selector, $locator), - 'Behat\\Mink\\Exception\\ExpectationException', - $expectedMessage - ); - } - - public function getArrayLocatorFormats() - { - return array( - 'named' => array( - 'named', - array('button', 'Test'), - 'An button matching locator "Test" appears on this page, but it should not.', - ), - 'custom' => array( - 'custom', - array('test', 'foo'), - 'An element matching custom "test foo" appears on this page, but it should not.', - ), - ); - } - - public function testElementTextContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue('element text')) - ; - - $this->assertCorrectAssertion('elementTextContains', array('css', 'h2 > span', 'text')); - $this->assertWrongAssertion( - 'elementTextContains', - array('css', 'h2 > span', 'html'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The text "html" was not found in the text of the element matching css "h2 > span".' - ); - } - - public function testElementTextNotContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getText') - ->will($this->returnValue('element text')) - ; - - $this->assertCorrectAssertion('elementTextNotContains', array('css', 'h2 > span', 'html')); - $this->assertWrongAssertion( - 'elementTextNotContains', - array('css', 'h2 > span', 'text'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The text "text" appears in the text of the element matching css "h2 > span", but it should not.' - ); - } - - public function testElementContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getHtml') - ->will($this->returnValue('element html')) - ; - - $this->assertCorrectAssertion('elementContains', array('css', 'h2 > span', 'html')); - $this->assertWrongAssertion( - 'elementContains', - array('css', 'h2 > span', 'text'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The string "text" was not found in the HTML of the element matching css "h2 > span".' - ); - } - - public function testElementNotContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getHtml') - ->will($this->returnValue('element html')) - ; - - $this->assertCorrectAssertion('elementNotContains', array('css', 'h2 > span', 'text')); - $this->assertWrongAssertion( - 'elementNotContains', - array('css', 'h2 > span', 'html'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The string "html" appears in the HTML of the element matching css "h2 > span", but it should not.' - ); - } - - public function testElementAttributeContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('hasAttribute') - ->will($this->returnValue(true)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getAttribute') - ->with('name') - ->will($this->returnValue('foo')) - ; - - $this->assertCorrectAssertion('elementAttributeContains', array('css', 'h2 > span', 'name', 'foo')); - $this->assertWrongAssertion( - 'elementAttributeContains', - array('css', 'h2 > span', 'name', 'bar'), - 'Behat\\Mink\\Exception\\ElementHtmlException', - 'The text "bar" was not found in the attribute "name" of the element matching css "h2 > span".' - ); - } - - public function testElementAttributeExists() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->at(0)) - ->method('hasAttribute') - ->with('name') - ->will($this->returnValue(true)) - ; - - $element - ->expects($this->at(1)) - ->method('hasAttribute') - ->with('name') - ->will($this->returnValue(false)) - ; - - $this->assertCorrectAssertion('elementAttributeExists', array('css', 'h2 > span', 'name')); - $this->assertWrongAssertion( - 'elementAttributeExists', - array('css', 'h2 > span', 'name'), - 'Behat\\Mink\\Exception\\ElementHtmlException', - 'The attribute "name" was not found in the element matching css "h2 > span".' - ); - } - - public function testElementAttributeNotContains() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('find') - ->with('css', 'h2 > span') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('hasAttribute') - ->will($this->returnValue(true)) - ; - - $element - ->expects($this->exactly(2)) - ->method('getAttribute') - ->with('name') - ->will($this->returnValue('foo')) - ; - - $this->assertCorrectAssertion('elementAttributeNotContains', array('css', 'h2 > span', 'name', 'bar')); - $this->assertWrongAssertion( - 'elementAttributeNotContains', - array('css', 'h2 > span', 'name', 'foo'), - 'Behat\\Mink\\Exception\\ElementHtmlException', - 'The text "foo" was found in the attribute "name" of the element matching css "h2 > span".' - ); - } - - public function testFieldExists() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('findField') - ->with('username') - ->will($this->onConsecutiveCalls($element, null)) - ; - - $this->assertCorrectAssertion('fieldExists', array('username')); - $this->assertWrongAssertion( - 'fieldExists', - array('username'), - 'Behat\\Mink\\Exception\\ElementNotFoundException', - 'Form field with id|name|label|value "username" not found.' - ); - } - - public function testFieldNotExists() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('findField') - ->with('username') - ->will($this->onConsecutiveCalls(null, $element)) - ; - - $this->assertCorrectAssertion('fieldNotExists', array('username')); - $this->assertWrongAssertion( - 'fieldNotExists', - array('username'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'A field "username" appears on this page, but it should not.' - ); - } - - public function testFieldValueEquals() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(4)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(4)) - ->method('findField') - ->with('username') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(4)) - ->method('getValue') - ->will($this->returnValue(234)) - ; - - $this->assertCorrectAssertion('fieldValueEquals', array('username', 234)); - $this->assertWrongAssertion( - 'fieldValueEquals', - array('username', 235), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The field "username" value is "234", but "235" expected.' - ); - $this->assertWrongAssertion( - 'fieldValueEquals', - array('username', 23), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The field "username" value is "234", but "23" expected.' - ); - $this->assertWrongAssertion( - 'fieldValueEquals', - array('username', ''), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The field "username" value is "234", but "" expected.' - ); - } - - public function testFieldValueNotEquals() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(4)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(4)) - ->method('findField') - ->with('username') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(4)) - ->method('getValue') - ->will($this->returnValue(235)) - ; - - $this->assertCorrectAssertion('fieldValueNotEquals', array('username', 234)); - $this->assertWrongAssertion( - 'fieldValueNotEquals', - array('username', 235), - 'Behat\\Mink\\Exception\\ExpectationException', - 'The field "username" value is "235", but it should not be.' - ); - $this->assertCorrectAssertion('fieldValueNotEquals', array('username', 23)); - $this->assertCorrectAssertion('fieldValueNotEquals', array('username', '')); - } - - public function testCheckboxChecked() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('findField') - ->with('remember_me') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('isChecked') - ->will($this->onConsecutiveCalls(true, false)) - ; - - $this->assertCorrectAssertion('checkboxChecked', array('remember_me')); - $this->assertWrongAssertion( - 'checkboxChecked', - array('remember_me'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Checkbox "remember_me" is not checked, but it should be.' - ); - } - - public function testCheckboxNotChecked() - { - $page = $this->getMockBuilder('Behat\\Mink\\Element\\DocumentElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $element = $this->getMockBuilder('Behat\\Mink\\Element\\NodeElement') - ->disableOriginalConstructor() - ->getMock() - ; - - $this->session - ->expects($this->exactly(2)) - ->method('getPage') - ->will($this->returnValue($page)) - ; - - $page - ->expects($this->exactly(2)) - ->method('findField') - ->with('remember_me') - ->will($this->returnValue($element)) - ; - - $element - ->expects($this->exactly(2)) - ->method('isChecked') - ->will($this->onConsecutiveCalls(false, true)) - ; - - $this->assertCorrectAssertion('checkboxNotChecked', array('remember_me')); - $this->assertWrongAssertion( - 'checkboxNotChecked', - array('remember_me'), - 'Behat\\Mink\\Exception\\ExpectationException', - 'Checkbox "remember_me" is checked, but it should not be.' - ); - } - - private function assertCorrectAssertion($assertion, $arguments) - { - try { - call_user_func_array(array($this->assert, $assertion), $arguments); - } catch (ExpectationException $e) { - $this->fail('Correct assertion should not throw an exception: '.$e->getMessage()); - } - } - - private function assertWrongAssertion($assertion, $arguments, $exceptionClass, $exceptionMessage) - { - if ('Behat\Mink\Exception\ExpectationException' !== $exceptionClass && !is_subclass_of($exceptionClass, 'Behat\Mink\Exception\ExpectationException')) { - throw new \LogicException('Wrong expected exception for the failed assertion. It should be a Behat\Mink\Exception\ExpectationException.'); - } - - try { - call_user_func_array(array($this->assert, $assertion), $arguments); - $this->fail('Wrong assertion should throw an exception'); - } catch (ExpectationException $e) { - $this->assertInstanceOf($exceptionClass, $e); - $this->assertSame($exceptionMessage, $e->getMessage()); - } - } -} diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index fdd91a9b4..4c4df5b1c 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -1,25 +1,39 @@ [ { - "name": "psr/log", - "version": "1.0.0", - "version_normalized": "1.0.0.0", + "name": "composer/installers", + "version": "v1.0.21", + "version_normalized": "1.0.21.0", "source": { "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "1.0.0" + "url": "https://github.com/composer/installers.git", + "reference": "d64e23fce42a4063d63262b19b8e7c0f3b5e4c45" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/fe0936ee26643249e916849d48e3a51d5f5e278b", - "reference": "1.0.0", + "url": "https://api.github.com/repos/composer/installers/zipball/d64e23fce42a4063d63262b19b8e7c0f3b5e4c45", + "reference": "d64e23fce42a4063d63262b19b8e7c0f3b5e4c45", "shasum": "" }, - "time": "2012-12-21 11:40:51", - "type": "library", + "replace": { + "roundcube/plugin-installer": "*", + "shama/baton": "*" + }, + "require-dev": { + "composer/composer": "1.0.*@dev", + "phpunit/phpunit": "4.1.*" + }, + "time": "2015-02-18 17:17:01", + "type": "composer-installer", + "extra": { + "class": "Composer\\Installers\\Installer", + "branch-alias": { + "dev-master": "1.0-dev" + } + }, "installation-source": "dist", "autoload": { "psr-0": { - "Psr\\Log\\": "" + "Composer\\Installers\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -28,57 +42,98 @@ ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Kyle Robinson Young", + "email": "kyle@dontkry.com", + "homepage": "https://github.com/shama" } ], - "description": "Common interface for logging libraries", + "description": "A multi-framework Composer library installer", + "homepage": "http://composer.github.com/installers/", "keywords": [ - "log", - "psr", - "psr-3" + "Craft", + "Dolibarr", + "Hurad", + "MODX Evo", + "OXID", + "SMF", + "Thelia", + "WolfCMS", + "agl", + "aimeos", + "annotatecms", + "bitrix", + "cakephp", + "chef", + "codeigniter", + "concrete5", + "croogo", + "dokuwiki", + "drupal", + "elgg", + "fuelphp", + "grav", + "installer", + "joomla", + "kohana", + "laravel", + "lithium", + "magento", + "mako", + "mediawiki", + "modulework", + "moodle", + "phpbb", + "piwik", + "ppi", + "puppet", + "roundcube", + "shopware", + "silverstripe", + "symfony", + "typo3", + "wordpress", + "zend", + "zikula" ] }, { - "name": "symfony-cmf/routing", - "version": "1.3.0", - "version_normalized": "1.3.0.0", + "name": "wikimedia/composer-merge-plugin", + "version": "dev-master", + "version_normalized": "9999999-dev", "source": { "type": "git", - "url": "https://github.com/symfony-cmf/Routing.git", - "reference": "8e87981d72c6930a27585dcd3119f3199f6cb2a6" + "url": "https://github.com/wikimedia/composer-merge-plugin.git", + "reference": "47bb3388cfeae41a38087ac8465a7d08fa92ea2e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony-cmf/Routing/zipball/8e87981d72c6930a27585dcd3119f3199f6cb2a6", - "reference": "8e87981d72c6930a27585dcd3119f3199f6cb2a6", + "url": "https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/47bb3388cfeae41a38087ac8465a7d08fa92ea2e", + "reference": "47bb3388cfeae41a38087ac8465a7d08fa92ea2e", "shasum": "" }, "require": { - "php": ">=5.3.3", - "psr/log": "~1.0", - "symfony/http-kernel": "~2.2", - "symfony/routing": "~2.2" + "composer-plugin-api": "^1.0", + "php": ">=5.3.2" }, "require-dev": { - "symfony/config": "~2.2", - "symfony/dependency-injection": "~2.0@stable", - "symfony/event-dispatcher": "~2.1" - }, - "suggest": { - "symfony/event-dispatcher": "DynamicRouter can optionally trigger an event at the start of matching. Minimal version ~2.1" + "composer/composer": "1.0.*@dev", + "jakub-onderka/php-parallel-lint": "~0.8", + "phpspec/prophecy-phpunit": "~1.0", + "phpunit/phpunit": "~4.0", + "squizlabs/php_codesniffer": "~2.1.0" }, - "time": "2014-10-20 20:55:17", - "type": "library", + "time": "2015-09-22 21:14:25", + "type": "composer-plugin", "extra": { "branch-alias": { - "dev-master": "1.3-dev" - } + "dev-master": "1.3.x-dev" + }, + "class": "Wikimedia\\Composer\\MergePlugin" }, "installation-source": "dist", "autoload": { "psr-4": { - "Symfony\\Cmf\\Component\\Routing\\": "" + "Wikimedia\\Composer\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -87,162 +142,163 @@ ], "authors": [ { - "name": "Symfony CMF Community", - "homepage": "https://github.com/symfony-cmf/Routing/contributors" + "name": "Bryan Davis", + "email": "bd808@wikimedia.org" } ], - "description": "Extends the Symfony2 routing component for dynamic routes and chaining several routers", - "homepage": "http://cmf.symfony.com", - "keywords": [ - "database", - "routing" - ] + "description": "Composer plugin to merge multiple composer.json files" }, { - "name": "sebastian/global-state", + "name": "composer/semver", "version": "1.0.0", "version_normalized": "1.0.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01" + "url": "https://github.com/composer/semver.git", + "reference": "d0e1ccc6d44ab318b758d709e19176037da6b1ba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/c7428acdb62ece0a45e6306f1ae85e1c05b09c01", - "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01", + "url": "https://api.github.com/repos/composer/semver/zipball/d0e1ccc6d44ab318b758d709e19176037da6b1ba", + "reference": "d0e1ccc6d44ab318b758d709e19176037da6b1ba", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.2" }, "require-dev": { - "phpunit/phpunit": "~4.2" - }, - "suggest": { - "ext-uopz": "*" + "phpunit/phpunit": "~4.5", + "phpunit/phpunit-mock-objects": "~2.3" }, - "time": "2014-10-06 09:23:50", + "time": "2015-09-21 09:42:36", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "0.1-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Composer\\Semver\\": "src" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Rob Bast", + "email": "rob.bast@gmail.com" + }, + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" } ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", + "description": "Semver library that offers utilities, version constraint parsing and validation.", "keywords": [ - "global state" + "semantic", + "semver", + "validation", + "versioning" ] }, { - "name": "sebastian/diff", - "version": "1.3.0", - "version_normalized": "1.3.0.0", + "name": "doctrine/lexer", + "version": "v1.0.1", + "version_normalized": "1.0.1.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3" + "url": "https://github.com/doctrine/lexer.git", + "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/863df9687835c62aa423a22412d26fa2ebde3fd3", - "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3", + "url": "https://api.github.com/repos/doctrine/lexer/zipball/83893c552fd2045dd78aef794c31e694c37c0b8c", + "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c", "shasum": "" }, "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.2" + "php": ">=5.3.2" }, - "time": "2015-02-22 15:13:53", + "time": "2014-09-09 13:34:57", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.0.x-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-0": { + "Doctrine\\Common\\Lexer\\": "lib/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" + "name": "Roman Borschel", + "email": "roman@code-factory.org" }, { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } ], - "description": "Diff implementation", - "homepage": "http://www.github.com/sebastianbergmann/diff", + "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", + "homepage": "http://www.doctrine-project.org", "keywords": [ - "diff" + "lexer", + "parser" ] }, { - "name": "phpdocumentor/reflection-docblock", - "version": "2.0.4", - "version_normalized": "2.0.4.0", + "name": "doctrine/inflector", + "version": "v1.0.1", + "version_normalized": "1.0.1.0", "source": { "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" + "url": "https://github.com/doctrine/inflector.git", + "reference": "0bcb2e79d8571787f18b7eb036ed3d004908e604" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", + "url": "https://api.github.com/repos/doctrine/inflector/zipball/0bcb2e79d8571787f18b7eb036ed3d004908e604", + "reference": "0bcb2e79d8571787f18b7eb036ed3d004908e604", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.2" }, "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "suggest": { - "dflydev/markdown": "~1.0", - "erusev/parsedown": "~1.0" + "phpunit/phpunit": "4.*" }, - "time": "2015-02-03 12:10:50", + "time": "2014-12-20 21:24:13", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "1.0.x-dev" } }, "installation-source": "dist", "autoload": { "psr-0": { - "phpDocumentor": [ - "src/" - ] + "Doctrine\\Common\\Inflector\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -251,40 +307,67 @@ ], "authors": [ { - "name": "Mike van Riel", - "email": "mike.vanriel@naenius.com" + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } + ], + "description": "Common String Manipulations with regard to casing and singular/plural rules.", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "inflection", + "pluralize", + "singularize", + "string" ] }, { - "name": "doctrine/lexer", - "version": "v1.0.1", - "version_normalized": "1.0.1.0", + "name": "doctrine/collections", + "version": "v1.3.0", + "version_normalized": "1.3.0.0", "source": { "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c" + "url": "https://github.com/doctrine/collections.git", + "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/83893c552fd2045dd78aef794c31e694c37c0b8c", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c", + "url": "https://api.github.com/repos/doctrine/collections/zipball/6c1e4eef75f310ea1b3e30945e9f06e652128b8a", + "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a", "shasum": "" }, "require": { "php": ">=5.3.2" }, - "time": "2014-09-09 13:34:57", + "require-dev": { + "phpunit/phpunit": "~4.0" + }, + "time": "2015-04-14 22:21:58", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.2.x-dev" } }, "installation-source": "dist", "autoload": { "psr-0": { - "Doctrine\\Common\\Lexer\\": "lib/" + "Doctrine\\Common\\Collections\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -296,51 +379,68 @@ "name": "Roman Borschel", "email": "roman@code-factory.org" }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, { "name": "Guilherme Blanco", "email": "guilhermeblanco@gmail.com" }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, { "name": "Johannes Schmitt", "email": "schmittjoh@gmail.com" } ], - "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", + "description": "Collections Abstraction library", "homepage": "http://www.doctrine-project.org", "keywords": [ - "lexer", - "parser" + "array", + "collections", + "iterator" ] }, { - "name": "psr/http-message", - "version": "1.0", - "version_normalized": "1.0.0.0", + "name": "doctrine/cache", + "version": "v1.4.2", + "version_normalized": "1.4.2.0", "source": { "type": "git", - "url": "https://github.com/php-fig/http-message.git", - "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298" + "url": "https://github.com/doctrine/cache.git", + "reference": "8c434000f420ade76a07c64cbe08ca47e5c101ca" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", - "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", + "url": "https://api.github.com/repos/doctrine/cache/zipball/8c434000f420ade76a07c64cbe08ca47e5c101ca", + "reference": "8c434000f420ade76a07c64cbe08ca47e5c101ca", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=5.3.2" }, - "time": "2015-05-04 20:22:00", + "conflict": { + "doctrine/common": ">2.2,<2.4" + }, + "require-dev": { + "phpunit/phpunit": ">=3.7", + "predis/predis": "~1.0", + "satooshi/php-coveralls": "~0.6" + }, + "time": "2015-08-31 12:36:41", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.5.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Psr\\Http\\Message\\": "src/" + "psr-0": { + "Doctrine\\Common\\Cache\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -349,52 +449,67 @@ ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } ], - "description": "Common interface for HTTP messages", + "description": "Caching library offering an object-oriented API for many cache backends", + "homepage": "http://www.doctrine-project.org", "keywords": [ - "http", - "http-message", - "psr", - "psr-7", - "request", - "response" + "cache", + "caching" ] }, { - "name": "symfony/psr-http-message-bridge", - "version": "v0.2", - "version_normalized": "0.2.0.0", + "name": "doctrine/annotations", + "version": "v1.2.7", + "version_normalized": "1.2.7.0", "source": { "type": "git", - "url": "https://github.com/symfony/psr-http-message-bridge.git", - "reference": "dc7e308e1dc2898a46776e2221a643cb08315453" + "url": "https://github.com/doctrine/annotations.git", + "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/psr-http-message-bridge/zipball/dc7e308e1dc2898a46776e2221a643cb08315453", - "reference": "dc7e308e1dc2898a46776e2221a643cb08315453", + "url": "https://api.github.com/repos/doctrine/annotations/zipball/f25c8aab83e0c3e976fd7d19875f198ccf2f7535", + "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535", "shasum": "" }, "require": { - "php": ">=5.3.3", - "psr/http-message": "~1.0", - "symfony/http-foundation": "~2.3|~3.0" + "doctrine/lexer": "1.*", + "php": ">=5.3.2" }, "require-dev": { - "symfony/phpunit-bridge": "~2.7|~3.0" + "doctrine/cache": "1.*", + "phpunit/phpunit": "4.*" }, - "suggest": { - "zendframework/zend-diactoros": "To use the Zend Diactoros factory" + "time": "2015-08-31 12:32:49", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.3.x-dev" + } }, - "time": "2015-05-29 17:57:12", - "type": "symfony-bridge", "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Bridge\\PsrHttpMessage\\": "" + "psr-0": { + "Doctrine\\Common\\Annotations\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -403,56 +518,71 @@ ], "authors": [ { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" + "name": "Roman Borschel", + "email": "roman@code-factory.org" }, { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } ], - "description": "PSR HTTP message bridge", - "homepage": "http://symfony.com", + "description": "Docblock Annotations Parser", + "homepage": "http://www.doctrine-project.org", "keywords": [ - "http", - "http-message", - "psr-7" + "annotations", + "docblock", + "parser" ] }, { - "name": "egulias/email-validator", - "version": "1.2.9", - "version_normalized": "1.2.9.0", + "name": "doctrine/common", + "version": "v2.5.1", + "version_normalized": "2.5.1.0", "source": { "type": "git", - "url": "https://github.com/egulias/EmailValidator.git", - "reference": "af864423f50ea59f96c87bb1eae147a70bcf67a1" + "url": "https://github.com/doctrine/common.git", + "reference": "0009b8f0d4a917aabc971fb089eba80e872f83f9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/af864423f50ea59f96c87bb1eae147a70bcf67a1", - "reference": "af864423f50ea59f96c87bb1eae147a70bcf67a1", + "url": "https://api.github.com/repos/doctrine/common/zipball/0009b8f0d4a917aabc971fb089eba80e872f83f9", + "reference": "0009b8f0d4a917aabc971fb089eba80e872f83f9", "shasum": "" }, "require": { - "doctrine/lexer": "~1.0,>=1.0.1", - "php": ">= 5.3.3" + "doctrine/annotations": "1.*", + "doctrine/cache": "1.*", + "doctrine/collections": "1.*", + "doctrine/inflector": "1.*", + "doctrine/lexer": "1.*", + "php": ">=5.3.2" }, "require-dev": { - "phpunit/phpunit": "~4.4", - "satooshi/php-coveralls": "dev-master" + "phpunit/phpunit": "~3.7" }, - "time": "2015-06-22 21:07:51", + "time": "2015-08-31 13:00:22", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.6.x-dev" } }, "installation-source": "dist", "autoload": { "psr-0": { - "Egulias\\": "src/" + "Doctrine\\Common\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -461,18 +591,154 @@ ], "authors": [ { - "name": "Eduardo Gulias Davis" - } - ], - "description": "A library for validating emails", - "homepage": "https://github.com/egulias/EmailValidator", - "keywords": [ - "email", - "emailvalidation", - "emailvalidator", - "validation", - "validator" - ] + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "Common Library for Doctrine projects", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "annotations", + "collections", + "eventmanager", + "persistence", + "spl" + ] + }, + { + "name": "easyrdf/easyrdf", + "version": "0.9.1", + "version_normalized": "0.9.1.0", + "source": { + "type": "git", + "url": "https://github.com/njh/easyrdf.git", + "reference": "acd09dfe0555fbcfa254291e433c45fdd4652566" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/njh/easyrdf/zipball/acd09dfe0555fbcfa254291e433c45fdd4652566", + "reference": "acd09dfe0555fbcfa254291e433c45fdd4652566", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "ext-pcre": "*", + "php": ">=5.2.8" + }, + "require-dev": { + "phpunit/phpunit": "~3.5", + "sami/sami": "~1.4", + "squizlabs/php_codesniffer": "~1.4.3" + }, + "suggest": { + "ml/json-ld": "~1.0" + }, + "time": "2015-02-27 09:45:49", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-0": { + "EasyRdf_": "lib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nicholas Humfrey", + "email": "njh@aelius.com", + "homepage": "http://www.aelius.com/njh/", + "role": "Developer" + }, + { + "name": "Alexey Zakhlestin", + "email": "indeyets@gmail.com", + "role": "Developer" + } + ], + "description": "EasyRdf is a PHP library designed to make it easy to consume and produce RDF.", + "homepage": "http://www.easyrdf.org/", + "keywords": [ + "Linked Data", + "RDF", + "Semantic Web", + "Turtle", + "rdfa", + "sparql" + ] + }, + { + "name": "egulias/email-validator", + "version": "1.2.9", + "version_normalized": "1.2.9.0", + "source": { + "type": "git", + "url": "https://github.com/egulias/EmailValidator.git", + "reference": "af864423f50ea59f96c87bb1eae147a70bcf67a1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/af864423f50ea59f96c87bb1eae147a70bcf67a1", + "reference": "af864423f50ea59f96c87bb1eae147a70bcf67a1", + "shasum": "" + }, + "require": { + "doctrine/lexer": "~1.0,>=1.0.1", + "php": ">= 5.3.3" + }, + "require-dev": { + "phpunit/phpunit": "~4.4", + "satooshi/php-coveralls": "dev-master" + }, + "time": "2015-06-22 21:07:51", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-0": { + "Egulias\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Eduardo Gulias Davis" + } + ], + "description": "A library for validating emails", + "homepage": "https://github.com/egulias/EmailValidator", + "keywords": [ + "email", + "emailvalidation", + "emailvalidator", + "validation", + "validator" + ] }, { "name": "guzzlehttp/promises", @@ -527,6 +793,57 @@ "promise" ] }, + { + "name": "psr/http-message", + "version": "1.0", + "version_normalized": "1.0.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message.git", + "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", + "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2015-05-04 20:22:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP messages", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ] + }, { "name": "guzzlehttp/psr7", "version": "1.2.0", @@ -588,42 +905,40 @@ ] }, { - "name": "doctrine/common", - "version": "v2.5.1", - "version_normalized": "2.5.1.0", + "name": "masterminds/html5", + "version": "2.1.2", + "version_normalized": "2.1.2.0", "source": { "type": "git", - "url": "https://github.com/doctrine/common.git", - "reference": "0009b8f0d4a917aabc971fb089eba80e872f83f9" + "url": "https://github.com/Masterminds/html5-php.git", + "reference": "8f782e0f01a6e33a319bdc8f6de9cfd6569979a4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/0009b8f0d4a917aabc971fb089eba80e872f83f9", - "reference": "0009b8f0d4a917aabc971fb089eba80e872f83f9", + "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/8f782e0f01a6e33a319bdc8f6de9cfd6569979a4", + "reference": "8f782e0f01a6e33a319bdc8f6de9cfd6569979a4", "shasum": "" }, "require": { - "doctrine/annotations": "1.*", - "doctrine/cache": "1.*", - "doctrine/collections": "1.*", - "doctrine/inflector": "1.*", - "doctrine/lexer": "1.*", - "php": ">=5.3.2" + "ext-libxml": "*", + "php": ">=5.3.0" }, "require-dev": { - "phpunit/phpunit": "~3.7" + "phpunit/phpunit": "4.*", + "sami/sami": "~2.0", + "satooshi/php-coveralls": "0.6.*" }, - "time": "2015-08-31 13:00:22", + "time": "2015-06-07 08:43:18", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.6.x-dev" + "dev-master": "2.1-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Doctrine\\Common\\": "lib/" + "psr-4": { + "Masterminds\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -632,71 +947,67 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "name": "Matt Butcher", + "email": "technosophos@gmail.com" }, { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" + "name": "Asmir Mustafic", + "email": "goetas@gmail.com" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Matt Farina", + "email": "matt@mattfarina.com" } ], - "description": "Common Library for Doctrine projects", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "collections", - "eventmanager", - "persistence", - "spl" + "description": "An HTML5 parser and serializer.", + "homepage": "http://masterminds.github.io/html5-php", + "keywords": [ + "HTML5", + "dom", + "html", + "parser", + "querypath", + "serializer", + "xml" ] }, { - "name": "doctrine/annotations", - "version": "v1.2.7", - "version_normalized": "1.2.7.0", + "name": "symfony/http-foundation", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535" + "url": "https://github.com/symfony/http-foundation.git", + "reference": "e1509119f164a0d0a940d7d924d693a7a28a5470" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/f25c8aab83e0c3e976fd7d19875f198ccf2f7535", - "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/e1509119f164a0d0a940d7d924d693a7a28a5470", + "reference": "e1509119f164a0d0a940d7d924d693a7a28a5470", "shasum": "" }, "require": { - "doctrine/lexer": "1.*", - "php": ">=5.3.2" + "php": ">=5.3.9" }, "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "4.*" + "symfony/expression-language": "~2.4", + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-08-31 12:32:49", + "time": "2015-09-22 13:49:29", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Doctrine\\Common\\Annotations\\": "lib/" - } + "psr-4": { + "Symfony\\Component\\HttpFoundation\\": "" + }, + "classmap": [ + "Resources/stubs" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -704,70 +1015,38 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "docblock", - "parser" - ] + "description": "Symfony HttpFoundation Component", + "homepage": "https://symfony.com" }, { - "name": "doctrine/instantiator", - "version": "1.0.5", - "version_normalized": "1.0.5.0", + "name": "psr/log", + "version": "1.0.0", + "version_normalized": "1.0.0.0", "source": { "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" + "url": "https://github.com/php-fig/log.git", + "reference": "1.0.0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe0936ee26643249e916849d48e3a51d5f5e278b", + "reference": "1.0.0", "shasum": "" }, - "require": { - "php": ">=5.3,<8.0-DEV" - }, - "require-dev": { - "athletic/athletic": "~0.1.8", - "ext-pdo": "*", - "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~2.0" - }, - "time": "2015-06-14 21:17:01", + "time": "2012-12-21 11:40:51", "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, "installation-source": "dist", "autoload": { - "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + "psr-0": { + "Psr\\Log\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -776,55 +1055,55 @@ ], "authors": [ { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://github.com/doctrine/instantiator", + "description": "Common interface for logging libraries", "keywords": [ - "constructor", - "instantiate" + "log", + "psr", + "psr-3" ] }, { - "name": "doctrine/cache", - "version": "v1.4.2", - "version_normalized": "1.4.2.0", + "name": "symfony/debug", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "8c434000f420ade76a07c64cbe08ca47e5c101ca" + "url": "https://github.com/symfony/debug.git", + "reference": "c79c361bca8e5ada6a47603875a3c964d03b67b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/8c434000f420ade76a07c64cbe08ca47e5c101ca", - "reference": "8c434000f420ade76a07c64cbe08ca47e5c101ca", + "url": "https://api.github.com/repos/symfony/debug/zipball/c79c361bca8e5ada6a47603875a3c964d03b67b1", + "reference": "c79c361bca8e5ada6a47603875a3c964d03b67b1", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": ">=5.3.9", + "psr/log": "~1.0" }, "conflict": { - "doctrine/common": ">2.2,<2.4" + "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" }, "require-dev": { - "phpunit/phpunit": ">=3.7", - "predis/predis": "~1.0", - "satooshi/php-coveralls": "~0.6" + "symfony/class-loader": "~2.2", + "symfony/http-kernel": "~2.3.24|~2.5.9|~2.6,>=2.6.2", + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-08-31 12:36:41", + "time": "2015-09-14 08:41:38", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.5.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Doctrine\\Common\\Cache\\": "lib/" + "psr-4": { + "Symfony\\Component\\Debug\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -833,65 +1112,80 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Caching library offering an object-oriented API for many cache backends", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "cache", - "caching" - ] + "description": "Symfony Debug Component", + "homepage": "https://symfony.com" }, { - "name": "doctrine/collections", - "version": "v1.3.0", - "version_normalized": "1.3.0.0", + "name": "symfony/http-kernel", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a" + "url": "https://github.com/symfony/http-kernel.git", + "reference": "353aa457424262d7d4e4289ea483145921cffcb5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/6c1e4eef75f310ea1b3e30945e9f06e652128b8a", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/353aa457424262d7d4e4289ea483145921cffcb5", + "reference": "353aa457424262d7d4e4289ea483145921cffcb5", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": ">=5.3.9", + "psr/log": "~1.0", + "symfony/debug": "~2.6,>=2.6.2", + "symfony/event-dispatcher": "~2.6,>=2.6.7", + "symfony/http-foundation": "~2.5,>=2.5.4" + }, + "conflict": { + "symfony/config": "<2.7" }, "require-dev": { - "phpunit/phpunit": "~4.0" + "symfony/browser-kit": "~2.3", + "symfony/class-loader": "~2.1", + "symfony/config": "~2.7", + "symfony/console": "~2.3", + "symfony/css-selector": "~2.0,>=2.0.5", + "symfony/dependency-injection": "~2.2", + "symfony/dom-crawler": "~2.0,>=2.0.5", + "symfony/expression-language": "~2.4", + "symfony/finder": "~2.0,>=2.0.5", + "symfony/phpunit-bridge": "~2.7", + "symfony/process": "~2.0,>=2.0.5", + "symfony/routing": "~2.2", + "symfony/stopwatch": "~2.3", + "symfony/templating": "~2.2", + "symfony/translation": "~2.0,>=2.0.5", + "symfony/var-dumper": "~2.6" }, - "time": "2015-04-14 22:21:58", + "suggest": { + "symfony/browser-kit": "", + "symfony/class-loader": "", + "symfony/config": "", + "symfony/console": "", + "symfony/dependency-injection": "", + "symfony/finder": "", + "symfony/var-dumper": "" + }, + "time": "2015-09-25 11:16:52", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Doctrine\\Common\\Collections\\": "lib/" + "psr-4": { + "Symfony\\Component\\HttpKernel\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -900,66 +1194,51 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Collections Abstraction library", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "array", - "collections", - "iterator" - ] + "description": "Symfony HttpKernel Component", + "homepage": "https://symfony.com" }, { - "name": "doctrine/inflector", - "version": "v1.0.1", - "version_normalized": "1.0.1.0", + "name": "stack/builder", + "version": "v1.0.3", + "version_normalized": "1.0.3.0", "source": { "type": "git", - "url": "https://github.com/doctrine/inflector.git", - "reference": "0bcb2e79d8571787f18b7eb036ed3d004908e604" + "url": "https://github.com/stackphp/builder.git", + "reference": "c1f8a4693b55c563405024f708a76ef576c3b276" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/inflector/zipball/0bcb2e79d8571787f18b7eb036ed3d004908e604", - "reference": "0bcb2e79d8571787f18b7eb036ed3d004908e604", + "url": "https://api.github.com/repos/stackphp/builder/zipball/c1f8a4693b55c563405024f708a76ef576c3b276", + "reference": "c1f8a4693b55c563405024f708a76ef576c3b276", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": ">=5.3.0", + "symfony/http-foundation": "~2.1", + "symfony/http-kernel": "~2.1" }, "require-dev": { - "phpunit/phpunit": "4.*" + "silex/silex": "~1.0" }, - "time": "2014-12-20 21:24:13", + "time": "2014-11-23 20:37:11", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" } }, "installation-source": "dist", "autoload": { "psr-0": { - "Doctrine\\Common\\Inflector\\": "lib/" + "Stack": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -968,386 +1247,403 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Igor Wiedler", + "email": "igor@wiedler.ch" } ], - "description": "Common String Manipulations with regard to casing and singular/plural rules.", - "homepage": "http://www.doctrine-project.org", + "description": "Builder for stack middlewares based on HttpKernelInterface.", "keywords": [ - "inflection", - "pluralize", - "singularize", - "string" + "stack" ] }, { - "name": "sebastian/environment", - "version": "1.3.2", - "version_normalized": "1.3.2.0", + "name": "symfony/routing", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44" + "url": "https://github.com/symfony/routing.git", + "reference": "6c5fae83efa20baf166fcf4582f57094e9f60f16" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6324c907ce7a52478eeeaede764f48733ef5ae44", - "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44", + "url": "https://api.github.com/repos/symfony/routing/zipball/6c5fae83efa20baf166fcf4582f57094e9f60f16", + "reference": "6c5fae83efa20baf166fcf4582f57094e9f60f16", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.9" + }, + "conflict": { + "symfony/config": "<2.7" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "doctrine/annotations": "~1.0", + "doctrine/common": "~2.2", + "psr/log": "~1.0", + "symfony/config": "~2.7", + "symfony/expression-language": "~2.4", + "symfony/http-foundation": "~2.3", + "symfony/phpunit-bridge": "~2.7", + "symfony/yaml": "~2.0,>=2.0.5" }, - "time": "2015-08-03 06:14:51", + "suggest": { + "doctrine/annotations": "For using the annotation loader", + "symfony/config": "For using the all-in-one router or any loader", + "symfony/expression-language": "For using expression matching", + "symfony/yaml": "For using the YAML loader" + }, + "time": "2015-09-14 14:14:09", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Symfony\\Component\\Routing\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", + "description": "Symfony Routing Component", + "homepage": "https://symfony.com", "keywords": [ - "Xdebug", - "environment", - "hhvm" + "router", + "routing", + "uri", + "url" ] }, { - "name": "phpunit/php-timer", - "version": "1.0.7", - "version_normalized": "1.0.7.0", + "name": "symfony-cmf/routing", + "version": "1.3.0", + "version_normalized": "1.3.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b" + "url": "https://github.com/symfony-cmf/Routing.git", + "reference": "8e87981d72c6930a27585dcd3119f3199f6cb2a6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3e82f4e9fc92665fafd9157568e4dcb01d014e5b", - "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b", + "url": "https://api.github.com/repos/symfony-cmf/Routing/zipball/8e87981d72c6930a27585dcd3119f3199f6cb2a6", + "reference": "8e87981d72c6930a27585dcd3119f3199f6cb2a6", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.3", + "psr/log": "~1.0", + "symfony/http-kernel": "~2.2", + "symfony/routing": "~2.2" }, - "time": "2015-06-21 08:01:12", + "require-dev": { + "symfony/config": "~2.2", + "symfony/dependency-injection": "~2.0@stable", + "symfony/event-dispatcher": "~2.1" + }, + "suggest": { + "symfony/event-dispatcher": "DynamicRouter can optionally trigger an event at the start of matching. Minimal version ~2.1" + }, + "time": "2014-10-20 20:55:17", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.3-dev" + } + }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Symfony\\Cmf\\Component\\Routing\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "name": "Symfony CMF Community", + "homepage": "https://github.com/symfony-cmf/Routing/contributors" } ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", + "description": "Extends the Symfony2 routing component for dynamic routes and chaining several routers", + "homepage": "http://cmf.symfony.com", "keywords": [ - "timer" + "database", + "routing" ] }, { - "name": "easyrdf/easyrdf", - "version": "0.9.1", - "version_normalized": "0.9.1.0", + "name": "symfony/class-loader", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/njh/easyrdf.git", - "reference": "acd09dfe0555fbcfa254291e433c45fdd4652566" + "url": "https://github.com/symfony/class-loader.git", + "reference": "d957ea6295d7016e20d7eff33a6c1deef819c0d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/njh/easyrdf/zipball/acd09dfe0555fbcfa254291e433c45fdd4652566", - "reference": "acd09dfe0555fbcfa254291e433c45fdd4652566", + "url": "https://api.github.com/repos/symfony/class-loader/zipball/d957ea6295d7016e20d7eff33a6c1deef819c0d4", + "reference": "d957ea6295d7016e20d7eff33a6c1deef819c0d4", "shasum": "" }, "require": { - "ext-mbstring": "*", - "ext-pcre": "*", - "php": ">=5.2.8" + "php": ">=5.3.9" }, "require-dev": { - "phpunit/phpunit": "~3.5", - "sami/sami": "~1.4", - "squizlabs/php_codesniffer": "~1.4.3" - }, - "suggest": { - "ml/json-ld": "~1.0" + "symfony/finder": "~2.0,>=2.0.5", + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-02-27 09:45:49", + "time": "2015-08-26 17:56:37", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev" + } + }, "installation-source": "dist", "autoload": { - "psr-0": { - "EasyRdf_": "lib/" + "psr-4": { + "Symfony\\Component\\ClassLoader\\": "" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Nicholas Humfrey", - "email": "njh@aelius.com", - "homepage": "http://www.aelius.com/njh/", - "role": "Developer" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Alexey Zakhlestin", - "email": "indeyets@gmail.com", - "role": "Developer" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "EasyRdf is a PHP library designed to make it easy to consume and produce RDF.", - "homepage": "http://www.easyrdf.org/", - "keywords": [ - "Linked Data", - "RDF", - "Semantic Web", - "Turtle", - "rdfa", - "sparql" - ] + "description": "Symfony ClassLoader Component", + "homepage": "https://symfony.com" }, { - "name": "zendframework/zend-escaper", - "version": "2.5.1", - "version_normalized": "2.5.1.0", - "source": { + "name": "symfony/console", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", + "source": { "type": "git", - "url": "https://github.com/zendframework/zend-escaper.git", - "reference": "a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73" + "url": "https://github.com/symfony/console.git", + "reference": "06cb17c013a82f94a3d840682b49425cd00a2161" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-escaper/zipball/a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73", - "reference": "a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73", + "url": "https://api.github.com/repos/symfony/console/zipball/06cb17c013a82f94a3d840682b49425cd00a2161", + "reference": "06cb17c013a82f94a3d840682b49425cd00a2161", "shasum": "" }, "require": { - "php": ">=5.3.23" + "php": ">=5.3.9" }, "require-dev": { - "fabpot/php-cs-fixer": "1.7.*", - "phpunit/phpunit": "~4.0" + "psr/log": "~1.0", + "symfony/event-dispatcher": "~2.1", + "symfony/phpunit-bridge": "~2.7", + "symfony/process": "~2.1" }, - "time": "2015-06-03 14:05:37", + "suggest": { + "psr/log": "For using the console logger", + "symfony/event-dispatcher": "", + "symfony/process": "" + }, + "time": "2015-09-25 08:32:23", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.5-dev", - "dev-develop": "2.6-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Zend\\Escaper\\": "src/" + "Symfony\\Component\\Console\\": "" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], - "homepage": "https://github.com/zendframework/zend-escaper", - "keywords": [ - "escaper", - "zf2" - ] + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Console Component", + "homepage": "https://symfony.com" }, { - "name": "zendframework/zend-feed", - "version": "2.5.2", - "version_normalized": "2.5.2.0", + "name": "symfony/dependency-injection", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/zendframework/zend-feed.git", - "reference": "0661345b82b51428619e05d3aadd3de65b57fa54" + "url": "https://github.com/symfony/dependency-injection.git", + "reference": "422c3819b110f610d79c6f1dc38af23787dc790e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-feed/zipball/0661345b82b51428619e05d3aadd3de65b57fa54", - "reference": "0661345b82b51428619e05d3aadd3de65b57fa54", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/422c3819b110f610d79c6f1dc38af23787dc790e", + "reference": "422c3819b110f610d79c6f1dc38af23787dc790e", "shasum": "" }, "require": { - "php": ">=5.5", - "zendframework/zend-escaper": "~2.5", - "zendframework/zend-stdlib": "~2.5" + "php": ">=5.3.9" + }, + "conflict": { + "symfony/expression-language": "<2.6" }, "require-dev": { - "fabpot/php-cs-fixer": "1.7.*", - "phpunit/phpunit": "~4.0", - "zendframework/zend-cache": "~2.5", - "zendframework/zend-db": "~2.5", - "zendframework/zend-http": "~2.5", - "zendframework/zend-servicemanager": "~2.5", - "zendframework/zend-validator": "~2.5" + "symfony/config": "~2.2", + "symfony/expression-language": "~2.6", + "symfony/phpunit-bridge": "~2.7", + "symfony/yaml": "~2.1" }, "suggest": { - "zendframework/zend-cache": "Zend\\Cache component", - "zendframework/zend-db": "Zend\\Db component", - "zendframework/zend-http": "Zend\\Http for PubSubHubbub, and optionally for use with Zend\\Feed\\Reader", - "zendframework/zend-servicemanager": "Zend\\ServiceManager component, for default/recommended ExtensionManager implementations", - "zendframework/zend-validator": "Zend\\Validator component" + "symfony/config": "", + "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them", + "symfony/yaml": "" }, - "time": "2015-08-04 21:39:18", + "time": "2015-09-15 08:30:42", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.5-dev", - "dev-develop": "2.6-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Zend\\Feed\\": "src/" + "Symfony\\Component\\DependencyInjection\\": "" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], - "description": "provides functionality for consuming RSS and Atom feeds", - "homepage": "https://github.com/zendframework/zend-feed", - "keywords": [ - "feed", - "zf2" - ] + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony DependencyInjection Component", + "homepage": "https://symfony.com" }, { - "name": "zendframework/zend-diactoros", - "version": "1.1.3", - "version_normalized": "1.1.3.0", + "name": "symfony/process", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/zendframework/zend-diactoros.git", - "reference": "e2f5c12916c74da384058d0dfbc7fbc0b03d1181" + "url": "https://github.com/symfony/process.git", + "reference": "b27c8e317922cd3cdd3600850273cf6b82b2e8e9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-diactoros/zipball/e2f5c12916c74da384058d0dfbc7fbc0b03d1181", - "reference": "e2f5c12916c74da384058d0dfbc7fbc0b03d1181", + "url": "https://api.github.com/repos/symfony/process/zipball/b27c8e317922cd3cdd3600850273cf6b82b2e8e9", + "reference": "b27c8e317922cd3cdd3600850273cf6b82b2e8e9", "shasum": "" }, "require": { - "php": ">=5.4", - "psr/http-message": "~1.0" - }, - "provide": { - "psr/http-message-implementation": "~1.0.0" + "php": ">=5.3.9" }, "require-dev": { - "phpunit/phpunit": "~4.6", - "squizlabs/php_codesniffer": "^2.3.1" + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-08-10 20:04:20", + "time": "2015-09-19 19:59:23", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev", - "dev-develop": "1.1-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Zend\\Diactoros\\": "src/" + "Symfony\\Component\\Process\\": "" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-2-Clause" + "MIT" ], - "description": "PSR HTTP Message implementations", - "homepage": "https://github.com/zendframework/zend-diactoros", - "keywords": [ - "http", - "psr", - "psr-7" - ] + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Process Component", + "homepage": "https://symfony.com" }, { - "name": "fabpot/goutte", - "version": "v3.1.1", - "version_normalized": "3.1.1.0", + "name": "symfony/psr-http-message-bridge", + "version": "v0.2", + "version_normalized": "0.2.0.0", "source": { "type": "git", - "url": "https://github.com/FriendsOfPHP/Goutte.git", - "reference": "751a3dc5c4d86ec3e97c9f27133ef9694d9243cc" + "url": "https://github.com/symfony/psr-http-message-bridge.git", + "reference": "dc7e308e1dc2898a46776e2221a643cb08315453" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/Goutte/zipball/751a3dc5c4d86ec3e97c9f27133ef9694d9243cc", - "reference": "751a3dc5c4d86ec3e97c9f27133ef9694d9243cc", + "url": "https://api.github.com/repos/symfony/psr-http-message-bridge/zipball/dc7e308e1dc2898a46776e2221a643cb08315453", + "reference": "dc7e308e1dc2898a46776e2221a643cb08315453", "shasum": "" }, "require": { - "guzzlehttp/guzzle": "^6.0", - "php": ">=5.5.0", - "symfony/browser-kit": "~2.1", - "symfony/css-selector": "~2.1", - "symfony/dom-crawler": "~2.1" + "php": ">=5.3.3", + "psr/http-message": "~1.0", + "symfony/http-foundation": "~2.3|~3.0" }, - "time": "2015-08-29 16:16:56", - "type": "application", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev" - } + "require-dev": { + "symfony/phpunit-bridge": "~2.7|~3.0" + }, + "suggest": { + "zendframework/zend-diactoros": "To use the Zend Diactoros factory" }, + "time": "2015-05-29 17:57:12", + "type": "symfony-bridge", "installation-source": "dist", "autoload": { "psr-4": { - "Goutte\\": "Goutte" + "Symfony\\Bridge\\PsrHttpMessage\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -1355,51 +1651,67 @@ "MIT" ], "authors": [ + { + "name": "Symfony Community", + "homepage": "http://symfony.com/contributors" + }, { "name": "Fabien Potencier", "email": "fabien@symfony.com" } ], - "description": "A simple PHP Web Scraper", - "homepage": "https://github.com/FriendsOfPHP/Goutte", + "description": "PSR HTTP message bridge", + "homepage": "http://symfony.com", "keywords": [ - "scraper" + "http", + "http-message", + "psr-7" ] }, { - "name": "phpspec/prophecy", - "version": "v1.5.0", - "version_normalized": "1.5.0.0", + "name": "symfony/serializer", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7" + "url": "https://github.com/symfony/serializer.git", + "reference": "baf24f86a8656eea9c80988f332e51461bfcb67f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4745ded9307786b730d7a60df5cb5a6c43cf95f7", - "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7", + "url": "https://api.github.com/repos/symfony/serializer/zipball/baf24f86a8656eea9c80988f332e51461bfcb67f", + "reference": "baf24f86a8656eea9c80988f332e51461bfcb67f", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "phpdocumentor/reflection-docblock": "~2.0", - "sebastian/comparator": "~1.1" + "php": ">=5.3.9" }, "require-dev": { - "phpspec/phpspec": "~2.0" + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.0", + "symfony/config": "~2.2", + "symfony/phpunit-bridge": "~2.7", + "symfony/property-access": "~2.3", + "symfony/yaml": "~2.0,>=2.0.5" }, - "time": "2015-08-13 10:07:40", + "suggest": { + "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", + "doctrine/cache": "For using the default cached annotation reader and metadata cache.", + "symfony/config": "For using the XML mapping loader.", + "symfony/property-access": "For using the ObjectNormalizer.", + "symfony/yaml": "For using the default YAML mapping loader." + }, + "time": "2015-08-31 16:44:53", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Prophecy\\": "src/" + "psr-4": { + "Symfony\\Component\\Serializer\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -1408,153 +1720,186 @@ ], "authors": [ { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ] + "description": "Symfony Serializer Component", + "homepage": "https://symfony.com" }, { - "name": "phpunit/php-file-iterator", - "version": "1.4.1", - "version_normalized": "1.4.1.0", + "name": "symfony/translation", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0" + "url": "https://github.com/symfony/translation.git", + "reference": "485877661835e188cd78345c6d4eef1290d17571" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/6150bf2c35d3fc379e50c7602b75caceaa39dbf0", - "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0", + "url": "https://api.github.com/repos/symfony/translation/zipball/485877661835e188cd78345c6d4eef1290d17571", + "reference": "485877661835e188cd78345c6d4eef1290d17571", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.9" }, - "time": "2015-06-21 13:08:43", + "conflict": { + "symfony/config": "<2.7" + }, + "require-dev": { + "psr/log": "~1.0", + "symfony/config": "~2.7", + "symfony/intl": "~2.4", + "symfony/phpunit-bridge": "~2.7", + "symfony/yaml": "~2.2" + }, + "suggest": { + "psr/log": "To use logging capability in translator", + "symfony/config": "", + "symfony/yaml": "" + }, + "time": "2015-09-06 08:36:38", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Symfony\\Component\\Translation\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "FilterIterator implementation that filters files based on a list of suffixes.", - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" - ] + "description": "Symfony Translation Component", + "homepage": "https://symfony.com" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", - "version_normalized": "1.2.1.0", + "name": "symfony/validator", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/symfony/validator.git", + "reference": "b359dc71e253ce6eb69eefbd5088032241e7a66f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/symfony/validator/zipball/b359dc71e253ce6eb69eefbd5088032241e7a66f", + "reference": "b359dc71e253ce6eb69eefbd5088032241e7a66f", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.3.9", + "symfony/translation": "~2.4" }, - "time": "2015-06-21 13:50:34", + "require-dev": { + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.0", + "egulias/email-validator": "~1.2,>=1.2.1", + "symfony/config": "~2.2", + "symfony/expression-language": "~2.4", + "symfony/http-foundation": "~2.1", + "symfony/intl": "~2.4", + "symfony/phpunit-bridge": "~2.7", + "symfony/property-access": "~2.3", + "symfony/yaml": "~2.0,>=2.0.5" + }, + "suggest": { + "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", + "doctrine/cache": "For using the default cached annotation reader and metadata cache.", + "egulias/email-validator": "Strict (RFC compliant) email validation", + "symfony/config": "", + "symfony/expression-language": "For using the 2.4 Expression validator", + "symfony/http-foundation": "", + "symfony/intl": "", + "symfony/property-access": "For using the 2.4 Validator API", + "symfony/yaml": "" + }, + "time": "2015-09-23 11:13:27", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev" + } + }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Symfony\\Component\\Validator\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" - ] + "description": "Symfony Validator Component", + "homepage": "https://symfony.com" }, { - "name": "sebastian/comparator", - "version": "1.2.0", - "version_normalized": "1.2.0.0", + "name": "twig/twig", + "version": "v1.22.2", + "version_normalized": "1.22.2.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "937efb279bd37a375bcadf584dec0726f84dbf22" + "url": "https://github.com/twigphp/Twig.git", + "reference": "79249fc8c9ff62e41e217e0c630e2e00bcadda6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/937efb279bd37a375bcadf584dec0726f84dbf22", - "reference": "937efb279bd37a375bcadf584dec0726f84dbf22", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/79249fc8c9ff62e41e217e0c630e2e00bcadda6a", + "reference": "79249fc8c9ff62e41e217e0c630e2e00bcadda6a", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/diff": "~1.2", - "sebastian/exporter": "~1.2" + "php": ">=5.2.7" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "symfony/debug": "~2.7", + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-07-26 15:48:44", + "time": "2015-09-22 13:59:32", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "1.22-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-0": { + "Twig_": "lib/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1562,224 +1907,392 @@ ], "authors": [ { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com", + "homepage": "http://fabien.potencier.org", + "role": "Lead Developer" }, { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" + "name": "Armin Ronacher", + "email": "armin.ronacher@active-4.com", + "role": "Project Founder" }, { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Twig Team", + "homepage": "http://twig.sensiolabs.org/contributors", + "role": "Contributors" } ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", + "description": "Twig, the flexible, fast, and secure template language for PHP", + "homepage": "http://twig.sensiolabs.org", "keywords": [ - "comparator", - "compare", - "equality" + "templating" ] }, { - "name": "sebastian/exporter", - "version": "1.2.1", - "version_normalized": "1.2.1.0", + "name": "zendframework/zend-diactoros", + "version": "1.1.3", + "version_normalized": "1.1.3.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "7ae5513327cb536431847bcc0c10edba2701064e" + "url": "https://github.com/zendframework/zend-diactoros.git", + "reference": "e2f5c12916c74da384058d0dfbc7fbc0b03d1181" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/7ae5513327cb536431847bcc0c10edba2701064e", - "reference": "7ae5513327cb536431847bcc0c10edba2701064e", + "url": "https://api.github.com/repos/zendframework/zend-diactoros/zipball/e2f5c12916c74da384058d0dfbc7fbc0b03d1181", + "reference": "e2f5c12916c74da384058d0dfbc7fbc0b03d1181", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/recursion-context": "~1.0" + "php": ">=5.4", + "psr/http-message": "~1.0" + }, + "provide": { + "psr/http-message-implementation": "~1.0.0" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "~4.6", + "squizlabs/php_codesniffer": "^2.3.1" }, - "time": "2015-06-21 07:55:53", + "time": "2015-08-10 20:04:20", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "1.0-dev", + "dev-develop": "1.1-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Zend\\Diactoros\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "BSD-2-Clause" ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" + "description": "PSR HTTP Message implementations", + "homepage": "https://github.com/zendframework/zend-diactoros", + "keywords": [ + "http", + "psr", + "psr-7" + ] + }, + { + "name": "zendframework/zend-stdlib", + "version": "2.7.3", + "version_normalized": "2.7.3.0", + "source": { + "type": "git", + "url": "https://github.com/zendframework/zend-stdlib.git", + "reference": "8ac0c77ff567fcf49b58689ee3bfa7595be102bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/zendframework/zend-stdlib/zipball/8ac0c77ff567fcf49b58689ee3bfa7595be102bc", + "reference": "8ac0c77ff567fcf49b58689ee3bfa7595be102bc", + "shasum": "" + }, + "require": { + "php": ">=5.5", + "zendframework/zend-hydrator": "~1.0" + }, + "require-dev": { + "athletic/athletic": "~0.1", + "fabpot/php-cs-fixer": "1.7.*", + "phpunit/phpunit": "~4.0", + "zendframework/zend-config": "~2.5", + "zendframework/zend-eventmanager": "~2.5", + "zendframework/zend-filter": "~2.5", + "zendframework/zend-inputfilter": "~2.5", + "zendframework/zend-serializer": "~2.5", + "zendframework/zend-servicemanager": "~2.5" + }, + "suggest": { + "zendframework/zend-eventmanager": "To support aggregate hydrator usage", + "zendframework/zend-filter": "To support naming strategy hydrator usage", + "zendframework/zend-serializer": "Zend\\Serializer component", + "zendframework/zend-servicemanager": "To support hydrator plugin manager usage" + }, + "time": "2015-09-25 04:06:33", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev", + "dev-develop": "2.8-dev" } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Zend\\Stdlib\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" ], - "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", + "homepage": "https://github.com/zendframework/zend-stdlib", "keywords": [ - "export", - "exporter" + "stdlib", + "zf2" ] }, { - "name": "sebastian/recursion-context", - "version": "1.0.1", - "version_normalized": "1.0.1.0", + "name": "zendframework/zend-hydrator", + "version": "1.0.0", + "version_normalized": "1.0.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "994d4a811bafe801fb06dccbee797863ba2792ba" + "url": "https://github.com/zendframework/zend-hydrator.git", + "reference": "f3ed8b833355140350bbed98d8a7b8b66875903f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/994d4a811bafe801fb06dccbee797863ba2792ba", - "reference": "994d4a811bafe801fb06dccbee797863ba2792ba", + "url": "https://api.github.com/repos/zendframework/zend-hydrator/zipball/f3ed8b833355140350bbed98d8a7b8b66875903f", + "reference": "f3ed8b833355140350bbed98d8a7b8b66875903f", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=5.5", + "zendframework/zend-stdlib": "^2.5.1" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "~4.0", + "squizlabs/php_codesniffer": "^2.0@dev", + "zendframework/zend-eventmanager": "^2.5.1", + "zendframework/zend-filter": "^2.5.1", + "zendframework/zend-inputfilter": "^2.5.1", + "zendframework/zend-serializer": "^2.5.1", + "zendframework/zend-servicemanager": "^2.5.1" }, - "time": "2015-06-21 08:04:50", + "suggest": { + "zendframework/zend-eventmanager": "^2.5.1, to support aggregate hydrator usage", + "zendframework/zend-filter": "^2.5.1, to support naming strategy hydrator usage", + "zendframework/zend-serializer": "^2.5.1, to use the SerializableStrategy", + "zendframework/zend-servicemanager": "^2.5.1, to support hydrator plugin manager usage" + }, + "time": "2015-09-17 14:06:43", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev", + "dev-develop": "1.1-dev" } }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Zend\\Hydrator\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ "BSD-3-Clause" ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" + "homepage": "https://github.com/zendframework/zend-hydrator", + "keywords": [ + "hydrator", + "zf2" + ] + }, + { + "name": "zendframework/zend-escaper", + "version": "2.5.1", + "version_normalized": "2.5.1.0", + "source": { + "type": "git", + "url": "https://github.com/zendframework/zend-escaper.git", + "reference": "a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/zendframework/zend-escaper/zipball/a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73", + "reference": "a4b227d8a477f4e7e9073f8e0a7ae7dbd3104a73", + "shasum": "" + }, + "require": { + "php": ">=5.3.23" + }, + "require-dev": { + "fabpot/php-cs-fixer": "1.7.*", + "phpunit/phpunit": "~4.0" + }, + "time": "2015-06-03 14:05:37", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.5-dev", + "dev-develop": "2.6-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Zend\\Escaper\\": "src/" } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context" + "homepage": "https://github.com/zendframework/zend-escaper", + "keywords": [ + "escaper", + "zf2" + ] }, { - "name": "sebastian/version", - "version": "1.0.6", - "version_normalized": "1.0.6.0", + "name": "zendframework/zend-feed", + "version": "2.5.2", + "version_normalized": "2.5.2.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6" + "url": "https://github.com/zendframework/zend-feed.git", + "reference": "0661345b82b51428619e05d3aadd3de65b57fa54" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", - "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", + "url": "https://api.github.com/repos/zendframework/zend-feed/zipball/0661345b82b51428619e05d3aadd3de65b57fa54", + "reference": "0661345b82b51428619e05d3aadd3de65b57fa54", "shasum": "" }, - "time": "2015-06-21 13:59:46", + "require": { + "php": ">=5.5", + "zendframework/zend-escaper": "~2.5", + "zendframework/zend-stdlib": "~2.5" + }, + "require-dev": { + "fabpot/php-cs-fixer": "1.7.*", + "phpunit/phpunit": "~4.0", + "zendframework/zend-cache": "~2.5", + "zendframework/zend-db": "~2.5", + "zendframework/zend-http": "~2.5", + "zendframework/zend-servicemanager": "~2.5", + "zendframework/zend-validator": "~2.5" + }, + "suggest": { + "zendframework/zend-cache": "Zend\\Cache component", + "zendframework/zend-db": "Zend\\Db component", + "zendframework/zend-http": "Zend\\Http for PubSubHubbub, and optionally for use with Zend\\Feed\\Reader", + "zendframework/zend-servicemanager": "Zend\\ServiceManager component, for default/recommended ExtensionManager implementations", + "zendframework/zend-validator": "Zend\\Validator component" + }, + "time": "2015-08-04 21:39:18", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.5-dev", + "dev-develop": "2.6-dev" + } + }, "installation-source": "dist", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Zend\\Feed\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ "BSD-3-Clause" ], + "description": "provides functionality for consuming RSS and Atom feeds", + "homepage": "https://github.com/zendframework/zend-feed", + "keywords": [ + "feed", + "zf2" + ] + }, + { + "name": "symfony/dom-crawler", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/dom-crawler.git", + "reference": "2e185ca136399f902b948694987e62c80099c052" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/2e185ca136399f902b948694987e62c80099c052", + "reference": "2e185ca136399f902b948694987e62c80099c052", + "shasum": "" + }, + "require": { + "php": ">=5.3.9" + }, + "require-dev": { + "symfony/css-selector": "~2.3", + "symfony/phpunit-bridge": "~2.7" + }, + "suggest": { + "symfony/css-selector": "" + }, + "time": "2015-09-20 21:13:58", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Symfony\\Component\\DomCrawler\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Library that helps with managing the version number of Git-hosted PHP projects", - "homepage": "https://github.com/sebastianbergmann/version" + "description": "Symfony DomCrawler Component", + "homepage": "https://symfony.com" }, { - "name": "stack/builder", - "version": "v1.0.3", - "version_normalized": "1.0.3.0", + "name": "symfony/css-selector", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/stackphp/builder.git", - "reference": "c1f8a4693b55c563405024f708a76ef576c3b276" + "url": "https://github.com/symfony/css-selector.git", + "reference": "abe19cc0429a06be0c133056d1f9859854860970" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/stackphp/builder/zipball/c1f8a4693b55c563405024f708a76ef576c3b276", - "reference": "c1f8a4693b55c563405024f708a76ef576c3b276", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/abe19cc0429a06be0c133056d1f9859854860970", + "reference": "abe19cc0429a06be0c133056d1f9859854860970", "shasum": "" }, "require": { - "php": ">=5.3.0", - "symfony/http-foundation": "~2.1", - "symfony/http-kernel": "~2.1" + "php": ">=5.3.9" }, "require-dev": { - "silex/silex": "~1.0" + "symfony/phpunit-bridge": "~2.7" }, - "time": "2014-11-23 20:37:11", + "time": "2015-09-22 13:49:29", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "Stack": "src" + "psr-4": { + "Symfony\\Component\\CssSelector\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -1788,50 +2301,59 @@ ], "authors": [ { - "name": "Igor Wiedler", - "email": "igor@wiedler.ch" + "name": "Jean-François Simon", + "email": "jeanfrancois.simon@sensiolabs.com" + }, + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Builder for stack middlewares based on HttpKernelInterface.", - "keywords": [ - "stack" - ] + "description": "Symfony CssSelector Component", + "homepage": "https://symfony.com" }, { - "name": "masterminds/html5", - "version": "2.1.2", - "version_normalized": "2.1.2.0", + "name": "symfony/browser-kit", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/Masterminds/html5-php.git", - "reference": "8f782e0f01a6e33a319bdc8f6de9cfd6569979a4" + "url": "https://github.com/symfony/browser-kit.git", + "reference": "277a2457776d4cc25706fbdd9d1e4ab2dac884e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/8f782e0f01a6e33a319bdc8f6de9cfd6569979a4", - "reference": "8f782e0f01a6e33a319bdc8f6de9cfd6569979a4", + "url": "https://api.github.com/repos/symfony/browser-kit/zipball/277a2457776d4cc25706fbdd9d1e4ab2dac884e4", + "reference": "277a2457776d4cc25706fbdd9d1e4ab2dac884e4", "shasum": "" }, "require": { - "ext-libxml": "*", - "php": ">=5.3.0" + "php": ">=5.3.9", + "symfony/dom-crawler": "~2.0,>=2.0.5" }, "require-dev": { - "phpunit/phpunit": "4.*", - "sami/sami": "~2.0", - "satooshi/php-coveralls": "0.6.*" + "symfony/css-selector": "~2.0,>=2.0.5", + "symfony/phpunit-bridge": "~2.7", + "symfony/process": "~2.0,>=2.0.5" }, - "time": "2015-06-07 08:43:18", + "suggest": { + "symfony/process": "" + }, + "time": "2015-09-06 08:36:38", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Masterminds\\": "src" + "Symfony\\Component\\BrowserKit\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -1840,29 +2362,16 @@ ], "authors": [ { - "name": "Matt Butcher", - "email": "technosophos@gmail.com" - }, - { - "name": "Asmir Mustafic", - "email": "goetas@gmail.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Matt Farina", - "email": "matt@mattfarina.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "An HTML5 parser and serializer.", - "homepage": "http://masterminds.github.io/html5-php", - "keywords": [ - "HTML5", - "dom", - "html", - "parser", - "querypath", - "serializer", - "xml" - ] + "description": "Symfony BrowserKit Component", + "homepage": "https://symfony.com" }, { "name": "guzzlehttp/guzzle", @@ -1929,155 +2438,38 @@ ] }, { - "name": "twig/twig", - "version": "v1.22.2", - "version_normalized": "1.22.2.0", + "name": "fabpot/goutte", + "version": "v3.1.1", + "version_normalized": "3.1.1.0", "source": { "type": "git", - "url": "https://github.com/twigphp/Twig.git", - "reference": "79249fc8c9ff62e41e217e0c630e2e00bcadda6a" + "url": "https://github.com/FriendsOfPHP/Goutte.git", + "reference": "751a3dc5c4d86ec3e97c9f27133ef9694d9243cc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/79249fc8c9ff62e41e217e0c630e2e00bcadda6a", - "reference": "79249fc8c9ff62e41e217e0c630e2e00bcadda6a", + "url": "https://api.github.com/repos/FriendsOfPHP/Goutte/zipball/751a3dc5c4d86ec3e97c9f27133ef9694d9243cc", + "reference": "751a3dc5c4d86ec3e97c9f27133ef9694d9243cc", "shasum": "" }, "require": { - "php": ">=5.2.7" - }, - "require-dev": { - "symfony/debug": "~2.7", - "symfony/phpunit-bridge": "~2.7" + "guzzlehttp/guzzle": "^6.0", + "php": ">=5.5.0", + "symfony/browser-kit": "~2.1", + "symfony/css-selector": "~2.1", + "symfony/dom-crawler": "~2.1" }, - "time": "2015-09-22 13:59:32", - "type": "library", + "time": "2015-08-29 16:16:56", + "type": "application", "extra": { "branch-alias": { - "dev-master": "1.22-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-0": { - "Twig_": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com", - "homepage": "http://fabien.potencier.org", - "role": "Lead Developer" - }, - { - "name": "Armin Ronacher", - "email": "armin.ronacher@active-4.com", - "role": "Project Founder" - }, - { - "name": "Twig Team", - "homepage": "http://twig.sensiolabs.org/contributors", - "role": "Contributors" + "dev-master": "3.1-dev" } - ], - "description": "Twig, the flexible, fast, and secure template language for PHP", - "homepage": "http://twig.sensiolabs.org", - "keywords": [ - "templating" - ] - }, - { - "name": "wikimedia/composer-merge-plugin", - "version": "dev-master", - "version_normalized": "9999999-dev", - "source": { - "type": "git", - "url": "https://github.com/wikimedia/composer-merge-plugin.git", - "reference": "47bb3388cfeae41a38087ac8465a7d08fa92ea2e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/47bb3388cfeae41a38087ac8465a7d08fa92ea2e", - "reference": "47bb3388cfeae41a38087ac8465a7d08fa92ea2e", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^1.0", - "php": ">=5.3.2" - }, - "require-dev": { - "composer/composer": "1.0.*@dev", - "jakub-onderka/php-parallel-lint": "~0.8", - "phpspec/prophecy-phpunit": "~1.0", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~2.1.0" - }, - "time": "2015-09-22 21:14:25", - "type": "composer-plugin", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - }, - "class": "Wikimedia\\Composer\\MergePlugin" }, "installation-source": "dist", "autoload": { "psr-4": { - "Wikimedia\\Composer\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bryan Davis", - "email": "bd808@wikimedia.org" - } - ], - "description": "Composer plugin to merge multiple composer.json files" - }, - { - "name": "composer/installers", - "version": "v1.0.21", - "version_normalized": "1.0.21.0", - "source": { - "type": "git", - "url": "https://github.com/composer/installers.git", - "reference": "d64e23fce42a4063d63262b19b8e7c0f3b5e4c45" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/installers/zipball/d64e23fce42a4063d63262b19b8e7c0f3b5e4c45", - "reference": "d64e23fce42a4063d63262b19b8e7c0f3b5e4c45", - "shasum": "" - }, - "replace": { - "roundcube/plugin-installer": "*", - "shama/baton": "*" - }, - "require-dev": { - "composer/composer": "1.0.*@dev", - "phpunit/phpunit": "4.1.*" - }, - "time": "2015-02-18 17:17:01", - "type": "composer-installer", - "extra": { - "class": "Composer\\Installers\\Installer", - "branch-alias": { - "dev-master": "1.0-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-0": { - "Composer\\Installers\\": "src/" + "Goutte\\": "Goutte" } }, "notification-url": "https://packagist.org/downloads/", @@ -2086,58 +2478,14 @@ ], "authors": [ { - "name": "Kyle Robinson Young", - "email": "kyle@dontkry.com", - "homepage": "https://github.com/shama" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" } ], - "description": "A multi-framework Composer library installer", - "homepage": "http://composer.github.com/installers/", + "description": "A simple PHP Web Scraper", + "homepage": "https://github.com/FriendsOfPHP/Goutte", "keywords": [ - "Craft", - "Dolibarr", - "Hurad", - "MODX Evo", - "OXID", - "SMF", - "Thelia", - "WolfCMS", - "agl", - "aimeos", - "annotatecms", - "bitrix", - "cakephp", - "chef", - "codeigniter", - "concrete5", - "croogo", - "dokuwiki", - "drupal", - "elgg", - "fuelphp", - "grav", - "installer", - "joomla", - "kohana", - "laravel", - "lithium", - "magento", - "mako", - "mediawiki", - "modulework", - "moodle", - "phpbb", - "piwik", - "ppi", - "puppet", - "roundcube", - "shopware", - "silverstripe", - "symfony", - "typo3", - "wordpress", - "zend", - "zikula" + "scraper" ] }, { @@ -2316,325 +2664,91 @@ ] }, { - "name": "phpunit/phpunit-mock-objects", - "version": "2.3.8", - "version_normalized": "2.3.8.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/ac8e7a3db35738d56ee9a76e78a4e03d97628983", - "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.0.2", - "php": ">=5.3.3", - "phpunit/php-text-template": "~1.2", - "sebastian/exporter": "~1.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.4" - }, - "suggest": { - "ext-soap": "*" - }, - "time": "2015-10-02 06:51:40", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Mock Object library for PHPUnit", - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", - "keywords": [ - "mock", - "xunit" - ] - }, - { - "name": "phpunit/php-token-stream", - "version": "1.4.8", - "version_normalized": "1.4.8.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", - "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.2" - }, - "time": "2015-09-15 10:49:45", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ] - }, - { - "name": "symfony/class-loader", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/class-loader.git", - "reference": "d957ea6295d7016e20d7eff33a6c1deef819c0d4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/class-loader/zipball/d957ea6295d7016e20d7eff33a6c1deef819c0d4", - "reference": "d957ea6295d7016e20d7eff33a6c1deef819c0d4", - "shasum": "" - }, - "require": { - "php": ">=5.3.9" - }, - "require-dev": { - "symfony/finder": "~2.0,>=2.0.5", - "symfony/phpunit-bridge": "~2.7" - }, - "time": "2015-08-26 17:56:37", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Symfony\\Component\\ClassLoader\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony ClassLoader Component", - "homepage": "https://symfony.com" - }, - { - "name": "symfony/console", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/console.git", - "reference": "06cb17c013a82f94a3d840682b49425cd00a2161" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/06cb17c013a82f94a3d840682b49425cd00a2161", - "reference": "06cb17c013a82f94a3d840682b49425cd00a2161", - "shasum": "" - }, - "require": { - "php": ">=5.3.9" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/event-dispatcher": "~2.1", - "symfony/phpunit-bridge": "~2.7", - "symfony/process": "~2.1" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "", - "symfony/process": "" - }, - "time": "2015-09-25 08:32:23", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Symfony\\Component\\Console\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Console Component", - "homepage": "https://symfony.com" - }, - { - "name": "symfony/dependency-injection", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "mikey179/vfsStream", + "version": "v1.6.0", + "version_normalized": "1.6.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/dependency-injection.git", - "reference": "422c3819b110f610d79c6f1dc38af23787dc790e" + "url": "https://github.com/mikey179/vfsStream.git", + "reference": "73bcb605b741a7d5044b47592338c633788b0eb7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/422c3819b110f610d79c6f1dc38af23787dc790e", - "reference": "422c3819b110f610d79c6f1dc38af23787dc790e", + "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/73bcb605b741a7d5044b47592338c633788b0eb7", + "reference": "73bcb605b741a7d5044b47592338c633788b0eb7", "shasum": "" }, "require": { - "php": ">=5.3.9" - }, - "conflict": { - "symfony/expression-language": "<2.6" + "php": ">=5.3.0" }, "require-dev": { - "symfony/config": "~2.2", - "symfony/expression-language": "~2.6", - "symfony/phpunit-bridge": "~2.7", - "symfony/yaml": "~2.1" - }, - "suggest": { - "symfony/config": "", - "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them", - "symfony/yaml": "" + "phpunit/phpunit": "~4.5" }, - "time": "2015-09-15 08:30:42", + "time": "2015-10-06 16:59:57", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.6.x-dev" } }, "installation-source": "dist", - "autoload": { - "psr-4": { - "Symfony\\Component\\DependencyInjection\\": "" + "autoload": { + "psr-0": { + "org\\bovigo\\vfs\\": "src/main/php" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Frank Kleine", + "homepage": "http://frankkleine.de/", + "role": "Developer" } ], - "description": "Symfony DependencyInjection Component", - "homepage": "https://symfony.com" + "description": "Virtual file system to mock the real file system in unit tests.", + "homepage": "http://vfs.bovigo.org/" }, { - "name": "symfony/debug", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "phpdocumentor/reflection-docblock", + "version": "2.0.4", + "version_normalized": "2.0.4.0", "source": { "type": "git", - "url": "https://github.com/symfony/debug.git", - "reference": "c79c361bca8e5ada6a47603875a3c964d03b67b1" + "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", + "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/c79c361bca8e5ada6a47603875a3c964d03b67b1", - "reference": "c79c361bca8e5ada6a47603875a3c964d03b67b1", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", + "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", "shasum": "" }, "require": { - "php": ">=5.3.9", - "psr/log": "~1.0" - }, - "conflict": { - "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" + "php": ">=5.3.3" }, "require-dev": { - "symfony/class-loader": "~2.2", - "symfony/http-kernel": "~2.3.24|~2.5.9|~2.6,>=2.6.2", - "symfony/phpunit-bridge": "~2.7" + "phpunit/phpunit": "~4.0" }, - "time": "2015-09-14 08:41:38", + "suggest": { + "dflydev/markdown": "~1.0", + "erusev/parsedown": "~1.0" + }, + "time": "2015-02-03 12:10:50", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "2.0.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Debug\\": "" + "psr-0": { + "phpDocumentor": [ + "src/" + ] } }, "notification-url": "https://packagist.org/downloads/", @@ -2643,103 +2757,84 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Mike van Riel", + "email": "mike.vanriel@naenius.com" } - ], - "description": "Symfony Debug Component", - "homepage": "https://symfony.com" + ] }, { - "name": "symfony/http-foundation", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "phpunit/php-token-stream", + "version": "1.4.8", + "version_normalized": "1.4.8.0", "source": { "type": "git", - "url": "https://github.com/symfony/http-foundation.git", - "reference": "e1509119f164a0d0a940d7d924d693a7a28a5470" + "url": "https://github.com/sebastianbergmann/php-token-stream.git", + "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/e1509119f164a0d0a940d7d924d693a7a28a5470", - "reference": "e1509119f164a0d0a940d7d924d693a7a28a5470", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", + "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", "shasum": "" }, "require": { - "php": ">=5.3.9" + "ext-tokenizer": "*", + "php": ">=5.3.3" }, "require-dev": { - "symfony/expression-language": "~2.4", - "symfony/phpunit-bridge": "~2.7" + "phpunit/phpunit": "~4.2" }, - "time": "2015-09-22 13:49:29", + "time": "2015-09-15 10:49:45", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.4-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\HttpFoundation\\": "" - }, "classmap": [ - "Resources/stubs" + "src/" ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Symfony HttpFoundation Component", - "homepage": "https://symfony.com" + "description": "Wrapper around PHP's tokenizer extension.", + "homepage": "https://github.com/sebastianbergmann/php-token-stream/", + "keywords": [ + "tokenizer" + ] }, { - "name": "symfony/event-dispatcher", + "name": "symfony/yaml", "version": "v2.7.5", "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "ae4dcc2a8d3de98bd794167a3ccda1311597c5d9" + "url": "https://github.com/symfony/yaml.git", + "reference": "31cb2ad0155c95b88ee55fe12bc7ff92232c1770" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/ae4dcc2a8d3de98bd794167a3ccda1311597c5d9", - "reference": "ae4dcc2a8d3de98bd794167a3ccda1311597c5d9", + "url": "https://api.github.com/repos/symfony/yaml/zipball/31cb2ad0155c95b88ee55fe12bc7ff92232c1770", + "reference": "31cb2ad0155c95b88ee55fe12bc7ff92232c1770", "shasum": "" }, "require": { "php": ">=5.3.9" }, "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~2.0,>=2.0.5", - "symfony/dependency-injection": "~2.6", - "symfony/expression-language": "~2.6", - "symfony/phpunit-bridge": "~2.7", - "symfony/stopwatch": "~2.3" - }, - "suggest": { - "symfony/dependency-injection": "", - "symfony/http-kernel": "" + "symfony/phpunit-bridge": "~2.7" }, - "time": "2015-09-22 13:49:29", + "time": "2015-09-14 14:14:09", "type": "library", "extra": { "branch-alias": { @@ -2749,7 +2844,7 @@ "installation-source": "dist", "autoload": { "psr-4": { - "Symfony\\Component\\EventDispatcher\\": "" + "Symfony\\Component\\Yaml\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -2766,555 +2861,473 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony EventDispatcher Component", + "description": "Symfony Yaml Component", "homepage": "https://symfony.com" }, { - "name": "symfony/http-kernel", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/version", + "version": "1.0.6", + "version_normalized": "1.0.6.0", "source": { "type": "git", - "url": "https://github.com/symfony/http-kernel.git", - "reference": "353aa457424262d7d4e4289ea483145921cffcb5" + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/353aa457424262d7d4e4289ea483145921cffcb5", - "reference": "353aa457424262d7d4e4289ea483145921cffcb5", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", + "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", "shasum": "" }, - "require": { - "php": ">=5.3.9", - "psr/log": "~1.0", - "symfony/debug": "~2.6,>=2.6.2", - "symfony/event-dispatcher": "~2.6,>=2.6.7", - "symfony/http-foundation": "~2.5,>=2.5.4" - }, - "conflict": { - "symfony/config": "<2.7" - }, - "require-dev": { - "symfony/browser-kit": "~2.3", - "symfony/class-loader": "~2.1", - "symfony/config": "~2.7", - "symfony/console": "~2.3", - "symfony/css-selector": "~2.0,>=2.0.5", - "symfony/dependency-injection": "~2.2", - "symfony/dom-crawler": "~2.0,>=2.0.5", - "symfony/expression-language": "~2.4", - "symfony/finder": "~2.0,>=2.0.5", - "symfony/phpunit-bridge": "~2.7", - "symfony/process": "~2.0,>=2.0.5", - "symfony/routing": "~2.2", - "symfony/stopwatch": "~2.3", - "symfony/templating": "~2.2", - "symfony/translation": "~2.0,>=2.0.5", - "symfony/var-dumper": "~2.6" - }, - "suggest": { - "symfony/browser-kit": "", - "symfony/class-loader": "", - "symfony/config": "", - "symfony/console": "", - "symfony/dependency-injection": "", - "symfony/finder": "", - "symfony/var-dumper": "" - }, - "time": "2015-09-25 11:16:52", + "time": "2015-06-21 13:59:46", "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev" - } - }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\HttpKernel\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Symfony HttpKernel Component", - "homepage": "https://symfony.com" + "description": "Library that helps with managing the version number of Git-hosted PHP projects", + "homepage": "https://github.com/sebastianbergmann/version" }, { - "name": "symfony/routing", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/global-state", + "version": "1.0.0", + "version_normalized": "1.0.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/routing.git", - "reference": "6c5fae83efa20baf166fcf4582f57094e9f60f16" + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/6c5fae83efa20baf166fcf4582f57094e9f60f16", - "reference": "6c5fae83efa20baf166fcf4582f57094e9f60f16", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/c7428acdb62ece0a45e6306f1ae85e1c05b09c01", + "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01", "shasum": "" }, "require": { - "php": ">=5.3.9" - }, - "conflict": { - "symfony/config": "<2.7" + "php": ">=5.3.3" }, "require-dev": { - "doctrine/annotations": "~1.0", - "doctrine/common": "~2.2", - "psr/log": "~1.0", - "symfony/config": "~2.7", - "symfony/expression-language": "~2.4", - "symfony/http-foundation": "~2.3", - "symfony/phpunit-bridge": "~2.7", - "symfony/yaml": "~2.0,>=2.0.5" + "phpunit/phpunit": "~4.2" }, "suggest": { - "doctrine/annotations": "For using the annotation loader", - "symfony/config": "For using the all-in-one router or any loader", - "symfony/expression-language": "For using expression matching", - "symfony/yaml": "For using the YAML loader" + "ext-uopz": "*" }, - "time": "2015-09-14 14:14:09", + "time": "2014-10-06 09:23:50", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.0-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Routing\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Symfony Routing Component", - "homepage": "https://symfony.com", + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", "keywords": [ - "router", - "routing", - "uri", - "url" + "global state" ] }, { - "name": "symfony/serializer", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/recursion-context", + "version": "1.0.1", + "version_normalized": "1.0.1.0", "source": { "type": "git", - "url": "https://github.com/symfony/serializer.git", - "reference": "baf24f86a8656eea9c80988f332e51461bfcb67f" + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "994d4a811bafe801fb06dccbee797863ba2792ba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/serializer/zipball/baf24f86a8656eea9c80988f332e51461bfcb67f", - "reference": "baf24f86a8656eea9c80988f332e51461bfcb67f", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/994d4a811bafe801fb06dccbee797863ba2792ba", + "reference": "994d4a811bafe801fb06dccbee797863ba2792ba", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.3.3" }, "require-dev": { - "doctrine/annotations": "~1.0", - "doctrine/cache": "~1.0", - "symfony/config": "~2.2", - "symfony/phpunit-bridge": "~2.7", - "symfony/property-access": "~2.3", - "symfony/yaml": "~2.0,>=2.0.5" - }, - "suggest": { - "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", - "doctrine/cache": "For using the default cached annotation reader and metadata cache.", - "symfony/config": "For using the XML mapping loader.", - "symfony/property-access": "For using the ObjectNormalizer.", - "symfony/yaml": "For using the default YAML mapping loader." + "phpunit/phpunit": "~4.4" }, - "time": "2015-08-31 16:44:53", + "time": "2015-06-21 08:04:50", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.0.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Serializer\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" }, { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" } ], - "description": "Symfony Serializer Component", - "homepage": "https://symfony.com" + "description": "Provides functionality to recursively process PHP variables", + "homepage": "http://www.github.com/sebastianbergmann/recursion-context" }, { - "name": "symfony/translation", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/exporter", + "version": "1.2.1", + "version_normalized": "1.2.1.0", "source": { "type": "git", - "url": "https://github.com/symfony/translation.git", - "reference": "485877661835e188cd78345c6d4eef1290d17571" + "url": "https://github.com/sebastianbergmann/exporter.git", + "reference": "7ae5513327cb536431847bcc0c10edba2701064e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/485877661835e188cd78345c6d4eef1290d17571", - "reference": "485877661835e188cd78345c6d4eef1290d17571", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/7ae5513327cb536431847bcc0c10edba2701064e", + "reference": "7ae5513327cb536431847bcc0c10edba2701064e", "shasum": "" }, "require": { - "php": ">=5.3.9" - }, - "conflict": { - "symfony/config": "<2.7" + "php": ">=5.3.3", + "sebastian/recursion-context": "~1.0" }, "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~2.7", - "symfony/intl": "~2.4", - "symfony/phpunit-bridge": "~2.7", - "symfony/yaml": "~2.2" - }, - "suggest": { - "psr/log": "To use logging capability in translator", - "symfony/config": "", - "symfony/yaml": "" + "phpunit/phpunit": "~4.4" }, - "time": "2015-09-06 08:36:38", + "time": "2015-06-21 07:55:53", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.2.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Translation\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" }, { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" } ], - "description": "Symfony Translation Component", - "homepage": "https://symfony.com" + "description": "Provides the functionality to export PHP variables for visualization", + "homepage": "http://www.github.com/sebastianbergmann/exporter", + "keywords": [ + "export", + "exporter" + ] }, { - "name": "symfony/validator", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/environment", + "version": "1.3.2", + "version_normalized": "1.3.2.0", "source": { "type": "git", - "url": "https://github.com/symfony/validator.git", - "reference": "b359dc71e253ce6eb69eefbd5088032241e7a66f" + "url": "https://github.com/sebastianbergmann/environment.git", + "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/validator/zipball/b359dc71e253ce6eb69eefbd5088032241e7a66f", - "reference": "b359dc71e253ce6eb69eefbd5088032241e7a66f", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6324c907ce7a52478eeeaede764f48733ef5ae44", + "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44", "shasum": "" }, "require": { - "php": ">=5.3.9", - "symfony/translation": "~2.4" + "php": ">=5.3.3" }, "require-dev": { - "doctrine/annotations": "~1.0", - "doctrine/cache": "~1.0", - "egulias/email-validator": "~1.2,>=1.2.1", - "symfony/config": "~2.2", - "symfony/expression-language": "~2.4", - "symfony/http-foundation": "~2.1", - "symfony/intl": "~2.4", - "symfony/phpunit-bridge": "~2.7", - "symfony/property-access": "~2.3", - "symfony/yaml": "~2.0,>=2.0.5" - }, - "suggest": { - "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", - "doctrine/cache": "For using the default cached annotation reader and metadata cache.", - "egulias/email-validator": "Strict (RFC compliant) email validation", - "symfony/config": "", - "symfony/expression-language": "For using the 2.4 Expression validator", - "symfony/http-foundation": "", - "symfony/intl": "", - "symfony/property-access": "For using the 2.4 Validator API", - "symfony/yaml": "" + "phpunit/phpunit": "~4.4" }, - "time": "2015-09-23 11:13:27", + "time": "2015-08-03 06:14:51", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.3.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Validator\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Symfony Validator Component", - "homepage": "https://symfony.com" + "description": "Provides functionality to handle HHVM/PHP environments", + "homepage": "http://www.github.com/sebastianbergmann/environment", + "keywords": [ + "Xdebug", + "environment", + "hhvm" + ] }, { - "name": "symfony/process", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/diff", + "version": "1.3.0", + "version_normalized": "1.3.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/process.git", - "reference": "b27c8e317922cd3cdd3600850273cf6b82b2e8e9" + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/b27c8e317922cd3cdd3600850273cf6b82b2e8e9", - "reference": "b27c8e317922cd3cdd3600850273cf6b82b2e8e9", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/863df9687835c62aa423a22412d26fa2ebde3fd3", + "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.3.3" }, "require-dev": { - "symfony/phpunit-bridge": "~2.7" + "phpunit/phpunit": "~4.2" }, - "time": "2015-09-19 19:59:23", + "time": "2015-02-22 15:13:53", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.3-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Process\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" }, { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Symfony Process Component", - "homepage": "https://symfony.com" + "description": "Diff implementation", + "homepage": "http://www.github.com/sebastianbergmann/diff", + "keywords": [ + "diff" + ] }, { - "name": "symfony/yaml", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "sebastian/comparator", + "version": "1.2.0", + "version_normalized": "1.2.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "31cb2ad0155c95b88ee55fe12bc7ff92232c1770" + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "937efb279bd37a375bcadf584dec0726f84dbf22" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/31cb2ad0155c95b88ee55fe12bc7ff92232c1770", - "reference": "31cb2ad0155c95b88ee55fe12bc7ff92232c1770", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/937efb279bd37a375bcadf584dec0726f84dbf22", + "reference": "937efb279bd37a375bcadf584dec0726f84dbf22", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.3.3", + "sebastian/diff": "~1.2", + "sebastian/exporter": "~1.2" }, "require-dev": { - "symfony/phpunit-bridge": "~2.7" + "phpunit/phpunit": "~4.4" }, - "time": "2015-09-14 14:14:09", + "time": "2015-07-26 15:48:44", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.2.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\Yaml\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" }, { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Symfony Yaml Component", - "homepage": "https://symfony.com" + "description": "Provides the functionality to compare PHP values for equality", + "homepage": "http://www.github.com/sebastianbergmann/comparator", + "keywords": [ + "comparator", + "compare", + "equality" + ] }, { - "name": "symfony/css-selector", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "phpunit/php-text-template", + "version": "1.2.1", + "version_normalized": "1.2.1.0", "source": { "type": "git", - "url": "https://github.com/symfony/css-selector.git", - "reference": "abe19cc0429a06be0c133056d1f9859854860970" + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/abe19cc0429a06be0c133056d1f9859854860970", - "reference": "abe19cc0429a06be0c133056d1f9859854860970", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", "shasum": "" }, "require": { - "php": ">=5.3.9" - }, - "require-dev": { - "symfony/phpunit-bridge": "~2.7" + "php": ">=5.3.3" }, - "time": "2015-09-22 13:49:29", + "time": "2015-06-21 13:50:34", "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev" - } - }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\CssSelector\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Jean-François Simon", - "email": "jeanfrancois.simon@sensiolabs.com" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Symfony CssSelector Component", - "homepage": "https://symfony.com" + "description": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "keywords": [ + "template" + ] }, { - "name": "symfony/dom-crawler", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "doctrine/instantiator", + "version": "1.0.5", + "version_normalized": "1.0.5.0", "source": { "type": "git", - "url": "https://github.com/symfony/dom-crawler.git", - "reference": "2e185ca136399f902b948694987e62c80099c052" + "url": "https://github.com/doctrine/instantiator.git", + "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/2e185ca136399f902b948694987e62c80099c052", - "reference": "2e185ca136399f902b948694987e62c80099c052", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d", + "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.3,<8.0-DEV" }, "require-dev": { - "symfony/css-selector": "~2.3", - "symfony/phpunit-bridge": "~2.7" - }, - "suggest": { - "symfony/css-selector": "" + "athletic/athletic": "~0.1.8", + "ext-pdo": "*", + "ext-phar": "*", + "phpunit/phpunit": "~4.0", + "squizlabs/php_codesniffer": "~2.0" }, - "time": "2015-09-20 21:13:58", + "time": "2015-06-14 21:17:01", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "1.0.x-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Symfony\\Component\\DomCrawler\\": "" + "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" } }, "notification-url": "https://packagist.org/downloads/", @@ -3323,170 +3336,149 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "homepage": "http://ocramius.github.com/" } ], - "description": "Symfony DomCrawler Component", - "homepage": "https://symfony.com" + "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", + "homepage": "https://github.com/doctrine/instantiator", + "keywords": [ + "constructor", + "instantiate" + ] }, { - "name": "symfony/browser-kit", - "version": "v2.7.5", - "version_normalized": "2.7.5.0", + "name": "phpunit/phpunit-mock-objects", + "version": "2.3.8", + "version_normalized": "2.3.8.0", "source": { "type": "git", - "url": "https://github.com/symfony/browser-kit.git", - "reference": "277a2457776d4cc25706fbdd9d1e4ab2dac884e4" + "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", + "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/browser-kit/zipball/277a2457776d4cc25706fbdd9d1e4ab2dac884e4", - "reference": "277a2457776d4cc25706fbdd9d1e4ab2dac884e4", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/ac8e7a3db35738d56ee9a76e78a4e03d97628983", + "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983", "shasum": "" }, "require": { - "php": ">=5.3.9", - "symfony/dom-crawler": "~2.0,>=2.0.5" + "doctrine/instantiator": "^1.0.2", + "php": ">=5.3.3", + "phpunit/php-text-template": "~1.2", + "sebastian/exporter": "~1.2" }, "require-dev": { - "symfony/css-selector": "~2.0,>=2.0.5", - "symfony/phpunit-bridge": "~2.7", - "symfony/process": "~2.0,>=2.0.5" + "phpunit/phpunit": "~4.4" }, "suggest": { - "symfony/process": "" + "ext-soap": "*" }, - "time": "2015-09-06 08:36:38", + "time": "2015-10-02 06:51:40", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev" + "dev-master": "2.3.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Component\\BrowserKit\\": "" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Sebastian Bergmann", + "email": "sb@sebastian-bergmann.de", + "role": "lead" } ], - "description": "Symfony BrowserKit Component", - "homepage": "https://symfony.com" + "description": "Mock Object library for PHPUnit", + "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", + "keywords": [ + "mock", + "xunit" + ] }, { - "name": "composer/semver", - "version": "1.0.0", - "version_normalized": "1.0.0.0", + "name": "phpunit/php-timer", + "version": "1.0.7", + "version_normalized": "1.0.7.0", "source": { "type": "git", - "url": "https://github.com/composer/semver.git", - "reference": "d0e1ccc6d44ab318b758d709e19176037da6b1ba" + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/d0e1ccc6d44ab318b758d709e19176037da6b1ba", - "reference": "d0e1ccc6d44ab318b758d709e19176037da6b1ba", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3e82f4e9fc92665fafd9157568e4dcb01d014e5b", + "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b", "shasum": "" }, "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.5", - "phpunit/phpunit-mock-objects": "~2.3" - }, - "time": "2015-09-21 09:42:36", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "0.1-dev" - } + "php": ">=5.3.3" }, + "time": "2015-06-21 08:01:12", + "type": "library", "installation-source": "dist", "autoload": { - "psr-4": { - "Composer\\Semver\\": "src" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Rob Bast", - "email": "rob.bast@gmail.com" - }, - { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" + "name": "Sebastian Bergmann", + "email": "sb@sebastian-bergmann.de", + "role": "lead" } ], - "description": "Semver library that offers utilities, version constraint parsing and validation.", + "description": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", "keywords": [ - "semantic", - "semver", - "validation", - "versioning" + "timer" ] }, { - "name": "mikey179/vfsStream", - "version": "v1.6.0", - "version_normalized": "1.6.0.0", + "name": "phpunit/php-file-iterator", + "version": "1.4.1", + "version_normalized": "1.4.1.0", "source": { "type": "git", - "url": "https://github.com/mikey179/vfsStream.git", - "reference": "73bcb605b741a7d5044b47592338c633788b0eb7" + "url": "https://github.com/sebastianbergmann/php-file-iterator.git", + "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/73bcb605b741a7d5044b47592338c633788b0eb7", - "reference": "73bcb605b741a7d5044b47592338c633788b0eb7", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/6150bf2c35d3fc379e50c7602b75caceaa39dbf0", + "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0", "shasum": "" }, "require": { - "php": ">=5.3.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.5" + "php": ">=5.3.3" }, - "time": "2015-10-06 16:59:57", + "time": "2015-06-21 13:08:43", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.6.x-dev" + "dev-master": "1.4.x-dev" } }, "installation-source": "dist", "autoload": { - "psr-0": { - "org\\bovigo\\vfs\\": "src/main/php" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3494,13 +3486,17 @@ ], "authors": [ { - "name": "Frank Kleine", - "homepage": "http://frankkleine.de/", - "role": "Developer" + "name": "Sebastian Bergmann", + "email": "sb@sebastian-bergmann.de", + "role": "lead" } ], - "description": "Virtual file system to mock the real file system in unit tests.", - "homepage": "http://vfs.bovigo.org/" + "description": "FilterIterator implementation that filters files based on a list of suffixes.", + "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", + "keywords": [ + "filesystem", + "iterator" + ] }, { "name": "phpunit/php-code-coverage", @@ -3566,6 +3562,68 @@ "xunit" ] }, + { + "name": "phpspec/prophecy", + "version": "v1.5.0", + "version_normalized": "1.5.0.0", + "source": { + "type": "git", + "url": "https://github.com/phpspec/prophecy.git", + "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4745ded9307786b730d7a60df5cb5a6c43cf95f7", + "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7", + "shasum": "" + }, + "require": { + "doctrine/instantiator": "^1.0.2", + "phpdocumentor/reflection-docblock": "~2.0", + "sebastian/comparator": "~1.1" + }, + "require-dev": { + "phpspec/phpspec": "~2.0" + }, + "time": "2015-08-13 10:07:40", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.4.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-0": { + "Prophecy\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Konstantin Kudryashov", + "email": "ever.zet@gmail.com", + "homepage": "http://everzet.com" + }, + { + "name": "Marcello Duarte", + "email": "marcello.duarte@gmail.com" + } + ], + "description": "Highly opinionated mocking framework for PHP 5.3+", + "homepage": "https://github.com/phpspec/prophecy", + "keywords": [ + "Double", + "Dummy", + "fake", + "mock", + "spy", + "stub" + ] + }, { "name": "phpunit/phpunit", "version": "4.8.11", @@ -3641,121 +3699,63 @@ ] }, { - "name": "zendframework/zend-hydrator", - "version": "1.0.0", - "version_normalized": "1.0.0.0", + "name": "symfony/event-dispatcher", + "version": "v2.7.5", + "version_normalized": "2.7.5.0", "source": { "type": "git", - "url": "https://github.com/zendframework/zend-hydrator.git", - "reference": "f3ed8b833355140350bbed98d8a7b8b66875903f" + "url": "https://github.com/symfony/event-dispatcher.git", + "reference": "ae4dcc2a8d3de98bd794167a3ccda1311597c5d9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-hydrator/zipball/f3ed8b833355140350bbed98d8a7b8b66875903f", - "reference": "f3ed8b833355140350bbed98d8a7b8b66875903f", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/ae4dcc2a8d3de98bd794167a3ccda1311597c5d9", + "reference": "ae4dcc2a8d3de98bd794167a3ccda1311597c5d9", "shasum": "" }, "require": { - "php": ">=5.5", - "zendframework/zend-stdlib": "^2.5.1" + "php": ">=5.3.9" }, "require-dev": { - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "^2.0@dev", - "zendframework/zend-eventmanager": "^2.5.1", - "zendframework/zend-filter": "^2.5.1", - "zendframework/zend-inputfilter": "^2.5.1", - "zendframework/zend-serializer": "^2.5.1", - "zendframework/zend-servicemanager": "^2.5.1" + "psr/log": "~1.0", + "symfony/config": "~2.0,>=2.0.5", + "symfony/dependency-injection": "~2.6", + "symfony/expression-language": "~2.6", + "symfony/phpunit-bridge": "~2.7", + "symfony/stopwatch": "~2.3" }, "suggest": { - "zendframework/zend-eventmanager": "^2.5.1, to support aggregate hydrator usage", - "zendframework/zend-filter": "^2.5.1, to support naming strategy hydrator usage", - "zendframework/zend-serializer": "^2.5.1, to use the SerializableStrategy", - "zendframework/zend-servicemanager": "^2.5.1, to support hydrator plugin manager usage" + "symfony/dependency-injection": "", + "symfony/http-kernel": "" }, - "time": "2015-09-17 14:06:43", + "time": "2015-09-22 13:49:29", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev", - "dev-develop": "1.1-dev" + "dev-master": "2.7-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Zend\\Hydrator\\": "src/" + "Symfony\\Component\\EventDispatcher\\": "" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], - "homepage": "https://github.com/zendframework/zend-hydrator", - "keywords": [ - "hydrator", - "zf2" - ] - }, - { - "name": "zendframework/zend-stdlib", - "version": "2.7.3", - "version_normalized": "2.7.3.0", - "source": { - "type": "git", - "url": "https://github.com/zendframework/zend-stdlib.git", - "reference": "8ac0c77ff567fcf49b58689ee3bfa7595be102bc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-stdlib/zipball/8ac0c77ff567fcf49b58689ee3bfa7595be102bc", - "reference": "8ac0c77ff567fcf49b58689ee3bfa7595be102bc", - "shasum": "" - }, - "require": { - "php": ">=5.5", - "zendframework/zend-hydrator": "~1.0" - }, - "require-dev": { - "athletic/athletic": "~0.1", - "fabpot/php-cs-fixer": "1.7.*", - "phpunit/phpunit": "~4.0", - "zendframework/zend-config": "~2.5", - "zendframework/zend-eventmanager": "~2.5", - "zendframework/zend-filter": "~2.5", - "zendframework/zend-inputfilter": "~2.5", - "zendframework/zend-serializer": "~2.5", - "zendframework/zend-servicemanager": "~2.5" - }, - "suggest": { - "zendframework/zend-eventmanager": "To support aggregate hydrator usage", - "zendframework/zend-filter": "To support naming strategy hydrator usage", - "zendframework/zend-serializer": "Zend\\Serializer component", - "zendframework/zend-servicemanager": "To support hydrator plugin manager usage" - }, - "time": "2015-09-25 04:06:33", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev", - "dev-develop": "2.8-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Zend\\Stdlib\\": "src/" + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" ], - "homepage": "https://github.com/zendframework/zend-stdlib", - "keywords": [ - "stdlib", - "zf2" - ] + "description": "Symfony EventDispatcher Component", + "homepage": "https://symfony.com" } ] diff --git a/vendor/composer/installers/src/Composer/Installers/Installer.php b/vendor/composer/installers/src/Composer/Installers/Installer.php index 898514970..63ba64ce3 100644 --- a/vendor/composer/installers/src/Composer/Installers/Installer.php +++ b/vendor/composer/installers/src/Composer/Installers/Installer.php @@ -80,7 +80,7 @@ public function getInstallPath(PackageInterface $package) if ($frameworkType === false) { throw new \InvalidArgumentException( - 'The package type of this package is not yet supported.' + 'Sorry the package type of this package is not yet supported.' ); } diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ApcCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ApcCacheTest.php deleted file mode 100644 index df8126201..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ApcCacheTest.php +++ /dev/null @@ -1,20 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of APC'); - } - } - - protected function _getCacheDriver() - { - return new ApcCache(); - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ArrayCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ArrayCacheTest.php deleted file mode 100644 index a6c3097d3..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ArrayCacheTest.php +++ /dev/null @@ -1,26 +0,0 @@ -_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats); - } - - protected function isSharedStorage() - { - return false; - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/BaseFileCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/BaseFileCacheTest.php deleted file mode 100644 index eaedd9944..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/BaseFileCacheTest.php +++ /dev/null @@ -1,40 +0,0 @@ -directory = sys_get_temp_dir() . '/doctrine_cache_'. uniqid(); - } while (file_exists($this->directory)); - } - - public function tearDown() - { - if ( ! is_dir($this->directory)) { - return; - } - - $iterator = new RecursiveDirectoryIterator($this->directory); - - foreach (new RecursiveIteratorIterator($iterator, RecursiveIteratorIterator::CHILD_FIRST) as $file) { - if ($file->isFile()) { - @unlink($file->getRealPath()); - } elseif ($file->isDir()) { - @rmdir($file->getRealPath()); - } - } - } - - protected function isSharedStorage() - { - return false; - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CacheTest.php deleted file mode 100644 index 3c7f619b6..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CacheTest.php +++ /dev/null @@ -1,373 +0,0 @@ -_getCacheDriver(); - - // Test saving a value, checking if it exists, and fetching it back - $this->assertTrue($cache->save('key', 'value')); - $this->assertTrue($cache->contains('key')); - $this->assertEquals('value', $cache->fetch('key')); - - // Test updating the value of a cache entry - $this->assertTrue($cache->save('key', 'value-changed')); - $this->assertTrue($cache->contains('key')); - $this->assertEquals('value-changed', $cache->fetch('key')); - - // Test deleting a value - $this->assertTrue($cache->delete('key')); - $this->assertFalse($cache->contains('key')); - } - - public function testFetchMulti() - { - $cache = $this->_getCacheDriver(); - - $cache->deleteAll(); - - // Test saving some values, checking if it exists, and fetching it back with multiGet - $this->assertTrue($cache->save('key1', 'value1')); - $this->assertTrue($cache->save('key2', 'value2')); - - $this->assertEquals( - array('key1' => 'value1', 'key2' => 'value2'), - $cache->fetchMultiple(array('key1', 'key2')) - ); - $this->assertEquals( - array('key1' => 'value1', 'key2' => 'value2'), - $cache->fetchMultiple(array('key1', 'key3', 'key2')) - ); - $this->assertEquals( - array('key1' => 'value1', 'key2' => 'value2'), - $cache->fetchMultiple(array('key1', 'key2', 'key3')) - ); - } - - public function testFetchMultiWillFilterNonRequestedKeys() - { - /* @var $cache \Doctrine\Common\Cache\CacheProvider|\PHPUnit_Framework_MockObject_MockObject */ - $cache = $this->getMockForAbstractClass( - 'Doctrine\Common\Cache\CacheProvider', - array(), - '', - true, - true, - true, - array('doFetchMultiple') - ); - - $cache - ->expects($this->once()) - ->method('doFetchMultiple') - ->will($this->returnValue(array( - '[foo][]' => 'bar', - '[bar][]' => 'baz', - '[baz][]' => 'tab', - ))); - - $this->assertEquals( - array('foo' => 'bar', 'bar' => 'baz'), - $cache->fetchMultiple(array('foo', 'bar')) - ); - } - - - public function provideCrudValues() - { - return array( - 'array' => array(array('one', 2, 3.0)), - 'string' => array('value'), - 'integer' => array(1), - 'float' => array(1.5), - 'object' => array(new ArrayObject()), - 'null' => array(null), - ); - } - - public function testDeleteAll() - { - $cache = $this->_getCacheDriver(); - - $this->assertTrue($cache->save('key1', 1)); - $this->assertTrue($cache->save('key2', 2)); - $this->assertTrue($cache->deleteAll()); - $this->assertFalse($cache->contains('key1')); - $this->assertFalse($cache->contains('key2')); - } - - public function testDeleteAllAndNamespaceVersioningBetweenCaches() - { - if ( ! $this->isSharedStorage()) { - $this->markTestSkipped('The ' . __CLASS__ .' does not use shared storage'); - } - - $cache1 = $this->_getCacheDriver(); - $cache2 = $this->_getCacheDriver(); - - $this->assertTrue($cache1->save('key1', 1)); - $this->assertTrue($cache2->save('key2', 2)); - - /* Both providers are initialized with the same namespace version, so - * they can see entries set by each other. - */ - $this->assertTrue($cache1->contains('key1')); - $this->assertTrue($cache1->contains('key2')); - $this->assertTrue($cache2->contains('key1')); - $this->assertTrue($cache2->contains('key2')); - - /* Deleting all entries through one provider will only increment the - * namespace version on that object (and in the cache itself, which new - * instances will use to initialize). The second provider will retain - * its original version and still see stale data. - */ - $this->assertTrue($cache1->deleteAll()); - $this->assertFalse($cache1->contains('key1')); - $this->assertFalse($cache1->contains('key2')); - $this->assertTrue($cache2->contains('key1')); - $this->assertTrue($cache2->contains('key2')); - - /* A new cache provider should not see the deleted entries, since its - * namespace version will be initialized. - */ - $cache3 = $this->_getCacheDriver(); - $this->assertFalse($cache3->contains('key1')); - $this->assertFalse($cache3->contains('key2')); - } - - public function testFlushAll() - { - $cache = $this->_getCacheDriver(); - - $this->assertTrue($cache->save('key1', 1)); - $this->assertTrue($cache->save('key2', 2)); - $this->assertTrue($cache->flushAll()); - $this->assertFalse($cache->contains('key1')); - $this->assertFalse($cache->contains('key2')); - } - - public function testFlushAllAndNamespaceVersioningBetweenCaches() - { - if ( ! $this->isSharedStorage()) { - $this->markTestSkipped('The ' . __CLASS__ .' does not use shared storage'); - } - - $cache1 = $this->_getCacheDriver(); - $cache2 = $this->_getCacheDriver(); - - /* Deleting all elements from the first provider should increment its - * namespace version before saving the first entry. - */ - $cache1->deleteAll(); - $this->assertTrue($cache1->save('key1', 1)); - - /* The second provider will be initialized with the same namespace - * version upon its first save operation. - */ - $this->assertTrue($cache2->save('key2', 2)); - - /* Both providers have the same namespace version and can see entires - * set by each other. - */ - $this->assertTrue($cache1->contains('key1')); - $this->assertTrue($cache1->contains('key2')); - $this->assertTrue($cache2->contains('key1')); - $this->assertTrue($cache2->contains('key2')); - - /* Flushing all entries through one cache will remove all entries from - * the cache but leave their namespace version as-is. - */ - $this->assertTrue($cache1->flushAll()); - $this->assertFalse($cache1->contains('key1')); - $this->assertFalse($cache1->contains('key2')); - $this->assertFalse($cache2->contains('key1')); - $this->assertFalse($cache2->contains('key2')); - - /* Inserting a new entry will use the same, incremented namespace - * version, and it will be visible to both providers. - */ - $this->assertTrue($cache1->save('key1', 1)); - $this->assertTrue($cache1->contains('key1')); - $this->assertTrue($cache2->contains('key1')); - - /* A new cache provider will be initialized with the original namespace - * version and not share any visibility with the first two providers. - */ - $cache3 = $this->_getCacheDriver(); - $this->assertFalse($cache3->contains('key1')); - $this->assertFalse($cache3->contains('key2')); - $this->assertTrue($cache3->save('key3', 3)); - $this->assertTrue($cache3->contains('key3')); - } - - public function testNamespace() - { - $cache = $this->_getCacheDriver(); - - $cache->setNamespace('ns1_'); - - $this->assertTrue($cache->save('key1', 1)); - $this->assertTrue($cache->contains('key1')); - - $cache->setNamespace('ns2_'); - - $this->assertFalse($cache->contains('key1')); - } - - public function testDeleteAllNamespace() - { - $cache = $this->_getCacheDriver(); - - $cache->setNamespace('ns1'); - $this->assertFalse($cache->contains('key1')); - $cache->save('key1', 'test'); - $this->assertTrue($cache->contains('key1')); - - $cache->setNamespace('ns2'); - $this->assertFalse($cache->contains('key1')); - $cache->save('key1', 'test'); - $this->assertTrue($cache->contains('key1')); - - $cache->setNamespace('ns1'); - $this->assertTrue($cache->contains('key1')); - $cache->deleteAll(); - $this->assertFalse($cache->contains('key1')); - - $cache->setNamespace('ns2'); - $this->assertTrue($cache->contains('key1')); - $cache->deleteAll(); - $this->assertFalse($cache->contains('key1')); - } - - /** - * @group DCOM-43 - */ - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertArrayHasKey(Cache::STATS_HITS, $stats); - $this->assertArrayHasKey(Cache::STATS_MISSES, $stats); - $this->assertArrayHasKey(Cache::STATS_UPTIME, $stats); - $this->assertArrayHasKey(Cache::STATS_MEMORY_USAGE, $stats); - $this->assertArrayHasKey(Cache::STATS_MEMORY_AVAILABLE, $stats); - } - - public function testFetchMissShouldReturnFalse() - { - $cache = $this->_getCacheDriver(); - - /* Ensure that caches return boolean false instead of null on a fetch - * miss to be compatible with ORM integration. - */ - $result = $cache->fetch('nonexistent_key'); - - $this->assertFalse($result); - $this->assertNotNull($result); - } - - /** - * Check to see that, even if the user saves a value that can be interpreted as false, - * the cache adapter will still recognize its existence there. - * - * @dataProvider falseCastedValuesProvider - */ - public function testFalseCastedValues($value) - { - $cache = $this->_getCacheDriver(); - - $this->assertTrue($cache->save('key', $value)); - $this->assertTrue($cache->contains('key')); - $this->assertEquals($value, $cache->fetch('key')); - } - - /** - * The following values get converted to FALSE if you cast them to a boolean. - * @see http://php.net/manual/en/types.comparisons.php - */ - public function falseCastedValuesProvider() - { - return array( - array(false), - array(null), - array(array()), - array('0'), - array(0), - array(0.0), - array('') - ); - } - - /** - * Check to see that objects are correctly serialized and unserialized by the cache - * provider. - */ - public function testCachedObject() - { - $cache = $this->_getCacheDriver(); - $cache->deleteAll(); - $obj = new \stdClass(); - $obj->foo = "bar"; - $obj2 = new \stdClass(); - $obj2->bar = "foo"; - $obj2->obj = $obj; - $obj->obj2 = $obj2; - $cache->save("obj", $obj); - - $fetched = $cache->fetch("obj"); - - $this->assertInstanceOf("stdClass", $obj); - $this->assertInstanceOf("stdClass", $obj->obj2); - $this->assertInstanceOf("stdClass", $obj->obj2->obj); - $this->assertEquals("bar", $fetched->foo); - $this->assertEquals("foo", $fetched->obj2->bar); - } - - /** - * Check to see that objects fetched via fetchMultiple are properly unserialized - */ - public function testFetchMultipleObjects() - { - $cache = $this->_getCacheDriver(); - $cache->deleteAll(); - $obj1 = new \stdClass(); - $obj1->foo = "bar"; - $cache->save("obj1", $obj1); - $obj2 = new \stdClass(); - $obj2->bar = "baz"; - $cache->save("obj2", $obj2); - - $fetched = $cache->fetchMultiple(array("obj1", "obj2")); - $this->assertInstanceOf("stdClass", $fetched["obj1"]); - $this->assertInstanceOf("stdClass", $fetched["obj2"]); - $this->assertEquals("bar", $fetched["obj1"]->foo); - $this->assertEquals("baz", $fetched["obj2"]->bar); - } - - /** - * Return whether multiple cache providers share the same storage. - * - * This is used for skipping certain tests for shared storage behavior. - * - * @return boolean - */ - protected function isSharedStorage() - { - return true; - } - - /** - * @return \Doctrine\Common\Cache\CacheProvider - */ - abstract protected function _getCacheDriver(); -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ChainCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ChainCacheTest.php deleted file mode 100644 index 46d78c129..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ChainCacheTest.php +++ /dev/null @@ -1,94 +0,0 @@ -_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertInternalType('array', $stats); - } - - public function testOnlyFetchFirstOne() - { - $cache1 = new ArrayCache(); - $cache2 = $this->getMockForAbstractClass('Doctrine\Common\Cache\CacheProvider'); - - $cache2->expects($this->never())->method('doFetch'); - - $chainCache = new ChainCache(array($cache1, $cache2)); - $chainCache->save('id', 'bar'); - - $this->assertEquals('bar', $chainCache->fetch('id')); - } - - public function testFetchPropagateToFastestCache() - { - $cache1 = new ArrayCache(); - $cache2 = new ArrayCache(); - - $cache2->save('bar', 'value'); - - $chainCache = new ChainCache(array($cache1, $cache2)); - - $this->assertFalse($cache1->contains('bar')); - - $result = $chainCache->fetch('bar'); - - $this->assertEquals('value', $result); - $this->assertTrue($cache2->contains('bar')); - } - - public function testNamespaceIsPropagatedToAllProviders() - { - $cache1 = new ArrayCache(); - $cache2 = new ArrayCache(); - - $chainCache = new ChainCache(array($cache1, $cache2)); - $chainCache->setNamespace('bar'); - - $this->assertEquals('bar', $cache1->getNamespace()); - $this->assertEquals('bar', $cache2->getNamespace()); - } - - public function testDeleteToAllProviders() - { - $cache1 = $this->getMockForAbstractClass('Doctrine\Common\Cache\CacheProvider'); - $cache2 = $this->getMockForAbstractClass('Doctrine\Common\Cache\CacheProvider'); - - $cache1->expects($this->once())->method('doDelete'); - $cache2->expects($this->once())->method('doDelete'); - - $chainCache = new ChainCache(array($cache1, $cache2)); - $chainCache->delete('bar'); - } - - public function testFlushToAllProviders() - { - $cache1 = $this->getMockForAbstractClass('Doctrine\Common\Cache\CacheProvider'); - $cache2 = $this->getMockForAbstractClass('Doctrine\Common\Cache\CacheProvider'); - - $cache1->expects($this->once())->method('doFlush'); - $cache2->expects($this->once())->method('doFlush'); - - $chainCache = new ChainCache(array($cache1, $cache2)); - $chainCache->flushAll(); - } - - protected function isSharedStorage() - { - return false; - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CouchbaseCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CouchbaseCacheTest.php deleted file mode 100644 index 40d5a6934..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CouchbaseCacheTest.php +++ /dev/null @@ -1,47 +0,0 @@ -couchbase = new Couchbase('127.0.0.1', 'Administrator', 'password', 'default'); - } catch(Exception $ex) { - $this->markTestSkipped('Could not instantiate the Couchbase cache because of: ' . $ex); - } - } else { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of the couchbase extension'); - } - } - - public function testNoExpire() - { - $cache = $this->_getCacheDriver(); - $cache->save('noexpire', 'value', 0); - sleep(1); - $this->assertTrue($cache->contains('noexpire'), 'Couchbase provider should support no-expire'); - } - - public function testLongLifetime() - { - $cache = $this->_getCacheDriver(); - $cache->save('key', 'value', 30 * 24 * 3600 + 1); - - $this->assertTrue($cache->contains('key'), 'Couchbase provider should support TTL > 30 days'); - } - - protected function _getCacheDriver() - { - $driver = new CouchbaseCache(); - $driver->setCouchbase($this->couchbase); - return $driver; - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FileCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FileCacheTest.php deleted file mode 100644 index 886832141..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FileCacheTest.php +++ /dev/null @@ -1,161 +0,0 @@ -driver = $this->getMock( - 'Doctrine\Common\Cache\FileCache', - array('doFetch', 'doContains', 'doSave'), - array(), '', false - ); - } - - public function getProviderFileName() - { - return array( - //The characters :\/<>"*?| are not valid in Windows filenames. - array('key:1', 'key-1'), - array('key\2', 'key-2'), - array('key/3', 'key-3'), - array('key<4', 'key-4'), - array('key>5', 'key-5'), - array('key"6', 'key-6'), - array('key*7', 'key-7'), - array('key?8', 'key-8'), - array('key|9', 'key-9'), - array('key[10]', 'key[10]'), - array('keyä11', 'key--11'), - array('../key12', '---key12'), - array('key-13', 'key__13'), - ); - } - - /** - * @dataProvider getProviderFileName - */ - public function testInvalidFilename($key, $expected) - { - $cache = $this->driver; - $method = new \ReflectionMethod($cache, 'getFilename'); - - $method->setAccessible(true); - - $value = $method->invoke($cache, $key); - $actual = pathinfo($value, PATHINFO_FILENAME); - - $this->assertEquals($expected, $actual); - } - - public function testFilenameCollision() - { - $data = array( - 'key:0' => 'key-0', - 'key\0' => 'key-0', - 'key/0' => 'key-0', - 'key<0' => 'key-0', - 'key>0' => 'key-0', - 'key"0' => 'key-0', - 'key*0' => 'key-0', - 'key?0' => 'key-0', - 'key|0' => 'key-0', - 'key-0' => 'key__0', - 'keyä0' => 'key--0', - ); - - $paths = array(); - $cache = $this->driver; - $method = new \ReflectionMethod($cache, 'getFilename'); - - $method->setAccessible(true); - - foreach ($data as $key => $expected) { - $path = $method->invoke($cache, $key); - $actual = pathinfo($path, PATHINFO_FILENAME); - - $this->assertNotContains($path, $paths); - $this->assertEquals($expected, $actual); - - $paths[] = $path; - } - } - - public function testFilenameShouldCreateThePathWithFourSubDirectories() - { - $cache = $this->driver; - $method = new \ReflectionMethod($cache, 'getFilename'); - $key = 'item-key'; - $expectedDir = array( - '84', 'e0', 'e2', 'e8', '93', 'fe', 'bb', '73', '7a', '0f', 'ee', - '0c', '89', 'd5', '3f', '4b', 'b7', 'fc', 'b4', '4c', '57', 'cd', - 'f3', 'd3', '2c', 'e7', '36', '3f', '5d', '59', '77', '60' - ); - $expectedDir = implode(DIRECTORY_SEPARATOR, $expectedDir); - - $method->setAccessible(true); - - $path = $method->invoke($cache, $key); - $filename = pathinfo($path, PATHINFO_FILENAME); - $dirname = pathinfo($path, PATHINFO_DIRNAME); - - $this->assertEquals('item__key', $filename); - $this->assertEquals(DIRECTORY_SEPARATOR . $expectedDir, $dirname); - $this->assertEquals(DIRECTORY_SEPARATOR . $expectedDir . DIRECTORY_SEPARATOR . 'item__key', $path); - } - - public function testFileExtensionCorrectlyEscaped() - { - $driver1 = $this->getMock( - 'Doctrine\Common\Cache\FileCache', - array('doFetch', 'doContains', 'doSave'), - array(__DIR__, '.*') - ); - $driver2 = $this->getMock( - 'Doctrine\Common\Cache\FileCache', - array('doFetch', 'doContains', 'doSave'), - array(__DIR__, '.php') - ); - - $doGetStats = new \ReflectionMethod($driver1, 'doGetStats'); - - $doGetStats->setAccessible(true); - - $stats1 = $doGetStats->invoke($driver1); - $stats2 = $doGetStats->invoke($driver2); - - $this->assertSame(0, $stats1[Cache::STATS_MEMORY_USAGE]); - $this->assertGreaterThan(0, $stats2[Cache::STATS_MEMORY_USAGE]); - } - - /** - * @group DCOM-266 - */ - public function testFileExtensionSlashCorrectlyEscaped() - { - $driver = $this->getMock( - 'Doctrine\Common\Cache\FileCache', - array('doFetch', 'doContains', 'doSave'), - array(__DIR__ . '/../', '/' . basename(__FILE__)) - ); - - $doGetStats = new \ReflectionMethod($driver, 'doGetStats'); - - $doGetStats->setAccessible(true); - - $stats = $doGetStats->invoke($driver); - - $this->assertGreaterThan(0, $stats[Cache::STATS_MEMORY_USAGE]); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FilesystemCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FilesystemCacheTest.php deleted file mode 100644 index e3b74cd01..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FilesystemCacheTest.php +++ /dev/null @@ -1,75 +0,0 @@ -_getCacheDriver(); - - // Test save - $cache->save('test_key', 'testing this out', 10); - - // Test contains to test that save() worked - $this->assertTrue($cache->contains('test_key')); - - // Test fetch - $this->assertEquals('testing this out', $cache->fetch('test_key')); - - // access private methods - $getFilename = new \ReflectionMethod($cache, 'getFilename'); - $getNamespacedId = new \ReflectionMethod($cache, 'getNamespacedId'); - - $getFilename->setAccessible(true); - $getNamespacedId->setAccessible(true); - - $id = $getNamespacedId->invoke($cache, 'test_key'); - $filename = $getFilename->invoke($cache, $id); - - $data = ''; - $lifetime = 0; - $resource = fopen($filename, "r"); - - if (false !== ($line = fgets($resource))) { - $lifetime = (integer) $line; - } - - while (false !== ($line = fgets($resource))) { - $data .= $line; - } - - $this->assertNotEquals(0, $lifetime, "previous lifetime could not be loaded"); - - // update lifetime - $lifetime = $lifetime - 20; - file_put_contents($filename, $lifetime . PHP_EOL . $data); - - // test expired data - $this->assertFalse($cache->contains('test_key')); - $this->assertFalse($cache->fetch('test_key')); - } - - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats[Cache::STATS_HITS]); - $this->assertNull($stats[Cache::STATS_MISSES]); - $this->assertNull($stats[Cache::STATS_UPTIME]); - $this->assertEquals(0, $stats[Cache::STATS_MEMORY_USAGE]); - $this->assertGreaterThan(0, $stats[Cache::STATS_MEMORY_AVAILABLE]); - } - - protected function _getCacheDriver() - { - return new FilesystemCache($this->directory); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php deleted file mode 100644 index b0da1b969..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php +++ /dev/null @@ -1,54 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of memcache'); - } - - $this->memcache = new Memcache(); - - if (@$this->memcache->connect('localhost', 11211) === false) { - unset($this->memcache); - $this->markTestSkipped('The ' . __CLASS__ .' cannot connect to memcache'); - } - } - - public function tearDown() - { - if ($this->memcache instanceof Memcache) { - $this->memcache->flush(); - } - } - - public function testNoExpire() - { - $cache = $this->_getCacheDriver(); - $cache->save('noexpire', 'value', 0); - sleep(1); - $this->assertTrue($cache->contains('noexpire'), 'Memcache provider should support no-expire'); - } - - public function testLongLifetime() - { - $cache = $this->_getCacheDriver(); - $cache->save('key', 'value', 30 * 24 * 3600 + 1); - $this->assertTrue($cache->contains('key'), 'Memcache provider should support TTL > 30 days'); - } - - protected function _getCacheDriver() - { - $driver = new MemcacheCache(); - $driver->setMemcache($this->memcache); - return $driver; - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcachedCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcachedCacheTest.php deleted file mode 100644 index 2028acc25..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcachedCacheTest.php +++ /dev/null @@ -1,70 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of memcached'); - } - - $this->memcached = new Memcached(); - $this->memcached->setOption(Memcached::OPT_COMPRESSION, false); - $this->memcached->addServer('127.0.0.1', 11211); - - if (@fsockopen('127.0.0.1', 11211) === false) { - unset($this->memcached); - $this->markTestSkipped('The ' . __CLASS__ .' cannot connect to memcache'); - } - } - - public function tearDown() - { - if ($this->memcached instanceof Memcached) { - $this->memcached->flush(); - } - } - - public function testNoExpire() - { - $cache = $this->_getCacheDriver(); - $cache->save('noexpire', 'value', 0); - sleep(1); - $this->assertTrue($cache->contains('noexpire'), 'Memcache provider should support no-expire'); - } - - public function testLongLifetime() - { - $cache = $this->_getCacheDriver(); - $cache->save('key', 'value', 30 * 24 * 3600 + 1); - $this->assertTrue($cache->contains('key'), 'Memcache provider should support TTL > 30 days'); - } - - protected function _getCacheDriver() - { - $driver = new MemcachedCache(); - $driver->setMemcached($this->memcached); - return $driver; - } - - /** - * {@inheritDoc} - * - * @dataProvider falseCastedValuesProvider - */ - public function testFalseCastedValues($value) - { - if (false === $value) { - $this->markTestIncomplete('Memcached currently doesn\'t support saving `false` values. '); - } - - parent::testFalseCastedValues($value); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MongoDBCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MongoDBCacheTest.php deleted file mode 100644 index 8c2f6e0e7..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MongoDBCacheTest.php +++ /dev/null @@ -1,61 +0,0 @@ -=')) { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of mongo >= 1.3.0'); - } - - $mongo = new MongoClient(); - $this->collection = $mongo->selectCollection('doctrine_common_cache', 'test'); - } - - public function tearDown() - { - if ($this->collection instanceof MongoCollection) { - $this->collection->drop(); - } - } - - public function testSaveWithNonUtf8String() - { - // Invalid 2-octet sequence - $data = "\xc3\x28"; - - $cache = $this->_getCacheDriver(); - - $this->assertTrue($cache->save('key', $data)); - $this->assertEquals($data, $cache->fetch('key')); - } - - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats[Cache::STATS_HITS]); - $this->assertNull($stats[Cache::STATS_MISSES]); - $this->assertGreaterThan(0, $stats[Cache::STATS_UPTIME]); - $this->assertEquals(0, $stats[Cache::STATS_MEMORY_USAGE]); - $this->assertNull($stats[Cache::STATS_MEMORY_AVAILABLE]); - } - - protected function _getCacheDriver() - { - return new MongoDBCache($this->collection); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PhpFileCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PhpFileCacheTest.php deleted file mode 100644 index f83a6e4d3..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PhpFileCacheTest.php +++ /dev/null @@ -1,128 +0,0 @@ -_getCacheDriver(); - - // Test save - $cache->save('test_key', 'testing this out', 10); - - // Test contains to test that save() worked - $this->assertTrue($cache->contains('test_key')); - - // Test fetch - $this->assertEquals('testing this out', $cache->fetch('test_key')); - - // access private methods - $getFilename = new \ReflectionMethod($cache, 'getFilename'); - $getNamespacedId = new \ReflectionMethod($cache, 'getNamespacedId'); - - $getFilename->setAccessible(true); - $getNamespacedId->setAccessible(true); - - $id = $getNamespacedId->invoke($cache, 'test_key'); - $path = $getFilename->invoke($cache, $id); - $value = include $path; - - // update lifetime - $value['lifetime'] = $value['lifetime'] - 20; - file_put_contents($path, 'assertFalse($cache->contains('test_key')); - $this->assertFalse($cache->fetch('test_key')); - } - - public function testImplementsSetState() - { - $cache = $this->_getCacheDriver(); - - // Test save - $cache->save('test_set_state', new SetStateClass(array(1,2,3))); - - //Test __set_state call - $this->assertCount(0, SetStateClass::$values); - - // Test fetch - $value = $cache->fetch('test_set_state'); - $this->assertInstanceOf('Doctrine\Tests\Common\Cache\SetStateClass', $value); - $this->assertEquals(array(1,2,3), $value->getValue()); - - //Test __set_state call - $this->assertCount(1, SetStateClass::$values); - - // Test contains - $this->assertTrue($cache->contains('test_set_state')); - } - - public function testNotImplementsSetState() - { - $cache = $this->_getCacheDriver(); - - $this->setExpectedException('InvalidArgumentException'); - $cache->save('test_not_set_state', new NotSetStateClass(array(1,2,3))); - } - - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats[Cache::STATS_HITS]); - $this->assertNull($stats[Cache::STATS_MISSES]); - $this->assertNull($stats[Cache::STATS_UPTIME]); - $this->assertEquals(0, $stats[Cache::STATS_MEMORY_USAGE]); - $this->assertGreaterThan(0, $stats[Cache::STATS_MEMORY_AVAILABLE]); - } - - public function testCachedObject() - { - $this->markTestSkipped("PhpFileCache cannot handle objects that don't implement __set_state."); - } - - public function testFetchMultipleObjects() - { - $this->markTestSkipped("PhpFileCache cannot handle objects that don't implement __set_state."); - } - - protected function _getCacheDriver() - { - return new PhpFileCache($this->directory); - } -} - -class NotSetStateClass -{ - private $value; - - public function __construct($value) - { - $this->value = $value; - } - - public function getValue() - { - return $this->value; - } -} - -class SetStateClass extends NotSetStateClass -{ - public static $values = array(); - - public static function __set_state($data) - { - self::$values = $data; - return new self($data['value']); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PredisCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PredisCacheTest.php deleted file mode 100644 index fecc92b4a..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PredisCacheTest.php +++ /dev/null @@ -1,62 +0,0 @@ -markTestSkipped('Predis\Client is missing. Make sure to "composer install" to have all dev dependencies.'); - } - - $this->client = new Client(); - - try { - $this->client->connect(); - } catch (ConnectionException $e) { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of redis'); - } - } - - public function testHitMissesStatsAreProvided() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNotNull($stats[Cache::STATS_HITS]); - $this->assertNotNull($stats[Cache::STATS_MISSES]); - } - - /** - * @return PredisCache - */ - protected function _getCacheDriver() - { - return new PredisCache($this->client); - } - - /** - * {@inheritDoc} - * - * @dataProvider falseCastedValuesProvider - */ - public function testFalseCastedValues($value) - { - if (array() === $value) { - $this->markTestIncomplete( - 'Predis currently doesn\'t support saving empty array values. ' - . 'See https://github.com/nrk/predis/issues/241' - ); - } - - parent::testFalseCastedValues($value); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RedisCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RedisCacheTest.php deleted file mode 100644 index 35d9f5ed1..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RedisCacheTest.php +++ /dev/null @@ -1,40 +0,0 @@ -_redis = new \Redis(); - $ok = @$this->_redis->connect('127.0.0.1'); - if (!$ok) { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of redis'); - } - } else { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of redis'); - } - } - - public function testHitMissesStatsAreProvided() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNotNull($stats[Cache::STATS_HITS]); - $this->assertNotNull($stats[Cache::STATS_MISSES]); - } - - protected function _getCacheDriver() - { - $driver = new RedisCache(); - $driver->setRedis($this->_redis); - return $driver; - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RiakCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RiakCacheTest.php deleted file mode 100644 index dce8cc00e..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RiakCacheTest.php +++ /dev/null @@ -1,64 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of Riak'); - } - - try { - $this->connection = new Connection('127.0.0.1', 8087); - $this->bucket = new Bucket($this->connection, 'test'); - } catch (Exception\RiakException $e) { - $this->markTestSkipped('The ' . __CLASS__ .' requires the use of Riak'); - } - } - - /** - * {@inheritdoc} - */ - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats); - } - - /** - * Retrieve RiakCache instance. - * - * @return \Doctrine\Common\Cache\RiakCache - */ - protected function _getCacheDriver() - { - return new RiakCache($this->bucket); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/SQLite3CacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/SQLite3CacheTest.php deleted file mode 100644 index 44ccce927..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/SQLite3CacheTest.php +++ /dev/null @@ -1,48 +0,0 @@ -file = tempnam(null, 'doctrine-cache-test-'); - unlink($this->file); - $this->sqlite = new SQLite3($this->file); - } - - protected function tearDown() - { - $this->sqlite = null; // DB must be closed before - unlink($this->file); - } - - public function testGetStats() - { - $this->assertNull($this->_getCacheDriver()->getStats()); - } - - public function testFetchSingle() - { - $id = uniqid('sqlite3_id_'); - $data = "\0"; // produces null bytes in serialized format - - $this->_getCacheDriver()->save($id, $data, 30); - - $this->assertEquals($data, $this->_getCacheDriver()->fetch($id)); - } - - protected function _getCacheDriver() - { - return new SQLite3Cache($this->sqlite, 'test_table'); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/VoidCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/VoidCacheTest.php deleted file mode 100644 index ca87f1661..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/VoidCacheTest.php +++ /dev/null @@ -1,51 +0,0 @@ -assertFalse($cache->contains('foo')); - $this->assertFalse($cache->contains('bar')); - } - - public function testShouldAlwaysReturnFalseOnFetch() - { - $cache = new VoidCache(); - - $this->assertFalse($cache->fetch('foo')); - $this->assertFalse($cache->fetch('bar')); - } - - public function testShouldAlwaysReturnTrueOnSaveButNotStoreAnything() - { - $cache = new VoidCache(); - - $this->assertTrue($cache->save('foo', 'fooVal')); - - $this->assertFalse($cache->contains('foo')); - $this->assertFalse($cache->fetch('foo')); - } - - public function testShouldAlwaysReturnTrueOnDelete() - { - $cache = new VoidCache(); - - $this->assertTrue($cache->delete('foo')); - } - - public function testShouldAlwaysReturnNullOnGetStatus() - { - $cache = new VoidCache(); - - $this->assertNull($cache->getStats()); - } -} diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/WinCacheCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/WinCacheCacheTest.php deleted file mode 100644 index cb363df95..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/WinCacheCacheTest.php +++ /dev/null @@ -1,20 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of Wincache'); - } - } - - protected function _getCacheDriver() - { - return new WincacheCache(); - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/XcacheCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/XcacheCacheTest.php deleted file mode 100644 index 625984877..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/XcacheCacheTest.php +++ /dev/null @@ -1,20 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of xcache'); - } - } - - protected function _getCacheDriver() - { - return new XcacheCache(); - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ZendDataCacheTest.php b/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ZendDataCacheTest.php deleted file mode 100644 index cd66e1578..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ZendDataCacheTest.php +++ /dev/null @@ -1,28 +0,0 @@ -markTestSkipped('The ' . __CLASS__ .' requires the use of Zend Data Cache which only works in apache2handler SAPI'); - } - } - - public function testGetStats() - { - $cache = $this->_getCacheDriver(); - $stats = $cache->getStats(); - - $this->assertNull($stats); - } - - protected function _getCacheDriver() - { - return new ZendDataCache(); - } -} \ No newline at end of file diff --git a/vendor/doctrine/cache/tests/Doctrine/Tests/DoctrineTestCase.php b/vendor/doctrine/cache/tests/Doctrine/Tests/DoctrineTestCase.php deleted file mode 100644 index e8323d294..000000000 --- a/vendor/doctrine/cache/tests/Doctrine/Tests/DoctrineTestCase.php +++ /dev/null @@ -1,10 +0,0 @@ -add('Doctrine\\Tests\\', __DIR__ . '/../../'); -unset($classLoader); diff --git a/vendor/doctrine/cache/tests/travis/php.ini b/vendor/doctrine/cache/tests/travis/php.ini deleted file mode 100644 index 105af36da..000000000 --- a/vendor/doctrine/cache/tests/travis/php.ini +++ /dev/null @@ -1,7 +0,0 @@ -extension="mongo.so" -extension="memcache.so" -extension="memcached.so" -extension="redis.so" - -apc.enabled=1 -apc.enable_cli=1 diff --git a/vendor/doctrine/cache/tests/travis/phpunit.travis.xml b/vendor/doctrine/cache/tests/travis/phpunit.travis.xml deleted file mode 100644 index a01faa5c2..000000000 --- a/vendor/doctrine/cache/tests/travis/phpunit.travis.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - - - - - - - - ../Doctrine/ - - - - - - ../../lib/Doctrine/ - - - - - - performance - - - diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/AbstractLazyCollectionTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/AbstractLazyCollectionTest.php deleted file mode 100644 index 4de82cc20..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/AbstractLazyCollectionTest.php +++ /dev/null @@ -1,20 +0,0 @@ -assertFalse($collection->isInitialized()); - $this->assertCount(3, $collection); - - $collection->add('bar'); - $this->assertTrue($collection->isInitialized()); - $this->assertCount(4, $collection); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ArrayCollectionTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ArrayCollectionTest.php deleted file mode 100644 index 1b8a906fd..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ArrayCollectionTest.php +++ /dev/null @@ -1,296 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Collections; - -use Doctrine\Common\Collections\ArrayCollection; -use Doctrine\Common\Collections\Criteria; - -/** - * Tests for {@see \Doctrine\Common\Collections\ArrayCollection} - * - * @covers \Doctrine\Common\Collections\ArrayCollection - */ -class ArrayCollectionTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider provideDifferentElements - */ - public function testToArray($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame($elements, $collection->toArray()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testFirst($elements) - { - $collection = new ArrayCollection($elements); - $this->assertSame(reset($elements), $collection->first()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testLast($elements) - { - $collection = new ArrayCollection($elements); - $this->assertSame(end($elements), $collection->last()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testKey($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame(key($elements), $collection->key()); - - next($elements); - $collection->next(); - - $this->assertSame(key($elements), $collection->key()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testNext($elements) - { - $collection = new ArrayCollection($elements); - - while (true) { - $collectionNext = $collection->next(); - $arrayNext = next($elements); - - if(!$collectionNext || !$arrayNext) { - break; - } - - $this->assertSame($arrayNext, $collectionNext, "Returned value of ArrayCollection::next() and next() not match"); - $this->assertSame(key($elements), $collection->key(), "Keys not match"); - $this->assertSame(current($elements), $collection->current(), "Current values not match"); - } - } - - /** - * @dataProvider provideDifferentElements - */ - public function testCurrent($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame(current($elements), $collection->current()); - - next($elements); - $collection->next(); - - $this->assertSame(current($elements), $collection->current()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testGetKeys($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame(array_keys($elements), $collection->getKeys()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testGetValues($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame(array_values($elements), $collection->getValues()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testCount($elements) - { - $collection = new ArrayCollection($elements); - - $this->assertSame(count($elements), $collection->count()); - } - - /** - * @dataProvider provideDifferentElements - */ - public function testIterator($elements) - { - $collection = new ArrayCollection($elements); - - $iterations = 0; - foreach($collection->getIterator() as $key => $item) { - $this->assertSame($elements[$key], $item, "Item {$key} not match"); - $iterations++; - } - - $this->assertEquals(count($elements), $iterations, "Number of iterations not match"); - } - - /** - * @return array - */ - public function provideDifferentElements() - { - return array( - 'indexed' => array(array(1, 2, 3, 4, 5)), - 'associative' => array(array('A' => 'a', 'B' => 'b', 'C' => 'c')), - 'mixed' => array(array('A' => 'a', 1, 'B' => 'b', 2, 3)), - ); - } - - public function testRemove() - { - $elements = array(1, 'A' => 'a', 2, 'B' => 'b', 3); - $collection = new ArrayCollection($elements); - - $this->assertEquals(1, $collection->remove(0)); - unset($elements[0]); - - $this->assertEquals(null, $collection->remove('non-existent')); - unset($elements['non-existent']); - - $this->assertEquals(2, $collection->remove(1)); - unset($elements[1]); - - $this->assertEquals('a', $collection->remove('A')); - unset($elements['A']); - - $this->assertEquals($elements, $collection->toArray()); - } - - public function testRemoveElement() - { - $elements = array(1, 'A' => 'a', 2, 'B' => 'b', 3, 'A2' => 'a', 'B2' => 'b'); - $collection = new ArrayCollection($elements); - - $this->assertTrue($collection->removeElement(1)); - unset($elements[0]); - - $this->assertFalse($collection->removeElement('non-existent')); - - $this->assertTrue($collection->removeElement('a')); - unset($elements['A']); - - $this->assertTrue($collection->removeElement('a')); - unset($elements['A2']); - - $this->assertEquals($elements, $collection->toArray()); - } - - public function testContainsKey() - { - $elements = array(1, 'A' => 'a', 2, 'null' => null, 3, 'A2' => 'a', 'B2' => 'b'); - $collection = new ArrayCollection($elements); - - $this->assertTrue($collection->containsKey(0), "Contains index 0"); - $this->assertTrue($collection->containsKey('A'), "Contains key \"A\""); - $this->assertTrue($collection->containsKey('null'), "Contains key \"null\", with value null"); - $this->assertFalse($collection->containsKey('non-existent'), "Doesn't contain key"); - } - - public function testEmpty() - { - $collection = new ArrayCollection(); - $this->assertTrue($collection->isEmpty(), "Empty collection"); - - $collection->add(1); - $this->assertFalse($collection->isEmpty(), "Not empty collection"); - } - - public function testContains() - { - $elements = array(1, 'A' => 'a', 2, 'null' => null, 3, 'A2' => 'a', 'zero' => 0); - $collection = new ArrayCollection($elements); - - $this->assertTrue($collection->contains(0), "Contains Zero"); - $this->assertTrue($collection->contains('a'), "Contains \"a\""); - $this->assertTrue($collection->contains(null), "Contains Null"); - $this->assertFalse($collection->contains('non-existent'), "Doesn't contain an element"); - } - - public function testExists() - { - $elements = array(1, 'A' => 'a', 2, 'null' => null, 3, 'A2' => 'a', 'zero' => 0); - $collection = new ArrayCollection($elements); - - $this->assertTrue($collection->exists(function($key, $element) { - return $key == 'A' && $element == 'a'; - }), "Element exists"); - - $this->assertFalse($collection->exists(function($key, $element) { - return $key == 'non-existent' && $element == 'non-existent'; - }), "Element not exists"); - } - - public function testIndexOf() - { - $elements = array(1, 'A' => 'a', 2, 'null' => null, 3, 'A2' => 'a', 'zero' => 0); - $collection = new ArrayCollection($elements); - - $this->assertSame(array_search(2, $elements, true), $collection->indexOf(2), 'Index of 2'); - $this->assertSame(array_search(null, $elements, true), $collection->indexOf(null), 'Index of null'); - $this->assertSame(array_search('non-existent', $elements, true), $collection->indexOf('non-existent'), 'Index of non existent'); - } - - public function testGet() - { - $elements = array(1, 'A' => 'a', 2, 'null' => null, 3, 'A2' => 'a', 'zero' => 0); - $collection = new ArrayCollection($elements); - - $this->assertSame(2, $collection->get(1), 'Get element by index'); - $this->assertSame('a', $collection->get('A'), 'Get element by name'); - $this->assertSame(null, $collection->get('non-existent'), 'Get non existent element'); - } - - public function testMatchingWithSortingPreservesyKeys() - { - $object1 = new \stdClass(); - $object2 = new \stdClass(); - - $object1->sortField = 2; - $object2->sortField = 1; - - $collection = new ArrayCollection(array( - 'object1' => $object1, - 'object2' => $object2, - )); - - $this->assertSame( - array( - 'object2' => $object2, - 'object1' => $object1, - ), - $collection - ->matching(new Criteria(null, array('sortField' => Criteria::ASC))) - ->toArray() - ); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ClosureExpressionVisitorTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ClosureExpressionVisitorTest.php deleted file mode 100644 index 21c2e3dfc..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ClosureExpressionVisitorTest.php +++ /dev/null @@ -1,250 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Collections; - -use Doctrine\Common\Collections\Expr\ClosureExpressionVisitor; -use Doctrine\Common\Collections\ExpressionBuilder; - -/** - * @group DDC-1637 - */ -class ClosureExpressionVisitorTest extends \PHPUnit_Framework_TestCase -{ - /** - * @var ClosureExpressionVisitor - */ - private $visitor; - - /** - * @var ExpressionBuilder - */ - private $builder; - - protected function setUp() - { - $this->visitor = new ClosureExpressionVisitor(); - $this->builder = new ExpressionBuilder(); - } - - public function testGetObjectFieldValueIsAccessor() - { - $object = new TestObject(1, 2, true); - - $this->assertTrue($this->visitor->getObjectFieldValue($object, 'baz')); - } - - public function testGetObjectFieldValueMagicCallMethod() - { - $object = new TestObject(1, 2, true, 3); - - $this->assertEquals(3, $this->visitor->getObjectFieldValue($object, 'qux')); - } - - public function testWalkEqualsComparison() - { - $closure = $this->visitor->walkComparison($this->builder->eq("foo", 1)); - - $this->assertTrue($closure(new TestObject(1))); - $this->assertFalse($closure(new TestObject(2))); - } - - public function testWalkNotEqualsComparison() - { - $closure = $this->visitor->walkComparison($this->builder->neq("foo", 1)); - - $this->assertFalse($closure(new TestObject(1))); - $this->assertTrue($closure(new TestObject(2))); - } - - public function testWalkLessThanComparison() - { - $closure = $this->visitor->walkComparison($this->builder->lt("foo", 1)); - - $this->assertFalse($closure(new TestObject(1))); - $this->assertTrue($closure(new TestObject(0))); - } - - public function testWalkLessThanEqualsComparison() - { - $closure = $this->visitor->walkComparison($this->builder->lte("foo", 1)); - - $this->assertFalse($closure(new TestObject(2))); - $this->assertTrue($closure(new TestObject(1))); - $this->assertTrue($closure(new TestObject(0))); - } - - public function testWalkGreaterThanEqualsComparison() - { - $closure = $this->visitor->walkComparison($this->builder->gte("foo", 1)); - - $this->assertTrue($closure(new TestObject(2))); - $this->assertTrue($closure(new TestObject(1))); - $this->assertFalse($closure(new TestObject(0))); - } - - public function testWalkGreaterThanComparison() - { - $closure = $this->visitor->walkComparison($this->builder->gt("foo", 1)); - - $this->assertTrue($closure(new TestObject(2))); - $this->assertFalse($closure(new TestObject(1))); - $this->assertFalse($closure(new TestObject(0))); - } - - public function testWalkInComparison() - { - $closure = $this->visitor->walkComparison($this->builder->in("foo", array(1, 2, 3))); - - $this->assertTrue($closure(new TestObject(2))); - $this->assertTrue($closure(new TestObject(1))); - $this->assertFalse($closure(new TestObject(0))); - } - - public function testWalkNotInComparison() - { - $closure = $this->visitor->walkComparison($this->builder->notIn("foo", array(1, 2, 3))); - - $this->assertFalse($closure(new TestObject(1))); - $this->assertFalse($closure(new TestObject(2))); - $this->assertTrue($closure(new TestObject(0))); - $this->assertTrue($closure(new TestObject(4))); - } - - public function testWalkContainsComparison() - { - $closure = $this->visitor->walkComparison($this->builder->contains('foo', 'hello')); - - $this->assertTrue($closure(new TestObject('hello world'))); - $this->assertFalse($closure(new TestObject('world'))); - } - - public function testWalkAndCompositeExpression() - { - $closure = $this->visitor->walkCompositeExpression( - $this->builder->andX( - $this->builder->eq("foo", 1), - $this->builder->eq("bar", 1) - ) - ); - - $this->assertTrue($closure(new TestObject(1, 1))); - $this->assertFalse($closure(new TestObject(1, 0))); - $this->assertFalse($closure(new TestObject(0, 1))); - $this->assertFalse($closure(new TestObject(0, 0))); - } - - public function testWalkOrCompositeExpression() - { - $closure = $this->visitor->walkCompositeExpression( - $this->builder->orX( - $this->builder->eq("foo", 1), - $this->builder->eq("bar", 1) - ) - ); - - $this->assertTrue($closure(new TestObject(1, 1))); - $this->assertTrue($closure(new TestObject(1, 0))); - $this->assertTrue($closure(new TestObject(0, 1))); - $this->assertFalse($closure(new TestObject(0, 0))); - } - - public function testSortByFieldAscending() - { - $objects = array(new TestObject("b"), new TestObject("a"), new TestObject("c")); - $sort = ClosureExpressionVisitor::sortByField("foo"); - - usort($objects, $sort); - - $this->assertEquals("a", $objects[0]->getFoo()); - $this->assertEquals("b", $objects[1]->getFoo()); - $this->assertEquals("c", $objects[2]->getFoo()); - } - - public function testSortByFieldDescending() - { - $objects = array(new TestObject("b"), new TestObject("a"), new TestObject("c")); - $sort = ClosureExpressionVisitor::sortByField("foo", -1); - - usort($objects, $sort); - - $this->assertEquals("c", $objects[0]->getFoo()); - $this->assertEquals("b", $objects[1]->getFoo()); - $this->assertEquals("a", $objects[2]->getFoo()); - } - - public function testSortDelegate() - { - $objects = array(new TestObject("a", "c"), new TestObject("a", "b"), new TestObject("a", "a")); - $sort = ClosureExpressionVisitor::sortByField("bar", 1); - $sort = ClosureExpressionVisitor::sortByField("foo", 1, $sort); - - usort($objects, $sort); - - $this->assertEquals("a", $objects[0]->getBar()); - $this->assertEquals("b", $objects[1]->getBar()); - $this->assertEquals("c", $objects[2]->getBar()); - } - - public function testArrayComparison() - { - $closure = $this->visitor->walkComparison($this->builder->eq("foo", 42)); - - $this->assertTrue($closure(array('foo' => 42))); - } -} - -class TestObject -{ - private $foo; - private $bar; - private $baz; - private $qux; - - public function __construct($foo = null, $bar = null, $baz = null, $qux = null) - { - $this->foo = $foo; - $this->bar = $bar; - $this->baz = $baz; - $this->qux = $qux; - } - - public function __call($name, $arguments) - { - if ('getqux' === $name) { - return $this->qux; - } - } - - public function getFoo() - { - return $this->foo; - } - - public function getBar() - { - return $this->bar; - } - - public function isBaz() - { - return $this->baz; - } -} - diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CollectionTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CollectionTest.php deleted file mode 100644 index f3f91ad3f..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CollectionTest.php +++ /dev/null @@ -1,265 +0,0 @@ -collection = new ArrayCollection(); - } - - public function testIssetAndUnset() - { - $this->assertFalse(isset($this->collection[0])); - $this->collection->add('testing'); - $this->assertTrue(isset($this->collection[0])); - unset($this->collection[0]); - $this->assertFalse(isset($this->collection[0])); - } - - public function testToString() - { - $this->collection->add('testing'); - $this->assertTrue(is_string((string) $this->collection)); - } - - public function testRemovingNonExistentEntryReturnsNull() - { - $this->assertEquals(null, $this->collection->remove('testing_does_not_exist')); - } - - public function testExists() - { - $this->collection->add("one"); - $this->collection->add("two"); - $exists = $this->collection->exists(function($k, $e) { return $e == "one"; }); - $this->assertTrue($exists); - $exists = $this->collection->exists(function($k, $e) { return $e == "other"; }); - $this->assertFalse($exists); - } - - public function testMap() - { - $this->collection->add(1); - $this->collection->add(2); - $res = $this->collection->map(function($e) { return $e * 2; }); - $this->assertEquals(array(2, 4), $res->toArray()); - } - - public function testFilter() - { - $this->collection->add(1); - $this->collection->add("foo"); - $this->collection->add(3); - $res = $this->collection->filter(function($e) { return is_numeric($e); }); - $this->assertEquals(array(0 => 1, 2 => 3), $res->toArray()); - } - - public function testFirstAndLast() - { - $this->collection->add('one'); - $this->collection->add('two'); - - $this->assertEquals($this->collection->first(), 'one'); - $this->assertEquals($this->collection->last(), 'two'); - } - - public function testArrayAccess() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - - $this->assertEquals($this->collection[0], 'one'); - $this->assertEquals($this->collection[1], 'two'); - - unset($this->collection[0]); - $this->assertEquals($this->collection->count(), 1); - } - - public function testContainsKey() - { - $this->collection[5] = 'five'; - $this->assertTrue($this->collection->containsKey(5)); - } - - public function testContains() - { - $this->collection[0] = 'test'; - $this->assertTrue($this->collection->contains('test')); - } - - public function testSearch() - { - $this->collection[0] = 'test'; - $this->assertEquals(0, $this->collection->indexOf('test')); - } - - public function testGet() - { - $this->collection[0] = 'test'; - $this->assertEquals('test', $this->collection->get(0)); - } - - public function testGetKeys() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->assertEquals(array(0, 1), $this->collection->getKeys()); - } - - public function testGetValues() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->assertEquals(array('one', 'two'), $this->collection->getValues()); - } - - public function testCount() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->assertEquals($this->collection->count(), 2); - $this->assertEquals(count($this->collection), 2); - } - - public function testForAll() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->assertEquals($this->collection->forAll(function($k, $e) { return is_string($e); }), true); - $this->assertEquals($this->collection->forAll(function($k, $e) { return is_array($e); }), false); - } - - public function testPartition() - { - $this->collection[] = true; - $this->collection[] = false; - $partition = $this->collection->partition(function($k, $e) { return $e == true; }); - $this->assertEquals($partition[0][0], true); - $this->assertEquals($partition[1][0], false); - } - - public function testClear() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->collection->clear(); - $this->assertEquals($this->collection->isEmpty(), true); - } - - public function testRemove() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $el = $this->collection->remove(0); - - $this->assertEquals('one', $el); - $this->assertEquals($this->collection->contains('one'), false); - $this->assertNull($this->collection->remove(0)); - } - - public function testRemoveElement() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - - $this->assertTrue($this->collection->removeElement('two')); - $this->assertFalse($this->collection->contains('two')); - $this->assertFalse($this->collection->removeElement('two')); - } - - public function testSlice() - { - $this->collection[] = 'one'; - $this->collection[] = 'two'; - $this->collection[] = 'three'; - - $slice = $this->collection->slice(0, 1); - $this->assertInternalType('array', $slice); - $this->assertEquals(array('one'), $slice); - - $slice = $this->collection->slice(1); - $this->assertEquals(array(1 => 'two', 2 => 'three'), $slice); - - $slice = $this->collection->slice(1, 1); - $this->assertEquals(array(1 => 'two'), $slice); - } - - public function fillMatchingFixture() - { - $std1 = new \stdClass(); - $std1->foo = "bar"; - $this->collection[] = $std1; - - $std2 = new \stdClass(); - $std2->foo = "baz"; - $this->collection[] = $std2; - } - - /** - * @group DDC-1637 - */ - public function testMatching() - { - $this->fillMatchingFixture(); - - $col = $this->collection->matching(new Criteria(Criteria::expr()->eq("foo", "bar"))); - $this->assertInstanceOf('Doctrine\Common\Collections\Collection', $col); - $this->assertNotSame($col, $this->collection); - $this->assertEquals(1, count($col)); - } - - /** - * @group DDC-1637 - */ - public function testMatchingOrdering() - { - $this->fillMatchingFixture(); - - $col = $this->collection->matching(new Criteria(null, array('foo' => 'DESC'))); - - $this->assertInstanceOf('Doctrine\Common\Collections\Collection', $col); - $this->assertNotSame($col, $this->collection); - $this->assertEquals(2, count($col)); - $this->assertEquals('baz', $col->first()->foo); - $this->assertEquals('bar', $col->last()->foo); - } - - /** - * @group DDC-1637 - */ - public function testMatchingSlice() - { - $this->fillMatchingFixture(); - - $col = $this->collection->matching(new Criteria(null, null, 1, 1)); - - $this->assertInstanceOf('Doctrine\Common\Collections\Collection', $col); - $this->assertNotSame($col, $this->collection); - $this->assertEquals(1, count($col)); - $this->assertEquals('baz', $col[0]->foo); - } - - public function testCanRemoveNullValuesByKey() - { - $this->collection->add(null); - $this->collection->remove(0); - $this->assertTrue($this->collection->isEmpty()); - } - - public function testCanVerifyExistingKeysWithNullValues() - { - $this->collection->set('key', null); - $this->assertTrue($this->collection->containsKey('key')); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CriteriaTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CriteriaTest.php deleted file mode 100644 index 1ab058a9b..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/CriteriaTest.php +++ /dev/null @@ -1,83 +0,0 @@ -assertInstanceOf('Doctrine\Common\Collections\Criteria', $criteria); - } - - public function testConstructor() - { - $expr = new Comparison("field", "=", "value"); - $criteria = new Criteria($expr, array("foo" => "ASC"), 10, 20); - - $this->assertSame($expr, $criteria->getWhereExpression()); - $this->assertEquals(array("foo" => "ASC"), $criteria->getOrderings()); - $this->assertEquals(10, $criteria->getFirstResult()); - $this->assertEquals(20, $criteria->getMaxResults()); - } - - public function testWhere() - { - $expr = new Comparison("field", "=", "value"); - $criteria = new Criteria(); - - $criteria->where($expr); - - $this->assertSame($expr, $criteria->getWhereExpression()); - } - - public function testAndWhere() - { - $expr = new Comparison("field", "=", "value"); - $criteria = new Criteria(); - - $criteria->where($expr); - $expr = $criteria->getWhereExpression(); - $criteria->andWhere($expr); - - $where = $criteria->getWhereExpression(); - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\CompositeExpression', $where); - - $this->assertEquals(CompositeExpression::TYPE_AND, $where->getType()); - $this->assertSame(array($expr, $expr), $where->getExpressionList()); - } - - public function testOrWhere() - { - $expr = new Comparison("field", "=", "value"); - $criteria = new Criteria(); - - $criteria->where($expr); - $expr = $criteria->getWhereExpression(); - $criteria->orWhere($expr); - - $where = $criteria->getWhereExpression(); - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\CompositeExpression', $where); - - $this->assertEquals(CompositeExpression::TYPE_OR, $where->getType()); - $this->assertSame(array($expr, $expr), $where->getExpressionList()); - } - - public function testOrderings() - { - $criteria = Criteria::create() - ->orderBy(array("foo" => "ASC")); - - $this->assertEquals(array("foo" => "ASC"), $criteria->getOrderings()); - } - - public function testExpr() - { - $this->assertInstanceOf('Doctrine\Common\Collections\ExpressionBuilder', Criteria::expr()); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ExpressionBuilderTest.php b/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ExpressionBuilderTest.php deleted file mode 100644 index 5f6b4ce2f..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/Common/Collections/ExpressionBuilderTest.php +++ /dev/null @@ -1,125 +0,0 @@ -builder = new ExpressionBuilder(); - } - - public function testAndX() - { - $expr = $this->builder->andX($this->builder->eq("a", "b")); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\CompositeExpression', $expr); - $this->assertEquals(CompositeExpression::TYPE_AND, $expr->getType()); - } - - public function testOrX() - { - $expr = $this->builder->orX($this->builder->eq("a", "b")); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\CompositeExpression', $expr); - $this->assertEquals(CompositeExpression::TYPE_OR, $expr->getType()); - } - - public function testInvalidAndXArgument() - { - $this->setExpectedException("RuntimeException"); - $this->builder->andX("foo"); - } - - public function testEq() - { - $expr = $this->builder->eq("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::EQ, $expr->getOperator()); - } - - public function testNeq() - { - $expr = $this->builder->neq("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::NEQ, $expr->getOperator()); - } - - public function testLt() - { - $expr = $this->builder->lt("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::LT, $expr->getOperator()); - } - - public function testGt() - { - $expr = $this->builder->gt("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::GT, $expr->getOperator()); - } - - public function testGte() - { - $expr = $this->builder->gte("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::GTE, $expr->getOperator()); - } - - public function testLte() - { - $expr = $this->builder->lte("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::LTE, $expr->getOperator()); - } - - public function testIn() - { - $expr = $this->builder->in("a", array("b")); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::IN, $expr->getOperator()); - } - - public function testNotIn() - { - $expr = $this->builder->notIn("a", array("b")); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::NIN, $expr->getOperator()); - } - - public function testIsNull() - { - $expr = $this->builder->isNull("a"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::EQ, $expr->getOperator()); - } - - public function testContains() - { - $expr = $this->builder->contains("a", "b"); - - $this->assertInstanceOf('Doctrine\Common\Collections\Expr\Comparison', $expr); - $this->assertEquals(Comparison::CONTAINS, $expr->getOperator()); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/LazyArrayCollection.php b/vendor/doctrine/collections/tests/Doctrine/Tests/LazyArrayCollection.php deleted file mode 100644 index 56736b83b..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/LazyArrayCollection.php +++ /dev/null @@ -1,22 +0,0 @@ -collection = new ArrayCollection(array('a', 'b', 'c')); - } -} diff --git a/vendor/doctrine/collections/tests/Doctrine/Tests/TestInit.php b/vendor/doctrine/collections/tests/Doctrine/Tests/TestInit.php deleted file mode 100644 index 973b5fef6..000000000 --- a/vendor/doctrine/collections/tests/Doctrine/Tests/TestInit.php +++ /dev/null @@ -1,21 +0,0 @@ -setIncludePath(__DIR__); - $classLoader->setFileExtension('.class.php'); - $classLoader->setNamespaceSeparator('_'); - - $this->assertTrue($classLoader->canLoadClass('ClassLoaderTest_ClassA')); - $this->assertTrue($classLoader->canLoadClass('ClassLoaderTest_ClassB')); - $this->assertTrue($classLoader->canLoadClass('ClassLoaderTest_ClassC')); - $this->assertFalse($classLoader->canLoadClass('OtherClass')); - $this->assertEquals($classLoader->loadClass('ClassLoaderTest_ClassA'), true); - $this->assertEquals($classLoader->loadClass('ClassLoaderTest_ClassB'), true); - $this->assertEquals($classLoader->loadClass('ClassLoaderTest_ClassC'), true); - } - - public function testClassExists() - { - $this->assertFalse(ClassLoader::classExists('ClassLoaderTest\ClassD')); - $badLoader = function($className) { - require __DIR__ . '/ClassLoaderTest/ClassD.php'; - return true; - }; - spl_autoload_register($badLoader); - $this->assertTrue(ClassLoader::classExists('ClassLoaderTest\ClassD')); - spl_autoload_unregister($badLoader); - } - - public function testGetClassLoader() - { - $cl = new ClassLoader('ClassLoaderTest', __DIR__); - $cl->register(); - $this->assertTrue(ClassLoader::getClassLoader('ClassLoaderTest\ClassD') instanceof \Doctrine\Common\ClassLoader); - $this->assertNull(ClassLoader::getClassLoader('This\Class\Does\Not\Exist')); - $cl->unregister(); - } - - public function testClassExistsWithSilentAutoloader() - { - $test = $this; - $silentLoader = function ($className) use ($test) { - $test->assertSame('ClassLoaderTest\ClassE', $className); - require __DIR__ . '/ClassLoaderTest/ClassE.php'; - }; - $additionalLoader = function () use ($test) { - $test->fail('Should not call this loader, class was already loaded'); - }; - - $this->assertFalse(ClassLoader::classExists('ClassLoaderTest\ClassE')); - spl_autoload_register($silentLoader); - spl_autoload_register($additionalLoader); - $this->assertTrue(ClassLoader::classExists('ClassLoaderTest\ClassE')); - spl_autoload_unregister($additionalLoader); - spl_autoload_unregister($silentLoader); - } - - public function testClassExistsWhenLoaderIsProtected() - { - require_once __DIR__ . '/ClassLoaderTest/ExternalLoader.php'; - - // Test static call - \ClassLoaderTest\ExternalLoader::registerStatic(); - $this->assertFalse(ClassLoader::classExists('ClassLoaderTest\Class\That\Does\Not\Exist')); - \ClassLoaderTest\ExternalLoader::unregisterStatic(); - - // Test object - $loader = new \ClassLoaderTest\ExternalLoader(); - $loader->register(); - $this->assertFalse(ClassLoader::classExists('ClassLoaderTest\Class\That\Does\Not\Exist')); - $loader->unregister(); - } - - public function testLoadNonExistingClass() - { - $classLoader = new ClassLoader('ClassLoaderTest', __DIR__); - - $this->assertFalse($classLoader->loadClass('ClassLoaderTest\Non\Existing\ClassName')); - } - - public function testLoadFileNotContainingClassClass() - { - $classLoader = new ClassLoader('ClassLoaderTest', __DIR__); - - $classLoader->setFileExtension('.class.php'); - - $this->assertFalse($classLoader->loadClass('ClassLoaderTest\EmptyFile')); - } - - public function testSupportsInterfaceAutoloading() - { - $classLoader = new ClassLoader(); - $classLoader->setIncludePath(__DIR__); - $classLoader->setFileExtension('.class.php'); - $classLoader->setNamespaceSeparator('_'); - - $this->assertTrue($classLoader->loadClass('ClassLoaderTest_InterfaceA')); - $this->assertTrue(interface_exists('ClassLoaderTest_InterfaceA', false)); - } - - public function testSupportsTraitAutoloading() - { - if (! function_exists('trait_exists')) { - $this->markTestSkipped('You need a PHP version that supports traits in order to run this test'); - } - - $classLoader = new ClassLoader(); - $classLoader->setIncludePath(__DIR__); - $classLoader->setFileExtension('.class.php'); - $classLoader->setNamespaceSeparator('_'); - - $this->assertTrue($classLoader->loadClass('ClassLoaderTest_TraitA')); - $this->assertTrue(trait_exists('ClassLoaderTest_TraitA', false)); - } - - public function testMultipleAutoloadRequestsWillProduceSameResult() - { - $classLoader = new ClassLoader(); - $classLoader->setIncludePath(__DIR__); - $classLoader->setFileExtension('.class.php'); - $classLoader->setNamespaceSeparator('_'); - - $this->assertTrue($classLoader->loadClass('ClassLoaderTest_ClassA')); - $this->assertTrue($classLoader->loadClass('ClassLoaderTest_ClassA')); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassA.class.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassA.class.php deleted file mode 100644 index 855465473..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/ClassLoaderTest/ClassA.class.php +++ /dev/null @@ -1,6 +0,0 @@ -_eventManager = new EventManager; - $this->_preFooInvoked = false; - $this->_postFooInvoked = false; - } - - public function testInitialState() - { - $this->assertEquals(array(), $this->_eventManager->getListeners()); - $this->assertFalse($this->_eventManager->hasListeners(self::preFoo)); - $this->assertFalse($this->_eventManager->hasListeners(self::postFoo)); - } - - public function testAddEventListener() - { - $this->_eventManager->addEventListener(array('preFoo', 'postFoo'), $this); - $this->assertTrue($this->_eventManager->hasListeners(self::preFoo)); - $this->assertTrue($this->_eventManager->hasListeners(self::postFoo)); - $this->assertEquals(1, count($this->_eventManager->getListeners(self::preFoo))); - $this->assertEquals(1, count($this->_eventManager->getListeners(self::postFoo))); - $this->assertEquals(2, count($this->_eventManager->getListeners())); - } - - public function testDispatchEvent() - { - $this->_eventManager->addEventListener(array('preFoo', 'postFoo'), $this); - $this->_eventManager->dispatchEvent(self::preFoo); - $this->assertTrue($this->_preFooInvoked); - $this->assertFalse($this->_postFooInvoked); - } - - public function testRemoveEventListener() - { - $this->_eventManager->addEventListener(array('preBar'), $this); - $this->assertTrue($this->_eventManager->hasListeners(self::preBar)); - $this->_eventManager->removeEventListener(array('preBar'), $this); - $this->assertFalse($this->_eventManager->hasListeners(self::preBar)); - } - - public function testAddEventSubscriber() - { - $eventSubscriber = new TestEventSubscriber(); - $this->_eventManager->addEventSubscriber($eventSubscriber); - $this->assertTrue($this->_eventManager->hasListeners(self::preFoo)); - $this->assertTrue($this->_eventManager->hasListeners(self::postFoo)); - } - - /* Listener methods */ - - public function preFoo(EventArgs $e) - { - $this->_preFooInvoked = true; - } - - public function postFoo(EventArgs $e) - { - $this->_postFooInvoked = true; - } -} - -class TestEventSubscriber implements \Doctrine\Common\EventSubscriber -{ - public function getSubscribedEvents() - { - return array('preFoo', 'postFoo'); - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/ManagerRegistryTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/ManagerRegistryTest.php deleted file mode 100644 index 7c9329091..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/ManagerRegistryTest.php +++ /dev/null @@ -1,97 +0,0 @@ -mr = new TestManagerRegistry( - 'ORM', - array('default_connection'), - array('default_manager'), - 'default', - 'default', - 'Doctrine\Common\Persistence\ObjectManagerAware' - ); - } - - public function testGetManagerForClass() - { - $this->mr->getManagerForClass('Doctrine\Tests\Common\Persistence\TestObject'); - } - - public function testGetManagerForInvalidClass() - { - $this->setExpectedException( - 'ReflectionException', - 'Class Doctrine\Tests\Common\Persistence\TestObjectInexistent does not exist' - ); - - $this->mr->getManagerForClass('prefix:TestObjectInexistent'); - } - - public function testGetManagerForAliasedClass() - { - $this->mr->getManagerForClass('prefix:TestObject'); - } - - public function testGetManagerForInvalidAliasedClass() - { - $this->setExpectedException( - 'ReflectionException', - 'Class Doctrine\Tests\Common\Persistence\TestObject:Foo does not exist' - ); - - $this->mr->getManagerForClass('prefix:TestObject:Foo'); - } -} - -class TestManager extends PHPUnit_Framework_TestCase -{ - public function getMetadataFactory() - { - $driver = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - - return new TestClassMetadataFactory($driver, $metadata); - } -} - -class TestManagerRegistry extends AbstractManagerRegistry -{ - protected function getService($name) - { - return new TestManager(); - } - - /** - * {@inheritdoc} - */ - protected function resetService($name) - { - - } - - public function getAliasNamespace($alias) - { - return __NAMESPACE__; - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/AnnotationDriverTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/AnnotationDriverTest.php deleted file mode 100644 index ab6cc5ce4..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/AnnotationDriverTest.php +++ /dev/null @@ -1,29 +0,0 @@ -getAllClassNames(); - - $this->assertEquals(array('Doctrine\TestClass'), $classes); - } -} - -class SimpleAnnotationDriver extends AnnotationDriver -{ - protected $entityAnnotationClasses = array('Doctrine\Entity' => true); - - public function loadMetadataForClass($className, ClassMetadata $metadata) - { - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ChainDriverTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ChainDriverTest.php deleted file mode 100644 index f9edd10f0..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ChainDriverTest.php +++ /dev/null @@ -1,152 +0,0 @@ -getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - - $chain = new MappingDriverChain(); - - $driver1 = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $driver1->expects($this->never()) - ->method('loadMetadataForClass'); - $driver1->expectS($this->never()) - ->method('isTransient'); - - $driver2 = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $driver2->expects($this->at(0)) - ->method('loadMetadataForClass') - ->with($this->equalTo($className), $this->equalTo($classMetadata)); - $driver2->expects($this->at(1)) - ->method('isTransient') - ->with($this->equalTo($className)) - ->will($this->returnValue( true )); - - $chain->addDriver($driver1, 'Doctrine\Tests\Models\Company'); - $chain->addDriver($driver2, 'Doctrine\Tests\Common\Persistence\Mapping'); - - $chain->loadMetadataForClass($className, $classMetadata); - - $this->assertTrue( $chain->isTransient($className) ); - } - - public function testLoadMetadata_NoDelegatorFound_ThrowsMappingException() - { - $className = 'Doctrine\Tests\Common\Persistence\Mapping\DriverChainEntity'; - $classMetadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - - $chain = new MappingDriverChain(); - - $this->setExpectedException('Doctrine\Common\Persistence\Mapping\MappingException'); - $chain->loadMetadataForClass($className, $classMetadata); - } - - public function testGatherAllClassNames() - { - $className = 'Doctrine\Tests\Common\Persistence\Mapping\DriverChainEntity'; - $classMetadata = $this->getMock('Doctrine\Common\Persistence\ClassMetadata'); - - $chain = new MappingDriverChain(); - - $driver1 = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $driver1->expects($this->once()) - ->method('getAllClassNames') - ->will($this->returnValue(array('Doctrine\Tests\Models\Company\Foo'))); - - $driver2 = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $driver2->expects($this->once()) - ->method('getAllClassNames') - ->will($this->returnValue(array('Doctrine\Tests\ORM\Mapping\Bar', 'Doctrine\Tests\ORM\Mapping\Baz', 'FooBarBaz'))); - - $chain->addDriver($driver1, 'Doctrine\Tests\Models\Company'); - $chain->addDriver($driver2, 'Doctrine\Tests\ORM\Mapping'); - - $this->assertEquals(array( - 'Doctrine\Tests\Models\Company\Foo', - 'Doctrine\Tests\ORM\Mapping\Bar', - 'Doctrine\Tests\ORM\Mapping\Baz' - ), $chain->getAllClassNames()); - } - - /** - * @group DDC-706 - */ - public function testIsTransient() - { - $driver1 = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $chain = new MappingDriverChain(); - $chain->addDriver($driver1, 'Doctrine\Tests\Models\CMS'); - - $this->assertTrue($chain->isTransient('stdClass'), "stdClass isTransient"); - } - - /** - * @group DDC-1412 - */ - public function testDefaultDriver() - { - $companyDriver = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $defaultDriver = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $entityClassName = 'Doctrine\Tests\ORM\Mapping\DriverChainEntity'; - $managerClassName = 'Doctrine\Tests\Models\Company\CompanyManager'; - $chain = new MappingDriverChain(); - - $companyDriver->expects($this->never()) - ->method('loadMetadataForClass'); - $companyDriver->expects($this->once()) - ->method('isTransient') - ->with($this->equalTo($managerClassName)) - ->will($this->returnValue(false)); - - $defaultDriver->expects($this->never()) - ->method('loadMetadataForClass'); - $defaultDriver->expects($this->once()) - ->method('isTransient') - ->with($this->equalTo($entityClassName)) - ->will($this->returnValue(true)); - - $this->assertNull($chain->getDefaultDriver()); - - $chain->setDefaultDriver($defaultDriver); - $chain->addDriver($companyDriver, 'Doctrine\Tests\Models\Company'); - - $this->assertSame($defaultDriver, $chain->getDefaultDriver()); - - $this->assertTrue($chain->isTransient($entityClassName)); - $this->assertFalse($chain->isTransient($managerClassName)); - } - - public function testDefaultDriverGetAllClassNames() - { - $companyDriver = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $defaultDriver = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $chain = new MappingDriverChain(); - - $companyDriver->expects($this->once()) - ->method('getAllClassNames') - ->will($this->returnValue(array('Doctrine\Tests\Models\Company\Foo'))); - - $defaultDriver->expects($this->once()) - ->method('getAllClassNames') - ->will($this->returnValue(array('Other\Class'))); - - $chain->setDefaultDriver($defaultDriver); - $chain->addDriver($companyDriver, 'Doctrine\Tests\Models\Company'); - - $classNames = $chain->getAllClassNames(); - - $this->assertEquals(array('Doctrine\Tests\Models\Company\Foo', 'Other\Class'), $classNames); - } -} - -class DriverChainEntity -{ - -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ClassMetadataFactoryTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ClassMetadataFactoryTest.php deleted file mode 100644 index b3815de97..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/ClassMetadataFactoryTest.php +++ /dev/null @@ -1,209 +0,0 @@ -getMock('Doctrine\Common\Persistence\Mapping\Driver\MappingDriver'); - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $this->cmf = new TestClassMetadataFactory($driver, $metadata); - } - - public function testGetCacheDriver() - { - $this->assertNull($this->cmf->getCacheDriver()); - $cache = new ArrayCache(); - $this->cmf->setCacheDriver($cache); - $this->assertSame($cache, $this->cmf->getCacheDriver()); - } - - public function testGetMetadataFor() - { - $metadata = $this->cmf->getMetadataFor('stdClass'); - - $this->assertInstanceOf('Doctrine\Common\Persistence\Mapping\ClassMetadata', $metadata); - $this->assertTrue($this->cmf->hasMetadataFor('stdClass')); - } - - public function testGetMetadataForAbsentClass() - { - $this->setExpectedException('Doctrine\Common\Persistence\Mapping\MappingException'); - $this->cmf->getMetadataFor(__NAMESPACE__ . '\AbsentClass'); - } - - public function testGetParentMetadata() - { - $metadata = $this->cmf->getMetadataFor(__NAMESPACE__ . '\ChildEntity'); - - $this->assertInstanceOf('Doctrine\Common\Persistence\Mapping\ClassMetadata', $metadata); - $this->assertTrue($this->cmf->hasMetadataFor(__NAMESPACE__ . '\ChildEntity')); - $this->assertTrue($this->cmf->hasMetadataFor(__NAMESPACE__ . '\RootEntity')); - } - - public function testGetCachedMetadata() - { - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $cache = new ArrayCache(); - $cache->save(__NAMESPACE__. '\ChildEntity$CLASSMETADATA', $metadata); - - $this->cmf->setCacheDriver($cache); - - $loadedMetadata = $this->cmf->getMetadataFor(__NAMESPACE__ . '\ChildEntity'); - $this->assertSame($loadedMetadata, $metadata); - } - - public function testCacheGetMetadataFor() - { - $cache = new ArrayCache(); - $this->cmf->setCacheDriver($cache); - - $loadedMetadata = $this->cmf->getMetadataFor(__NAMESPACE__ . '\ChildEntity'); - - $this->assertSame($loadedMetadata, $cache->fetch(__NAMESPACE__. '\ChildEntity$CLASSMETADATA')); - } - - public function testGetAliasedMetadata() - { - $this->cmf->getMetadataFor('prefix:ChildEntity'); - - $this->assertTrue($this->cmf->hasMetadataFor(__NAMESPACE__ . '\ChildEntity')); - $this->assertTrue($this->cmf->hasMetadataFor('prefix:ChildEntity')); - } - - /** - * @group DCOM-270 - */ - public function testGetInvalidAliasedMetadata() - { - $this->setExpectedException( - 'Doctrine\Common\Persistence\Mapping\MappingException', - 'Class \'Doctrine\Tests\Common\Persistence\Mapping\ChildEntity:Foo\' does not exist' - ); - - $this->cmf->getMetadataFor('prefix:ChildEntity:Foo'); - } - - /** - * @group DCOM-270 - */ - public function testClassIsTransient() - { - $this->assertTrue($this->cmf->isTransient('prefix:ChildEntity:Foo')); - } - - public function testWillFallbackOnNotLoadedMetadata() - { - $classMetadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - - $this->cmf->fallbackCallback = function () use ($classMetadata) { - return $classMetadata; - }; - - $this->cmf->metadata = null; - - $this->assertSame($classMetadata, $this->cmf->getMetadataFor('Foo')); - } - - public function testWillFailOnFallbackFailureWithNotLoadedMetadata() - { - $this->cmf->fallbackCallback = function () { - return null; - }; - - $this->cmf->metadata = null; - - $this->setExpectedException('Doctrine\Common\Persistence\Mapping\MappingException'); - - $this->cmf->getMetadataFor('Foo'); - } -} - -class TestClassMetadataFactory extends AbstractClassMetadataFactory -{ - public $driver; - public $metadata; - - /** @var callable|null */ - public $fallbackCallback; - - public function __construct($driver, $metadata) - { - $this->driver = $driver; - $this->metadata = $metadata; - } - - protected function doLoadMetadata($class, $parent, $rootEntityFound, array $nonSuperclassParents) - { - - } - - protected function getFqcnFromAlias($namespaceAlias, $simpleClassName) - { - return __NAMESPACE__ . '\\' . $simpleClassName; - } - - protected function initialize() - { - - } - - protected function newClassMetadataInstance($className) - { - return $this->metadata; - } - - protected function getDriver() - { - return $this->driver; - } - protected function wakeupReflection(ClassMetadata $class, ReflectionService $reflService) - { - } - - protected function initializeReflection(ClassMetadata $class, ReflectionService $reflService) - { - } - - protected function isEntity(ClassMetadata $class) - { - return true; - } - - protected function onNotFoundMetadata($className) - { - if (! $fallback = $this->fallbackCallback) { - return null; - } - - return $fallback(); - } - - public function isTransient($class) - { - return true; - } -} - -class RootEntity -{ - -} - -class ChildEntity extends RootEntity -{ - -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/DefaultFileLocatorTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/DefaultFileLocatorTest.php deleted file mode 100644 index 37072de6a..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/DefaultFileLocatorTest.php +++ /dev/null @@ -1,90 +0,0 @@ -assertEquals(array($path), $locator->getPaths()); - - $locator = new DefaultFileLocator($path); - $this->assertEquals(array($path), $locator->getPaths()); - } - - public function testGetFileExtension() - { - $locator = new DefaultFileLocator(array(), ".yml"); - $this->assertEquals(".yml", $locator->getFileExtension()); - $locator->setFileExtension(".xml"); - $this->assertEquals(".xml", $locator->getFileExtension()); - } - - public function testUniquePaths() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path, $path)); - $this->assertEquals(array($path), $locator->getPaths()); - } - - public function testFindMappingFile() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path), ".yml"); - - $this->assertEquals(__DIR__ . '/_files' . DIRECTORY_SEPARATOR . 'stdClass.yml', $locator->findMappingFile('stdClass')); - } - - public function testFindMappingFileNotFound() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path), ".yml"); - - $this->setExpectedException( - 'Doctrine\Common\Persistence\Mapping\MappingException', - "No mapping file found named 'stdClass2.yml' for class 'stdClass2'" - ); - $locator->findMappingFile('stdClass2'); - } - - public function testGetAllClassNames() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path), ".yml"); - $classes = $locator->getAllClassNames(null); - sort($classes); - - $this->assertEquals(array('global', 'stdClass'), $classes); - $this->assertEquals(array('stdClass'), $locator->getAllClassNames("global")); - } - - public function testGetAllClassNamesNonMatchingFileExtension() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path), ".xml"); - $this->assertEquals(array(), $locator->getAllClassNames("global")); - } - - public function testFileExists() - { - $path = __DIR__ . "/_files"; - - $locator = new DefaultFileLocator(array($path), ".yml"); - - $this->assertTrue($locator->fileExists("stdClass")); - $this->assertFalse($locator->fileExists("stdClass2")); - $this->assertTrue($locator->fileExists("global")); - $this->assertFalse($locator->fileExists("global2")); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/FileDriverTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/FileDriverTest.php deleted file mode 100644 index 020c24247..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/FileDriverTest.php +++ /dev/null @@ -1,142 +0,0 @@ -assertNull($driver->getGlobalBasename()); - - $driver->setGlobalBasename("global"); - $this->assertEquals("global", $driver->getGlobalBasename()); - } - - public function testGetElementFromGlobalFile() - { - $driver = new TestFileDriver($this->newLocator()); - $driver->setGlobalBasename("global"); - - $element = $driver->getElement('stdGlobal'); - - $this->assertEquals('stdGlobal', $element); - } - - public function testGetElementFromFile() - { - $locator = $this->newLocator(); - $locator->expects($this->once()) - ->method('findMappingFile') - ->with($this->equalTo('stdClass')) - ->will($this->returnValue(__DIR__ . '/_files/stdClass.yml')); - - $driver = new TestFileDriver($locator); - - $this->assertEquals('stdClass', $driver->getElement('stdClass')); - } - - public function testGetAllClassNamesGlobalBasename() - { - $driver = new TestFileDriver($this->newLocator()); - $driver->setGlobalBasename("global"); - - $classNames = $driver->getAllClassNames(); - - $this->assertEquals(array('stdGlobal', 'stdGlobal2'), $classNames); - } - - public function testGetAllClassNamesFromMappingFile() - { - $locator = $this->newLocator(); - $locator->expects($this->any()) - ->method('getAllClassNames') - ->with($this->equalTo(null)) - ->will($this->returnValue(array('stdClass'))); - $driver = new TestFileDriver($locator); - - $classNames = $driver->getAllClassNames(); - - $this->assertEquals(array('stdClass'), $classNames); - } - - public function testGetAllClassNamesBothSources() - { - $locator = $this->newLocator(); - $locator->expects($this->any()) - ->method('getAllClassNames') - ->with($this->equalTo('global')) - ->will($this->returnValue(array('stdClass'))); - $driver = new TestFileDriver($locator); - $driver->setGlobalBasename("global"); - - $classNames = $driver->getAllClassNames(); - - $this->assertEquals(array('stdGlobal', 'stdGlobal2', 'stdClass'), $classNames); - } - - public function testIsNotTransient() - { - $locator = $this->newLocator(); - $locator->expects($this->once()) - ->method('fileExists') - ->with($this->equalTo('stdClass')) - ->will($this->returnValue( true )); - - $driver = new TestFileDriver($locator); - $driver->setGlobalBasename("global"); - - $this->assertFalse($driver->isTransient('stdClass')); - $this->assertFalse($driver->isTransient('stdGlobal')); - $this->assertFalse($driver->isTransient('stdGlobal2')); - } - - public function testIsTransient() - { - $locator = $this->newLocator(); - $locator->expects($this->once()) - ->method('fileExists') - ->with($this->equalTo('stdClass2')) - ->will($this->returnValue( false )); - - $driver = new TestFileDriver($locator); - - $this->assertTrue($driver->isTransient('stdClass2')); - } - - public function testNonLocatorFallback() - { - $driver = new TestFileDriver(__DIR__ . '/_files', '.yml'); - $this->assertTrue($driver->isTransient('stdClass2')); - $this->assertFalse($driver->isTransient('stdClass')); - } - - private function newLocator() - { - $locator = $this->getMock('Doctrine\Common\Persistence\Mapping\Driver\FileLocator'); - $locator->expects($this->any())->method('getFileExtension')->will($this->returnValue('.yml')); - $locator->expects($this->any())->method('getPaths')->will($this->returnValue(array(__DIR__ . "/_files"))); - return $locator; - } -} - -class TestFileDriver extends FileDriver -{ - protected function loadMappingFile($file) - { - if (strpos($file, "global.yml") !== false) { - return array('stdGlobal' => 'stdGlobal', 'stdGlobal2' => 'stdGlobal2'); - } - return array('stdClass' => 'stdClass'); - } - - public function loadMetadataForClass($className, ClassMetadata $metadata) - { - - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/PHPDriverTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/PHPDriverTest.php deleted file mode 100644 index 8fc4d8071..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/PHPDriverTest.php +++ /dev/null @@ -1,18 +0,0 @@ -getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $metadata->expects($this->once())->method('getFieldNames'); - - $driver = new PHPDriver(array(__DIR__ . "/_files")); - $driver->loadMetadataForClass('TestEntity', $metadata); - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/RuntimeReflectionServiceTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/RuntimeReflectionServiceTest.php deleted file mode 100644 index 767ccd639..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/RuntimeReflectionServiceTest.php +++ /dev/null @@ -1,84 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Persistence\Mapping; - -use Doctrine\Common\Persistence\Mapping\RuntimeReflectionService; - -/** - * @group DCOM-93 - */ -class RuntimeReflectionServiceTest extends \PHPUnit_Framework_TestCase -{ - /** - * @var RuntimeReflectionService - */ - private $reflectionService; - - public $unusedPublicProperty; - - public function setUp() - { - $this->reflectionService = new RuntimeReflectionService(); - } - - public function testShortname() - { - $this->assertEquals("RuntimeReflectionServiceTest", $this->reflectionService->getClassShortName(__CLASS__)); - } - - public function testClassNamespaceName() - { - $this->assertEquals("Doctrine\Tests\Common\Persistence\Mapping", $this->reflectionService->getClassNamespace(__CLASS__)); - } - - public function testGetParentClasses() - { - $classes = $this->reflectionService->getParentClasses(__CLASS__); - $this->assertTrue(count($classes) >= 1, "The test class ".__CLASS__." should have at least one parent."); - } - - public function testGetParentClassesForAbsentClass() - { - $this->setExpectedException('Doctrine\Common\Persistence\Mapping\MappingException'); - $this->reflectionService->getParentClasses(__NAMESPACE__ . '\AbsentClass'); - } - - public function testGetReflectionClass() - { - $class = $this->reflectionService->getClass(__CLASS__); - $this->assertInstanceOf("ReflectionClass", $class); - } - - public function testGetMethods() - { - $this->assertTrue($this->reflectionService->hasPublicMethod(__CLASS__, "testGetMethods")); - $this->assertFalse($this->reflectionService->hasPublicMethod(__CLASS__, "testGetMethods2")); - } - - public function testGetAccessibleProperty() - { - $reflProp = $this->reflectionService->getAccessibleProperty(__CLASS__, "reflectionService"); - $this->assertInstanceOf("ReflectionProperty", $reflProp); - - $reflProp = $this->reflectionService->getAccessibleProperty(__CLASS__, "unusedPublicProperty"); - $this->assertInstanceOf("Doctrine\Common\Reflection\RuntimePublicReflectionProperty", $reflProp); - } -} - diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticPHPDriverTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticPHPDriverTest.php deleted file mode 100644 index 9f1c5684e..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticPHPDriverTest.php +++ /dev/null @@ -1,35 +0,0 @@ -getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $metadata->expects($this->once())->method('getFieldNames'); - - $driver = new StaticPHPDriver(array(__DIR__)); - $driver->loadMetadataForClass(__NAMESPACE__ . '\\TestEntity', $metadata); - } - - public function testGetAllClassNames() - { - $driver = new StaticPHPDriver(array(__DIR__)); - $classNames = $driver->getAllClassNames(); - - $this->assertContains( - 'Doctrine\Tests\Common\Persistence\Mapping\TestEntity', $classNames); - } -} - -class TestEntity -{ - static public function loadMetadata($metadata) - { - $metadata->getFieldNames(); - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticReflectionServiceTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticReflectionServiceTest.php deleted file mode 100644 index 9054b6c31..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/StaticReflectionServiceTest.php +++ /dev/null @@ -1,70 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Persistence\Mapping; - -use Doctrine\Common\Persistence\Mapping\StaticReflectionService; - -/** - * @group DCOM-93 - */ -class StaticReflectionServiceTest extends \PHPUnit_Framework_TestCase -{ - private $reflectionService; - - public function setUp() - { - $this->reflectionService = new StaticReflectionService(); - } - - public function testShortname() - { - $this->assertEquals("StaticReflectionServiceTest", $this->reflectionService->getClassShortName(__CLASS__)); - } - - public function testClassNamespaceName() - { - $this->assertEquals("Doctrine\Tests\Common\Persistence\Mapping", $this->reflectionService->getClassNamespace(__CLASS__)); - } - - public function testGetParentClasses() - { - $classes = $this->reflectionService->getParentClasses(__CLASS__); - $this->assertTrue(count($classes) == 0, "The test class ".__CLASS__." should have no parents according to static reflection."); - } - - public function testGetReflectionClass() - { - $class = $this->reflectionService->getClass(__CLASS__); - $this->assertNull($class); - } - - public function testGetMethods() - { - $this->assertTrue($this->reflectionService->hasPublicMethod(__CLASS__, "testGetMethods")); - $this->assertTrue($this->reflectionService->hasPublicMethod(__CLASS__, "testGetMethods2")); - } - - public function testGetAccessibleProperty() - { - $reflProp = $this->reflectionService->getAccessibleProperty(__CLASS__, "reflectionService"); - $this->assertNull($reflProp); - } -} - diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/SymfonyFileLocatorTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/SymfonyFileLocatorTest.php deleted file mode 100644 index e79b8f45d..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/SymfonyFileLocatorTest.php +++ /dev/null @@ -1,173 +0,0 @@ - $prefix)); - $this->assertEquals(array($path), $locator->getPaths()); - - $locator = new SymfonyFileLocator(array($path => $prefix)); - $this->assertEquals(array($path), $locator->getPaths()); - } - - public function testGetPrefixes() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix)); - $this->assertEquals(array($path => $prefix), $locator->getNamespacePrefixes()); - } - - public function testGetFileExtension() - { - $locator = new SymfonyFileLocator(array(), ".yml"); - $this->assertEquals(".yml", $locator->getFileExtension()); - $locator->setFileExtension(".xml"); - $this->assertEquals(".xml", $locator->getFileExtension()); - } - - public function testFileExists() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml"); - - $this->assertTrue($locator->fileExists("Foo\stdClass")); - $this->assertTrue($locator->fileExists("Foo\global")); - $this->assertFalse($locator->fileExists("Foo\stdClass2")); - $this->assertFalse($locator->fileExists("Foo\global2")); - } - - public function testGetAllClassNames() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml"); - $classes = $locator->getAllClassNames(null); - sort($classes); - - $this->assertEquals(array("Foo\\global", "Foo\\stdClass"), $classes); - $this->assertEquals(array("Foo\\stdClass"), $locator->getAllClassNames("global")); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Namespace separator should not be empty - */ - public function testInvalidCustomNamespaceSeparator() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - new SymfonyFileLocator(array($path => $prefix), ".yml", null); - } - - public function customNamespaceSeparatorProvider() - { - return array( - 'directory separator' => array(DIRECTORY_SEPARATOR, "/_custom_ns/dir"), - 'default dot separator' => array('.', "/_custom_ns/dot"), - ); - } - - /** - * @dataProvider customNamespaceSeparatorProvider - * - * @param $separator string Directory separator to test against - * @param $dir string Path to load mapping data from - * - * @throws \Doctrine\Common\Persistence\Mapping\MappingException - */ - public function testGetClassNamesWithCustomNsSeparator($separator, $dir) - { - $path = __DIR__ . $dir; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml", $separator); - $classes = $locator->getAllClassNames(null); - sort($classes); - - $this->assertEquals(array("Foo\\stdClass", "Foo\\sub\\subClass", "Foo\\sub\\subsub\\subSubClass"), $classes); - } - - public function customNamespaceLookupQueryProvider() - { - return array( - 'directory separator' => array( - DIRECTORY_SEPARATOR, - "/_custom_ns/dir", - array( - "stdClass.yml" => "Foo\\stdClass", - "sub/subClass.yml" => "Foo\\sub\\subClass", - "sub/subsub/subSubClass.yml" => "Foo\\sub\\subsub\\subSubClass", - ) - ), - 'default dot separator' => array( - '.', - "/_custom_ns/dot", - array( - "stdClass.yml" => "Foo\\stdClass", - "sub.subClass.yml" => "Foo\\sub\\subClass", - "sub.subsub.subSubClass.yml" => "Foo\\sub\\subsub\\subSubClass", - ) - ), - ); - } - - /** @dataProvider customNamespaceLookupQueryProvider - * @param $separator string Directory separator to test against - * @param $dir string Path to load mapping data from - * @param $files array Files to lookup classnames - * - * @throws \Doctrine\Common\Persistence\Mapping\MappingException - */ - public function testFindMappingFileWithCustomNsSeparator($separator, $dir, $files) - { - $path = __DIR__ . $dir; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml", $separator); - - foreach ($files as $filePath => $className) { - $this->assertEquals(realpath($path .'/'. $filePath), realpath($locator->findMappingFile($className))); - } - - } - - - public function testFindMappingFile() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml"); - - $this->assertEquals(__DIR__ . "/_files/stdClass.yml", $locator->findMappingFile("Foo\\stdClass")); - } - - public function testFindMappingFileNotFound() - { - $path = __DIR__ . "/_files"; - $prefix = "Foo"; - - $locator = new SymfonyFileLocator(array($path => $prefix), ".yml"); - - $this->setExpectedException( - "Doctrine\Common\Persistence\Mapping\MappingException", - "No mapping file found named '".__DIR__."/_files/stdClass2.yml' for class 'Foo\stdClass2'." - ); - $locator->findMappingFile("Foo\\stdClass2"); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/stdClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/stdClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/stdClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subsub/subSubClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subsub/subSubClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dir/sub/subsub/subSubClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/stdClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/stdClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/stdClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subsub.subSubClass.yml b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subsub.subSubClass.yml deleted file mode 100644 index 9daeafb98..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_custom_ns/dot/sub.subsub.subSubClass.yml +++ /dev/null @@ -1 +0,0 @@ -test diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/TestEntity.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/TestEntity.php deleted file mode 100644 index d0e9976ae..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/TestEntity.php +++ /dev/null @@ -1,3 +0,0 @@ -getFieldNames(); \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/annotation/TestClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/annotation/TestClass.php deleted file mode 100644 index ff0356821..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/Mapping/_files/annotation/TestClass.php +++ /dev/null @@ -1,17 +0,0 @@ -wrapped = $wrapped; - } -} - -class ObjectManagerDecoratorTest extends \PHPUnit_Framework_TestCase -{ - private $wrapped; - private $decorated; - - public function setUp() - { - $this->wrapped = $this->getMock('Doctrine\Common\Persistence\ObjectManager'); - $this->decorated = new NullObjectManagerDecorator($this->wrapped); - } - - public function getMethodParameters() - { - $class = new \ReflectionClass('Doctrine\Common\Persistence\ObjectManager'); - - $methods = array(); - foreach ($class->getMethods() as $method) { - if ($method->getNumberOfRequiredParameters() === 0) { - $methods[] = array($method->getName(), array()); - } elseif ($method->getNumberOfRequiredParameters() > 0) { - $methods[] = array($method->getName(), array_fill(0, $method->getNumberOfRequiredParameters(), 'req') ?: array()); - } - if ($method->getNumberOfParameters() != $method->getNumberOfRequiredParameters()) { - $methods[] = array($method->getName(), array_fill(0, $method->getNumberOfParameters(), 'all') ?: array()); - } - } - - return $methods; - } - - /** - * @dataProvider getMethodParameters - */ - public function testAllMethodCallsAreDelegatedToTheWrappedInstance($method, array $parameters) - { - $stub = $this->wrapped - ->expects($this->once()) - ->method($method) - ->will($this->returnValue('INNER VALUE FROM ' . $method)); - - call_user_func_array(array($stub, 'with'), $parameters); - - $this->assertSame('INNER VALUE FROM ' . $method, call_user_func_array(array($this->decorated, $method), $parameters)); - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/PersistentObjectTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/PersistentObjectTest.php deleted file mode 100644 index 180d0f0d0..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Persistence/PersistentObjectTest.php +++ /dev/null @@ -1,247 +0,0 @@ -cm = new TestObjectMetadata; - $this->om = $this->getMock('Doctrine\Common\Persistence\ObjectManager'); - $this->om->expects($this->any())->method('getClassMetadata') - ->will($this->returnValue($this->cm)); - $this->object = new TestObject; - PersistentObject::setObjectManager($this->om); - $this->object->injectObjectManager($this->om, $this->cm); - } - - public function testGetObjectManager() - { - $this->assertSame($this->om, PersistentObject::getObjectManager()); - } - - public function testNonMatchingObjectManager() - { - $this->setExpectedException('RuntimeException'); - $om = $this->getMock('Doctrine\Common\Persistence\ObjectManager'); - $this->object->injectObjectManager($om, $this->cm); - } - - public function testGetField() - { - $this->assertEquals('beberlei', $this->object->getName()); - } - - public function testSetField() - { - $this->object->setName("test"); - $this->assertEquals("test", $this->object->getName()); - } - - public function testGetIdentifier() - { - $this->assertEquals(1, $this->object->getId()); - } - - public function testSetIdentifier() - { - $this->setExpectedException('BadMethodCallException'); - $this->object->setId(2); - } - - public function testSetUnknownField() - { - $this->setExpectedException('BadMethodCallException'); - $this->object->setUnknown("test"); - } - - public function testGetUnknownField() - { - $this->setExpectedException('BadMethodCallException'); - $this->object->getUnknown(); - } - - public function testGetToOneAssociation() - { - $this->assertNull($this->object->getParent()); - } - - public function testSetToOneAssociation() - { - $parent = new TestObject(); - $this->object->setParent($parent); - $this->assertSame($parent, $this->object->getParent($parent)); - } - - public function testSetInvalidToOneAssociation() - { - $parent = new \stdClass(); - - $this->setExpectedException('InvalidArgumentException'); - $this->object->setParent($parent); - } - - public function testSetToOneAssociationNull() - { - $parent = new TestObject(); - $this->object->setParent($parent); - $this->object->setParent(null); - $this->assertNull($this->object->getParent()); - } - - public function testAddToManyAssociation() - { - $child = new TestObject(); - $this->object->addChildren($child); - - $this->assertSame($this->object, $child->getParent()); - $this->assertEquals(1, count($this->object->getChildren())); - - $child = new TestObject(); - $this->object->addChildren($child); - - $this->assertEquals(2, count($this->object->getChildren())); - } - - public function testAddInvalidToManyAssociation() - { - $this->setExpectedException('InvalidArgumentException'); - $this->object->addChildren(new \stdClass()); - } - - public function testNoObjectManagerSet() - { - PersistentObject::setObjectManager(null); - $child = new TestObject(); - - $this->setExpectedException('RuntimeException'); - $child->setName("test"); - } - - public function testInvalidMethod() - { - $this->setExpectedException('BadMethodCallException'); - $this->object->asdf(); - } - - public function testAddInvalidCollection() - { - $this->setExpectedException('BadMethodCallException'); - $this->object->addAsdf(new \stdClass()); - } -} - -class TestObject extends PersistentObject -{ - protected $id = 1; - protected $name = 'beberlei'; - protected $parent; - protected $children; -} - -class TestObjectMetadata implements ClassMetadata -{ - - public function getAssociationMappedByTargetField($assocName) - { - $assoc = array('children' => 'parent'); - return $assoc[$assocName]; - } - - public function getAssociationNames() - { - return array('parent', 'children'); - } - - public function getAssociationTargetClass($assocName) - { - return __NAMESPACE__ . '\TestObject'; - } - - public function getFieldNames() - { - return array('id', 'name'); - } - - public function getIdentifier() - { - return array('id'); - } - - public function getName() - { - return __NAMESPACE__ . '\TestObject'; - } - - public function getReflectionClass() - { - return new \ReflectionClass($this->getName()); - } - - public function getTypeOfField($fieldName) - { - $types = array('id' => 'integer', 'name' => 'string'); - return $types[$fieldName]; - } - - public function hasAssociation($fieldName) - { - return in_array($fieldName, array('parent', 'children')); - } - - public function hasField($fieldName) - { - return in_array($fieldName, array('id', 'name')); - } - - public function isAssociationInverseSide($assocName) - { - return ($assocName === 'children'); - } - - public function isCollectionValuedAssociation($fieldName) - { - return ($fieldName === 'children'); - } - - public function isIdentifier($fieldName) - { - return $fieldName === 'id'; - } - - public function isSingleValuedAssociation($fieldName) - { - return $fieldName === 'parent'; - } - - public function getIdentifierValues($entity) - { - - } - - public function getIdentifierFieldNames() - { - - } - - public function initializeReflection(ReflectionService $reflService) - { - - } - - public function wakeupReflection(ReflectionService $reflService) - { - - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AbstractProxyFactoryTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AbstractProxyFactoryTest.php deleted file mode 100644 index 6ae931638..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AbstractProxyFactoryTest.php +++ /dev/null @@ -1,146 +0,0 @@ -getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $proxyGenerator = $this->getMock('Doctrine\Common\Proxy\ProxyGenerator', array(), array(), '', false); - - $proxyGenerator - ->expects($this->once()) - ->method('getProxyFileName'); - $proxyGenerator - ->expects($this->once()) - ->method('generateProxyClass'); - - $metadataFactory = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadataFactory'); - $proxyFactory = $this->getMockForAbstractClass( - 'Doctrine\Common\Proxy\AbstractProxyFactory', - array($proxyGenerator, $metadataFactory, true) - ); - - $proxyFactory - ->expects($this->any()) - ->method('skipClass') - ->will($this->returnValue(false)); - - $generated = $proxyFactory->generateProxyClasses(array($metadata), sys_get_temp_dir()); - - $this->assertEquals(1, $generated, 'One proxy was generated'); - } - - public function testGetProxy() - { - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $proxy = $this->getMock('Doctrine\Common\Proxy\Proxy'); - $definition = new ProxyDefinition(get_class($proxy), array(), array(), null, null); - $proxyGenerator = $this->getMock('Doctrine\Common\Proxy\ProxyGenerator', array(), array(), '', false); - $metadataFactory = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadataFactory'); - - $metadataFactory - ->expects($this->once()) - ->method('getMetadataFor') - ->will($this->returnValue($metadata)); - - $proxyFactory = $this->getMockForAbstractClass( - 'Doctrine\Common\Proxy\AbstractProxyFactory', - array($proxyGenerator, $metadataFactory, true) - ); - - $proxyFactory - ->expects($this->any()) - ->method('createProxyDefinition') - ->will($this->returnValue($definition)); - - $generatedProxy = $proxyFactory->getProxy('Class', array('id' => 1)); - - $this->assertInstanceOf(get_class($proxy), $generatedProxy); - } - - public function testResetUnitializedProxy() - { - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $proxy = $this->getMock('Doctrine\Common\Proxy\Proxy'); - $definition = new ProxyDefinition(get_class($proxy), array(), array(), null, null); - $proxyGenerator = $this->getMock('Doctrine\Common\Proxy\ProxyGenerator', array(), array(), '', false); - $metadataFactory = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadataFactory'); - - $metadataFactory - ->expects($this->once()) - ->method('getMetadataFor') - ->will($this->returnValue($metadata)); - - $proxyFactory = $this->getMockForAbstractClass( - 'Doctrine\Common\Proxy\AbstractProxyFactory', - array($proxyGenerator, $metadataFactory, true) - ); - - $proxyFactory - ->expects($this->any()) - ->method('createProxyDefinition') - ->will($this->returnValue($definition)); - - $proxy - ->expects($this->once()) - ->method('__isInitialized') - ->will($this->returnValue(false)); - $proxy - ->expects($this->once()) - ->method('__setInitializer'); - $proxy - ->expects($this->once()) - ->method('__setCloner'); - - $proxyFactory->resetUninitializedProxy($proxy); - } - - public function testDisallowsResettingInitializedProxy() - { - $proxyFactory = $this->getMockForAbstractClass('Doctrine\Common\Proxy\AbstractProxyFactory', array(), '', false); - $proxy = $this->getMock('Doctrine\Common\Proxy\Proxy'); - - $proxy - ->expects($this->any()) - ->method('__isInitialized') - ->will($this->returnValue(true)); - - $this->setExpectedException('Doctrine\Common\Proxy\Exception\InvalidArgumentException'); - - $proxyFactory->resetUninitializedProxy($proxy); - } - - public function testMissingPrimaryKeyValue() - { - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $proxy = $this->getMock('Doctrine\Common\Proxy\Proxy'); - $definition = new ProxyDefinition(get_class($proxy), array('missingKey'), array(), null, null); - $proxyGenerator = $this->getMock('Doctrine\Common\Proxy\ProxyGenerator', array(), array(), '', false); - $metadataFactory = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadataFactory'); - - $metadataFactory - ->expects($this->once()) - ->method('getMetadataFor') - ->will($this->returnValue($metadata)); - - $proxyFactory = $this->getMockForAbstractClass( - 'Doctrine\Common\Proxy\AbstractProxyFactory', - array($proxyGenerator, $metadataFactory, true) - ); - - $proxyFactory - ->expects($this->any()) - ->method('createProxyDefinition') - ->will($this->returnValue($definition)); - - $this->setExpectedException('\OutOfBoundsException'); - - $generatedProxy = $proxyFactory->getProxy('Class', array()); - } -} - diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AutoloaderTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AutoloaderTest.php deleted file mode 100644 index be713fcd2..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/AutoloaderTest.php +++ /dev/null @@ -1,72 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -use PHPUnit_Framework_TestCase; -use Doctrine\Common\Proxy\Autoloader; - -/** - * @group DDC-1698 - */ -class AutoloaderTest extends PHPUnit_Framework_TestCase -{ - public static function dataResolveFile() - { - return array( - array('/tmp', 'MyProxy', 'MyProxy\__CG__\RealClass', '/tmp' . DIRECTORY_SEPARATOR . '__CG__RealClass.php'), - array('/tmp', 'MyProxy\Subdir', 'MyProxy\Subdir\__CG__\RealClass', '/tmp' . DIRECTORY_SEPARATOR . '__CG__RealClass.php'), - array('/tmp', 'MyProxy', 'MyProxy\__CG__\Other\RealClass', '/tmp' . DIRECTORY_SEPARATOR . '__CG__OtherRealClass.php'), - ); - } - - /** - * @dataProvider dataResolveFile - */ - public function testResolveFile($proxyDir, $proxyNamespace, $className, $expectedProxyFile) - { - $actualProxyFile = Autoloader::resolveFile($proxyDir, $proxyNamespace, $className); - $this->assertEquals($expectedProxyFile, $actualProxyFile); - } - - public function testAutoload() - { - if (file_exists(sys_get_temp_dir() ."/AutoloaderTestClass.php")) { - unlink(sys_get_temp_dir() ."/AutoloaderTestClass.php"); - } - - $autoloader = Autoloader::register(sys_get_temp_dir(), 'ProxyAutoloaderTest', function($proxyDir, $proxyNamespace, $className) { - file_put_contents(sys_get_temp_dir() . "/AutoloaderTestClass.php", "assertTrue(class_exists('ProxyAutoloaderTest\AutoloaderTestClass', true)); - unlink(sys_get_temp_dir() ."/AutoloaderTestClass.php"); - } - - public function testRegisterWithInvalidCallback() - { - $this->setExpectedException( - 'Doctrine\Common\Proxy\Exception\InvalidArgumentException', - 'Invalid \$notFoundCallback given: must be a callable, "stdClass" given' - ); - - Autoloader::register('', '', new \stdClass()); - } -} - diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/CallableTypeHintClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/CallableTypeHintClass.php deleted file mode 100644 index f5fccb0dc..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/CallableTypeHintClass.php +++ /dev/null @@ -1,16 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -/** - * Test asset representing a lazy loadable object - * - * @author Marco Pivetta - * @since 2.4 - */ -class LazyLoadableObject -{ - /** - * @var string - */ - public $publicIdentifierField; - - /** - * @var string - */ - protected $protectedIdentifierField; - - /** - * @var string - */ - public $publicTransientField = 'publicTransientFieldValue'; - - /** - * @var string - */ - protected $protectedTransientField = 'protectedTransientFieldValue'; - - /** - * @var string - */ - public $publicPersistentField = 'publicPersistentFieldValue'; - - /** - * @var string - */ - protected $protectedPersistentField = 'protectedPersistentFieldValue'; - - /** - * @var string - */ - public $publicAssociation = 'publicAssociationValue'; - - /** - * @var string - */ - protected $protectedAssociation = 'protectedAssociationValue'; - - /** - * @return string - */ - public function getProtectedIdentifierField() - { - return $this->protectedIdentifierField; - } - - /** - * @return string - */ - public function testInitializationTriggeringMethod() - { - return 'testInitializationTriggeringMethod'; - } - - /** - * @return string - */ - public function getProtectedAssociation() - { - return $this->protectedAssociation; - } - - /** - * @param \stdClass $param - */ - public function publicTypeHintedMethod(\stdClass $param) - { - } - - /** - * - */ - public function &byRefMethod() - { - } - - /** - * @param mixed $thisIsNotByRef - * @param &mixed $thisIsByRef - */ - public function byRefParamMethod($thisIsNotByRef, &$thisIsByRef) - { - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObjectClassMetadata.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObjectClassMetadata.php deleted file mode 100644 index 167386e35..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObjectClassMetadata.php +++ /dev/null @@ -1,195 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -use ReflectionClass; -use Doctrine\Common\Persistence\Mapping\ClassMetadata; - -/** - * Class metadata test asset for @see LazyLoadableObject - * - * @author Marco Pivetta - * @since 2.4 - */ -class LazyLoadableObjectClassMetadata implements ClassMetadata -{ - /** - * @var ReflectionClass - */ - protected $reflectionClass; - - /** - * @var array - */ - protected $identifier = array( - 'publicIdentifierField' => true, - 'protectedIdentifierField' => true, - ); - - /** - * @var array - */ - protected $fields = array( - 'publicIdentifierField' => true, - 'protectedIdentifierField' => true, - 'publicPersistentField' => true, - 'protectedPersistentField' => true, - ); - - /** - * @var array - */ - protected $associations = array( - 'publicAssociation' => true, - 'protectedAssociation' => true, - ); - - /** - * {@inheritDoc} - */ - public function getName() - { - return $this->getReflectionClass()->getName(); - } - - /** - * {@inheritDoc} - */ - public function getIdentifier() - { - return array_keys($this->identifier); - } - - /** - * {@inheritDoc} - */ - public function getReflectionClass() - { - if (null === $this->reflectionClass) { - $this->reflectionClass = new \ReflectionClass(__NAMESPACE__ . '\LazyLoadableObject'); - } - - return $this->reflectionClass; - } - - /** - * {@inheritDoc} - */ - public function isIdentifier($fieldName) - { - return isset($this->identifier[$fieldName]); - } - - /** - * {@inheritDoc} - */ - public function hasField($fieldName) - { - return isset($this->fields[$fieldName]); - } - - /** - * {@inheritDoc} - */ - public function hasAssociation($fieldName) - { - return isset($this->associations[$fieldName]); - } - - /** - * {@inheritDoc} - */ - public function isSingleValuedAssociation($fieldName) - { - throw new \BadMethodCallException('not implemented'); - } - - /** - * {@inheritDoc} - */ - public function isCollectionValuedAssociation($fieldName) - { - throw new \BadMethodCallException('not implemented'); - } - - /** - * {@inheritDoc} - */ - public function getFieldNames() - { - return array_keys($this->fields); - } - - /** - * {@inheritDoc} - */ - public function getIdentifierFieldNames() - { - return $this->getIdentifier(); - } - - /** - * {@inheritDoc} - */ - public function getAssociationNames() - { - return array_keys($this->associations); - } - - /** - * {@inheritDoc} - */ - public function getTypeOfField($fieldName) - { - return 'string'; - } - - /** - * {@inheritDoc} - */ - public function getAssociationTargetClass($assocName) - { - throw new \BadMethodCallException('not implemented'); - } - - /** - * {@inheritDoc} - */ - public function isAssociationInverseSide($assocName) - { - throw new \BadMethodCallException('not implemented'); - } - - /** - * {@inheritDoc} - */ - public function getAssociationMappedByTargetField($assocName) - { - throw new \BadMethodCallException('not implemented'); - } - - /** - * {@inheritDoc} - */ - public function getIdentifierValues($object) - { - throw new \BadMethodCallException('not implemented'); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicCloneClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicCloneClass.php deleted file mode 100644 index 33b983dc6..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicCloneClass.php +++ /dev/null @@ -1,37 +0,0 @@ -clonedValue = 'newClonedValue'; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetByRefClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetByRefClass.php deleted file mode 100644 index 6adf1f574..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetByRefClass.php +++ /dev/null @@ -1,51 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -use InvalidArgumentException; - -/** - * Test asset class - * - * @since 2.4 - */ -class MagicGetByRefClass -{ - /** - * @var mixed - */ - public $valueField; - - /** - * @param string $name - * - * @return mixed - * - * @throws \InvalidArgumentException - */ - public function & __get($name) - { - if ($name === 'value') { - return $this->valueField; - } - - throw new InvalidArgumentException(); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php deleted file mode 100644 index 0cab36a96..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicGetClass.php +++ /dev/null @@ -1,38 +0,0 @@ -testAttribute = $value; - } - - if ($name === 'publicField' || $name === 'id') { - throw new \BadMethodCallException('Should never be called for "publicField" or "id"'); - } - - $this->testAttribute = $value; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicSleepClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicSleepClass.php deleted file mode 100644 index 3934a05e7..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/MagicSleepClass.php +++ /dev/null @@ -1,37 +0,0 @@ -wakeupValue = 'newWakeupValue'; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyClassGeneratorTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyClassGeneratorTest.php deleted file mode 100644 index 5de83a180..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyClassGeneratorTest.php +++ /dev/null @@ -1,249 +0,0 @@ -. - */ - - -namespace Doctrine\Tests\Common\Proxy; - -use Doctrine\Common\Proxy\ProxyGenerator; -use ReflectionClass; -use ReflectionMethod; -use PHPUnit_Framework_TestCase; - -/** - * Test the proxy generator. Its work is generating on-the-fly subclasses of a given model, which implement the Proxy - * pattern. - * - * @author Giorgio Sironi - * @author Marco Pivetta - */ -class ProxyClassGeneratorTest extends PHPUnit_Framework_TestCase -{ - /** - * @var string - */ - protected $proxyClass = 'Doctrine\Tests\Common\ProxyProxy\__CG__\Doctrine\Tests\Common\Proxy\LazyLoadableObject'; - - /** - * @var LazyLoadableObjectClassMetadata - */ - protected $metadata; - - /** - * @var ProxyGenerator - */ - protected $proxyGenerator; - - /** - * {@inheritDoc} - */ - protected function setUp() - { - $this->metadata = new LazyLoadableObjectClassMetadata(); - $this->proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - - if (class_exists($this->proxyClass, false)) { - return; - } - - $this->generateAndRequire($this->proxyGenerator, $this->metadata); - } - - public function testReferenceProxyRespectsMethodsParametersTypeHinting() - { - $method = new ReflectionMethod($this->proxyClass, 'publicTypeHintedMethod'); - $params = $method->getParameters(); - - $this->assertEquals(1, count($params)); - $this->assertEquals('stdClass', $params[0]->getClass()->getName()); - } - - public function testProxyRespectsMethodsWhichReturnValuesByReference() - { - $method = new ReflectionMethod($this->proxyClass, 'byRefMethod'); - - $this->assertTrue($method->returnsReference()); - } - - public function testProxyRespectsByRefMethodParameters() - { - $method = new ReflectionMethod($this->proxyClass, 'byRefParamMethod'); - $parameters = $method->getParameters(); - $this->assertSame('thisIsNotByRef', $parameters[0]->getName()); - $this->assertFalse($parameters[0]->isPassedByReference()); - $this->assertSame('thisIsByRef', $parameters[1]->getName()); - $this->assertTrue($parameters[1]->isPassedByReference()); - } - - public function testCreatesAssociationProxyAsSubclassOfTheOriginalOne() - { - $this->assertTrue(is_subclass_of($this->proxyClass, $this->metadata->getName())); - } - - public function testNonNamespacedProxyGeneration() - { - $classCode = file_get_contents($this->proxyGenerator->getProxyFileName($this->metadata->getName())); - - $this->assertNotContains("class LazyLoadableObject extends \\\\" . $this->metadata->getName(), $classCode); - $this->assertContains("class LazyLoadableObject extends \\" . $this->metadata->getName(), $classCode); - } - - public function testClassWithSleepProxyGeneration() - { - if (!class_exists('Doctrine\Tests\Common\ProxyProxy\__CG__\SleepClass', false)) { - $className = 'Doctrine\Tests\Common\Proxy\SleepClass'; - $metadata = $this->createClassMetadata($className, array('id')); - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - - $this->generateAndRequire($proxyGenerator, $metadata); - } - - $classCode = file_get_contents(__DIR__ . '/generated/__CG__DoctrineTestsCommonProxySleepClass.php'); - $this->assertEquals(1, substr_count($classCode, 'function __sleep')); - $this->assertEquals(1, substr_count($classCode, 'parent::__sleep()')); - } - - /** - * Check that the proxy doesn't serialize static properties (in __sleep() method) - * @group DCOM-212 - */ - public function testClassWithStaticPropertyProxyGeneration() - { - if (!class_exists('Doctrine\Tests\Common\ProxyProxy\__CG__\StaticPropertyClass', false)) { - $className = 'Doctrine\Tests\Common\Proxy\StaticPropertyClass'; - $metadata = $this->createClassMetadata($className, array()); - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - - $this->generateAndRequire($proxyGenerator, $metadata); - } - - $classCode = file_get_contents(__DIR__ . '/generated/__CG__DoctrineTestsCommonProxyStaticPropertyClass.php'); - $this->assertEquals(1, substr_count($classCode, 'function __sleep')); - $this->assertNotContains('protectedStaticProperty', $classCode); - } - - private function generateAndRequire($proxyGenerator, $metadata) - { - $proxyGenerator->generateProxyClass($metadata, $proxyGenerator->getProxyFileName($metadata->getName())); - - require_once $proxyGenerator->getProxyFileName($metadata->getName()); - } - - public function testClassWithCallableTypeHintOnProxiedMethod() - { - if (PHP_VERSION_ID < 50400) { - $this->markTestSkipped('`callable` is only supported in PHP >=5.4.0'); - } - - if (!class_exists('Doctrine\Tests\Common\ProxyProxy\__CG__\CallableTypeHintClass', false)) { - $className = 'Doctrine\Tests\Common\Proxy\CallableTypeHintClass'; - $metadata = $this->createClassMetadata($className, array('id')); - - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - $this->generateAndRequire($proxyGenerator, $metadata); - } - - $classCode = file_get_contents(__DIR__ . '/generated/__CG__DoctrineTestsCommonProxyCallableTypeHintClass.php'); - - $this->assertEquals(1, substr_count($classCode, 'call(callable $foo)')); - } - - public function testClassWithVariadicArgumentOnProxiedMethod() - { - if (PHP_VERSION_ID < 50600) { - $this->markTestSkipped('`...` is only supported in PHP >=5.6.0'); - } - - if (!class_exists('Doctrine\Tests\Common\ProxyProxy\__CG__\VariadicTypeHintClass', false)) { - $className = 'Doctrine\Tests\Common\Proxy\VariadicTypeHintClass'; - $metadata = $this->createClassMetadata($className, array('id')); - - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - $this->generateAndRequire($proxyGenerator, $metadata); - } - - $classCode = file_get_contents(__DIR__ . '/generated/__CG__DoctrineTestsCommonProxyVariadicTypeHintClass.php'); - - $this->assertEquals(1, substr_count($classCode, 'function addType(...$types)')); - $this->assertEquals(1, substr_count($classCode, '__invoke($this, \'addType\', array($types))')); - $this->assertEquals(1, substr_count($classCode, 'parent::addType(...$types)')); - } - - public function testClassWithInvalidTypeHintOnProxiedMethod() - { - $className = 'Doctrine\Tests\Common\Proxy\InvalidTypeHintClass'; - $metadata = $this->createClassMetadata($className, array('id')); - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - - $this->setExpectedException( - 'Doctrine\Common\Proxy\Exception\UnexpectedValueException', - 'The type hint of parameter "foo" in method "invalidTypeHintMethod"' - .' in class "' . $className . '" is invalid.' - ); - $proxyGenerator->generateProxyClass($metadata); - } - - public function testNoConfigDirThrowsException() - { - $this->setExpectedException('Doctrine\Common\Proxy\Exception\InvalidArgumentException'); - new ProxyGenerator(null, null); - } - - public function testNoNamespaceThrowsException() - { - $this->setExpectedException('Doctrine\Common\Proxy\Exception\InvalidArgumentException'); - new ProxyGenerator(__DIR__ . '/generated', null); - } - - public function testInvalidPlaceholderThrowsException() - { - $this->setExpectedException('Doctrine\Common\Proxy\Exception\InvalidArgumentException'); - $generator = new ProxyGenerator(__DIR__ . '/generated', 'SomeNamespace'); - $generator->setPlaceholder('', array()); - } - - public function testUseEvalIfNoFilenameIsGiven() - { - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - - $className = __NAMESPACE__ . '\\EvalBase'; - - $metadata = $this->createClassMetadata($className, array('id')); - - $proxyGenerator->generateProxyClass($metadata); - - $reflClass = new ReflectionClass('Doctrine\Tests\Common\ProxyProxy\__CG__\Doctrine\Tests\Common\Proxy\EvalBase'); - - $this->assertContains("eval()'d code", $reflClass->getFileName()); - } - - private function createClassMetadata($className, array $ids) - { - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - $reflClass = new ReflectionClass($className); - $metadata->expects($this->any())->method('getReflectionClass')->will($this->returnValue($reflClass)); - $metadata->expects($this->any())->method('getIdentifierFieldNames')->will($this->returnValue($ids)); - $metadata->expects($this->any())->method('getName')->will($this->returnValue($className)); - - return $metadata; - } -} - -class EvalBase -{ -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyLogicTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyLogicTest.php deleted file mode 100644 index c97ac79f2..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyLogicTest.php +++ /dev/null @@ -1,752 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -use Doctrine\Common\Proxy\ProxyGenerator; -use Doctrine\Common\Proxy\Proxy; -use Doctrine\Common\Proxy\Exception\UnexpectedValueException; -use Doctrine\Common\Persistence\Mapping\ClassMetadata; -use PHPUnit_Framework_TestCase; - -/** - * Test the generated proxies behavior. These tests make assumptions about the structure of LazyLoadableObject - * - * @author Marco Pivetta - */ -class ProxyLogicTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \PHPUnit_Framework_MockObject_MockObject - */ - protected $proxyLoader; - - /** - * @var ClassMetadata - */ - protected $lazyLoadableObjectMetadata; - - /** - * @var LazyLoadableObject|Proxy - */ - protected $lazyObject; - - protected $identifier = array( - 'publicIdentifierField' => 'publicIdentifierFieldValue', - 'protectedIdentifierField' => 'protectedIdentifierFieldValue', - ); - - /** - * @var \PHPUnit_Framework_MockObject_MockObject|Callable - */ - protected $initializerCallbackMock; - - /** - * {@inheritDoc} - */ - public function setUp() - { - $this->proxyLoader = $loader = $this->getMock('stdClass', array('load'), array(), '', false); - $this->initializerCallbackMock = $this->getMock('stdClass', array('__invoke')); - $identifier = $this->identifier; - $this->lazyLoadableObjectMetadata = $metadata = new LazyLoadableObjectClassMetadata(); - - // emulating what should happen in a proxy factory - $cloner = function (LazyLoadableObject $proxy) use ($loader, $identifier, $metadata) { - /* @var $proxy LazyLoadableObject|Proxy */ - if ($proxy->__isInitialized()) { - return; - } - - $proxy->__setInitialized(true); - $proxy->__setInitializer(null); - $original = $loader->load($identifier); - - if (null === $original) { - throw new UnexpectedValueException(); - } - - foreach ($metadata->getReflectionClass()->getProperties() as $reflProperty) { - $propertyName = $reflProperty->getName(); - - if ($metadata->hasField($propertyName) || $metadata->hasAssociation($propertyName)) { - $reflProperty->setAccessible(true); - $reflProperty->setValue($proxy, $reflProperty->getValue($original)); - } - } - }; - - $proxyClassName = 'Doctrine\Tests\Common\ProxyProxy\__CG__\Doctrine\Tests\Common\Proxy\LazyLoadableObject'; - - // creating the proxy class - if (!class_exists($proxyClassName, false)) { - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - $proxyGenerator->generateProxyClass($metadata); - require_once $proxyGenerator->getProxyFileName($metadata->getName()); - } - - $this->lazyObject = new $proxyClassName($this->getClosure($this->initializerCallbackMock), $cloner); - - // setting identifiers in the proxy via reflection - foreach ($metadata->getIdentifierFieldNames() as $idField) { - $prop = $metadata->getReflectionClass()->getProperty($idField); - $prop->setAccessible(true); - $prop->setValue($this->lazyObject, $identifier[$idField]); - } - - $this->assertFalse($this->lazyObject->__isInitialized()); - } - - public function testFetchingPublicIdentifierDoesNotCauseLazyLoading() - { - $this->configureInitializerMock(0); - - $this->assertSame('publicIdentifierFieldValue', $this->lazyObject->publicIdentifierField); - } - - public function testFetchingIdentifiersViaPublicGetterDoesNotCauseLazyLoading() - { - $this->configureInitializerMock(0); - - $this->assertSame('protectedIdentifierFieldValue', $this->lazyObject->getProtectedIdentifierField()); - } - - public function testCallingMethodCausesLazyLoading() - { - $this->configureInitializerMock( - 1, - array($this->lazyObject, 'testInitializationTriggeringMethod', array()), - function (Proxy $proxy) { - $proxy->__setInitializer(null); - } - ); - - $this->lazyObject->testInitializationTriggeringMethod(); - $this->lazyObject->testInitializationTriggeringMethod(); - } - - public function testFetchingPublicFieldsCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__get', array('publicPersistentField')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', 'loadedValue'); - } - ); - - $this->assertSame('loadedValue', $this->lazyObject->publicPersistentField); - $this->assertSame('loadedValue', $this->lazyObject->publicPersistentField); - } - - public function testFetchingPublicAssociationCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__get', array('publicAssociation')), - function () use ($test) { - $test->setProxyValue('publicAssociation', 'loadedAssociation'); - } - ); - - $this->assertSame('loadedAssociation', $this->lazyObject->publicAssociation); - $this->assertSame('loadedAssociation', $this->lazyObject->publicAssociation); - } - - public function testFetchingProtectedAssociationViaPublicGetterCausesLazyLoading() - { - $this->configureInitializerMock( - 1, - array($this->lazyObject, 'getProtectedAssociation', array()), - function (Proxy $proxy) { - $proxy->__setInitializer(null); - } - ); - - $this->assertSame('protectedAssociationValue', $this->lazyObject->getProtectedAssociation()); - $this->assertSame('protectedAssociationValue', $this->lazyObject->getProtectedAssociation()); - } - - public function testLazyLoadingTriggeredOnlyAtFirstPublicPropertyRead() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__get', array('publicPersistentField')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', 'loadedValue'); - $test->setProxyValue('publicAssociation', 'publicAssociationValue'); - } - ); - - $this->assertSame('loadedValue', $this->lazyObject->publicPersistentField); - $this->assertSame('publicAssociationValue', $this->lazyObject->publicAssociation); - } - - public function testNoticeWhenReadingNonExistentPublicProperties() - { - $this->configureInitializerMock(0); - - $class = get_class($this->lazyObject); - $this->setExpectedException( - 'PHPUnit_Framework_Error_Notice', - 'Undefined property: ' . $class . '::$non_existing_property' - ); - - $this->lazyObject->non_existing_property; - } - - public function testFalseWhenCheckingNonExistentProperty() - { - $this->configureInitializerMock(0); - - $this->assertFalse(isset($this->lazyObject->non_existing_property)); - } - - public function testNoErrorWhenSettingNonExistentProperty() - { - $this->configureInitializerMock(0); - - $this->lazyObject->non_existing_property = 'now has a value'; - $this->assertSame('now has a value', $this->lazyObject->non_existing_property); - } - - public function testCloningCallsClonerWithClonedObject() - { - $lazyObject = $this->lazyObject; - $test = $this; - $cb = $this->getMock('stdClass', array('cb')); - $cb - ->expects($this->once()) - ->method('cb') - ->will($this->returnCallback(function (LazyLoadableObject $proxy) use ($lazyObject, $test) { - /* @var $proxy LazyLoadableObject|Proxy */ - $test->assertNotSame($proxy, $lazyObject); - $proxy->__setInitializer(null); - $proxy->publicAssociation = 'clonedAssociation'; - })); - - $this->lazyObject->__setCloner($this->getClosure(array($cb, 'cb'))); - - $cloned = clone $this->lazyObject; - $this->assertSame('clonedAssociation', $cloned->publicAssociation); - $this->assertNotSame($cloned, $lazyObject, 'a clone of the lazy object is retrieved'); - } - - public function testFetchingTransientPropertiesWillNotTriggerLazyLoading() - { - $this->configureInitializerMock(0); - - $this->assertSame( - 'publicTransientFieldValue', - $this->lazyObject->publicTransientField, - 'fetching public transient field won\'t trigger lazy loading' - ); - $property = $this - ->lazyLoadableObjectMetadata - ->getReflectionClass() - ->getProperty('protectedTransientField'); - $property->setAccessible(true); - $this->assertSame( - 'protectedTransientFieldValue', - $property->getValue($this->lazyObject), - 'fetching protected transient field via reflection won\'t trigger lazy loading' - ); - } - - /** - * Provided to guarantee backwards compatibility - */ - public function testLoadProxyMethod() - { - $this->configureInitializerMock(2, array($this->lazyObject, '__load', array())); - - $this->lazyObject->__load(); - $this->lazyObject->__load(); - } - - public function testLoadingWithPersisterWillBeTriggeredOnlyOnce() - { - $this - ->proxyLoader - ->expects($this->once()) - ->method('load') - ->with( - array( - 'publicIdentifierField' => 'publicIdentifierFieldValue', - 'protectedIdentifierField' => 'protectedIdentifierFieldValue', - ), - $this->lazyObject - ) - ->will($this->returnCallback(function ($id, LazyLoadableObject $lazyObject) { - // setting a value to verify that the persister can actually set something in the object - $lazyObject->publicAssociation = $id['publicIdentifierField'] . '-test'; - return true; - })); - $this->lazyObject->__setInitializer($this->getSuggestedInitializerImplementation()); - - $this->lazyObject->__load(); - $this->lazyObject->__load(); - $this->assertSame('publicIdentifierFieldValue-test', $this->lazyObject->publicAssociation); - } - - public function testFailedLoadingWillThrowException() - { - $this->proxyLoader->expects($this->any())->method('load')->will($this->returnValue(null)); - $this->setExpectedException('UnexpectedValueException'); - $this->lazyObject->__setInitializer($this->getSuggestedInitializerImplementation()); - - $this->lazyObject->__load(); - } - - public function testCloningWithPersister() - { - $this->lazyObject->publicTransientField = 'should-not-change'; - $this - ->proxyLoader - ->expects($this->exactly(2)) - ->method('load') - ->with(array( - 'publicIdentifierField' => 'publicIdentifierFieldValue', - 'protectedIdentifierField' => 'protectedIdentifierFieldValue', - )) - ->will($this->returnCallback(function () { - $blueprint = new LazyLoadableObject(); - $blueprint->publicPersistentField = 'checked-persistent-field'; - $blueprint->publicAssociation = 'checked-association-field'; - $blueprint->publicTransientField = 'checked-transient-field'; - - return $blueprint; - })); - - $firstClone = clone $this->lazyObject; - $this->assertSame( - 'checked-persistent-field', - $firstClone->publicPersistentField, - 'Persistent fields are cloned correctly' - ); - $this->assertSame( - 'checked-association-field', - $firstClone->publicAssociation, - 'Associations are cloned correctly' - ); - $this->assertSame( - 'should-not-change', - $firstClone->publicTransientField, - 'Transient fields are not overwritten' - ); - - $secondClone = clone $this->lazyObject; - $this->assertSame( - 'checked-persistent-field', - $secondClone->publicPersistentField, - 'Persistent fields are cloned correctly' - ); - $this->assertSame( - 'checked-association-field', - $secondClone->publicAssociation, - 'Associations are cloned correctly' - ); - $this->assertSame( - 'should-not-change', - $secondClone->publicTransientField, - 'Transient fields are not overwritten' - ); - - // those should not trigger lazy loading - $firstClone->__load(); - $secondClone->__load(); - } - - public function testNotInitializedProxyUnserialization() - { - $this->configureInitializerMock(); - - $serialized = serialize($this->lazyObject); - /* @var $unserialized LazyLoadableObject|Proxy */ - $unserialized = unserialize($serialized); - $reflClass = $this->lazyLoadableObjectMetadata->getReflectionClass(); - - $this->assertFalse($unserialized->__isInitialized(), 'serialization didn\'t cause intialization'); - - // Checking identifiers - $this->assertSame('publicIdentifierFieldValue', $unserialized->publicIdentifierField, 'identifiers are kept'); - $protectedIdentifierField = $reflClass->getProperty('protectedIdentifierField'); - $protectedIdentifierField->setAccessible(true); - $this->assertSame( - 'protectedIdentifierFieldValue', - $protectedIdentifierField->getValue($unserialized), - 'identifiers are kept' - ); - - // Checking transient fields - $this->assertSame( - 'publicTransientFieldValue', - $unserialized->publicTransientField, - 'transient fields are kept' - ); - $protectedTransientField = $reflClass->getProperty('protectedTransientField'); - $protectedTransientField->setAccessible(true); - $this->assertSame( - 'protectedTransientFieldValue', - $protectedTransientField->getValue($unserialized), - 'transient fields are kept' - ); - - // Checking persistent fields - $this->assertSame( - 'publicPersistentFieldValue', - $unserialized->publicPersistentField, - 'persistent fields are kept' - ); - $protectedPersistentField = $reflClass->getProperty('protectedPersistentField'); - $protectedPersistentField->setAccessible(true); - $this->assertSame( - 'protectedPersistentFieldValue', - $protectedPersistentField->getValue($unserialized), - 'persistent fields are kept' - ); - - // Checking associations - $this->assertSame('publicAssociationValue', $unserialized->publicAssociation, 'associations are kept'); - $protectedAssociationField = $reflClass->getProperty('protectedAssociation'); - $protectedAssociationField->setAccessible(true); - $this->assertSame( - 'protectedAssociationValue', - $protectedAssociationField->getValue($unserialized), - 'associations are kept' - ); - } - - public function testInitializedProxyUnserialization() - { - // persister will retrieve the lazy object itself, so that we don't have to re-define all field values - $this->proxyLoader->expects($this->once())->method('load')->will($this->returnValue($this->lazyObject)); - $this->lazyObject->__setInitializer($this->getSuggestedInitializerImplementation()); - $this->lazyObject->__load(); - - $serialized = serialize($this->lazyObject); - $reflClass = $this->lazyLoadableObjectMetadata->getReflectionClass(); - /* @var $unserialized LazyLoadableObject|Proxy */ - $unserialized = unserialize($serialized); - - $this->assertTrue($unserialized->__isInitialized(), 'serialization didn\'t cause intialization'); - - // Checking transient fields - $this->assertSame( - 'publicTransientFieldValue', - $unserialized->publicTransientField, - 'transient fields are kept' - ); - $protectedTransientField = $reflClass->getProperty('protectedTransientField'); - $protectedTransientField->setAccessible(true); - $this->assertSame( - 'protectedTransientFieldValue', - $protectedTransientField->getValue($unserialized), - 'transient fields are kept' - ); - - // Checking persistent fields - $this->assertSame( - 'publicPersistentFieldValue', - $unserialized->publicPersistentField, - 'persistent fields are kept' - ); - $protectedPersistentField = $reflClass->getProperty('protectedPersistentField'); - $protectedPersistentField->setAccessible(true); - $this->assertSame( - 'protectedPersistentFieldValue', - $protectedPersistentField->getValue($unserialized), - 'persistent fields are kept' - ); - - // Checking identifiers - $this->assertSame( - 'publicIdentifierFieldValue', - $unserialized->publicIdentifierField, - 'identifiers are kept' - ); - $protectedIdentifierField = $reflClass->getProperty('protectedIdentifierField'); - $protectedIdentifierField->setAccessible(true); - $this->assertSame( - 'protectedIdentifierFieldValue', - $protectedIdentifierField->getValue($unserialized), - 'identifiers are kept' - ); - - // Checking associations - $this->assertSame('publicAssociationValue', $unserialized->publicAssociation, 'associations are kept'); - $protectedAssociationField = $reflClass->getProperty('protectedAssociation'); - $protectedAssociationField->setAccessible(true); - $this->assertSame( - 'protectedAssociationValue', - $protectedAssociationField->getValue($unserialized), - 'associations are kept' - ); - } - - public function testInitializationRestoresDefaultPublicLazyLoadedFieldValues() - { - // setting noop persister - $this->proxyLoader->expects($this->once())->method('load')->will($this->returnValue($this->lazyObject)); - $this->lazyObject->__setInitializer($this->getSuggestedInitializerImplementation()); - - $this->assertSame( - 'publicPersistentFieldValue', - $this->lazyObject->publicPersistentField, - 'Persistent field is restored to default value' - ); - $this->assertSame( - 'publicAssociationValue', - $this->lazyObject->publicAssociation, - 'Association is restored to default value' - ); - } - - public function testSettingPublicFieldsCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__set', array('publicPersistentField', 'newPublicPersistentFieldValue')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', 'overrideValue'); - $test->setProxyValue('publicAssociation', 'newAssociationValue'); - } - ); - - $this->lazyObject->publicPersistentField = 'newPublicPersistentFieldValue'; - $this->assertSame('newPublicPersistentFieldValue', $this->lazyObject->publicPersistentField); - $this->assertSame('newAssociationValue', $this->lazyObject->publicAssociation); - } - - public function testSettingPublicAssociationCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__set', array('publicAssociation', 'newPublicAssociationValue')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', 'newPublicPersistentFieldValue'); - $test->setProxyValue('publicAssociation', 'overrideValue'); - } - ); - - $this->lazyObject->publicAssociation = 'newPublicAssociationValue'; - $this->assertSame('newPublicAssociationValue', $this->lazyObject->publicAssociation); - $this->assertSame('newPublicPersistentFieldValue', $this->lazyObject->publicPersistentField); - } - - public function testCheckingPublicFieldsCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__isset', array('publicPersistentField')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', null); - $test->setProxyValue('publicAssociation', 'setPublicAssociation'); - } - ); - - $this->assertFalse(isset($this->lazyObject->publicPersistentField)); - $this->assertNull($this->lazyObject->publicPersistentField); - $this->assertTrue(isset($this->lazyObject->publicAssociation)); - $this->assertSame('setPublicAssociation', $this->lazyObject->publicAssociation); - } - - public function testCheckingPublicAssociationCausesLazyLoading() - { - $test = $this; - $this->configureInitializerMock( - 1, - array($this->lazyObject, '__isset', array('publicAssociation')), - function () use ($test) { - $test->setProxyValue('publicPersistentField', 'newPersistentFieldValue'); - $test->setProxyValue('publicAssociation', 'setPublicAssociation'); - } - ); - - $this->assertTrue(isset($this->lazyObject->publicAssociation)); - $this->assertSame('setPublicAssociation', $this->lazyObject->publicAssociation); - $this->assertTrue(isset($this->lazyObject->publicPersistentField)); - $this->assertSame('newPersistentFieldValue', $this->lazyObject->publicPersistentField); - } - - public function testCallingVariadicMethodCausesLazyLoading() - { - if (PHP_VERSION_ID < 50600) { - $this->markTestSkipped('Test applies only to PHP 5.6+'); - } - - $proxyClassName = 'Doctrine\Tests\Common\ProxyProxy\__CG__\Doctrine\Tests\Common\Proxy\VariadicTypeHintClass'; - - /* @var $metadata \Doctrine\Common\Persistence\Mapping\ClassMetadata|\PHPUnit_Framework_MockObject_MockObject */ - $metadata = $this->getMock('Doctrine\Common\Persistence\Mapping\ClassMetadata'); - - $metadata - ->expects($this->any()) - ->method('getName') - ->will($this->returnValue('Doctrine\Tests\Common\Proxy\VariadicTypeHintClass')); - $metadata - ->expects($this->any()) - ->method('getReflectionClass') - ->will($this->returnValue(new \ReflectionClass('Doctrine\Tests\Common\Proxy\VariadicTypeHintClass'))); - - // creating the proxy class - if (!class_exists($proxyClassName, false)) { - $proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . 'Proxy', true); - $proxyGenerator->generateProxyClass($metadata); - require_once $proxyGenerator->getProxyFileName($metadata->getName()); - } - - /* @var $invocationMock callable|\PHPUnit_Framework_MockObject_MockObject */ - $invocationMock = $this->getMock('stdClass', array('__invoke')); - - /* @var $lazyObject \Doctrine\Tests\Common\Proxy\VariadicTypeHintClass */ - $lazyObject = new $proxyClassName( - function ($proxy, $method, $parameters) use ($invocationMock) { - $invocationMock($proxy, $method, $parameters); - }, - function () {} - ); - - $invocationMock - ->expects($this->at(0)) - ->method('__invoke') - ->with($lazyObject, 'addType', array(array('type1', 'type2'))); - $invocationMock - ->expects($this->at(1)) - ->method('__invoke') - ->with($lazyObject, 'addTypeWithMultipleParameters', array('foo', 'bar', array('baz1', 'baz2'))); - - $lazyObject->addType('type1', 'type2'); - $this->assertSame(array('type1', 'type2'), $lazyObject->types); - - $lazyObject->addTypeWithMultipleParameters('foo', 'bar', 'baz1', 'baz2'); - $this->assertSame('foo', $lazyObject->foo); - $this->assertSame('bar', $lazyObject->bar); - $this->assertSame(array('baz1', 'baz2'), $lazyObject->baz); - } - - /** - * Converts a given callable into a closure - * - * @param callable $callable - * @return \Closure - */ - public function getClosure($callable) { - return function () use ($callable) { - call_user_func_array($callable, func_get_args()); - }; - } - - /** - * Configures the current initializer callback mock with provided matcher params - * - * @param int $expectedCallCount the number of invocations to be expected. If a value< 0 is provided, `any` is used - * @param array $callParamsMatch an ordered array of parameters to be expected - * @param callable $callbackClosure a return callback closure - * - * @return \PHPUnit_Framework_MockObject_MockObject| - */ - protected function configureInitializerMock( - $expectedCallCount = 0, - array $callParamsMatch = null, - \Closure $callbackClosure = null - ) { - if (!$expectedCallCount) { - $invocationCountMatcher = $this->exactly((int) $expectedCallCount); - } else { - $invocationCountMatcher = $expectedCallCount < 0 ? $this->any() : $this->exactly($expectedCallCount); - } - - $invocationMocker = $this->initializerCallbackMock->expects($invocationCountMatcher)->method('__invoke'); - - if (null !== $callParamsMatch) { - call_user_func_array(array($invocationMocker, 'with'), $callParamsMatch); - } - - if ($callbackClosure) { - $invocationMocker->will($this->returnCallback($callbackClosure)); - } - } - - /** - * Sets a value in the current proxy object without triggering lazy loading through `__set` - * - * @link https://bugs.php.net/bug.php?id=63463 - * - * @param string $property - * @param mixed $value - */ - public function setProxyValue($property, $value) - { - $reflectionProperty = new \ReflectionProperty($this->lazyObject, $property); - $initializer = $this->lazyObject->__getInitializer(); - - // disabling initializer since setting `publicPersistentField` triggers `__set`/`__get` - $this->lazyObject->__setInitializer(null); - $reflectionProperty->setValue($this->lazyObject, $value); - $this->lazyObject->__setInitializer($initializer); - } - - /** - * Retrieves the suggested implementation of an initializer that proxy factories in O*M - * are currently following, and that should be used to initialize the current proxy object - * - * @return \Closure - */ - protected function getSuggestedInitializerImplementation() - { - $loader = $this->proxyLoader; - $identifier = $this->identifier; - - return function (LazyLoadableObject $proxy) use ($loader, $identifier) { - /* @var $proxy LazyLoadableObject|Proxy */ - $proxy->__setInitializer(null); - $proxy->__setCloner(null); - - - if ($proxy->__isInitialized()) { - return; - } - - $properties = $proxy->__getLazyProperties(); - - foreach ($properties as $propertyName => $property) { - if (!isset($proxy->$propertyName)) { - $proxy->$propertyName = $properties[$propertyName]; - } - } - - $proxy->__setInitialized(true); - - if (method_exists($proxy, '__wakeup')) { - $proxy->__wakeup(); - } - - if (null === $loader->load($identifier, $proxy)) { - throw new \UnexpectedValueException('Couldn\'t load'); - } - }; - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyMagicMethodsTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyMagicMethodsTest.php deleted file mode 100644 index 1ed9d92a7..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyMagicMethodsTest.php +++ /dev/null @@ -1,327 +0,0 @@ -. - */ - -namespace Doctrine\Tests\Common\Proxy; - -use Doctrine\Common\Proxy\ProxyGenerator; -use Doctrine\Common\Proxy\Proxy; -use Doctrine\Common\Proxy\Exception\UnexpectedValueException; -use PHPUnit_Framework_TestCase; -use ReflectionClass; - -/** - * Test for behavior of proxies with inherited magic methods - * - * @author Marco Pivetta - */ -class ProxyMagicMethodsTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \Doctrine\Common\Proxy\ProxyGenerator - */ - protected $proxyGenerator; - - /** - * @var LazyLoadableObject|Proxy - */ - protected $lazyObject; - - protected $identifier = array( - 'publicIdentifierField' => 'publicIdentifierFieldValue', - 'protectedIdentifierField' => 'protectedIdentifierFieldValue', - ); - - /** - * @var \PHPUnit_Framework_MockObject_MockObject|Callable - */ - protected $initializerCallbackMock; - - /** - * {@inheritDoc} - */ - public function setUp() - { - $this->proxyGenerator = new ProxyGenerator(__DIR__ . '/generated', __NAMESPACE__ . '\\MagicMethodProxy'); - } - - public static function tearDownAfterClass() - { - - } - - public function testInheritedMagicGet() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicGetClass'); - $proxy = new $proxyClassName( - function (Proxy $proxy, $method, $params) use (&$counter) { - if ( ! in_array($params[0], array('publicField', 'test', 'notDefined'))) { - throw new \InvalidArgumentException('Unexpected access to field "' . $params[0] . '"'); - } - - $initializer = $proxy->__getInitializer(); - - $proxy->__setInitializer(null); - - $proxy->publicField = 'modifiedPublicField'; - $counter += 1; - - $proxy->__setInitializer($initializer); - - } - ); - - $this->assertSame('id', $proxy->id); - $this->assertSame('modifiedPublicField', $proxy->publicField); - $this->assertSame('test', $proxy->test); - $this->assertSame('not defined', $proxy->notDefined); - - $this->assertSame(3, $counter); - } - - /** - * @group DCOM-194 - */ - public function testInheritedMagicGetByRef() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicGetByRefClass'); - /* @var $proxy \Doctrine\Tests\Common\Proxy\MagicGetByRefClass */ - $proxy = new $proxyClassName(); - $proxy->valueField = 123; - $value = & $proxy->__get('value'); - - $this->assertSame(123, $value); - - $value = 456; - - $this->assertSame(456, $proxy->__get('value'), 'Value was fetched by reference'); - - $this->setExpectedException('InvalidArgumentException'); - - $undefined = $proxy->nonExisting; - } - - public function testInheritedMagicSet() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicSetClass'); - $proxy = new $proxyClassName( - function (Proxy $proxy, $method, $params) use (&$counter) { - if ( ! in_array($params[0], array('publicField', 'test', 'notDefined'))) { - throw new \InvalidArgumentException('Unexpected access to field "' . $params[0] . '"'); - } - - $counter += 1; - } - ); - - $this->assertSame('id', $proxy->id); - - $proxy->publicField = 'publicFieldValue'; - - $this->assertSame('publicFieldValue', $proxy->publicField); - - $proxy->test = 'testValue'; - - $this->assertSame('testValue', $proxy->testAttribute); - - $proxy->notDefined = 'not defined'; - - $this->assertSame('not defined', $proxy->testAttribute); - $this->assertSame(3, $counter); - } - - public function testInheritedMagicSleep() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicSleepClass'); - $proxy = new $proxyClassName(); - - $this->assertSame('defaultValue', $proxy->serializedField); - $this->assertSame('defaultValue', $proxy->nonSerializedField); - - $proxy->serializedField = 'changedValue'; - $proxy->nonSerializedField = 'changedValue'; - - $unserialized = unserialize(serialize($proxy)); - - $this->assertSame('changedValue', $unserialized->serializedField); - $this->assertSame('defaultValue', $unserialized->nonSerializedField, 'Field was not returned by "__sleep"'); - } - - public function testInheritedMagicWakeup() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicWakeupClass'); - $proxy = new $proxyClassName(); - - $this->assertSame('defaultValue', $proxy->wakeupValue); - - $proxy->wakeupValue = 'changedValue'; - $unserialized = unserialize(serialize($proxy)); - - $this->assertSame('newWakeupValue', $unserialized->wakeupValue, '"__wakeup" was called'); - - $unserialized->__setInitializer(function (Proxy $proxy) { - $proxy->__setInitializer(null); - - $proxy->publicField = 'newPublicFieldValue'; - }); - - $this->assertSame('newPublicFieldValue', $unserialized->publicField, 'Proxy can still be initialized'); - } - - public function testInheritedMagicIsset() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicIssetClass'); - $proxy = new $proxyClassName(function (Proxy $proxy, $method, $params) use (&$counter) { - if (in_array($params[0], array('publicField', 'test', 'nonExisting'))) { - $initializer = $proxy->__getInitializer(); - - $proxy->__setInitializer(null); - - $proxy->publicField = 'modifiedPublicField'; - $counter += 1; - - $proxy->__setInitializer($initializer); - - return; - } - - throw new \InvalidArgumentException( - sprintf('Should not be initialized when checking isset("%s")', $params[0]) - ); - }); - - $this->assertTrue(isset($proxy->id)); - $this->assertTrue(isset($proxy->publicField)); - $this->assertTrue(isset($proxy->test)); - $this->assertFalse(isset($proxy->nonExisting)); - - $this->assertSame(3, $counter); - } - - public function testInheritedMagicClone() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\MagicCloneClass'); - $proxy = new $proxyClassName( - null, - function ($proxy) { - $proxy->cloned = true; - } - ); - - $cloned = clone $proxy; - - $this->assertSame('newClonedValue', $cloned->clonedValue); - $this->assertFalse($proxy->cloned); - $this->assertTrue($cloned->cloned); - } - - /** - * @group DCOM-175 - */ - public function testClonesPrivateProperties() - { - $proxyClassName = $this->generateProxyClass(__NAMESPACE__ . '\\SerializedClass'); - /* @var $proxy SerializedClass */ - $proxy = new $proxyClassName(); - - $proxy->setFoo(1); - $proxy->setBar(2); - $proxy->setBaz(3); - - $unserialized = unserialize(serialize($proxy)); - - $this->assertSame(1, $unserialized->getFoo()); - $this->assertSame(2, $unserialized->getBar()); - $this->assertSame(3, $unserialized->getBaz()); - } - - /** - * @param $className - * - * @return string - */ - private function generateProxyClass($className) - { - $proxyClassName = 'Doctrine\\Tests\\Common\\Proxy\\MagicMethodProxy\\__CG__\\' . $className; - - if (class_exists($proxyClassName, false)) { - return $proxyClassName; - } - - $metadata = $this->getMock('Doctrine\\Common\\Persistence\\Mapping\\ClassMetadata'); - - $metadata - ->expects($this->any()) - ->method('getName') - ->will($this->returnValue($className)); - - $metadata - ->expects($this->any()) - ->method('getIdentifier') - ->will($this->returnValue(array('id'))); - - $metadata - ->expects($this->any()) - ->method('getReflectionClass') - ->will($this->returnValue(new ReflectionClass($className))); - - $metadata - ->expects($this->any()) - ->method('isIdentifier') - ->will($this->returnCallback(function ($fieldName) { - return 'id' === $fieldName; - })); - - $metadata - ->expects($this->any()) - ->method('hasField') - ->will($this->returnCallback(function ($fieldName) { - return in_array($fieldName, array('id', 'publicField')); - })); - - $metadata - ->expects($this->any()) - ->method('hasAssociation') - ->will($this->returnValue(false)); - - $metadata - ->expects($this->any()) - ->method('getFieldNames') - ->will($this->returnValue(array('id', 'publicField'))); - - $metadata - ->expects($this->any()) - ->method('getIdentifierFieldNames') - ->will($this->returnValue(array('id'))); - - $metadata - ->expects($this->any()) - ->method('getAssociationNames') - ->will($this->returnValue(array())); - - $metadata - ->expects($this->any()) - ->method('getTypeOfField') - ->will($this->returnValue('string')); - - $this->proxyGenerator->generateProxyClass($metadata, $this->proxyGenerator->getProxyFileName($className)); - require_once $this->proxyGenerator->getProxyFileName($className); - - return $proxyClassName; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SerializedClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SerializedClass.php deleted file mode 100644 index a36c3bb74..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SerializedClass.php +++ /dev/null @@ -1,72 +0,0 @@ -foo = $foo; - } - - /** - * @return mixed|string - */ - public function getFoo() - { - return $this->foo; - } - - /** - * @param $bar - */ - public function setBar($bar) - { - $this->bar = $bar; - } - - /** - * @return mixed|string - */ - public function getBar() - { - return $this->bar; - } - - /** - * @param $baz - */ - public function setBaz($baz) - { - $this->baz = $baz; - } - - /** - * @return mixed|string - */ - public function getBaz() - { - return $this->baz; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SleepClass.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SleepClass.php deleted file mode 100644 index 3c6ffcdba..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/SleepClass.php +++ /dev/null @@ -1,19 +0,0 @@ -types = $types; - } - - public function addTypeWithMultipleParameters($foo, $bar, ...$baz) - { - $this->foo = $foo; - $this->bar = $bar; - $this->baz = $baz; - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/DeeperNamespaceParent.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/DeeperNamespaceParent.php deleted file mode 100644 index 11b3fc8fa..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/DeeperNamespaceParent.php +++ /dev/null @@ -1,7 +0,0 @@ -getMock('stdClass', array('callGet')); - $getCheckMock->expects($this->never())->method('callGet'); - $initializer = function () use ($getCheckMock) { - call_user_func($getCheckMock); - }; - - $mockProxy = new RuntimePublicReflectionPropertyTestProxyMock(); - $mockProxy->__setInitializer($initializer); - - $reflProperty = new RuntimePublicReflectionProperty( - __NAMESPACE__ . '\RuntimePublicReflectionPropertyTestProxyMock', - 'checkedProperty' - ); - - $this->assertSame('testValue', $reflProperty->getValue($mockProxy)); - unset($mockProxy->checkedProperty); - $this->assertNull($reflProperty->getValue($mockProxy)); - } - - public function testSetValueOnProxyPublicProperty() - { - $setCheckMock = $this->getMock('stdClass', array('neverCallSet')); - $setCheckMock->expects($this->never())->method('neverCallSet'); - $initializer = function () use ($setCheckMock) { - call_user_func(array($setCheckMock, 'neverCallSet')); - }; - - $mockProxy = new RuntimePublicReflectionPropertyTestProxyMock(); - $mockProxy->__setInitializer($initializer); - - $reflProperty = new RuntimePublicReflectionProperty( - __NAMESPACE__ . '\RuntimePublicReflectionPropertyTestProxyMock', - 'checkedProperty' - ); - - $reflProperty->setValue($mockProxy, 'newValue'); - $this->assertSame('newValue', $mockProxy->checkedProperty); - - unset($mockProxy->checkedProperty); - $reflProperty->setValue($mockProxy, 'otherNewValue'); - $this->assertSame('otherNewValue', $mockProxy->checkedProperty); - - $setCheckMock = $this->getMock('stdClass', array('callSet')); - $setCheckMock->expects($this->once())->method('callSet'); - $initializer = function () use ($setCheckMock) { - call_user_func(array($setCheckMock, 'callSet')); - }; - - $mockProxy->__setInitializer($initializer); - $mockProxy->__setInitialized(true); - - unset($mockProxy->checkedProperty); - $reflProperty->setValue($mockProxy, 'againNewValue'); - $this->assertSame('againNewValue', $mockProxy->checkedProperty); - } -} - -/** - * Mock that simulates proxy public property lazy loading - */ -class RuntimePublicReflectionPropertyTestProxyMock implements Proxy -{ - /** - * @var \Closure|null - */ - private $initializer = null; - - /** - * @var \Closure|null - */ - private $initialized = false; - - /** - * @var string - */ - public $checkedProperty = 'testValue'; - - /** - * {@inheritDoc} - */ - public function __getInitializer() - { - return $this->initializer; - } - - /** - * {@inheritDoc} - */ - public function __setInitializer(\Closure $initializer = null) - { - $this->initializer = $initializer; - } - - /** - * {@inheritDoc} - */ - public function __getLazyProperties() - { - } - - /** - * {@inheritDoc} - */ - public function __load() - { - } - - /** - * {@inheritDoc} - */ - public function __isInitialized() - { - return $this->initialized; - } - - /** - * {@inheritDoc} - */ - public function __setInitialized($initialized) - { - $this->initialized = (bool) $initialized; - } - - /** - * @param string $name - */ - public function __get($name) - { - if ($this->initializer) { - $cb = $this->initializer; - $cb(); - } - - return $this->checkedProperty; - } - - /** - * @param string $name - * @param mixed $value - */ - public function __set($name, $value) - { - if ($this->initializer) { - $cb = $this->initializer; - $cb(); - } - - // triggers notices if `$name` is used: see https://bugs.php.net/bug.php?id=63463 - $this->checkedProperty = $value; - } - - /** - * @param string $name - * - * @return integer - */ - public function __isset($name) - { - if ($this->initializer) { - $cb = $this->initializer; - $cb(); - } - - return isset($this->checkedProperty); - } - - /** - * {@inheritDoc} - */ - public function __setCloner(\Closure $cloner = null) - { - } - - /** - * {@inheritDoc} - */ - public function __getCloner() - { - } -} \ No newline at end of file diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/SameNamespaceParent.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/SameNamespaceParent.php deleted file mode 100644 index 844d4a55e..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/SameNamespaceParent.php +++ /dev/null @@ -1,7 +0,0 @@ -setExpectedException('ReflectionException'); - } - - $testsRoot = substr(__DIR__, 0, -strlen(__NAMESPACE__) - 1); - $paths = array( - 'Doctrine\\Tests' => array($testsRoot), - ); - $staticReflectionParser = new StaticReflectionParser($parsedClassName, new Psr0FindFile($paths), $classAnnotationOptimize); - $declaringClassName = $staticReflectionParser->getStaticReflectionParserForDeclaringClass('property', 'test')->getClassName(); - $this->assertEquals($expectedClassName, $declaringClassName); - - } - - /** - * @return array - */ - public function parentClassData() - { - $data = array(); - $noParentClassName = 'Doctrine\\Tests\\Common\\Reflection\\NoParent'; - $dummyParentClassName = 'Doctrine\\Tests\\Common\\Reflection\\Dummies\\NoParent'; - foreach (array(false, true) as $classAnnotationOptimize) { - $data[] = array( - $classAnnotationOptimize, $noParentClassName, $noParentClassName, - ); - $data[] = array( - $classAnnotationOptimize, 'Doctrine\\Tests\\Common\\Reflection\\FullyClassifiedParent', $noParentClassName, - ); - $data[] = array( - $classAnnotationOptimize, 'Doctrine\\Tests\\Common\\Reflection\\SameNamespaceParent', $noParentClassName, - ); - $data[] = array( - $classAnnotationOptimize, 'Doctrine\\Tests\\Common\\Reflection\\DeeperNamespaceParent', $dummyParentClassName, - ); - $data[] = array( - $classAnnotationOptimize, 'Doctrine\\Tests\\Common\\Reflection\\UseParent', $dummyParentClassName, - ); - } - return $data; - } - - /** - * @dataProvider classAnnotationOptimize - */ - public function testClassAnnotationOptimizedParsing($classAnnotationOptimize) { - $testsRoot = substr(__DIR__, 0, -strlen(__NAMESPACE__) - 1); - $paths = array( - 'Doctrine\\Tests' => array($testsRoot), - ); - $staticReflectionParser = new StaticReflectionParser('Doctrine\\Tests\\Common\\Reflection\\ExampleAnnotationClass', new Psr0FindFile($paths), $classAnnotationOptimize); - $expectedDocComment = '/** - * @Annotation( - * key = "value" - * ) - */'; - $this->assertEquals($expectedDocComment, $staticReflectionParser->getDocComment('class')); - } - - /** - * @return array - */ - public function classAnnotationOptimize() - { - return array( - array(false), - array(true) - ); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/UseParent.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/UseParent.php deleted file mode 100644 index dd512d4d6..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Reflection/UseParent.php +++ /dev/null @@ -1,9 +0,0 @@ -assertEquals($expectedClassName, ClassUtils::getRealClass($className)); - } - - /** - * @dataProvider dataGetClass - */ - public function testGetClass( $className, $expectedClassName ) - { - $object = new $className(); - $this->assertEquals($expectedClassName, ClassUtils::getClass($object)); - } - - public function testGetParentClass() - { - $parentClass = ClassUtils::getParentClass( 'MyProject\Proxies\__CG__\OtherProject\Proxies\__CG__\Doctrine\Tests\Common\Util\ChildObject' ); - $this->assertEquals('stdClass', $parentClass); - } - - public function testGenerateProxyClassName() - { - $this->assertEquals( 'Proxies\__CG__\stdClass', ClassUtils::generateProxyClassName( 'stdClass', 'Proxies' ) ); - } - - /** - * @dataProvider dataGetClass - */ - public function testNewReflectionClass( $className, $expectedClassName ) - { - $reflClass = ClassUtils::newReflectionClass( $className ); - $this->assertEquals( $expectedClassName, $reflClass->getName() ); - } - - /** - * @dataProvider dataGetClass - */ - public function testNewReflectionObject( $className, $expectedClassName ) - { - $object = new $className; - $reflClass = ClassUtils::newReflectionObject( $object ); - $this->assertEquals( $expectedClassName, $reflClass->getName() ); - } - } - - class ChildObject extends \stdClass - { - } -} - -namespace MyProject\Proxies\__CG__ -{ - class stdClass extends \stdClass - { - } -} - -namespace MyProject\Proxies\__CG__\Doctrine\Tests\Common\Util -{ - class ChildObject extends \Doctrine\Tests\Common\Util\ChildObject - { - } -} - -namespace MyProject\Proxies\__CG__\OtherProject\Proxies\__CG__ -{ - class stdClass extends \MyProject\Proxies\__CG__\stdClass - { - } -} - -namespace MyProject\Proxies\__CG__\OtherProject\Proxies\__CG__\Doctrine\Tests\Common\Util -{ - class ChildObject extends \MyProject\Proxies\__CG__\Doctrine\Tests\Common\Util\ChildObject - { - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Util/DebugTest.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Util/DebugTest.php deleted file mode 100644 index 66e83376f..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Util/DebugTest.php +++ /dev/null @@ -1,65 +0,0 @@ -foo = "bar"; - $obj->bar = 1234; - - $var = Debug::export($obj, 2); - $this->assertEquals( "stdClass", $var->__CLASS__ ); - } - - public function testExportDateTime() - { - $obj = new \DateTime( "2010-10-10 10:10:10" ); - - $var = Debug::export( $obj, 2 ); - $this->assertEquals( "DateTime", $var->__CLASS__ ); - } - - public function testExportArrayTraversable() - { - $obj = new \ArrayObject(array('foobar')); - - $var = Debug::export($obj, 2); - $this->assertContains('foobar', $var->__STORAGE__); - - $it = new \ArrayIterator(array('foobar')); - - $var = Debug::export($it, 5); - $this->assertContains('foobar', $var->__STORAGE__); - } - - public function testReturnsOutput() - { - ob_start(); - - $dump = Debug::dump('foo'); - $outputValue = ob_get_contents(); - - ob_end_clean(); - - $this->assertSame($outputValue, $dump); - } - - public function testDisablesOutput() - { - ob_start(); - - $dump = Debug::dump('foo', 2, true, false); - $outputValue = ob_get_contents(); - - ob_end_clean(); - - $this->assertEmpty($outputValue); - $this->assertNotSame($outputValue, $dump); - } -} diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/DoctrineTestCase.php b/vendor/doctrine/common/tests/Doctrine/Tests/DoctrineTestCase.php deleted file mode 100644 index e8323d294..000000000 --- a/vendor/doctrine/common/tests/Doctrine/Tests/DoctrineTestCase.php +++ /dev/null @@ -1,10 +0,0 @@ - Doctrine/Tests/ORM/Functional/Locking/GearmanLockTest.php - -This can run considerable time, because it is using sleep() to test for the timing ranges of locks. \ No newline at end of file diff --git a/vendor/doctrine/inflector/tests/Doctrine/Tests/Common/Inflector/InflectorTest.php b/vendor/doctrine/inflector/tests/Doctrine/Tests/Common/Inflector/InflectorTest.php deleted file mode 100644 index a8a075daa..000000000 --- a/vendor/doctrine/inflector/tests/Doctrine/Tests/Common/Inflector/InflectorTest.php +++ /dev/null @@ -1,210 +0,0 @@ -assertEquals( - $singular, - Inflector::singularize($plural), - "'$plural' should be singularized to '$singular'" - ); - } - - /** - * testInflectingPlurals method - * - * @dataProvider dataSampleWords - * @return void - */ - public function testInflectingPlurals($singular, $plural) - { - $this->assertEquals( - $plural, - Inflector::pluralize($singular), - "'$singular' should be pluralized to '$plural'" - ); - } - - /** - * testCustomPluralRule method - * - * @return void - */ - public function testCustomPluralRule() - { - Inflector::reset(); - Inflector::rules('plural', array('/^(custom)$/i' => '\1izables')); - - $this->assertEquals(Inflector::pluralize('custom'), 'customizables'); - - Inflector::rules('plural', array('uninflected' => array('uninflectable'))); - - $this->assertEquals(Inflector::pluralize('uninflectable'), 'uninflectable'); - - Inflector::rules('plural', array( - 'rules' => array('/^(alert)$/i' => '\1ables'), - 'uninflected' => array('noflect', 'abtuse'), - 'irregular' => array('amaze' => 'amazable', 'phone' => 'phonezes') - )); - - $this->assertEquals(Inflector::pluralize('noflect'), 'noflect'); - $this->assertEquals(Inflector::pluralize('abtuse'), 'abtuse'); - $this->assertEquals(Inflector::pluralize('alert'), 'alertables'); - $this->assertEquals(Inflector::pluralize('amaze'), 'amazable'); - $this->assertEquals(Inflector::pluralize('phone'), 'phonezes'); - } - - /** - * testCustomSingularRule method - * - * @return void - */ - public function testCustomSingularRule() - { - Inflector::reset(); - Inflector::rules('singular', array('/(eple)r$/i' => '\1', '/(jente)r$/i' => '\1')); - - $this->assertEquals(Inflector::singularize('epler'), 'eple'); - $this->assertEquals(Inflector::singularize('jenter'), 'jente'); - - Inflector::rules('singular', array( - 'rules' => array('/^(bil)er$/i' => '\1', '/^(inflec|contribu)tors$/i' => '\1ta'), - 'uninflected' => array('singulars'), - 'irregular' => array('spins' => 'spinor') - )); - - $this->assertEquals(Inflector::singularize('inflectors'), 'inflecta'); - $this->assertEquals(Inflector::singularize('contributors'), 'contributa'); - $this->assertEquals(Inflector::singularize('spins'), 'spinor'); - $this->assertEquals(Inflector::singularize('singulars'), 'singulars'); - } - - /** - * test that setting new rules clears the inflector caches. - * - * @return void - */ - public function testRulesClearsCaches() - { - Inflector::reset(); - - $this->assertEquals(Inflector::singularize('Bananas'), 'Banana'); - $this->assertEquals(Inflector::pluralize('Banana'), 'Bananas'); - - Inflector::rules('singular', array( - 'rules' => array('/(.*)nas$/i' => '\1zzz') - )); - - $this->assertEquals('Banazzz', Inflector::singularize('Bananas'), 'Was inflected with old rules.'); - - Inflector::rules('plural', array( - 'rules' => array('/(.*)na$/i' => '\1zzz'), - 'irregular' => array('corpus' => 'corpora') - )); - - $this->assertEquals(Inflector::pluralize('Banana'), 'Banazzz', 'Was inflected with old rules.'); - $this->assertEquals(Inflector::pluralize('corpus'), 'corpora', 'Was inflected with old irregular form.'); - } - - /** - * Test resetting inflection rules. - * - * @return void - */ - public function testCustomRuleWithReset() - { - Inflector::reset(); - - $uninflected = array('atlas', 'lapis', 'onibus', 'pires', 'virus', '.*x'); - $pluralIrregular = array('as' => 'ases'); - - Inflector::rules('singular', array( - 'rules' => array('/^(.*)(a|e|o|u)is$/i' => '\1\2l'), - 'uninflected' => $uninflected, - ), true); - - Inflector::rules('plural', array( - 'rules' => array( - '/^(.*)(a|e|o|u)l$/i' => '\1\2is', - ), - 'uninflected' => $uninflected, - 'irregular' => $pluralIrregular - ), true); - - $this->assertEquals(Inflector::pluralize('Alcool'), 'Alcoois'); - $this->assertEquals(Inflector::pluralize('Atlas'), 'Atlas'); - $this->assertEquals(Inflector::singularize('Alcoois'), 'Alcool'); - $this->assertEquals(Inflector::singularize('Atlas'), 'Atlas'); - } -} - diff --git a/vendor/doctrine/inflector/tests/Doctrine/Tests/DoctrineTestCase.php b/vendor/doctrine/inflector/tests/Doctrine/Tests/DoctrineTestCase.php deleted file mode 100644 index e8323d294..000000000 --- a/vendor/doctrine/inflector/tests/Doctrine/Tests/DoctrineTestCase.php +++ /dev/null @@ -1,10 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorPerformance; - -use Athletic\AthleticEvent; -use Doctrine\Instantiator\Instantiator; - -/** - * Performance tests for {@see \Doctrine\Instantiator\Instantiator} - * - * @author Marco Pivetta - */ -class InstantiatorPerformanceEvent extends AthleticEvent -{ - /** - * @var \Doctrine\Instantiator\Instantiator - */ - private $instantiator; - - /** - * {@inheritDoc} - */ - protected function setUp() - { - $this->instantiator = new Instantiator(); - - $this->instantiator->instantiate(__CLASS__); - $this->instantiator->instantiate('ArrayObject'); - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\SimpleSerializableAsset'); - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\SerializableArrayObjectAsset'); - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\UnCloneableAsset'); - } - - /** - * @iterations 20000 - * @baseline - * @group instantiation - */ - public function testInstantiateSelf() - { - $this->instantiator->instantiate(__CLASS__); - } - - /** - * @iterations 20000 - * @group instantiation - */ - public function testInstantiateInternalClass() - { - $this->instantiator->instantiate('ArrayObject'); - } - - /** - * @iterations 20000 - * @group instantiation - */ - public function testInstantiateSimpleSerializableAssetClass() - { - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\SimpleSerializableAsset'); - } - - /** - * @iterations 20000 - * @group instantiation - */ - public function testInstantiateSerializableArrayObjectAsset() - { - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\SerializableArrayObjectAsset'); - } - - /** - * @iterations 20000 - * @group instantiation - */ - public function testInstantiateUnCloneableAsset() - { - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\UnCloneableAsset'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/InvalidArgumentExceptionTest.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/InvalidArgumentExceptionTest.php deleted file mode 100644 index 39d9b94df..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/InvalidArgumentExceptionTest.php +++ /dev/null @@ -1,83 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTest\Exception; - -use Doctrine\Instantiator\Exception\InvalidArgumentException; -use PHPUnit_Framework_TestCase; -use ReflectionClass; - -/** - * Tests for {@see \Doctrine\Instantiator\Exception\InvalidArgumentException} - * - * @author Marco Pivetta - * - * @covers \Doctrine\Instantiator\Exception\InvalidArgumentException - */ -class InvalidArgumentExceptionTest extends PHPUnit_Framework_TestCase -{ - public function testFromNonExistingTypeWithNonExistingClass() - { - $className = __CLASS__ . uniqid(); - $exception = InvalidArgumentException::fromNonExistingClass($className); - - $this->assertInstanceOf('Doctrine\\Instantiator\\Exception\\InvalidArgumentException', $exception); - $this->assertSame('The provided class "' . $className . '" does not exist', $exception->getMessage()); - } - - public function testFromNonExistingTypeWithTrait() - { - if (PHP_VERSION_ID < 50400) { - $this->markTestSkipped('Need at least PHP 5.4.0, as this test requires traits support to run'); - } - - $exception = InvalidArgumentException::fromNonExistingClass( - 'DoctrineTest\\InstantiatorTestAsset\\SimpleTraitAsset' - ); - - $this->assertSame( - 'The provided type "DoctrineTest\\InstantiatorTestAsset\\SimpleTraitAsset" is a trait, ' - . 'and can not be instantiated', - $exception->getMessage() - ); - } - - public function testFromNonExistingTypeWithInterface() - { - $exception = InvalidArgumentException::fromNonExistingClass('Doctrine\\Instantiator\\InstantiatorInterface'); - - $this->assertSame( - 'The provided type "Doctrine\\Instantiator\\InstantiatorInterface" is an interface, ' - . 'and can not be instantiated', - $exception->getMessage() - ); - } - - public function testFromAbstractClass() - { - $reflection = new ReflectionClass('DoctrineTest\\InstantiatorTestAsset\\AbstractClassAsset'); - $exception = InvalidArgumentException::fromAbstractClass($reflection); - - $this->assertSame( - 'The provided class "DoctrineTest\\InstantiatorTestAsset\\AbstractClassAsset" is abstract, ' - . 'and can not be instantiated', - $exception->getMessage() - ); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/UnexpectedValueExceptionTest.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/UnexpectedValueExceptionTest.php deleted file mode 100644 index 84154e739..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/Exception/UnexpectedValueExceptionTest.php +++ /dev/null @@ -1,69 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTest\Exception; - -use Doctrine\Instantiator\Exception\UnexpectedValueException; -use Exception; -use PHPUnit_Framework_TestCase; -use ReflectionClass; - -/** - * Tests for {@see \Doctrine\Instantiator\Exception\UnexpectedValueException} - * - * @author Marco Pivetta - * - * @covers \Doctrine\Instantiator\Exception\UnexpectedValueException - */ -class UnexpectedValueExceptionTest extends PHPUnit_Framework_TestCase -{ - public function testFromSerializationTriggeredException() - { - $reflectionClass = new ReflectionClass($this); - $previous = new Exception(); - $exception = UnexpectedValueException::fromSerializationTriggeredException($reflectionClass, $previous); - - $this->assertInstanceOf('Doctrine\\Instantiator\\Exception\\UnexpectedValueException', $exception); - $this->assertSame($previous, $exception->getPrevious()); - $this->assertSame( - 'An exception was raised while trying to instantiate an instance of "' - . __CLASS__ . '" via un-serialization', - $exception->getMessage() - ); - } - - public function testFromUncleanUnSerialization() - { - $reflection = new ReflectionClass('DoctrineTest\\InstantiatorTestAsset\\AbstractClassAsset'); - $exception = UnexpectedValueException::fromUncleanUnSerialization($reflection, 'foo', 123, 'bar', 456); - - $this->assertInstanceOf('Doctrine\\Instantiator\\Exception\\UnexpectedValueException', $exception); - $this->assertSame( - 'Could not produce an instance of "DoctrineTest\\InstantiatorTestAsset\\AbstractClassAsset" ' - . 'via un-serialization, since an error was triggered in file "bar" at line "456"', - $exception->getMessage() - ); - - $previous = $exception->getPrevious(); - - $this->assertInstanceOf('Exception', $previous); - $this->assertSame('foo', $previous->getMessage()); - $this->assertSame(123, $previous->getCode()); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/InstantiatorTest.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/InstantiatorTest.php deleted file mode 100644 index 0a2cb9313..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTest/InstantiatorTest.php +++ /dev/null @@ -1,219 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTest; - -use Doctrine\Instantiator\Exception\UnexpectedValueException; -use Doctrine\Instantiator\Instantiator; -use PHPUnit_Framework_TestCase; -use ReflectionClass; - -/** - * Tests for {@see \Doctrine\Instantiator\Instantiator} - * - * @author Marco Pivetta - * - * @covers \Doctrine\Instantiator\Instantiator - */ -class InstantiatorTest extends PHPUnit_Framework_TestCase -{ - /** - * @var Instantiator - */ - private $instantiator; - - /** - * {@inheritDoc} - */ - protected function setUp() - { - $this->instantiator = new Instantiator(); - } - - /** - * @param string $className - * - * @dataProvider getInstantiableClasses - */ - public function testCanInstantiate($className) - { - $this->assertInstanceOf($className, $this->instantiator->instantiate($className)); - } - - /** - * @param string $className - * - * @dataProvider getInstantiableClasses - */ - public function testInstantiatesSeparateInstances($className) - { - $instance1 = $this->instantiator->instantiate($className); - $instance2 = $this->instantiator->instantiate($className); - - $this->assertEquals($instance1, $instance2); - $this->assertNotSame($instance1, $instance2); - } - - public function testExceptionOnUnSerializationException() - { - if (defined('HHVM_VERSION')) { - $this->markTestSkipped( - 'As of facebook/hhvm#3432, HHVM has no PDORow, and therefore ' - . ' no internal final classes that cannot be instantiated' - ); - } - - $className = 'DoctrineTest\\InstantiatorTestAsset\\UnserializeExceptionArrayObjectAsset'; - - if (\PHP_VERSION_ID >= 50600) { - $className = 'PDORow'; - } - - if (\PHP_VERSION_ID === 50429 || \PHP_VERSION_ID === 50513) { - $className = 'DoctrineTest\\InstantiatorTestAsset\\SerializableArrayObjectAsset'; - } - - $this->setExpectedException('Doctrine\\Instantiator\\Exception\\UnexpectedValueException'); - - $this->instantiator->instantiate($className); - } - - public function testNoticeOnUnSerializationException() - { - if (\PHP_VERSION_ID >= 50600) { - $this->markTestSkipped( - 'PHP 5.6 supports `ReflectionClass#newInstanceWithoutConstructor()` for some internal classes' - ); - } - - try { - $this->instantiator->instantiate('DoctrineTest\\InstantiatorTestAsset\\WakeUpNoticesAsset'); - - $this->fail('No exception was raised'); - } catch (UnexpectedValueException $exception) { - $wakeUpNoticesReflection = new ReflectionClass('DoctrineTest\\InstantiatorTestAsset\\WakeUpNoticesAsset'); - $previous = $exception->getPrevious(); - - $this->assertInstanceOf('Exception', $previous); - - // in PHP 5.4.29 and PHP 5.5.13, this case is not a notice, but an exception being thrown - if (! (\PHP_VERSION_ID === 50429 || \PHP_VERSION_ID === 50513)) { - $this->assertSame( - 'Could not produce an instance of "DoctrineTest\\InstantiatorTestAsset\WakeUpNoticesAsset" ' - . 'via un-serialization, since an error was triggered in file "' - . $wakeUpNoticesReflection->getFileName() . '" at line "36"', - $exception->getMessage() - ); - - $this->assertSame('Something went bananas while un-serializing this instance', $previous->getMessage()); - $this->assertSame(\E_USER_NOTICE, $previous->getCode()); - } - } - } - - /** - * @param string $invalidClassName - * - * @dataProvider getInvalidClassNames - */ - public function testInstantiationFromNonExistingClass($invalidClassName) - { - $this->setExpectedException('Doctrine\\Instantiator\\Exception\\InvalidArgumentException'); - - $this->instantiator->instantiate($invalidClassName); - } - - public function testInstancesAreNotCloned() - { - $className = 'TemporaryClass' . uniqid(); - - eval('namespace ' . __NAMESPACE__ . '; class ' . $className . '{}'); - - $instance = $this->instantiator->instantiate(__NAMESPACE__ . '\\' . $className); - - $instance->foo = 'bar'; - - $instance2 = $this->instantiator->instantiate(__NAMESPACE__ . '\\' . $className); - - $this->assertObjectNotHasAttribute('foo', $instance2); - } - - /** - * Provides a list of instantiable classes (existing) - * - * @return string[][] - */ - public function getInstantiableClasses() - { - $classes = array( - array('stdClass'), - array(__CLASS__), - array('Doctrine\\Instantiator\\Instantiator'), - array('Exception'), - array('PharException'), - array('DoctrineTest\\InstantiatorTestAsset\\SimpleSerializableAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\ExceptionAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\FinalExceptionAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\PharExceptionAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\UnCloneableAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\XMLReaderAsset'), - ); - - if (\PHP_VERSION_ID === 50429 || \PHP_VERSION_ID === 50513) { - return $classes; - } - - $classes = array_merge( - $classes, - array( - array('PharException'), - array('ArrayObject'), - array('DoctrineTest\\InstantiatorTestAsset\\ArrayObjectAsset'), - array('DoctrineTest\\InstantiatorTestAsset\\SerializableArrayObjectAsset'), - ) - ); - - if (\PHP_VERSION_ID >= 50600) { - $classes[] = array('DoctrineTest\\InstantiatorTestAsset\\WakeUpNoticesAsset'); - $classes[] = array('DoctrineTest\\InstantiatorTestAsset\\UnserializeExceptionArrayObjectAsset'); - } - - return $classes; - } - - /** - * Provides a list of instantiable classes (existing) - * - * @return string[][] - */ - public function getInvalidClassNames() - { - $classNames = array( - array(__CLASS__ . uniqid()), - array('Doctrine\\Instantiator\\InstantiatorInterface'), - array('DoctrineTest\\InstantiatorTestAsset\\AbstractClassAsset'), - ); - - if (\PHP_VERSION_ID >= 50400) { - $classNames[] = array('DoctrineTest\\InstantiatorTestAsset\\SimpleTraitAsset'); - } - - return $classNames; - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/AbstractClassAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/AbstractClassAsset.php deleted file mode 100644 index fbe28ddd0..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/AbstractClassAsset.php +++ /dev/null @@ -1,29 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -/** - * A simple asset for an abstract class - * - * @author Marco Pivetta - */ -abstract class AbstractClassAsset -{ -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ArrayObjectAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ArrayObjectAsset.php deleted file mode 100644 index 56146d709..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ArrayObjectAsset.php +++ /dev/null @@ -1,41 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use ArrayObject; -use BadMethodCallException; - -/** - * Test asset that extends an internal PHP class - * - * @author Marco Pivetta - */ -class ArrayObjectAsset extends ArrayObject -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ExceptionAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ExceptionAsset.php deleted file mode 100644 index 43bbe46b7..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/ExceptionAsset.php +++ /dev/null @@ -1,41 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use Exception; - -/** - * Test asset that extends an internal PHP base exception - * - * @author Marco Pivetta - */ -class ExceptionAsset extends Exception -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/FinalExceptionAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/FinalExceptionAsset.php deleted file mode 100644 index 7d268f5b3..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/FinalExceptionAsset.php +++ /dev/null @@ -1,41 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use Exception; - -/** - * Test asset that extends an internal PHP base exception - * - * @author Marco Pivetta - */ -final class FinalExceptionAsset extends Exception -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharAsset.php deleted file mode 100644 index 553fd5612..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharAsset.php +++ /dev/null @@ -1,41 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use Phar; - -/** - * Test asset that extends an internal PHP class - * - * @author Marco Pivetta - */ -class PharAsset extends Phar -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharExceptionAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharExceptionAsset.php deleted file mode 100644 index 42bf73e7e..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/PharExceptionAsset.php +++ /dev/null @@ -1,44 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use PharException; - -/** - * Test asset that extends an internal PHP class - * This class should be serializable without problems - * and without getting the "Erroneous data format for unserializing" - * error - * - * @author Marco Pivetta - */ -class PharExceptionAsset extends PharException -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SerializableArrayObjectAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SerializableArrayObjectAsset.php deleted file mode 100644 index ba19aaf63..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SerializableArrayObjectAsset.php +++ /dev/null @@ -1,62 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use ArrayObject; -use BadMethodCallException; -use Serializable; - -/** - * Serializable test asset that also extends an internal class - * - * @author Marco Pivetta - */ -class SerializableArrayObjectAsset extends ArrayObject implements Serializable -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } - - /** - * {@inheritDoc} - */ - public function serialize() - { - return ''; - } - - /** - * {@inheritDoc} - * - * Should not be called - * - * @throws BadMethodCallException - */ - public function unserialize($serialized) - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleSerializableAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleSerializableAsset.php deleted file mode 100644 index 39f84a6c0..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleSerializableAsset.php +++ /dev/null @@ -1,61 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use Serializable; - -/** - * Base serializable test asset - * - * @author Marco Pivetta - */ -class SimpleSerializableAsset implements Serializable -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } - - /** - * {@inheritDoc} - */ - public function serialize() - { - return ''; - } - - /** - * {@inheritDoc} - * - * Should not be called - * - * @throws BadMethodCallException - */ - public function unserialize($serialized) - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleTraitAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleTraitAsset.php deleted file mode 100644 index 04e78069d..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/SimpleTraitAsset.php +++ /dev/null @@ -1,29 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -/** - * A simple trait with no attached logic - * - * @author Marco Pivetta - */ -trait SimpleTraitAsset -{ -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnCloneableAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnCloneableAsset.php deleted file mode 100644 index 7d03bdab0..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnCloneableAsset.php +++ /dev/null @@ -1,50 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; - -/** - * Base un-cloneable asset - * - * @author Marco Pivetta - */ -class UnCloneableAsset -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } - - /** - * Magic `__clone` - should not be invoked - * - * @throws BadMethodCallException - */ - public function __clone() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnserializeExceptionArrayObjectAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnserializeExceptionArrayObjectAsset.php deleted file mode 100644 index b348a4053..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/UnserializeExceptionArrayObjectAsset.php +++ /dev/null @@ -1,39 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use ArrayObject; -use BadMethodCallException; - -/** - * A simple asset for an abstract class - * - * @author Marco Pivetta - */ -class UnserializeExceptionArrayObjectAsset extends ArrayObject -{ - /** - * {@inheritDoc} - */ - public function __wakeup() - { - throw new BadMethodCallException(); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/WakeUpNoticesAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/WakeUpNoticesAsset.php deleted file mode 100644 index 18dc6711d..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/WakeUpNoticesAsset.php +++ /dev/null @@ -1,38 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use ArrayObject; - -/** - * A simple asset for an abstract class - * - * @author Marco Pivetta - */ -class WakeUpNoticesAsset extends ArrayObject -{ - /** - * Wakeup method called after un-serialization - */ - public function __wakeup() - { - trigger_error('Something went bananas while un-serializing this instance'); - } -} diff --git a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/XMLReaderAsset.php b/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/XMLReaderAsset.php deleted file mode 100644 index 39ee6992a..000000000 --- a/vendor/doctrine/instantiator/tests/DoctrineTest/InstantiatorTestAsset/XMLReaderAsset.php +++ /dev/null @@ -1,41 +0,0 @@ -. - */ - -namespace DoctrineTest\InstantiatorTestAsset; - -use BadMethodCallException; -use XMLReader; - -/** - * Test asset that extends an internal PHP class - * - * @author Dave Marshall - */ -class XMLReaderAsset extends XMLReader -{ - /** - * Constructor - should not be called - * - * @throws BadMethodCallException - */ - public function __construct() - { - throw new BadMethodCallException('Not supposed to be called!'); - } -} diff --git a/vendor/egulias/email-validator/documentation/Other.md b/vendor/egulias/email-validator/documentation/Other.md deleted file mode 100644 index 9ec4bd9e5..000000000 --- a/vendor/egulias/email-validator/documentation/Other.md +++ /dev/null @@ -1,69 +0,0 @@ -Email length ------------- -http://tools.ietf.org/html/rfc5321#section-4.1.2 - Forward-path = Path - - Path = "<" [ A-d-l ":" ] Mailbox ">" - -http://tools.ietf.org/html/rfc5321#section-4.5.3.1.3 -http://tools.ietf.org/html/rfc1035#section-2.3.4 - -DNS ---- - -http://tools.ietf.org/html/rfc5321#section-2.3.5 - Names that can - be resolved to MX RRs or address (i.e., A or AAAA) RRs (as discussed - in Section 5) are permitted, as are CNAME RRs whose targets can be - resolved, in turn, to MX or address RRs. - -http://tools.ietf.org/html/rfc5321#section-5.1 - The lookup first attempts to locate an MX record associated with the - name. If a CNAME record is found, the resulting name is processed as - if it were the initial name. ... If an empty list of MXs is returned, - the address is treated as if it was associated with an implicit MX - RR, with a preference of 0, pointing to that host. - -is_email() author's note: We will regard the existence of a CNAME to be -sufficient evidence of the domain's existence. For performance reasons -we will not repeat the DNS lookup for the CNAME's target, but we will -raise a warning because we didn't immediately find an MX record. - -Check for TLD addresses ------------------------ -TLD addresses are specifically allowed in RFC 5321 but they are -unusual to say the least. We will allocate a separate -status to these addresses on the basis that they are more likely -to be typos than genuine addresses (unless we've already -established that the domain does have an MX record) - -http://tools.ietf.org/html/rfc5321#section-2.3.5 - In the case - of a top-level domain used by itself in an email address, a single - string is used without any dots. This makes the requirement, - described in more detail below, that only fully-qualified domain - names appear in SMTP transactions on the public Internet, - particularly important where top-level domains are involved. - -TLD format ----------- -The format of TLDs has changed a number of times. The standards -used by IANA have been largely ignored by ICANN, leading to -confusion over the standards being followed. These are not defined -anywhere, except as a general component of a DNS host name (a label). -However, this could potentially lead to 123.123.123.123 being a -valid DNS name (rather than an IP address) and thereby creating -an ambiguity. The most authoritative statement on TLD formats that -the author can find is in a (rejected!) erratum to RFC 1123 -submitted by John Klensin, the author of RFC 5321: - -http://www.rfc-editor.org/errata_search.php?rfc=1123&eid=1353 - However, a valid host name can never have the dotted-decimal - form #.#.#.#, since this change does not permit the highest-level - component label to start with a digit even if it is not all-numeric. - -Comments --------- -Comments at the start of the domain are deprecated in the text -Comments at the start of a subdomain are obs-domain -(http://tools.ietf.org/html/rfc5322#section-3.4.1) diff --git a/vendor/egulias/email-validator/documentation/RFC5321BNF.html b/vendor/egulias/email-validator/documentation/RFC5321BNF.html deleted file mode 100644 index 2313f01eb..000000000 --- a/vendor/egulias/email-validator/documentation/RFC5321BNF.html +++ /dev/null @@ -1,89 +0,0 @@ - - - - - -The BNF from RFC 5321 defining parts of a valid SMTP address - - - -
    -   Mailbox        = Local-part "@" ( Domain / address-literal )
    -
    -   Local-part     = Dot-string / Quoted-string
    -                  ; MAY be case-sensitive
    -
    -
    -   Dot-string     = Atom *("."  Atom)
    -
    -   Atom           = 1*atext
    -
    -   Quoted-string  = DQUOTE *QcontentSMTP DQUOTE
    -
    -   QcontentSMTP   = qtextSMTP / quoted-pairSMTP
    -
    -   quoted-pairSMTP  = %d92 %d32-126
    -                    ; i.e., backslash followed by any ASCII
    -                    ; graphic (including itself) or SPace
    -
    -   qtextSMTP      = %d32-33 / %d35-91 / %d93-126
    -                  ; i.e., within a quoted string, any
    -                  ; ASCII graphic or space is permitted
    -                  ; without blackslash-quoting except
    -                  ; double-quote and the backslash itself.
    -
    -   Domain         = sub-domain *("." sub-domain)
    -
    -   sub-domain     = Let-dig [Ldh-str]
    -
    -   Let-dig        = ALPHA / DIGIT
    -
    -   Ldh-str        = *( ALPHA / DIGIT / "-" ) Let-dig
    -
    -   address-literal  = "[" ( IPv4-address-literal /
    -                    IPv6-address-literal /
    -                    General-address-literal ) "]"
    -                    ; See Section 4.1.3
    -
    -   IPv4-address-literal  = Snum 3("."  Snum)
    -
    -   IPv6-address-literal  = "IPv6:" IPv6-addr
    -
    -   General-address-literal  = Standardized-tag ":" 1*dcontent
    -
    -   Standardized-tag  = Ldh-str
    -                     ; Standardized-tag MUST be specified in a
    -                     ; Standards-Track RFC and registered with IANA
    -
    -   dcontent       = %d33-90 / ; Printable US-ASCII
    -                  %d94-126 ; excl. "[", "\", "]"
    -
    -   Snum           = 1*3DIGIT
    -                  ; representing a decimal integer
    -                  ; value in the range 0 through 255
    -
    -   IPv6-addr      = IPv6-full / IPv6-comp / IPv6v4-full / IPv6v4-comp
    -
    -   IPv6-hex       = 1*4HEXDIG
    -
    -   IPv6-full      = IPv6-hex 7(":" IPv6-hex)
    -
    -   IPv6-comp      = [IPv6-hex *5(":" IPv6-hex)] "::"
    -                  [IPv6-hex *5(":" IPv6-hex)]
    -                  ; The "::" represents at least 2 16-bit groups of
    -                  ; zeros.  No more than 6 groups in addition to the
    -                  ; "::" may be present.
    -
    -   IPv6v4-full    = IPv6-hex 5(":" IPv6-hex) ":" IPv4-address-literal
    -
    -   IPv6v4-comp    = [IPv6-hex *3(":" IPv6-hex)] "::"
    -                  [IPv6-hex *3(":" IPv6-hex) ":"]
    -                  IPv4-address-literal
    -                  ; The "::" represents at least 2 16-bit groups of
    -                  ; zeros.  No more than 4 groups in addition to the
    -                  ; "::" and IPv4-address-literal may be present.
    -
    -
    - - - diff --git a/vendor/egulias/email-validator/documentation/RFC5322BNF.html b/vendor/egulias/email-validator/documentation/RFC5322BNF.html deleted file mode 100644 index e2f8fd733..000000000 --- a/vendor/egulias/email-validator/documentation/RFC5322BNF.html +++ /dev/null @@ -1,141 +0,0 @@ - - - - - -The BNF from RFC 5322 defining parts of a valid internet message address - - - -
    -   addr-spec       =   local-part "@" domain
    -
    -   local-part      =   dot-atom / quoted-string / obs-local-part
    -
    -   dot-atom        =   [CFWS] dot-atom-text [CFWS]
    -
    -   CFWS            =   (1*([FWS] comment) [FWS]) / FWS
    -
    -   FWS             =   ([*WSP CRLF] 1*WSP) /  obs-FWS
    -                                          ; Folding white space
    -
    -   WSP             =   SP / HTAB          ; white space
    -
    -   obs-FWS         =   1*([CRLF] WSP)     ; As amended in erratum #1908
    -
    -   ctext           =   %d33-39 /          ; Printable US-ASCII
    -                       %d42-91 /          ;  characters not including
    -                       %d93-126 /         ;  "(", ")", or "\"
    -                       obs-ctext
    -
    -   obs-ctext       =   obs-NO-WS-CTL
    -   ccontent        =   ctext / quoted-pair / comment
    -
    -   comment         =   "(" *([FWS] ccontent) [FWS] ")"
    -
    -   dot-atom-text   =   1*atext *("." 1*atext)
    -
    -   atext           =   ALPHA / DIGIT /    ; Printable US-ASCII
    -                       "!" / "#" /        ;  characters not including
    -                       "$" / "%" /        ;  specials.  Used for atoms.
    -                       "&" / "'" /
    -                       "*" / "+" /
    -                       "-" / "/" /
    -                       "=" / "?" /
    -                       "^" / "_" /
    -                       "`" / "{" /
    -                       "|" / "}" /
    -                       "~"
    -
    -   specials        =   "(" / ")" /        ; Special characters that do
    -                       "<" / ">" /        ;  not appear in atext
    -                       "[" / "]" /
    -                       ":" / ";" /
    -                       "@" / "\" /
    -                       "," / "." /
    -                       DQUOTE
    -
    -   quoted-string   =   [CFWS]
    -                       DQUOTE *([FWS] qcontent) [FWS] DQUOTE
    -                       [CFWS]
    -
    -   qcontent        =   qtext / quoted-pair
    -
    -   qtext           =   %d33 /             ; Printable US-ASCII
    -                       %d35-91 /          ;  characters not including
    -                       %d93-126 /         ;  "\" or the quote character
    -                       obs-qtext
    -
    -   obs-qtext       =   obs-NO-WS-CTL
    -
    -   obs-NO-WS-CTL   =   %d1-8 /            ; US-ASCII control
    -                       %d11 /             ;  characters that do not
    -                       %d12 /             ;  include the carriage
    -                       %d14-31 /          ;  return, line feed, and
    -                       %d127              ;  white space characters
    -
    -   quoted-pair     =   ("\" (VCHAR / WSP)) / obs-qp
    -
    -   VCHAR           =   %x21-7E            ; visible (printing) characters
    -
    -   obs-qp          =   "\" (%d0 / obs-NO-WS-CTL / LF / CR)
    -
    -   obs-local-part  =   word *("." word)
    -
    -   word            =   atom / quoted-string
    -
    -   atom            =   [CFWS] 1*atext [CFWS]
    -
    -   domain          =   dot-atom / domain-literal / obs-domain
    -
    -   domain-literal  =   [CFWS] "[" *([FWS] dtext) [FWS] "]" [CFWS]
    -
    -   dtext           =   %d33-90 /          ; Printable US-ASCII
    -                       %d94-126 /         ;  characters not including
    -                       obs-dtext          ;  "[", "]", or "\"
    -
    -   obs-dtext       =   obs-NO-WS-CTL / quoted-pair
    -
    -   obs-domain      =   atom *("." atom)
    -
    -NB For SMTP mail, the domain-literal is restricted by RFC5321 as follows:
    -
    -   Mailbox        = Local-part "@" ( Domain / address-literal )
    -
    -   address-literal  = "[" ( IPv4-address-literal /
    -                    IPv6-address-literal /
    -                    General-address-literal ) "]"
    -
    -   IPv4-address-literal  = Snum 3("."  Snum)
    -
    -   IPv6-address-literal  = "IPv6:" IPv6-addr
    -
    -   Snum           = 1*3DIGIT
    -                  ; representing a decimal integer
    -                  ; value in the range 0 through 255
    -
    -   IPv6-addr      = IPv6-full / IPv6-comp / IPv6v4-full / IPv6v4-comp
    -
    -   IPv6-hex       = 1*4HEXDIG
    -
    -   IPv6-full      = IPv6-hex 7(":" IPv6-hex)
    -
    -   IPv6-comp      = [IPv6-hex *5(":" IPv6-hex)] "::"
    -                  [IPv6-hex *5(":" IPv6-hex)]
    -                  ; The "::" represents at least 2 16-bit groups of
    -                  ; zeros.  No more than 6 groups in addition to the
    -                  ; "::" may be present.
    -
    -   IPv6v4-full    = IPv6-hex 5(":" IPv6-hex) ":" IPv4-address-literal
    -
    -   IPv6v4-comp    = [IPv6-hex *3(":" IPv6-hex)] "::"
    -                  [IPv6-hex *3(":" IPv6-hex) ":"]
    -                  IPv4-address-literal
    -                  ; The "::" represents at least 2 16-bit groups of
    -                  ; zeros.  No more than 4 groups in addition to the
    -                  ; "::" and IPv4-address-literal may be present.
    -
    -
    - - - diff --git a/vendor/egulias/email-validator/tests/bootstrap.php b/vendor/egulias/email-validator/tests/bootstrap.php deleted file mode 100644 index 676c4b186..000000000 --- a/vendor/egulias/email-validator/tests/bootstrap.php +++ /dev/null @@ -1,8 +0,0 @@ -isValid($testingMail); -} -$b = microtime(true); -echo ($b - $a) . ' seconds with EmailValidator + instantiation' . PHP_EOL; - -$a = microtime(true); -$validator = new EmailValidator(); -for ($i = 0; $i < $iterations; $i++) { - $isValid = $validator->isValid($testingMail); -} -$b = microtime(true); -echo ($b - $a) . ' seconds with EmailValidator once instanced' . PHP_EOL; diff --git a/vendor/egulias/email-validator/tests/egulias/Performance/AgainstOldIsemail.php b/vendor/egulias/email-validator/tests/egulias/Performance/AgainstOldIsemail.php deleted file mode 100644 index 99476c137..000000000 --- a/vendor/egulias/email-validator/tests/egulias/Performance/AgainstOldIsemail.php +++ /dev/null @@ -1,34 +0,0 @@ -isValid($testingMail); -} -$b = microtime(true); -echo ($b - $a) . ' seconds with EmailValidator + instantiation' . PHP_EOL; - -$a = microtime(true); -$validator = new EmailValidator(); -for ($i = 0; $i < $iterations; $i++) { - $isValid = $validator->isValid($testingMail); -} -$b = microtime(true); -echo ($b - $a) . ' seconds with EmailValidator once instanced' . PHP_EOL; diff --git a/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailLexerTest.php b/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailLexerTest.php deleted file mode 100644 index d5389efa5..000000000 --- a/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailLexerTest.php +++ /dev/null @@ -1,161 +0,0 @@ -assertInstanceOf('Doctrine\Common\Lexer\AbstractLexer', $lexer); - } - - /** - * @dataProvider getTokens - * - */ - public function testLexerTokens($str, $token) - { - $lexer = new EmailLexer(); - $lexer->setInput($str); - $lexer->moveNext(); - $lexer->moveNext(); - $this->assertEquals($token, $lexer->token['type']); - } - - public function testLexerParsesMultipleSpaces() - { - $lexer = new EmailLexer(); - $lexer->setInput(' '); - $lexer->moveNext(); - $lexer->moveNext(); - $this->assertEquals(EmailLexer::S_SP, $lexer->token['type']); - $lexer->moveNext(); - $this->assertEquals(EmailLexer::S_SP, $lexer->token['type']); - } - - /** - * @dataProvider invalidUTF8CharsProvider - */ - public function testLexerParsesInvalidUTF8($char) - { - $lexer = new EmailLexer(); - $lexer->setInput($char); - $lexer->moveNext(); - $lexer->moveNext(); - - $this->assertEquals(EmailLexer::INVALID, $lexer->token['type']); - } - - public function invalidUTF8CharsProvider() - { - $chars = array(); - for ($i = 0; $i < 0x100; ++$i) { - $c = $this->utf8Chr($i); - if (preg_match('/(?=\p{Cc})(?=[^\t\n\n\r])/u', $c) && !preg_match('/\x{0000}/u', $c)) { - $chars[] = array($c); - } - } - - return $chars; - } - - protected function utf8Chr($code_point) - { - - if ($code_point < 0 || 0x10FFFF < $code_point || (0xD800 <= $code_point && $code_point <= 0xDFFF)) { - return ''; - } - - if ($code_point < 0x80) { - $hex[0] = $code_point; - $ret = chr($hex[0]); - } elseif ($code_point < 0x800) { - $hex[0] = 0x1C0 | $code_point >> 6; - $hex[1] = 0x80 | $code_point & 0x3F; - $ret = chr($hex[0]).chr($hex[1]); - } elseif ($code_point < 0x10000) { - $hex[0] = 0xE0 | $code_point >> 12; - $hex[1] = 0x80 | $code_point >> 6 & 0x3F; - $hex[2] = 0x80 | $code_point & 0x3F; - $ret = chr($hex[0]).chr($hex[1]).chr($hex[2]); - } else { - $hex[0] = 0xF0 | $code_point >> 18; - $hex[1] = 0x80 | $code_point >> 12 & 0x3F; - $hex[2] = 0x80 | $code_point >> 6 & 0x3F; - $hex[3] = 0x80 | $code_point & 0x3F; - $ret = chr($hex[0]).chr($hex[1]).chr($hex[2]).chr($hex[3]); - } - - return $ret; - } - - public function testLexerForTab() - { - $lexer = new EmailLexer(); - $lexer->setInput("foo\tbar"); - $lexer->moveNext(); - $lexer->skipUntil(EmailLexer::S_HTAB); - $lexer->moveNext(); - $this->assertEquals(EmailLexer::S_HTAB, $lexer->token['type']); - } - - public function testLexerForUTF8() - { - $lexer = new EmailLexer(); - $lexer->setInput("áÇ@bar.com"); - $lexer->moveNext(); - $lexer->moveNext(); - $this->assertEquals(EmailLexer::GENERIC, $lexer->token['type']); - $lexer->moveNext(); - $this->assertEquals(EmailLexer::GENERIC, $lexer->token['type']); - } - - public function testLexerSearchToken() - { - $lexer = new EmailLexer(); - $lexer->setInput("foo\tbar"); - $lexer->moveNext(); - $this->assertTrue($lexer->find(EmailLexer::S_HTAB)); - } - - public function getTokens() - { - return array( - array("foo", EmailLexer::GENERIC), - array("\r", EmailLexer::S_CR), - array("\t", EmailLexer::S_HTAB), - array("\r\n", EmailLexer::CRLF), - array("\n", EmailLexer::S_LF), - array(" ", EmailLexer::S_SP), - array("@", EmailLexer::S_AT), - array("IPv6", EmailLexer::S_IPV6TAG), - array("::", EmailLexer::S_DOUBLECOLON), - array(":", EmailLexer::S_COLON), - array(".", EmailLexer::S_DOT), - array("\"", EmailLexer::S_DQUOTE), - array("-", EmailLexer::S_HYPHEN), - array("\\", EmailLexer::S_BACKSLASH), - array("/", EmailLexer::S_SLASH), - array("(", EmailLexer::S_OPENPARENTHESIS), - array(")", EmailLexer::S_CLOSEPARENTHESIS), - array('<', EmailLexer::S_LOWERTHAN), - array('>', EmailLexer::S_GREATERTHAN), - array('[', EmailLexer::S_OPENBRACKET), - array(']', EmailLexer::S_CLOSEBRACKET), - array(';', EmailLexer::S_SEMICOLON), - array(',', EmailLexer::S_COMMA), - array('<', EmailLexer::S_LOWERTHAN), - array('>', EmailLexer::S_GREATERTHAN), - array('{', EmailLexer::S_OPENQBRACKET), - array('}', EmailLexer::S_CLOSEQBRACKET), - array('', EmailLexer::S_EMPTY), - array(chr(31), EmailLexer::INVALID), - array(chr(226), EmailLexer::GENERIC), - array(chr(0), EmailLexer::C_NUL) - ); - } -} diff --git a/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailValidatorTest.php b/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailValidatorTest.php deleted file mode 100644 index 1491df75d..000000000 --- a/vendor/egulias/email-validator/tests/egulias/Tests/EmailValidator/EmailValidatorTest.php +++ /dev/null @@ -1,375 +0,0 @@ -validator = new EmailValidator(); - } - - protected function tearDown() - { - $this->validator = null; - } - - /** - * @dataProvider getValidEmails - */ - public function testValidEmails($email) - { - $this->assertTrue($this->validator->isValid($email)); - } - - public function testInvalidUTF8Email() - { - $validator = new EmailValidator; - $email = "\x80\x81\x82@\x83\x84\x85.\x86\x87\x88"; - - $this->assertFalse($validator->isValid($email)); - } - - public function getValidEmails() - { - return array( - array('â@iana.org'), - array('fabien@symfony.com'), - array('example@example.co.uk'), - array('fabien_potencier@example.fr'), - array('example@localhost'), - array('fab\'ien@symfony.com'), - array('fab\ ien@symfony.com'), - array('example((example))@fakedfake.co.uk'), - array('example@faked(fake).co.uk'), - array('fabien+@symfony.com'), - array('инфо@письмо.рф'), - array('"username"@example.com'), - array('"user,name"@example.com'), - array('"user name"@example.com'), - array('"user@name"@example.com'), - array('"\a"@iana.org'), - array('"test\ test"@iana.org'), - array('""@iana.org'), - array('"\""@iana.org'), - array('müller@möller.de'), - array('test@email*'), - array('test@email!'), - array('test@email&'), - array('test@email^'), - array('test@email%'), - array('test@email$'), - ); - } - - /** - * @dataProvider getInvalidEmails - */ - public function testInvalidEmails($email) - { - $this->assertFalse($this->validator->isValid($email)); - } - - public function getInvalidEmails() - { - return array( - array('test@example.com test'), - array('user name@example.com'), - array('user name@example.com'), - array('example.@example.co.uk'), - array('example@example@example.co.uk'), - array('(test_exampel@example.fr)'), - array('example(example)example@example.co.uk'), - array('.example@localhost'), - array('ex\ample@localhost'), - array('example@local\host'), - array('example@localhost.'), - array('user name@example.com'), - array('username@ example . com'), - array('example@(fake).com'), - array('example@(fake.com'), - array('username@example,com'), - array('usern,ame@example.com'), - array('user[na]me@example.com'), - array('"""@iana.org'), - array('"\"@iana.org'), - array('"test"test@iana.org'), - array('"test""test"@iana.org'), - array('"test"."test"@iana.org'), - array('"test".test@iana.org'), - array('"test"' . chr(0) . '@iana.org'), - array('"test\"@iana.org'), - array(chr(226) . '@iana.org'), - array('test@' . chr(226) . '.org'), - array('\r\ntest@iana.org'), - array('\r\n test@iana.org'), - array('\r\n \r\ntest@iana.org'), - array('\r\n \r\ntest@iana.org'), - array('\r\n \r\n test@iana.org'), - array('test@iana.org \r\n'), - array('test@iana.org \r\n '), - array('test@iana.org \r\n \r\n'), - array('test@iana.org \r\n\r\n'), - array('test@iana.org \r\n\r\n '), - array('test@iana/icann.org'), - array('test@foo;bar.com'), - array('test;123@foobar.com'), - array('test@example..com'), - array('email.email@email."'), - array('test@email>'), - array('test@email<'), - array('test@email{'), - ); - } - - /** - * @dataProvider getInvalidEmailsWithErrors - */ - public function testInvalidEmailsWithErrorsCheck($errors, $email) - { - $this->assertFalse($this->validator->isValid($email)); - - $this->assertEquals($errors, $this->validator->getError()); - } - - public function getInvalidEmailsWithErrors() - { - return array( - array(EmailValidator::ERR_NOLOCALPART, '@example.co.uk'), - array(EmailValidator::ERR_NODOMAIN, 'example@'), - array(EmailValidator::ERR_DOMAINHYPHENEND, 'example@example-.co.uk'), - array(EmailValidator::ERR_DOMAINHYPHENEND, 'example@example-'), - array(EmailValidator::ERR_CONSECUTIVEATS, 'example@@example.co.uk'), - array(EmailValidator::ERR_CONSECUTIVEDOTS, 'example..example@example.co.uk'), - array(EmailValidator::ERR_CONSECUTIVEDOTS, 'example@example..co.uk'), - array(EmailValidator::ERR_EXPECTING_ATEXT, '@example.fr'), - array(EmailValidator::ERR_DOT_START, '.example@localhost'), - array(EmailValidator::ERR_DOT_START, 'example@.localhost'), - array(EmailValidator::ERR_DOT_END, 'example@localhost.'), - array(EmailValidator::ERR_DOT_END, 'example.@example.co.uk'), - array(EmailValidator::ERR_UNCLOSEDCOMMENT, '(example@localhost'), - array(EmailValidator::ERR_UNCLOSEDQUOTEDSTR, '"example@localhost'), - array(EmailValidator::ERR_EXPECTING_ATEXT, 'exa"mple@localhost'), - //This was the original. But atext is not allowed after \n - //array(EmailValidator::ERR_EXPECTING_ATEXT, "exampl\ne@example.co.uk"), - array(EmailValidator::ERR_ATEXT_AFTER_CFWS, "exampl\ne@example.co.uk"), - array(EmailValidator::ERR_EXPECTING_DTEXT, "example@[[]"), - array(EmailValidator::ERR_ATEXT_AFTER_CFWS, "exampl\te@example.co.uk"), - array(EmailValidator::ERR_CR_NO_LF, "example@exa\rmple.co.uk"), - array(EmailValidator::ERR_CR_NO_LF, "example@[\r]"), - array(EmailValidator::ERR_CR_NO_LF, "exam\rple@example.co.uk"), - ); - } - - /** - * @dataProvider getInvalidEmailsWithWarnings - */ - public function testValidEmailsWithWarningsCheck($warnings, $email) - { - $this->assertTrue($this->validator->isValid($email, true)); - - $this->assertEquals($warnings, $this->validator->getWarnings()); - } - - /** - * @dataProvider getInvalidEmailsWithWarnings - */ - public function testInvalidEmailsWithDnsCheckAndStrictMode($warnings, $email) - { - $this->assertFalse($this->validator->isValid($email, true, true)); - - $this->assertEquals($warnings, $this->validator->getWarnings()); - } - - public function getInvalidEmailsWithWarnings() - { - return array( - array( - array( - EmailValidator::DEPREC_CFWS_NEAR_AT, - EmailValidator::DNSWARN_NO_RECORD - ), - 'example @example.co.uk' - ), - array( - array( - EmailValidator::DEPREC_CFWS_NEAR_AT, - EmailValidator::DNSWARN_NO_RECORD - ), - 'example@ example.co.uk' - ), - array( - array( - EmailValidator::CFWS_COMMENT, - EmailValidator::DNSWARN_NO_RECORD - ), - 'example@example(examplecomment).co.uk' - ), - array( - array( - EmailValidator::CFWS_COMMENT, - EmailValidator::DEPREC_CFWS_NEAR_AT, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example(examplecomment)@example.co.uk' - ), - array( - array( - EmailValidator::RFC5321_QUOTEDSTRING, - EmailValidator::CFWS_FWS, - EmailValidator::DNSWARN_NO_RECORD, - ), - "\"\t\"@example.co.uk" - ), - array( - array( - EmailValidator::RFC5321_QUOTEDSTRING, - EmailValidator::CFWS_FWS, - EmailValidator::DNSWARN_NO_RECORD - ), - "\"\r\"@example.co.uk" - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[127.0.0.1]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370:7334]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5321_IPV6DEPRECATED, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370::]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5322_IPV6_MAXGRPS, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370:7334::]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5322_IPV6_2X2XCOLON, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:1::1::1]' - ), - array( - array( - EmailValidator::RFC5322_DOMLIT_OBSDTEXT, - EmailValidator::RFC5322_DOMAINLITERAL, - EmailValidator::DNSWARN_NO_RECORD, - ), - "example@[\n]" - ), - array( - array( - EmailValidator::RFC5322_DOMAINLITERAL, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[::1]' - ), - array( - array( - EmailValidator::RFC5322_DOMAINLITERAL, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[::123.45.67.178]' - ), - array( - array( - EmailValidator::RFC5322_IPV6_COLONSTRT, - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5322_IPV6_GRPCOUNT, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6::2001:0db8:85a3:0000:0000:8a2e:0370:7334]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5322_IPV6_BADCHAR, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:z001:0db8:85a3:0000:0000:8a2e:0370:7334]' - ), - array( - array( - EmailValidator::RFC5321_ADDRESSLITERAL, - EmailValidator::RFC5322_IPV6_COLONEND, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370:]' - ), - array( - array( - EmailValidator::RFC5321_QUOTEDSTRING, - EmailValidator::DNSWARN_NO_RECORD - ), - '"example"@example.co.uk' - ), - array( - array( - EmailValidator::RFC5322_LOCAL_TOOLONG, - EmailValidator::DNSWARN_NO_RECORD - ), - 'too_long_localpart_too_long_localpart_too_long_localpart_too_long_localpart@example.co.uk' - ), - array( - array( - EmailValidator::RFC5322_LABEL_TOOLONG, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@toolonglocalparttoolonglocalparttoolonglocalparttoolonglocalpart.co.uk' - ), - array( - array( - EmailValidator::RFC5322_DOMAIN_TOOLONG, - EmailValidator::RFC5322_TOOLONG, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@toolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocal'. - 'parttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalpart'. - 'toolonglocalparttoolonglocalparttoolonglocalparttoolonglocalpart' - ), - array( - array( - EmailValidator::RFC5322_DOMAIN_TOOLONG, - EmailValidator::RFC5322_TOOLONG, - EmailValidator::DNSWARN_NO_RECORD, - ), - 'example@toolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocal'. - 'parttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalparttoolonglocalpart'. - 'toolonglocalparttoolonglocalparttoolonglocalparttoolonglocalpar' - ), - array( - array( - EmailValidator::DNSWARN_NO_RECORD, - ), - 'test@test' - ), - ); - } - - public function testInvalidEmailsWithStrict() - { - $this->assertFalse($this->validator->isValid('"test"@test', false, true)); - } -} diff --git a/vendor/fabpot/goutte/Goutte/Tests/ClientTest.php b/vendor/fabpot/goutte/Goutte/Tests/ClientTest.php deleted file mode 100644 index 8c2b0a512..000000000 --- a/vendor/fabpot/goutte/Goutte/Tests/ClientTest.php +++ /dev/null @@ -1,375 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Goutte\Tests; - -use Goutte\Client; -use GuzzleHttp\Client as GuzzleClient; -use GuzzleHttp\Exception\RequestException; -use GuzzleHttp\Handler\MockHandler; -use GuzzleHttp\HandlerStack; -use GuzzleHttp\Psr7\Response as GuzzleResponse; -use GuzzleHttp\Middleware; -use Symfony\Component\BrowserKit\Cookie; - -/** - * Goutte Client Test. - * - * @author Michael Dowling - * @author Charles Sarrazin - */ -class ClientTest extends \PHPUnit_Framework_TestCase -{ - protected $history; - /** @var MockHandler */ - protected $mock; - - protected function getGuzzle(array $responses = []) - { - if (empty($responses)) { - $responses = [new GuzzleResponse(200, [], '

    Hi

    ')]; - } - $this->mock = new MockHandler($responses); - $handlerStack = HandlerStack::create($this->mock); - $this->history = []; - $handlerStack->push(Middleware::history($this->history)); - $guzzle = new GuzzleClient(array('redirect.disable' => true, 'base_uri' => '', 'handler' => $handlerStack)); - - return $guzzle; - } - - public function testCreatesDefaultClient() - { - $client = new Client(); - $this->assertInstanceOf('GuzzleHttp\\ClientInterface', $client->getClient()); - } - - public function testUsesCustomClient() - { - $guzzle = new GuzzleClient(); - $client = new Client(); - $this->assertSame($client, $client->setClient($guzzle)); - $this->assertSame($guzzle, $client->getClient()); - } - - public function testUsesCustomHeaders() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->setHeader('X-Test', 'test'); - $client->request('GET', 'http://www.example.com/'); - $this->assertEquals('test', end($this->history)['request']->getHeaderLine('X-Test')); - } - - public function testCustomUserAgent() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->setHeader('User-Agent', 'foo'); - $client->request('GET', 'http://www.example.com/'); - $this->assertEquals('Symfony2 BrowserKit, foo', end($this->history)['request']->getHeaderLine('User-Agent')); - } - - public function testUsesAuth() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->setAuth('me', '**'); - $client->request('GET', 'http://www.example.com/'); - $request = end($this->history)['request']; - $this->assertEquals('Basic bWU6Kio=', $request->getHeaderLine('Authorization')); - } - - public function testResetsAuth() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->setAuth('me', '**'); - $client->resetAuth(); - $client->request('GET', 'http://www.example.com/'); - $request = end($this->history)['request']; - $this->assertEquals('', $request->getHeaderLine('authorization')); - } - - public function testUsesCookies() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->getCookieJar()->set(new Cookie('test', '123')); - $client->request('GET', 'http://www.example.com/'); - $request = end($this->history)['request']; - $this->assertEquals('test=123', $request->getHeaderLine('Cookie')); - } - - public function testUsesCookiesWithCustomPort() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $client->getCookieJar()->set(new Cookie('test', '123')); - $client->request('GET', 'http://www.example.com:8000/'); - $request = end($this->history)['request']; - $this->assertEquals('test=123', $request->getHeaderLine('Cookie')); - } - - public function testUsesPostFiles() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => array( - 'name' => 'test.txt', - 'tmp_name' => __DIR__.'/fixtures.txt', - ), - ); - - $client->request('POST', 'http://www.example.com/', array(), $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"test\"; filename=\"test.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents() - ); - } - - public function testUsesPostNamedFiles() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => __DIR__.'/fixtures.txt', - ); - - $client->request('POST', 'http://www.example.com/', array(), $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"test\"; filename=\"fixtures.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents() - ); - } - - public function testUsesPostFilesNestedFields() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'form' => array( - 'test' => array( - 'name' => 'test.txt', - 'tmp_name' => __DIR__.'/fixtures.txt', - ), - ), - ); - - $client->request('POST', 'http://www.example.com/', array(), $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"form[test]\"; filename=\"test.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents() - ); - } - - public function testPostFormWithFiles() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => __DIR__.'/fixtures.txt', - ); - $params = array( - 'foo' => 'bar', - ); - - $client->request('POST', 'http://www.example.com/', $params, $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"foo\"\r\nContent-Length: 3\r\n" - ."\r\nbar\r\n" - ."--$boundary\r\nContent-Disposition: form-data; name=\"test\"; filename=\"fixtures.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents()); - } - - public function testPostEmbeddedFormWithFiles() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => __DIR__.'/fixtures.txt', - ); - $params = array( - 'foo' => array( - 'bar' => 'baz', - ), - ); - - $client->request('POST', 'http://www.example.com/', $params, $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"foo[bar]\"\r\nContent-Length: 3\r\n" - ."\r\nbaz\r\n" - ."--$boundary\r\nContent-Disposition: form-data; name=\"test\"; filename=\"fixtures.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents()); - } - - public function testUsesPostFilesOnClientSide() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => __DIR__.'/fixtures.txt', - ); - - $client->request('POST', 'http://www.example.com/', array(), $files); - $request = end($this->history)['request']; - - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - $this->assertEquals( - "--$boundary\r\nContent-Disposition: form-data; name=\"test\"; filename=\"fixtures.txt\"\r\nContent-Length: 4\r\n" - ."Content-Type: text/plain\r\n\r\nfoo\n\r\n--$boundary--\r\n", - $stream->getContents() - ); - } - - public function testUsesPostFilesUploadError() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $files = array( - 'test' => array( - 'name' => '', - 'type' => '', - 'tmp_name' => '', - 'error' => 4, - 'size' => 0, - ), - ); - - $client->request('POST', 'http://www.example.com/', array(), $files); - $request = end($this->history)['request']; - $stream = $request->getBody(); - $boundary = $stream->getBoundary(); - - $this->assertEquals("--$boundary--\r\n", $stream->getContents()); - } - - public function testCreatesResponse() - { - $guzzle = $this->getGuzzle(); - $client = new Client(); - $client->setClient($guzzle); - $crawler = $client->request('GET', 'http://www.example.com/'); - $this->assertEquals('Hi', $crawler->filter('p')->text()); - } - - public function testHandlesRedirectsCorrectly() - { - $guzzle = $this->getGuzzle([ - new GuzzleResponse(301, array( - 'Location' => 'http://www.example.com/', - )), - new GuzzleResponse(200, [], '

    Test

    '), - ]); - - $client = new Client(); - $client->setClient($guzzle); - - $crawler = $client->request('GET', 'http://www.example.com/'); - $this->assertEquals('Test', $crawler->filter('p')->text()); - - // Ensure that two requests were sent - $this->assertEquals(2, count($this->history)); - } - - public function testConvertsGuzzleHeadersToArrays() - { - $guzzle = $this->getGuzzle([ - new GuzzleResponse(200, array( - 'Date' => 'Tue, 04 Jun 2013 13:22:41 GMT', - )), - ]); - - $client = new Client(); - $client->setClient($guzzle); - $client->request('GET', 'http://www.example.com/'); - $response = $client->getResponse(); - $headers = $response->getHeaders(); - - $this->assertInternalType('array', array_shift($headers), 'Header not converted from Guzzle\Http\Message\Header to array'); - } - - public function testNullResponseException() - { - $this->setExpectedException('GuzzleHttp\Exception\RequestException'); - $guzzle = $this->getGuzzle([ - new RequestException('', $this->getMock('Psr\Http\Message\RequestInterface')), - ]); - $client = new Client(); - $client->setClient($guzzle); - $client->request('GET', 'http://www.example.com/'); - $client->getResponse(); - } - - public function testHttps() - { - $guzzle = $this->getGuzzle([ - new GuzzleResponse(200, [], '

    Test

    '), - ]); - - $client = new Client(); - $client->setClient($guzzle); - $crawler = $client->request('GET', 'https://www.example.com/'); - $this->assertEquals('Test', $crawler->filter('p')->text()); - } - - public function testCustomUserAgentConstructor() - { - $guzzle = $this->getGuzzle(); - $client = new Client([ - 'HTTP_HOST' => '1.2.3.4', - 'HTTP_USER_AGENT' => 'SomeHost', - ]); - $client->setClient($guzzle); - $client->request('GET', 'http://www.example.com/'); - $this->assertEquals('SomeHost', end($this->history)['request']->getHeaderLine('User-Agent')); - } -} diff --git a/vendor/fabpot/goutte/Goutte/Tests/fixtures.txt b/vendor/fabpot/goutte/Goutte/Tests/fixtures.txt deleted file mode 100644 index 257cc5642..000000000 --- a/vendor/fabpot/goutte/Goutte/Tests/fixtures.txt +++ /dev/null @@ -1 +0,0 @@ -foo diff --git a/vendor/guzzlehttp/promises/tests/AggregateExceptionTest.php b/vendor/guzzlehttp/promises/tests/AggregateExceptionTest.php deleted file mode 100644 index eaa77039a..000000000 --- a/vendor/guzzlehttp/promises/tests/AggregateExceptionTest.php +++ /dev/null @@ -1,14 +0,0 @@ -assertContains('foo', $e->getMessage()); - $this->assertEquals(['baz', 'bar'], $e->getReason()); - } -} diff --git a/vendor/guzzlehttp/promises/tests/EachPromiseTest.php b/vendor/guzzlehttp/promises/tests/EachPromiseTest.php deleted file mode 100644 index b913b3a71..000000000 --- a/vendor/guzzlehttp/promises/tests/EachPromiseTest.php +++ /dev/null @@ -1,288 +0,0 @@ - 100]); - $this->assertSame($each->promise(), $each->promise()); - } - - public function testInvokesAllPromises() - { - $promises = [new Promise(), new Promise(), new Promise()]; - $called = []; - $each = new EachPromise($promises, [ - 'fulfilled' => function ($value) use (&$called) { - $called[] = $value; - } - ]); - $p = $each->promise(); - $promises[0]->resolve('a'); - $promises[1]->resolve('c'); - $promises[2]->resolve('b'); - P\queue()->run(); - $this->assertEquals(['a', 'c', 'b'], $called); - $this->assertEquals(PromiseInterface::FULFILLED, $p->getState()); - } - - public function testIsWaitable() - { - $a = new Promise(function () use (&$a) { $a->resolve('a'); }); - $b = new Promise(function () use (&$b) { $b->resolve('b'); }); - $called = []; - $each = new EachPromise([$a, $b], [ - 'fulfilled' => function ($value) use (&$called) { $called[] = $value; } - ]); - $p = $each->promise(); - $this->assertNull($p->wait()); - $this->assertEquals(PromiseInterface::FULFILLED, $p->getState()); - $this->assertEquals(['a', 'b'], $called); - } - - public function testCanResolveBeforeConsumingAll() - { - $called = 0; - $a = new Promise(function () use (&$a) { $a->resolve('a'); }); - $b = new Promise(function () { $this->fail(); }); - $each = new EachPromise([$a, $b], [ - 'fulfilled' => function ($value, $idx, Promise $aggregate) use (&$called) { - $this->assertSame($idx, 0); - $this->assertEquals('a', $value); - $aggregate->resolve(null); - $called++; - }, - 'rejected' => function (\Exception $reason) { - $this->fail($reason->getMessage()); - } - ]); - $p = $each->promise(); - $p->wait(); - $this->assertNull($p->wait()); - $this->assertEquals(1, $called); - $this->assertEquals(PromiseInterface::FULFILLED, $a->getState()); - $this->assertEquals(PromiseInterface::PENDING, $b->getState()); - // Resolving $b has no effect on the aggregate promise. - $b->resolve('foo'); - $this->assertEquals(1, $called); - } - - public function testLimitsPendingPromises() - { - $pending = [new Promise(), new Promise(), new Promise(), new Promise()]; - $promises = new \ArrayIterator($pending); - $each = new EachPromise($promises, ['concurrency' => 2]); - $p = $each->promise(); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - $pending[0]->resolve('a'); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - $this->assertTrue($promises->valid()); - $pending[1]->resolve('b'); - P\queue()->run(); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - $this->assertTrue($promises->valid()); - $promises[2]->resolve('c'); - P\queue()->run(); - $this->assertCount(1, $this->readAttribute($each, 'pending')); - $this->assertEquals(PromiseInterface::PENDING, $p->getState()); - $promises[3]->resolve('d'); - P\queue()->run(); - $this->assertNull($this->readAttribute($each, 'pending')); - $this->assertEquals(PromiseInterface::FULFILLED, $p->getState()); - $this->assertFalse($promises->valid()); - } - - public function testDynamicallyLimitsPendingPromises() - { - $calls = []; - $pendingFn = function ($count) use (&$calls) { - $calls[] = $count; - return 2; - }; - $pending = [new Promise(), new Promise(), new Promise(), new Promise()]; - $promises = new \ArrayIterator($pending); - $each = new EachPromise($promises, ['concurrency' => $pendingFn]); - $p = $each->promise(); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - $pending[0]->resolve('a'); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - $this->assertTrue($promises->valid()); - $pending[1]->resolve('b'); - $this->assertCount(2, $this->readAttribute($each, 'pending')); - P\queue()->run(); - $this->assertTrue($promises->valid()); - $promises[2]->resolve('c'); - P\queue()->run(); - $this->assertCount(1, $this->readAttribute($each, 'pending')); - $this->assertEquals(PromiseInterface::PENDING, $p->getState()); - $promises[3]->resolve('d'); - P\queue()->run(); - $this->assertNull($this->readAttribute($each, 'pending')); - $this->assertEquals(PromiseInterface::FULFILLED, $p->getState()); - $this->assertEquals([0, 1, 1, 1], $calls); - $this->assertFalse($promises->valid()); - } - - public function testClearsReferencesWhenResolved() - { - $called = false; - $a = new Promise(function () use (&$a, &$called) { - $a->resolve('a'); - $called = true; - }); - $each = new EachPromise([$a], [ - 'concurrency' => function () { return 1; }, - 'fulfilled' => function () {}, - 'rejected' => function () {} - ]); - $each->promise()->wait(); - $this->assertNull($this->readAttribute($each, 'onFulfilled')); - $this->assertNull($this->readAttribute($each, 'onRejected')); - $this->assertNull($this->readAttribute($each, 'iterable')); - $this->assertNull($this->readAttribute($each, 'pending')); - $this->assertNull($this->readAttribute($each, 'concurrency')); - $this->assertTrue($called); - } - - public function testCanBeCancelled() - { - $this->markTestIncomplete(); - } - - public function testDoesNotBlowStackWithFulfilledPromises() - { - $pending = []; - for ($i = 0; $i < 100; $i++) { - $pending[] = new FulfilledPromise($i); - } - $values = []; - $each = new EachPromise($pending, [ - 'fulfilled' => function ($value) use (&$values) { - $values[] = $value; - } - ]); - $called = false; - $each->promise()->then(function () use (&$called) { - $called = true; - }); - $this->assertFalse($called); - P\queue()->run(); - $this->assertTrue($called); - $this->assertEquals(range(0, 99), $values); - } - - public function testDoesNotBlowStackWithRejectedPromises() - { - $pending = []; - for ($i = 0; $i < 100; $i++) { - $pending[] = new RejectedPromise($i); - } - $values = []; - $each = new EachPromise($pending, [ - 'rejected' => function ($value) use (&$values) { - $values[] = $value; - } - ]); - $called = false; - $each->promise()->then( - function () use (&$called) { $called = true; }, - function () { $this->fail('Should not have rejected.'); } - ); - $this->assertFalse($called); - P\queue()->run(); - $this->assertTrue($called); - $this->assertEquals(range(0, 99), $values); - } - - public function testReturnsPromiseForWhatever() - { - $called = []; - $arr = ['a', 'b']; - $each = new EachPromise($arr, [ - 'fulfilled' => function ($v) use (&$called) { $called[] = $v; } - ]); - $p = $each->promise(); - $this->assertNull($p->wait()); - $this->assertEquals(['a', 'b'], $called); - } - - public function testRejectsAggregateWhenNextThrows() - { - $iter = function () { - yield 'a'; - throw new \Exception('Failure'); - }; - $each = new EachPromise($iter()); - $p = $each->promise(); - $e = null; - $received = null; - $p->then(null, function ($reason) use (&$e) { $e = $reason; }); - P\queue()->run(); - $this->assertInstanceOf('Exception', $e); - $this->assertEquals('Failure', $e->getMessage()); - } - - public function testDoesNotCallNextOnIteratorUntilNeededWhenWaiting() - { - $results = []; - $values = [10]; - $remaining = 9; - $iter = function () use (&$values) { - while ($value = array_pop($values)) { - yield $value; - } - }; - $each = new EachPromise($iter(), [ - 'concurrency' => 1, - 'fulfilled' => function ($r) use (&$results, &$values, &$remaining) { - $results[] = $r; - if ($remaining > 0) { - $values[] = $remaining--; - } - } - ]); - $each->promise()->wait(); - $this->assertEquals(range(10, 1), $results); - } - - public function testDoesNotCallNextOnIteratorUntilNeededWhenAsync() - { - $firstPromise = new Promise(); - $pending = [$firstPromise]; - $values = [$firstPromise]; - $results = []; - $remaining = 9; - $iter = function () use (&$values) { - while ($value = array_pop($values)) { - yield $value; - } - }; - $each = new EachPromise($iter(), [ - 'concurrency' => 1, - 'fulfilled' => function ($r) use (&$results, &$values, &$remaining, &$pending) { - $results[] = $r; - if ($remaining-- > 0) { - $pending[] = $values[] = new Promise(); - } - } - ]); - $i = 0; - $each->promise(); - while ($promise = array_pop($pending)) { - $promise->resolve($i++); - P\queue()->run(); - } - $this->assertEquals(range(0, 9), $results); - } -} diff --git a/vendor/guzzlehttp/promises/tests/FulfilledPromiseTest.php b/vendor/guzzlehttp/promises/tests/FulfilledPromiseTest.php deleted file mode 100644 index 554c15070..000000000 --- a/vendor/guzzlehttp/promises/tests/FulfilledPromiseTest.php +++ /dev/null @@ -1,108 +0,0 @@ -assertEquals('fulfilled', $p->getState()); - $this->assertEquals('foo', $p->wait(true)); - } - - public function testCannotCancel() - { - $p = new FulfilledPromise('foo'); - $this->assertEquals('fulfilled', $p->getState()); - $p->cancel(); - $this->assertEquals('foo', $p->wait()); - } - - /** - * @expectedException \LogicException - * @exepctedExceptionMessage Cannot resolve a fulfilled promise - */ - public function testCannotResolve() - { - $p = new FulfilledPromise('foo'); - $p->resolve('bar'); - } - - /** - * @expectedException \LogicException - * @exepctedExceptionMessage Cannot reject a fulfilled promise - */ - public function testCannotReject() - { - $p = new FulfilledPromise('foo'); - $p->reject('bar'); - } - - public function testCanResolveWithSameValue() - { - $p = new FulfilledPromise('foo'); - $p->resolve('foo'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testCannotResolveWithPromise() - { - new FulfilledPromise(new Promise()); - } - - public function testReturnsSelfWhenNoOnFulfilled() - { - $p = new FulfilledPromise('a'); - $this->assertSame($p, $p->then()); - } - - public function testAsynchronouslyInvokesOnFulfilled() - { - $p = new FulfilledPromise('a'); - $r = null; - $f = function ($d) use (&$r) { $r = $d; }; - $p2 = $p->then($f); - $this->assertNotSame($p, $p2); - $this->assertNull($r); - \GuzzleHttp\Promise\queue()->run(); - $this->assertEquals('a', $r); - } - - public function testReturnsNewRejectedWhenOnFulfilledFails() - { - $p = new FulfilledPromise('a'); - $f = function () { throw new \Exception('b'); }; - $p2 = $p->then($f); - $this->assertNotSame($p, $p2); - try { - $p2->wait(); - $this->fail(); - } catch (\Exception $e) { - $this->assertEquals('b', $e->getMessage()); - } - } - - public function testOtherwiseIsSugarForRejections() - { - $c = null; - $p = new FulfilledPromise('foo'); - $p->otherwise(function ($v) use (&$c) { $c = $v; }); - $this->assertNull($c); - } - - public function testDoesNotTryToFulfillTwiceDuringTrampoline() - { - $fp = new FulfilledPromise('a'); - $t1 = $fp->then(function ($v) { return $v . ' b'; }); - $t1->resolve('why!'); - $this->assertEquals('why!', $t1->wait()); - } -} diff --git a/vendor/guzzlehttp/promises/tests/NotPromiseInstance.php b/vendor/guzzlehttp/promises/tests/NotPromiseInstance.php deleted file mode 100644 index 6288aa88a..000000000 --- a/vendor/guzzlehttp/promises/tests/NotPromiseInstance.php +++ /dev/null @@ -1,50 +0,0 @@ -nextPromise = new Promise(); - } - - public function then(callable $res = null, callable $rej = null) - { - return $this->nextPromise->then($res, $rej); - } - - public function otherwise(callable $onRejected) - { - return $this->then($onRejected); - } - - public function resolve($value) - { - $this->nextPromise->resolve($value); - } - - public function reject($reason) - { - $this->nextPromise->reject($reason); - } - - public function wait($unwrap = true, $defaultResolution = null) - { - - } - - public function cancel() - { - - } - - public function getState() - { - return $this->nextPromise->getState(); - } -} diff --git a/vendor/guzzlehttp/promises/tests/PromiseTest.php b/vendor/guzzlehttp/promises/tests/PromiseTest.php deleted file mode 100644 index 946c62724..000000000 --- a/vendor/guzzlehttp/promises/tests/PromiseTest.php +++ /dev/null @@ -1,579 +0,0 @@ -resolve('foo'); - $p->resolve('bar'); - $this->assertEquals('foo', $p->wait()); - } - - public function testCanResolveWithSameValue() - { - $p = new Promise(); - $p->resolve('foo'); - $p->resolve('foo'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot change a fulfilled promise to rejected - */ - public function testCannotRejectNonPendingPromise() - { - $p = new Promise(); - $p->resolve('foo'); - $p->reject('bar'); - $this->assertEquals('foo', $p->wait()); - } - - public function testCanRejectWithSameValue() - { - $p = new Promise(); - $p->reject('foo'); - $p->reject('foo'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot change a fulfilled promise to rejected - */ - public function testCannotRejectResolveWithSameValue() - { - $p = new Promise(); - $p->resolve('foo'); - $p->reject('foo'); - } - - public function testInvokesWaitFunction() - { - $p = new Promise(function () use (&$p) { $p->resolve('10'); }); - $this->assertEquals('10', $p->wait()); - } - - /** - * @expectedException \GuzzleHttp\Promise\RejectionException - */ - public function testRejectsAndThrowsWhenWaitFailsToResolve() - { - $p = new Promise(function () {}); - $p->wait(); - } - - /** - * @expectedException \GuzzleHttp\Promise\RejectionException - * @expectedExceptionMessage The promise was rejected with reason: foo - */ - public function testThrowsWhenUnwrapIsRejectedWithNonException() - { - $p = new Promise(function () use (&$p) { $p->reject('foo'); }); - $p->wait(); - } - - /** - * @expectedException \UnexpectedValueException - * @expectedExceptionMessage foo - */ - public function testThrowsWhenUnwrapIsRejectedWithException() - { - $e = new \UnexpectedValueException('foo'); - $p = new Promise(function () use (&$p, $e) { $p->reject($e); }); - $p->wait(); - } - - public function testDoesNotUnwrapExceptionsWhenDisabled() - { - $p = new Promise(function () use (&$p) { $p->reject('foo'); }); - $this->assertEquals('pending', $p->getState()); - $p->wait(false); - $this->assertEquals('rejected', $p->getState()); - } - - public function testRejectsSelfWhenWaitThrows() - { - $e = new \UnexpectedValueException('foo'); - $p = new Promise(function () use ($e) { throw $e; }); - try { - $p->wait(); - $this->fail(); - } catch (\UnexpectedValueException $e) { - $this->assertEquals('rejected', $p->getState()); - } - } - - public function testWaitsOnNestedPromises() - { - $p = new Promise(function () use (&$p) { $p->resolve('_'); }); - $p2 = new Promise(function () use (&$p2) { $p2->resolve('foo'); }); - $p3 = $p->then(function () use ($p2) { return $p2; }); - $this->assertSame('foo', $p3->wait()); - } - - /** - * @expectedException \GuzzleHttp\Promise\RejectionException - */ - public function testThrowsWhenWaitingOnPromiseWithNoWaitFunction() - { - $p = new Promise(); - $p->wait(); - } - - public function testThrowsWaitExceptionAfterPromiseIsResolved() - { - $p = new Promise(function () use (&$p) { - $p->reject('Foo!'); - throw new \Exception('Bar?'); - }); - - try { - $p->wait(); - $this->fail(); - } catch (\Exception $e) { - $this->assertEquals('Bar?', $e->getMessage()); - } - } - - public function testGetsActualWaitValueFromThen() - { - $p = new Promise(function () use (&$p) { $p->reject('Foo!'); }); - $p2 = $p->then(null, function ($reason) { - return new RejectedPromise([$reason]); - }); - - try { - $p2->wait(); - $this->fail('Should have thrown'); - } catch (RejectionException $e) { - $this->assertEquals(['Foo!'], $e->getReason()); - } - } - - public function testWaitBehaviorIsBasedOnLastPromiseInChain() - { - $p3 = new Promise(function () use (&$p3) { $p3->resolve('Whoop'); }); - $p2 = new Promise(function () use (&$p2, $p3) { $p2->reject($p3); }); - $p = new Promise(function () use (&$p, $p2) { $p->reject($p2); }); - $this->assertEquals('Whoop', $p->wait()); - } - - public function testCannotCancelNonPending() - { - $p = new Promise(); - $p->resolve('foo'); - $p->cancel(); - $this->assertEquals('fulfilled', $p->getState()); - } - - /** - * @expectedException \GuzzleHttp\Promise\CancellationException - */ - public function testCancelsPromiseWhenNoCancelFunction() - { - $p = new Promise(); - $p->cancel(); - $this->assertEquals('rejected', $p->getState()); - $p->wait(); - } - - public function testCancelsPromiseWithCancelFunction() - { - $called = false; - $p = new Promise(null, function () use (&$called) { $called = true; }); - $p->cancel(); - $this->assertEquals('rejected', $p->getState()); - $this->assertTrue($called); - } - - public function testCancelsUppermostPendingPromise() - { - $called = false; - $p1 = new Promise(null, function () use (&$called) { $called = true; }); - $p2 = $p1->then(function () {}); - $p3 = $p2->then(function () {}); - $p4 = $p3->then(function () {}); - $p3->cancel(); - $this->assertEquals('rejected', $p1->getState()); - $this->assertEquals('rejected', $p2->getState()); - $this->assertEquals('rejected', $p3->getState()); - $this->assertEquals('pending', $p4->getState()); - $this->assertTrue($called); - - try { - $p3->wait(); - $this->fail(); - } catch (CancellationException $e) { - $this->assertContains('cancelled', $e->getMessage()); - } - - try { - $p4->wait(); - $this->fail(); - } catch (CancellationException $e) { - $this->assertContains('cancelled', $e->getMessage()); - } - - $this->assertEquals('rejected', $p4->getState()); - } - - public function testCancelsChildPromises() - { - $called1 = $called2 = $called3 = false; - $p1 = new Promise(null, function () use (&$called1) { $called1 = true; }); - $p2 = new Promise(null, function () use (&$called2) { $called2 = true; }); - $p3 = new Promise(null, function () use (&$called3) { $called3 = true; }); - $p4 = $p2->then(function () use ($p3) { return $p3; }); - $p5 = $p4->then(function () { $this->fail(); }); - $p4->cancel(); - $this->assertEquals('pending', $p1->getState()); - $this->assertEquals('rejected', $p2->getState()); - $this->assertEquals('rejected', $p4->getState()); - $this->assertEquals('pending', $p5->getState()); - $this->assertFalse($called1); - $this->assertTrue($called2); - $this->assertFalse($called3); - } - - public function testRejectsPromiseWhenCancelFails() - { - $called = false; - $p = new Promise(null, function () use (&$called) { - $called = true; - throw new \Exception('e'); - }); - $p->cancel(); - $this->assertEquals('rejected', $p->getState()); - $this->assertTrue($called); - try { - $p->wait(); - $this->fail(); - } catch (\Exception $e) { - $this->assertEquals('e', $e->getMessage()); - } - } - - public function testCreatesPromiseWhenFulfilledAfterThen() - { - $p = new Promise(); - $carry = null; - $p2 = $p->then(function ($v) use (&$carry) { $carry = $v; }); - $this->assertNotSame($p, $p2); - $p->resolve('foo'); - P\queue()->run(); - - $this->assertEquals('foo', $carry); - } - - public function testCreatesPromiseWhenFulfilledBeforeThen() - { - $p = new Promise(); - $p->resolve('foo'); - $carry = null; - $p2 = $p->then(function ($v) use (&$carry) { $carry = $v; }); - $this->assertNotSame($p, $p2); - $this->assertNull($carry); - \GuzzleHttp\Promise\queue()->run(); - $this->assertEquals('foo', $carry); - } - - public function testCreatesPromiseWhenFulfilledWithNoCallback() - { - $p = new Promise(); - $p->resolve('foo'); - $p2 = $p->then(); - $this->assertNotSame($p, $p2); - $this->assertInstanceOf('GuzzleHttp\Promise\FulfilledPromise', $p2); - } - - public function testCreatesPromiseWhenRejectedAfterThen() - { - $p = new Promise(); - $carry = null; - $p2 = $p->then(null, function ($v) use (&$carry) { $carry = $v; }); - $this->assertNotSame($p, $p2); - $p->reject('foo'); - P\queue()->run(); - $this->assertEquals('foo', $carry); - } - - public function testCreatesPromiseWhenRejectedBeforeThen() - { - $p = new Promise(); - $p->reject('foo'); - $carry = null; - $p2 = $p->then(null, function ($v) use (&$carry) { $carry = $v; }); - $this->assertNotSame($p, $p2); - $this->assertNull($carry); - P\queue()->run(); - $this->assertEquals('foo', $carry); - } - - public function testCreatesPromiseWhenRejectedWithNoCallback() - { - $p = new Promise(); - $p->reject('foo'); - $p2 = $p->then(); - $this->assertNotSame($p, $p2); - $this->assertInstanceOf('GuzzleHttp\Promise\RejectedPromise', $p2); - } - - public function testInvokesWaitFnsForThens() - { - $p = new Promise(function () use (&$p) { $p->resolve('a'); }); - $p2 = $p - ->then(function ($v) { return $v . '-1-'; }) - ->then(function ($v) { return $v . '2'; }); - $this->assertEquals('a-1-2', $p2->wait()); - } - - public function testStacksThenWaitFunctions() - { - $p1 = new Promise(function () use (&$p1) { $p1->resolve('a'); }); - $p2 = new Promise(function () use (&$p2) { $p2->resolve('b'); }); - $p3 = new Promise(function () use (&$p3) { $p3->resolve('c'); }); - $p4 = $p1 - ->then(function () use ($p2) { return $p2; }) - ->then(function () use ($p3) { return $p3; }); - $this->assertEquals('c', $p4->wait()); - } - - public function testForwardsFulfilledDownChainBetweenGaps() - { - $p = new Promise(); - $r = $r2 = null; - $p->then(null, null) - ->then(function ($v) use (&$r) { $r = $v; return $v . '2'; }) - ->then(function ($v) use (&$r2) { $r2 = $v; }); - $p->resolve('foo'); - P\queue()->run(); - $this->assertEquals('foo', $r); - $this->assertEquals('foo2', $r2); - } - - public function testForwardsRejectedPromisesDownChainBetweenGaps() - { - $p = new Promise(); - $r = $r2 = null; - $p->then(null, null) - ->then(null, function ($v) use (&$r) { $r = $v; return $v . '2'; }) - ->then(function ($v) use (&$r2) { $r2 = $v; }); - $p->reject('foo'); - P\queue()->run(); - $this->assertEquals('foo', $r); - $this->assertEquals('foo2', $r2); - } - - public function testForwardsThrownPromisesDownChainBetweenGaps() - { - $e = new \Exception(); - $p = new Promise(); - $r = $r2 = null; - $p->then(null, null) - ->then(null, function ($v) use (&$r, $e) { - $r = $v; - throw $e; - }) - ->then( - null, - function ($v) use (&$r2) { $r2 = $v; } - ); - $p->reject('foo'); - P\queue()->run(); - $this->assertEquals('foo', $r); - $this->assertSame($e, $r2); - } - - public function testForwardsReturnedRejectedPromisesDownChainBetweenGaps() - { - $p = new Promise(); - $rejected = new RejectedPromise('bar'); - $r = $r2 = null; - $p->then(null, null) - ->then(null, function ($v) use (&$r, $rejected) { - $r = $v; - return $rejected; - }) - ->then( - null, - function ($v) use (&$r2) { $r2 = $v; } - ); - $p->reject('foo'); - P\queue()->run(); - $this->assertEquals('foo', $r); - $this->assertEquals('bar', $r2); - try { - $p->wait(); - } catch (RejectionException $e) { - $this->assertEquals('foo', $e->getReason()); - } - } - - public function testForwardsHandlersToNextPromise() - { - $p = new Promise(); - $p2 = new Promise(); - $resolved = null; - $p - ->then(function ($v) use ($p2) { return $p2; }) - ->then(function ($value) use (&$resolved) { $resolved = $value; }); - $p->resolve('a'); - $p2->resolve('b'); - P\queue()->run(); - $this->assertEquals('b', $resolved); - } - - public function testRemovesReferenceFromChildWhenParentWaitedUpon() - { - $r = null; - $p = new Promise(function () use (&$p) { $p->resolve('a'); }); - $p2 = new Promise(function () use (&$p2) { $p2->resolve('b'); }); - $pb = $p->then( - function ($v) use ($p2, &$r) { - $r = $v; - return $p2; - }) - ->then(function ($v) { return $v . '.'; }); - $this->assertEquals('a', $p->wait()); - $this->assertEquals('b', $p2->wait()); - $this->assertEquals('b.', $pb->wait()); - $this->assertEquals('a', $r); - } - - public function testForwardsHandlersWhenFulfilledPromiseIsReturned() - { - $res = []; - $p = new Promise(); - $p2 = new Promise(); - $p2->resolve('foo'); - $p2->then(function ($v) use (&$res) { $res[] = 'A:' . $v; }); - // $res is A:foo - $p - ->then(function () use ($p2, &$res) { $res[] = 'B'; return $p2; }) - ->then(function ($v) use (&$res) { $res[] = 'C:' . $v; }); - $p->resolve('a'); - $p->then(function ($v) use (&$res) { $res[] = 'D:' . $v; }); - P\queue()->run(); - $this->assertEquals(['A:foo', 'B', 'D:a', 'C:foo'], $res); - } - - public function testForwardsHandlersWhenRejectedPromiseIsReturned() - { - $res = []; - $p = new Promise(); - $p2 = new Promise(); - $p2->reject('foo'); - $p2->then(null, function ($v) use (&$res) { $res[] = 'A:' . $v; }); - $p->then(null, function () use ($p2, &$res) { $res[] = 'B'; return $p2; }) - ->then(null, function ($v) use (&$res) { $res[] = 'C:' . $v; }); - $p->reject('a'); - $p->then(null, function ($v) use (&$res) { $res[] = 'D:' . $v; }); - P\queue()->run(); - $this->assertEquals(['A:foo', 'B', 'D:a', 'C:foo'], $res); - } - - public function testDoesNotForwardRejectedPromise() - { - $res = []; - $p = new Promise(); - $p2 = new Promise(); - $p2->cancel(); - $p2->then(function ($v) use (&$res) { $res[] = "B:$v"; return $v; }); - $p->then(function ($v) use ($p2, &$res) { $res[] = "B:$v"; return $p2; }) - ->then(function ($v) use (&$res) { $res[] = 'C:' . $v; }); - $p->resolve('a'); - $p->then(function ($v) use (&$res) { $res[] = 'D:' . $v; }); - P\queue()->run(); - $this->assertEquals(['B:a', 'D:a'], $res); - } - - public function testRecursivelyForwardsWhenOnlyThennable() - { - $res = []; - $p = new Promise(); - $p2 = new Thennable(); - $p2->resolve('foo'); - $p2->then(function ($v) use (&$res) { $res[] = 'A:' . $v; }); - $p->then(function () use ($p2, &$res) { $res[] = 'B'; return $p2; }) - ->then(function ($v) use (&$res) { $res[] = 'C:' . $v; }); - $p->resolve('a'); - $p->then(function ($v) use (&$res) { $res[] = 'D:' . $v; }); - P\queue()->run(); - $this->assertEquals(['A:foo', 'B', 'D:a', 'C:foo'], $res); - } - - public function testRecursivelyForwardsWhenNotInstanceOfPromise() - { - $res = []; - $p = new Promise(); - $p2 = new NotPromiseInstance(); - $p2->then(function ($v) use (&$res) { $res[] = 'A:' . $v; }); - $p->then(function () use ($p2, &$res) { $res[] = 'B'; return $p2; }) - ->then(function ($v) use (&$res) { $res[] = 'C:' . $v; }); - $p->resolve('a'); - $p->then(function ($v) use (&$res) { $res[] = 'D:' . $v; }); - P\queue()->run(); - $this->assertEquals(['B', 'D:a'], $res); - $p2->resolve('foo'); - P\queue()->run(); - $this->assertEquals(['B', 'D:a', 'A:foo', 'C:foo'], $res); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot fulfill or reject a promise with itself - */ - public function testCannotResolveWithSelf() - { - $p = new Promise(); - $p->resolve($p); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot fulfill or reject a promise with itself - */ - public function testCannotRejectWithSelf() - { - $p = new Promise(); - $p->reject($p); - } - - public function testDoesNotBlowStackWhenWaitingOnNestedThens() - { - $inner = new Promise(function () use (&$inner) { $inner->resolve(0); }); - $prev = $inner; - for ($i = 1; $i < 100; $i++) { - $prev = $prev->then(function ($i) { return $i + 1; }); - } - - $parent = new Promise(function () use (&$parent, $prev) { - $parent->resolve($prev); - }); - - $this->assertEquals(99, $parent->wait()); - } - - public function testOtherwiseIsSugarForRejections() - { - $p = new Promise(); - $p->reject('foo'); - $p->otherwise(function ($v) use (&$c) { $c = $v; }); - P\queue()->run(); - $this->assertEquals($c, 'foo'); - } -} diff --git a/vendor/guzzlehttp/promises/tests/RejectedPromiseTest.php b/vendor/guzzlehttp/promises/tests/RejectedPromiseTest.php deleted file mode 100644 index 60f926e92..000000000 --- a/vendor/guzzlehttp/promises/tests/RejectedPromiseTest.php +++ /dev/null @@ -1,143 +0,0 @@ -assertEquals('rejected', $p->getState()); - try { - $p->wait(true); - $this->fail(); - } catch (\Exception $e) { - $this->assertEquals('rejected', $p->getState()); - $this->assertContains('foo', $e->getMessage()); - } - } - - public function testCannotCancel() - { - $p = new RejectedPromise('foo'); - $p->cancel(); - $this->assertEquals('rejected', $p->getState()); - } - - /** - * @expectedException \LogicException - * @exepctedExceptionMessage Cannot resolve a rejected promise - */ - public function testCannotResolve() - { - $p = new RejectedPromise('foo'); - $p->resolve('bar'); - } - - /** - * @expectedException \LogicException - * @exepctedExceptionMessage Cannot reject a rejected promise - */ - public function testCannotReject() - { - $p = new RejectedPromise('foo'); - $p->reject('bar'); - } - - public function testCanRejectWithSameValue() - { - $p = new RejectedPromise('foo'); - $p->reject('foo'); - } - - public function testThrowsSpecificException() - { - $e = new \Exception(); - $p = new RejectedPromise($e); - try { - $p->wait(true); - $this->fail(); - } catch (\Exception $e2) { - $this->assertSame($e, $e2); - } - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testCannotResolveWithPromise() - { - new RejectedPromise(new Promise()); - } - - public function testReturnsSelfWhenNoOnReject() - { - $p = new RejectedPromise('a'); - $this->assertSame($p, $p->then()); - } - - public function testInvokesOnRejectedAsynchronously() - { - $p = new RejectedPromise('a'); - $r = null; - $f = function ($reason) use (&$r) { $r = $reason; }; - $p->then(null, $f); - $this->assertNull($r); - \GuzzleHttp\Promise\queue()->run(); - $this->assertEquals('a', $r); - } - - public function testReturnsNewRejectedWhenOnRejectedFails() - { - $p = new RejectedPromise('a'); - $f = function () { throw new \Exception('b'); }; - $p2 = $p->then(null, $f); - $this->assertNotSame($p, $p2); - try { - $p2->wait(); - $this->fail(); - } catch (\Exception $e) { - $this->assertEquals('b', $e->getMessage()); - } - } - - public function testWaitingIsNoOp() - { - $p = new RejectedPromise('a'); - $p->wait(false); - } - - public function testOtherwiseIsSugarForRejections() - { - $p = new RejectedPromise('foo'); - $p->otherwise(function ($v) use (&$c) { $c = $v; }); - \GuzzleHttp\Promise\queue()->run(); - $this->assertSame('foo', $c); - } - - public function testCanResolveThenWithSuccess() - { - $actual = null; - $p = new RejectedPromise('foo'); - $p->otherwise(function ($v) { - return $v . ' bar'; - })->then(function ($v) use (&$actual) { - $actual = $v; - }); - \GuzzleHttp\Promise\queue()->run(); - $this->assertEquals('foo bar', $actual); - } - - public function testDoesNotTryToRejectTwiceDuringTrampoline() - { - $fp = new RejectedPromise('a'); - $t1 = $fp->then(null, function ($v) { return $v . ' b'; }); - $t1->resolve('why!'); - $this->assertEquals('why!', $t1->wait()); - } -} diff --git a/vendor/guzzlehttp/promises/tests/RejectionExceptionTest.php b/vendor/guzzlehttp/promises/tests/RejectionExceptionTest.php deleted file mode 100644 index 36c6a88c5..000000000 --- a/vendor/guzzlehttp/promises/tests/RejectionExceptionTest.php +++ /dev/null @@ -1,47 +0,0 @@ -message = $message; - } - - public function __toString() - { - return $this->message; - } -} - -class Thing2 implements \JsonSerializable -{ - public function jsonSerialize() - { - return '{}'; - } -} - -/** - * @covers GuzzleHttp\Promise\RejectionException - */ -class RejectionExceptionTest extends \PHPUnit_Framework_TestCase -{ - public function testCanGetReasonFromException() - { - $thing = new Thing1('foo'); - $e = new RejectionException($thing); - - $this->assertSame($thing, $e->getReason()); - $this->assertEquals('The promise was rejected with reason: foo', $e->getMessage()); - } - - public function testCanGetReasonMessageFromJson() - { - $reason = new Thing2(); - $e = new RejectionException($reason); - $this->assertContains("{}", $e->getMessage()); - } -} diff --git a/vendor/guzzlehttp/promises/tests/TaskQueueTest.php b/vendor/guzzlehttp/promises/tests/TaskQueueTest.php deleted file mode 100644 index 845b26352..000000000 --- a/vendor/guzzlehttp/promises/tests/TaskQueueTest.php +++ /dev/null @@ -1,31 +0,0 @@ -assertTrue($tq->isEmpty()); - } - - public function testKnowsIfFull() - { - $tq = new TaskQueue(false); - $tq->add(function () {}); - $this->assertFalse($tq->isEmpty()); - } - - public function testExecutesTasksInOrder() - { - $tq = new TaskQueue(false); - $called = []; - $tq->add(function () use (&$called) { $called[] = 'a'; }); - $tq->add(function () use (&$called) { $called[] = 'b'; }); - $tq->add(function () use (&$called) { $called[] = 'c'; }); - $tq->run(); - $this->assertEquals(['a', 'b', 'c'], $called); - } -} diff --git a/vendor/guzzlehttp/promises/tests/Thennable.php b/vendor/guzzlehttp/promises/tests/Thennable.php deleted file mode 100644 index 398954d7d..000000000 --- a/vendor/guzzlehttp/promises/tests/Thennable.php +++ /dev/null @@ -1,24 +0,0 @@ -nextPromise = new Promise(); - } - - public function then(callable $res = null, callable $rej = null) - { - return $this->nextPromise->then($res, $rej); - } - - public function resolve($value) - { - $this->nextPromise->resolve($value); - } -} diff --git a/vendor/guzzlehttp/promises/tests/bootstrap.php b/vendor/guzzlehttp/promises/tests/bootstrap.php deleted file mode 100644 index a63d264bf..000000000 --- a/vendor/guzzlehttp/promises/tests/bootstrap.php +++ /dev/null @@ -1,4 +0,0 @@ -assertInstanceOf('GuzzleHttp\Promise\FulfilledPromise', $p); - } - - public function testReturnsPromiseForPromise() - { - $p = new Promise(); - $this->assertSame($p, \GuzzleHttp\Promise\promise_for($p)); - } - - public function testReturnsPromiseForThennable() - { - $p = new Thennable(); - $wrapped = \GuzzleHttp\Promise\promise_for($p); - $this->assertNotSame($p, $wrapped); - $this->assertInstanceOf('GuzzleHttp\Promise\PromiseInterface', $wrapped); - $p->resolve('foo'); - P\queue()->run(); - $this->assertEquals('foo', $wrapped->wait()); - } - - public function testReturnsRejection() - { - $p = \GuzzleHttp\Promise\rejection_for('fail'); - $this->assertInstanceOf('GuzzleHttp\Promise\RejectedPromise', $p); - $this->assertEquals('fail', $this->readAttribute($p, 'reason')); - } - - public function testReturnsPromisesAsIsInRejectionFor() - { - $a = new Promise(); - $b = \GuzzleHttp\Promise\rejection_for($a); - $this->assertSame($a, $b); - } - - public function testWaitsOnAllPromisesIntoArray() - { - $e = new \Exception(); - $a = new Promise(function () use (&$a) { $a->resolve('a'); }); - $b = new Promise(function () use (&$b) { $b->reject('b'); }); - $c = new Promise(function () use (&$c, $e) { $c->reject($e); }); - $results = \GuzzleHttp\Promise\inspect_all([$a, $b, $c]); - $this->assertEquals([ - ['state' => 'fulfilled', 'value' => 'a'], - ['state' => 'rejected', 'reason' => 'b'], - ['state' => 'rejected', 'reason' => $e] - ], $results); - } - - /** - * @expectedException \GuzzleHttp\Promise\RejectionException - */ - public function testUnwrapsPromisesWithNoDefaultAndFailure() - { - $promises = [new FulfilledPromise('a'), new Promise()]; - \GuzzleHttp\Promise\unwrap($promises); - } - - public function testUnwrapsPromisesWithNoDefault() - { - $promises = [new FulfilledPromise('a')]; - $this->assertEquals(['a'], \GuzzleHttp\Promise\unwrap($promises)); - } - - public function testUnwrapsPromisesWithKeys() - { - $promises = [ - 'foo' => new FulfilledPromise('a'), - 'bar' => new FulfilledPromise('b'), - ]; - $this->assertEquals([ - 'foo' => 'a', - 'bar' => 'b' - ], \GuzzleHttp\Promise\unwrap($promises)); - } - - public function testAllAggregatesSortedArray() - { - $a = new Promise(); - $b = new Promise(); - $c = new Promise(); - $d = \GuzzleHttp\Promise\all([$a, $b, $c]); - $b->resolve('b'); - $a->resolve('a'); - $c->resolve('c'); - $d->then( - function ($value) use (&$result) { $result = $value; }, - function ($reason) use (&$result) { $result = $reason; } - ); - P\queue()->run(); - $this->assertEquals(['a', 'b', 'c'], $result); - } - - public function testAllThrowsWhenAnyRejected() - { - $a = new Promise(); - $b = new Promise(); - $c = new Promise(); - $d = \GuzzleHttp\Promise\all([$a, $b, $c]); - $b->resolve('b'); - $a->reject('fail'); - $c->resolve('c'); - $d->then( - function ($value) use (&$result) { $result = $value; }, - function ($reason) use (&$result) { $result = $reason; } - ); - P\queue()->run(); - $this->assertEquals('fail', $result); - } - - public function testSomeAggregatesSortedArrayWithMax() - { - $a = new Promise(); - $b = new Promise(); - $c = new Promise(); - $d = \GuzzleHttp\Promise\some(2, [$a, $b, $c]); - $b->resolve('b'); - $c->resolve('c'); - $a->resolve('a'); - $d->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals(['b', 'c'], $result); - } - - public function testSomeRejectsWhenTooManyRejections() - { - $a = new Promise(); - $b = new Promise(); - $d = \GuzzleHttp\Promise\some(2, [$a, $b]); - $a->reject('bad'); - $b->resolve('good'); - P\queue()->run(); - $this->assertEquals($a::REJECTED, $d->getState()); - $d->then(null, function ($reason) use (&$called) { - $called = $reason; - }); - P\queue()->run(); - $this->assertInstanceOf('GuzzleHttp\Promise\AggregateException', $called); - $this->assertContains('bad', $called->getReason()); - } - - public function testCanWaitUntilSomeCountIsSatisfied() - { - $a = new Promise(function () use (&$a) { $a->resolve('a'); }); - $b = new Promise(function () use (&$b) { $b->resolve('b'); }); - $c = new Promise(function () use (&$c) { $c->resolve('c'); }); - $d = \GuzzleHttp\Promise\some(2, [$a, $b, $c]); - $this->assertEquals(['a', 'b'], $d->wait()); - } - - /** - * @expectedException \GuzzleHttp\Promise\AggregateException - * @expectedExceptionMessage Not enough promises to fulfill count - */ - public function testThrowsIfImpossibleToWaitForSomeCount() - { - $a = new Promise(function () use (&$a) { $a->resolve('a'); }); - $d = \GuzzleHttp\Promise\some(2, [$a]); - $d->wait(); - } - - /** - * @expectedException \GuzzleHttp\Promise\AggregateException - * @expectedExceptionMessage Not enough promises to fulfill count - */ - public function testThrowsIfResolvedWithoutCountTotalResults() - { - $a = new Promise(); - $b = new Promise(); - $d = \GuzzleHttp\Promise\some(3, [$a, $b]); - $a->resolve('a'); - $b->resolve('b'); - $d->wait(); - } - - public function testAnyReturnsFirstMatch() - { - $a = new Promise(); - $b = new Promise(); - $c = \GuzzleHttp\Promise\any([$a, $b]); - $b->resolve('b'); - $a->resolve('a'); - //P\queue()->run(); - //$this->assertEquals('fulfilled', $c->getState()); - $c->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals('b', $result); - } - - public function testSettleFulfillsWithFulfilledAndRejected() - { - $a = new Promise(); - $b = new Promise(); - $c = new Promise(); - $d = \GuzzleHttp\Promise\settle([$a, $b, $c]); - $b->resolve('b'); - $c->resolve('c'); - $a->reject('a'); - P\queue()->run(); - $this->assertEquals('fulfilled', $d->getState()); - $d->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals([ - ['state' => 'rejected', 'reason' => 'a'], - ['state' => 'fulfilled', 'value' => 'b'], - ['state' => 'fulfilled', 'value' => 'c'] - ], $result); - } - - public function testCanInspectFulfilledPromise() - { - $p = new FulfilledPromise('foo'); - $this->assertEquals([ - 'state' => 'fulfilled', - 'value' => 'foo' - ], \GuzzleHttp\Promise\inspect($p)); - } - - public function testCanInspectRejectedPromise() - { - $p = new RejectedPromise('foo'); - $this->assertEquals([ - 'state' => 'rejected', - 'reason' => 'foo' - ], \GuzzleHttp\Promise\inspect($p)); - } - - public function testCanInspectRejectedPromiseWithNormalException() - { - $e = new \Exception('foo'); - $p = new RejectedPromise($e); - $this->assertEquals([ - 'state' => 'rejected', - 'reason' => $e - ], \GuzzleHttp\Promise\inspect($p)); - } - - public function testCallsEachLimit() - { - $p = new Promise(); - $aggregate = \GuzzleHttp\Promise\each_limit($p, 2); - $p->resolve('a'); - P\queue()->run(); - $this->assertEquals($p::FULFILLED, $aggregate->getState()); - } - - public function testEachLimitAllRejectsOnFailure() - { - $p = [new FulfilledPromise('a'), new RejectedPromise('b')]; - $aggregate = \GuzzleHttp\Promise\each_limit_all($p, 2); - P\queue()->run(); - $this->assertEquals(P\PromiseInterface::REJECTED, $aggregate->getState()); - $result = \GuzzleHttp\Promise\inspect($aggregate); - $this->assertEquals('b', $result['reason']); - } - - public function testIterForReturnsIterator() - { - $iter = new \ArrayIterator(); - $this->assertSame($iter, \GuzzleHttp\Promise\iter_for($iter)); - } - - public function testKnowsIfFulfilled() - { - $p = new FulfilledPromise(null); - $this->assertTrue(P\is_fulfilled($p)); - $this->assertFalse(P\is_rejected($p)); - } - - public function testKnowsIfRejected() - { - $p = new RejectedPromise(null); - $this->assertTrue(P\is_rejected($p)); - $this->assertFalse(P\is_fulfilled($p)); - } - - public function testKnowsIfSettled() - { - $p = new RejectedPromise(null); - $this->assertTrue(P\is_settled($p)); - $p = new Promise(); - $this->assertFalse(P\is_settled($p)); - } - - public function testReturnsTrampoline() - { - $this->assertInstanceOf('GuzzleHttp\Promise\TaskQueue', P\queue()); - $this->assertSame(P\queue(), P\queue()); - } - - public function testCanScheduleThunk() - { - $tramp = P\queue(); - $promise = P\task(function () { return 'Hi!'; }); - $c = null; - $promise->then(function ($v) use (&$c) { $c = $v; }); - $this->assertNull($c); - $tramp->run(); - $this->assertEquals('Hi!', $c); - } - - public function testCanScheduleThunkWithRejection() - { - $tramp = P\queue(); - $promise = P\task(function () { throw new \Exception('Hi!'); }); - $c = null; - $promise->otherwise(function ($v) use (&$c) { $c = $v; }); - $this->assertNull($c); - $tramp->run(); - $this->assertEquals('Hi!', $c->getMessage()); - } - - public function testCanScheduleThunkWithWait() - { - $tramp = P\queue(); - $promise = P\task(function () { return 'a'; }); - $this->assertEquals('a', $promise->wait()); - $tramp->run(); - } - - public function testYieldsFromCoroutine() - { - $promise = P\coroutine(function () { - $value = (yield new P\FulfilledPromise('a')); - yield $value . 'b'; - }); - $promise->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals('ab', $result); - } - - public function testCanCatchExceptionsInCoroutine() - { - $promise = P\coroutine(function () { - try { - yield new P\RejectedPromise('a'); - $this->fail('Should have thrown into the coroutine!'); - } catch (P\RejectionException $e) { - $value = (yield new P\FulfilledPromise($e->getReason())); - yield $value . 'b'; - } - }); - $promise->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals(P\PromiseInterface::FULFILLED, $promise->getState()); - $this->assertEquals('ab', $result); - } - - public function testRejectsParentExceptionWhenException() - { - $promise = P\coroutine(function () { - yield new P\FulfilledPromise(0); - throw new \Exception('a'); - }); - $promise->then( - function () { $this->fail(); }, - function ($reason) use (&$result) { $result = $reason; } - ); - P\queue()->run(); - $this->assertInstanceOf('Exception', $result); - $this->assertEquals('a', $result->getMessage()); - } - - public function testCanRejectFromRejectionCallback() - { - $promise = P\coroutine(function () { - yield new P\FulfilledPromise(0); - yield new P\RejectedPromise('no!'); - }); - $promise->then( - function () { $this->fail(); }, - function ($reason) use (&$result) { $result = $reason; } - ); - P\queue()->run(); - $this->assertInstanceOf('GuzzleHttp\Promise\RejectionException', $result); - $this->assertEquals('no!', $result->getReason()); - } - - public function testCanAsyncReject() - { - $rej = new P\Promise(); - $promise = P\coroutine(function () use ($rej) { - yield new P\FulfilledPromise(0); - yield $rej; - }); - $promise->then( - function () { $this->fail(); }, - function ($reason) use (&$result) { $result = $reason; } - ); - $rej->reject('no!'); - P\queue()->run(); - $this->assertInstanceOf('GuzzleHttp\Promise\RejectionException', $result); - $this->assertEquals('no!', $result->getReason()); - } - - public function testCanCatchAndThrowOtherException() - { - $promise = P\coroutine(function () { - try { - yield new P\RejectedPromise('a'); - $this->fail('Should have thrown into the coroutine!'); - } catch (P\RejectionException $e) { - throw new \Exception('foo'); - } - }); - $promise->otherwise(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals(P\PromiseInterface::REJECTED, $promise->getState()); - $this->assertContains('foo', $result->getMessage()); - } - - public function testCanCatchAndYieldOtherException() - { - $promise = P\coroutine(function () { - try { - yield new P\RejectedPromise('a'); - $this->fail('Should have thrown into the coroutine!'); - } catch (P\RejectionException $e) { - yield new P\RejectedPromise('foo'); - } - }); - $promise->otherwise(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals(P\PromiseInterface::REJECTED, $promise->getState()); - $this->assertContains('foo', $result->getMessage()); - } - - public function createLotsOfSynchronousPromise() - { - return P\coroutine(function () { - $value = 0; - for ($i = 0; $i < 1000; $i++) { - $value = (yield new P\FulfilledPromise($i)); - } - yield $value; - }); - } - - public function testLotsOfSynchronousDoesNotBlowStack() - { - $promise = $this->createLotsOfSynchronousPromise(); - $promise->then(function ($v) use (&$r) { $r = $v; }); - P\queue()->run(); - $this->assertEquals(999, $r); - } - - public function testLotsOfSynchronousWaitDoesNotBlowStack() - { - $promise = $this->createLotsOfSynchronousPromise(); - $promise->then(function ($v) use (&$r) { $r = $v; }); - $this->assertEquals(999, $promise->wait()); - $this->assertEquals(999, $r); - } - - private function createLotsOfFlappingPromise() - { - return P\coroutine(function () { - $value = 0; - for ($i = 0; $i < 1000; $i++) { - try { - if ($i % 2) { - $value = (yield new P\FulfilledPromise($i)); - } else { - $value = (yield new P\RejectedPromise($i)); - } - } catch (\Exception $e) { - $value = (yield new P\FulfilledPromise($i)); - } - } - yield $value; - }); - } - - public function testLotsOfTryCatchingDoesNotBlowStack() - { - $promise = $this->createLotsOfFlappingPromise(); - $promise->then(function ($v) use (&$r) { $r = $v; }); - P\queue()->run(); - $this->assertEquals(999, $r); - } - - public function testLotsOfTryCatchingWaitingDoesNotBlowStack() - { - $promise = $this->createLotsOfFlappingPromise(); - $promise->then(function ($v) use (&$r) { $r = $v; }); - $this->assertEquals(999, $promise->wait()); - $this->assertEquals(999, $r); - } - - public function testAsyncPromisesWithCorrectlyYieldedValues() - { - $promises = [ - new P\Promise(), - new P\Promise(), - new P\Promise() - ]; - - $promise = P\coroutine(function () use ($promises) { - $value = null; - $this->assertEquals('skip', (yield new P\FulfilledPromise('skip'))); - foreach ($promises as $idx => $p) { - $value = (yield $p); - $this->assertEquals($value, $idx); - $this->assertEquals('skip', (yield new P\FulfilledPromise('skip'))); - } - $this->assertEquals('skip', (yield new P\FulfilledPromise('skip'))); - yield $value; - }); - - $promises[0]->resolve(0); - $promises[1]->resolve(1); - $promises[2]->resolve(2); - - $promise->then(function ($v) use (&$r) { $r = $v; }); - P\queue()->run(); - $this->assertEquals(2, $r); - } - - public function testYieldFinalWaitablePromise() - { - $p1 = new P\Promise(function () use (&$p1) { - $p1->resolve('skip me'); - }); - $p2 = new P\Promise(function () use (&$p2) { - $p2->resolve('hello!'); - }); - $co = P\coroutine(function() use ($p1, $p2) { - yield $p1; - yield $p2; - }); - P\queue()->run(); - $this->assertEquals('hello!', $co->wait()); - } - - public function testCanYieldFinalPendingPromise() - { - $p1 = new P\Promise(); - $p2 = new P\Promise(); - $co = P\coroutine(function() use ($p1, $p2) { - yield $p1; - yield $p2; - }); - $p1->resolve('a'); - $p2->resolve('b'); - $co->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals('b', $result); - } - - public function testCanNestYieldsAndFailures() - { - $p1 = new P\Promise(); - $p2 = new P\Promise(); - $p3 = new P\Promise(); - $p4 = new P\Promise(); - $p5 = new P\Promise(); - $co = P\coroutine(function() use ($p1, $p2, $p3, $p4, $p5) { - try { - yield $p1; - } catch (\Exception $e) { - yield $p2; - try { - yield $p3; - yield $p4; - } catch (\Exception $e) { - yield $p5; - } - } - }); - $p1->reject('a'); - $p2->resolve('b'); - $p3->resolve('c'); - $p4->reject('d'); - $p5->resolve('e'); - $co->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals('e', $result); - } - - public function testCanYieldErrorsAndSuccessesWithoutRecursion() - { - $promises = []; - for ($i = 0; $i < 20; $i++) { - $promises[] = new P\Promise(); - } - - $co = P\coroutine(function() use ($promises) { - for ($i = 0; $i < 20; $i += 4) { - try { - yield $promises[$i]; - yield $promises[$i + 1]; - } catch (\Exception $e) { - yield $promises[$i + 2]; - yield $promises[$i + 3]; - } - } - }); - - for ($i = 0; $i < 20; $i += 4) { - $promises[$i]->resolve($i); - $promises[$i + 1]->reject($i + 1); - $promises[$i + 2]->resolve($i + 2); - $promises[$i + 3]->resolve($i + 3); - } - - $co->then(function ($value) use (&$result) { $result = $value; }); - P\queue()->run(); - $this->assertEquals('19', $result); - } - - public function testCanWaitOnPromiseAfterFulfilled() - { - $f = function () { - static $i = 0; - $i++; - return $p = new P\Promise(function () use (&$p, $i) { - $p->resolve($i . '-bar'); - }); - }; - - $promises = []; - for ($i = 0; $i < 20; $i++) { - $promises[] = $f(); - } - - $p = P\coroutine(function () use ($promises) { - yield new P\FulfilledPromise('foo!'); - foreach ($promises as $promise) { - yield $promise; - } - }); - - $this->assertEquals('20-bar', $p->wait()); - } - - public function testCanWaitOnErroredPromises() - { - $p1 = new P\Promise(function () use (&$p1) { $p1->reject('a'); }); - $p2 = new P\Promise(function () use (&$p2) { $p2->resolve('b'); }); - $p3 = new P\Promise(function () use (&$p3) { $p3->resolve('c'); }); - $p4 = new P\Promise(function () use (&$p4) { $p4->reject('d'); }); - $p5 = new P\Promise(function () use (&$p5) { $p5->resolve('e'); }); - $p6 = new P\Promise(function () use (&$p6) { $p6->reject('f'); }); - - $co = P\coroutine(function() use ($p1, $p2, $p3, $p4, $p5, $p6) { - try { - yield $p1; - } catch (\Exception $e) { - yield $p2; - try { - yield $p3; - yield $p4; - } catch (\Exception $e) { - yield $p5; - yield $p6; - } - } - }); - - $res = P\inspect($co); - $this->assertEquals('f', $res['reason']); - } - - public function testCoroutineOtherwiseIntegrationTest() - { - $a = new P\Promise(); - $b = new P\Promise(); - $promise = P\coroutine(function () use ($a, $b) { - // Execute the pool of commands concurrently, and process errors. - yield $a; - yield $b; - })->otherwise(function (\Exception $e) { - // Throw errors from the operations as a specific Multipart error. - throw new \OutOfBoundsException('a', 0, $e); - }); - $a->resolve('a'); - $b->reject('b'); - $reason = P\inspect($promise)['reason']; - $this->assertInstanceOf('OutOfBoundsException', $reason); - $this->assertInstanceOf('GuzzleHttp\Promise\RejectionException', $reason->getPrevious()); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php b/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php deleted file mode 100644 index 3c197dcea..000000000 --- a/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php +++ /dev/null @@ -1,186 +0,0 @@ -getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable']) - ->getMockForAbstractClass(); - $s->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(false)); - $a->addStream($s); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage The AppendStream can only seek with SEEK_SET - */ - public function testValidatesSeekType() - { - $a = new AppendStream(); - $a->seek(100, SEEK_CUR); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Unable to seek stream 0 of the AppendStream - */ - public function testTriesToRewindOnSeek() - { - $a = new AppendStream(); - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'rewind', 'isSeekable']) - ->getMockForAbstractClass(); - $s->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(true)); - $s->expects($this->once()) - ->method('isSeekable') - ->will($this->returnValue(true)); - $s->expects($this->once()) - ->method('rewind') - ->will($this->throwException(new \RuntimeException())); - $a->addStream($s); - $a->seek(10); - } - - public function testSeeksToPositionByReading() - { - $a = new AppendStream([ - Psr7\stream_for('foo'), - Psr7\stream_for('bar'), - Psr7\stream_for('baz'), - ]); - - $a->seek(3); - $this->assertEquals(3, $a->tell()); - $this->assertEquals('bar', $a->read(3)); - - $a->seek(6); - $this->assertEquals(6, $a->tell()); - $this->assertEquals('baz', $a->read(3)); - } - - public function testDetachesEachStream() - { - $s1 = Psr7\stream_for('foo'); - $s2 = Psr7\stream_for('bar'); - $a = new AppendStream([$s1, $s2]); - $this->assertSame('foobar', (string) $a); - $a->detach(); - $this->assertSame('', (string) $a); - $this->assertSame(0, $a->getSize()); - } - - public function testClosesEachStream() - { - $s1 = Psr7\stream_for('foo'); - $a = new AppendStream([$s1]); - $a->close(); - $this->assertSame('', (string) $a); - } - - /** - * @expectedExceptionMessage Cannot write to an AppendStream - * @expectedException \RuntimeException - */ - public function testIsNotWritable() - { - $a = new AppendStream([Psr7\stream_for('foo')]); - $this->assertFalse($a->isWritable()); - $this->assertTrue($a->isSeekable()); - $this->assertTrue($a->isReadable()); - $a->write('foo'); - } - - public function testDoesNotNeedStreams() - { - $a = new AppendStream(); - $this->assertEquals('', (string) $a); - } - - public function testCanReadFromMultipleStreams() - { - $a = new AppendStream([ - Psr7\stream_for('foo'), - Psr7\stream_for('bar'), - Psr7\stream_for('baz'), - ]); - $this->assertFalse($a->eof()); - $this->assertSame(0, $a->tell()); - $this->assertEquals('foo', $a->read(3)); - $this->assertEquals('bar', $a->read(3)); - $this->assertEquals('baz', $a->read(3)); - $this->assertSame('', $a->read(1)); - $this->assertTrue($a->eof()); - $this->assertSame(9, $a->tell()); - $this->assertEquals('foobarbaz', (string) $a); - } - - public function testCanDetermineSizeFromMultipleStreams() - { - $a = new AppendStream([ - Psr7\stream_for('foo'), - Psr7\stream_for('bar') - ]); - $this->assertEquals(6, $a->getSize()); - - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'isReadable']) - ->getMockForAbstractClass(); - $s->expects($this->once()) - ->method('isSeekable') - ->will($this->returnValue(null)); - $s->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(true)); - $a->addStream($s); - $this->assertNull($a->getSize()); - } - - public function testCatchesExceptionsWhenCastingToString() - { - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'read', 'isReadable', 'eof']) - ->getMockForAbstractClass(); - $s->expects($this->once()) - ->method('isSeekable') - ->will($this->returnValue(true)); - $s->expects($this->once()) - ->method('read') - ->will($this->throwException(new \RuntimeException('foo'))); - $s->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(true)); - $s->expects($this->any()) - ->method('eof') - ->will($this->returnValue(false)); - $a = new AppendStream([$s]); - $this->assertFalse($a->eof()); - $this->assertSame('', (string) $a); - } - - public function testCanDetach() - { - $s = new AppendStream(); - $s->detach(); - } - - public function testReturnsEmptyMetadata() - { - $s = new AppendStream(); - $this->assertEquals([], $s->getMetadata()); - $this->assertNull($s->getMetadata('foo')); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php b/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php deleted file mode 100644 index 0a635d467..000000000 --- a/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php +++ /dev/null @@ -1,63 +0,0 @@ -assertTrue($b->isReadable()); - $this->assertTrue($b->isWritable()); - $this->assertFalse($b->isSeekable()); - $this->assertEquals(null, $b->getMetadata('foo')); - $this->assertEquals(10, $b->getMetadata('hwm')); - $this->assertEquals([], $b->getMetadata()); - } - - public function testRemovesReadDataFromBuffer() - { - $b = new BufferStream(); - $this->assertEquals(3, $b->write('foo')); - $this->assertEquals(3, $b->getSize()); - $this->assertFalse($b->eof()); - $this->assertEquals('foo', $b->read(10)); - $this->assertTrue($b->eof()); - $this->assertEquals('', $b->read(10)); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Cannot determine the position of a BufferStream - */ - public function testCanCastToStringOrGetContents() - { - $b = new BufferStream(); - $b->write('foo'); - $b->write('baz'); - $this->assertEquals('foo', $b->read(3)); - $b->write('bar'); - $this->assertEquals('bazbar', (string) $b); - $b->tell(); - } - - public function testDetachClearsBuffer() - { - $b = new BufferStream(); - $b->write('foo'); - $b->detach(); - $this->assertTrue($b->eof()); - $this->assertEquals(3, $b->write('abc')); - $this->assertEquals('abc', $b->read(10)); - } - - public function testExceedingHighwaterMarkReturnsFalseButStillBuffers() - { - $b = new BufferStream(5); - $this->assertEquals(3, $b->write('hi ')); - $this->assertFalse($b->write('hello')); - $this->assertEquals('hi hello', (string) $b); - $this->assertEquals(4, $b->write('test')); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php b/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php deleted file mode 100644 index f82c3a5b6..000000000 --- a/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php +++ /dev/null @@ -1,166 +0,0 @@ -decorated = Psr7\stream_for('testing'); - $this->body = new CachingStream($this->decorated); - } - - public function tearDown() - { - $this->decorated->close(); - $this->body->close(); - } - - public function testUsesRemoteSizeIfPossible() - { - $body = Psr7\stream_for('test'); - $caching = new CachingStream($body); - $this->assertEquals(4, $caching->getSize()); - } - - public function testReadsUntilCachedToByte() - { - $this->body->seek(5); - $this->assertEquals('n', $this->body->read(1)); - $this->body->seek(0); - $this->assertEquals('t', $this->body->read(1)); - } - - public function testCanSeekNearEndWithSeekEnd() - { - $baseStream = Psr7\stream_for(implode('', range('a', 'z'))); - $cached = new CachingStream($baseStream); - $cached->seek(1, SEEK_END); - $this->assertEquals(24, $baseStream->tell()); - $this->assertEquals('y', $cached->read(1)); - $this->assertEquals(26, $cached->getSize()); - } - - public function testCanSeekToEndWithSeekEnd() - { - $baseStream = Psr7\stream_for(implode('', range('a', 'z'))); - $cached = new CachingStream($baseStream); - $cached->seek(0, SEEK_END); - $this->assertEquals(25, $baseStream->tell()); - $this->assertEquals('z', $cached->read(1)); - $this->assertEquals(26, $cached->getSize()); - } - - public function testCanUseSeekEndWithUnknownSize() - { - $baseStream = Psr7\stream_for('testing'); - $decorated = Psr7\FnStream::decorate($baseStream, [ - 'getSize' => function () { return null; } - ]); - $cached = new CachingStream($decorated); - $cached->seek(1, SEEK_END); - $this->assertEquals('ng', $cached->read(2)); - } - - public function testRewindUsesSeek() - { - $a = Psr7\stream_for('foo'); - $d = $this->getMockBuilder('GuzzleHttp\Psr7\CachingStream') - ->setMethods(array('seek')) - ->setConstructorArgs(array($a)) - ->getMock(); - $d->expects($this->once()) - ->method('seek') - ->with(0) - ->will($this->returnValue(true)); - $d->seek(0); - } - - public function testCanSeekToReadBytes() - { - $this->assertEquals('te', $this->body->read(2)); - $this->body->seek(0); - $this->assertEquals('test', $this->body->read(4)); - $this->assertEquals(4, $this->body->tell()); - $this->body->seek(2); - $this->assertEquals(2, $this->body->tell()); - $this->body->seek(2, SEEK_CUR); - $this->assertEquals(4, $this->body->tell()); - $this->assertEquals('ing', $this->body->read(3)); - } - - public function testWritesToBufferStream() - { - $this->body->read(2); - $this->body->write('hi'); - $this->body->seek(0); - $this->assertEquals('tehiing', (string) $this->body); - } - - public function testSkipsOverwrittenBytes() - { - $decorated = Psr7\stream_for( - implode("\n", array_map(function ($n) { - return str_pad($n, 4, '0', STR_PAD_LEFT); - }, range(0, 25))) - ); - - $body = new CachingStream($decorated); - - $this->assertEquals("0000\n", Psr7\readline($body)); - $this->assertEquals("0001\n", Psr7\readline($body)); - // Write over part of the body yet to be read, so skip some bytes - $this->assertEquals(5, $body->write("TEST\n")); - $this->assertEquals(5, $this->readAttribute($body, 'skipReadBytes')); - // Read, which skips bytes, then reads - $this->assertEquals("0003\n", Psr7\readline($body)); - $this->assertEquals(0, $this->readAttribute($body, 'skipReadBytes')); - $this->assertEquals("0004\n", Psr7\readline($body)); - $this->assertEquals("0005\n", Psr7\readline($body)); - - // Overwrite part of the cached body (so don't skip any bytes) - $body->seek(5); - $this->assertEquals(5, $body->write("ABCD\n")); - $this->assertEquals(0, $this->readAttribute($body, 'skipReadBytes')); - $this->assertEquals("TEST\n", Psr7\readline($body)); - $this->assertEquals("0003\n", Psr7\readline($body)); - $this->assertEquals("0004\n", Psr7\readline($body)); - $this->assertEquals("0005\n", Psr7\readline($body)); - $this->assertEquals("0006\n", Psr7\readline($body)); - $this->assertEquals(5, $body->write("1234\n")); - $this->assertEquals(5, $this->readAttribute($body, 'skipReadBytes')); - - // Seek to 0 and ensure the overwritten bit is replaced - $body->seek(0); - $this->assertEquals("0000\nABCD\nTEST\n0003\n0004\n0005\n0006\n1234\n0008\n0009\n", $body->read(50)); - - // Ensure that casting it to a string does not include the bit that was overwritten - $this->assertContains("0000\nABCD\nTEST\n0003\n0004\n0005\n0006\n1234\n0008\n0009\n", (string) $body); - } - - public function testClosesBothStreams() - { - $s = fopen('php://temp', 'r'); - $a = Psr7\stream_for($s); - $d = new CachingStream($a); - $d->close(); - $this->assertFalse(is_resource($s)); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresValidWhence() - { - $this->body->seek(10, -123456); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php b/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php deleted file mode 100644 index 915b21523..000000000 --- a/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php +++ /dev/null @@ -1,26 +0,0 @@ -assertEquals(3, $drop->write('hel')); - $this->assertEquals(2, $drop->write('lo')); - $this->assertEquals(5, $drop->getSize()); - $this->assertEquals('hello', $drop->read(5)); - $this->assertEquals(0, $drop->getSize()); - $drop->write('12345678910'); - $this->assertEquals(5, $stream->getSize()); - $this->assertEquals(5, $drop->getSize()); - $this->assertEquals('12345', (string) $drop); - $this->assertEquals(0, $drop->getSize()); - $drop->write('hello'); - $this->assertSame(0, $drop->write('test')); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/FnStreamTest.php b/vendor/guzzlehttp/psr7/tests/FnStreamTest.php deleted file mode 100644 index 66ae90a04..000000000 --- a/vendor/guzzlehttp/psr7/tests/FnStreamTest.php +++ /dev/null @@ -1,90 +0,0 @@ -seek(1); - } - - public function testProxiesToFunction() - { - $s = new FnStream([ - 'read' => function ($len) { - $this->assertEquals(3, $len); - return 'foo'; - } - ]); - - $this->assertEquals('foo', $s->read(3)); - } - - public function testCanCloseOnDestruct() - { - $called = false; - $s = new FnStream([ - 'close' => function () use (&$called) { - $called = true; - } - ]); - unset($s); - $this->assertTrue($called); - } - - public function testDoesNotRequireClose() - { - $s = new FnStream([]); - unset($s); - } - - public function testDecoratesStream() - { - $a = Psr7\stream_for('foo'); - $b = FnStream::decorate($a, []); - $this->assertEquals(3, $b->getSize()); - $this->assertEquals($b->isWritable(), true); - $this->assertEquals($b->isReadable(), true); - $this->assertEquals($b->isSeekable(), true); - $this->assertEquals($b->read(3), 'foo'); - $this->assertEquals($b->tell(), 3); - $this->assertEquals($a->tell(), 3); - $this->assertSame('', $a->read(1)); - $this->assertEquals($b->eof(), true); - $this->assertEquals($a->eof(), true); - $b->seek(0); - $this->assertEquals('foo', (string) $b); - $b->seek(0); - $this->assertEquals('foo', $b->getContents()); - $this->assertEquals($a->getMetadata(), $b->getMetadata()); - $b->seek(0, SEEK_END); - $b->write('bar'); - $this->assertEquals('foobar', (string) $b); - $this->assertInternalType('resource', $b->detach()); - $b->close(); - } - - public function testDecoratesWithCustomizations() - { - $called = false; - $a = Psr7\stream_for('foo'); - $b = FnStream::decorate($a, [ - 'read' => function ($len) use (&$called, $a) { - $called = true; - return $a->read($len); - } - ]); - $this->assertEquals('foo', $b->read(3)); - $this->assertTrue($called); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/FunctionsTest.php b/vendor/guzzlehttp/psr7/tests/FunctionsTest.php deleted file mode 100644 index de5b5cbcb..000000000 --- a/vendor/guzzlehttp/psr7/tests/FunctionsTest.php +++ /dev/null @@ -1,586 +0,0 @@ -assertEquals('foobaz', Psr7\copy_to_string($s)); - $s->seek(0); - $this->assertEquals('foo', Psr7\copy_to_string($s, 3)); - $this->assertEquals('baz', Psr7\copy_to_string($s, 3)); - $this->assertEquals('', Psr7\copy_to_string($s)); - } - - public function testCopiesToStringStopsWhenReadFails() - { - $s1 = Psr7\stream_for('foobaz'); - $s1 = FnStream::decorate($s1, [ - 'read' => function () { return ''; } - ]); - $result = Psr7\copy_to_string($s1); - $this->assertEquals('', $result); - } - - public function testCopiesToStream() - { - $s1 = Psr7\stream_for('foobaz'); - $s2 = Psr7\stream_for(''); - Psr7\copy_to_stream($s1, $s2); - $this->assertEquals('foobaz', (string) $s2); - $s2 = Psr7\stream_for(''); - $s1->seek(0); - Psr7\copy_to_stream($s1, $s2, 3); - $this->assertEquals('foo', (string) $s2); - Psr7\copy_to_stream($s1, $s2, 3); - $this->assertEquals('foobaz', (string) $s2); - } - - public function testStopsCopyToStreamWhenWriteFails() - { - $s1 = Psr7\stream_for('foobaz'); - $s2 = Psr7\stream_for(''); - $s2 = FnStream::decorate($s2, ['write' => function () { return 0; }]); - Psr7\copy_to_stream($s1, $s2); - $this->assertEquals('', (string) $s2); - } - - public function testStopsCopyToSteamWhenWriteFailsWithMaxLen() - { - $s1 = Psr7\stream_for('foobaz'); - $s2 = Psr7\stream_for(''); - $s2 = FnStream::decorate($s2, ['write' => function () { return 0; }]); - Psr7\copy_to_stream($s1, $s2, 10); - $this->assertEquals('', (string) $s2); - } - - public function testStopsCopyToSteamWhenReadFailsWithMaxLen() - { - $s1 = Psr7\stream_for('foobaz'); - $s1 = FnStream::decorate($s1, ['read' => function () { return ''; }]); - $s2 = Psr7\stream_for(''); - Psr7\copy_to_stream($s1, $s2, 10); - $this->assertEquals('', (string) $s2); - } - - public function testReadsLines() - { - $s = Psr7\stream_for("foo\nbaz\nbar"); - $this->assertEquals("foo\n", Psr7\readline($s)); - $this->assertEquals("baz\n", Psr7\readline($s)); - $this->assertEquals("bar", Psr7\readline($s)); - } - - public function testReadsLinesUpToMaxLength() - { - $s = Psr7\stream_for("12345\n"); - $this->assertEquals("123", Psr7\readline($s, 4)); - $this->assertEquals("45\n", Psr7\readline($s)); - } - - public function testReadsLineUntilFalseReturnedFromRead() - { - $s = $this->getMockBuilder('GuzzleHttp\Psr7\Stream') - ->setMethods(['read', 'eof']) - ->disableOriginalConstructor() - ->getMock(); - $s->expects($this->exactly(2)) - ->method('read') - ->will($this->returnCallback(function () { - static $c = false; - if ($c) { - return false; - } - $c = true; - return 'h'; - })); - $s->expects($this->exactly(2)) - ->method('eof') - ->will($this->returnValue(false)); - $this->assertEquals("h", Psr7\readline($s)); - } - - public function testCalculatesHash() - { - $s = Psr7\stream_for('foobazbar'); - $this->assertEquals(md5('foobazbar'), Psr7\hash($s, 'md5')); - } - - /** - * @expectedException \RuntimeException - */ - public function testCalculatesHashThrowsWhenSeekFails() - { - $s = new NoSeekStream(Psr7\stream_for('foobazbar')); - $s->read(2); - Psr7\hash($s, 'md5'); - } - - public function testCalculatesHashSeeksToOriginalPosition() - { - $s = Psr7\stream_for('foobazbar'); - $s->seek(4); - $this->assertEquals(md5('foobazbar'), Psr7\hash($s, 'md5')); - $this->assertEquals(4, $s->tell()); - } - - public function testOpensFilesSuccessfully() - { - $r = Psr7\try_fopen(__FILE__, 'r'); - $this->assertInternalType('resource', $r); - fclose($r); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Unable to open /path/to/does/not/exist using mode r - */ - public function testThrowsExceptionNotWarning() - { - Psr7\try_fopen('/path/to/does/not/exist', 'r'); - } - - public function parseQueryProvider() - { - return [ - // Does not need to parse when the string is empty - ['', []], - // Can parse mult-values items - ['q=a&q=b', ['q' => ['a', 'b']]], - // Can parse multi-valued items that use numeric indices - ['q[0]=a&q[1]=b', ['q[0]' => 'a', 'q[1]' => 'b']], - // Can parse duplicates and does not include numeric indices - ['q[]=a&q[]=b', ['q[]' => ['a', 'b']]], - // Ensures that the value of "q" is an array even though one value - ['q[]=a', ['q[]' => 'a']], - // Does not modify "." to "_" like PHP's parse_str() - ['q.a=a&q.b=b', ['q.a' => 'a', 'q.b' => 'b']], - // Can decode %20 to " " - ['q%20a=a%20b', ['q a' => 'a b']], - // Can parse funky strings with no values by assigning each to null - ['q&a', ['q' => null, 'a' => null]], - // Does not strip trailing equal signs - ['data=abc=', ['data' => 'abc=']], - // Can store duplicates without affecting other values - ['foo=a&foo=b&?µ=c', ['foo' => ['a', 'b'], '?µ' => 'c']], - // Sets value to null when no "=" is present - ['foo', ['foo' => null]], - // Preserves "0" keys. - ['0', ['0' => null]], - // Sets the value to an empty string when "=" is present - ['0=', ['0' => '']], - // Preserves falsey keys - ['var=0', ['var' => '0']], - ['a[b][c]=1&a[b][c]=2', ['a[b][c]' => ['1', '2']]], - ['a[b]=c&a[d]=e', ['a[b]' => 'c', 'a[d]' => 'e']], - // Ensure it doesn't leave things behind with repeated values - // Can parse mult-values items - ['q=a&q=b&q=c', ['q' => ['a', 'b', 'c']]], - ]; - } - - /** - * @dataProvider parseQueryProvider - */ - public function testParsesQueries($input, $output) - { - $result = Psr7\parse_query($input); - $this->assertSame($output, $result); - } - - public function testDoesNotDecode() - { - $str = 'foo%20=bar'; - $data = Psr7\parse_query($str, false); - $this->assertEquals(['foo%20' => 'bar'], $data); - } - - /** - * @dataProvider parseQueryProvider - */ - public function testParsesAndBuildsQueries($input, $output) - { - $result = Psr7\parse_query($input, false); - $this->assertSame($input, Psr7\build_query($result, false)); - } - - public function testEncodesWithRfc1738() - { - $str = Psr7\build_query(['foo bar' => 'baz+'], PHP_QUERY_RFC1738); - $this->assertEquals('foo+bar=baz%2B', $str); - } - - public function testEncodesWithRfc3986() - { - $str = Psr7\build_query(['foo bar' => 'baz+'], PHP_QUERY_RFC3986); - $this->assertEquals('foo%20bar=baz%2B', $str); - } - - public function testDoesNotEncode() - { - $str = Psr7\build_query(['foo bar' => 'baz+'], false); - $this->assertEquals('foo bar=baz+', $str); - } - - public function testCanControlDecodingType() - { - $result = Psr7\parse_query('var=foo+bar', PHP_QUERY_RFC3986); - $this->assertEquals('foo+bar', $result['var']); - $result = Psr7\parse_query('var=foo+bar', PHP_QUERY_RFC1738); - $this->assertEquals('foo bar', $result['var']); - } - - public function testParsesRequestMessages() - { - $req = "GET /abc HTTP/1.0\r\nHost: foo.com\r\nFoo: Bar\r\nBaz: Bam\r\nBaz: Qux\r\n\r\nTest"; - $request = Psr7\parse_request($req); - $this->assertEquals('GET', $request->getMethod()); - $this->assertEquals('/abc', $request->getRequestTarget()); - $this->assertEquals('1.0', $request->getProtocolVersion()); - $this->assertEquals('foo.com', $request->getHeaderLine('Host')); - $this->assertEquals('Bar', $request->getHeaderLine('Foo')); - $this->assertEquals('Bam, Qux', $request->getHeaderLine('Baz')); - $this->assertEquals('Test', (string) $request->getBody()); - $this->assertEquals('http://foo.com/abc', (string) $request->getUri()); - } - - public function testParsesRequestMessagesWithHttpsScheme() - { - $req = "PUT /abc?baz=bar HTTP/1.1\r\nHost: foo.com:443\r\n\r\n"; - $request = Psr7\parse_request($req); - $this->assertEquals('PUT', $request->getMethod()); - $this->assertEquals('/abc?baz=bar', $request->getRequestTarget()); - $this->assertEquals('1.1', $request->getProtocolVersion()); - $this->assertEquals('foo.com:443', $request->getHeaderLine('Host')); - $this->assertEquals('', (string) $request->getBody()); - $this->assertEquals('https://foo.com/abc?baz=bar', (string) $request->getUri()); - } - - public function testParsesRequestMessagesWithUriWhenHostIsNotFirst() - { - $req = "PUT / HTTP/1.1\r\nFoo: Bar\r\nHost: foo.com\r\n\r\n"; - $request = Psr7\parse_request($req); - $this->assertEquals('PUT', $request->getMethod()); - $this->assertEquals('/', $request->getRequestTarget()); - $this->assertEquals('http://foo.com/', (string) $request->getUri()); - } - - public function testParsesRequestMessagesWithFullUri() - { - $req = "GET https://www.google.com:443/search?q=foobar HTTP/1.1\r\nHost: www.google.com\r\n\r\n"; - $request = Psr7\parse_request($req); - $this->assertEquals('GET', $request->getMethod()); - $this->assertEquals('https://www.google.com:443/search?q=foobar', $request->getRequestTarget()); - $this->assertEquals('1.1', $request->getProtocolVersion()); - $this->assertEquals('www.google.com', $request->getHeaderLine('Host')); - $this->assertEquals('', (string) $request->getBody()); - $this->assertEquals('https://www.google.com/search?q=foobar', (string) $request->getUri()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesRequestMessages() - { - Psr7\parse_request("HTTP/1.1 200 OK\r\n\r\n"); - } - - public function testParsesResponseMessages() - { - $res = "HTTP/1.0 200 OK\r\nFoo: Bar\r\nBaz: Bam\r\nBaz: Qux\r\n\r\nTest"; - $response = Psr7\parse_response($res); - $this->assertEquals(200, $response->getStatusCode()); - $this->assertEquals('OK', $response->getReasonPhrase()); - $this->assertEquals('1.0', $response->getProtocolVersion()); - $this->assertEquals('Bar', $response->getHeaderLine('Foo')); - $this->assertEquals('Bam, Qux', $response->getHeaderLine('Baz')); - $this->assertEquals('Test', (string) $response->getBody()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesResponseMessages() - { - Psr7\parse_response("GET / HTTP/1.1\r\n\r\n"); - } - - public function testDetermineMimetype() - { - $this->assertNull(Psr7\mimetype_from_extension('not-a-real-extension')); - $this->assertEquals( - 'application/json', - Psr7\mimetype_from_extension('json') - ); - $this->assertEquals( - 'image/jpeg', - Psr7\mimetype_from_filename('/tmp/images/IMG034821.JPEG') - ); - } - - public function testCreatesUriForValue() - { - $this->assertInstanceOf('GuzzleHttp\Psr7\Uri', Psr7\uri_for('/foo')); - $this->assertInstanceOf( - 'GuzzleHttp\Psr7\Uri', - Psr7\uri_for(new Psr7\Uri('/foo')) - ); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesUri() - { - Psr7\uri_for([]); - } - - public function testKeepsPositionOfResource() - { - $h = fopen(__FILE__, 'r'); - fseek($h, 10); - $stream = Psr7\stream_for($h); - $this->assertEquals(10, $stream->tell()); - $stream->close(); - } - - public function testCreatesWithFactory() - { - $stream = Psr7\stream_for('foo'); - $this->assertInstanceOf('GuzzleHttp\Psr7\Stream', $stream); - $this->assertEquals('foo', $stream->getContents()); - $stream->close(); - } - - public function testFactoryCreatesFromEmptyString() - { - $s = Psr7\stream_for(); - $this->assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - } - - public function testFactoryCreatesFromNull() - { - $s = Psr7\stream_for(null); - $this->assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - } - - public function testFactoryCreatesFromResource() - { - $r = fopen(__FILE__, 'r'); - $s = Psr7\stream_for($r); - $this->assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - $this->assertSame(file_get_contents(__FILE__), (string) $s); - } - - public function testFactoryCreatesFromObjectWithToString() - { - $r = new HasToString(); - $s = Psr7\stream_for($r); - $this->assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - $this->assertEquals('foo', (string) $s); - } - - public function testCreatePassesThrough() - { - $s = Psr7\stream_for('foo'); - $this->assertSame($s, Psr7\stream_for($s)); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testThrowsExceptionForUnknown() - { - Psr7\stream_for(new \stdClass()); - } - - public function testReturnsCustomMetadata() - { - $s = Psr7\stream_for('foo', ['metadata' => ['hwm' => 3]]); - $this->assertEquals(3, $s->getMetadata('hwm')); - $this->assertArrayHasKey('hwm', $s->getMetadata()); - } - - public function testCanSetSize() - { - $s = Psr7\stream_for('', ['size' => 10]); - $this->assertEquals(10, $s->getSize()); - } - - public function testCanCreateIteratorBasedStream() - { - $a = new \ArrayIterator(['foo', 'bar', '123']); - $p = Psr7\stream_for($a); - $this->assertInstanceOf('GuzzleHttp\Psr7\PumpStream', $p); - $this->assertEquals('foo', $p->read(3)); - $this->assertFalse($p->eof()); - $this->assertEquals('b', $p->read(1)); - $this->assertEquals('a', $p->read(1)); - $this->assertEquals('r12', $p->read(3)); - $this->assertFalse($p->eof()); - $this->assertEquals('3', $p->getContents()); - $this->assertTrue($p->eof()); - $this->assertEquals(9, $p->tell()); - } - - public function testConvertsRequestsToStrings() - { - $request = new Psr7\Request('PUT', 'http://foo.com/hi?123', [ - 'Baz' => 'bar', - 'Qux' => ' ipsum' - ], 'hello', '1.0'); - $this->assertEquals( - "PUT /hi?123 HTTP/1.0\r\nHost: foo.com\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\str($request) - ); - } - - public function testConvertsResponsesToStrings() - { - $response = new Psr7\Response(200, [ - 'Baz' => 'bar', - 'Qux' => ' ipsum' - ], 'hello', '1.0', 'FOO'); - $this->assertEquals( - "HTTP/1.0 200 FOO\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\str($response) - ); - } - - public function parseParamsProvider() - { - $res1 = array( - array( - '', - 'rel' => 'front', - 'type' => 'image/jpeg', - ), - array( - '', - 'rel' => 'back', - 'type' => 'image/jpeg', - ), - ); - return array( - array( - '; rel="front"; type="image/jpeg", ; rel=back; type="image/jpeg"', - $res1 - ), - array( - '; rel="front"; type="image/jpeg",; rel=back; type="image/jpeg"', - $res1 - ), - array( - 'foo="baz"; bar=123, boo, test="123", foobar="foo;bar"', - array( - array('foo' => 'baz', 'bar' => '123'), - array('boo'), - array('test' => '123'), - array('foobar' => 'foo;bar') - ) - ), - array( - '; rel="side"; type="image/jpeg",; rel=side; type="image/jpeg"', - array( - array('', 'rel' => 'side', 'type' => 'image/jpeg'), - array('', 'rel' => 'side', 'type' => 'image/jpeg') - ) - ), - array( - '', - array() - ) - ); - } - /** - * @dataProvider parseParamsProvider - */ - public function testParseParams($header, $result) - { - $this->assertEquals($result, Psr7\parse_header($header)); - } - - public function testParsesArrayHeaders() - { - $header = ['a, b', 'c', 'd, e']; - $this->assertEquals(['a', 'b', 'c', 'd', 'e'], Psr7\normalize_header($header)); - } - - public function testRewindsBody() - { - $body = Psr7\stream_for('abc'); - $res = new Psr7\Response(200, [], $body); - Psr7\rewind_body($res); - $this->assertEquals(0, $body->tell()); - $body->rewind(1); - Psr7\rewind_body($res); - $this->assertEquals(0, $body->tell()); - } - - /** - * @expectedException \RuntimeException - */ - public function testThrowsWhenBodyCannotBeRewound() - { - $body = Psr7\stream_for('abc'); - $body->read(1); - $body = FnStream::decorate($body, [ - 'rewind' => function () { throw new \RuntimeException('a'); } - ]); - $res = new Psr7\Response(200, [], $body); - Psr7\rewind_body($res); - } - - public function testCanModifyRequestWithUri() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\modify_request($r1, [ - 'uri' => new Psr7\Uri('http://www.foo.com') - ]); - $this->assertEquals('http://www.foo.com', (string) $r2->getUri()); - $this->assertEquals('www.foo.com', (string) $r2->getHeaderLine('host')); - } - - public function testCanModifyRequestWithCaseInsensitiveHeader() - { - $r1 = new Psr7\Request('GET', 'http://foo.com', ['User-Agent' => 'foo']); - $r2 = Psr7\modify_request($r1, ['set_headers' => ['User-agent' => 'bar']]); - $this->assertEquals('bar', $r2->getHeaderLine('User-Agent')); - $this->assertEquals('bar', $r2->getHeaderLine('User-agent')); - } - - public function testReturnsAsIsWhenNoChanges() - { - $request = new Psr7\Request('GET', 'http://foo.com'); - $this->assertSame($request, Psr7\modify_request($request, [])); - } - - public function testReturnsUriAsIsWhenNoChanges() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\modify_request($r1, ['set_headers' => ['foo' => 'bar']]); - $this->assertNotSame($r1, $r2); - $this->assertEquals('bar', $r2->getHeaderLine('foo')); - } - - public function testRemovesHeadersFromMessage() - { - $r1 = new Psr7\Request('GET', 'http://foo.com', ['foo' => 'bar']); - $r2 = Psr7\modify_request($r1, ['remove_headers' => ['foo']]); - $this->assertNotSame($r1, $r2); - $this->assertFalse($r2->hasHeader('foo')); - } - - public function testAddsQueryToUri() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\modify_request($r1, ['query' => 'foo=bar']); - $this->assertNotSame($r1, $r2); - $this->assertEquals('foo=bar', $r2->getUri()->getQuery()); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php b/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php deleted file mode 100644 index 927fc0b7b..000000000 --- a/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php +++ /dev/null @@ -1,16 +0,0 @@ -assertEquals('test', (string) $b); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php b/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php deleted file mode 100644 index fdef1423d..000000000 --- a/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php +++ /dev/null @@ -1,64 +0,0 @@ -fname = tempnam('/tmp', 'tfile'); - - if (file_exists($this->fname)) { - unlink($this->fname); - } - } - - public function tearDown() - { - if (file_exists($this->fname)) { - unlink($this->fname); - } - } - - public function testOpensLazily() - { - $l = new LazyOpenStream($this->fname, 'w+'); - $l->write('foo'); - $this->assertInternalType('array', $l->getMetadata()); - $this->assertFileExists($this->fname); - $this->assertEquals('foo', file_get_contents($this->fname)); - $this->assertEquals('foo', (string) $l); - } - - public function testProxiesToFile() - { - file_put_contents($this->fname, 'foo'); - $l = new LazyOpenStream($this->fname, 'r'); - $this->assertEquals('foo', $l->read(4)); - $this->assertTrue($l->eof()); - $this->assertEquals(3, $l->tell()); - $this->assertTrue($l->isReadable()); - $this->assertTrue($l->isSeekable()); - $this->assertFalse($l->isWritable()); - $l->seek(1); - $this->assertEquals('oo', $l->getContents()); - $this->assertEquals('foo', (string) $l); - $this->assertEquals(3, $l->getSize()); - $this->assertInternalType('array', $l->getMetadata()); - $l->close(); - } - - public function testDetachesUnderlyingStream() - { - file_put_contents($this->fname, 'foo'); - $l = new LazyOpenStream($this->fname, 'r'); - $r = $l->detach(); - $this->assertInternalType('resource', $r); - fseek($r, 0); - $this->assertEquals('foo', stream_get_contents($r)); - fclose($r); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php b/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php deleted file mode 100644 index 2198b7a9b..000000000 --- a/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php +++ /dev/null @@ -1,166 +0,0 @@ -decorated = Psr7\stream_for(fopen(__FILE__, 'r')); - $this->body = new LimitStream($this->decorated, 10, 3); - } - - public function testReturnsSubset() - { - $body = new LimitStream(Psr7\stream_for('foo'), -1, 1); - $this->assertEquals('oo', (string) $body); - $this->assertTrue($body->eof()); - $body->seek(0); - $this->assertFalse($body->eof()); - $this->assertEquals('oo', $body->read(100)); - $this->assertSame('', $body->read(1)); - $this->assertTrue($body->eof()); - } - - public function testReturnsSubsetWhenCastToString() - { - $body = Psr7\stream_for('foo_baz_bar'); - $limited = new LimitStream($body, 3, 4); - $this->assertEquals('baz', (string) $limited); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Unable to seek to stream position 10 with whence 0 - */ - public function testEnsuresPositionCanBeekSeekedTo() - { - new LimitStream(Psr7\stream_for(''), 0, 10); - } - - public function testReturnsSubsetOfEmptyBodyWhenCastToString() - { - $body = Psr7\stream_for('01234567891234'); - $limited = new LimitStream($body, 0, 10); - $this->assertEquals('', (string) $limited); - } - - public function testReturnsSpecificSubsetOBodyWhenCastToString() - { - $body = Psr7\stream_for('0123456789abcdef'); - $limited = new LimitStream($body, 3, 10); - $this->assertEquals('abc', (string) $limited); - } - - public function testSeeksWhenConstructed() - { - $this->assertEquals(0, $this->body->tell()); - $this->assertEquals(3, $this->decorated->tell()); - } - - public function testAllowsBoundedSeek() - { - $this->body->seek(100); - $this->assertEquals(10, $this->body->tell()); - $this->assertEquals(13, $this->decorated->tell()); - $this->body->seek(0); - $this->assertEquals(0, $this->body->tell()); - $this->assertEquals(3, $this->decorated->tell()); - try { - $this->body->seek(-10); - $this->fail(); - } catch (\RuntimeException $e) {} - $this->assertEquals(0, $this->body->tell()); - $this->assertEquals(3, $this->decorated->tell()); - $this->body->seek(5); - $this->assertEquals(5, $this->body->tell()); - $this->assertEquals(8, $this->decorated->tell()); - // Fail - try { - $this->body->seek(1000, SEEK_END); - $this->fail(); - } catch (\RuntimeException $e) {} - } - - public function testReadsOnlySubsetOfData() - { - $data = $this->body->read(100); - $this->assertEquals(10, strlen($data)); - $this->assertSame('', $this->body->read(1000)); - - $this->body->setOffset(10); - $newData = $this->body->read(100); - $this->assertEquals(10, strlen($newData)); - $this->assertNotSame($data, $newData); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Could not seek to stream offset 2 - */ - public function testThrowsWhenCurrentGreaterThanOffsetSeek() - { - $a = Psr7\stream_for('foo_bar'); - $b = new NoSeekStream($a); - $c = new LimitStream($b); - $a->getContents(); - $c->setOffset(2); - } - - public function testCanGetContentsWithoutSeeking() - { - $a = Psr7\stream_for('foo_bar'); - $b = new NoSeekStream($a); - $c = new LimitStream($b); - $this->assertEquals('foo_bar', $c->getContents()); - } - - public function testClaimsConsumedWhenReadLimitIsReached() - { - $this->assertFalse($this->body->eof()); - $this->body->read(1000); - $this->assertTrue($this->body->eof()); - } - - public function testContentLengthIsBounded() - { - $this->assertEquals(10, $this->body->getSize()); - } - - public function testGetContentsIsBasedOnSubset() - { - $body = new LimitStream(Psr7\stream_for('foobazbar'), 3, 3); - $this->assertEquals('baz', $body->getContents()); - } - - public function testReturnsNullIfSizeCannotBeDetermined() - { - $a = new FnStream([ - 'getSize' => function () { return null; }, - 'tell' => function () { return 0; }, - ]); - $b = new LimitStream($a); - $this->assertNull($b->getSize()); - } - - public function testLengthLessOffsetWhenNoLimitSize() - { - $a = Psr7\stream_for('foo_bar'); - $b = new LimitStream($a, -1, 4); - $this->assertEquals(3, $b->getSize()); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/MultipartStreamTest.php b/vendor/guzzlehttp/psr7/tests/MultipartStreamTest.php deleted file mode 100644 index 61edb067a..000000000 --- a/vendor/guzzlehttp/psr7/tests/MultipartStreamTest.php +++ /dev/null @@ -1,214 +0,0 @@ -assertNotEmpty($b->getBoundary()); - } - - public function testCanProvideBoundary() - { - $b = new MultipartStream([], 'foo'); - $this->assertEquals('foo', $b->getBoundary()); - } - - public function testIsNotWritable() - { - $b = new MultipartStream(); - $this->assertFalse($b->isWritable()); - } - - public function testCanCreateEmptyStream() - { - $b = new MultipartStream(); - $boundary = $b->getBoundary(); - $this->assertSame("--{$boundary}--\r\n", $b->getContents()); - $this->assertSame(strlen($boundary) + 6, $b->getSize()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesFilesArrayElement() - { - new MultipartStream([['foo' => 'bar']]); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresFileHasName() - { - new MultipartStream([['contents' => 'bar']]); - } - - public function testSerializesFields() - { - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => 'bar' - ], - [ - 'name' => 'baz', - 'contents' => 'bam' - ] - ], 'boundary'); - $this->assertEquals( - "--boundary\r\nContent-Disposition: form-data; name=\"foo\"\r\nContent-Length: 3\r\n\r\n" - . "bar\r\n--boundary\r\nContent-Disposition: form-data; name=\"baz\"\r\nContent-Length: 3" - . "\r\n\r\nbam\r\n--boundary--\r\n", (string) $b); - } - - public function testSerializesFiles() - { - $f1 = Psr7\FnStream::decorate(Psr7\stream_for('foo'), [ - 'getMetadata' => function () { - return '/foo/bar.txt'; - } - ]); - - $f2 = Psr7\FnStream::decorate(Psr7\stream_for('baz'), [ - 'getMetadata' => function () { - return '/foo/baz.jpg'; - } - ]); - - $f3 = Psr7\FnStream::decorate(Psr7\stream_for('bar'), [ - 'getMetadata' => function () { - return '/foo/bar.gif'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1 - ], - [ - 'name' => 'qux', - 'contents' => $f2 - ], - [ - 'name' => 'qux', - 'contents' => $f3 - ], - ], 'boundary'); - - $expected = <<assertEquals($expected, str_replace("\r", '', $b)); - } - - public function testSerializesFilesWithCustomHeaders() - { - $f1 = Psr7\FnStream::decorate(Psr7\stream_for('foo'), [ - 'getMetadata' => function () { - return '/foo/bar.txt'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1, - 'headers' => [ - 'x-foo' => 'bar', - 'content-disposition' => 'custom' - ] - ] - ], 'boundary'); - - $expected = <<assertEquals($expected, str_replace("\r", '', $b)); - } - - public function testSerializesFilesWithCustomHeadersAndMultipleValues() - { - $f1 = Psr7\FnStream::decorate(Psr7\stream_for('foo'), [ - 'getMetadata' => function () { - return '/foo/bar.txt'; - } - ]); - - $f2 = Psr7\FnStream::decorate(Psr7\stream_for('baz'), [ - 'getMetadata' => function () { - return '/foo/baz.jpg'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1, - 'headers' => [ - 'x-foo' => 'bar', - 'content-disposition' => 'custom' - ] - ], - [ - 'name' => 'foo', - 'contents' => $f2, - 'headers' => ['cOntenT-Type' => 'custom'], - ] - ], 'boundary'); - - $expected = <<assertEquals($expected, str_replace("\r", '', $b)); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/NoSeekStreamTest.php b/vendor/guzzlehttp/psr7/tests/NoSeekStreamTest.php deleted file mode 100644 index a309317bd..000000000 --- a/vendor/guzzlehttp/psr7/tests/NoSeekStreamTest.php +++ /dev/null @@ -1,40 +0,0 @@ -getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'seek']) - ->getMockForAbstractClass(); - $s->expects($this->never())->method('seek'); - $s->expects($this->never())->method('isSeekable'); - $wrapped = new NoSeekStream($s); - $this->assertFalse($wrapped->isSeekable()); - $wrapped->seek(2); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Cannot write to a non-writable stream - */ - public function testHandlesClose() - { - $s = Psr7\stream_for('foo'); - $wrapped = new NoSeekStream($s); - $wrapped->close(); - $wrapped->write('foo'); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php b/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php deleted file mode 100644 index 7358bb6e0..000000000 --- a/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php +++ /dev/null @@ -1,72 +0,0 @@ - ['foo' => 'bar'], - 'size' => 100 - ]); - - $this->assertEquals('bar', $p->getMetadata('foo')); - $this->assertEquals(['foo' => 'bar'], $p->getMetadata()); - $this->assertEquals(100, $p->getSize()); - } - - public function testCanReadFromCallable() - { - $p = Psr7\stream_for(function ($size) { - return 'a'; - }); - $this->assertEquals('a', $p->read(1)); - $this->assertEquals(1, $p->tell()); - $this->assertEquals('aaaaa', $p->read(5)); - $this->assertEquals(6, $p->tell()); - } - - public function testStoresExcessDataInBuffer() - { - $called = []; - $p = Psr7\stream_for(function ($size) use (&$called) { - $called[] = $size; - return 'abcdef'; - }); - $this->assertEquals('a', $p->read(1)); - $this->assertEquals('b', $p->read(1)); - $this->assertEquals('cdef', $p->read(4)); - $this->assertEquals('abcdefabc', $p->read(9)); - $this->assertEquals([1, 9, 3], $called); - } - - public function testInifiniteStreamWrappedInLimitStream() - { - $p = Psr7\stream_for(function () { return 'a'; }); - $s = new LimitStream($p, 5); - $this->assertEquals('aaaaa', (string) $s); - } - - public function testDescribesCapabilities() - { - $p = Psr7\stream_for(function () {}); - $this->assertTrue($p->isReadable()); - $this->assertFalse($p->isSeekable()); - $this->assertFalse($p->isWritable()); - $this->assertNull($p->getSize()); - $this->assertEquals('', $p->getContents()); - $this->assertEquals('', (string) $p); - $p->close(); - $this->assertEquals('', $p->read(10)); - $this->assertTrue($p->eof()); - - try { - $this->assertFalse($p->write('aa')); - $this->fail(); - } catch (\RuntimeException $e) {} - } -} diff --git a/vendor/guzzlehttp/psr7/tests/RequestTest.php b/vendor/guzzlehttp/psr7/tests/RequestTest.php deleted file mode 100644 index 9defe68d9..000000000 --- a/vendor/guzzlehttp/psr7/tests/RequestTest.php +++ /dev/null @@ -1,157 +0,0 @@ -assertEquals('/', (string) $r->getUri()); - } - - public function testRequestUriMayBeUri() - { - $uri = new Uri('/'); - $r = new Request('GET', $uri); - $this->assertSame($uri, $r->getUri()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidateRequestUri() - { - new Request('GET', true); - } - - public function testCanConstructWithBody() - { - $r = new Request('GET', '/', [], 'baz'); - $this->assertEquals('baz', (string) $r->getBody()); - } - - public function testCapitalizesMethod() - { - $r = new Request('get', '/'); - $this->assertEquals('GET', $r->getMethod()); - } - - public function testCapitalizesWithMethod() - { - $r = new Request('GET', '/'); - $this->assertEquals('PUT', $r->withMethod('put')->getMethod()); - } - - public function testWithUri() - { - $r1 = new Request('GET', '/'); - $u1 = $r1->getUri(); - $u2 = new Uri('http://www.example.com'); - $r2 = $r1->withUri($u2); - $this->assertNotSame($r1, $r2); - $this->assertSame($u2, $r2->getUri()); - $this->assertSame($u1, $r1->getUri()); - } - - public function testSameInstanceWhenSameUri() - { - $r1 = new Request('GET', 'http://foo.com'); - $r2 = $r1->withUri($r1->getUri()); - $this->assertSame($r1, $r2); - } - - public function testWithRequestTarget() - { - $r1 = new Request('GET', '/'); - $r2 = $r1->withRequestTarget('*'); - $this->assertEquals('*', $r2->getRequestTarget()); - $this->assertEquals('/', $r1->getRequestTarget()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testRequestTargetDoesNotAllowSpaces() - { - $r1 = new Request('GET', '/'); - $r1->withRequestTarget('/foo bar'); - } - - public function testRequestTargetDefaultsToSlash() - { - $r1 = new Request('GET', ''); - $this->assertEquals('/', $r1->getRequestTarget()); - $r2 = new Request('GET', '*'); - $this->assertEquals('*', $r2->getRequestTarget()); - $r3 = new Request('GET', 'http://foo.com/bar baz/'); - $this->assertEquals('/bar%20baz/', $r3->getRequestTarget()); - } - - public function testBuildsRequestTarget() - { - $r1 = new Request('GET', 'http://foo.com/baz?bar=bam'); - $this->assertEquals('/baz?bar=bam', $r1->getRequestTarget()); - } - - public function testHostIsAddedFirst() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', ['Foo' => 'Bar']); - $this->assertEquals([ - 'Host' => ['foo.com'], - 'Foo' => ['Bar'] - ], $r->getHeaders()); - } - - public function testCanGetHeaderAsCsv() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', [ - 'Foo' => ['a', 'b', 'c'] - ]); - $this->assertEquals('a, b, c', $r->getHeaderLine('Foo')); - $this->assertEquals('', $r->getHeaderLine('Bar')); - } - - public function testHostIsNotOverwrittenWhenPreservingHost() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', ['Host' => 'a.com']); - $this->assertEquals(['Host' => ['a.com']], $r->getHeaders()); - $r2 = $r->withUri(new Uri('http://www.foo.com/bar'), true); - $this->assertEquals('a.com', $r2->getHeaderLine('Host')); - } - - public function testOverridesHostWithUri() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam'); - $this->assertEquals(['Host' => ['foo.com']], $r->getHeaders()); - $r2 = $r->withUri(new Uri('http://www.baz.com/bar')); - $this->assertEquals('www.baz.com', $r2->getHeaderLine('Host')); - } - - public function testAggregatesHeaders() - { - $r = new Request('GET', 'http://foo.com', [ - 'ZOO' => 'zoobar', - 'zoo' => ['foobar', 'zoobar'] - ]); - $this->assertEquals('zoobar, foobar, zoobar', $r->getHeaderLine('zoo')); - } - - public function testAddsPortToHeader() - { - $r = new Request('GET', 'http://foo.com:8124/bar'); - $this->assertEquals('foo.com:8124', $r->getHeaderLine('host')); - } - - public function testAddsPortToHeaderAndReplacePreviousPort() - { - $r = new Request('GET', 'http://foo.com:8124/bar'); - $r = $r->withUri(new Uri('http://foo.com:8125/bar')); - $this->assertEquals('foo.com:8125', $r->getHeaderLine('host')); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/ResponseTest.php b/vendor/guzzlehttp/psr7/tests/ResponseTest.php deleted file mode 100644 index 0ce3e21e0..000000000 --- a/vendor/guzzlehttp/psr7/tests/ResponseTest.php +++ /dev/null @@ -1,146 +0,0 @@ -assertSame(200, $r->getStatusCode()); - $this->assertEquals('OK', $r->getReasonPhrase()); - } - - public function testCanGiveCustomReason() - { - $r = new Response(200, [], null, '1.1', 'bar'); - $this->assertEquals('bar', $r->getReasonPhrase()); - } - - public function testCanGiveCustomProtocolVersion() - { - $r = new Response(200, [], null, '1000'); - $this->assertEquals('1000', $r->getProtocolVersion()); - } - - public function testCanCreateNewResponseWithStatusAndNoReason() - { - $r = new Response(200); - $r2 = $r->withStatus(201); - $this->assertEquals(200, $r->getStatusCode()); - $this->assertEquals('OK', $r->getReasonPhrase()); - $this->assertEquals(201, $r2->getStatusCode()); - $this->assertEquals('Created', $r2->getReasonPhrase()); - } - - public function testCanCreateNewResponseWithStatusAndReason() - { - $r = new Response(200); - $r2 = $r->withStatus(201, 'Foo'); - $this->assertEquals(200, $r->getStatusCode()); - $this->assertEquals('OK', $r->getReasonPhrase()); - $this->assertEquals(201, $r2->getStatusCode()); - $this->assertEquals('Foo', $r2->getReasonPhrase()); - } - - public function testCreatesResponseWithAddedHeaderArray() - { - $r = new Response(); - $r2 = $r->withAddedHeader('foo', ['baz', 'bar']); - $this->assertFalse($r->hasHeader('foo')); - $this->assertEquals('baz, bar', $r2->getHeaderLine('foo')); - } - - public function testReturnsIdentityWhenRemovingMissingHeader() - { - $r = new Response(); - $this->assertSame($r, $r->withoutHeader('foo')); - } - - public function testAlwaysReturnsBody() - { - $r = new Response(); - $this->assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - } - - public function testCanSetHeaderAsArray() - { - $r = new Response(200, [ - 'foo' => ['baz ', ' bar '] - ]); - $this->assertEquals('baz, bar', $r->getHeaderLine('foo')); - $this->assertEquals(['baz', 'bar'], $r->getHeader('foo')); - } - - public function testSameInstanceWhenSameBody() - { - $r = new Response(200, [], 'foo'); - $b = $r->getBody(); - $this->assertSame($r, $r->withBody($b)); - } - - public function testNewInstanceWhenNewBody() - { - $r = new Response(200, [], 'foo'); - $b2 = Psr7\stream_for('abc'); - $this->assertNotSame($r, $r->withBody($b2)); - } - - public function testSameInstanceWhenSameProtocol() - { - $r = new Response(200); - $this->assertSame($r, $r->withProtocolVersion('1.1')); - } - - public function testNewInstanceWhenNewProtocol() - { - $r = new Response(200); - $this->assertNotSame($r, $r->withProtocolVersion('1.0')); - } - - public function testNewInstanceWhenRemovingHeader() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withoutHeader('Foo'); - $this->assertNotSame($r, $r2); - $this->assertFalse($r2->hasHeader('foo')); - } - - public function testNewInstanceWhenAddingHeader() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withAddedHeader('Foo', 'Baz'); - $this->assertNotSame($r, $r2); - $this->assertEquals('Bar, Baz', $r2->getHeaderLine('foo')); - } - - public function testNewInstanceWhenAddingHeaderThatWasNotThereBefore() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withAddedHeader('Baz', 'Bam'); - $this->assertNotSame($r, $r2); - $this->assertEquals('Bam', $r2->getHeaderLine('Baz')); - $this->assertEquals('Bar', $r2->getHeaderLine('Foo')); - } - - public function testRemovesPreviouslyAddedHeaderOfDifferentCase() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withHeader('foo', 'Bam'); - $this->assertNotSame($r, $r2); - $this->assertEquals('Bam', $r2->getHeaderLine('Foo')); - } - - public function testBodyConsistent() - { - $r = new Response(200, [], '0'); - $this->assertEquals('0', (string)$r->getBody()); - } - -} diff --git a/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php b/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php deleted file mode 100644 index 682079e0c..000000000 --- a/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php +++ /dev/null @@ -1,137 +0,0 @@ -c = fopen('php://temp', 'r+'); - fwrite($this->c, 'foo'); - fseek($this->c, 0); - $this->a = Psr7\stream_for($this->c); - $this->b = new Str($this->a); - } - - public function testCatchesExceptionsWhenCastingToString() - { - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['read']) - ->getMockForAbstractClass(); - $s->expects($this->once()) - ->method('read') - ->will($this->throwException(new \Exception('foo'))); - $msg = ''; - set_error_handler(function ($errNo, $str) use (&$msg) { $msg = $str; }); - echo new Str($s); - restore_error_handler(); - $this->assertContains('foo', $msg); - } - - public function testToString() - { - $this->assertEquals('foo', (string) $this->b); - } - - public function testHasSize() - { - $this->assertEquals(3, $this->b->getSize()); - } - - public function testReads() - { - $this->assertEquals('foo', $this->b->read(10)); - } - - public function testCheckMethods() - { - $this->assertEquals($this->a->isReadable(), $this->b->isReadable()); - $this->assertEquals($this->a->isWritable(), $this->b->isWritable()); - $this->assertEquals($this->a->isSeekable(), $this->b->isSeekable()); - } - - public function testSeeksAndTells() - { - $this->b->seek(1); - $this->assertEquals(1, $this->a->tell()); - $this->assertEquals(1, $this->b->tell()); - $this->b->seek(0); - $this->assertEquals(0, $this->a->tell()); - $this->assertEquals(0, $this->b->tell()); - $this->b->seek(0, SEEK_END); - $this->assertEquals(3, $this->a->tell()); - $this->assertEquals(3, $this->b->tell()); - } - - public function testGetsContents() - { - $this->assertEquals('foo', $this->b->getContents()); - $this->assertEquals('', $this->b->getContents()); - $this->b->seek(1); - $this->assertEquals('oo', $this->b->getContents(1)); - } - - public function testCloses() - { - $this->b->close(); - $this->assertFalse(is_resource($this->c)); - } - - public function testDetaches() - { - $this->b->detach(); - $this->assertFalse($this->b->isReadable()); - } - - public function testWrapsMetadata() - { - $this->assertSame($this->b->getMetadata(), $this->a->getMetadata()); - $this->assertSame($this->b->getMetadata('uri'), $this->a->getMetadata('uri')); - } - - public function testWrapsWrites() - { - $this->b->seek(0, SEEK_END); - $this->b->write('foo'); - $this->assertEquals('foofoo', (string) $this->a); - } - - /** - * @expectedException \UnexpectedValueException - */ - public function testThrowsWithInvalidGetter() - { - $this->b->foo; - } - - /** - * @expectedException \BadMethodCallException - */ - public function testThrowsWhenGetterNotImplemented() - { - $s = new BadStream(); - $s->stream; - } -} - -class BadStream -{ - use StreamDecoratorTrait; - - public function __construct() {} -} diff --git a/vendor/guzzlehttp/psr7/tests/StreamTest.php b/vendor/guzzlehttp/psr7/tests/StreamTest.php deleted file mode 100644 index 4fe92cc6b..000000000 --- a/vendor/guzzlehttp/psr7/tests/StreamTest.php +++ /dev/null @@ -1,161 +0,0 @@ -assertTrue($stream->isReadable()); - $this->assertTrue($stream->isWritable()); - $this->assertTrue($stream->isSeekable()); - $this->assertEquals('php://temp', $stream->getMetadata('uri')); - $this->assertInternalType('array', $stream->getMetadata()); - $this->assertEquals(4, $stream->getSize()); - $this->assertFalse($stream->eof()); - $stream->close(); - } - - public function testStreamClosesHandleOnDestruct() - { - $handle = fopen('php://temp', 'r'); - $stream = new Stream($handle); - unset($stream); - $this->assertFalse(is_resource($handle)); - } - - public function testConvertsToString() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - $this->assertEquals('data', (string) $stream); - $this->assertEquals('data', (string) $stream); - $stream->close(); - } - - public function testGetsContents() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - $this->assertEquals('', $stream->getContents()); - $stream->seek(0); - $this->assertEquals('data', $stream->getContents()); - $this->assertEquals('', $stream->getContents()); - } - - public function testChecksEof() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - $this->assertFalse($stream->eof()); - $stream->read(4); - $this->assertTrue($stream->eof()); - $stream->close(); - } - - public function testGetSize() - { - $size = filesize(__FILE__); - $handle = fopen(__FILE__, 'r'); - $stream = new Stream($handle); - $this->assertEquals($size, $stream->getSize()); - // Load from cache - $this->assertEquals($size, $stream->getSize()); - $stream->close(); - } - - public function testEnsuresSizeIsConsistent() - { - $h = fopen('php://temp', 'w+'); - $this->assertEquals(3, fwrite($h, 'foo')); - $stream = new Stream($h); - $this->assertEquals(3, $stream->getSize()); - $this->assertEquals(4, $stream->write('test')); - $this->assertEquals(7, $stream->getSize()); - $this->assertEquals(7, $stream->getSize()); - $stream->close(); - } - - public function testProvidesStreamPosition() - { - $handle = fopen('php://temp', 'w+'); - $stream = new Stream($handle); - $this->assertEquals(0, $stream->tell()); - $stream->write('foo'); - $this->assertEquals(3, $stream->tell()); - $stream->seek(1); - $this->assertEquals(1, $stream->tell()); - $this->assertSame(ftell($handle), $stream->tell()); - $stream->close(); - } - - public function testCanDetachStream() - { - $r = fopen('php://temp', 'w+'); - $stream = new Stream($r); - $stream->write('foo'); - $this->assertTrue($stream->isReadable()); - $this->assertSame($r, $stream->detach()); - $stream->detach(); - - $this->assertFalse($stream->isReadable()); - $this->assertFalse($stream->isWritable()); - $this->assertFalse($stream->isSeekable()); - - $throws = function (callable $fn) use ($stream) { - try { - $fn($stream); - $this->fail(); - } catch (\Exception $e) {} - }; - - $throws(function ($stream) { $stream->read(10); }); - $throws(function ($stream) { $stream->write('bar'); }); - $throws(function ($stream) { $stream->seek(10); }); - $throws(function ($stream) { $stream->tell(); }); - $throws(function ($stream) { $stream->eof(); }); - $throws(function ($stream) { $stream->getSize(); }); - $throws(function ($stream) { $stream->getContents(); }); - $this->assertSame('', (string) $stream); - $stream->close(); - } - - public function testCloseClearProperties() - { - $handle = fopen('php://temp', 'r+'); - $stream = new Stream($handle); - $stream->close(); - - $this->assertFalse($stream->isSeekable()); - $this->assertFalse($stream->isReadable()); - $this->assertFalse($stream->isWritable()); - $this->assertNull($stream->getSize()); - $this->assertEmpty($stream->getMetadata()); - } - - public function testDoesNotThrowInToString() - { - $s = \GuzzleHttp\Psr7\stream_for('foo'); - $s = new NoSeekStream($s); - $this->assertEquals('foo', (string) $s); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php b/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php deleted file mode 100644 index 0156e5988..000000000 --- a/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php +++ /dev/null @@ -1,100 +0,0 @@ -assertSame('foo', fread($handle, 3)); - $this->assertSame(3, ftell($handle)); - $this->assertSame(3, fwrite($handle, 'bar')); - $this->assertSame(0, fseek($handle, 0)); - $this->assertSame('foobar', fread($handle, 6)); - $this->assertSame('', fread($handle, 1)); - $this->assertTrue(feof($handle)); - - // This fails on HHVM for some reason - if (!defined('HHVM_VERSION')) { - $this->assertEquals([ - 'dev' => 0, - 'ino' => 0, - 'mode' => 33206, - 'nlink' => 0, - 'uid' => 0, - 'gid' => 0, - 'rdev' => 0, - 'size' => 6, - 'atime' => 0, - 'mtime' => 0, - 'ctime' => 0, - 'blksize' => 0, - 'blocks' => 0, - 0 => 0, - 1 => 0, - 2 => 33206, - 3 => 0, - 4 => 0, - 5 => 0, - 6 => 0, - 7 => 6, - 8 => 0, - 9 => 0, - 10 => 0, - 11 => 0, - 12 => 0, - ], fstat($handle)); - } - - $this->assertTrue(fclose($handle)); - $this->assertSame('foobar', (string) $stream); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesStream() - { - $stream = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'isWritable']) - ->getMockForAbstractClass(); - $stream->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(false)); - $stream->expects($this->once()) - ->method('isWritable') - ->will($this->returnValue(false)); - StreamWrapper::getResource($stream); - } - - /** - * @expectedException \PHPUnit_Framework_Error_Warning - */ - public function testReturnsFalseWhenStreamDoesNotExist() - { - fopen('guzzle://foo', 'r'); - } - - public function testCanOpenReadonlyStream() - { - $stream = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'isWritable']) - ->getMockForAbstractClass(); - $stream->expects($this->once()) - ->method('isReadable') - ->will($this->returnValue(false)); - $stream->expects($this->once()) - ->method('isWritable') - ->will($this->returnValue(true)); - $r = StreamWrapper::getResource($stream); - $this->assertInternalType('resource', $r); - fclose($r); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/UriTest.php b/vendor/guzzlehttp/psr7/tests/UriTest.php deleted file mode 100644 index 277692072..000000000 --- a/vendor/guzzlehttp/psr7/tests/UriTest.php +++ /dev/null @@ -1,247 +0,0 @@ -assertEquals( - 'https://michael:test@test.com/path/123?q=abc#test', - (string) $uri - ); - - $this->assertEquals('test', $uri->getFragment()); - $this->assertEquals('test.com', $uri->getHost()); - $this->assertEquals('/path/123', $uri->getPath()); - $this->assertEquals(null, $uri->getPort()); - $this->assertEquals('q=abc', $uri->getQuery()); - $this->assertEquals('https', $uri->getScheme()); - $this->assertEquals('michael:test', $uri->getUserInfo()); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Unable to parse URI - */ - public function testValidatesUriCanBeParsed() - { - new Uri('///'); - } - - public function testCanTransformAndRetrievePartsIndividually() - { - $uri = (new Uri('')) - ->withFragment('#test') - ->withHost('example.com') - ->withPath('path/123') - ->withPort(8080) - ->withQuery('?q=abc') - ->withScheme('http') - ->withUserInfo('user', 'pass'); - - // Test getters. - $this->assertEquals('user:pass@example.com:8080', $uri->getAuthority()); - $this->assertEquals('test', $uri->getFragment()); - $this->assertEquals('example.com', $uri->getHost()); - $this->assertEquals('path/123', $uri->getPath()); - $this->assertEquals(8080, $uri->getPort()); - $this->assertEquals('q=abc', $uri->getQuery()); - $this->assertEquals('http', $uri->getScheme()); - $this->assertEquals('user:pass', $uri->getUserInfo()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testPortMustBeValid() - { - (new Uri(''))->withPort(100000); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testPathMustBeValid() - { - (new Uri(''))->withPath([]); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testQueryMustBeValid() - { - (new Uri(''))->withQuery(new \stdClass); - } - - public function testAllowsFalseyUrlParts() - { - $url = new Uri('http://a:1/0?0#0'); - $this->assertSame('a', $url->getHost()); - $this->assertEquals(1, $url->getPort()); - $this->assertSame('/0', $url->getPath()); - $this->assertEquals('0', (string) $url->getQuery()); - $this->assertSame('0', $url->getFragment()); - $this->assertEquals('http://a:1/0?0#0', (string) $url); - $url = new Uri(''); - $this->assertSame('', (string) $url); - $url = new Uri('0'); - $this->assertSame('0', (string) $url); - $url = new Uri('/'); - $this->assertSame('/', (string) $url); - } - - /** - * @dataProvider getResolveTestCases - */ - public function testResolvesUris($base, $rel, $expected) - { - $uri = new Uri($base); - $actual = Uri::resolve($uri, $rel); - $this->assertEquals($expected, (string) $actual); - } - - public function getResolveTestCases() - { - return [ - //[self::RFC3986_BASE, 'g:h', 'g:h'], - [self::RFC3986_BASE, 'g', 'http://a/b/c/g'], - [self::RFC3986_BASE, './g', 'http://a/b/c/g'], - [self::RFC3986_BASE, 'g/', 'http://a/b/c/g/'], - [self::RFC3986_BASE, '/g', 'http://a/g'], - [self::RFC3986_BASE, '//g', 'http://g'], - [self::RFC3986_BASE, '?y', 'http://a/b/c/d;p?y'], - [self::RFC3986_BASE, 'g?y', 'http://a/b/c/g?y'], - [self::RFC3986_BASE, '#s', 'http://a/b/c/d;p?q#s'], - [self::RFC3986_BASE, 'g#s', 'http://a/b/c/g#s'], - [self::RFC3986_BASE, 'g?y#s', 'http://a/b/c/g?y#s'], - [self::RFC3986_BASE, ';x', 'http://a/b/c/;x'], - [self::RFC3986_BASE, 'g;x', 'http://a/b/c/g;x'], - [self::RFC3986_BASE, 'g;x?y#s', 'http://a/b/c/g;x?y#s'], - [self::RFC3986_BASE, '', self::RFC3986_BASE], - [self::RFC3986_BASE, '.', 'http://a/b/c/'], - [self::RFC3986_BASE, './', 'http://a/b/c/'], - [self::RFC3986_BASE, '..', 'http://a/b/'], - [self::RFC3986_BASE, '../', 'http://a/b/'], - [self::RFC3986_BASE, '../g', 'http://a/b/g'], - [self::RFC3986_BASE, '../..', 'http://a/'], - [self::RFC3986_BASE, '../../', 'http://a/'], - [self::RFC3986_BASE, '../../g', 'http://a/g'], - [self::RFC3986_BASE, '../../../g', 'http://a/g'], - [self::RFC3986_BASE, '../../../../g', 'http://a/g'], - [self::RFC3986_BASE, '/./g', 'http://a/g'], - [self::RFC3986_BASE, '/../g', 'http://a/g'], - [self::RFC3986_BASE, 'g.', 'http://a/b/c/g.'], - [self::RFC3986_BASE, '.g', 'http://a/b/c/.g'], - [self::RFC3986_BASE, 'g..', 'http://a/b/c/g..'], - [self::RFC3986_BASE, '..g', 'http://a/b/c/..g'], - [self::RFC3986_BASE, './../g', 'http://a/b/g'], - [self::RFC3986_BASE, 'foo////g', 'http://a/b/c/foo////g'], - [self::RFC3986_BASE, './g/.', 'http://a/b/c/g/'], - [self::RFC3986_BASE, 'g/./h', 'http://a/b/c/g/h'], - [self::RFC3986_BASE, 'g/../h', 'http://a/b/c/h'], - [self::RFC3986_BASE, 'g;x=1/./y', 'http://a/b/c/g;x=1/y'], - [self::RFC3986_BASE, 'g;x=1/../y', 'http://a/b/c/y'], - ['http://u@a/b/c/d;p?q', '.', 'http://u@a/b/c/'], - ['http://u:p@a/b/c/d;p?q', '.', 'http://u:p@a/b/c/'], - //[self::RFC3986_BASE, 'http:g', 'http:g'], - ]; - } - - public function testAddAndRemoveQueryValues() - { - $uri = new Uri('http://foo.com/bar'); - $uri = Uri::withQueryValue($uri, 'a', 'b'); - $uri = Uri::withQueryValue($uri, 'c', 'd'); - $uri = Uri::withQueryValue($uri, 'e', null); - $this->assertEquals('a=b&c=d&e', $uri->getQuery()); - - $uri = Uri::withoutQueryValue($uri, 'c'); - $uri = Uri::withoutQueryValue($uri, 'e'); - $this->assertEquals('a=b', $uri->getQuery()); - $uri = Uri::withoutQueryValue($uri, 'a'); - $uri = Uri::withoutQueryValue($uri, 'a'); - $this->assertEquals('', $uri->getQuery()); - } - - public function testGetAuthorityReturnsCorrectPort() - { - // HTTPS non-standard port - $uri = new Uri('https://foo.co:99'); - $this->assertEquals('foo.co:99', $uri->getAuthority()); - - // HTTP non-standard port - $uri = new Uri('http://foo.co:99'); - $this->assertEquals('foo.co:99', $uri->getAuthority()); - - // No scheme - $uri = new Uri('foo.co:99'); - $this->assertEquals('foo.co:99', $uri->getAuthority()); - - // No host or port - $uri = new Uri('http:'); - $this->assertEquals('', $uri->getAuthority()); - - // No host or port - $uri = new Uri('http://foo.co'); - $this->assertEquals('foo.co', $uri->getAuthority()); - } - - public function pathTestProvider() - { - return [ - // Percent encode spaces. - ['http://foo.com/baz bar', 'http://foo.com/baz%20bar'], - // Don't encoding something that's already encoded. - ['http://foo.com/baz%20bar', 'http://foo.com/baz%20bar'], - // Percent encode invalid percent encodings - ['http://foo.com/baz%2-bar', 'http://foo.com/baz%252-bar'], - // Don't encode path segments - ['http://foo.com/baz/bar/bam?a', 'http://foo.com/baz/bar/bam?a'], - ['http://foo.com/baz+bar', 'http://foo.com/baz+bar'], - ['http://foo.com/baz:bar', 'http://foo.com/baz:bar'], - ['http://foo.com/baz@bar', 'http://foo.com/baz@bar'], - ['http://foo.com/baz(bar);bam/', 'http://foo.com/baz(bar);bam/'], - ['http://foo.com/a-zA-Z0-9.-_~!$&\'()*+,;=:@', 'http://foo.com/a-zA-Z0-9.-_~!$&\'()*+,;=:@'], - ]; - } - - /** - * @dataProvider pathTestProvider - */ - public function testUriEncodesPathProperly($input, $output) - { - $uri = new Uri($input); - $this->assertEquals((string) $uri, $output); - } - - public function testDoesNotAddPortWhenNoPort() - { - $this->assertEquals('bar', new Uri('//bar')); - $this->assertEquals('bar', (new Uri('//bar'))->getHost()); - } - - public function testAllowsForRelativeUri() - { - $uri = (new Uri)->withPath('foo'); - $this->assertEquals('foo', $uri->getPath()); - $this->assertEquals('foo', (string) $uri); - } - - public function testAddsSlashForRelativeUriStringWithHost() - { - $uri = (new Uri)->withPath('foo')->withHost('bar.com'); - $this->assertEquals('foo', $uri->getPath()); - $this->assertEquals('bar.com/foo', (string) $uri); - } -} diff --git a/vendor/guzzlehttp/psr7/tests/bootstrap.php b/vendor/guzzlehttp/psr7/tests/bootstrap.php deleted file mode 100644 index 8601dd330..000000000 --- a/vendor/guzzlehttp/psr7/tests/bootstrap.php +++ /dev/null @@ -1,11 +0,0 @@ -html5Elements as $element) { - $this->assertTrue(Elements::isHtml5Element($element), 'html5 element test failed on: ' . $element); - - $this->assertTrue(Elements::isHtml5Element(strtoupper($element)), 'html5 element test failed on: ' . strtoupper($element)); - } - - $nonhtml5 = array( - 'foo', - 'bar', - 'baz' - ); - foreach ($nonhtml5 as $element) { - $this->assertFalse(Elements::isHtml5Element($element), 'html5 element test failed on: ' . $element); - - $this->assertFalse(Elements::isHtml5Element(strtoupper($element)), 'html5 element test failed on: ' . strtoupper($element)); - } - } - - public function testIsMathMLElement() - { - foreach ($this->mathmlElements as $element) { - $this->assertTrue(Elements::isMathMLElement($element), 'MathML element test failed on: ' . $element); - - // MathML is case sensetitive so these should all fail. - $this->assertFalse(Elements::isMathMLElement(strtoupper($element)), 'MathML element test failed on: ' . strtoupper($element)); - } - - $nonMathML = array( - 'foo', - 'bar', - 'baz' - ); - foreach ($nonMathML as $element) { - $this->assertFalse(Elements::isMathMLElement($element), 'MathML element test failed on: ' . $element); - } - } - - public function testIsSvgElement() - { - foreach ($this->svgElements as $element) { - $this->assertTrue(Elements::isSvgElement($element), 'SVG element test failed on: ' . $element); - - // SVG is case sensetitive so these should all fail. - $this->assertFalse(Elements::isSvgElement(strtoupper($element)), 'SVG element test failed on: ' . strtoupper($element)); - } - - $nonSVG = array( - 'foo', - 'bar', - 'baz' - ); - foreach ($nonSVG as $element) { - $this->assertFalse(Elements::isSvgElement($element), 'SVG element test failed on: ' . $element); - } - } - - public function testIsElement() - { - foreach ($this->html5Elements as $element) { - $this->assertTrue(Elements::isElement($element), 'html5 element test failed on: ' . $element); - - $this->assertTrue(Elements::isElement(strtoupper($element)), 'html5 element test failed on: ' . strtoupper($element)); - } - - foreach ($this->mathmlElements as $element) { - $this->assertTrue(Elements::isElement($element), 'MathML element test failed on: ' . $element); - - // MathML is case sensetitive so these should all fail. - $this->assertFalse(Elements::isElement(strtoupper($element)), 'MathML element test failed on: ' . strtoupper($element)); - } - - foreach ($this->svgElements as $element) { - $this->assertTrue(Elements::isElement($element), 'SVG element test failed on: ' . $element); - - // SVG is case sensetitive so these should all fail. But, there is duplication - // html5 and SVG. Since html5 is case insensetitive we need to make sure - // it's not a html5 element first. - if (! in_array($element, $this->html5Elements)) { - $this->assertFalse(Elements::isElement(strtoupper($element)), 'SVG element test failed on: ' . strtoupper($element)); - } - } - - $nonhtml5 = array( - 'foo', - 'bar', - 'baz' - ); - foreach ($nonhtml5 as $element) { - $this->assertFalse(Elements::isElement($element), 'html5 element test failed on: ' . $element); - - $this->assertFalse(Elements::isElement(strtoupper($element)), 'html5 element test failed on: ' . strtoupper($element)); - } - } - - public function testElement() - { - foreach ($this->html5Elements as $element) { - $this->assertGreaterThan(0, Elements::element($element)); - } - $nonhtml5 = array( - 'foo', - 'bar', - 'baz' - ); - foreach ($nonhtml5 as $element) { - $this->assertFalse(Elements::element($element)); - } - } - - public function testIsA() - { - $this->assertTrue(Elements::isA('script', Elements::KNOWN_ELEMENT)); - $this->assertFalse(Elements::isA('scriptypoo', Elements::KNOWN_ELEMENT)); - $this->assertTrue(Elements::isA('script', Elements::TEXT_RAW)); - $this->assertFalse(Elements::isA('script', Elements::TEXT_RCDATA)); - - $voidElements = array( - 'area', - 'base', - 'basefont', - 'bgsound', - 'br', - 'col', - 'command', - 'embed', - 'frame', - 'hr', - 'img' - ); - - foreach ($voidElements as $element) { - $this->assertTrue(Elements::isA($element, Elements::VOID_TAG), 'Void element test failed on: ' . $element); - } - - $nonVoid = array( - 'span', - 'a', - 'div' - ); - foreach ($nonVoid as $tag) { - $this->assertFalse(Elements::isA($tag, Elements::VOID_TAG), 'Void element test failed on: ' . $tag); - } - - $blockTags = array( - 'address', - 'article', - 'aside', - 'audio', - 'blockquote', - 'canvas', - 'dd', - 'div', - 'dl', - 'fieldset', - 'figcaption', - 'figure', - 'footer', - 'form', - 'h1', - 'h2', - 'h3', - 'h4', - 'h5', - 'h6', - 'header', - 'hgroup', - 'hr', - 'noscript', - 'ol', - 'output', - 'p', - 'pre', - 'section', - 'table', - 'tfoot', - 'ul', - 'video' - ); - - foreach ($blockTags as $tag) { - $this->assertTrue(Elements::isA($tag, Elements::BLOCK_TAG), 'Block tag test failed on: ' . $tag); - } - - $nonBlockTags = array( - 'span', - 'img', - 'label' - ); - foreach ($nonBlockTags as $tag) { - $this->assertFalse(Elements::isA($tag, Elements::BLOCK_TAG), 'Block tag test failed on: ' . $tag); - } - } - - public function testNormalizeSvgElement() - { - $tests = array( - 'foo' => 'foo', - 'altglyph' => 'altGlyph', - 'BAR' => 'bar', - 'fespecularlighting' => 'feSpecularLighting', - 'bAz' => 'baz', - 'foreignobject' => 'foreignObject' - ); - - foreach ($tests as $input => $expected) { - $this->assertEquals($expected, Elements::normalizeSvgElement($input)); - } - } - - public function testNormalizeSvgAttribute() - { - $tests = array( - 'foo' => 'foo', - 'attributename' => 'attributeName', - 'BAR' => 'bar', - 'limitingconeangle' => 'limitingConeAngle', - 'bAz' => 'baz', - 'patterncontentunits' => 'patternContentUnits' - ); - - foreach ($tests as $input => $expected) { - $this->assertEquals($expected, Elements::normalizeSvgAttribute($input)); - } - } - - public function testNormalizeMathMlAttribute() - { - $tests = array( - 'foo' => 'foo', - 'definitionurl' => 'definitionURL', - 'BAR' => 'bar' - ); - - foreach ($tests as $input => $expected) { - $this->assertEquals($expected, Elements::normalizeMathMlAttribute($input)); - } - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Html5Test.html b/vendor/masterminds/html5/test/HTML5/Html5Test.html deleted file mode 100644 index a976e8be9..000000000 --- a/vendor/masterminds/html5/test/HTML5/Html5Test.html +++ /dev/null @@ -1,10 +0,0 @@ - - - - - Test - - -

    This is a test.

    - - \ No newline at end of file diff --git a/vendor/masterminds/html5/test/HTML5/Html5Test.php b/vendor/masterminds/html5/test/HTML5/Html5Test.php deleted file mode 100644 index cce58b70b..000000000 --- a/vendor/masterminds/html5/test/HTML5/Html5Test.php +++ /dev/null @@ -1,401 +0,0 @@ -html5 = $this->getInstance(); - } - - /** - * Parse and serialize a string. - */ - protected function cycle($html) - { - $dom = $this->html5->loadHTML('' . $html . ''); - $out = $this->html5->saveHTML($dom); - - return $out; - } - - protected function cycleFragment($fragment) - { - $dom = $this->html5->loadHTMLFragment($fragment); - $out = $this->html5->saveHTML($dom); - - return $out; - } - - public function testLoadOptions() - { - // doc - $dom = $this->html5->loadHTML($this->wrap(''), array( - 'implicitNamespaces' => array('t' => 'http://example.com'), - "xmlNamespaces" => true - )); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - $this->assertFalse($this->html5->hasErrors()); - - $xpath = new \DOMXPath( $dom ); - $xpath->registerNamespace( "t", "http://example.com" ); - $this->assertEquals(1, $xpath->query( "//t:tag" )->length); - - // doc fragment - $frag = $this->html5->loadHTMLFragment('', array( - 'implicitNamespaces' => array('t' => 'http://example.com'), - "xmlNamespaces" => true - )); - $this->assertInstanceOf('\DOMDocumentFragment', $frag); - $this->assertEmpty($this->html5->getErrors()); - $this->assertFalse($this->html5->hasErrors()); - - $frag->ownerDocument->appendChild($frag); - $xpath = new \DOMXPath( $frag->ownerDocument ); - $xpath->registerNamespace( "t", "http://example.com" ); - $this->assertEquals(1, $xpath->query( "//t:tag" , $frag)->length); - } - - public function testErrors() - { - $dom = $this->html5->loadHTML(''); - $this->assertInstanceOf('\DOMDocument', $dom); - - $this->assertNotEmpty($this->html5->getErrors()); - $this->assertTrue($this->html5->hasErrors()); - } - - public function testLoad() - { - $dom = $this->html5->load(__DIR__ . '/Html5Test.html'); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - $this->assertFalse($this->html5->hasErrors()); - - $file = fopen(__DIR__ . '/Html5Test.html', 'r'); - $dom = $this->html5->load($file); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - - $dom = $this->html5->loadHTMLFile(__DIR__ . '/Html5Test.html'); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - } - - public function testLoadHTML() - { - $contents = file_get_contents(__DIR__ . '/Html5Test.html'); - $dom = $this->html5->loadHTML($contents); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - } - - public function testLoadHTMLFragment() - { - $fragment = '
    Baz
    '; - $dom = $this->html5->loadHTMLFragment($fragment); - $this->assertInstanceOf('\DOMDocumentFragment', $dom); - $this->assertEmpty($this->html5->getErrors()); - } - - public function testSaveHTML() - { - $dom = $this->html5->load(__DIR__ . '/Html5Test.html'); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - - $saved = $this->html5->saveHTML($dom); - $this->assertRegExp('|

    This is a test.

    |', $saved); - } - - public function testSaveHTMLFragment() - { - $fragment = '
    Baz
    '; - $dom = $this->html5->loadHTMLFragment($fragment); - - $string = $this->html5->saveHTML($dom); - $this->assertEquals($fragment, $string); - } - - public function testSave() - { - $dom = $this->html5->load(__DIR__ . '/Html5Test.html'); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - - // Test resource - $file = fopen('php://temp', 'w'); - $this->html5->save($dom, $file); - $content = stream_get_contents($file, - 1, 0); - $this->assertRegExp('|

    This is a test.

    |', $content); - - // Test file - $tmpfname = tempnam(sys_get_temp_dir(), "html5-php"); - $this->html5->save($dom, $tmpfname); - $content = file_get_contents($tmpfname); - $this->assertRegExp('|

    This is a test.

    |', $content); - unlink($tmpfname); - } - - // This test reads a document into a dom, turn the dom into a document, - // then tries to read that document again. This makes sure we are reading, - // and generating a document that works at a high level. - public function testItWorks() - { - $dom = $this->html5->load(__DIR__ . '/Html5Test.html'); - $this->assertInstanceOf('\DOMDocument', $dom); - $this->assertEmpty($this->html5->getErrors()); - - $saved = $this->html5->saveHTML($dom); - - $dom2 = $this->html5->loadHTML($saved); - $this->assertInstanceOf('\DOMDocument', $dom2); - $this->assertEmpty($this->html5->getErrors()); - } - - public function testConfig() - { - $html5 = $this->getInstance(); - $options = $html5->getOptions(); - $this->assertEquals(false, $options['encode_entities']); - - $html5 = $this->getInstance(array( - 'foo' => 'bar', - 'encode_entities' => true - )); - $options = $html5->getOptions(); - $this->assertEquals('bar', $options['foo']); - $this->assertEquals(true, $options['encode_entities']); - - // Need to reset to original so future tests pass as expected. - // $this->getInstance()->setOption('encode_entities', false); - } - - public function testSvg() - { - $dom = $this->html5->loadHTML( - ' - - -
    foo bar baz
    - - - - - - - Test Text. - - - - - '); - - $this->assertEmpty($this->html5->getErrors()); - - // Test a mixed case attribute. - $list = $dom->getElementsByTagName('svg'); - $this->assertNotEmpty($list->length); - $svg = $list->item(0); - $this->assertEquals("0 0 3 2", $svg->getAttribute('viewBox')); - $this->assertFalse($svg->hasAttribute('viewbox')); - - // Test a mixed case tag. - // Note: getElementsByTagName is not case sensetitive. - $list = $dom->getElementsByTagName('textPath'); - $this->assertNotEmpty($list->length); - $textPath = $list->item(0); - $this->assertEquals('textPath', $textPath->tagName); - $this->assertNotEquals('textpath', $textPath->tagName); - - $html = $this->html5->saveHTML($dom); - $this->assertRegExp('||', $html); - $this->assertRegExp('||', $html); - } - - public function testMathMl() - { - $dom = $this->html5->loadHTML( - ' - - -
    foo bar baz
    - - x - - ± - - y - - - '); - - $this->assertEmpty($this->html5->getErrors()); - $list = $dom->getElementsByTagName('math'); - $this->assertNotEmpty($list->length); - - $list = $dom->getElementsByTagName('div'); - $this->assertNotEmpty($list->length); - $div = $list->item(0); - $this->assertEquals('http://example.com', $div->getAttribute('definitionurl')); - $this->assertFalse($div->hasAttribute('definitionURL')); - $list = $dom->getElementsByTagName('csymbol'); - $csymbol = $list->item(0); - $this->assertEquals('http://www.example.com/mathops/multiops.html#plusminus', $csymbol->getAttribute('definitionURL')); - $this->assertFalse($csymbol->hasAttribute('definitionurl')); - - $html = $this->html5->saveHTML($dom); - $this->assertRegExp('||', $html); - $this->assertRegExp('|y|', $html); - } - - public function testUnknownElements() - { - // The : should not have special handling accourding to section 2.9 of the - // spec. This is differenant than XML. Since we don't know these elements - // they are handled as normal elements. Note, to do this is really - // an invalid example and you should not embed prefixed xml in html5. - $dom = $this->html5->loadHTMLFragment( - " - Big rectangle thing - 40 - 80 - - um, yeah"); - - $this->assertEmpty($this->html5->getErrors()); - $markup = $this->html5->saveHTML($dom); - $this->assertRegExp('|Big rectangle thing|', $markup); - $this->assertRegExp('|um, yeah|', $markup); - } - - public function testElements() - { - // Should have content. - $res = $this->cycle('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - // Should be empty - $res = $this->cycle(''); - $this->assertRegExp('||', $res); - - // Should have content. - $res = $this->cycleFragment('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - // Should be empty - $res = $this->cycleFragment(''); - $this->assertRegExp('||', $res); - - // Elements with dashes and underscores - $res = $this->cycleFragment(''); - $this->assertRegExp('||', $res); - $res = $this->cycleFragment(''); - $this->assertRegExp('||', $res); - - // Should have no closing tag. - $res = $this->cycle('
    '); - $this->assertRegExp('|
    |', $res); - } - - public function testAttributes() - { - $res = $this->cycle('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - // XXX: Note that spec does NOT require attrs in the same order. - $res = $this->cycle('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - $res = $this->cycle('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - $res = $this->cycleFragment('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - // XXX: Note that spec does NOT require attrs in the same order. - $res = $this->cycleFragment('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - - $res = $this->cycleFragment('
    FOO
    '); - $this->assertRegExp('|
    FOO
    |', $res); - } - - public function testPCData() - { - $res = $this->cycle('This is a test.'); - $this->assertRegExp('|This is a test.|', $res); - - $res = $this->cycleFragment('This is a test.'); - $this->assertRegExp('|This is a test.|', $res); - - $res = $this->cycle('This - is - a - test.'); - - // Check that newlines are there, but don't count spaces. - $this->assertRegExp('|This\n\s*is\n\s*a\n\s*test.|', $res); - - $res = $this->cycleFragment('This - is - a - test.'); - - // Check that newlines are there, but don't count spaces. - $this->assertRegExp('|This\n\s*is\n\s*a\n\s*test.|', $res); - - $res = $this->cycle('This is a test.'); - $this->assertRegExp('|This is a test.|', $res); - - $res = $this->cycleFragment('This is a test.'); - $this->assertRegExp('|This is a test.|', $res); - } - - public function testUnescaped() - { - $res = $this->cycle(''); - $this->assertRegExp('|2 < 1|', $res); - - $res = $this->cycle(''); - $this->assertRegExp('|div>div>div|', $res); - - $res = $this->cycleFragment(''); - $this->assertRegExp('|2 < 1|', $res); - - $res = $this->cycleFragment(''); - $this->assertRegExp('|div>div>div|', $res); - } - - public function testEntities() - { - $res = $this->cycle('Apples & bananas.'); - $this->assertRegExp('|Apples & bananas.|', $res); - - $res = $this->cycleFragment('Apples & bananas.'); - $this->assertRegExp('|Apples & bananas.|', $res); - - $res = $this->cycleFragment('

    R&D

    '); - $this->assertRegExp('|R&D|', $res); - } - - public function testComment() - { - $res = $this->cycle('ab'); - $this->assertRegExp('||', $res); - - $res = $this->cycleFragment('ab'); - $this->assertRegExp('||', $res); - } - - public function testCDATA() - { - $res = $this->cycle('a a test. ]]>b'); - $this->assertRegExp('| a test\. \]\]>|', $res); - - $res = $this->cycleFragment('a a test. ]]>b'); - $this->assertRegExp('| a test\. \]\]>|', $res); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/CharacterReferenceTest.php b/vendor/masterminds/html5/test/HTML5/Parser/CharacterReferenceTest.php deleted file mode 100644 index 762bcc261..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/CharacterReferenceTest.php +++ /dev/null @@ -1,44 +0,0 @@ -assertEquals('&', CharacterReference::lookupName('amp')); - $this->assertEquals('<', CharacterReference::lookupName('lt')); - $this->assertEquals('>', CharacterReference::lookupName('gt')); - $this->assertEquals('"', CharacterReference::lookupName('quot')); - $this->assertEquals('∌', CharacterReference::lookupName('NotReverseElement')); - - $this->assertNull(CharacterReference::lookupName('StinkyCheese')); - } - - public function testLookupHex() - { - $this->assertEquals('<', CharacterReference::lookupHex('3c')); - $this->assertEquals('<', CharacterReference::lookupHex('003c')); - $this->assertEquals('&', CharacterReference::lookupHex('26')); - $this->assertEquals('}', CharacterReference::lookupHex('7d')); - $this->assertEquals('Σ', CharacterReference::lookupHex('3A3')); - $this->assertEquals('Σ', CharacterReference::lookupHex('03A3')); - $this->assertEquals('Σ', CharacterReference::lookupHex('3a3')); - $this->assertEquals('Σ', CharacterReference::lookupHex('03a3')); - } - - public function testLookupDecimal() - { - $this->assertEquals('&', CharacterReference::lookupDecimal(38)); - $this->assertEquals('&', CharacterReference::lookupDecimal('38')); - $this->assertEquals('<', CharacterReference::lookupDecimal(60)); - $this->assertEquals('Σ', CharacterReference::lookupDecimal(931)); - $this->assertEquals('Σ', CharacterReference::lookupDecimal('0931')); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/DOMTreeBuilderTest.php b/vendor/masterminds/html5/test/HTML5/Parser/DOMTreeBuilderTest.php deleted file mode 100644 index b2a2d398f..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/DOMTreeBuilderTest.php +++ /dev/null @@ -1,537 +0,0 @@ -parse(); - $this->errors = $treeBuilder->getErrors(); - - return $treeBuilder->document(); - } - - /** - * Utility function for parsing a fragment of HTML5. - */ - protected function parseFragment($string) - { - $treeBuilder = new DOMTreeBuilder(true); - $input = new StringInputStream($string); - $scanner = new Scanner($input); - $parser = new Tokenizer($scanner, $treeBuilder); - - $parser->parse(); - $this->errors = $treeBuilder->getErrors(); - - return $treeBuilder->fragment(); - } - - public function testDocument() - { - $html = ""; - $doc = $this->parse($html); - - $this->assertInstanceOf('\DOMDocument', $doc); - $this->assertEquals('html', $doc->documentElement->tagName); - $this->assertEquals('http://www.w3.org/1999/xhtml', $doc->documentElement->namespaceURI); - } - - public function testStrangeCapitalization() - { - $html = " - - - Hello, world! - - TheBody - "; - $doc = $this->parse($html); - - $this->assertInstanceOf('\DOMDocument', $doc); - $this->assertEquals('html', $doc->documentElement->tagName); - - $xpath = new \DOMXPath( $doc ); - $xpath->registerNamespace( "x", "http://www.w3.org/1999/xhtml" ); - - $this->assertEquals("Hello, world!", $xpath->query( "//x:title" )->item( 0 )->nodeValue); - $this->assertEquals("foo", $xpath->query( "//x:script" )->item( 0 )->nodeValue); - } - - public function testDocumentWithDisabledNamespaces() - { - $html = ""; - $doc = $this->parse($html, array('disable_html_ns' => true)); - - $this->assertInstanceOf('\DOMDocument', $doc); - $this->assertEquals('html', $doc->documentElement->tagName); - $this->assertNull($doc->documentElement->namespaceURI); - } - - public function testDocumentWithATargetDocument() - { - $targetDom = new \DOMDocument(); - - $html = ""; - $doc = $this->parse($html, array('target_document' => $targetDom)); - - $this->assertInstanceOf('\DOMDocument', $doc); - $this->assertSame($doc, $targetDom); - $this->assertEquals('html', $doc->documentElement->tagName); - } - - public function testDocumentFakeAttrAbsence() - { - $html = "foo"; - $doc = $this->parse($html, array('xmlNamespaces'=>true)); - - $xp = new \DOMXPath($doc); - $this->assertEquals(0, $xp->query("//@html5-php-fake-id-attribute")->length); - } - - public function testFragment() - { - $html = "
    test
    test2"; - $doc = $this->parseFragment($html); - - $this->assertInstanceOf('\DOMDocumentFragment', $doc); - $this->assertTrue($doc->hasChildNodes()); - $this->assertEquals('div', $doc->childNodes->item(0)->tagName); - $this->assertEquals('test', $doc->childNodes->item(0)->textContent); - $this->assertEquals('span', $doc->childNodes->item(1)->tagName); - $this->assertEquals('test2', $doc->childNodes->item(1)->textContent); - } - - public function testElements() - { - $html = ""; - $doc = $this->parse($html); - $root = $doc->documentElement; - - $this->assertEquals('html', $root->tagName); - $this->assertEquals('html', $root->localName); - $this->assertEquals('html', $root->nodeName); - - $this->assertEquals(2, $root->childNodes->length); - $kids = $root->childNodes; - - $this->assertEquals('head', $kids->item(0)->tagName); - $this->assertEquals('body', $kids->item(1)->tagName); - - $head = $kids->item(0); - $this->assertEquals(1, $head->childNodes->length); - $this->assertEquals('title', $head->childNodes->item(0)->tagName); - } - - public function testImplicitNamespaces() - { - $dom = $this->parse('foo'); - $a = $dom->getElementsByTagName('a')->item(0); - $attr = $a->getAttributeNode('xlink:href'); - $this->assertEquals('http://www.w3.org/1999/xlink', $attr->namespaceURI); - - $dom = $this->parse('foo'); - $a = $dom->getElementsByTagName('a')->item(0); - $attr = $a->getAttributeNode('xml:base'); - $this->assertEquals('http://www.w3.org/XML/1998/namespace', $attr->namespaceURI); - } - - public function testCustomImplicitNamespaces() - { - $dom = $this->parse('foo', array( - 'implicitNamespaces' => array( - 't' => 'http://www.example.com' - ) - )); - $a = $dom->getElementsByTagName('a')->item(0); - $attr = $a->getAttributeNode('t:href'); - $this->assertEquals('http://www.example.com', $attr->namespaceURI); - - $dom = $this->parse('foo', array( - 'implicitNamespaces' => array( - 't' => 'http://www.example.com' - ) - )); - $list = $dom->getElementsByTagNameNS('http://www.example.com', 'a'); - $this->assertEquals(1, $list->length); - } - - public function testXmlNamespaces() - { - $dom = $this->parse( - ' - - foo - -
    foo
    - ', array( - 'xmlNamespaces' => true - )); - $a = $dom->getElementsByTagName('a')->item(0); - $attr = $a->getAttributeNode('t:href'); - $this->assertEquals('http://www.example.com', $attr->namespaceURI); - - $list = $dom->getElementsByTagNameNS('http://www.example.com', 'body'); - $this->assertEquals(1, $list->length); - } - - public function testXmlNamespaceNesting() - { - $dom = $this->parse( - ' - - - - - - -
    - - - - ', array( - 'xmlNamespaces' => true - )); - - - $this->assertEmpty($this->errors); - - $div = $dom->getElementById('div'); - $this->assertEquals('http://www.w3.org/1999/xhtml', $div->namespaceURI); - - $body = $dom->getElementById('body'); - $this->assertEquals('http://www.w3.org/1999/xhtml', $body->namespaceURI); - - $bar1 = $dom->getElementById('bar1'); - $this->assertEquals('http://www.prefixed.com/bar1', $bar1->namespaceURI); - - $bar2 = $dom->getElementById('bar2'); - $this->assertEquals("http://www.prefixed.com/bar2", $bar2->namespaceURI); - - $bar3 = $dom->getElementById('bar3'); - $this->assertEquals("http://www.w3.org/1999/xhtml", $bar3->namespaceURI); - - $bar4 = $dom->getElementById('bar4'); - $this->assertEquals("http://www.prefixed.com/bar4", $bar4->namespaceURI); - - $svg = $dom->getElementById('svg'); - $this->assertEquals("http://www.w3.org/2000/svg", $svg->namespaceURI); - - $prefixed = $dom->getElementById('prefixed'); - $this->assertEquals("http://www.prefixed.com", $prefixed->namespaceURI); - - $prefixed = $dom->getElementById('bar5'); - $this->assertEquals("http://www.prefixed.com/xn", $prefixed->namespaceURI); - - $prefixed = $dom->getElementById('bar5_x'); - $this->assertEquals("http://www.prefixed.com/bar5_x", $prefixed->namespaceURI); - } - - public function testMoveNonInlineElements() - { - $doc = $this->parse('

    line1


    line2

    '); - $this->assertEquals('

    line1


    line2', $doc->saveXML($doc->documentElement), 'Move non-inline elements outside of inline containers.'); - - $doc = $this->parse('

    line1

    line2

    '); - $this->assertEquals('

    line1

    line2
    ', $doc->saveXML($doc->documentElement), 'Move non-inline elements outside of inline containers.'); - } - - public function testAttributes() - { - $html = " - - - - "; - $doc = $this->parse($html); - $root = $doc->documentElement; - - $body = $root->GetElementsByTagName('body')->item(0); - $this->assertEquals('body', $body->tagName); - $this->assertTrue($body->hasAttributes()); - $this->assertEquals('a', $body->getAttribute('id')); - $this->assertEquals('b c', $body->getAttribute('class')); - - $body2 = $doc->getElementById('a'); - $this->assertEquals('body', $body2->tagName); - $this->assertEquals('a', $body2->getAttribute('id')); - } - - public function testSVGAttributes() - { - $html = " - - - - foo - - "; - $doc = $this->parse($html); - $root = $doc->documentElement; - - $svg = $root->getElementsByTagName('svg')->item(0); - $this->assertTrue($svg->hasAttribute('viewBox')); - - $rect = $root->getElementsByTagName('rect')->item(0); - $this->assertTrue($rect->hasAttribute('textLength')); - - $ac = $root->getElementsByTagName('animateColor'); - $this->assertEquals(1, $ac->length); - } - - public function testMathMLAttribute() - { - $html = ' - - - - x - - ± - - y - - - '; - - $doc = $this->parse($html); - $root = $doc->documentElement; - - $csymbol = $root->getElementsByTagName('csymbol')->item(0); - $this->assertTrue($csymbol->hasAttribute('definitionURL')); - } - - public function testMissingHtmlTag() - { - $html = "test"; - $doc = $this->parse($html); - - $this->assertEquals('html', $doc->documentElement->tagName); - $this->assertEquals('title', $doc->documentElement->childNodes->item(0)->tagName); - } - - public function testComment() - { - $html = ''; - - $doc = $this->parse($html); - - $comment = $doc->documentElement->childNodes->item(0); - $this->assertEquals(XML_COMMENT_NODE, $comment->nodeType); - $this->assertEquals("Hello World.", $comment->data); - - $html = ''; - $doc = $this->parse($html); - - $comment = $doc->childNodes->item(1); - $this->assertEquals(XML_COMMENT_NODE, $comment->nodeType); - $this->assertEquals("Hello World.", $comment->data); - - $comment = $doc->childNodes->item(2); - $this->assertEquals(XML_ELEMENT_NODE, $comment->nodeType); - $this->assertEquals("html", $comment->tagName); - } - - public function testCDATA() - { - $html = "test"; - $doc = $this->parse($html); - - $wrapper = $doc->getElementsByTagName('math')->item(0); - $this->assertEquals(1, $wrapper->childNodes->length); - $cdata = $wrapper->childNodes->item(0); - $this->assertEquals(XML_CDATA_SECTION_NODE, $cdata->nodeType); - $this->assertEquals('test', $cdata->data); - } - - public function testText() - { - $html = "test"; - $doc = $this->parse($html); - - $wrapper = $doc->getElementsByTagName('math')->item(0); - $this->assertEquals(1, $wrapper->childNodes->length); - $data = $wrapper->childNodes->item(0); - $this->assertEquals(XML_TEXT_NODE, $data->nodeType); - $this->assertEquals('test', $data->data); - - // The DomTreeBuilder has special handling for text when in before head mode. - $html = " - Foo"; - $doc = $this->parse($html); - $this->assertEquals('Line 0, Col 0: Unexpected text. Ignoring: Foo', $this->errors[0]); - $headElement = $doc->documentElement->firstChild; - $this->assertEquals('head', $headElement->tagName); - } - - public function testParseErrors() - { - $html = "test"; - $doc = $this->parse($html); - - // We're JUST testing that we can access errors. Actual testing of - // error messages happen in the Tokenizer's tests. - $this->assertGreaterThan(0, count($this->errors)); - $this->assertTrue(is_string($this->errors[0])); - } - - public function testProcessingInstruction() - { - // Test the simple case, which is where PIs are inserted into the DOM. - $doc = $this->parse('<!DOCTYPE html><html><?foo bar?>'); - $this->assertEquals(1, $doc->documentElement->childNodes->length); - $pi = $doc->documentElement->firstChild; - $this->assertInstanceOf('\DOMProcessingInstruction', $pi); - $this->assertEquals('foo', $pi->nodeName); - $this->assertEquals('bar', $pi->data); - - // Leading xml PIs should be ignored. - $doc = $this->parse('<?xml version="1.0"?><!DOCTYPE html><html><head></head></html>'); - - $this->assertEquals(2, $doc->childNodes->length); - $this->assertInstanceOf('\DOMDocumentType', $doc->childNodes->item(0)); - $this->assertInstanceOf('\DOMElement', $doc->childNodes->item(1)); - } - - public function testAutocloseP() - { - $html = "<!DOCTYPE html><html><body><p><figure></body></html>"; - $doc = $this->parse($html); - - $p = $doc->getElementsByTagName('p')->item(0); - $this->assertEquals(0, $p->childNodes->length); - $this->assertEquals('figure', $p->nextSibling->tagName); - } - - public function testAutocloseLI() - { - $html = '<!doctype html> - <html lang="en"> - <body> - <ul><li>Foo<li>Bar<li>Baz</ul> - </body> - </html>'; - - $doc = $this->parse($html); - $length = $doc->getElementsByTagName('ul')->item(0)->childNodes->length; - $this->assertEquals(3, $length); - } - - public function testMathML() - { - $html = '<!doctype html> - <html lang="en"> - <body> - <math xmlns="http://www.w3.org/1998/Math/MathML"> - <mi>x</mi> - <csymbol definitionurl="http://www.example.com/mathops/multiops.html#plusminus"> - <mo>&PlusMinus;</mo> - </csymbol> - <mi>y</mi> - </math> - </body> - </html>'; - - $doc = $this->parse($html); - $math = $doc->getElementsByTagName('math')->item(0); - $this->assertEquals('math', $math->tagName); - $this->assertEquals('math', $math->nodeName); - $this->assertEquals('math', $math->localName); - $this->assertEquals('http://www.w3.org/1998/Math/MathML', $math->namespaceURI); - } - - public function testSVG() - { - $html = '<!doctype html> - <html lang="en"> - <body> - <svg width="150" height="100" viewBox="0 0 3 2" xmlns="http://www.w3.org/2000/svg"> - <rect width="1" height="2" x="2" fill="#d2232c" /> - <text font-family="Verdana" font-size="32"> - <textpath xlink:href="#Foo"> - Test Text. - </textPath> - </text> - </svg> - </body> - </html>'; - - $doc = $this->parse($html); - $svg = $doc->getElementsByTagName('svg')->item(0); - $this->assertEquals('svg', $svg->tagName); - $this->assertEquals('svg', $svg->nodeName); - $this->assertEquals('svg', $svg->localName); - $this->assertEquals('http://www.w3.org/2000/svg', $svg->namespaceURI); - - $textPath = $doc->getElementsByTagName('textPath')->item(0); - $this->assertEquals('textPath', $textPath->tagName); - } - - public function testNoScript() - { - $html = '<!DOCTYPE html><html><head><noscript>No JS</noscript></head></html>'; - $doc = $this->parse($html); - $this->assertEmpty($this->errors); - $noscript = $doc->getElementsByTagName('noscript')->item(0); - $this->assertEquals('noscript', $noscript->tagName); - } - - /** - * Regression for issue #13 - */ - public function testRegressionHTMLNoBody() - { - $html = '<!DOCTYPE html><html><span id="test">Test</span></html>'; - $doc = $this->parse($html); - $span = $doc->getElementById('test'); - - $this->assertEmpty($this->errors); - - $this->assertEquals('span', $span->tagName); - $this->assertEquals('Test', $span->textContent); - } - - public function testInstructionProcessor() - { - $string = '<!DOCTYPE html><html><?foo bar ?></html>'; - - $treeBuilder = new DOMTreeBuilder(); - $is = new InstructionProcessorMock(); - $treeBuilder->setInstructionProcessor($is); - - $input = new StringInputStream($string); - $scanner = new Scanner($input); - $parser = new Tokenizer($scanner, $treeBuilder); - - $parser->parse(); - $dom = $treeBuilder->document(); - $div = $dom->getElementsByTagName('div')->item(0); - - $this->assertEquals(1, $is->count); - $this->assertEquals('foo', $is->name); - $this->assertEquals('bar ', $is->data); - $this->assertEquals('div', $div->tagName); - $this->assertEquals('foo', $div->textContent); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/EventStack.php b/vendor/masterminds/html5/test/HTML5/Parser/EventStack.php deleted file mode 100644 index 60e2abe9b..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/EventStack.php +++ /dev/null @@ -1,116 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -use Masterminds\HTML5\Elements; -use Masterminds\HTML5\Parser\EventHandler; - -/** - * This testing class gathers events from a parser and builds a stack of events. - * It is useful for checking the output of a tokenizer. - * - * IMPORTANT: - * - * The startTag event also kicks the parser into TEXT_RAW when it encounters - * script or pre tags. This is to match the behavior required by the HTML5 spec, - * which says that the tree builder must tell the tokenizer when to switch states. - */ -class EventStack implements EventHandler -{ - - protected $stack; - - public function __construct() - { - $this->stack = array(); - } - - /** - * Get the event stack. - */ - public function events() - { - return $this->stack; - } - - public function depth() - { - return count($this->stack); - } - - public function get($index) - { - return $this->stack[$index]; - } - - protected function store($event, $data = null) - { - $this->stack[] = array( - 'name' => $event, - 'data' => $data - ); - } - - public function doctype($name, $type = 0, $id = null, $quirks = false) - { - $args = array( - $name, - $type, - $id, - $quirks - ); - $this->store('doctype', $args); - } - - public function startTag($name, $attributes = array(), $selfClosing = false) - { - $args = func_get_args(); - $this->store('startTag', $args); - if ($name == 'pre' || $name == 'script') { - return Elements::TEXT_RAW; - } - } - - public function endTag($name) - { - $this->store('endTag', array( - $name - )); - } - - public function comment($cdata) - { - $this->store('comment', array( - $cdata - )); - } - - public function cdata($data) - { - $this->store('cdata', func_get_args()); - } - - public function text($cdata) - { - // fprintf(STDOUT, "Received TEXT event with: " . $cdata); - $this->store('text', array( - $cdata - )); - } - - public function eof() - { - $this->store('eof'); - } - - public function parseError($msg, $line, $col) - { - // throw new EventStackParseError(sprintf("%s (line %d, col %d)", $msg, $line, $col)); - // $this->store(sprintf("%s (line %d, col %d)", $msg, $line, $col)); - $this->store('error', func_get_args()); - } - - public function processingInstruction($name, $data = null) - { - $this->store('pi', func_get_args()); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/EventStackError.php b/vendor/masterminds/html5/test/HTML5/Parser/EventStackError.php deleted file mode 100644 index e58fdff26..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/EventStackError.php +++ /dev/null @@ -1,6 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -class EventStackError extends \Exception -{ -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.html b/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.html deleted file mode 100644 index a976e8be9..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.html +++ /dev/null @@ -1,10 +0,0 @@ -<!doctype html> -<html lang="en"> - <head> - <meta charset="utf-8"> - <title>Test</title> - </head> - <body> - <p>This is a test.</p> - </body> -</html> \ No newline at end of file diff --git a/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.php b/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.php deleted file mode 100644 index 71dd828c4..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/FileInputStreamTest.php +++ /dev/null @@ -1,195 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -use Masterminds\HTML5\Parser\FileInputStream; - -class FileInputStreamTest extends \Masterminds\HTML5\Tests\TestCase -{ - - public function testConstruct() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertInstanceOf('\Masterminds\HTML5\Parser\FileInputStream', $s); - } - - public function testNext() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $s->next(); - $this->assertEquals('!', $s->current()); - $s->next(); - $this->assertEquals('d', $s->current()); - } - - public function testKey() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals(0, $s->key()); - - $s->next(); - $this->assertEquals(1, $s->key()); - } - - public function testPeek() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals('!', $s->peek()); - - $s->next(); - $this->assertEquals('d', $s->peek()); - } - - public function testCurrent() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals('<', $s->current()); - - $s->next(); - $this->assertEquals('!', $s->current()); - - $s->next(); - $this->assertEquals('d', $s->current()); - } - - public function testColumnOffset() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - $this->assertEquals(0, $s->columnOffset()); - $s->next(); - $this->assertEquals(1, $s->columnOffset()); - $s->next(); - $this->assertEquals(2, $s->columnOffset()); - $s->next(); - $this->assertEquals(3, $s->columnOffset()); - - // Make sure we get to the second line - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $this->assertEquals(0, $s->columnOffset()); - - $s->next(); - $canary = $s->current(); // h - $this->assertEquals('h', $canary); - $this->assertEquals(1, $s->columnOffset()); - } - - public function testCurrentLine() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals(1, $s->currentLine()); - - // Make sure we get to the second line - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $this->assertEquals(2, $s->currentLine()); - - // Make sure we get to the third line - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $this->assertEquals(3, $s->currentLine()); - } - - public function testRemainingChars() - { - $text = file_get_contents(__DIR__ . '/FileInputStreamTest.html'); - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - $this->assertEquals($text, $s->remainingChars()); - - $text = substr(file_get_contents(__DIR__ . '/FileInputStreamTest.html'), 1); - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - $s->next(); // Pop one. - $this->assertEquals($text, $s->remainingChars()); - } - - public function testCharsUnitl() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals('', $s->charsUntil('<')); - // Pointer at '<', moves to ' ' - $this->assertEquals('<!doctype', $s->charsUntil(' ', 20)); - - // Pointer at ' ', moves to '>' - $this->assertEquals(' html', $s->charsUntil('>')); - - // Pointer at '>', moves to '\n'. - $this->assertEquals('>', $s->charsUntil("\n")); - - // Pointer at '\n', move forward then to the next'\n'. - $s->next(); - $this->assertEquals('<html lang="en">', $s->charsUntil("\n")); - - // Ony get one of the spaces. - $this->assertEquals("\n ", $s->charsUntil('<', 2)); - - // Get the other space. - $this->assertEquals(" ", $s->charsUntil('<')); - - // This should scan to the end of the file. - $text = "<head> - <meta charset=\"utf-8\"> - <title>Test</title> - </head> - <body> - <p>This is a test.</p> - </body> -</html>"; - $this->assertEquals($text, $s->charsUntil("\t")); - } - - public function testCharsWhile() - { - $s = new FileInputStream(__DIR__ . '/FileInputStreamTest.html'); - - $this->assertEquals('<!', $s->charsWhile('!<')); - $this->assertEquals('', $s->charsWhile('>')); - $this->assertEquals('doctype', $s->charsWhile('odcyept')); - $this->assertEquals(' htm', $s->charsWhile('html ', 4)); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/InstructionProcessorMock.php b/vendor/masterminds/html5/test/HTML5/Parser/InstructionProcessorMock.php deleted file mode 100644 index 32a220482..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/InstructionProcessorMock.php +++ /dev/null @@ -1,26 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -class InstructionProcessorMock implements \Masterminds\HTML5\InstructionProcessor -{ - - public $name = null; - - public $data = null; - - public $count = 0; - - public function process(\DOMElement $element, $name, $data) - { - $this->name = $name; - $this->data = $data; - $this->count ++; - - $div = $element->ownerDocument->createElement("div"); - $div->nodeValue = 'foo'; - - $element->appendChild($div); - - return $div; - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/ScannerTest.php b/vendor/masterminds/html5/test/HTML5/Parser/ScannerTest.php deleted file mode 100644 index 8fa511068..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/ScannerTest.php +++ /dev/null @@ -1,171 +0,0 @@ -<?php -/** - * @file - * Test the Scanner. This requires the InputStream tests are all good. - */ -namespace Masterminds\HTML5\Tests\Parser; - -use Masterminds\HTML5\Parser\StringInputStream; -use Masterminds\HTML5\Parser\Scanner; - -class ScannerTest extends \Masterminds\HTML5\Tests\TestCase -{ - - /** - * A canary test to make sure the basics are setup and working. - */ - public function testConstruct() - { - $is = new StringInputStream("abc"); - $s = new Scanner($is); - - $this->assertInstanceOf('\Masterminds\HTML5\Parser\Scanner', $s); - } - - public function testNext() - { - $s = new Scanner(new StringInputStream("abc")); - - $this->assertEquals('b', $s->next()); - $this->assertEquals('c', $s->next()); - } - - public function testPosition() - { - $s = new Scanner(new StringInputStream("abc")); - - $this->assertEquals(0, $s->position()); - - $s->next(); - $this->assertEquals(1, $s->position()); - } - - public function testPeek() - { - $s = new Scanner(new StringInputStream("abc")); - - $this->assertEquals('b', $s->peek()); - - $s->next(); - $this->assertEquals('c', $s->peek()); - } - - public function testCurrent() - { - $s = new Scanner(new StringInputStream("abc")); - - // Before scanning the string begins the current is empty. - $this->assertEquals('a', $s->current()); - - $c = $s->next(); - $this->assertEquals('b', $s->current()); - - // Test movement through the string. - $c = $s->next(); - $this->assertEquals('c', $s->current()); - } - - public function testUnconsume() - { - $s = new Scanner(new StringInputStream("abcdefghijklmnopqrst")); - - // Get initial position. - $s->next(); - $start = $s->position(); - - // Move forward a bunch of positions. - $amount = 7; - for ($i = 0; $i < $amount; $i ++) { - $s->next(); - } - - // Roll back the amount we moved forward. - $s->unconsume($amount); - - $this->assertEquals($start, $s->position()); - } - - public function testGetHex() - { - $s = new Scanner(new StringInputStream("ab13ck45DE*")); - - $this->assertEquals('ab13c', $s->getHex()); - - $s->next(); - $this->assertEquals('45DE', $s->getHex()); - } - - public function testGetAsciiAlpha() - { - $s = new Scanner(new StringInputStream("abcdef1%mnop*")); - - $this->assertEquals('abcdef', $s->getAsciiAlpha()); - - // Move past the 1% to scan the next group of text. - $s->next(); - $s->next(); - $this->assertEquals('mnop', $s->getAsciiAlpha()); - } - - public function testGetAsciiAlphaNum() - { - $s = new Scanner(new StringInputStream("abcdef1ghpo#mn94op")); - - $this->assertEquals('abcdef1ghpo', $s->getAsciiAlphaNum()); - - // Move past the # to scan the next group of text. - $s->next(); - $this->assertEquals('mn94op', $s->getAsciiAlphaNum()); - } - - public function testGetNumeric() - { - $s = new Scanner(new StringInputStream("1784a 45 9867 #")); - - $this->assertEquals('1784', $s->getNumeric()); - - // Move past the 'a ' to scan the next group of text. - $s->next(); - $s->next(); - $this->assertEquals('45', $s->getNumeric()); - } - - public function testCurrentLine() - { - $s = new Scanner(new StringInputStream("1784a\n45\n9867 #\nThis is a test.")); - - $this->assertEquals(1, $s->currentLine()); - - // Move to the next line. - $s->getAsciiAlphaNum(); - $s->next(); - $this->assertEquals(2, $s->currentLine()); - } - - public function testColumnOffset() - { - $s = new Scanner(new StringInputStream("1784a a\n45 9867 #\nThis is a test.")); - - // Move the pointer to the space. - $s->getAsciiAlphaNum(); - $this->assertEquals(5, $s->columnOffset()); - - // We move the pointer ahead. There must be a better way to do this. - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $s->next(); - $this->assertEquals(3, $s->columnOffset()); - } - - public function testRemainingChars() - { - $string = "\n45\n9867 #\nThis is a test."; - $s = new Scanner(new StringInputStream("1784a\n45\n9867 #\nThis is a test.")); - - $s->getAsciiAlphaNum(); - $this->assertEquals($string, $s->remainingChars()); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php b/vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php deleted file mode 100644 index f87cc1066..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php +++ /dev/null @@ -1,327 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -use Masterminds\HTML5\Parser\StringInputStream; - -class StringInputStreamTest extends \Masterminds\HTML5\Tests\TestCase -{ - - /** - * A canary test to make sure the basics are setup and working. - */ - public function testConstruct() - { - $s = new StringInputStream("abc"); - - $this->assertInstanceOf('\Masterminds\HTML5\Parser\StringInputStream', $s); - } - - public function testNext() - { - $s = new StringInputStream("abc"); - - $s->next(); - $this->assertEquals('b', $s->current()); - $s->next(); - $this->assertEquals('c', $s->current()); - } - - public function testKey() - { - $s = new StringInputStream("abc"); - - $this->assertEquals(0, $s->key()); - - $s->next(); - $this->assertEquals(1, $s->key()); - } - - public function testPeek() - { - $s = new StringInputStream("abc"); - - $this->assertEquals('b', $s->peek()); - - $s->next(); - $this->assertEquals('c', $s->peek()); - } - - public function testCurrent() - { - $s = new StringInputStream("abc"); - - // Before scanning the string begins the current is empty. - $this->assertEquals('a', $s->current()); - - $s->next(); - $this->assertEquals('b', $s->current()); - - // Test movement through the string. - $s->next(); - $this->assertEquals('c', $s->current()); - } - - public function testColumnOffset() - { - $s = new StringInputStream("abc\ndef\n"); - $this->assertEquals(0, $s->columnOffset()); - $s->next(); - $this->assertEquals(1, $s->columnOffset()); - $s->next(); - $this->assertEquals(2, $s->columnOffset()); - $s->next(); - $this->assertEquals(3, $s->columnOffset()); - $s->next(); // LF - $this->assertEquals(0, $s->columnOffset()); - $s->next(); - $canary = $s->current(); // e - $this->assertEquals('e', $canary); - $this->assertEquals(1, $s->columnOffset()); - - $s = new StringInputStream("abc"); - $this->assertEquals(0, $s->columnOffset()); - $s->next(); - $this->assertEquals(1, $s->columnOffset()); - $s->next(); - $this->assertEquals(2, $s->columnOffset()); - } - - public function testCurrentLine() - { - $txt = "1\n2\n\n\n\n3"; - $stream = new StringInputStream($txt); - $this->assertEquals(1, $stream->currentLine()); - - // Advance over 1 and LF on to line 2 value 2. - $stream->next(); - $stream->next(); - $canary = $stream->current(); - $this->assertEquals(2, $stream->currentLine()); - $this->assertEquals('2', $canary); - - // Advance over 4x LF - $stream->next(); - $stream->next(); - $stream->next(); - $stream->next(); - $stream->next(); - $this->assertEquals(6, $stream->currentLine()); - $this->assertEquals('3', $stream->current()); - - // Make sure it doesn't do 7. - $this->assertEquals(6, $stream->currentLine()); - } - - public function testRemainingChars() - { - $text = "abcd"; - $s = new StringInputStream($text); - $this->assertEquals($text, $s->remainingChars()); - - $text = "abcd"; - $s = new StringInputStream($text); - $s->next(); // Pop one. - $this->assertEquals('bcd', $s->remainingChars()); - } - - public function testCharsUnitl() - { - $text = "abcdefffffffghi"; - $s = new StringInputStream($text); - $this->assertEquals('', $s->charsUntil('a')); - // Pointer at 'a', moves 2 to 'c' - $this->assertEquals('ab', $s->charsUntil('w', 2)); - - // Pointer at 'c', moves to first 'f' - $this->assertEquals('cde', $s->charsUntil('fzxv')); - - // Only get five 'f's - $this->assertEquals('fffff', $s->charsUntil('g', 5)); - - // Get just the last two 'f's - $this->assertEquals('ff', $s->charsUntil('g')); - - // This should scan to the end. - $this->assertEquals('ghi', $s->charsUntil('w', 9)); - } - - public function testCharsWhile() - { - $text = "abcdefffffffghi"; - $s = new StringInputStream($text); - - $this->assertEquals('ab', $s->charsWhile('ba')); - - $this->assertEquals('', $s->charsWhile('a')); - $this->assertEquals('cde', $s->charsWhile('cdeba')); - $this->assertEquals('ff', $s->charsWhile('f', 2)); - $this->assertEquals('fffff', $s->charsWhile('f')); - $this->assertEquals('g', $s->charsWhile('fg')); - $this->assertEquals('hi', $s->charsWhile('fghi', 99)); - } - - public function testBOM() - { - // Ignore in-text BOM. - $stream = new StringInputStream("a\xEF\xBB\xBF"); - $this->assertEquals("a\xEF\xBB\xBF", $stream->remainingChars(), 'A non-leading U+FEFF (BOM/ZWNBSP) should remain'); - - // Strip leading BOM - $leading = new StringInputStream("\xEF\xBB\xBFa"); - $this->assertEquals('a', $leading->current(), 'BOM should be stripped'); - } - - public function testCarriageReturn() - { - // Replace NULL with Unicode replacement. - $stream = new StringInputStream("\0\0\0"); - $this->assertEquals("\xEF\xBF\xBD\xEF\xBF\xBD\xEF\xBF\xBD", $stream->remainingChars(), 'Null character should be replaced by U+FFFD'); - $this->assertEquals(3, count($stream->errors), 'Null character should set parse error: ' . print_r($stream->errors, true)); - - // Remove CR when next to LF. - $stream = new StringInputStream("\r\n"); - $this->assertEquals("\n", $stream->remainingChars(), 'CRLF should be replaced by LF'); - - // Convert CR to LF when on its own. - $stream = new StringInputStream("\r"); - $this->assertEquals("\n", $stream->remainingChars(), 'CR should be replaced by LF'); - } - - public function invalidParseErrorTestHandler($input, $numErrors, $name) - { - $stream = new StringInputStream($input, 'UTF-8'); - $this->assertEquals($input, $stream->remainingChars(), $name . ' (stream content)'); - $this->assertEquals($numErrors, count($stream->errors), $name . ' (number of errors)'); - } - - public function testInvalidReplace() - { - $invalidTest = array( - - // Min/max overlong - "\xC0\x80a" => 'Overlong representation of U+0000', - "\xE0\x80\x80a" => 'Overlong representation of U+0000', - "\xF0\x80\x80\x80a" => 'Overlong representation of U+0000', - "\xF8\x80\x80\x80\x80a" => 'Overlong representation of U+0000', - "\xFC\x80\x80\x80\x80\x80a" => 'Overlong representation of U+0000', - "\xC1\xBFa" => 'Overlong representation of U+007F', - "\xE0\x9F\xBFa" => 'Overlong representation of U+07FF', - "\xF0\x8F\xBF\xBFa" => 'Overlong representation of U+FFFF', - - "a\xDF" => 'Incomplete two byte sequence (missing final byte)', - "a\xEF\xBF" => 'Incomplete three byte sequence (missing final byte)', - "a\xF4\xBF\xBF" => 'Incomplete four byte sequence (missing final byte)', - - // Min/max continuation bytes - "a\x80" => 'Lone 80 continuation byte', - "a\xBF" => 'Lone BF continuation byte', - - // Invalid bytes (these can never occur) - "a\xFE" => 'Invalid FE byte', - "a\xFF" => 'Invalid FF byte' - ); - foreach ($invalidTest as $test => $note) { - $stream = new StringInputStream($test); - $this->assertEquals('a', $stream->remainingChars(), $note); - } - - // MPB: - // It appears that iconv just leaves these alone. Not sure what to - // do. - /* - * $converted = array( "a\xF5\x90\x80\x80" => 'U+110000, off unicode planes.', ); foreach ($converted as $test => $note) { $stream = new StringInputStream($test); $this->assertEquals(2, mb_strlen($stream->remainingChars()), $note); } - */ - } - - public function testInvalidParseError() - { - // C0 controls (except U+0000 and U+000D due to different handling) - $this->invalidParseErrorTestHandler("\x01", 1, 'U+0001 (C0 control)'); - $this->invalidParseErrorTestHandler("\x02", 1, 'U+0002 (C0 control)'); - $this->invalidParseErrorTestHandler("\x03", 1, 'U+0003 (C0 control)'); - $this->invalidParseErrorTestHandler("\x04", 1, 'U+0004 (C0 control)'); - $this->invalidParseErrorTestHandler("\x05", 1, 'U+0005 (C0 control)'); - $this->invalidParseErrorTestHandler("\x06", 1, 'U+0006 (C0 control)'); - $this->invalidParseErrorTestHandler("\x07", 1, 'U+0007 (C0 control)'); - $this->invalidParseErrorTestHandler("\x08", 1, 'U+0008 (C0 control)'); - $this->invalidParseErrorTestHandler("\x09", 0, 'U+0009 (C0 control)'); - $this->invalidParseErrorTestHandler("\x0A", 0, 'U+000A (C0 control)'); - $this->invalidParseErrorTestHandler("\x0B", 1, 'U+000B (C0 control)'); - $this->invalidParseErrorTestHandler("\x0C", 0, 'U+000C (C0 control)'); - $this->invalidParseErrorTestHandler("\x0E", 1, 'U+000E (C0 control)'); - $this->invalidParseErrorTestHandler("\x0F", 1, 'U+000F (C0 control)'); - $this->invalidParseErrorTestHandler("\x10", 1, 'U+0010 (C0 control)'); - $this->invalidParseErrorTestHandler("\x11", 1, 'U+0011 (C0 control)'); - $this->invalidParseErrorTestHandler("\x12", 1, 'U+0012 (C0 control)'); - $this->invalidParseErrorTestHandler("\x13", 1, 'U+0013 (C0 control)'); - $this->invalidParseErrorTestHandler("\x14", 1, 'U+0014 (C0 control)'); - $this->invalidParseErrorTestHandler("\x15", 1, 'U+0015 (C0 control)'); - $this->invalidParseErrorTestHandler("\x16", 1, 'U+0016 (C0 control)'); - $this->invalidParseErrorTestHandler("\x17", 1, 'U+0017 (C0 control)'); - $this->invalidParseErrorTestHandler("\x18", 1, 'U+0018 (C0 control)'); - $this->invalidParseErrorTestHandler("\x19", 1, 'U+0019 (C0 control)'); - $this->invalidParseErrorTestHandler("\x1A", 1, 'U+001A (C0 control)'); - $this->invalidParseErrorTestHandler("\x1B", 1, 'U+001B (C0 control)'); - $this->invalidParseErrorTestHandler("\x1C", 1, 'U+001C (C0 control)'); - $this->invalidParseErrorTestHandler("\x1D", 1, 'U+001D (C0 control)'); - $this->invalidParseErrorTestHandler("\x1E", 1, 'U+001E (C0 control)'); - $this->invalidParseErrorTestHandler("\x1F", 1, 'U+001F (C0 control)'); - - // DEL (U+007F) - $this->invalidParseErrorTestHandler("\x7F", 1, 'U+007F'); - - // C1 Controls - $this->invalidParseErrorTestHandler("\xC2\x80", 1, 'U+0080 (C1 control)'); - $this->invalidParseErrorTestHandler("\xC2\x9F", 1, 'U+009F (C1 control)'); - $this->invalidParseErrorTestHandler("\xC2\xA0", 0, 'U+00A0 (first codepoint above highest C1 control)'); - - // Charcters surrounding surrogates - $this->invalidParseErrorTestHandler("\xED\x9F\xBF", 0, 'U+D7FF (one codepoint below lowest surrogate codepoint)'); - $this->invalidParseErrorTestHandler("\xEF\xBF\xBD", 0, 'U+DE00 (one codepoint above highest surrogate codepoint)'); - - // Permanent noncharacters - $this->invalidParseErrorTestHandler("\xEF\xB7\x90", 1, 'U+FDD0 (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xEF\xB7\xAF", 1, 'U+FDEF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xEF\xBF\xBE", 1, 'U+FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xEF\xBF\xBF", 1, 'U+FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\x9F\xBF\xBE", 1, 'U+1FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\x9F\xBF\xBF", 1, 'U+1FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\xAF\xBF\xBE", 1, 'U+2FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\xAF\xBF\xBF", 1, 'U+2FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\xBF\xBF\xBE", 1, 'U+3FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF0\xBF\xBF\xBF", 1, 'U+3FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\x8F\xBF\xBE", 1, 'U+4FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\x8F\xBF\xBF", 1, 'U+4FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\x9F\xBF\xBE", 1, 'U+5FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\x9F\xBF\xBF", 1, 'U+5FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\xAF\xBF\xBE", 1, 'U+6FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\xAF\xBF\xBF", 1, 'U+6FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\xBF\xBF\xBE", 1, 'U+7FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF1\xBF\xBF\xBF", 1, 'U+7FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\x8F\xBF\xBE", 1, 'U+8FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\x8F\xBF\xBF", 1, 'U+8FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\x9F\xBF\xBE", 1, 'U+9FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\x9F\xBF\xBF", 1, 'U+9FFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\xAF\xBF\xBE", 1, 'U+AFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\xAF\xBF\xBF", 1, 'U+AFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\xBF\xBF\xBE", 1, 'U+BFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF2\xBF\xBF\xBF", 1, 'U+BFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\x8F\xBF\xBE", 1, 'U+CFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\x8F\xBF\xBF", 1, 'U+CFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\x9F\xBF\xBE", 1, 'U+DFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\x9F\xBF\xBF", 1, 'U+DFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\xAF\xBF\xBE", 1, 'U+EFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\xAF\xBF\xBF", 1, 'U+EFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\xBF\xBF\xBE", 1, 'U+FFFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF3\xBF\xBF\xBF", 1, 'U+FFFFF (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF4\x8F\xBF\xBE", 1, 'U+10FFFE (permanent noncharacter)'); - $this->invalidParseErrorTestHandler("\xF4\x8F\xBF\xBF", 1, 'U+10FFFF (permanent noncharacter)'); - - // MPB: These pass on some versions of iconv, and fail on others. Since we aren't in the - // business of writing tests against iconv, I've just commented these out. Should revisit - // at a later point. - /* - * $this->invalidParseErrorTestHandler("\xED\xA0\x80", 1, 'U+D800 (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xAD\xBF", 1, 'U+DB7F (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xAE\x80", 1, 'U+DB80 (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xAF\xBF", 1, 'U+DBFF (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xB0\x80", 1, 'U+DC00 (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xBE\x80", 1, 'U+DF80 (UTF-16 surrogate character)'); $this->invalidParseErrorTestHandler("\xED\xBF\xBF", 1, 'U+DFFF (UTF-16 surrogate character)'); // Paired UTF-16 surrogates $this->invalidParseErrorTestHandler("\xED\xA0\x80\xED\xB0\x80", 2, 'U+D800 U+DC00 (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xA0\x80\xED\xBF\xBF", 2, 'U+D800 U+DFFF (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAD\xBF\xED\xB0\x80", 2, 'U+DB7F U+DC00 (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAD\xBF\xED\xBF\xBF", 2, 'U+DB7F U+DFFF (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAE\x80\xED\xB0\x80", 2, 'U+DB80 U+DC00 (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAE\x80\xED\xBF\xBF", 2, 'U+DB80 U+DFFF (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAF\xBF\xED\xB0\x80", 2, 'U+DBFF U+DC00 (paired UTF-16 surrogates)'); $this->invalidParseErrorTestHandler("\xED\xAF\xBF\xED\xBF\xBF", 2, 'U+DBFF U+DFFF (paired UTF-16 surrogates)'); - */ - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php b/vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php deleted file mode 100644 index 3d834fd19..000000000 --- a/vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php +++ /dev/null @@ -1,970 +0,0 @@ -<?php -namespace Masterminds\HTML5\Tests\Parser; - -use Masterminds\HTML5\Parser\UTF8Utils; -use Masterminds\HTML5\Parser\StringInputStream; -use Masterminds\HTML5\Parser\Scanner; -use Masterminds\HTML5\Parser\Tokenizer; - -class TokenizerTest extends \Masterminds\HTML5\Tests\TestCase -{ - // ================================================================ - // Additional assertions. - // ================================================================ - /** - * Tests that an event matches both the event type and the expected value. - * - * @param string $type - * Expected event type. - * @param string $expects - * The value expected in $event['data'][0]. - */ - public function assertEventEquals($type, $expects, $event) - { - $this->assertEquals($type, $event['name'], "Event $type for " . print_r($event, true)); - if (is_array($expects)) { - $this->assertEquals($expects, $event['data'], "Event $type should equal " . print_r($expects, true) . ": " . print_r($event, true)); - } else { - $this->assertEquals($expects, $event['data'][0], "Event $type should equal $expects: " . print_r($event, true)); - } - } - - /** - * Assert that a given event is 'error'. - */ - public function assertEventError($event) - { - $this->assertEquals('error', $event['name'], "Expected error for event: " . print_r($event, true)); - } - - /** - * Asserts that all of the tests are good. - * - * This loops through a map of tests/expectations and runs a few assertions on each test. - * - * Checks: - * - depth (if depth is > 0) - * - event name - * - matches on event 0. - */ - protected function isAllGood($name, $depth, $tests, $debug = false) - { - foreach ($tests as $try => $expects) { - if ($debug) { - fprintf(STDOUT, "%s expects %s\n", $try, print_r($expects, true)); - } - $e = $this->parse($try); - if ($depth > 0) { - $this->assertEquals($depth, $e->depth(), "Expected depth $depth for test $try." . print_r($e, true)); - } - $this->assertEventEquals($name, $expects, $e->get(0)); - } - } - - // ================================================================ - // Utility functions. - // ================================================================ - public function testParse() - { - list ($tok, $events) = $this->createTokenizer(''); - - $tok->parse(); - $e1 = $events->get(0); - - $this->assertEquals(1, $events->Depth()); - $this->assertEquals('eof', $e1['name']); - } - - public function testWhitespace() - { - $spaces = ' '; - list ($tok, $events) = $this->createTokenizer($spaces); - - $tok->parse(); - - $this->assertEquals(2, $events->depth()); - - $e1 = $events->get(0); - - $this->assertEquals('text', $e1['name']); - $this->assertEquals($spaces, $e1['data'][0]); - } - - public function testCharacterReference() - { - $good = array( - '&amp;' => '&', - '&#x0003c;' => '<', - '&#38;' => '&', - '&' => '&' - ); - $this->isAllGood('text', 2, $good); - - // Test with broken charref - $str = '&foo'; - $events = $this->parse($str); - $e1 = $events->get(0); - $this->assertEquals('error', $e1['name']); - - $str = '&#xfoo'; - $events = $this->parse($str); - $e1 = $events->get(0); - $this->assertEquals('error', $e1['name']); - - $str = '&#foo'; - $events = $this->parse($str); - $e1 = $events->get(0); - $this->assertEquals('error', $e1['name']); - - // FIXME: Once the text processor is done, need to verify that the - // tokens are transformed correctly into text. - } - - public function testBogusComment() - { - $bogus = array( - '</+this is a bogus comment. +>', - '<!+this is a bogus comment. !>', - '<!D OCTYPE foo bar>', - '<!DOCTYEP foo bar>', - '<![CADATA[ TEST ', - '', - ' Hello [[>', - '<!CDATA[[ test ', - '', - '<![CDATA[hellooooo hello', - '<? Hello World ?>', - '<? Hello World' - ); - foreach ($bogus as $str) { - $events = $this->parse($str); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('comment', $str, $events->get(1)); - } - } - - public function testEndTag() - { - $succeed = array( - '</a>' => 'a', - '</test>' => 'test', - '</test - >' => 'test', - '</thisIsTheTagThatDoesntEndItJustGoesOnAndOnMyFriend>' => 'thisisthetagthatdoesntenditjustgoesonandonmyfriend', - // See 8.2.4.10, which requires this and does not say error. - '</a<b>' => 'a<b' - ); - $this->isAllGood('endTag', 2, $succeed); - - // Recoverable failures - $fail = array( - '</a class="monkey">' => 'a', - '</a <b>' => 'a', - '</a <b <c>' => 'a', - '</a is the loneliest letter>' => 'a', - '</a' => 'a' - ); - foreach ($fail as $test => $result) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth()); - // Should have triggered an error. - $this->assertEventError($events->get(0)); - // Should have tried to parse anyway. - $this->assertEventEquals('endTag', $result, $events->get(1)); - } - - // BogoComments - $comments = array( - '</>' => '</>', - '</ >' => '</ >', - '</ a>' => '</ a>' - ); - foreach ($comments as $test => $result) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth()); - - // Should have triggered an error. - $this->assertEventError($events->get(0)); - - // Should have tried to parse anyway. - $this->assertEventEquals('comment', $result, $events->get(1)); - } - } - - public function testComment() - { - $good = array( - '<!--easy-->' => 'easy', - '<!-- 1 > 0 -->' => ' 1 > 0 ', - '<!-- --$i -->' => ' --$i ', - '<!----$i-->' => '--$i', - '<!-- 1 > 0 -->' => ' 1 > 0 ', - "<!--\nHello World.\na-->" => "\nHello World.\na", - '<!-- <!-- -->' => ' <!-- ' - ); - foreach ($good as $test => $expected) { - $events = $this->parse($test); - $this->assertEventEquals('comment', $expected, $events->get(0)); - } - - $fail = array( - '<!-->' => '', - '<!--Hello' => 'Hello', - "<!--\0Hello" => UTF8Utils::FFFD . 'Hello', - '<!--' => '' - ); - foreach ($fail as $test => $expected) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth()); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('comment', $expected, $events->get(1)); - } - } - - public function testCDATASection() - { - $good = array( - '<![CDATA[ This is a test. ' => ' This is a test. ', - 'CDATA' => 'CDATA', - ' ]] > ' => ' ]] > ', - ' ' => ' ' - ); - $this->isAllGood('cdata', 2, $good); - } - - public function testDoctype() - { - $good = array( - '' => array( - 'html', - 0, - null, - false - ), - '' => array( - 'html', - 0, - null, - false - ), - '' => array( - 'html', - 0, - null, - false - ), - "" => array( - 'html', - 0, - null, - false - ), - "" => array( - 'html', - 0, - null, - false - ), - '' => array( - 'html', - EventStack::DOCTYPE_PUBLIC, - 'foo bar', - false - ), - "" => array( - 'html', - EventStack::DOCTYPE_PUBLIC, - 'foo bar', - false - ), - '' => array( - 'html', - EventStack::DOCTYPE_PUBLIC, - 'foo bar', - false - ), - "" => array( - 'html', - EventStack::DOCTYPE_PUBLIC, - 'foo bar', - false - ), - '' => array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo bar', - false - ), - "" => array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo bar', - false - ), - '' => array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo/bar', - false - ), - "" => array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo bar', - false - ) - ); - $this->isAllGood('doctype', 2, $good); - - $bad = array( - '' => array( - null, - EventStack::DOCTYPE_NONE, - null, - true - ), - '' => array( - null, - EventStack::DOCTYPE_NONE, - null, - true - ), - ' array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - ' array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - '' => array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - '' => array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - ' array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - - // Can't tell whether these are ids or ID types, since the context is chopped. - ' array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - '' => array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - ' array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - '' => array( - 'foo', - EventStack::DOCTYPE_NONE, - null, - true - ), - - ' array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo bar', - true - ), - '' => array( - 'html', - EventStack::DOCTYPE_SYSTEM, - 'foo bar', - true - ) - ); - foreach ($bad as $test => $expects) { - $events = $this->parse($test); - // fprintf(STDOUT, $test . PHP_EOL); - $this->assertEquals(3, $events->depth(), "Counting events for '$test': " . print_r($events, true)); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('doctype', $expects, $events->get(1)); - } - } - - public function testProcessorInstruction() - { - $good = array( - '' => 'hph', - '' => array( - 'hph', - 'echo "Hello World"; ' - ), - "" => array( - 'hph', - "echo 'Hello World';\n" - ) - ); - $this->isAllGood('pi', 2, $good); - } - - /** - * This tests just simple tags. - */ - public function testSimpleTags() - { - $open = array( - '' => 'foo', - '' => 'foo', - '' => 'foo', - '' => 'foo', - "" => 'foo', - '' => 'foo:bar' - ); - $this->isAllGood('startTag', 2, $open); - - $selfClose = array( - '' => 'foo', - '' => 'foo', - '' => 'foo', - "" => 'foo', - '' => 'foo:bar' - ); - foreach ($selfClose as $test => $expects) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth(), "Counting events for '$test'" . print_r($events, true)); - $this->assertEventEquals('startTag', $expects, $events->get(0)); - $this->assertEventEquals('endTag', $expects, $events->get(1)); - } - - $bad = array( - ' 'foo', - ' 'foo', - ' 'foo', - ' 'foo' - ); - - foreach ($bad as $test => $expects) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth(), "Counting events for '$test': " . print_r($events, true)); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', $expects, $events->get(1)); - } - } - - public function testTagsWithAttributeAndMissingName() - { - $cases = array( - '' => 'id', - '' => 'color', - "" => 'class', - '' => 'bgcolor', - '' => 'class' - ); - - foreach ($cases as $html => $expected) { - $events = $this->parse($html); - $this->assertEventError($events->get(0)); - $this->assertEventError($events->get(1)); - $this->assertEventError($events->get(2)); - $this->assertEventEquals('startTag', $expected, $events->get(3)); - $this->assertEventEquals('eof', null, $events->get(4)); - } - } - - public function testTagNotClosedAfterTagName() - { - $cases = array( - "" => array( - 'noscript', - 'img' - ), - '' => array( - 'center', - 'a' - ), - '' => array( - 'br', - 'br' - ) - ); - - foreach ($cases as $html => $expected) { - $events = $this->parse($html); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', $expected[0], $events->get(1)); - $this->assertEventEquals('startTag', $expected[1], $events->get(2)); - $this->assertEventEquals('eof', null, $events->get(3)); - } - - $events = $this->parse('02'); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', 'span', $events->get(1)); - $this->assertEventError($events->get(2)); - $this->assertEventEquals('text', '>02', $events->get(3)); - $this->assertEventEquals('endTag', 'span', $events->get(4)); - $this->assertEventEquals('eof', null, $events->get(5)); - - $events = $this->parse(''); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', 'p', $events->get(1)); - $this->assertEventEquals('endTag', 'p', $events->get(2)); - $this->assertEventEquals('eof', null, $events->get(3)); - - $events = $this->parse(''); - $this->assertEventEquals('startTag', 'strong', $events->get(0)); - $this->assertEventError($events->get(1)); - $this->assertEventEquals('startTag', 'wordpress', $events->get(2)); - $this->assertEventEquals('endTag', 'strong', $events->get(3)); - $this->assertEventEquals('eof', null, $events->get(4)); - - $events = $this->parse(''); - $this->assertEventError($events->get(0)); - $this->assertEventError($events->get(1)); - $this->assertEventError($events->get(2)); - $this->assertEventEquals('startTag', 'src', $events->get(3)); - $this->assertEventEquals('startTag', 'a', $events->get(4)); - $this->assertEventEquals('eof', null, $events->get(5)); - - $events = $this->parse(''); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', 'br', $events->get(1)); - $this->assertEventEquals('eof', null, $events->get(2)); - } - - public function testIllegalTagNames() - { - $cases = array( - '' => 'li', - '' => 'p', - '' => 'b', - '' => 'static', - '' => 'h', - '' => 'st', - ); - - foreach ($cases as $html => $expected) { - $events = $this->parse($html); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', $expected, $events->get(1)); - } - } - - /** - * @depends testCharacterReference - */ - public function testTagAttributes() - { - // Opening tags. - $good = array( - '' => array( - 'foo', - array( - 'bar' => 'baz' - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => ' baz ' - ), - false - ), - "" => array( - 'foo', - array( - 'bar' => "\nbaz\n" - ), - false - ), - "" => array( - 'foo', - array( - 'bar' => 'baz' - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => 'A full sentence.' - ), - false - ), - "" => array( - 'foo', - array( - 'a' => '1', - 'b' => '2' - ), - false - ), - "" => array( - 'foo', - array( - 'ns:bar' => 'baz' - ), - false - ), - "" => array( - 'foo', - array( - 'a' => 'blue&red' - ), - false - ), - "" => array( - 'foo', - array( - 'a' => 'blue&&red' - ), - false - ), - "" => array( - 'foo', - array( - 'bar' => 'baz' - ), - false - ), - '' => array( - 'doe', - array( - 'a' => null, - 'deer' => null - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => 'baz' - ), - false - ), - - // Updated for 8.1.2.3 - '' => array( - 'foo', - array( - 'bar' => 'baz' - ), - false - ), - - // The spec allows an unquoted value '/'. This will not be a closing - // tag. - '' => array( - 'foo', - array( - 'bar' => '/' - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => 'baz/' - ), - false - ) - ); - $this->isAllGood('startTag', 2, $good); - - // Self-closing tags. - $withEnd = array( - '' => array( - 'foo', - array( - 'bar' => 'baz' - ), - true - ), - '' => array( - 'foo', - array( - 'bar' => 'baz' - ), - true - ), - '' => array( - 'foo', - array( - 'bar' => 'BAZ' - ), - true - ), - "" => array( - 'foo', - array( - 'a' => '1', - 'b' => '2', - 'c' => '3', - 'd' => null - ), - true - ) - ); - $this->isAllGood('startTag', 3, $withEnd); - - // Cause a parse error. - $bad = array( - // This will emit an entity lookup failure for &red. - "" => array( - 'foo', - array( - 'a' => 'blue&red' - ), - false - ), - "" => array( - 'foo', - array( - 'a' => 'blue&&&red' - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => null - ), - false - ), - '' => array( - 'foo', - array( - 'bar' => 'oh"' - ), - false - ), - - // these attributes are ignored because of current implementation - // of method "DOMElement::setAttribute" - // see issue #23: https://github.com/Masterminds/html5-php/issues/23 - '' => array( - 'foo', - array(), - false - ), - '' => array( - 'foo', - array(), - false - ), - '' => array( - 'foo', - array(), - false - ), - '' => array( - 'foo', - array(), - false - ) - ) - ; - foreach ($bad as $test => $expects) { - $events = $this->parse($test); - $this->assertEquals(3, $events->depth(), "Counting events for '$test': " . print_r($events, true)); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', $expects, $events->get(1)); - } - - // Cause multiple parse errors. - $reallyBad = array( - '' => array( - 'foo', - array( - '=' => null, - '"bar"' => null - ), - false - ), - '' => array( - 'foo', - array(), - true - ), - // character "&" in unquoted attribute shouldn't cause an infinite loop - '' => array( - 'foo', - array( - 'bar' => 'index.php?str=1&id=29' - ), - false - ) - ); - foreach ($reallyBad as $test => $expects) { - $events = $this->parse($test); - // fprintf(STDOUT, $test . print_r($events, true)); - $this->assertEventError($events->get(0)); - $this->assertEventError($events->get(1)); - // $this->assertEventEquals('startTag', $expects, $events->get(1)); - } - - // Regression: Malformed elements should be detected. - // '' => array('foo', array('baz' => '1'), false), - $events = $this->parse(''); - $this->assertEventError($events->get(0)); - $this->assertEventEquals('startTag', array( - 'foo', - array( - 'baz' => '1' - ), - false - ), $events->get(1)); - $this->assertEventEquals('startTag', array( - 'bar', - array(), - false - ), $events->get(2)); - $this->assertEventEquals('endTag', array( - 'foo' - ), $events->get(3)); - } - - public function testRawText() - { - $good = array( - ' ' => 'abcd efg hijk lmnop', - '' => '', - '' => '<<<<<<<<', - '' => 'hello\nhello" => "\nhello&' => '&', - '' => '', - '' => '' - ); - foreach ($good as $test => $expects) { - $events = $this->parse($test); - $this->assertEventEquals('startTag', 'script', $events->get(0)); - $this->assertEventEquals('text', $expects, $events->get(1)); - $this->assertEventEquals('endTag', 'script', $events->get(2)); - } - - $bad = array( - ' - - -
    foo bar baz
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $script = $dom->getElementsByTagName('script'); - $r->element($script->item(0)); - $this->assertEquals( - '', stream_get_contents($stream, - 1, 0)); - } - - public function testElementWithStyle() - { - $dom = $this->html5->loadHTML( - ' - - - - - -
    foo bar baz
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $style = $dom->getElementsByTagName('style'); - $r->element($style->item(0)); - $this->assertEquals('', stream_get_contents($stream, - 1, 0)); - } - - public function testOpenTag() - { - $dom = $this->html5->loadHTML(' - - -
    foo bar baz
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('div'); - $m = $this->getProtectedMethod('openTag'); - $m->invoke($r, $list->item(0)); - $this->assertEquals('
    ', stream_get_contents($stream, - 1, 0)); - } - - public function testCData() - { - $dom = $this->html5->loadHTML(' - - -
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('div'); - $r->cdata($list->item(0)->childNodes->item(0)); - $this->assertEquals('', stream_get_contents($stream, - 1, 0)); - - $dom = $this->html5->loadHTML(' - - -
    - - '); - - $dom->getElementById('foo')->appendChild(new \DOMCdataSection("]]>Foo<[![CDATA test ]]>")); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - $list = $dom->getElementsByTagName('div'); - $r->cdata($list->item(0)->childNodes->item(0)); - - $this->assertEquals('Foo<[![CDATA test ]]]]>]]>', stream_get_contents($stream, - 1, 0)); - } - - public function testComment() - { - $dom = $this->html5->loadHTML(' - - -
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('div'); - $r->comment($list->item(0)->childNodes->item(0)); - $this->assertEquals('', stream_get_contents($stream, - 1, 0)); - - $dom = $this->html5->loadHTML(' - - -
    - - '); - $dom->getElementById('foo')->appendChild(new \DOMComment(' --> Foo -->')); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('div'); - $r->comment($list->item(0)->childNodes->item(0)); - - // Could not find more definitive guidelines on what this should be. Went with - // what the HTML5 spec says and what \DOMDocument::saveXML() produces. - $this->assertEquals(' --> Foo -->-->', stream_get_contents($stream, - 1, 0)); - } - - public function testText() - { - $dom = $this->html5->loadHTML(' - - - - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('script'); - $r->text($list->item(0)->childNodes->item(0)); - $this->assertEquals('baz();', stream_get_contents($stream, - 1, 0)); - - $dom = $this->html5->loadHTML(' - - - '); - $foo = $dom->getElementById('foo'); - $foo->appendChild(new \DOMText('')); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $r->text($foo->firstChild); - $this->assertEquals('<script>alert("hi");</script>', stream_get_contents($stream, - 1, 0)); - } - - public function testNl() - { - list ($o, $s) = $this->getOutputRules(); - - $m = $this->getProtectedMethod('nl'); - $m->invoke($o); - $this->assertEquals(PHP_EOL, stream_get_contents($s, - 1, 0)); - } - - public function testWr() - { - list ($o, $s) = $this->getOutputRules(); - - $m = $this->getProtectedMethod('wr'); - $m->invoke($o, 'foo'); - $this->assertEquals('foo', stream_get_contents($s, - 1, 0)); - } - - public function getEncData() - { - return array( - array( - false, - '&\'<>"', - '&\'<>"', - '&'<>"' - ), - array( - false, - 'This + is. a < test', - 'This + is. a < test', - 'This + is. a < test' - ), - array( - false, - '.+#', - '.+#', - '.+#' - ), - - array( - true, - '.+#\'', - '.+#\'', - '.+#'' - ), - array( - true, - '&".<', - '&".<', - '&".<' - ), - array( - true, - '&\'<>"', - '&\'<>"', - '&'<>"' - ), - array( - true, - "\xc2\xa0\"'", - ' "\'', - ' "'' - ) - ); - } - - /** - * Test basic encoding of text. - * @dataProvider getEncData - */ - public function testEnc($isAttribute, $test, $expected, $expectedEncoded) - { - list ($o, $s) = $this->getOutputRules(); - $m = $this->getProtectedMethod('enc'); - - $this->assertEquals($expected, $m->invoke($o, $test, $isAttribute)); - - list ($o, $s) = $this->getOutputRules(array( - 'encode_entities' => true - )); - $m = $this->getProtectedMethod('enc'); - $this->assertEquals($expectedEncoded, $m->invoke($o, $test, $isAttribute)); - } - - /** - * Test basic encoding of text. - * @dataProvider getEncData - */ - public function testEscape($isAttribute, $test, $expected, $expectedEncoded) - { - list ($o, $s) = $this->getOutputRules(); - $m = $this->getProtectedMethod('escape'); - - $this->assertEquals($expected, $m->invoke($o, $test, $isAttribute)); - } - - public function booleanAttributes() - { - return array( - array(''), - array(''), - array(''), - array(''), - array(''), - array(''), - array('
    '), - array(''), - array('
    '), - array(''), - ); - } - /** - * @dataProvider booleanAttributes - */ - public function testBooleanAttrs($html) - { - $dom = $this->html5->loadHTML(''.$html.''); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $node = $dom->getElementsByTagName('body')->item(0)->firstChild; - - $m = $this->getProtectedMethod('attrs'); - $m->invoke($r, $node); - - $content = stream_get_contents($stream, - 1, 0); - - $html = preg_replace('~<[a-z]+(.*)>~', '\1', $html); - $html = preg_replace('~<[a-z]+(.*)/?>~', '\1', $html); - - $this->assertEquals($content, $html); - - } - - public function testAttrs() - { - $dom = $this->html5->loadHTML(' - - -
    foo bar baz
    - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('div'); - - $m = $this->getProtectedMethod('attrs'); - $m->invoke($r, $list->item(0)); - - $content = stream_get_contents($stream, - 1, 0); - $this->assertEquals(' id="foo" class="bar baz"', $content); - } - - public function testSvg() - { - $dom = $this->html5->loadHTML( - ' - - -
    foo bar baz
    - - - - - - - - - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('svg'); - $r->element($list->item(0)); - $contents = stream_get_contents($stream, - 1, 0); - $this->assertRegExp('||', $contents); - $this->assertRegExp('||', $contents); - $this->assertRegExp('||', $contents); - } - - public function testMath() - { - $dom = $this->html5->loadHTML( - ' - - -
    foo bar baz
    - - x - - ± - - y - - - '); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $list = $dom->getElementsByTagName('math'); - $r->element($list->item(0)); - $content = stream_get_contents($stream, - 1, 0); - $this->assertRegExp('||', $content); - $this->assertRegExp('||', $content); - } - - public function testProcessorInstruction() - { - $dom = $this->html5->loadHTMLFragment(''); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $r->processorInstruction($dom->firstChild); - $content = stream_get_contents($stream, - 1, 0); - $this->assertRegExp('|<\?foo bar \?>|', $content); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/Serializer/TraverserTest.php b/vendor/masterminds/html5/test/HTML5/Serializer/TraverserTest.php deleted file mode 100644 index c91463370..000000000 --- a/vendor/masterminds/html5/test/HTML5/Serializer/TraverserTest.php +++ /dev/null @@ -1,105 +0,0 @@ - - - - - Test - - -

    This is a test.

    - - '; - - public function setUp() - { - $this->html5 = $this->getInstance(); - } - - /** - * Using reflection we make a protected method accessible for testing. - * - * @param string $name - * The name of the method on the Traverser class to test. - * - * @return \ReflectionMethod \ReflectionMethod for the specified method - */ - public function getProtectedMethod($name) - { - $class = new \ReflectionClass('\Masterminds\HTML5\Serializer\Traverser'); - $method = $class->getMethod($name); - $method->setAccessible(true); - - return $method; - } - - public function getTraverser() - { - $stream = fopen('php://temp', 'w'); - - $dom = $this->html5->loadHTML($this->markup); - $t = new Traverser($dom, $stream, $html5->getOptions()); - - // We return both the traverser and stream so we can pull from it. - return array( - $t, - $stream - ); - } - - public function testConstruct() - { - // The traverser needs a place to write the output to. In our case we - // use a stream in temp space. - $stream = fopen('php://temp', 'w'); - - $html5 = $this->getInstance(); - - $r = new OutputRules($stream, $this->html5->getOptions()); - $dom = $this->html5->loadHTML($this->markup); - - $t = new Traverser($dom, $stream, $r, $html5->getOptions()); - - $this->assertInstanceOf('\Masterminds\HTML5\Serializer\Traverser', $t); - } - - public function testFragment() - { - $html = 'foo
    bar
    '; - $input = new \Masterminds\HTML5\Parser\StringInputStream($html); - $dom = $this->html5->parseFragment($input); - - $this->assertInstanceOf('\DOMDocumentFragment', $dom); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $out = $t->walk(); - $this->assertEquals($html, stream_get_contents($stream, - 1, 0)); - } - - public function testProcessorInstruction() - { - $html = ''; - $input = new \Masterminds\HTML5\Parser\StringInputStream($html); - $dom = $this->html5->parseFragment($input); - - $this->assertInstanceOf('\DOMDocumentFragment', $dom); - - $stream = fopen('php://temp', 'w'); - $r = new OutputRules($stream, $this->html5->getOptions()); - $t = new Traverser($dom, $stream, $r, $this->html5->getOptions()); - - $out = $t->walk(); - $this->assertEquals($html, stream_get_contents($stream, - 1, 0)); - } -} diff --git a/vendor/masterminds/html5/test/HTML5/TestCase.php b/vendor/masterminds/html5/test/HTML5/TestCase.php deleted file mode 100644 index 3cb864547..000000000 --- a/vendor/masterminds/html5/test/HTML5/TestCase.php +++ /dev/null @@ -1,27 +0,0 @@ -test'; - - const DOC_CLOSE = ''; - - public function testFoo() - { - // Placeholder. Why is PHPUnit emitting warnings about no tests? - } - - public function getInstance(array $options = array()) - { - return new HTML5($options); - } - - protected function wrap($fragment) - { - return self::DOC_OPEN . $fragment . self::DOC_CLOSE; - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/DirectoryIterationTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/DirectoryIterationTestCase.php deleted file mode 100644 index 4f30b038b..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/DirectoryIterationTestCase.php +++ /dev/null @@ -1,318 +0,0 @@ -assertEquals($expectedCount, - $actualCount, - 'Directory foo contains ' . $expectedCount . ' children, but got ' . $actualCount . ' children while iterating over directory contents' - ); - } - - /** - * @param \Closure $dotFilesSwitch - * @param string[] $expectedDirectories - * @test - * @dataProvider provideSwitchWithExpectations - */ - public function directoryIteration(\Closure $dotFilesSwitch, array $expectedDirectories) - { - $dotFilesSwitch(); - $dir = dir($this->fooURL); - $i = 0; - while (false !== ($entry = $dir->read())) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - $dir->rewind(); - $i = 0; - while (false !== ($entry = $dir->read())) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - $dir->close(); - } - - /** - * @param \Closure $dotFilesSwitch - * @param string[] $expectedDirectories - * @test - * @dataProvider provideSwitchWithExpectations - */ - public function directoryIterationWithDot(\Closure $dotFilesSwitch, array $expectedDirectories) - { - $dotFilesSwitch(); - $dir = dir($this->fooURL . '/.'); - $i = 0; - while (false !== ($entry = $dir->read())) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - $dir->rewind(); - $i = 0; - while (false !== ($entry = $dir->read())) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - $dir->close(); - } - - /** - * assure that a directory iteration works as expected - * - * @param \Closure $dotFilesSwitch - * @param string[] $expectedDirectories - * @test - * @dataProvider provideSwitchWithExpectations - * @group regression - * @group bug_2 - */ - public function directoryIterationWithOpenDir_Bug_2(\Closure $dotFilesSwitch, array $expectedDirectories) - { - $dotFilesSwitch(); - $handle = opendir($this->fooURL); - $i = 0; - while (false !== ($entry = readdir($handle))) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - - rewinddir($handle); - $i = 0; - while (false !== ($entry = readdir($handle))) { - $i++; - $this->assertTrue(in_array($entry, $expectedDirectories)); - } - - $this->assertDirectoryCount(count($expectedDirectories), $i); - closedir($handle); - } - - /** - * assure that a directory iteration works as expected - * - * @author Christoph Bloemer - * @param \Closure $dotFilesSwitch - * @param string[] $expectedDirectories - * @test - * @dataProvider provideSwitchWithExpectations - * @group regression - * @group bug_4 - */ - public function directoryIteration_Bug_4(\Closure $dotFilesSwitch, array $expectedDirectories) - { - $dotFilesSwitch(); - $dir = $this->fooURL; - $list1 = array(); - if ($handle = opendir($dir)) { - while (false !== ($listItem = readdir($handle))) { - if ('.' != $listItem && '..' != $listItem) { - if (is_file($dir . '/' . $listItem) === true) { - $list1[] = 'File:[' . $listItem . ']'; - } elseif (is_dir($dir . '/' . $listItem) === true) { - $list1[] = 'Folder:[' . $listItem . ']'; - } - } - } - - closedir($handle); - } - - $list2 = array(); - if ($handle = opendir($dir)) { - while (false !== ($listItem = readdir($handle))) { - if ('.' != $listItem && '..' != $listItem) { - if (is_file($dir . '/' . $listItem) === true) { - $list2[] = 'File:[' . $listItem . ']'; - } elseif (is_dir($dir . '/' . $listItem) === true) { - $list2[] = 'Folder:[' . $listItem . ']'; - } - } - } - - closedir($handle); - } - - $this->assertEquals($list1, $list2); - $this->assertEquals(2, count($list1)); - $this->assertEquals(2, count($list2)); - } - - /** - * assure that a directory iteration works as expected - * - * @param \Closure $dotFilesSwitch - * @param string[] $expectedDirectories - * @test - * @dataProvider provideSwitchWithExpectations - */ - public function directoryIterationShouldBeIndependent(\Closure $dotFilesSwitch, array $expectedDirectories) - { - $dotFilesSwitch(); - $list1 = array(); - $list2 = array(); - $handle1 = opendir($this->fooURL); - if (false !== ($listItem = readdir($handle1))) { - $list1[] = $listItem; - } - - $handle2 = opendir($this->fooURL); - if (false !== ($listItem = readdir($handle2))) { - $list2[] = $listItem; - } - - if (false !== ($listItem = readdir($handle1))) { - $list1[] = $listItem; - } - - if (false !== ($listItem = readdir($handle2))) { - $list2[] = $listItem; - } - - closedir($handle1); - closedir($handle2); - $this->assertEquals($list1, $list2); - $this->assertEquals(2, count($list1)); - $this->assertEquals(2, count($list2)); - } - - /** - * @test - * @group issue_50 - */ - public function recursiveDirectoryIterationWithDotsEnabled() - { - vfsStream::enableDotfiles(); - vfsStream::setup(); - $structure = array( - 'Core' => array( - 'AbstractFactory' => array( - 'test.php' => 'some text content', - 'other.php' => 'Some more text content', - 'Invalid.csv' => 'Something else', - ), - 'AnEmptyFolder' => array(), - 'badlocation.php' => 'some bad content', - ) - ); - $root = vfsStream::create($structure); - $rootPath = vfsStream::url($root->getName()); - - $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($rootPath), - \RecursiveIteratorIterator::CHILD_FIRST); - $pathes = array(); - foreach ($iterator as $fullFileName => $fileSPLObject) { - $pathes[] = $fullFileName; - } - - $this->assertEquals(array('vfs://root'.DIRECTORY_SEPARATOR.'.', - 'vfs://root'.DIRECTORY_SEPARATOR.'..', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'.', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'..', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'.', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'..', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'test.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'other.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'Invalid.csv', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AnEmptyFolder'.DIRECTORY_SEPARATOR.'.', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AnEmptyFolder'.DIRECTORY_SEPARATOR.'..', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AnEmptyFolder', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'badlocation.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core' - ), - $pathes - ); - } - - /** - * @test - * @group issue_50 - */ - public function recursiveDirectoryIterationWithDotsDisabled() - { - vfsStream::disableDotfiles(); - vfsStream::setup(); - $structure = array( - 'Core' => array( - 'AbstractFactory' => array( - 'test.php' => 'some text content', - 'other.php' => 'Some more text content', - 'Invalid.csv' => 'Something else', - ), - 'AnEmptyFolder' => array(), - 'badlocation.php' => 'some bad content', - ) - ); - $root = vfsStream::create($structure); - $rootPath = vfsStream::url($root->getName()); - - $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($rootPath), - \RecursiveIteratorIterator::CHILD_FIRST); - $pathes = array(); - foreach ($iterator as $fullFileName => $fileSPLObject) { - $pathes[] = $fullFileName; - } - - $this->assertEquals(array('vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'test.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'other.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory'.DIRECTORY_SEPARATOR.'Invalid.csv', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AbstractFactory', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'AnEmptyFolder', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core'.DIRECTORY_SEPARATOR.'badlocation.php', - 'vfs://root'.DIRECTORY_SEPARATOR.'Core' - ), - $pathes - ); - } -} \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/Issue104TestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/Issue104TestCase.php deleted file mode 100644 index 89ae146b1..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/Issue104TestCase.php +++ /dev/null @@ -1,52 +0,0 @@ - array( - 'schema.xsd' => ' - - ', - ) - ); - vfsStream::setup('root', null, $structure); - $doc = new \DOMDocument(); - $this->assertTrue($doc->load(vfsStream::url('root/foo bar/schema.xsd'))); - } - - /** - * @test - */ - public function vfsStreamCanHandleUrlEncodedPath() - { - $content = ' - - '; - $structure = array('foo bar' => array( - 'schema.xsd' => $content, - ) - ); - vfsStream::setup('root', null, $structure); - $this->assertEquals( - $content, - file_get_contents(vfsStream::url('root/foo%20bar/schema.xsd')) - ); - } -} - diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/PermissionsTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/PermissionsTestCase.php deleted file mode 100644 index 56767ac7b..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/PermissionsTestCase.php +++ /dev/null @@ -1,118 +0,0 @@ - array('test.file' => '')); - $this->root = vfsStream::setup('root', null, $structure); - } - - /** - * @test - * @group issue_52 - */ - public function canNotChangePermissionWhenDirectoryNotWriteable() - { - $this->root->getChild('test_directory')->chmod(0444); - $this->assertFalse(@chmod(vfsStream::url('root/test_directory/test.file'), 0777)); - } - - /** - * @test - * @group issue_53 - */ - public function canNotChangePermissionWhenFileNotOwned() - { - $this->root->getChild('test_directory')->getChild('test.file')->chown(vfsStream::OWNER_USER_1); - $this->assertFalse(@chmod(vfsStream::url('root/test_directory/test.file'), 0777)); - } - - /** - * @test - * @group issue_52 - */ - public function canNotChangeOwnerWhenDirectoryNotWriteable() - { - $this->root->getChild('test_directory')->chmod(0444); - $this->assertFalse(@chown(vfsStream::url('root/test_directory/test.file'), vfsStream::OWNER_USER_2)); - } - - /** - * @test - * @group issue_53 - */ - public function canNotChangeOwnerWhenFileNotOwned() - { - $this->root->getChild('test_directory')->getChild('test.file')->chown(vfsStream::OWNER_USER_1); - $this->assertFalse(@chown(vfsStream::url('root/test_directory/test.file'), vfsStream::OWNER_USER_2)); - } - - /** - * @test - * @group issue_52 - */ - public function canNotChangeGroupWhenDirectoryNotWriteable() - { - $this->root->getChild('test_directory')->chmod(0444); - $this->assertFalse(@chgrp(vfsStream::url('root/test_directory/test.file'), vfsStream::GROUP_USER_2)); - } - - /** - * @test - * @group issue_53 - */ - public function canNotChangeGroupWhenFileNotOwned() - { - $this->root->getChild('test_directory')->getChild('test.file')->chown(vfsStream::OWNER_USER_1); - $this->assertFalse(@chgrp(vfsStream::url('root/test_directory/test.file'), vfsStream::GROUP_USER_2)); - } - - /** - * @test - * @group issue_107 - * @expectedException PHPUnit_Framework_Error - * @expectedExceptionMessage Can not create new file in non-writable path root - * @requires PHP 5.4 - * @since 1.5.0 - */ - public function touchOnNonWriteableDirectoryTriggersError() - { - $this->root->chmod(0555); - touch($this->root->url() . '/touch.txt'); - } - - /** - * @test - * @group issue_107 - * @requires PHP 5.4 - * @since 1.5.0 - */ - public function touchOnNonWriteableDirectoryDoesNotCreateFile() - { - $this->root->chmod(0555); - $this->assertFalse(@touch($this->root->url() . '/touch.txt')); - $this->assertFalse($this->root->hasChild('touch.txt')); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/QuotaTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/QuotaTestCase.php deleted file mode 100644 index 7007183e0..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/QuotaTestCase.php +++ /dev/null @@ -1,81 +0,0 @@ -quota = new Quota(10); - } - - /** - * @test - */ - public function unlimitedQuotaIsNotLimited() - { - $this->assertFalse(Quota::unlimited()->isLimited()); - } - - /** - * @test - */ - public function limitedQuotaIsLimited() - { - $this->assertTrue($this->quota->isLimited()); - } - - /** - * @test - */ - public function unlimitedQuotaHasAlwaysSpaceLeft() - { - $this->assertEquals(303, Quota::unlimited()->spaceLeft(303)); - } - - /** - * @test - */ - public function hasNoSpaceLeftWhenUsedSpaceIsLargerThanQuota() - { - $this->assertEquals(0, $this->quota->spaceLeft(11)); - } - - /** - * @test - */ - public function hasNoSpaceLeftWhenUsedSpaceIsEqualToQuota() - { - $this->assertEquals(0, $this->quota->spaceLeft(10)); - } - - /** - * @test - */ - public function hasSpaceLeftWhenUsedSpaceIsLowerThanQuota() - { - $this->assertEquals(1, $this->quota->spaceLeft(9)); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/UnlinkTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/UnlinkTestCase.php deleted file mode 100644 index 4f9fb17bc..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/UnlinkTestCase.php +++ /dev/null @@ -1,58 +0,0 @@ - array('test.file' => '')); - $root = vfsStream::setup('root', null, $structure); - $root->getChild('test_directory')->chmod(0777); - $root->getChild('test_directory')->getChild('test.file')->chmod(0444); - $this->assertTrue(@unlink(vfsStream::url('root/test_directory/test.file'))); - } - - /** - * @test - * @group issue_51 - */ - public function canNotRemoveWritableFileFromNonWritableDirectory() - { - $structure = array('test_directory' => array('test.file' => '')); - $root = vfsStream::setup('root', null, $structure); - $root->getChild('test_directory')->chmod(0444); - $root->getChild('test_directory')->getChild('test.file')->chmod(0777); - $this->assertFalse(@unlink(vfsStream::url('root/test_directory/test.file'))); - } - - /** - * @test - * @since 1.4.0 - * @group issue_68 - */ - public function unlinkNonExistingFileTriggersError() - { - vfsStream::setup(); - try { - $this->assertFalse(unlink('vfs://root/foo.txt')); - } catch (\PHPUnit_Framework_Error $fe) { - $this->assertEquals('unlink(vfs://root/foo.txt): No such file or directory', $fe->getMessage()); - } - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/LargeFileContentTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/LargeFileContentTestCase.php deleted file mode 100644 index c7a7458de..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/LargeFileContentTestCase.php +++ /dev/null @@ -1,225 +0,0 @@ -largeFileContent = new LargeFileContent(100); - } - - /** - * @test - */ - public function hasSizeOriginallyGiven() - { - $this->assertEquals(100, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function contentIsFilledUpWithSpacesIfNoDataWritten() - { - $this->assertEquals( - str_repeat(' ', 100), - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function readReturnsSpacesWhenNothingWrittenAtOffset() - { - $this->assertEquals( - str_repeat(' ', 10), - $this->largeFileContent->read(10) - ); - } - - /** - * @test - */ - public function readReturnsContentFilledWithSpaces() - { - $this->largeFileContent->write('foobarbaz'); - $this->largeFileContent->seek(0, SEEK_SET); - $this->assertEquals( - 'foobarbaz ', - $this->largeFileContent->read(10) - ); - } - - /** - * @test - */ - public function writesDataAtStartWhenOffsetNotMoved() - { - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals( - 'foobarbaz' . str_repeat(' ', 91), - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function writeDataAtStartDoesNotIncreaseSize() - { - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals(100, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function writesDataAtOffsetWhenOffsetMoved() - { - $this->largeFileContent->seek(50, SEEK_SET); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals( - str_repeat(' ', 50) . 'foobarbaz' . str_repeat(' ', 41), - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function writeDataInBetweenDoesNotIncreaseSize() - { - $this->largeFileContent->seek(50, SEEK_SET); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals(100, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function writesDataOverEndWhenOffsetAndDataLengthLargerThanSize() - { - $this->largeFileContent->seek(95, SEEK_SET); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals( - str_repeat(' ', 95) . 'foobarbaz', - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function writeDataOverLastOffsetIncreasesSize() - { - $this->largeFileContent->seek(95, SEEK_SET); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals(104, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function writesDataAfterEndWhenOffsetAfterEnd() - { - $this->largeFileContent->seek(0, SEEK_END); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals( - str_repeat(' ', 100) . 'foobarbaz', - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function writeDataAfterLastOffsetIncreasesSize() - { - $this->largeFileContent->seek(0, SEEK_END); - $this->assertEquals(9, $this->largeFileContent->write('foobarbaz')); - $this->assertEquals(109, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function truncateReducesSize() - { - $this->assertTrue($this->largeFileContent->truncate(50)); - $this->assertEquals(50, $this->largeFileContent->size()); - } - - /** - * @test - */ - public function truncateRemovesWrittenContentAfterOffset() - { - $this->largeFileContent->seek(45, SEEK_SET); - $this->largeFileContent->write('foobarbaz'); - $this->assertTrue($this->largeFileContent->truncate(50)); - $this->assertEquals( - str_repeat(' ', 45) . 'fooba', - $this->largeFileContent->content() - ); - } - - /** - * @test - */ - public function createInstanceWithKilobytes() - { - $this->assertEquals( - 100 * 1024, - LargeFileContent::withKilobytes(100) - ->size() - ); - } - - /** - * @test - */ - public function createInstanceWithMegabytes() - { - $this->assertEquals( - 100 * 1024 * 1024, - LargeFileContent::withMegabytes(100) - ->size() - ); - } - - /** - * @test - */ - public function createInstanceWithGigabytes() - { - $this->assertEquals( - 100 * 1024 * 1024 * 1024, - LargeFileContent::withGigabytes(100) - ->size() - ); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php deleted file mode 100644 index d0e15edb4..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php +++ /dev/null @@ -1,230 +0,0 @@ -stringBasedFileContent = new StringBasedFileContent('foobarbaz'); - } - - /** - * @test - */ - public function hasContentOriginallySet() - { - $this->assertEquals('foobarbaz', $this->stringBasedFileContent->content()); - } - - /** - * @test - */ - public function hasNotReachedEofAfterCreation() - { - $this->assertFalse($this->stringBasedFileContent->eof()); - } - - /** - * @test - */ - public function sizeEqualsLengthOfGivenString() - { - $this->assertEquals(9, $this->stringBasedFileContent->size()); - } - - /** - * @test - */ - public function readReturnsSubstringWithRequestedLength() - { - $this->assertEquals('foo', $this->stringBasedFileContent->read(3)); - } - - /** - * @test - */ - public function readMovesOffset() - { - $this->assertEquals('foo', $this->stringBasedFileContent->read(3)); - $this->assertEquals('bar', $this->stringBasedFileContent->read(3)); - $this->assertEquals('baz', $this->stringBasedFileContent->read(3)); - } - - /** - * @test - */ - public function reaMoreThanSizeReturnsWholeContent() - { - $this->assertEquals('foobarbaz', $this->stringBasedFileContent->read(10)); - } - - /** - * @test - */ - public function readAfterEndReturnsEmptyString() - { - $this->stringBasedFileContent->read(9); - $this->assertEquals('', $this->stringBasedFileContent->read(3)); - } - - /** - * @test - */ - public function readDoesNotChangeSize() - { - $this->stringBasedFileContent->read(3); - $this->assertEquals(9, $this->stringBasedFileContent->size()); - } - - /** - * @test - */ - public function readLessThenSizeDoesNotReachEof() - { - $this->stringBasedFileContent->read(3); - $this->assertFalse($this->stringBasedFileContent->eof()); - } - - /** - * @test - */ - public function readSizeReachesEof() - { - $this->stringBasedFileContent->read(9); - $this->assertTrue($this->stringBasedFileContent->eof()); - } - - /** - * @test - */ - public function readMoreThanSizeReachesEof() - { - $this->stringBasedFileContent->read(10); - $this->assertTrue($this->stringBasedFileContent->eof()); - } - - /** - * @test - */ - public function seekWithInvalidOptionReturnsFalse() - { - $this->assertFalse($this->stringBasedFileContent->seek(0, 55)); - } - - /** - * @test - */ - public function canSeekToGivenOffset() - { - $this->assertTrue($this->stringBasedFileContent->seek(5, SEEK_SET)); - $this->assertEquals('rbaz', $this->stringBasedFileContent->read(10)); - } - - /** - * @test - */ - public function canSeekFromCurrentOffset() - { - $this->assertTrue($this->stringBasedFileContent->seek(5, SEEK_SET)); - $this->assertTrue($this->stringBasedFileContent->seek(2, SEEK_CUR)); - $this->assertEquals('az', $this->stringBasedFileContent->read(10)); - } - - /** - * @test - */ - public function canSeekToEnd() - { - $this->assertTrue($this->stringBasedFileContent->seek(0, SEEK_END)); - $this->assertEquals('', $this->stringBasedFileContent->read(10)); - } - - /** - * @test - */ - public function writeOverwritesExistingContentWhenOffsetNotAtEof() - { - $this->assertEquals(3, $this->stringBasedFileContent->write('bar')); - $this->assertEquals('barbarbaz', $this->stringBasedFileContent->content()); - } - - /** - * @test - */ - public function writeAppendsContentWhenOffsetAtEof() - { - $this->assertTrue($this->stringBasedFileContent->seek(0, SEEK_END)); - $this->assertEquals(3, $this->stringBasedFileContent->write('bar')); - $this->assertEquals('foobarbazbar', $this->stringBasedFileContent->content()); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateRemovesSuperflouosContent() - { - $this->assertTrue($this->stringBasedFileContent->truncate(6)); - $this->assertEquals('foobar', $this->stringBasedFileContent->content()); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateDecreasesSize() - { - $this->assertTrue($this->stringBasedFileContent->truncate(6)); - $this->assertEquals(6, $this->stringBasedFileContent->size()); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateToGreaterSizeAddsZeroBytes() - { - $this->assertTrue($this->stringBasedFileContent->truncate(25)); - $this->assertEquals( - "foobarbaz\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", - $this->stringBasedFileContent->content() - ); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateToGreaterSizeIncreasesSize() - { - $this->assertTrue($this->stringBasedFileContent->truncate(25)); - $this->assertEquals(25, $this->stringBasedFileContent->size()); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/proxy/vfsStreamWrapperRecordingProxy.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/proxy/vfsStreamWrapperRecordingProxy.php deleted file mode 100644 index 899931d68..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/proxy/vfsStreamWrapperRecordingProxy.php +++ /dev/null @@ -1,326 +0,0 @@ - - */ - public static function getMethodCalls($path) - { - if (isset(self::$calledMethods[$path]) === true) { - return self::$calledMethods[$path]; - } - - return array(); - } - - /** - * helper method for setting up vfsStream with the proxy - * - * @param string $rootDirName optional name of root directory - * @param int $permissions optional file permissions of root directory - * @return vfsStreamDirectory - * @throws vfsStreamException - */ - public static function setup($rootDirName = 'root', $permissions = null) - { - self::$root = vfsStream::newDirectory($rootDirName, $permissions); - if (true === self::$registered) { - return self::$root; - } - - if (@stream_wrapper_register(vfsStream::SCHEME, __CLASS__) === false) { - throw new vfsStreamException('A handler has already been registered for the ' . vfsStream::SCHEME . ' protocol.'); - } - - self::$registered = true; - return self::$root; - } - - /** - * open the stream - * - * @param string $path the path to open - * @param string $mode mode for opening - * @param string $options options for opening - * @param string $opened_path full path that was actually opened - * @return bool - */ - public function stream_open($path, $mode, $options, $opened_path) - { - $this->path = $path; - self::recordMethodCall('stream_open', $this->path); - return parent::stream_open($path, $mode, $options, $opened_path); - } - - /** - * closes the stream - */ - public function stream_close() - { - self::recordMethodCall('stream_close', $this->path); - return parent::stream_close(); - } - - /** - * read the stream up to $count bytes - * - * @param int $count amount of bytes to read - * @return string - */ - public function stream_read($count) - { - self::recordMethodCall('stream_read', $this->path); - return parent::stream_read($count); - } - - /** - * writes data into the stream - * - * @param string $data - * @return int amount of bytes written - */ - public function stream_write($data) - { - self::recordMethodCall('stream_write', $this->path); - return parent::stream_write($data); - } - - /** - * checks whether stream is at end of file - * - * @return bool - */ - public function stream_eof() - { - self::recordMethodCall('stream_eof', $this->path); - return parent::stream_eof(); - } - - /** - * returns the current position of the stream - * - * @return int - */ - public function stream_tell() - { - self::recordMethodCall('stream_tell', $this->path); - return parent::stream_tell(); - } - - /** - * seeks to the given offset - * - * @param int $offset - * @param int $whence - * @return bool - */ - public function stream_seek($offset, $whence) - { - self::recordMethodCall('stream_seek', $this->path); - return parent::stream_seek($offset, $whence); - } - - /** - * flushes unstored data into storage - * - * @return bool - */ - public function stream_flush() - { - self::recordMethodCall('stream_flush', $this->path); - return parent::stream_flush(); - } - - /** - * returns status of stream - * - * @return array - */ - public function stream_stat() - { - self::recordMethodCall('stream_stat', $this->path); - return parent::stream_stat(); - } - - /** - * retrieve the underlaying resource - * - * @param int $cast_as - * @return bool - */ - public function stream_cast($cast_as) - { - self::recordMethodCall('stream_cast', $this->path); - return parent::stream_cast($cast_as); - } - - /** - * set lock status for stream - * - * @param int $operation - * @return bool - */ - public function stream_lock($operation) - { - self::recordMethodCall('stream_link', $this->path); - return parent::stream_lock($operation); - } - - /** - * remove the data under the given path - * - * @param string $path - * @return bool - */ - public function unlink($path) - { - self::recordMethodCall('unlink', $path); - return parent::unlink($path); - } - - /** - * rename from one path to another - * - * @param string $path_from - * @param string $path_to - * @return bool - */ - public function rename($path_from, $path_to) - { - self::recordMethodCall('rename', $path_from); - return parent::rename($path_from, $path_to); - } - - /** - * creates a new directory - * - * @param string $path - * @param int $mode - * @param int $options - * @return bool - */ - public function mkdir($path, $mode, $options) - { - self::recordMethodCall('mkdir', $path); - return parent::mkdir($path, $mode, $options); - } - - /** - * removes a directory - * - * @param string $path - * @param int $options - * @return bool - */ - public function rmdir($path, $options) - { - self::recordMethodCall('rmdir', $path); - return parent::rmdir($path, $options); - } - - /** - * opens a directory - * - * @param string $path - * @param int $options - * @return bool - */ - public function dir_opendir($path, $options) - { - $this->path = $path; - self::recordMethodCall('dir_opendir', $this->path); - return parent::dir_opendir($path, $options); - } - - /** - * reads directory contents - * - * @return string - */ - public function dir_readdir() - { - self::recordMethodCall('dir_readdir', $this->path); - return parent::dir_readdir(); - } - - /** - * reset directory iteration - * - * @return bool - */ - public function dir_rewinddir() - { - self::recordMethodCall('dir_rewinddir', $this->path); - return parent::dir_rewinddir(); - } - - /** - * closes directory - * - * @return bool - */ - public function dir_closedir() - { - self::recordMethodCall('dir_closedir', $this->path); - return parent::dir_closedir(); - } - - /** - * returns status of url - * - * @param string $path path of url to return status for - * @param int $flags flags set by the stream API - * @return array - */ - public function url_stat($path, $flags) - { - self::recordMethodCall('url_stat', $path); - return parent::url_stat($path, $flags); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamAbstractContentTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamAbstractContentTestCase.php deleted file mode 100644 index 9bb60795b..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamAbstractContentTestCase.php +++ /dev/null @@ -1,1054 +0,0 @@ -assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executePermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0100); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executePermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0010); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executePermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0001); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function writePermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0200); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function writePermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0020); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function writePermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0002); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executeAndWritePermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0300); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executeAndWritePermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0030); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function executeAndWritePermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0003); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readPermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0400); - $this->assertTrue($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readPermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0040); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readPermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0004); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndExecutePermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0500); - $this->assertTrue($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndExecutePermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0050); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndExecutePermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0005); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndWritePermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0600); - $this->assertTrue($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndWritePermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0060); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function readAndWritePermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0006); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function allPermissionsForUser() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0700); - $this->assertTrue($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertTrue($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function allPermissionsForGroup() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0070); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - -1 - ) - ); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function allPermissionsForOther() - { - $abstractContent = new TestvfsStreamAbstractContent('foo', 0007); - $this->assertFalse($abstractContent->isReadable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isReadable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isReadable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isWritable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isWritable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isWritable(-1, - -1 - ) - ); - $this->assertFalse($abstractContent->isExecutable(vfsStream::getCurrentUser(), - vfsStream::getCurrentGroup() - ) - ); - $this->assertFalse($abstractContent->isExecutable(-1, - vfsStream::getCurrentGroup() - ) - ); - $this->assertTrue($abstractContent->isExecutable(-1, - -1 - ) - ); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamBlockTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamBlockTestCase.php deleted file mode 100644 index 33222f7ae..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamBlockTestCase.php +++ /dev/null @@ -1,89 +0,0 @@ -block = new vfsStreamBlock('foo'); - } - - /** - * test default values and methods - * - * @test - */ - public function defaultValues() - { - $this->assertEquals(vfsStreamContent::TYPE_BLOCK, $this->block->getType()); - $this->assertEquals('foo', $this->block->getName()); - $this->assertTrue($this->block->appliesTo('foo')); - $this->assertFalse($this->block->appliesTo('foo/bar')); - $this->assertFalse($this->block->appliesTo('bar')); - } - - /** - * tests how external functions see this object - * - * @test - */ - public function external() - { - $root = vfsStream::setup('root'); - $root->addChild(vfsStream::newBlock('foo')); - $this->assertEquals('block', filetype(vfsStream::url('root/foo'))); - } - - /** - * tests adding a complex structure - * - * @test - */ - public function addStructure() - { - $structure = array( - 'topLevel' => array( - 'thisIsAFile' => 'file contents', - '[blockDevice]' => 'block contents' - ) - ); - - $root = vfsStream::create($structure); - - $this->assertSame('block', filetype(vfsStream::url('root/topLevel/blockDevice'))); - } - - /** - * tests that a blank name for a block device throws an exception - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - */ - public function createWithEmptyName() - { - $structure = array( - 'topLevel' => array( - 'thisIsAFile' => 'file contents', - '[]' => 'block contents' - ) - ); - - $root = vfsStream::create($structure); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamContainerIteratorTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamContainerIteratorTestCase.php deleted file mode 100644 index e1b4fe112..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamContainerIteratorTestCase.php +++ /dev/null @@ -1,112 +0,0 @@ -dir = new vfsStreamDirectory('foo'); - $this->mockChild1 = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $this->mockChild1->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - $this->dir->addChild($this->mockChild1); - $this->mockChild2 = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $this->mockChild2->expects($this->any()) - ->method('getName') - ->will($this->returnValue('baz')); - $this->dir->addChild($this->mockChild2); - } - - /** - * clean up test environment - */ - public function tearDown() - { - vfsStream::enableDotfiles(); - } - - /** - * @return array - */ - public function provideSwitchWithExpectations() - { - return array(array(function() { vfsStream::disableDotfiles(); }, - array() - ), - array(function() { vfsStream::enableDotfiles(); }, - array('.', '..') - ) - ); - } - - private function getDirName($dir) - { - if (is_string($dir)) { - return $dir; - } - - - return $dir->getName(); - } - - /** - * @param \Closure $dotFilesSwitch - * @param array $dirNames - * @test - * @dataProvider provideSwitchWithExpectations - */ - public function iteration(\Closure $dotFilesSwitch, array $dirs) - { - $dirs[] = $this->mockChild1; - $dirs[] = $this->mockChild2; - $dotFilesSwitch(); - $dirIterator = $this->dir->getIterator(); - foreach ($dirs as $dir) { - $this->assertEquals($this->getDirName($dir), $dirIterator->key()); - $this->assertTrue($dirIterator->valid()); - if (!is_string($dir)) { - $this->assertSame($dir, $dirIterator->current()); - } - - $dirIterator->next(); - } - - $this->assertFalse($dirIterator->valid()); - $this->assertNull($dirIterator->key()); - $this->assertNull($dirIterator->current()); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryIssue18TestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryIssue18TestCase.php deleted file mode 100644 index 89cde1ce8..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryIssue18TestCase.php +++ /dev/null @@ -1,81 +0,0 @@ -rootDirectory = vfsStream::newDirectory('/'); - $this->rootDirectory->addChild(vfsStream::newDirectory('var/log/app')); - $dir = $this->rootDirectory->getChild('var/log/app'); - $dir->addChild(vfsStream::newDirectory('app1')); - $dir->addChild(vfsStream::newDirectory('app2')); - $dir->addChild(vfsStream::newDirectory('foo')); - } - - /** - * @test - */ - public function shouldContainThreeSubdirectories() - { - $this->assertEquals(3, - count($this->rootDirectory->getChild('var/log/app')->getChildren()) - ); - } - - /** - * @test - */ - public function shouldContainSubdirectoryFoo() - { - $this->assertTrue($this->rootDirectory->getChild('var/log/app')->hasChild('foo')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $this->rootDirectory->getChild('var/log/app')->getChild('foo') - ); - } - - /** - * @test - */ - public function shouldContainSubdirectoryApp1() - { - $this->assertTrue($this->rootDirectory->getChild('var/log/app')->hasChild('app1')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $this->rootDirectory->getChild('var/log/app')->getChild('app1') - ); - } - - /** - * @test - */ - public function shouldContainSubdirectoryApp2() - { - $this->assertTrue($this->rootDirectory->getChild('var/log/app')->hasChild('app2')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $this->rootDirectory->getChild('var/log/app')->getChild('app2') - ); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryTestCase.php deleted file mode 100644 index f8b93842f..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamDirectoryTestCase.php +++ /dev/null @@ -1,335 +0,0 @@ -dir = new vfsStreamDirectory('foo'); - } - - /** - * assure that a directory seperator inside the name throws an exception - * - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - */ - public function invalidCharacterInName() - { - $dir = new vfsStreamDirectory('foo/bar'); - } - - /** - * test default values and methods - * - * @test - */ - public function defaultValues() - { - $this->assertEquals(vfsStreamContent::TYPE_DIR, $this->dir->getType()); - $this->assertEquals('foo', $this->dir->getName()); - $this->assertTrue($this->dir->appliesTo('foo')); - $this->assertTrue($this->dir->appliesTo('foo/bar')); - $this->assertFalse($this->dir->appliesTo('bar')); - $this->assertEquals(array(), $this->dir->getChildren()); - } - - /** - * test renaming the directory - * - * @test - */ - public function rename() - { - $this->dir->rename('bar'); - $this->assertEquals('bar', $this->dir->getName()); - $this->assertFalse($this->dir->appliesTo('foo')); - $this->assertFalse($this->dir->appliesTo('foo/bar')); - $this->assertTrue($this->dir->appliesTo('bar')); - } - - /** - * renaming the directory to an invalid name throws a vfsStreamException - * - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - */ - public function renameToInvalidNameThrowsvfsStreamException() - { - $this->dir->rename('foo/baz'); - } - - /** - * @test - * @since 0.10.0 - */ - public function hasNoChildrenByDefault() - { - $this->assertFalse($this->dir->hasChildren()); - } - - /** - * @test - * @since 0.10.0 - */ - public function hasChildrenReturnsTrueIfAtLeastOneChildPresent() - { - $mockChild = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild->expects($this->any()) - ->method('appliesTo') - ->will($this->returnValue(false)); - $mockChild->expects($this->any()) - ->method('getName') - ->will($this->returnValue('baz')); - $this->dir->addChild($mockChild); - $this->assertTrue($this->dir->hasChildren()); - } - - /** - * @test - */ - public function hasChildReturnsFalseForNonExistingChild() - { - $this->assertFalse($this->dir->hasChild('bar')); - } - - /** - * @test - */ - public function getChildReturnsNullForNonExistingChild() - { - $this->assertNull($this->dir->getChild('bar')); - } - - /** - * @test - */ - public function removeChildReturnsFalseForNonExistingChild() - { - $this->assertFalse($this->dir->removeChild('bar')); - } - - /** - * @test - */ - public function nonExistingChild() - { - $mockChild = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild->expects($this->any()) - ->method('appliesTo') - ->will($this->returnValue(false)); - $mockChild->expects($this->any()) - ->method('getName') - ->will($this->returnValue('baz')); - $this->dir->addChild($mockChild); - $this->assertFalse($this->dir->removeChild('bar')); - } - - /** - * test that adding, handling and removing of a child works as expected - * - * @test - */ - public function childHandling() - { - $mockChild = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild->expects($this->any()) - ->method('getType') - ->will($this->returnValue(vfsStreamContent::TYPE_FILE)); - $mockChild->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - $mockChild->expects($this->any()) - ->method('appliesTo') - ->with($this->equalTo('bar')) - ->will($this->returnValue(true)); - $mockChild->expects($this->once()) - ->method('size') - ->will($this->returnValue(5)); - $this->dir->addChild($mockChild); - $this->assertTrue($this->dir->hasChild('bar')); - $bar = $this->dir->getChild('bar'); - $this->assertSame($mockChild, $bar); - $this->assertEquals(array($mockChild), $this->dir->getChildren()); - $this->assertEquals(0, $this->dir->size()); - $this->assertEquals(5, $this->dir->sizeSummarized()); - $this->assertTrue($this->dir->removeChild('bar')); - $this->assertEquals(array(), $this->dir->getChildren()); - $this->assertEquals(0, $this->dir->size()); - $this->assertEquals(0, $this->dir->sizeSummarized()); - } - - /** - * test that adding, handling and removing of a child works as expected - * - * @test - */ - public function childHandlingWithSubdirectory() - { - $mockChild = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild->expects($this->any()) - ->method('getType') - ->will($this->returnValue(vfsStreamContent::TYPE_FILE)); - $mockChild->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - $mockChild->expects($this->once()) - ->method('size') - ->will($this->returnValue(5)); - $subdir = new vfsStreamDirectory('subdir'); - $subdir->addChild($mockChild); - $this->dir->addChild($subdir); - $this->assertTrue($this->dir->hasChild('subdir')); - $this->assertSame($subdir, $this->dir->getChild('subdir')); - $this->assertEquals(array($subdir), $this->dir->getChildren()); - $this->assertEquals(0, $this->dir->size()); - $this->assertEquals(5, $this->dir->sizeSummarized()); - $this->assertTrue($this->dir->removeChild('subdir')); - $this->assertEquals(array(), $this->dir->getChildren()); - $this->assertEquals(0, $this->dir->size()); - $this->assertEquals(0, $this->dir->sizeSummarized()); - } - - /** - * dd - * - * @test - * @group regression - * @group bug_5 - */ - public function addChildReplacesChildWithSameName_Bug_5() - { - $mockChild1 = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild1->expects($this->any()) - ->method('getType') - ->will($this->returnValue(vfsStreamContent::TYPE_FILE)); - $mockChild1->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - $mockChild2 = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild2->expects($this->any()) - ->method('getType') - ->will($this->returnValue(vfsStreamContent::TYPE_FILE)); - $mockChild2->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - $this->dir->addChild($mockChild1); - $this->assertTrue($this->dir->hasChild('bar')); - $this->assertSame($mockChild1, $this->dir->getChild('bar')); - $this->dir->addChild($mockChild2); - $this->assertTrue($this->dir->hasChild('bar')); - $this->assertSame($mockChild2, $this->dir->getChild('bar')); - } - - /** - * When testing for a nested path, verify that directory separators are respected properly - * so that subdir1/subdir2 is not considered equal to subdir1Xsubdir2. - * - * @test - * @group bug_24 - * @group regression - */ - public function explicitTestForSeparatorWithNestedPaths_Bug_24() - { - $mockChild = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockChild->expects($this->any()) - ->method('getType') - ->will($this->returnValue(vfsStreamContent::TYPE_FILE)); - $mockChild->expects($this->any()) - ->method('getName') - ->will($this->returnValue('bar')); - - $subdir1 = new vfsStreamDirectory('subdir1'); - $this->dir->addChild($subdir1); - - $subdir2 = new vfsStreamDirectory('subdir2'); - $subdir1->addChild($subdir2); - - $subdir2->addChild($mockChild); - - $this->assertTrue($this->dir->hasChild('subdir1'), "Level 1 path with separator exists"); - $this->assertTrue($this->dir->hasChild('subdir1/subdir2'), "Level 2 path with separator exists"); - $this->assertTrue($this->dir->hasChild('subdir1/subdir2/bar'), "Level 3 path with separator exists"); - $this->assertFalse($this->dir->hasChild('subdir1.subdir2'), "Path with period does not exist"); - $this->assertFalse($this->dir->hasChild('subdir1.subdir2/bar'), "Nested path with period does not exist"); - } - - - /** - * setting and retrieving permissions for a directory - * - * @test - * @group permissions - */ - public function permissions() - { - $this->assertEquals(0777, $this->dir->getPermissions()); - $this->assertSame($this->dir, $this->dir->chmod(0755)); - $this->assertEquals(0755, $this->dir->getPermissions()); - } - - /** - * setting and retrieving permissions for a directory - * - * @test - * @group permissions - */ - public function permissionsSet() - { - $this->dir = new vfsStreamDirectory('foo', 0755); - $this->assertEquals(0755, $this->dir->getPermissions()); - $this->assertSame($this->dir, $this->dir->chmod(0700)); - $this->assertEquals(0700, $this->dir->getPermissions()); - } - - /** - * setting and retrieving owner of a file - * - * @test - * @group permissions - */ - public function owner() - { - $this->assertEquals(vfsStream::getCurrentUser(), $this->dir->getUser()); - $this->assertTrue($this->dir->isOwnedByUser(vfsStream::getCurrentUser())); - $this->assertSame($this->dir, $this->dir->chown(vfsStream::OWNER_USER_1)); - $this->assertEquals(vfsStream::OWNER_USER_1, $this->dir->getUser()); - $this->assertTrue($this->dir->isOwnedByUser(vfsStream::OWNER_USER_1)); - } - - /** - * setting and retrieving owner group of a file - * - * @test - * @group permissions - */ - public function group() - { - $this->assertEquals(vfsStream::getCurrentGroup(), $this->dir->getGroup()); - $this->assertTrue($this->dir->isOwnedByGroup(vfsStream::getCurrentGroup())); - $this->assertSame($this->dir, $this->dir->chgrp(vfsStream::GROUP_USER_1)); - $this->assertEquals(vfsStream::GROUP_USER_1, $this->dir->getGroup()); - $this->assertTrue($this->dir->isOwnedByGroup(vfsStream::GROUP_USER_1)); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamExLockTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamExLockTestCase.php deleted file mode 100644 index 976356008..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamExLockTestCase.php +++ /dev/null @@ -1,56 +0,0 @@ -at($root); - - } - - /** - * This test verifies the current behaviour where vfsStream URLs do not work - * with file_put_contents() and LOCK_EX. The test is intended to break once - * PHP changes this so we get notified about the change. - * - * @test - */ - public function filePutContentsLockShouldReportError() - { - @file_put_contents(vfsStream::url('root/testfile'), "some string\n", LOCK_EX); - $php_error = error_get_last(); - $this->assertEquals("file_put_contents(): Exclusive locks may only be set for regular files", $php_error['message']); - } - - /** - * @test - */ - public function flockSouldPass() - { - $fp = fopen(vfsStream::url('root/testfile'), 'w'); - flock($fp, LOCK_EX); - fwrite($fp, "another string\n"); - flock($fp, LOCK_UN); - fclose($fp); - $this->assertEquals("another string\n", file_get_contents(vfsStream::url('root/testfile'))); - } -} - diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamFileTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamFileTestCase.php deleted file mode 100644 index 5fe15d030..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamFileTestCase.php +++ /dev/null @@ -1,306 +0,0 @@ -file = new vfsStreamFile('foo'); - } - - /** - * test default values and methods - * - * @test - */ - public function defaultValues() - { - $this->assertEquals(vfsStreamContent::TYPE_FILE, $this->file->getType()); - $this->assertEquals('foo', $this->file->getName()); - $this->assertTrue($this->file->appliesTo('foo')); - $this->assertFalse($this->file->appliesTo('foo/bar')); - $this->assertFalse($this->file->appliesTo('bar')); - } - - /** - * test setting and getting the content of a file - * - * @test - */ - public function content() - { - $this->assertNull($this->file->getContent()); - $this->assertSame($this->file, $this->file->setContent('bar')); - $this->assertEquals('bar', $this->file->getContent()); - $this->assertSame($this->file, $this->file->withContent('baz')); - $this->assertEquals('baz', $this->file->getContent()); - } - - /** - * test renaming the directory - * - * @test - */ - public function rename() - { - $this->file->rename('bar'); - $this->assertEquals('bar', $this->file->getName()); - $this->assertFalse($this->file->appliesTo('foo')); - $this->assertFalse($this->file->appliesTo('foo/bar')); - $this->assertTrue($this->file->appliesTo('bar')); - } - - /** - * test reading contents from the file - * - * @test - */ - public function readEmptyFile() - { - $this->assertTrue($this->file->eof()); - $this->assertEquals(0, $this->file->size()); - $this->assertEquals('', $this->file->read(5)); - $this->assertEquals(5, $this->file->getBytesRead()); - $this->assertTrue($this->file->eof()); - } - - /** - * test reading contents from the file - * - * @test - */ - public function read() - { - $this->file->setContent('foobarbaz'); - $this->assertFalse($this->file->eof()); - $this->assertEquals(9, $this->file->size()); - $this->assertEquals('foo', $this->file->read(3)); - $this->assertEquals(3, $this->file->getBytesRead()); - $this->assertFalse($this->file->eof()); - $this->assertEquals(9, $this->file->size()); - $this->assertEquals('bar', $this->file->read(3)); - $this->assertEquals(6, $this->file->getBytesRead()); - $this->assertFalse($this->file->eof()); - $this->assertEquals(9, $this->file->size()); - $this->assertEquals('baz', $this->file->read(3)); - $this->assertEquals(9, $this->file->getBytesRead()); - $this->assertEquals(9, $this->file->size()); - $this->assertTrue($this->file->eof()); - $this->assertEquals('', $this->file->read(3)); - } - - /** - * test seeking to offset - * - * @test - */ - public function seekEmptyFile() - { - $this->assertFalse($this->file->seek(0, 55)); - $this->assertTrue($this->file->seek(0, SEEK_SET)); - $this->assertEquals(0, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(5, SEEK_SET)); - $this->assertEquals(5, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(0, SEEK_CUR)); - $this->assertEquals(5, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(2, SEEK_CUR)); - $this->assertEquals(7, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(0, SEEK_END)); - $this->assertEquals(0, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(2, SEEK_END)); - $this->assertEquals(2, $this->file->getBytesRead()); - } - - /** - * test seeking to offset - * - * @test - */ - public function seekRead() - { - $this->file->setContent('foobarbaz'); - $this->assertFalse($this->file->seek(0, 55)); - $this->assertTrue($this->file->seek(0, SEEK_SET)); - $this->assertEquals('foobarbaz', $this->file->readUntilEnd()); - $this->assertEquals(0, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(5, SEEK_SET)); - $this->assertEquals('rbaz', $this->file->readUntilEnd()); - $this->assertEquals(5, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(0, SEEK_CUR)); - $this->assertEquals('rbaz', $this->file->readUntilEnd()); - $this->assertEquals(5, $this->file->getBytesRead(), 5); - $this->assertTrue($this->file->seek(2, SEEK_CUR)); - $this->assertEquals('az', $this->file->readUntilEnd()); - $this->assertEquals(7, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(0, SEEK_END)); - $this->assertEquals('', $this->file->readUntilEnd()); - $this->assertEquals(9, $this->file->getBytesRead()); - $this->assertTrue($this->file->seek(2, SEEK_END)); - $this->assertEquals('', $this->file->readUntilEnd()); - $this->assertEquals(11, $this->file->getBytesRead()); - } - - /** - * test writing data into the file - * - * @test - */ - public function writeEmptyFile() - { - $this->assertEquals(3, $this->file->write('foo')); - $this->assertEquals('foo', $this->file->getContent()); - $this->assertEquals(3, $this->file->size()); - $this->assertEquals(3, $this->file->write('bar')); - $this->assertEquals('foobar', $this->file->getContent()); - $this->assertEquals(6, $this->file->size()); - } - - /** - * test writing data into the file - * - * @test - */ - public function write() - { - $this->file->setContent('foobarbaz'); - $this->assertTrue($this->file->seek(3, SEEK_SET)); - $this->assertEquals(3, $this->file->write('foo')); - $this->assertEquals('foofoobaz', $this->file->getContent()); - $this->assertEquals(9, $this->file->size()); - $this->assertEquals(3, $this->file->write('bar')); - $this->assertEquals('foofoobar', $this->file->getContent()); - $this->assertEquals(9, $this->file->size()); - } - - /** - * setting and retrieving permissions for a file - * - * @test - * @group permissions - */ - public function permissions() - { - $this->assertEquals(0666, $this->file->getPermissions()); - $this->assertSame($this->file, $this->file->chmod(0644)); - $this->assertEquals(0644, $this->file->getPermissions()); - } - - /** - * setting and retrieving permissions for a file - * - * @test - * @group permissions - */ - public function permissionsSet() - { - $this->file = new vfsStreamFile('foo', 0644); - $this->assertEquals(0644, $this->file->getPermissions()); - $this->assertSame($this->file, $this->file->chmod(0600)); - $this->assertEquals(0600, $this->file->getPermissions()); - } - - /** - * setting and retrieving owner of a file - * - * @test - * @group permissions - */ - public function owner() - { - $this->assertEquals(vfsStream::getCurrentUser(), $this->file->getUser()); - $this->assertTrue($this->file->isOwnedByUser(vfsStream::getCurrentUser())); - $this->assertSame($this->file, $this->file->chown(vfsStream::OWNER_USER_1)); - $this->assertEquals(vfsStream::OWNER_USER_1, $this->file->getUser()); - $this->assertTrue($this->file->isOwnedByUser(vfsStream::OWNER_USER_1)); - } - - /** - * setting and retrieving owner group of a file - * - * @test - * @group permissions - */ - public function group() - { - $this->assertEquals(vfsStream::getCurrentGroup(), $this->file->getGroup()); - $this->assertTrue($this->file->isOwnedByGroup(vfsStream::getCurrentGroup())); - $this->assertSame($this->file, $this->file->chgrp(vfsStream::GROUP_USER_1)); - $this->assertEquals(vfsStream::GROUP_USER_1, $this->file->getGroup()); - $this->assertTrue($this->file->isOwnedByGroup(vfsStream::GROUP_USER_1)); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateRemovesSuperflouosContent() - { - $this->assertEquals(11, $this->file->write("lorem ipsum")); - $this->assertTrue($this->file->truncate(5)); - $this->assertEquals(5, $this->file->size()); - $this->assertEquals('lorem', $this->file->getContent()); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - */ - public function truncateToGreaterSizeAddsZeroBytes() - { - $this->assertEquals(11, $this->file->write("lorem ipsum")); - $this->assertTrue($this->file->truncate(25)); - $this->assertEquals(25, $this->file->size()); - $this->assertEquals("lorem ipsum\0\0\0\0\0\0\0\0\0\0\0\0\0\0", $this->file->getContent()); - } - - /** - * @test - * @group issue_79 - * @since 1.3.0 - */ - public function withContentAcceptsAnyFileContentInstance() - { - $mockFileContent = $this->getMock('org\bovigo\vfs\content\FileContent'); - $mockFileContent->expects($this->once()) - ->method('content') - ->will($this->returnValue('foobarbaz')); - $this->assertEquals( - 'foobarbaz', - $this->file->withContent($mockFileContent) - ->getContent() - ); - } - - /** - * @test - * @group issue_79 - * @expectedException \InvalidArgumentException - * @since 1.3.0 - */ - public function withContentThrowsInvalidArgumentExceptionWhenContentIsNoStringAndNoFileContent() - { - $this->file->withContent(313); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamGlobTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamGlobTestCase.php deleted file mode 100644 index 24884edf6..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamGlobTestCase.php +++ /dev/null @@ -1,29 +0,0 @@ -assertEmpty(glob(vfsStream::url('example'), GLOB_MARK)); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamResolveIncludePathTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamResolveIncludePathTestCase.php deleted file mode 100644 index 106dae649..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamResolveIncludePathTestCase.php +++ /dev/null @@ -1,62 +0,0 @@ -backupIncludePath = get_include_path(); - vfsStream::setup(); - mkdir('vfs://root/a/path', 0777, true); - set_include_path('vfs://root/a' . PATH_SEPARATOR . $this->backupIncludePath); - } - - /** - * clean up test environment - */ - public function tearDown() - { - set_include_path($this->backupIncludePath); - } - - /** - * @test - */ - public function knownFileCanBeResolved() - { - file_put_contents('vfs://root/a/path/knownFile.php', ''); - $this->assertEquals('vfs://root/a/path/knownFile.php', stream_resolve_include_path('path/knownFile.php')); - } - - /** - * @test - */ - public function unknownFileCanNotBeResolvedYieldsFalse() - { - $this->assertFalse(@stream_resolve_include_path('path/unknownFile.php')); - } -} -?> diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php deleted file mode 100644 index 530d664ca..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php +++ /dev/null @@ -1,728 +0,0 @@ -assertEquals('vfs://foo', vfsStream::url('foo')); - $this->assertEquals('vfs://foo/bar.baz', vfsStream::url('foo/bar.baz')); - $this->assertEquals('vfs://foo/bar.baz', vfsStream::url('foo\bar.baz')); - } - - /** - * assure that url2path conversion works correct - * - * @test - */ - public function path() - { - $this->assertEquals('foo', vfsStream::path('vfs://foo')); - $this->assertEquals('foo/bar.baz', vfsStream::path('vfs://foo/bar.baz')); - $this->assertEquals('foo/bar.baz', vfsStream::path('vfs://foo\bar.baz')); - } - - /** - * windows directory separators are converted into default separator - * - * @author Gabriel Birke - * @test - */ - public function pathConvertsWindowsDirectorySeparators() - { - $this->assertEquals('foo/bar', vfsStream::path('vfs://foo\\bar')); - } - - /** - * trailing whitespace should be removed - * - * @author Gabriel Birke - * @test - */ - public function pathRemovesTrailingWhitespace() - { - $this->assertEquals('foo/bar', vfsStream::path('vfs://foo/bar ')); - } - - /** - * trailing slashes are removed - * - * @author Gabriel Birke - * @test - */ - public function pathRemovesTrailingSlash() - { - $this->assertEquals('foo/bar', vfsStream::path('vfs://foo/bar/')); - } - - /** - * trailing slash and whitespace should be removed - * - * @author Gabriel Birke - * @test - */ - public function pathRemovesTrailingSlashAndWhitespace() - { - $this->assertEquals('foo/bar', vfsStream::path('vfs://foo/bar/ ')); - } - - /** - * double slashes should be replaced by single slash - * - * @author Gabriel Birke - * @test - */ - public function pathRemovesDoubleSlashes() - { - // Regular path - $this->assertEquals('my/path', vfsStream::path('vfs://my/path')); - // Path with double slashes - $this->assertEquals('my/path', vfsStream::path('vfs://my//path')); - } - - /** - * test to create a new file - * - * @test - */ - public function newFile() - { - $file = vfsStream::newFile('filename.txt'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamFile', $file); - $this->assertEquals('filename.txt', $file->getName()); - $this->assertEquals(0666, $file->getPermissions()); - } - - /** - * test to create a new file with non-default permissions - * - * @test - * @group permissions - */ - public function newFileWithDifferentPermissions() - { - $file = vfsStream::newFile('filename.txt', 0644); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamFile', $file); - $this->assertEquals('filename.txt', $file->getName()); - $this->assertEquals(0644, $file->getPermissions()); - } - - /** - * test to create a new directory structure - * - * @test - */ - public function newSingleDirectory() - { - $foo = vfsStream::newDirectory('foo'); - $this->assertEquals('foo', $foo->getName()); - $this->assertEquals(0, count($foo->getChildren())); - $this->assertEquals(0777, $foo->getPermissions()); - } - - /** - * test to create a new directory structure with non-default permissions - * - * @test - * @group permissions - */ - public function newSingleDirectoryWithDifferentPermissions() - { - $foo = vfsStream::newDirectory('foo', 0755); - $this->assertEquals('foo', $foo->getName()); - $this->assertEquals(0, count($foo->getChildren())); - $this->assertEquals(0755, $foo->getPermissions()); - } - - /** - * test to create a new directory structure - * - * @test - */ - public function newDirectoryStructure() - { - $foo = vfsStream::newDirectory('foo/bar/baz'); - $this->assertEquals('foo', $foo->getName()); - $this->assertEquals(0777, $foo->getPermissions()); - $this->assertTrue($foo->hasChild('bar')); - $this->assertTrue($foo->hasChild('bar/baz')); - $this->assertFalse($foo->hasChild('baz')); - $bar = $foo->getChild('bar'); - $this->assertEquals('bar', $bar->getName()); - $this->assertEquals(0777, $bar->getPermissions()); - $this->assertTrue($bar->hasChild('baz')); - $baz1 = $bar->getChild('baz'); - $this->assertEquals('baz', $baz1->getName()); - $this->assertEquals(0777, $baz1->getPermissions()); - $baz2 = $foo->getChild('bar/baz'); - $this->assertSame($baz1, $baz2); - } - - /** - * test that correct directory structure is created - * - * @test - */ - public function newDirectoryWithSlashAtStart() - { - $foo = vfsStream::newDirectory('/foo/bar/baz', 0755); - $this->assertEquals('foo', $foo->getName()); - $this->assertEquals(0755, $foo->getPermissions()); - $this->assertTrue($foo->hasChild('bar')); - $this->assertTrue($foo->hasChild('bar/baz')); - $this->assertFalse($foo->hasChild('baz')); - $bar = $foo->getChild('bar'); - $this->assertEquals('bar', $bar->getName()); - $this->assertEquals(0755, $bar->getPermissions()); - $this->assertTrue($bar->hasChild('baz')); - $baz1 = $bar->getChild('baz'); - $this->assertEquals('baz', $baz1->getName()); - $this->assertEquals(0755, $baz1->getPermissions()); - $baz2 = $foo->getChild('bar/baz'); - $this->assertSame($baz1, $baz2); - } - - /** - * @test - * @group setup - * @since 0.7.0 - */ - public function setupRegistersStreamWrapperAndCreatesRootDirectoryWithDefaultNameAndPermissions() - { - $root = vfsStream::setup(); - $this->assertSame($root, vfsStreamWrapper::getRoot()); - $this->assertEquals('root', $root->getName()); - $this->assertEquals(0777, $root->getPermissions()); - } - - /** - * @test - * @group setup - * @since 0.7.0 - */ - public function setupRegistersStreamWrapperAndCreatesRootDirectoryWithGivenNameAndDefaultPermissions() - { - $root = vfsStream::setup('foo'); - $this->assertSame($root, vfsStreamWrapper::getRoot()); - $this->assertEquals('foo', $root->getName()); - $this->assertEquals(0777, $root->getPermissions()); - } - - /** - * @test - * @group setup - * @since 0.7.0 - */ - public function setupRegistersStreamWrapperAndCreatesRootDirectoryWithGivenNameAndPermissions() - { - $root = vfsStream::setup('foo', 0444); - $this->assertSame($root, vfsStreamWrapper::getRoot()); - $this->assertEquals('foo', $root->getName()); - $this->assertEquals(0444, $root->getPermissions()); - } - - /** - * @test - * @group issue_14 - * @group issue_20 - * @since 0.10.0 - */ - public function setupWithEmptyArrayIsEqualToSetup() - { - $root = vfsStream::setup('example', - 0755, - array() - ); - $this->assertEquals('example', $root->getName()); - $this->assertEquals(0755, $root->getPermissions()); - $this->assertFalse($root->hasChildren()); - } - - /** - * @test - * @group issue_14 - * @group issue_20 - * @since 0.10.0 - */ - public function setupArraysAreTurnedIntoSubdirectories() - { - $root = vfsStream::setup('root', - null, - array('test' => array()) - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $root->getChild('test') - ); - $this->assertFalse($root->getChild('test')->hasChildren()); - } - - /** - * @test - * @group issue_14 - * @group issue_20 - * @since 0.10.0 - */ - public function setupStringsAreTurnedIntoFilesWithContent() - { - $root = vfsStream::setup('root', - null, - array('test.txt' => 'some content') - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test.txt')); - $this->assertVfsFile($root->getChild('test.txt'), 'some content'); - } - - /** - * @test - * @group issue_14 - * @group issue_20 - * @since 0.10.0 - */ - public function setupWorksRecursively() - { - $root = vfsStream::setup('root', - null, - array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ) - ) - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test')); - $test = $root->getChild('test'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $test); - $this->assertTrue($test->hasChildren()); - $this->assertTrue($test->hasChild('baz.txt')); - $this->assertVfsFile($test->getChild('baz.txt'), 'world'); - - $this->assertTrue($test->hasChild('foo')); - $foo = $test->getChild('foo'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $foo); - $this->assertTrue($foo->hasChildren()); - $this->assertTrue($foo->hasChild('test.txt')); - $this->assertVfsFile($foo->getChild('test.txt'), 'hello'); - } - - /** - * @test - * @group issue_17 - * @group issue_20 - */ - public function setupCastsNumericDirectoriesToStrings() - { - $root = vfsStream::setup('root', - null, - array(2011 => array ('test.txt' => 'some content')) - ); - $this->assertTrue($root->hasChild('2011')); - - $directory = $root->getChild('2011'); - $this->assertVfsFile($directory->getChild('test.txt'), 'some content'); - - $this->assertTrue(file_exists('vfs://root/2011/test.txt')); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createArraysAreTurnedIntoSubdirectories() - { - $baseDir = vfsStream::create(array('test' => array()), new vfsStreamDirectory('baseDir')); - $this->assertTrue($baseDir->hasChildren()); - $this->assertTrue($baseDir->hasChild('test')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $baseDir->getChild('test') - ); - $this->assertFalse($baseDir->getChild('test')->hasChildren()); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createArraysAreTurnedIntoSubdirectoriesOfRoot() - { - $root = vfsStream::setup(); - $this->assertSame($root, vfsStream::create(array('test' => array()))); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test')); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', - $root->getChild('test') - ); - $this->assertFalse($root->getChild('test')->hasChildren()); - } - - /** - * @test - * @group issue_20 - * @expectedException \InvalidArgumentException - * @since 0.11.0 - */ - public function createThrowsExceptionIfNoBaseDirGivenAndNoRootSet() - { - vfsStream::create(array('test' => array())); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createWorksRecursively() - { - $baseDir = vfsStream::create(array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ) - ), - new vfsStreamDirectory('baseDir') - ); - $this->assertTrue($baseDir->hasChildren()); - $this->assertTrue($baseDir->hasChild('test')); - $test = $baseDir->getChild('test'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $test); - $this->assertTrue($test->hasChildren()); - $this->assertTrue($test->hasChild('baz.txt')); - $this->assertVfsFile($test->getChild('baz.txt'), 'world'); - - $this->assertTrue($test->hasChild('foo')); - $foo = $test->getChild('foo'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $foo); - $this->assertTrue($foo->hasChildren()); - $this->assertTrue($foo->hasChild('test.txt')); - $this->assertVfsFile($foo->getChild('test.txt'), 'hello'); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createWorksRecursivelyWithRoot() - { - $root = vfsStream::setup(); - $this->assertSame($root, - vfsStream::create(array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ) - ) - ) - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test')); - $test = $root->getChild('test'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $test); - $this->assertTrue($test->hasChildren()); - $this->assertTrue($test->hasChild('baz.txt')); - $this->assertVfsFile($test->getChild('baz.txt'), 'world'); - - $this->assertTrue($test->hasChild('foo')); - $foo = $test->getChild('foo'); - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamDirectory', $foo); - $this->assertTrue($foo->hasChildren()); - $this->assertTrue($foo->hasChild('test.txt')); - $this->assertVfsFile($foo->getChild('test.txt'), 'hello'); - } - - /** - * @test - * @group issue_20 - * @since 0.10.0 - */ - public function createStringsAreTurnedIntoFilesWithContent() - { - $baseDir = vfsStream::create(array('test.txt' => 'some content'), new vfsStreamDirectory('baseDir')); - $this->assertTrue($baseDir->hasChildren()); - $this->assertTrue($baseDir->hasChild('test.txt')); - $this->assertVfsFile($baseDir->getChild('test.txt'), 'some content'); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createStringsAreTurnedIntoFilesWithContentWithRoot() - { - $root = vfsStream::setup(); - $this->assertSame($root, - vfsStream::create(array('test.txt' => 'some content')) - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('test.txt')); - $this->assertVfsFile($root->getChild('test.txt'), 'some content'); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createCastsNumericDirectoriesToStrings() - { - $baseDir = vfsStream::create(array(2011 => array ('test.txt' => 'some content')), new vfsStreamDirectory('baseDir')); - $this->assertTrue($baseDir->hasChild('2011')); - - $directory = $baseDir->getChild('2011'); - $this->assertVfsFile($directory->getChild('test.txt'), 'some content'); - } - - /** - * @test - * @group issue_20 - * @since 0.11.0 - */ - public function createCastsNumericDirectoriesToStringsWithRoot() - { - $root = vfsStream::setup(); - $this->assertSame($root, - vfsStream::create(array(2011 => array ('test.txt' => 'some content'))) - ); - $this->assertTrue($root->hasChild('2011')); - - $directory = $root->getChild('2011'); - $this->assertVfsFile($directory->getChild('test.txt'), 'some content'); - } - - /** - * helper function for assertions on vfsStreamFile - * - * @param vfsStreamFile $file - * @param string $content - */ - protected function assertVfsFile(vfsStreamFile $file, $content) - { - $this->assertInstanceOf('org\\bovigo\\vfs\\vfsStreamFile', - $file - ); - $this->assertEquals($content, - $file->getContent() - ); - } - - /** - * @test - * @group issue_10 - * @since 0.10.0 - */ - public function inspectWithContentGivesContentToVisitor() - { - $mockContent = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockVisitor = $this->getMock('org\\bovigo\\vfs\\visitor\\vfsStreamVisitor'); - $mockVisitor->expects($this->once()) - ->method('visit') - ->with($this->equalTo($mockContent)) - ->will($this->returnValue($mockVisitor)); - $this->assertSame($mockVisitor, vfsStream::inspect($mockVisitor, $mockContent)); - } - - /** - * @test - * @group issue_10 - * @since 0.10.0 - */ - public function inspectWithoutContentGivesRootToVisitor() - { - $root = vfsStream::setup(); - $mockVisitor = $this->getMock('org\\bovigo\\vfs\\visitor\\vfsStreamVisitor'); - $mockVisitor->expects($this->once()) - ->method('visitDirectory') - ->with($this->equalTo($root)) - ->will($this->returnValue($mockVisitor)); - $this->assertSame($mockVisitor, vfsStream::inspect($mockVisitor)); - } - - /** - * @test - * @group issue_10 - * @expectedException \InvalidArgumentException - * @since 0.10.0 - */ - public function inspectWithoutContentAndWithoutRootThrowsInvalidArgumentException() - { - $mockVisitor = $this->getMock('org\\bovigo\\vfs\\visitor\\vfsStreamVisitor'); - $mockVisitor->expects($this->never()) - ->method('visit'); - $mockVisitor->expects($this->never()) - ->method('visitDirectory'); - vfsStream::inspect($mockVisitor); - } - - /** - * returns path to file system copy resource directory - * - * @return string - */ - protected function getFileSystemCopyDir() - { - return realpath(dirname(__FILE__) . '/../../../../resources/filesystemcopy'); - } - - /** - * @test - * @group issue_4 - * @expectedException \InvalidArgumentException - * @since 0.11.0 - */ - public function copyFromFileSystemThrowsExceptionIfNoBaseDirGivenAndNoRootSet() - { - vfsStream::copyFromFileSystem($this->getFileSystemCopyDir()); - } - - /** - * @test - * @group issue_4 - * @since 0.11.0 - */ - public function copyFromEmptyFolder() - { - $baseDir = vfsStream::copyFromFileSystem($this->getFileSystemCopyDir() . '/emptyFolder', - vfsStream::newDirectory('test') - ); - $baseDir->removeChild('.gitignore'); - $this->assertFalse($baseDir->hasChildren()); - } - - /** - * @test - * @group issue_4 - * @since 0.11.0 - */ - public function copyFromEmptyFolderWithRoot() - { - $root = vfsStream::setup(); - $this->assertEquals($root, - vfsStream::copyFromFileSystem($this->getFileSystemCopyDir() . '/emptyFolder') - ); - $root->removeChild('.gitignore'); - $this->assertFalse($root->hasChildren()); - } - - /** - * @test - * @group issue_4 - * @since 0.11.0 - */ - public function copyFromWithSubFolders() - { - $baseDir = vfsStream::copyFromFileSystem($this->getFileSystemCopyDir(), - vfsStream::newDirectory('test'), - 3 - ); - $this->assertTrue($baseDir->hasChildren()); - $this->assertTrue($baseDir->hasChild('emptyFolder')); - $this->assertTrue($baseDir->hasChild('withSubfolders')); - $subfolderDir = $baseDir->getChild('withSubfolders'); - $this->assertTrue($subfolderDir->hasChild('subfolder1')); - $this->assertTrue($subfolderDir->getChild('subfolder1')->hasChild('file1.txt')); - $this->assertVfsFile($subfolderDir->getChild('subfolder1/file1.txt'), ' '); - $this->assertTrue($subfolderDir->hasChild('subfolder2')); - $this->assertTrue($subfolderDir->hasChild('aFile.txt')); - $this->assertVfsFile($subfolderDir->getChild('aFile.txt'), 'foo'); - } - - /** - * @test - * @group issue_4 - * @since 0.11.0 - */ - public function copyFromWithSubFoldersWithRoot() - { - $root = vfsStream::setup(); - $this->assertEquals($root, - vfsStream::copyFromFileSystem($this->getFileSystemCopyDir(), - null, - 3 - ) - ); - $this->assertTrue($root->hasChildren()); - $this->assertTrue($root->hasChild('emptyFolder')); - $this->assertTrue($root->hasChild('withSubfolders')); - $subfolderDir = $root->getChild('withSubfolders'); - $this->assertTrue($subfolderDir->hasChild('subfolder1')); - $this->assertTrue($subfolderDir->getChild('subfolder1')->hasChild('file1.txt')); - $this->assertVfsFile($subfolderDir->getChild('subfolder1/file1.txt'), ' '); - $this->assertTrue($subfolderDir->hasChild('subfolder2')); - $this->assertTrue($subfolderDir->hasChild('aFile.txt')); - $this->assertVfsFile($subfolderDir->getChild('aFile.txt'), 'foo'); - } - - /** - * @test - * @group issue_4 - * @group issue_29 - * @since 0.11.2 - */ - public function copyFromPreservesFilePermissions() - { - if (DIRECTORY_SEPARATOR !== '/') { - $this->markTestSkipped('Only applicable on Linux style systems.'); - } - - $copyDir = $this->getFileSystemCopyDir(); - $root = vfsStream::setup(); - $this->assertEquals($root, - vfsStream::copyFromFileSystem($copyDir, - null - ) - ); - $this->assertEquals(fileperms($copyDir . '/withSubfolders') - vfsStreamContent::TYPE_DIR, - $root->getChild('withSubfolders') - ->getPermissions() - ); - $this->assertEquals(fileperms($copyDir . '/withSubfolders/aFile.txt') - vfsStreamContent::TYPE_FILE, - $root->getChild('withSubfolders/aFile.txt') - ->getPermissions() - ); - } - - /** - * To test this the max file size is reduced to something reproduceable. - * - * @test - * @group issue_91 - * @since 1.5.0 - */ - public function copyFromFileSystemMocksLargeFiles() - { - if (DIRECTORY_SEPARATOR !== '/') { - $this->markTestSkipped('Only applicable on Linux style systems.'); - } - - $copyDir = $this->getFileSystemCopyDir(); - $root = vfsStream::setup(); - vfsStream::copyFromFileSystem($copyDir, $root, 3); - $this->assertEquals( - ' ', - $root->getChild('withSubfolders/subfolder1/file1.txt')->getContent() - ); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamUmaskTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamUmaskTestCase.php deleted file mode 100644 index 342af310b..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamUmaskTestCase.php +++ /dev/null @@ -1,195 +0,0 @@ -assertEquals(vfsStream::umask(), - vfsStream::umask() - ); - $this->assertEquals(0000, - vfsStream::umask() - ); - } - - /** - * @test - */ - public function changingUmaskSettingReturnsOldUmaskSetting() - { - $this->assertEquals(0000, - vfsStream::umask(0022) - ); - $this->assertEquals(0022, - vfsStream::umask() - ); - } - - /** - * @test - */ - public function createFileWithDefaultUmaskSetting() - { - $file = new vfsStreamFile('foo'); - $this->assertEquals(0666, $file->getPermissions()); - } - - /** - * @test - */ - public function createFileWithDifferentUmaskSetting() - { - vfsStream::umask(0022); - $file = new vfsStreamFile('foo'); - $this->assertEquals(0644, $file->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryWithDefaultUmaskSetting() - { - $directory = new vfsStreamDirectory('foo'); - $this->assertEquals(0777, $directory->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryWithDifferentUmaskSetting() - { - vfsStream::umask(0022); - $directory = new vfsStreamDirectory('foo'); - $this->assertEquals(0755, $directory->getPermissions()); - } - - /** - * @test - */ - public function createFileUsingStreamWithDefaultUmaskSetting() - { - $root = vfsStream::setup(); - file_put_contents(vfsStream::url('root/newfile.txt'), 'file content'); - $this->assertEquals(0666, $root->getChild('newfile.txt')->getPermissions()); - } - - /** - * @test - */ - public function createFileUsingStreamWithDifferentUmaskSetting() - { - $root = vfsStream::setup(); - vfsStream::umask(0022); - file_put_contents(vfsStream::url('root/newfile.txt'), 'file content'); - $this->assertEquals(0644, $root->getChild('newfile.txt')->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryUsingStreamWithDefaultUmaskSetting() - { - $root = vfsStream::setup(); - mkdir(vfsStream::url('root/newdir')); - $this->assertEquals(0777, $root->getChild('newdir')->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryUsingStreamWithDifferentUmaskSetting() - { - $root = vfsStream::setup(); - vfsStream::umask(0022); - mkdir(vfsStream::url('root/newdir')); - $this->assertEquals(0755, $root->getChild('newdir')->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryUsingStreamWithExplicit0() - { - $root = vfsStream::setup(); - vfsStream::umask(0022); - mkdir(vfsStream::url('root/newdir'), null); - $this->assertEquals(0000, $root->getChild('newdir')->getPermissions()); - } - - /** - * @test - * - */ - public function createDirectoryUsingStreamWithDifferentUmaskSettingButExplicit0777() - { - $root = vfsStream::setup(); - vfsStream::umask(0022); - mkdir(vfsStream::url('root/newdir'), 0777); - $this->assertEquals(0755, $root->getChild('newdir')->getPermissions()); - } - - /** - * @test - */ - public function createDirectoryUsingStreamWithDifferentUmaskSettingButExplicitModeRequestedByCall() - { - $root = vfsStream::setup(); - vfsStream::umask(0022); - mkdir(vfsStream::url('root/newdir'), 0700); - $this->assertEquals(0700, $root->getChild('newdir')->getPermissions()); - } - - /** - * @test - */ - public function defaultUmaskSettingDoesNotInfluenceSetup() - { - $root = vfsStream::setup(); - $this->assertEquals(0777, $root->getPermissions()); - } - - /** - * @test - */ - public function umaskSettingShouldBeRespectedBySetup() - { - vfsStream::umask(0022); - $root = vfsStream::setup(); - $this->assertEquals(0755, $root->getPermissions()); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperAlreadyRegisteredTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperAlreadyRegisteredTestCase.php deleted file mode 100644 index c7f78dcc8..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperAlreadyRegisteredTestCase.php +++ /dev/null @@ -1,63 +0,0 @@ -getMock('org\\bovigo\\vfs\\vfsStreamWrapper'); - stream_wrapper_register(vfsStream::SCHEME, get_class($mock)); - } - - /** - * clean up test environment - */ - public function tearDown() - { - TestvfsStreamWrapper::unregister(); - } - - /** - * registering the stream wrapper when another stream wrapper is already - * registered for the vfs scheme should throw an exception - * - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - */ - public function registerOverAnotherStreamWrapper() - { - vfsStreamWrapper::register(); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperBaseTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperBaseTestCase.php deleted file mode 100644 index 52ec40cf7..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperBaseTestCase.php +++ /dev/null @@ -1,99 +0,0 @@ -fooURL = vfsStream::url('foo'); - $this->barURL = vfsStream::url('foo/bar'); - $this->baz1URL = vfsStream::url('foo/bar/baz1'); - $this->baz2URL = vfsStream::url('foo/baz2'); - $this->foo = new vfsStreamDirectory('foo'); - $this->bar = new vfsStreamDirectory('bar'); - $this->baz1 = vfsStream::newFile('baz1') - ->lastModified(300) - ->lastAccessed(300) - ->lastAttributeModified(300) - ->withContent('baz 1'); - $this->baz2 = vfsStream::newFile('baz2') - ->withContent('baz2') - ->lastModified(400) - ->lastAccessed(400) - ->lastAttributeModified(400); - $this->bar->addChild($this->baz1); - $this->foo->addChild($this->bar); - $this->foo->addChild($this->baz2); - $this->foo->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - $this->bar->lastModified(200) - ->lastAccessed(100) - ->lastAttributeModified(100); - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot($this->foo); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirSeparatorTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirSeparatorTestCase.php deleted file mode 100644 index 1fd2a2d9c..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirSeparatorTestCase.php +++ /dev/null @@ -1,73 +0,0 @@ -root = vfsStream::setup(); - } - - /** - * @test - */ - public function fileCanBeAccessedUsingWinDirSeparator() - { - vfsStream::newFile('foo/bar/baz.txt') - ->at($this->root) - ->withContent('test'); - $this->assertEquals('test', file_get_contents('vfs://root/foo\bar\baz.txt')); - } - - - /** - * @test - */ - public function directoryCanBeCreatedUsingWinDirSeparator() - { - mkdir('vfs://root/dir\bar\foo', true, 0777); - $this->assertTrue($this->root->hasChild('dir')); - $this->assertTrue($this->root->getChild('dir')->hasChild('bar')); - $this->assertTrue($this->root->getChild('dir/bar')->hasChild('foo')); - } - - /** - * @test - */ - public function directoryExitsTestUsingTrailingWinDirSeparator() - { - $structure = array( - 'dir' => array( - 'bar' => array( - ) - ) - ); - vfsStream::create($structure, $this->root); - - $this->assertTrue(file_exists(vfsStream::url('root/').'dir\\')); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirTestCase.php deleted file mode 100644 index 6e2f44ba3..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperDirTestCase.php +++ /dev/null @@ -1,488 +0,0 @@ -assertFalse(mkdir(vfsStream::url('another'))); - $this->assertEquals(2, count($this->foo->getChildren())); - $this->assertSame($this->foo, vfsStreamWrapper::getRoot()); - } - - /** - * mkdir() should not overwrite existing root - * - * @test - */ - public function mkdirNoNewRootRecursively() - { - $this->assertFalse(mkdir(vfsStream::url('another/more'), 0777, true)); - $this->assertEquals(2, count($this->foo->getChildren())); - $this->assertSame($this->foo, vfsStreamWrapper::getRoot()); - } - - /** - * assert that mkdir() creates the correct directory structure - * - * @test - * @group permissions - */ - public function mkdirNonRecursively() - { - $this->assertFalse(mkdir($this->barURL . '/another/more')); - $this->assertEquals(2, count($this->foo->getChildren())); - $this->assertTrue(mkdir($this->fooURL . '/another')); - $this->assertEquals(3, count($this->foo->getChildren())); - $this->assertEquals(0777, $this->foo->getChild('another')->getPermissions()); - } - - /** - * assert that mkdir() creates the correct directory structure - * - * @test - * @group permissions - */ - public function mkdirRecursively() - { - $this->assertTrue(mkdir($this->fooURL . '/another/more', 0777, true)); - $this->assertEquals(3, count($this->foo->getChildren())); - $another = $this->foo->getChild('another'); - $this->assertTrue($another->hasChild('more')); - $this->assertEquals(0777, $this->foo->getChild('another')->getPermissions()); - $this->assertEquals(0777, $this->foo->getChild('another')->getChild('more')->getPermissions()); - } - - /** - * @test - * @group issue_9 - * @since 0.9.0 - */ - public function mkdirWithDots() - { - $this->assertTrue(mkdir($this->fooURL . '/another/../more/.', 0777, true)); - $this->assertEquals(3, count($this->foo->getChildren())); - $this->assertTrue($this->foo->hasChild('more')); - } - - /** - * no root > new directory becomes root - * - * @test - * @group permissions - */ - public function mkdirWithoutRootCreatesNewRoot() - { - vfsStreamWrapper::register(); - $this->assertTrue(@mkdir(vfsStream::url('foo'))); - $this->assertEquals(vfsStreamContent::TYPE_DIR, vfsStreamWrapper::getRoot()->getType()); - $this->assertEquals('foo', vfsStreamWrapper::getRoot()->getName()); - $this->assertEquals(0777, vfsStreamWrapper::getRoot()->getPermissions()); - } - - /** - * trying to create a subdirectory of a file should not work - * - * @test - */ - public function mkdirOnFileReturnsFalse() - { - $this->assertFalse(mkdir($this->baz1URL . '/another/more', 0777, true)); - } - - /** - * assert that mkdir() creates the correct directory structure - * - * @test - * @group permissions - */ - public function mkdirNonRecursivelyDifferentPermissions() - { - $this->assertTrue(mkdir($this->fooURL . '/another', 0755)); - $this->assertEquals(0755, $this->foo->getChild('another')->getPermissions()); - } - - /** - * assert that mkdir() creates the correct directory structure - * - * @test - * @group permissions - */ - public function mkdirRecursivelyDifferentPermissions() - { - $this->assertTrue(mkdir($this->fooURL . '/another/more', 0755, true)); - $this->assertEquals(3, count($this->foo->getChildren())); - $another = $this->foo->getChild('another'); - $this->assertTrue($another->hasChild('more')); - $this->assertEquals(0755, $this->foo->getChild('another')->getPermissions()); - $this->assertEquals(0755, $this->foo->getChild('another')->getChild('more')->getPermissions()); - } - - /** - * assert that mkdir() creates the correct directory structure - * - * @test - * @group permissions - */ - public function mkdirRecursivelyUsesDefaultPermissions() - { - $this->foo->chmod(0700); - $this->assertTrue(mkdir($this->fooURL . '/another/more', 0777, true)); - $this->assertEquals(3, count($this->foo->getChildren())); - $another = $this->foo->getChild('another'); - $this->assertTrue($another->hasChild('more')); - $this->assertEquals(0777, $this->foo->getChild('another')->getPermissions()); - $this->assertEquals(0777, $this->foo->getChild('another')->getChild('more')->getPermissions()); - } - - /** - * no root > new directory becomes root - * - * @test - * @group permissions - */ - public function mkdirWithoutRootCreatesNewRootDifferentPermissions() - { - vfsStreamWrapper::register(); - $this->assertTrue(@mkdir(vfsStream::url('foo'), 0755)); - $this->assertEquals(vfsStreamContent::TYPE_DIR, vfsStreamWrapper::getRoot()->getType()); - $this->assertEquals('foo', vfsStreamWrapper::getRoot()->getName()); - $this->assertEquals(0755, vfsStreamWrapper::getRoot()->getPermissions()); - } - - /** - * no root > new directory becomes root - * - * @test - * @group permissions - */ - public function mkdirWithoutRootCreatesNewRootWithDefaultPermissions() - { - vfsStreamWrapper::register(); - $this->assertTrue(@mkdir(vfsStream::url('foo'))); - $this->assertEquals(vfsStreamContent::TYPE_DIR, vfsStreamWrapper::getRoot()->getType()); - $this->assertEquals('foo', vfsStreamWrapper::getRoot()->getName()); - $this->assertEquals(0777, vfsStreamWrapper::getRoot()->getPermissions()); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function mkdirDirCanNotCreateNewDirInNonWritingDirectory() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root')); - vfsStreamWrapper::getRoot()->addChild(new vfsStreamDirectory('restrictedFolder', 0000)); - $this->assertFalse(is_writable(vfsStream::url('root/restrictedFolder/'))); - $this->assertFalse(mkdir(vfsStream::url('root/restrictedFolder/newFolder'))); - $this->assertFalse(vfsStreamWrapper::getRoot()->hasChild('restrictedFolder/newFolder')); - } - - /** - * @test - * @group issue_28 - */ - public function mkDirShouldNotOverwriteExistingDirectories() - { - vfsStream::setup('root'); - $dir = vfsStream::url('root/dir'); - $this->assertTrue(mkdir($dir)); - $this->assertFalse(@mkdir($dir)); - } - - /** - * @test - * @group issue_28 - * @expectedException PHPUnit_Framework_Error - * @expectedExceptionMessage mkdir(): Path vfs://root/dir exists - */ - public function mkDirShouldNotOverwriteExistingDirectoriesAndTriggerE_USER_WARNING() - { - vfsStream::setup('root'); - $dir = vfsStream::url('root/dir'); - $this->assertTrue(mkdir($dir)); - $this->assertFalse(mkdir($dir)); - } - - /** - * @test - * @group issue_28 - */ - public function mkDirShouldNotOverwriteExistingFiles() - { - $root = vfsStream::setup('root'); - vfsStream::newFile('test.txt')->at($root); - $this->assertFalse(@mkdir(vfsStream::url('root/test.txt'))); - } - - /** - * @test - * @group issue_28 - * @expectedException PHPUnit_Framework_Error - * @expectedExceptionMessage mkdir(): Path vfs://root/test.txt exists - */ - public function mkDirShouldNotOverwriteExistingFilesAndTriggerE_USER_WARNING() - { - $root = vfsStream::setup('root'); - vfsStream::newFile('test.txt')->at($root); - $this->assertFalse(mkdir(vfsStream::url('root/test.txt'))); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function canNotIterateOverNonReadableDirectory() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0000)); - $this->assertFalse(@opendir(vfsStream::url('root'))); - $this->assertFalse(@dir(vfsStream::url('root'))); - } - - /** - * assert is_dir() returns correct result - * - * @test - */ - public function is_dir() - { - $this->assertTrue(is_dir($this->fooURL)); - $this->assertTrue(is_dir($this->fooURL . '/.')); - $this->assertTrue(is_dir($this->barURL)); - $this->assertTrue(is_dir($this->barURL . '/.')); - $this->assertFalse(is_dir($this->baz1URL)); - $this->assertFalse(is_dir($this->baz2URL)); - $this->assertFalse(is_dir($this->fooURL . '/another')); - $this->assertFalse(is_dir(vfsStream::url('another'))); - } - - /** - * can not unlink without root - * - * @test - */ - public function canNotUnlinkDirectoryWithoutRoot() - { - vfsStreamWrapper::register(); - $this->assertFalse(@rmdir(vfsStream::url('foo'))); - } - - /** - * rmdir() can not remove files - * - * @test - */ - public function rmdirCanNotRemoveFiles() - { - $this->assertFalse(rmdir($this->baz1URL)); - $this->assertFalse(rmdir($this->baz2URL)); - } - - /** - * rmdir() can not remove a non-existing directory - * - * @test - */ - public function rmdirCanNotRemoveNonExistingDirectory() - { - $this->assertFalse(rmdir($this->fooURL . '/another')); - } - - /** - * rmdir() can not remove non-empty directories - * - * @test - */ - public function rmdirCanNotRemoveNonEmptyDirectory() - { - $this->assertFalse(rmdir($this->fooURL)); - $this->assertFalse(rmdir($this->barURL)); - } - - /** - * @test - */ - public function rmdirCanRemoveEmptyDirectory() - { - vfsStream::newDirectory('empty')->at($this->foo); - $this->assertTrue($this->foo->hasChild('empty')); - $this->assertTrue(rmdir($this->fooURL . '/empty')); - $this->assertFalse($this->foo->hasChild('empty')); - } - - /** - * @test - */ - public function rmdirCanRemoveEmptyDirectoryWithDot() - { - vfsStream::newDirectory('empty')->at($this->foo); - $this->assertTrue($this->foo->hasChild('empty')); - $this->assertTrue(rmdir($this->fooURL . '/empty/.')); - $this->assertFalse($this->foo->hasChild('empty')); - } - - /** - * rmdir() can remove empty directories - * - * @test - */ - public function rmdirCanRemoveEmptyRoot() - { - $this->foo->removeChild('bar'); - $this->foo->removeChild('baz2'); - $this->assertTrue(rmdir($this->fooURL)); - $this->assertFalse(file_exists($this->fooURL)); // make sure statcache was cleared - $this->assertNull(vfsStreamWrapper::getRoot()); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function rmdirDirCanNotRemoveDirFromNonWritingDirectory() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0000)); - vfsStreamWrapper::getRoot()->addChild(new vfsStreamDirectory('nonRemovableFolder')); - $this->assertFalse(is_writable(vfsStream::url('root'))); - $this->assertFalse(rmdir(vfsStream::url('root/nonRemovableFolder'))); - $this->assertTrue(vfsStreamWrapper::getRoot()->hasChild('nonRemovableFolder')); - } - - /** - * @test - * @group permissions - * @group bug_17 - */ - public function issue17() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0770)); - vfsStreamWrapper::getRoot()->chgrp(vfsStream::GROUP_USER_1) - ->chown(vfsStream::OWNER_USER_1); - $this->assertFalse(mkdir(vfsStream::url('root/doesNotWork'))); - $this->assertFalse(vfsStreamWrapper::getRoot()->hasChild('doesNotWork')); - } - - /** - * @test - * @group bug_19 - */ - public function accessWithDoubleDotReturnsCorrectContent() - { - $this->assertEquals('baz2', - file_get_contents(vfsStream::url('foo/bar/../baz2')) - ); - } - - /** - * @test - * @group bug_115 - */ - public function accessWithExcessDoubleDotsReturnsCorrectContent() - { - $this->assertEquals('baz2', - file_get_contents(vfsStream::url('foo/../../../../bar/../baz2')) - ); - } - - /** - * @test - * @group bug_115 - */ - public function alwaysResolvesRootDirectoryAsOwnParentWithDoubleDot() - { - vfsStreamWrapper::getRoot()->chown(vfsStream::OWNER_USER_1); - - $this->assertTrue(is_dir(vfsStream::url('foo/..'))); - $stat = stat(vfsStream::url('foo/..')); - $this->assertEquals( - vfsStream::OWNER_USER_1, - $stat['uid'] - ); - } - - - /** - * @test - * @since 0.11.0 - * @group issue_23 - */ - public function unlinkCanNotRemoveNonEmptyDirectory() - { - try { - $this->assertFalse(unlink($this->barURL)); - } catch (\PHPUnit_Framework_Error $fe) { - $this->assertEquals('unlink(vfs://foo/bar): Operation not permitted', $fe->getMessage()); - } - - $this->assertTrue($this->foo->hasChild('bar')); - $this->assertFileExists($this->barURL); - } - - /** - * @test - * @since 0.11.0 - * @group issue_23 - */ - public function unlinkCanNotRemoveEmptyDirectory() - { - vfsStream::newDirectory('empty')->at($this->foo); - try { - $this->assertTrue(unlink($this->fooURL . '/empty')); - } catch (\PHPUnit_Framework_Error $fe) { - $this->assertEquals('unlink(vfs://foo/empty): Operation not permitted', $fe->getMessage()); - } - - $this->assertTrue($this->foo->hasChild('empty')); - $this->assertFileExists($this->fooURL . '/empty'); - } - - /** - * @test - * @group issue_32 - */ - public function canCreateFolderOfSameNameAsParentFolder() - { - $root = vfsStream::setup('testFolder'); - mkdir(vfsStream::url('testFolder') . '/testFolder/subTestFolder', 0777, true); - $this->assertTrue(file_exists(vfsStream::url('testFolder/testFolder/subTestFolder/.'))); - } - - /** - * @test - * @group issue_32 - */ - public function canRetrieveFolderOfSameNameAsParentFolder() - { - $root = vfsStream::setup('testFolder'); - mkdir(vfsStream::url('testFolder') . '/testFolder/subTestFolder', 0777, true); - $this->assertTrue($root->hasChild('testFolder')); - $this->assertNotNull($root->getChild('testFolder')); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTestCase.php deleted file mode 100644 index 5bcb37adc..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTestCase.php +++ /dev/null @@ -1,458 +0,0 @@ -assertEquals('baz2', file_get_contents($this->baz2URL)); - $this->assertEquals('baz 1', file_get_contents($this->baz1URL)); - $this->assertFalse(@file_get_contents($this->barURL)); - $this->assertFalse(@file_get_contents($this->fooURL)); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function file_get_contentsNonReadableFile() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root')); - vfsStream::newFile('new.txt', 0000)->at(vfsStreamWrapper::getRoot())->withContent('content'); - $this->assertEquals('', @file_get_contents(vfsStream::url('root/new.txt'))); - } - - /** - * assert that file_put_contents() delivers correct file contents - * - * @test - */ - public function file_put_contentsExistingFile() - { - $this->assertEquals(14, file_put_contents($this->baz2URL, 'baz is not bar')); - $this->assertEquals('baz is not bar', $this->baz2->getContent()); - $this->assertEquals(6, file_put_contents($this->baz1URL, 'foobar')); - $this->assertEquals('foobar', $this->baz1->getContent()); - $this->assertFalse(@file_put_contents($this->barURL, 'This does not work.')); - $this->assertFalse(@file_put_contents($this->fooURL, 'This does not work, too.')); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function file_put_contentsExistingFileNonWritableDirectory() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0000)); - vfsStream::newFile('new.txt')->at(vfsStreamWrapper::getRoot())->withContent('content'); - $this->assertEquals(15, @file_put_contents(vfsStream::url('root/new.txt'), 'This does work.')); - $this->assertEquals('This does work.', file_get_contents(vfsStream::url('root/new.txt'))); - - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function file_put_contentsExistingNonWritableFile() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root')); - vfsStream::newFile('new.txt', 0400)->at(vfsStreamWrapper::getRoot())->withContent('content'); - $this->assertFalse(@file_put_contents(vfsStream::url('root/new.txt'), 'This does not work.')); - $this->assertEquals('content', file_get_contents(vfsStream::url('root/new.txt'))); - } - - /** - * assert that file_put_contents() delivers correct file contents - * - * @test - */ - public function file_put_contentsNonExistingFile() - { - $this->assertEquals(14, file_put_contents($this->fooURL . '/baznot.bar', 'baz is not bar')); - $this->assertEquals(3, count($this->foo->getChildren())); - $this->assertEquals(14, file_put_contents($this->barURL . '/baznot.bar', 'baz is not bar')); - $this->assertEquals(2, count($this->bar->getChildren())); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function file_put_contentsNonExistingFileNonWritableDirectory() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0000)); - $this->assertFalse(@file_put_contents(vfsStream::url('root/new.txt'), 'This does not work.')); - $this->assertFalse(file_exists(vfsStream::url('root/new.txt'))); - - } - - /** - * using a file pointer should work without any problems - * - * @test - */ - public function usingFilePointer() - { - $fp = fopen($this->baz1URL, 'r'); - $this->assertEquals(0, ftell($fp)); - $this->assertFalse(feof($fp)); - $this->assertEquals(0, fseek($fp, 2)); - $this->assertEquals(2, ftell($fp)); - $this->assertEquals(0, fseek($fp, 1, SEEK_CUR)); - $this->assertEquals(3, ftell($fp)); - $this->assertEquals(0, fseek($fp, 1, SEEK_END)); - $this->assertEquals(6, ftell($fp)); - $this->assertTrue(feof($fp)); - $this->assertEquals(0, fseek($fp, 2)); - $this->assertFalse(feof($fp)); - $this->assertEquals(2, ftell($fp)); - $this->assertEquals('z', fread($fp, 1)); - $this->assertEquals(3, ftell($fp)); - $this->assertEquals(' 1', fread($fp, 8092)); - $this->assertEquals(5, ftell($fp)); - $this->assertTrue(fclose($fp)); - } - - /** - * assert is_file() returns correct result - * - * @test - */ - public function is_file() - { - $this->assertFalse(is_file($this->fooURL)); - $this->assertFalse(is_file($this->barURL)); - $this->assertTrue(is_file($this->baz1URL)); - $this->assertTrue(is_file($this->baz2URL)); - $this->assertFalse(is_file($this->fooURL . '/another')); - $this->assertFalse(is_file(vfsStream::url('another'))); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function issue13CanNotOverwriteFiles() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - file_put_contents($vfsFile, 'd'); - $this->assertEquals('d', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function appendContentIfOpenedWithModeA() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'ab'); - fwrite($fp, 'd'); - fclose($fp); - $this->assertEquals('testd', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canOverwriteNonExistingFileWithModeX() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - $fp = fopen($vfsFile, 'xb'); - fwrite($fp, 'test'); - fclose($fp); - $this->assertEquals('test', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotOverwriteExistingFileWithModeX() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $this->assertFalse(@fopen($vfsFile, 'xb')); - $this->assertEquals('test', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotOpenNonExistingFileReadonly() - { - $this->assertFalse(@fopen(vfsStream::url('foo/doesNotExist.txt'), 'rb')); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotOpenNonExistingFileReadAndWrite() - { - $this->assertFalse(@fopen(vfsStream::url('foo/doesNotExist.txt'), 'rb+')); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotOpenWithIllegalMode() - { - $this->assertFalse(@fopen($this->baz2URL, 'invalid')); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotWriteToReadOnlyFile() - { - $fp = fopen($this->baz2URL, 'rb'); - $this->assertEquals('baz2', fread($fp, 4096)); - $this->assertEquals(0, fwrite($fp, 'foo')); - fclose($fp); - $this->assertEquals('baz2', file_get_contents($this->baz2URL)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotReadFromWriteOnlyFileWithModeW() - { - $fp = fopen($this->baz2URL, 'wb'); - $this->assertEquals('', fread($fp, 4096)); - $this->assertEquals(3, fwrite($fp, 'foo')); - fseek($fp, 0); - $this->assertEquals('', fread($fp, 4096)); - fclose($fp); - $this->assertEquals('foo', file_get_contents($this->baz2URL)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotReadFromWriteOnlyFileWithModeA() - { - $fp = fopen($this->baz2URL, 'ab'); - $this->assertEquals('', fread($fp, 4096)); - $this->assertEquals(3, fwrite($fp, 'foo')); - fseek($fp, 0); - $this->assertEquals('', fread($fp, 4096)); - fclose($fp); - $this->assertEquals('baz2foo', file_get_contents($this->baz2URL)); - } - - /** - * @test - * @group issue7 - * @group issue13 - */ - public function canNotReadFromWriteOnlyFileWithModeX() - { - $vfsFile = vfsStream::url('foo/modeXtest.txt'); - $fp = fopen($vfsFile, 'xb'); - $this->assertEquals('', fread($fp, 4096)); - $this->assertEquals(3, fwrite($fp, 'foo')); - fseek($fp, 0); - $this->assertEquals('', fread($fp, 4096)); - fclose($fp); - $this->assertEquals('foo', file_get_contents($vfsFile)); - } - - /** - * @test - * @group permissions - * @group bug_15 - */ - public function canNotRemoveFileFromDirectoryWithoutWritePermissions() - { - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(new vfsStreamDirectory('root', 0000)); - vfsStream::newFile('new.txt')->at(vfsStreamWrapper::getRoot()); - $this->assertFalse(unlink(vfsStream::url('root/new.txt'))); - $this->assertTrue(file_exists(vfsStream::url('root/new.txt'))); - } - - /** - * @test - * @group issue_30 - */ - public function truncatesFileWhenOpenedWithModeW() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'wb'); - $this->assertEquals('', file_get_contents($vfsFile)); - fclose($fp); - } - - /** - * @test - * @group issue_30 - */ - public function createsNonExistingFileWhenOpenedWithModeC() - { - $vfsFile = vfsStream::url('foo/tobecreated.txt'); - $fp = fopen($vfsFile, 'cb'); - fwrite($fp, 'some content'); - $this->assertTrue($this->foo->hasChild('tobecreated.txt')); - fclose($fp); - $this->assertEquals('some content', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue_30 - */ - public function createsNonExistingFileWhenOpenedWithModeCplus() - { - $vfsFile = vfsStream::url('foo/tobecreated.txt'); - $fp = fopen($vfsFile, 'cb+'); - fwrite($fp, 'some content'); - $this->assertTrue($this->foo->hasChild('tobecreated.txt')); - fclose($fp); - $this->assertEquals('some content', file_get_contents($vfsFile)); - } - - /** - * @test - * @group issue_30 - */ - public function doesNotTruncateFileWhenOpenedWithModeC() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'cb'); - $this->assertEquals('test', file_get_contents($vfsFile)); - fclose($fp); - } - - /** - * @test - * @group issue_30 - */ - public function setsPointerToStartWhenOpenedWithModeC() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'cb'); - $this->assertEquals(0, ftell($fp)); - fclose($fp); - } - - /** - * @test - * @group issue_30 - */ - public function doesNotTruncateFileWhenOpenedWithModeCplus() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'cb+'); - $this->assertEquals('test', file_get_contents($vfsFile)); - fclose($fp); - } - - /** - * @test - * @group issue_30 - */ - public function setsPointerToStartWhenOpenedWithModeCplus() - { - $vfsFile = vfsStream::url('foo/overwrite.txt'); - file_put_contents($vfsFile, 'test'); - $fp = fopen($vfsFile, 'cb+'); - $this->assertEquals(0, ftell($fp)); - fclose($fp); - } - - /** - * @test - */ - public function cannotOpenExistingNonwritableFileWithModeA() - { - $this->baz1->chmod(0400); - $this->assertFalse(@fopen($this->baz1URL, 'a')); - } - - /** - * @test - */ - public function cannotOpenExistingNonwritableFileWithModeW() - { - $this->baz1->chmod(0400); - $this->assertFalse(@fopen($this->baz1URL, 'w')); - } - - /** - * @test - */ - public function cannotOpenNonReadableFileWithModeR() - { - $this->baz1->chmod(0); - $this->assertFalse(@fopen($this->baz1URL, 'r')); - } - - /** - * @test - */ - public function cannotRenameToNonWritableDir() - { - $this->bar->chmod(0); - $this->assertFalse(@rename($this->baz2URL, vfsStream::url('foo/bar/baz3'))); - } - - /** - * @test - * @group issue_38 - */ - public function cannotReadFileFromNonReadableDir() - { - $this->markTestSkipped("Issue #38."); - $this->bar->chmod(0); - $this->assertFalse(@file_get_contents($this->baz1URL)); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTimesTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTimesTestCase.php deleted file mode 100644 index ebe0a52cf..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFileTimesTestCase.php +++ /dev/null @@ -1,315 +0,0 @@ -lastModified(50) - ->lastAccessed(50) - ->lastAttributeModified(50); - $this->fooUrl = vfsStream::url('root/foo.txt'); - $this->barUrl = vfsStream::url('root/bar'); - $this->bazUrl = vfsStream::url('root/bar/baz.txt'); - } - - /** - * helper assertion for the tests - * - * @param string $url url to check - * @param vfsStreamContent $content content to compare - */ - protected function assertFileTimesEqualStreamTimes($url, vfsStreamContent $content) - { - $this->assertEquals(filemtime($url), $content->filemtime()); - $this->assertEquals(fileatime($url), $content->fileatime()); - $this->assertEquals(filectime($url), $content->filectime()); - } - - /** - * @test - * @group issue_7 - * @group issue_26 - */ - public function openFileChangesAttributeTimeOnly() - { - $file = vfsStream::newFile('foo.txt') - ->withContent('test') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - fclose(fopen($this->fooUrl, 'rb')); - $this->assertGreaterThan(time() - 2, fileatime($this->fooUrl)); - $this->assertLessThanOrEqual(time(), fileatime($this->fooUrl)); - $this->assertLessThanOrEqual(100, filemtime($this->fooUrl)); - $this->assertEquals(100, filectime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, $file); - } - - /** - * @test - * @group issue_7 - * @group issue_26 - */ - public function fileGetContentsChangesAttributeTimeOnly() - { - $file = vfsStream::newFile('foo.txt') - ->withContent('test') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - file_get_contents($this->fooUrl); - $this->assertGreaterThan(time() - 2, fileatime($this->fooUrl)); - $this->assertLessThanOrEqual(time(), fileatime($this->fooUrl)); - $this->assertLessThanOrEqual(100, filemtime($this->fooUrl)); - $this->assertEquals(100, filectime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, $file); - } - - /** - * @test - * @group issue_7 - * @group issue_26 - */ - public function openFileWithTruncateChangesAttributeAndModificationTime() - { - $file = vfsStream::newFile('foo.txt') - ->withContent('test') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - fclose(fopen($this->fooUrl, 'wb')); - $this->assertGreaterThan(time() - 2, filemtime($this->fooUrl)); - $this->assertGreaterThan(time() - 2, fileatime($this->fooUrl)); - $this->assertLessThanOrEqual(time(), filemtime($this->fooUrl)); - $this->assertLessThanOrEqual(time(), fileatime($this->fooUrl)); - $this->assertEquals(100, filectime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, $file); - } - - /** - * @test - * @group issue_7 - */ - public function readFileChangesAccessTime() - { - $file = vfsStream::newFile('foo.txt') - ->withContent('test') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - $fp = fopen($this->fooUrl, 'rb'); - $openTime = time(); - sleep(2); - fread($fp, 1024); - fclose($fp); - $this->assertLessThanOrEqual($openTime, filemtime($this->fooUrl)); - $this->assertLessThanOrEqual($openTime + 3, fileatime($this->fooUrl)); - $this->assertEquals(100, filectime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, $file); - } - - /** - * @test - * @group issue_7 - */ - public function writeFileChangesModificationTime() - { - $file = vfsStream::newFile('foo.txt') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - $fp = fopen($this->fooUrl, 'wb'); - $openTime = time(); - sleep(2); - fwrite($fp, 'test'); - fclose($fp); - $this->assertLessThanOrEqual($openTime + 3, filemtime($this->fooUrl)); - $this->assertLessThanOrEqual($openTime, fileatime($this->fooUrl)); - $this->assertEquals(100, filectime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, $file); - - } - - /** - * @test - * @group issue_7 - */ - public function createNewFileSetsAllTimesToCurrentTime() - { - file_put_contents($this->fooUrl, 'test'); - $this->assertLessThanOrEqual(time(), filemtime($this->fooUrl)); - $this->assertEquals(fileatime($this->fooUrl), filectime($this->fooUrl)); - $this->assertEquals(fileatime($this->fooUrl), filemtime($this->fooUrl)); - $this->assertFileTimesEqualStreamTimes($this->fooUrl, vfsStreamWrapper::getRoot()->getChild('foo.txt')); - } - - /** - * @test - * @group issue_7 - */ - public function createNewFileChangesAttributeAndModificationTimeOfContainingDirectory() - { - $dir = vfsStream::newDirectory('bar') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - file_put_contents($this->bazUrl, 'test'); - $this->assertLessThanOrEqual(time(), filemtime($this->barUrl)); - $this->assertLessThanOrEqual(time(), filectime($this->barUrl)); - $this->assertEquals(100, fileatime($this->barUrl)); - $this->assertFileTimesEqualStreamTimes($this->barUrl, $dir); - } - - /** - * @test - * @group issue_7 - */ - public function addNewFileNameWithLinkFunctionChangesAttributeTimeOfOriginalFile() - { - $this->markTestSkipped('Links are currently not supported by vfsStream.'); - } - - /** - * @test - * @group issue_7 - */ - public function addNewFileNameWithLinkFunctionChangesAttributeAndModificationTimeOfDirectoryContainingLink() - { - $this->markTestSkipped('Links are currently not supported by vfsStream.'); - } - - /** - * @test - * @group issue_7 - */ - public function removeFileChangesAttributeAndModificationTimeOfContainingDirectory() - { - $dir = vfsStream::newDirectory('bar') - ->at(vfsStreamWrapper::getRoot()); - $file = vfsStream::newFile('baz.txt') - ->at($dir) - ->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - $dir->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - unlink($this->bazUrl); - $this->assertLessThanOrEqual(time(), filemtime($this->barUrl)); - $this->assertLessThanOrEqual(time(), filectime($this->barUrl)); - $this->assertEquals(100, fileatime($this->barUrl)); - $this->assertFileTimesEqualStreamTimes($this->barUrl, $dir); - } - - /** - * @test - * @group issue_7 - */ - public function renameFileChangesAttributeAndModificationTimeOfAffectedDirectories() - { - $target = vfsStream::newDirectory('target') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(200) - ->lastAccessed(200) - ->lastAttributeModified(200); - $source = vfsStream::newDirectory('bar') - ->at(vfsStreamWrapper::getRoot()); - $file = vfsStream::newFile('baz.txt') - ->at($source) - ->lastModified(300) - ->lastAccessed(300) - ->lastAttributeModified(300); - $source->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - rename($this->bazUrl, vfsStream::url('root/target/baz.txt')); - $this->assertLessThanOrEqual(time(), filemtime($this->barUrl)); - $this->assertLessThanOrEqual(time(), filectime($this->barUrl)); - $this->assertEquals(100, fileatime($this->barUrl)); - $this->assertFileTimesEqualStreamTimes($this->barUrl, $source); - $this->assertLessThanOrEqual(time(), filemtime(vfsStream::url('root/target'))); - $this->assertLessThanOrEqual(time(), filectime(vfsStream::url('root/target'))); - $this->assertEquals(200, fileatime(vfsStream::url('root/target'))); - $this->assertFileTimesEqualStreamTimes(vfsStream::url('root/target'), $target); - } - - /** - * @test - * @group issue_7 - */ - public function renameFileDoesNotChangeFileTimesOfFileItself() - { - $target = vfsStream::newDirectory('target') - ->at(vfsStreamWrapper::getRoot()) - ->lastModified(200) - ->lastAccessed(200) - ->lastAttributeModified(200); - $source = vfsStream::newDirectory('bar') - ->at(vfsStreamWrapper::getRoot()); - $file = vfsStream::newFile('baz.txt') - ->at($source) - ->lastModified(300) - ->lastAccessed(300) - ->lastAttributeModified(300); - $source->lastModified(100) - ->lastAccessed(100) - ->lastAttributeModified(100); - rename($this->bazUrl, vfsStream::url('root/target/baz.txt')); - $this->assertEquals(300, filemtime(vfsStream::url('root/target/baz.txt'))); - $this->assertEquals(300, filectime(vfsStream::url('root/target/baz.txt'))); - $this->assertEquals(300, fileatime(vfsStream::url('root/target/baz.txt'))); - $this->assertFileTimesEqualStreamTimes(vfsStream::url('root/target/baz.txt'), $file); - } - - /** - * @test - * @group issue_7 - */ - public function changeFileAttributesChangesAttributeTimeOfFileItself() - { - $this->markTestSkipped('Changing file attributes via stream wrapper for self-defined streams is not supported by PHP.'); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFlockTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFlockTestCase.php deleted file mode 100644 index 1b329dc50..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperFlockTestCase.php +++ /dev/null @@ -1,440 +0,0 @@ -root = vfsStream::setup(); - } - - /** - * @test - */ - public function fileIsNotLockedByDefault() - { - $this->assertFalse(vfsStream::newFile('foo.txt')->isLocked()); - } - - /** - * @test - */ - public function streamIsNotLockedByDefault() - { - file_put_contents(vfsStream::url('root/foo.txt'), 'content'); - $this->assertFalse($this->root->getChild('foo.txt')->isLocked()); - } - - /** - * @test - */ - public function canAquireSharedLock() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertTrue(flock($fp, LOCK_SH)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - - } - - /** - * @test - */ - public function canAquireSharedLockWithNonBlockingFlockCall() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertTrue(flock($fp, LOCK_SH | LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - - } - - /** - * @test - */ - public function canAquireEclusiveLock() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertTrue(flock($fp, LOCK_EX)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @test - */ - public function canAquireEclusiveLockWithNonBlockingFlockCall() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertTrue(flock($fp, LOCK_EX | LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @test - */ - public function canRemoveLock() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_EX); - $this->assertTrue(flock($fp, LOCK_UN)); - $this->assertFalse($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canRemoveLockWhenNotLocked() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertTrue(flock($fp, LOCK_UN)); - $this->assertFalse($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertFalse($file->hasSharedLock($fp)); - $this->assertFalse($file->hasExclusiveLock()); - $this->assertFalse($file->hasExclusiveLock($fp)); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canRemoveSharedLockWithoutRemovingSharedLockOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_SH); - $file->lock($fp2, LOCK_SH); - $this->assertTrue(flock($fp1, LOCK_UN)); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasSharedLock($fp1)); - $this->assertTrue($file->hasSharedLock($fp2)); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canNotRemoveSharedLockAcquiredOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_SH); - $this->assertTrue(flock($fp2, LOCK_UN)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canNotRemoveExlusiveLockAcquiredOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_EX); - $this->assertTrue(flock($fp2, LOCK_UN)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp1); - fclose($fp2); - } - - /** - * @test - */ - public function canRemoveLockWithNonBlockingFlockCall() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_EX); - $this->assertTrue(flock($fp, LOCK_UN | LOCK_NB)); - $this->assertFalse($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canNotAquireExclusiveLockIfAlreadyExclusivelyLockedOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_EX); - $this->assertFalse(flock($fp2, LOCK_EX + LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - $this->assertTrue($file->hasExclusiveLock($fp1)); - $this->assertFalse($file->hasExclusiveLock($fp2)); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canAquireExclusiveLockIfAlreadySelfExclusivelyLocked() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_EX); - $this->assertTrue(flock($fp, LOCK_EX + LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canNotAquireExclusiveLockIfAlreadySharedLockedOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_SH); - $this->assertFalse(flock($fp2, LOCK_EX)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canAquireExclusiveLockIfAlreadySelfSharedLocked() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_SH); - $this->assertTrue(flock($fp, LOCK_EX)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canNotAquireSharedLockIfAlreadyExclusivelyLockedOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_EX); - $this->assertFalse(flock($fp2, LOCK_SH + LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canAquireSharedLockIfAlreadySelfExclusivelyLocked() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_EX); - $this->assertTrue(flock($fp, LOCK_SH + LOCK_NB)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canAquireSharedLockIfAlreadySelfSharedLocked() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_SH); - $this->assertTrue(flock($fp, LOCK_SH)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function canAquireSharedLockIfAlreadySharedLockedOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp1, LOCK_SH); - $this->assertTrue(flock($fp2, LOCK_SH)); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertTrue($file->hasSharedLock($fp1)); - $this->assertTrue($file->hasSharedLock($fp2)); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp1); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/31 - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_31 - * @group issue_40 - */ - public function removesExclusiveLockOnStreamClose() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_EX); - fclose($fp); - $this->assertFalse($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/31 - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_31 - * @group issue_40 - */ - public function removesSharedLockOnStreamClose() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp, LOCK_SH); - fclose($fp); - $this->assertFalse($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertFalse($file->hasExclusiveLock()); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function notRemovesExclusiveLockOnStreamCloseIfExclusiveLockAcquiredOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp2, LOCK_EX); - fclose($fp1); - $this->assertTrue($file->isLocked()); - $this->assertFalse($file->hasSharedLock()); - $this->assertTrue($file->hasExclusiveLock()); - $this->assertTrue($file->hasExclusiveLock($fp2)); - fclose($fp2); - } - - /** - * @see https://github.com/mikey179/vfsStream/issues/40 - * @test - * @group issue_40 - */ - public function notRemovesSharedLockOnStreamCloseIfSharedLockAcquiredOnOtherFileHandler() - { - $file = vfsStream::newFile('foo.txt')->at($this->root); - $fp1 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $fp2 = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $file->lock($fp2, LOCK_SH); - fclose($fp1); - $this->assertTrue($file->isLocked()); - $this->assertTrue($file->hasSharedLock()); - $this->assertTrue($file->hasSharedLock($fp2)); - $this->assertFalse($file->hasExclusiveLock()); - fclose($fp2); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperLargeFileTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperLargeFileTestCase.php deleted file mode 100644 index ca1a3f51c..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperLargeFileTestCase.php +++ /dev/null @@ -1,77 +0,0 @@ -largeFile = vfsStream::newFile('large.txt') - ->withContent(LargeFileContent::withGigabytes(100)) - ->at($root); - } - - /** - * @test - */ - public function hasLargeFileSize() - { - $this->assertEquals( - 100 * 1024 * 1024 * 1024, - filesize($this->largeFile->url()) - ); - } - - /** - * @test - */ - public function canReadFromLargeFile() - { - $fp = fopen($this->largeFile->url(), 'rb'); - $data = fread($fp, 15); - fclose($fp); - $this->assertEquals(str_repeat(' ', 15), $data); - } - - /** - * @test - */ - public function canWriteIntoLargeFile() - { - $fp = fopen($this->largeFile->url(), 'rb+'); - fseek($fp, 100 * 1024 * 1024, SEEK_SET); - fwrite($fp, 'foobarbaz'); - fclose($fp); - $this->largeFile->seek((100 * 1024 * 1024) - 3, SEEK_SET); - $this->assertEquals( - ' foobarbaz ', - $this->largeFile->read(15) - ); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperQuotaTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperQuotaTestCase.php deleted file mode 100644 index afaeb4719..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperQuotaTestCase.php +++ /dev/null @@ -1,224 +0,0 @@ -root = vfsStream::setup(); - vfsStream::setQuota(10); - } - - /** - * @test - */ - public function writeLessThanQuotaWritesEverything() - { - $this->assertEquals(9, file_put_contents(vfsStream::url('root/file.txt'), '123456789')); - $this->assertEquals('123456789', $this->root->getChild('file.txt')->getContent()); - } - - /** - * @test - */ - public function writeUpToQotaWritesEverything() - { - $this->assertEquals(10, file_put_contents(vfsStream::url('root/file.txt'), '1234567890')); - $this->assertEquals('1234567890', $this->root->getChild('file.txt')->getContent()); - } - - /** - * @test - */ - public function writeMoreThanQotaWritesOnlyUpToQuota() - { - try { - file_put_contents(vfsStream::url('root/file.txt'), '12345678901'); - } catch (\PHPUnit_Framework_Error $e) { - $this->assertEquals('file_put_contents(): Only 10 of 11 bytes written, possibly out of free disk space', - $e->getMessage() - ); - } - - $this->assertEquals('1234567890', $this->root->getChild('file.txt')->getContent()); - } - - /** - * @test - */ - public function considersAllFilesForQuota() - { - vfsStream::newFile('foo.txt') - ->withContent('foo') - ->at(vfsStream::newDirectory('bar') - ->at($this->root) - ); - try { - file_put_contents(vfsStream::url('root/file.txt'), '12345678901'); - } catch (\PHPUnit_Framework_Error $e) { - $this->assertEquals('file_put_contents(): Only 7 of 11 bytes written, possibly out of free disk space', - $e->getMessage() - ); - } - - $this->assertEquals('1234567', $this->root->getChild('file.txt')->getContent()); - } - - /** - * @test - * @group issue_33 - */ - public function truncateToLessThanQuotaWritesEverything() - { - if (version_compare(PHP_VERSION, '5.4.0', '<')) { - $this->markTestSkipped('Requires PHP 5.4'); - } - - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - $fp = fopen(vfsStream::url('root/file.txt'), 'w+'); - $this->assertTrue(ftruncate($fp, 9)); - fclose($fp); - $this->assertEquals(9, - $this->root->getChild('file.txt')->size() - ); - $this->assertEquals("\0\0\0\0\0\0\0\0\0", - $this->root->getChild('file.txt')->getContent() - ); - } - - /** - * @test - * @group issue_33 - */ - public function truncateUpToQotaWritesEverything() - { - if (version_compare(PHP_VERSION, '5.4.0', '<')) { - $this->markTestSkipped('Requires PHP 5.4'); - } - - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - $fp = fopen(vfsStream::url('root/file.txt'), 'w+'); - $this->assertTrue(ftruncate($fp, 10)); - fclose($fp); - $this->assertEquals(10, - $this->root->getChild('file.txt')->size() - ); - $this->assertEquals("\0\0\0\0\0\0\0\0\0\0", - $this->root->getChild('file.txt')->getContent() - ); - } - - /** - * @test - * @group issue_33 - */ - public function truncateToMoreThanQotaWritesOnlyUpToQuota() - { - if (version_compare(PHP_VERSION, '5.4.0', '<')) { - $this->markTestSkipped('Requires PHP 5.4'); - } - - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - $fp = fopen(vfsStream::url('root/file.txt'), 'w+'); - $this->assertTrue(ftruncate($fp, 11)); - fclose($fp); - $this->assertEquals(10, - $this->root->getChild('file.txt')->size() - ); - $this->assertEquals("\0\0\0\0\0\0\0\0\0\0", - $this->root->getChild('file.txt')->getContent() - ); - } - - /** - * @test - * @group issue_33 - */ - public function truncateConsidersAllFilesForQuota() - { - if (version_compare(PHP_VERSION, '5.4.0', '<')) { - $this->markTestSkipped('Requires PHP 5.4'); - } - - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - vfsStream::newFile('bar.txt') - ->withContent('bar') - ->at(vfsStream::newDirectory('bar') - ->at($this->root) - ); - $fp = fopen(vfsStream::url('root/file.txt'), 'w+'); - $this->assertTrue(ftruncate($fp, 11)); - fclose($fp); - $this->assertEquals(7, - $this->root->getChild('file.txt')->size() - ); - $this->assertEquals("\0\0\0\0\0\0\0", - $this->root->getChild('file.txt')->getContent() - ); - } - - /** - * @test - * @group issue_33 - */ - public function canNotTruncateToGreaterLengthWhenDiscQuotaReached() - { - if (version_compare(PHP_VERSION, '5.4.0', '<')) { - $this->markTestSkipped('Requires PHP 5.4'); - } - - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - vfsStream::newFile('bar.txt') - ->withContent('1234567890') - ->at(vfsStream::newDirectory('bar') - ->at($this->root) - ); - $fp = fopen(vfsStream::url('root/file.txt'), 'w+'); - $this->assertFalse(ftruncate($fp, 11)); - fclose($fp); - $this->assertEquals(0, - $this->root->getChild('file.txt')->size() - ); - $this->assertEquals('', - $this->root->getChild('file.txt')->getContent() - ); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperSetOptionTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperSetOptionTestCase.php deleted file mode 100644 index aa86bd343..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperSetOptionTestCase.php +++ /dev/null @@ -1,76 +0,0 @@ -root = vfsStream::setup(); - vfsStream::newFile('foo.txt')->at($this->root); - } - - /** - * @test - */ - public function setBlockingDoesNotWork() - { - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertFalse(stream_set_blocking($fp, 1)); - fclose($fp); - } - - /** - * @test - */ - public function removeBlockingDoesNotWork() - { - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertFalse(stream_set_blocking($fp, 0)); - fclose($fp); - } - - /** - * @test - */ - public function setTimeoutDoesNotWork() - { - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertFalse(stream_set_timeout($fp, 1)); - fclose($fp); - } - - /** - * @test - */ - public function setWriteBufferDoesNotWork() - { - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $this->assertEquals(-1, stream_set_write_buffer($fp, 512)); - fclose($fp); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperStreamSelectTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperStreamSelectTestCase.php deleted file mode 100644 index c2aec9971..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperStreamSelectTestCase.php +++ /dev/null @@ -1,35 +0,0 @@ -at($root)->withContent('testContent'); - - $fp = fopen(vfsStream::url('root/foo.txt'), 'rb'); - $readarray = array($fp); - $writearray = array(); - $exceptarray = array(); - stream_select($readarray, $writearray, $exceptarray, 1); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php deleted file mode 100644 index 3dd4e517c..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php +++ /dev/null @@ -1,770 +0,0 @@ -assertSame($this->foo, vfsStreamWrapper::getRoot()); - vfsStreamWrapper::register(); - $this->assertNull(vfsStreamWrapper::getRoot()); - } - - /** - * @test - * @since 0.11.0 - */ - public function setRootReturnsRoot() - { - vfsStreamWrapper::register(); - $root = vfsStream::newDirectory('root'); - $this->assertSame($root, vfsStreamWrapper::setRoot($root)); - } - - /** - * assure that filesize is returned correct - * - * @test - */ - public function filesize() - { - $this->assertEquals(0, filesize($this->fooURL)); - $this->assertEquals(0, filesize($this->fooURL . '/.')); - $this->assertEquals(0, filesize($this->barURL)); - $this->assertEquals(0, filesize($this->barURL . '/.')); - $this->assertEquals(4, filesize($this->baz2URL)); - $this->assertEquals(5, filesize($this->baz1URL)); - } - - /** - * assert that file_exists() delivers correct result - * - * @test - */ - public function file_exists() - { - $this->assertTrue(file_exists($this->fooURL)); - $this->assertTrue(file_exists($this->fooURL . '/.')); - $this->assertTrue(file_exists($this->barURL)); - $this->assertTrue(file_exists($this->barURL . '/.')); - $this->assertTrue(file_exists($this->baz1URL)); - $this->assertTrue(file_exists($this->baz2URL)); - $this->assertFalse(file_exists($this->fooURL . '/another')); - $this->assertFalse(file_exists(vfsStream::url('another'))); - } - - /** - * assert that filemtime() delivers correct result - * - * @test - */ - public function filemtime() - { - $this->assertEquals(100, filemtime($this->fooURL)); - $this->assertEquals(100, filemtime($this->fooURL . '/.')); - $this->assertEquals(200, filemtime($this->barURL)); - $this->assertEquals(200, filemtime($this->barURL . '/.')); - $this->assertEquals(300, filemtime($this->baz1URL)); - $this->assertEquals(400, filemtime($this->baz2URL)); - } - - /** - * @test - * @group issue_23 - */ - public function unlinkRemovesFilesOnly() - { - $this->assertTrue(unlink($this->baz2URL)); - $this->assertFalse(file_exists($this->baz2URL)); // make sure statcache was cleared - $this->assertEquals(array($this->bar), $this->foo->getChildren()); - $this->assertFalse(@unlink($this->fooURL . '/another')); - $this->assertFalse(@unlink(vfsStream::url('another'))); - $this->assertEquals(array($this->bar), $this->foo->getChildren()); - } - - /** - * @test - * @group issue_49 - */ - public function unlinkReturnsFalseWhenFileDoesNotExist() - { - vfsStream::setup()->addChild(vfsStream::newFile('foo.blubb')); - $this->assertFalse(@unlink(vfsStream::url('foo.blubb2'))); - } - - /** - * @test - * @group issue_49 - */ - public function unlinkReturnsFalseWhenFileDoesNotExistAndFileWithSameNameExistsInRoot() - { - vfsStream::setup()->addChild(vfsStream::newFile('foo.blubb')); - $this->assertFalse(@unlink(vfsStream::url('foo.blubb'))); - } - - /** - * assert dirname() returns correct directory name - * - * @test - */ - public function dirname() - { - $this->assertEquals($this->fooURL, dirname($this->barURL)); - $this->assertEquals($this->barURL, dirname($this->baz1URL)); - # returns "vfs:" instead of "." - # however this seems not to be fixable because dirname() does not - # call the stream wrapper - #$this->assertEquals(dirname(vfsStream::url('doesNotExist')), '.'); - } - - /** - * assert basename() returns correct file name - * - * @test - */ - public function basename() - { - $this->assertEquals('bar', basename($this->barURL)); - $this->assertEquals('baz1', basename($this->baz1URL)); - $this->assertEquals('doesNotExist', basename(vfsStream::url('doesNotExist'))); - } - - /** - * assert is_readable() works correct - * - * @test - */ - public function is_readable() - { - $this->assertTrue(is_readable($this->fooURL)); - $this->assertTrue(is_readable($this->fooURL . '/.')); - $this->assertTrue(is_readable($this->barURL)); - $this->assertTrue(is_readable($this->barURL . '/.')); - $this->assertTrue(is_readable($this->baz1URL)); - $this->assertTrue(is_readable($this->baz2URL)); - $this->assertFalse(is_readable($this->fooURL . '/another')); - $this->assertFalse(is_readable(vfsStream::url('another'))); - - $this->foo->chmod(0222); - $this->assertFalse(is_readable($this->fooURL)); - - $this->baz1->chmod(0222); - $this->assertFalse(is_readable($this->baz1URL)); - } - - /** - * assert is_writable() works correct - * - * @test - */ - public function is_writable() - { - $this->assertTrue(is_writable($this->fooURL)); - $this->assertTrue(is_writable($this->fooURL . '/.')); - $this->assertTrue(is_writable($this->barURL)); - $this->assertTrue(is_writable($this->barURL . '/.')); - $this->assertTrue(is_writable($this->baz1URL)); - $this->assertTrue(is_writable($this->baz2URL)); - $this->assertFalse(is_writable($this->fooURL . '/another')); - $this->assertFalse(is_writable(vfsStream::url('another'))); - - $this->foo->chmod(0444); - $this->assertFalse(is_writable($this->fooURL)); - - $this->baz1->chmod(0444); - $this->assertFalse(is_writable($this->baz1URL)); - } - - /** - * assert is_executable() works correct - * - * @test - */ - public function is_executable() - { - $this->assertFalse(is_executable($this->baz1URL)); - $this->baz1->chmod(0766); - $this->assertTrue(is_executable($this->baz1URL)); - $this->assertFalse(is_executable($this->baz2URL)); - } - - /** - * assert is_executable() works correct - * - * @test - */ - public function directoriesAndNonExistingFilesAreNeverExecutable() - { - $this->assertFalse(is_executable($this->fooURL)); - $this->assertFalse(is_executable($this->fooURL . '/.')); - $this->assertFalse(is_executable($this->barURL)); - $this->assertFalse(is_executable($this->barURL . '/.')); - $this->assertFalse(is_executable($this->fooURL . '/another')); - $this->assertFalse(is_executable(vfsStream::url('another'))); - } - - /** - * file permissions - * - * @test - * @group permissions - */ - public function chmod() - { - $this->assertEquals(40777, decoct(fileperms($this->fooURL))); - $this->assertEquals(40777, decoct(fileperms($this->fooURL . '/.'))); - $this->assertEquals(40777, decoct(fileperms($this->barURL))); - $this->assertEquals(40777, decoct(fileperms($this->barURL . '/.'))); - $this->assertEquals(100666, decoct(fileperms($this->baz1URL))); - $this->assertEquals(100666, decoct(fileperms($this->baz2URL))); - - $this->foo->chmod(0755); - $this->bar->chmod(0700); - $this->baz1->chmod(0644); - $this->baz2->chmod(0600); - $this->assertEquals(40755, decoct(fileperms($this->fooURL))); - $this->assertEquals(40755, decoct(fileperms($this->fooURL . '/.'))); - $this->assertEquals(40700, decoct(fileperms($this->barURL))); - $this->assertEquals(40700, decoct(fileperms($this->barURL . '/.'))); - $this->assertEquals(100644, decoct(fileperms($this->baz1URL))); - $this->assertEquals(100600, decoct(fileperms($this->baz2URL))); - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function chmodModifiesPermissions() - { - if (version_compare(phpversion(), '5.4.0', '<')) { - $this->assertFalse(@chmod($this->fooURL, 0755)); - $this->assertFalse(@chmod($this->barURL, 0711)); - $this->assertFalse(@chmod($this->baz1URL, 0644)); - $this->assertFalse(@chmod($this->baz2URL, 0664)); - $this->assertEquals(40777, decoct(fileperms($this->fooURL))); - $this->assertEquals(40777, decoct(fileperms($this->barURL))); - $this->assertEquals(100666, decoct(fileperms($this->baz1URL))); - $this->assertEquals(100666, decoct(fileperms($this->baz2URL))); - } else { - $this->assertTrue(chmod($this->fooURL, 0755)); - $this->assertTrue(chmod($this->barURL, 0711)); - $this->assertTrue(chmod($this->baz1URL, 0644)); - $this->assertTrue(chmod($this->baz2URL, 0664)); - $this->assertEquals(40755, decoct(fileperms($this->fooURL))); - $this->assertEquals(40711, decoct(fileperms($this->barURL))); - $this->assertEquals(100644, decoct(fileperms($this->baz1URL))); - $this->assertEquals(100664, decoct(fileperms($this->baz2URL))); - } - } - - /** - * @test - * @group permissions - */ - public function fileownerIsCurrentUserByDefault() - { - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->fooURL)); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->fooURL . '/.')); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->barURL)); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->barURL . '/.')); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->baz1URL)); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->baz2URL)); - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function chownChangesUser() - { - if (version_compare(phpversion(), '5.4.0', '<')) { - $this->foo->chown(vfsStream::OWNER_USER_1); - $this->bar->chown(vfsStream::OWNER_USER_1); - $this->baz1->chown(vfsStream::OWNER_USER_2); - $this->baz2->chown(vfsStream::OWNER_USER_2); - } else { - chown($this->fooURL, vfsStream::OWNER_USER_1); - chown($this->barURL, vfsStream::OWNER_USER_1); - chown($this->baz1URL, vfsStream::OWNER_USER_2); - chown($this->baz2URL, vfsStream::OWNER_USER_2); - } - - $this->assertEquals(vfsStream::OWNER_USER_1, fileowner($this->fooURL)); - $this->assertEquals(vfsStream::OWNER_USER_1, fileowner($this->fooURL . '/.')); - $this->assertEquals(vfsStream::OWNER_USER_1, fileowner($this->barURL)); - $this->assertEquals(vfsStream::OWNER_USER_1, fileowner($this->barURL . '/.')); - $this->assertEquals(vfsStream::OWNER_USER_2, fileowner($this->baz1URL)); - $this->assertEquals(vfsStream::OWNER_USER_2, fileowner($this->baz2URL)); - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function chownDoesNotWorkOnVfsStreamUrls() - { - if (version_compare(phpversion(), '5.4.0', '<')) { - $this->assertFalse(@chown($this->fooURL, vfsStream::OWNER_USER_2)); - $this->assertEquals(vfsStream::getCurrentUser(), fileowner($this->fooURL)); - } - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function groupIsCurrentGroupByDefault() - { - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->fooURL)); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->fooURL . '/.')); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->barURL)); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->barURL . '/.')); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->baz1URL)); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->baz2URL)); - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function chgrp() - { - if (version_compare(phpversion(), '5.4.0', '<')) { - $this->foo->chgrp(vfsStream::GROUP_USER_1); - $this->bar->chgrp(vfsStream::GROUP_USER_1); - $this->baz1->chgrp(vfsStream::GROUP_USER_2); - $this->baz2->chgrp(vfsStream::GROUP_USER_2); - } else { - chgrp($this->fooURL, vfsStream::GROUP_USER_1); - chgrp($this->barURL, vfsStream::GROUP_USER_1); - chgrp($this->baz1URL, vfsStream::GROUP_USER_2); - chgrp($this->baz2URL, vfsStream::GROUP_USER_2); - } - - $this->assertEquals(vfsStream::GROUP_USER_1, filegroup($this->fooURL)); - $this->assertEquals(vfsStream::GROUP_USER_1, filegroup($this->fooURL . '/.')); - $this->assertEquals(vfsStream::GROUP_USER_1, filegroup($this->barURL)); - $this->assertEquals(vfsStream::GROUP_USER_1, filegroup($this->barURL . '/.')); - $this->assertEquals(vfsStream::GROUP_USER_2, filegroup($this->baz1URL)); - $this->assertEquals(vfsStream::GROUP_USER_2, filegroup($this->baz2URL)); - } - - /** - * @test - * @group issue_11 - * @group permissions - */ - public function chgrpDoesNotWorkOnVfsStreamUrls() - { - if (version_compare(phpversion(), '5.4.0', '<')) { - $this->assertFalse(@chgrp($this->fooURL, vfsStream::GROUP_USER_2)); - $this->assertEquals(vfsStream::getCurrentGroup(), filegroup($this->fooURL)); - } - } - - /** - * @test - * @author Benoit Aubuchon - */ - public function renameDirectory() - { - // move foo/bar to foo/baz3 - $baz3URL = vfsStream::url('foo/baz3'); - $this->assertTrue(rename($this->barURL, $baz3URL)); - $this->assertFileExists($baz3URL); - $this->assertFileNotExists($this->barURL); - } - - /** - * @test - */ - public function renameDirectoryWithDots() - { - // move foo/bar to foo/baz3 - $baz3URL = vfsStream::url('foo/baz3'); - $this->assertTrue(rename($this->barURL . '/.', $baz3URL)); - $this->assertFileExists($baz3URL); - $this->assertFileNotExists($this->barURL); - } - - /** - * @test - * @group issue_9 - * @since 0.9.0 - */ - public function renameDirectoryWithDotsInTarget() - { - // move foo/bar to foo/baz3 - $baz3URL = vfsStream::url('foo/../baz3/.'); - $this->assertTrue(rename($this->barURL . '/.', $baz3URL)); - $this->assertFileExists($baz3URL); - $this->assertFileNotExists($this->barURL); - } - - /** - * @test - * @author Benoit Aubuchon - */ - public function renameDirectoryOverwritingExistingFile() - { - // move foo/bar to foo/baz2 - $this->assertTrue(rename($this->barURL, $this->baz2URL)); - $this->assertFileExists(vfsStream::url('foo/baz2/baz1')); - $this->assertFileNotExists($this->barURL); - } - - /** - * @test - * @expectedException PHPUnit_Framework_Error - */ - public function renameFileIntoFile() - { - // foo/baz2 is a file, so it can not be turned into a directory - $baz3URL = vfsStream::url('foo/baz2/baz3'); - $this->assertTrue(rename($this->baz1URL, $baz3URL)); - $this->assertFileExists($baz3URL); - $this->assertFileNotExists($this->baz1URL); - } - - /** - * @test - * @author Benoit Aubuchon - */ - public function renameFileToDirectory() - { - // move foo/bar/baz1 to foo/baz3 - $baz3URL = vfsStream::url('foo/baz3'); - $this->assertTrue(rename($this->baz1URL, $baz3URL)); - $this->assertFileExists($this->barURL); - $this->assertFileExists($baz3URL); - $this->assertFileNotExists($this->baz1URL); - } - - /** - * assert that trying to rename from a non existing file trigger a warning - * - * @expectedException PHPUnit_Framework_Error - * @test - */ - public function renameOnSourceFileNotFound() - { - rename(vfsStream::url('notfound'), $this->baz1URL); - } - /** - * assert that trying to rename to a directory that is not found trigger a warning - - * @expectedException PHPUnit_Framework_Error - * @test - */ - public function renameOnDestinationDirectoryFileNotFound() - { - rename($this->baz1URL, vfsStream::url('foo/notfound/file2')); - } - /** - * stat() and fstat() should return the same result - * - * @test - */ - public function statAndFstatReturnSameResult() - { - $fp = fopen($this->baz2URL, 'r'); - $this->assertEquals(stat($this->baz2URL), - fstat($fp) - ); - fclose($fp); - } - - /** - * stat() returns full data - * - * @test - */ - public function statReturnsFullDataForFiles() - { - $this->assertEquals(array(0 => 0, - 1 => 0, - 2 => 0100666, - 3 => 0, - 4 => vfsStream::getCurrentUser(), - 5 => vfsStream::getCurrentGroup(), - 6 => 0, - 7 => 4, - 8 => 400, - 9 => 400, - 10 => 400, - 11 => -1, - 12 => -1, - 'dev' => 0, - 'ino' => 0, - 'mode' => 0100666, - 'nlink' => 0, - 'uid' => vfsStream::getCurrentUser(), - 'gid' => vfsStream::getCurrentGroup(), - 'rdev' => 0, - 'size' => 4, - 'atime' => 400, - 'mtime' => 400, - 'ctime' => 400, - 'blksize' => -1, - 'blocks' => -1 - ), - stat($this->baz2URL) - ); - } - - /** - * @test - */ - public function statReturnsFullDataForDirectories() - { - $this->assertEquals(array(0 => 0, - 1 => 0, - 2 => 0040777, - 3 => 0, - 4 => vfsStream::getCurrentUser(), - 5 => vfsStream::getCurrentGroup(), - 6 => 0, - 7 => 0, - 8 => 100, - 9 => 100, - 10 => 100, - 11 => -1, - 12 => -1, - 'dev' => 0, - 'ino' => 0, - 'mode' => 0040777, - 'nlink' => 0, - 'uid' => vfsStream::getCurrentUser(), - 'gid' => vfsStream::getCurrentGroup(), - 'rdev' => 0, - 'size' => 0, - 'atime' => 100, - 'mtime' => 100, - 'ctime' => 100, - 'blksize' => -1, - 'blocks' => -1 - ), - stat($this->fooURL) - ); - } - - /** - * @test - */ - public function statReturnsFullDataForDirectoriesWithDot() - { - $this->assertEquals(array(0 => 0, - 1 => 0, - 2 => 0040777, - 3 => 0, - 4 => vfsStream::getCurrentUser(), - 5 => vfsStream::getCurrentGroup(), - 6 => 0, - 7 => 0, - 8 => 100, - 9 => 100, - 10 => 100, - 11 => -1, - 12 => -1, - 'dev' => 0, - 'ino' => 0, - 'mode' => 0040777, - 'nlink' => 0, - 'uid' => vfsStream::getCurrentUser(), - 'gid' => vfsStream::getCurrentGroup(), - 'rdev' => 0, - 'size' => 0, - 'atime' => 100, - 'mtime' => 100, - 'ctime' => 100, - 'blksize' => -1, - 'blocks' => -1 - ), - stat($this->fooURL . '/.') - ); - } - - /** - * @test - * @expectedException PHPUnit_Framework_Error - */ - public function openFileWithoutDirectory() - { - vfsStreamWrapper::register(); - $this->assertFalse(file_get_contents(vfsStream::url('file.txt'))); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - * @requires PHP 5.4.0 - */ - public function truncateRemovesSuperflouosContent() - { - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - $handle = fopen($this->baz1URL, "r+"); - $this->assertTrue(ftruncate($handle, 0)); - $this->assertEquals(0, filesize($this->baz1URL)); - $this->assertEquals('', file_get_contents($this->baz1URL)); - fclose($handle); - } - - /** - * @test - * @group issue_33 - * @since 1.1.0 - * @requires PHP 5.4.0 - */ - public function truncateToGreaterSizeAddsZeroBytes() - { - if (strstr(PHP_VERSION, 'hiphop') !== false) { - $this->markTestSkipped('Not supported on hhvm'); - } - - $handle = fopen($this->baz1URL, "r+"); - $this->assertTrue(ftruncate($handle, 25)); - $this->assertEquals(25, filesize($this->baz1URL)); - $this->assertEquals("baz 1\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", - file_get_contents($this->baz1URL)); - fclose($handle); - } - - /** - * @test - * @group issue_11 - * @requires PHP 5.4.0 - */ - public function touchCreatesNonExistingFile() - { - $this->assertTrue(touch($this->fooURL . '/new.txt')); - $this->assertTrue($this->foo->hasChild('new.txt')); - } - - /** - * @test - * @group issue_11 - * @requires PHP 5.4.0 - */ - public function touchChangesAccessAndModificationTimeForFile() - { - $this->assertTrue(touch($this->baz1URL, 303, 313)); - $this->assertEquals(303, $this->baz1->filemtime()); - $this->assertEquals(313, $this->baz1->fileatime()); - } - - /** - * @test - * @group issue_11 - * @group issue_80 - * @requires PHP 5.4.0 - */ - public function touchChangesTimesToCurrentTimestampWhenNoTimesGiven() - { - $this->assertTrue(touch($this->baz1URL)); - $this->assertEquals(time(), $this->baz1->filemtime(), '', 1); - $this->assertEquals(time(), $this->baz1->fileatime(), '', 1); - } - - /** - * @test - * @group issue_11 - * @requires PHP 5.4.0 - */ - public function touchWithModifiedTimeChangesAccessAndModifiedTime() - { - $this->assertTrue(touch($this->baz1URL, 303)); - $this->assertEquals(303, $this->baz1->filemtime()); - $this->assertEquals(303, $this->baz1->fileatime()); - } - - /** - * @test - * @group issue_11 - * @requires PHP 5.4.0 - */ - public function touchChangesAccessAndModificationTimeForDirectory() - { - $this->assertTrue(touch($this->fooURL, 303, 313)); - $this->assertEquals(303, $this->foo->filemtime()); - $this->assertEquals(313, $this->foo->fileatime()); - } - - /** - * @test - * @group issue_34 - * @since 1.2.0 - */ - public function pathesAreCorrectlySet() - { - $this->assertEquals(vfsStream::path($this->fooURL), $this->foo->path()); - $this->assertEquals(vfsStream::path($this->barURL), $this->bar->path()); - $this->assertEquals(vfsStream::path($this->baz1URL), $this->baz1->path()); - $this->assertEquals(vfsStream::path($this->baz2URL), $this->baz2->path()); - } - - /** - * @test - * @group issue_34 - * @since 1.2.0 - */ - public function urlsAreCorrectlySet() - { - $this->assertEquals($this->fooURL, $this->foo->url()); - $this->assertEquals($this->barURL, $this->bar->url()); - $this->assertEquals($this->baz1URL, $this->baz1->url()); - $this->assertEquals($this->baz2URL, $this->baz2->url()); - } - - /** - * @test - * @group issue_34 - * @since 1.2.0 - */ - public function pathIsUpdatedAfterMove() - { - // move foo/bar/baz1 to foo/baz3 - $baz3URL = vfsStream::url('foo/baz3'); - $this->assertTrue(rename($this->baz1URL, $baz3URL)); - $this->assertEquals(vfsStream::path($baz3URL), $this->baz1->path()); - } - - /** - * @test - * @group issue_34 - * @since 1.2.0 - */ - public function urlIsUpdatedAfterMove() - { - // move foo/bar/baz1 to foo/baz3 - $baz3URL = vfsStream::url('foo/baz3'); - $this->assertTrue(rename($this->baz1URL, $baz3URL)); - $this->assertEquals($baz3URL, $this->baz1->url()); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperUnregisterTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperUnregisterTestCase.php deleted file mode 100644 index 2457304eb..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperUnregisterTestCase.php +++ /dev/null @@ -1,75 +0,0 @@ -assertNotContains(vfsStream::SCHEME, stream_get_wrappers()); - } - - /** - * Unregistering a third party wrapper for vfs:// fails. - * - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - * @runInSeparateProcess - */ - public function unregisterThirdPartyVfsScheme() - { - // Unregister possible registered URL wrapper. - vfsStreamWrapper::unregister(); - - $mock = $this->getMock('org\\bovigo\\vfs\\vfsStreamWrapper'); - stream_wrapper_register(vfsStream::SCHEME, get_class($mock)); - - vfsStreamWrapper::unregister(); - } - - /** - * Unregistering when not in registered state will fail. - * - * @test - * @expectedException org\bovigo\vfs\vfsStreamException - * @runInSeparateProcess - */ - public function unregisterWhenNotInRegisteredState() - { - vfsStreamWrapper::register(); - stream_wrapper_unregister(vfsStream::SCHEME); - vfsStreamWrapper::unregister(); - } - - /** - * Unregistering while not registers won't fail. - * - * @test - */ - public function unregisterWhenNotRegistered() - { - // Unregister possible registered URL wrapper. - vfsStreamWrapper::unregister(); - - $this->assertNotContains(vfsStream::SCHEME, stream_get_wrappers()); - vfsStreamWrapper::unregister(); - } -} diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperWithoutRootTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperWithoutRootTestCase.php deleted file mode 100644 index fab0c1311..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperWithoutRootTestCase.php +++ /dev/null @@ -1,64 +0,0 @@ - no directory to open - * - * @test - */ - public function canNotOpenDirectory() - { - $this->assertFalse(@dir(vfsStream::url('foo'))); - } - - /** - * can not unlink without root - * - * @test - */ - public function canNotUnlink() - { - $this->assertFalse(@unlink(vfsStream::url('foo'))); - } - - /** - * can not open a file without root - * - * @test - */ - public function canNotOpen() - { - $this->assertFalse(@fopen(vfsStream::url('foo'), 'r')); - } - - /** - * can not rename a file without root - * - * @test - */ - public function canNotRename() - { - $this->assertFalse(@rename(vfsStream::url('foo'), vfsStream::url('bar'))); - } -} -?> diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamZipTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamZipTestCase.php deleted file mode 100644 index 6aedcecd9..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamZipTestCase.php +++ /dev/null @@ -1,53 +0,0 @@ -markTestSkipped('No ext/zip installed, skipping test.'); - } - - $this->markTestSkipped('Zip extension can not work with vfsStream urls.'); - - vfsStreamWrapper::register(); - vfsStreamWrapper::setRoot(vfsStream::newDirectory('root')); - - } - - /** - * @test - */ - public function createZipArchive() - { - $zip = new ZipArchive(); - $this->assertTrue($zip->open(vfsStream::url('root/test.zip'), ZipArchive::CREATE)); - $this->assertTrue($zip->addFromString("testfile1.txt", "#1 This is a test string added as testfile1.txt.\n")); - $this->assertTrue($zip->addFromString("testfile2.txt", "#2 This is a test string added as testfile2.txt.\n")); - $zip->setArchiveComment('a test'); - var_dump($zip); - $this->assertTrue($zip->close()); - var_dump($zip->getStatusString()); - var_dump($zip->close()); - var_dump($zip->getStatusString()); - var_dump($zip); - var_dump(file_exists(vfsStream::url('root/test.zip'))); - } -} -?> \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamAbstractVisitorTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamAbstractVisitorTestCase.php deleted file mode 100644 index d7bb49e91..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamAbstractVisitorTestCase.php +++ /dev/null @@ -1,99 +0,0 @@ -abstractVisitor = $this->getMock('org\\bovigo\\vfs\\visitor\\vfsStreamAbstractVisitor', - array('visitFile', 'visitDirectory') - ); - } - - /** - * @test - * @expectedException \InvalidArgumentException - */ - public function visitThrowsInvalidArgumentExceptionOnUnknownContentType() - { - $mockContent = $this->getMock('org\\bovigo\\vfs\\vfsStreamContent'); - $mockContent->expects($this->any()) - ->method('getType') - ->will($this->returnValue('invalid')); - $this->assertSame($this->abstractVisitor, - $this->abstractVisitor->visit($mockContent) - ); - } - - /** - * @test - */ - public function visitWithFileCallsVisitFile() - { - $file = new vfsStreamFile('foo.txt'); - $this->abstractVisitor->expects($this->once()) - ->method('visitFile') - ->with($this->equalTo($file)); - $this->assertSame($this->abstractVisitor, - $this->abstractVisitor->visit($file) - ); - } - - /** - * tests that a block device eventually calls out to visit file - * - * @test - */ - public function visitWithBlockCallsVisitFile() - { - $block = new vfsStreamBlock('foo'); - $this->abstractVisitor->expects($this->once()) - ->method('visitFile') - ->with($this->equalTo($block)); - $this->assertSame($this->abstractVisitor, - $this->abstractVisitor->visit($block) - ); - } - - /** - * @test - */ - public function visitWithDirectoryCallsVisitDirectory() - { - $dir = new vfsStreamDirectory('bar'); - $this->abstractVisitor->expects($this->once()) - ->method('visitDirectory') - ->with($this->equalTo($dir)); - $this->assertSame($this->abstractVisitor, - $this->abstractVisitor->visit($dir) - ); - } -} -?> diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamPrintVisitorTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamPrintVisitorTestCase.php deleted file mode 100644 index 05a11ac22..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamPrintVisitorTestCase.php +++ /dev/null @@ -1,103 +0,0 @@ -at(vfsStream::setup()); - $printVisitor = new vfsStreamPrintVisitor(fopen('vfs://root/foo.txt', 'wb')); - $this->assertSame($printVisitor, - $printVisitor->visitFile(vfsStream::newFile('bar.txt')) - ); - $this->assertEquals("- bar.txt\n", $output->getContent()); - } - - /** - * @test - */ - public function visitFileWritesBlockDeviceToStream() - { - $output = vfsStream::newFile('foo.txt') - ->at(vfsStream::setup()); - $printVisitor = new vfsStreamPrintVisitor(fopen('vfs://root/foo.txt', 'wb')); - $this->assertSame($printVisitor, - $printVisitor->visitBlockDevice(vfsStream::newBlock('bar')) - ); - $this->assertEquals("- [bar]\n", $output->getContent()); - } - - /** - * @test - */ - public function visitDirectoryWritesDirectoryNameToStream() - { - $output = vfsStream::newFile('foo.txt') - ->at(vfsStream::setup()); - $printVisitor = new vfsStreamPrintVisitor(fopen('vfs://root/foo.txt', 'wb')); - $this->assertSame($printVisitor, - $printVisitor->visitDirectory(vfsStream::newDirectory('baz')) - ); - $this->assertEquals("- baz\n", $output->getContent()); - } - - /** - * @test - */ - public function visitRecursiveDirectoryStructure() - { - $root = vfsStream::setup('root', - null, - array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ), - 'foo.txt' => '' - ) - ); - $printVisitor = new vfsStreamPrintVisitor(fopen('vfs://root/foo.txt', 'wb')); - $this->assertSame($printVisitor, - $printVisitor->visitDirectory($root) - ); - $this->assertEquals("- root\n - test\n - foo\n - test.txt\n - baz.txt\n - foo.txt\n", file_get_contents('vfs://root/foo.txt')); - } -} -?> diff --git a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamStructureVisitorTestCase.php b/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamStructureVisitorTestCase.php deleted file mode 100644 index ad93a2c09..000000000 --- a/vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamStructureVisitorTestCase.php +++ /dev/null @@ -1,86 +0,0 @@ -assertEquals(array('foo.txt' => 'test'), - $structureVisitor->visitFile(vfsStream::newFile('foo.txt') - ->withContent('test') - ) - ->getStructure() - ); - } - - /** - * @test - */ - public function visitFileCreatesStructureForBlock() - { - $structureVisitor = new vfsStreamStructureVisitor(); - $this->assertEquals(array('[foo]' => 'test'), - $structureVisitor->visitBlockDevice(vfsStream::newBlock('foo') - ->withContent('test') - ) - ->getStructure() - ); - } - - /** - * @test - */ - public function visitDirectoryCreatesStructureForDirectory() - { - $structureVisitor = new vfsStreamStructureVisitor(); - $this->assertEquals(array('baz' => array()), - $structureVisitor->visitDirectory(vfsStream::newDirectory('baz')) - ->getStructure() - ); - } - - /** - * @test - */ - public function visitRecursiveDirectoryStructure() - { - $root = vfsStream::setup('root', - null, - array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ), - 'foo.txt' => '' - ) - ); - $structureVisitor = new vfsStreamStructureVisitor(); - $this->assertEquals(array('root' => array('test' => array('foo' => array('test.txt' => 'hello'), - 'baz.txt' => 'world' - ), - 'foo.txt' => '' - ), - ), - $structureVisitor->visitDirectory($root) - ->getStructure() - ); - } -} -?> diff --git a/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/aFile.txt b/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/aFile.txt deleted file mode 100644 index 191028156..000000000 --- a/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/aFile.txt +++ /dev/null @@ -1 +0,0 @@ -foo \ No newline at end of file diff --git a/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/subfolder1/file1.txt b/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/subfolder1/file1.txt deleted file mode 100644 index f6ea04951..000000000 --- a/vendor/mikey179/vfsStream/src/test/resources/filesystemcopy/withSubfolders/subfolder1/file1.txt +++ /dev/null @@ -1 +0,0 @@ -foobar \ No newline at end of file diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/DescriptionTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/DescriptionTest.php deleted file mode 100644 index a6ca7b37e..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/DescriptionTest.php +++ /dev/null @@ -1,245 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Description - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class DescriptionTest extends \PHPUnit_Framework_TestCase -{ - public function testConstruct() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(1, $parsedContents); - $this->assertSame($fixture, $parsedContents[0]); - } - - public function testInlineTagParsing() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - $this->assertSame('This is text for a ', $parsedContents[0]); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag\LinkTag', - $parsedContents[1] - ); - $this->assertSame( - ' that uses inline -tags.', - $parsedContents[2] - ); - } - - public function testInlineTagAtStartParsing() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - - $this->assertSame('', $parsedContents[0]); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag\LinkTag', - $parsedContents[1] - ); - $this->assertSame( - ' is text for a description that uses inline -tags.', - $parsedContents[2] - ); - } - - public function testNestedInlineTagParsing() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - - $this->assertSame( - 'This is text for a description with ', - $parsedContents[0] - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $parsedContents[1] - ); - $this->assertSame('.', $parsedContents[2]); - - $parsedDescription = $parsedContents[1]->getParsedDescription(); - $this->assertCount(3, $parsedDescription); - $this->assertSame("inline tag with\n", $parsedDescription[0]); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag\LinkTag', - $parsedDescription[1] - ); - $this->assertSame(' in it', $parsedDescription[2]); - } - - public function testLiteralOpeningDelimiter() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(1, $parsedContents); - $this->assertSame($fixture, $parsedContents[0]); - } - - public function testNestedLiteralOpeningDelimiter() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - $this->assertSame( - 'This is text for a description containing ', - $parsedContents[0] - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $parsedContents[1] - ); - $this->assertSame('.', $parsedContents[2]); - - $this->assertSame( - array('inline tag that has { that -is literal'), - $parsedContents[1]->getParsedDescription() - ); - } - - public function testLiteralClosingDelimiter() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(1, $parsedContents); - $this->assertSame( - 'This is text for a description with } that is not a tag.', - $parsedContents[0] - ); - } - - public function testNestedLiteralClosingDelimiter() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - $this->assertSame( - 'This is text for a description with ', - $parsedContents[0] - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $parsedContents[1] - ); - $this->assertSame('.', $parsedContents[2]); - - $this->assertSame( - array('inline tag with } that is not an -inline tag'), - $parsedContents[1]->getParsedDescription() - ); - } - - public function testInlineTagEscapingSequence() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(1, $parsedContents); - $this->assertSame( - 'This is text for a description with literal {@link}.', - $parsedContents[0] - ); - } - - public function testNestedInlineTagEscapingSequence() - { - $fixture = <<assertSame($fixture, $object->getContents()); - - $parsedContents = $object->getParsedContents(); - $this->assertCount(3, $parsedContents); - $this->assertSame( - 'This is text for a description with an ', - $parsedContents[0] - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $parsedContents[1] - ); - $this->assertSame('.', $parsedContents[2]); - - $this->assertSame( - array('inline tag with literal -{@link} in it'), - $parsedContents[1]->getParsedDescription() - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/CoversTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/CoversTagTest.php deleted file mode 100644 index ff257aa19..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/CoversTagTest.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\CoversTag - * - * @author Daniel O'Connor - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class CoversTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\CoversTag can create - * a link for the covers doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exReference - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\CoversTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exReference - ) { - $tag = new CoversTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exReference, $tag->getReference()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exReference - return array( - array( - 'covers', - 'Foo::bar()', - 'Foo::bar()', - '', - 'Foo::bar()' - ), - array( - 'covers', - 'Foo::bar() Testing', - 'Foo::bar() Testing', - 'Testing', - 'Foo::bar()', - ), - array( - 'covers', - 'Foo::bar() Testing comments', - 'Foo::bar() Testing comments', - 'Testing comments', - 'Foo::bar()', - ), - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/DeprecatedTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/DeprecatedTagTest.php deleted file mode 100644 index 7a75e79ce..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/DeprecatedTagTest.php +++ /dev/null @@ -1,115 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\DeprecatedTag - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class DeprecatedTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\LinkTag can create - * a link for the @deprecated doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exDescription - * @param string $exVersion - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\DeprecatedTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exVersion - ) { - $tag = new DeprecatedTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exVersion, $tag->getVersion()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exVersion - return array( - array( - 'deprecated', - '1.0 First release.', - '1.0 First release.', - 'First release.', - '1.0' - ), - array( - 'deprecated', - "1.0\nFirst release.", - "1.0\nFirst release.", - 'First release.', - '1.0' - ), - array( - 'deprecated', - "1.0\nFirst\nrelease.", - "1.0\nFirst\nrelease.", - "First\nrelease.", - '1.0' - ), - array( - 'deprecated', - 'Unfinished release', - 'Unfinished release', - 'Unfinished release', - '' - ), - array( - 'deprecated', - '1.0', - '1.0', - '', - '1.0' - ), - array( - 'deprecated', - 'GIT: $Id$', - 'GIT: $Id$', - '', - 'GIT: $Id$' - ), - array( - 'deprecated', - 'GIT: $Id$ Dev build', - 'GIT: $Id$ Dev build', - 'Dev build', - 'GIT: $Id$' - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ExampleTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ExampleTagTest.php deleted file mode 100644 index 519a61b3a..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ExampleTagTest.php +++ /dev/null @@ -1,203 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\ExampleTag - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class ExampleTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\SourceTag can - * understand the @source DocBlock. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exStartingLine - * @param string $exLineCount - * @param string $exFilepath - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\ExampleTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exStartingLine, - $exLineCount, - $exFilePath - ) { - $tag = new ExampleTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exStartingLine, $tag->getStartingLine()); - $this->assertEquals($exLineCount, $tag->getLineCount()); - $this->assertEquals($exFilePath, $tag->getFilePath()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, - // $content, - // $exContent, - // $exDescription, - // $exStartingLine, - // $exLineCount, - // $exFilePath - return array( - array( - 'example', - 'file.php', - 'file.php', - '', - 1, - null, - 'file.php' - ), - array( - 'example', - 'Testing comments', - 'Testing comments', - 'comments', - 1, - null, - 'Testing' - ), - array( - 'example', - 'file.php 2 Testing', - 'file.php 2 Testing', - 'Testing', - 2, - null, - 'file.php' - ), - array( - 'example', - 'file.php 2 3 Testing comments', - 'file.php 2 3 Testing comments', - 'Testing comments', - 2, - 3, - 'file.php' - ), - array( - 'example', - 'file.php 2 -1 Testing comments', - 'file.php 2 -1 Testing comments', - '-1 Testing comments', - 2, - null, - 'file.php' - ), - array( - 'example', - 'file.php -1 1 Testing comments', - 'file.php -1 1 Testing comments', - '-1 1 Testing comments', - 1, - null, - 'file.php' - ), - array( - 'example', - '"file with spaces.php" Testing comments', - '"file with spaces.php" Testing comments', - 'Testing comments', - 1, - null, - 'file with spaces.php' - ), - array( - 'example', - '"file with spaces.php" 2 Testing comments', - '"file with spaces.php" 2 Testing comments', - 'Testing comments', - 2, - null, - 'file with spaces.php' - ), - array( - 'example', - '"file with spaces.php" 2 3 Testing comments', - '"file with spaces.php" 2 3 Testing comments', - 'Testing comments', - 2, - 3, - 'file with spaces.php' - ), - array( - 'example', - '"file with spaces.php" 2 -3 Testing comments', - '"file with spaces.php" 2 -3 Testing comments', - '-3 Testing comments', - 2, - null, - 'file with spaces.php' - ), - array( - 'example', - '"file with spaces.php" -2 3 Testing comments', - '"file with spaces.php" -2 3 Testing comments', - '-2 3 Testing comments', - 1, - null, - 'file with spaces.php' - ), - array( - 'example', - 'file%20with%20spaces.php Testing comments', - 'file%20with%20spaces.php Testing comments', - 'Testing comments', - 1, - null, - 'file with spaces.php' - ), - array( - 'example', - 'folder/file%20with%20spaces.php Testing comments', - 'folder/file%20with%20spaces.php Testing comments', - 'Testing comments', - 1, - null, - 'folder/file with spaces.php' - ), - array( - 'example', - 'http://example.com/file%20with%20spaces.php Testing comments', - 'http://example.com/file%20with%20spaces.php Testing comments', - 'Testing comments', - 1, - null, - 'http://example.com/file%20with%20spaces.php' - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/LinkTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/LinkTagTest.php deleted file mode 100644 index 0c64ed086..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/LinkTagTest.php +++ /dev/null @@ -1,87 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\LinkTag - * - * @author Ben Selby - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class LinkTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\LinkTag can create - * a link for the @link doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exDescription - * @param string $exLink - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\LinkTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exLink - ) { - $tag = new LinkTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exLink, $tag->getLink()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exLink - return array( - array( - 'link', - 'http://www.phpdoc.org/', - 'http://www.phpdoc.org/', - 'http://www.phpdoc.org/', - 'http://www.phpdoc.org/' - ), - array( - 'link', - 'http://www.phpdoc.org/ Testing', - 'http://www.phpdoc.org/ Testing', - 'Testing', - 'http://www.phpdoc.org/' - ), - array( - 'link', - 'http://www.phpdoc.org/ Testing comments', - 'http://www.phpdoc.org/ Testing comments', - 'Testing comments', - 'http://www.phpdoc.org/' - ), - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/MethodTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/MethodTagTest.php deleted file mode 100644 index efc3a15b5..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/MethodTagTest.php +++ /dev/null @@ -1,146 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\MethodTag - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class MethodTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * @param string $signature The signature to test. - * @param bool $valid Whether the given signature is expected to - * be valid. - * @param string $expected_name The method name that is expected from this - * signature. - * @param string $expected_return The return type that is expected from this - * signature. - * @param bool $paramCount Number of parameters in the signature. - * @param string $description The short description mentioned in the - * signature. - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\MethodTag - * @dataProvider getTestSignatures - * - * @return void - */ - public function testConstruct( - $signature, - $valid, - $expected_name, - $expected_return, - $expected_isStatic, - $paramCount, - $description - ) { - ob_start(); - $tag = new MethodTag('method', $signature); - $stdout = ob_get_clean(); - - $this->assertSame( - $valid, - empty($stdout), - 'No error should have been output if the signature is valid' - ); - - if (!$valid) { - return; - } - - $this->assertEquals($expected_name, $tag->getMethodName()); - $this->assertEquals($expected_return, $tag->getType()); - $this->assertEquals($description, $tag->getDescription()); - $this->assertEquals($expected_isStatic, $tag->isStatic()); - $this->assertCount($paramCount, $tag->getArguments()); - } - - public function getTestSignatures() - { - return array( - // TODO: Verify this case -// array( -// 'foo', -// false, 'foo', '', false, 0, '' -// ), - array( - 'foo()', - true, 'foo', 'void', false, 0, '' - ), - array( - 'foo() description', - true, 'foo', 'void', false, 0, 'description' - ), - array( - 'int foo()', - true, 'foo', 'int', false, 0, '' - ), - array( - 'int foo() description', - true, 'foo', 'int', false, 0, 'description' - ), - array( - 'int foo($a, $b)', - true, 'foo', 'int', false, 2, '' - ), - array( - 'int foo() foo(int $a, int $b)', - true, 'foo', 'int', false, 2, '' - ), - array( - 'int foo(int $a, int $b)', - true, 'foo', 'int', false, 2, '' - ), - array( - 'null|int foo(int $a, int $b)', - true, 'foo', 'null|int', false, 2, '' - ), - array( - 'int foo(null|int $a, int $b)', - true, 'foo', 'int', false, 2, '' - ), - array( - '\Exception foo() foo(Exception $a, Exception $b)', - true, 'foo', '\Exception', false, 2, '' - ), - array( - 'int foo() foo(Exception $a, Exception $b) description', - true, 'foo', 'int', false, 2, 'description' - ), - array( - 'int foo() foo(\Exception $a, \Exception $b) description', - true, 'foo', 'int', false, 2, 'description' - ), - array( - 'void()', - true, 'void', 'void', false, 0, '' - ), - array( - 'static foo()', - true, 'foo', 'static', false, 0, '' - ), - array( - 'static void foo()', - true, 'foo', 'void', true, 0, '' - ), - array( - 'static static foo()', - true, 'foo', 'static', true, 0, '' - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ParamTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ParamTagTest.php deleted file mode 100644 index 0e05382fa..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ParamTagTest.php +++ /dev/null @@ -1,118 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\ParamTag - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class ParamTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\ParamTag can - * understand the @param DocBlock. - * - * @param string $type - * @param string $content - * @param string $extractedType - * @param string $extractedTypes - * @param string $extractedVarName - * @param string $extractedDescription - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\ParamTag - * @dataProvider provideDataForConstructor - * - * @return void - */ - public function testConstructorParsesInputsIntoCorrectFields( - $type, - $content, - $extractedType, - $extractedTypes, - $extractedVarName, - $extractedDescription - ) { - $tag = new ParamTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($extractedType, $tag->getType()); - $this->assertEquals($extractedTypes, $tag->getTypes()); - $this->assertEquals($extractedVarName, $tag->getVariableName()); - $this->assertEquals($extractedDescription, $tag->getDescription()); - } - - /** - * Data provider for testConstructorParsesInputsIntoCorrectFields() - * - * @return array - */ - public function provideDataForConstructor() - { - return array( - array('param', 'int', 'int', array('int'), '', ''), - array('param', '$bob', '', array(), '$bob', ''), - array( - 'param', - 'int Number of bobs', - 'int', - array('int'), - '', - 'Number of bobs' - ), - array( - 'param', - 'int $bob', - 'int', - array('int'), - '$bob', - '' - ), - array( - 'param', - 'int $bob Number of bobs', - 'int', - array('int'), - '$bob', - 'Number of bobs' - ), - array( - 'param', - "int Description \n on multiple lines", - 'int', - array('int'), - '', - "Description \n on multiple lines" - ), - array( - 'param', - "int \n\$bob Variable name on a new line", - 'int', - array('int'), - '$bob', - "Variable name on a new line" - ), - array( - 'param', - "\nint \$bob Type on a new line", - 'int', - array('int'), - '$bob', - "Type on a new line" - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ReturnTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ReturnTagTest.php deleted file mode 100644 index 9e2aec0d1..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ReturnTagTest.php +++ /dev/null @@ -1,102 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\ReturnTag - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class ReturnTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\ReturnTag can - * understand the @return DocBlock. - * - * @param string $type - * @param string $content - * @param string $extractedType - * @param string $extractedTypes - * @param string $extractedDescription - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\ReturnTag - * @dataProvider provideDataForConstructor - * - * @return void - */ - public function testConstructorParsesInputsIntoCorrectFields( - $type, - $content, - $extractedType, - $extractedTypes, - $extractedDescription - ) { - $tag = new ReturnTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($extractedType, $tag->getType()); - $this->assertEquals($extractedTypes, $tag->getTypes()); - $this->assertEquals($extractedDescription, $tag->getDescription()); - } - - /** - * Data provider for testConstructorParsesInputsIntoCorrectFields() - * - * @return array - */ - public function provideDataForConstructor() - { - return array( - array('return', '', '', array(), ''), - array('return', 'int', 'int', array('int'), ''), - array( - 'return', - 'int Number of Bobs', - 'int', - array('int'), - 'Number of Bobs' - ), - array( - 'return', - 'int|double Number of Bobs', - 'int|double', - array('int', 'double'), - 'Number of Bobs' - ), - array( - 'return', - "int Number of \n Bobs", - 'int', - array('int'), - "Number of \n Bobs" - ), - array( - 'return', - " int Number of Bobs", - 'int', - array('int'), - "Number of Bobs" - ), - array( - 'return', - "int\nNumber of Bobs", - 'int', - array('int'), - "Number of Bobs" - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SeeTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SeeTagTest.php deleted file mode 100644 index 6829b0460..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SeeTagTest.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\SeeTag - * - * @author Daniel O'Connor - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class SeeTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the phpDocumentor_Reflection_DocBlock_Tag_See can create a link - * for the @see doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exReference - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\SeeTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exReference - ) { - $tag = new SeeTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exReference, $tag->getReference()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exReference - return array( - array( - 'see', - 'Foo::bar()', - 'Foo::bar()', - '', - 'Foo::bar()' - ), - array( - 'see', - 'Foo::bar() Testing', - 'Foo::bar() Testing', - 'Testing', - 'Foo::bar()', - ), - array( - 'see', - 'Foo::bar() Testing comments', - 'Foo::bar() Testing comments', - 'Testing comments', - 'Foo::bar()', - ), - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SinceTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SinceTagTest.php deleted file mode 100644 index 8caf25d1c..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SinceTagTest.php +++ /dev/null @@ -1,115 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\SinceTag - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class SinceTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\LinkTag can create - * a link for the @since doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exDescription - * @param string $exVersion - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\SinceTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exVersion - ) { - $tag = new SinceTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exVersion, $tag->getVersion()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exVersion - return array( - array( - 'since', - '1.0 First release.', - '1.0 First release.', - 'First release.', - '1.0' - ), - array( - 'since', - "1.0\nFirst release.", - "1.0\nFirst release.", - 'First release.', - '1.0' - ), - array( - 'since', - "1.0\nFirst\nrelease.", - "1.0\nFirst\nrelease.", - "First\nrelease.", - '1.0' - ), - array( - 'since', - 'Unfinished release', - 'Unfinished release', - 'Unfinished release', - '' - ), - array( - 'since', - '1.0', - '1.0', - '', - '1.0' - ), - array( - 'since', - 'GIT: $Id$', - 'GIT: $Id$', - '', - 'GIT: $Id$' - ), - array( - 'since', - 'GIT: $Id$ Dev build', - 'GIT: $Id$ Dev build', - 'Dev build', - 'GIT: $Id$' - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SourceTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SourceTagTest.php deleted file mode 100644 index 2a40e0aa3..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/SourceTagTest.php +++ /dev/null @@ -1,116 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\SourceTag - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class SourceTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\SourceTag can - * understand the @source DocBlock. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exStartingLine - * @param string $exLineCount - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\SourceTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exStartingLine, - $exLineCount - ) { - $tag = new SourceTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exStartingLine, $tag->getStartingLine()); - $this->assertEquals($exLineCount, $tag->getLineCount()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exStartingLine, $exLineCount - return array( - array( - 'source', - '2', - '2', - '', - 2, - null - ), - array( - 'source', - 'Testing', - 'Testing', - 'Testing', - 1, - null - ), - array( - 'source', - '2 Testing', - '2 Testing', - 'Testing', - 2, - null - ), - array( - 'source', - '2 3 Testing comments', - '2 3 Testing comments', - 'Testing comments', - 2, - 3 - ), - array( - 'source', - '2 -1 Testing comments', - '2 -1 Testing comments', - '-1 Testing comments', - 2, - null - ), - array( - 'source', - '-1 1 Testing comments', - '-1 1 Testing comments', - '-1 1 Testing comments', - 1, - null - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ThrowsTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ThrowsTagTest.php deleted file mode 100644 index 3c669d558..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/ThrowsTagTest.php +++ /dev/null @@ -1,102 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\ThrowsTag - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class ThrowsTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\ThrowsTag can - * understand the @throws DocBlock. - * - * @param string $type - * @param string $content - * @param string $extractedType - * @param string $extractedTypes - * @param string $extractedDescription - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\ThrowsTag - * @dataProvider provideDataForConstructor - * - * @return void - */ - public function testConstructorParsesInputsIntoCorrectFields( - $type, - $content, - $extractedType, - $extractedTypes, - $extractedDescription - ) { - $tag = new ThrowsTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($extractedType, $tag->getType()); - $this->assertEquals($extractedTypes, $tag->getTypes()); - $this->assertEquals($extractedDescription, $tag->getDescription()); - } - - /** - * Data provider for testConstructorParsesInputsIntoCorrectFields() - * - * @return array - */ - public function provideDataForConstructor() - { - return array( - array('throws', '', '', array(), ''), - array('throws', 'int', 'int', array('int'), ''), - array( - 'throws', - 'int Number of Bobs', - 'int', - array('int'), - 'Number of Bobs' - ), - array( - 'throws', - 'int|double Number of Bobs', - 'int|double', - array('int', 'double'), - 'Number of Bobs' - ), - array( - 'throws', - "int Number of \n Bobs", - 'int', - array('int'), - "Number of \n Bobs" - ), - array( - 'throws', - " int Number of Bobs", - 'int', - array('int'), - "Number of Bobs" - ), - array( - 'throws', - "int\nNumber of Bobs", - 'int', - array('int'), - "Number of Bobs" - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/UsesTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/UsesTagTest.php deleted file mode 100644 index 45868d73e..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/UsesTagTest.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\UsesTag - * - * @author Daniel O'Connor - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class UsesTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\UsesTag can create - * a link for the @uses doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exReference - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\UsesTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exReference - ) { - $tag = new UsesTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exReference, $tag->getReference()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exReference - return array( - array( - 'uses', - 'Foo::bar()', - 'Foo::bar()', - '', - 'Foo::bar()' - ), - array( - 'uses', - 'Foo::bar() Testing', - 'Foo::bar() Testing', - 'Testing', - 'Foo::bar()', - ), - array( - 'uses', - 'Foo::bar() Testing comments', - 'Foo::bar() Testing comments', - 'Testing comments', - 'Foo::bar()', - ), - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VarTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VarTagTest.php deleted file mode 100644 index 9ae2aa5f7..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VarTagTest.php +++ /dev/null @@ -1,94 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\VarTag - * - * @author Daniel O'Connor - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class VarTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\VarTag can - * understand the @var doc block. - * - * @param string $type - * @param string $content - * @param string $exType - * @param string $exVariable - * @param string $exDescription - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\VarTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exType, - $exVariable, - $exDescription - ) { - $tag = new VarTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exType, $tag->getType()); - $this->assertEquals($exVariable, $tag->getVariableName()); - $this->assertEquals($exDescription, $tag->getDescription()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exType, $exVariable, $exDescription - return array( - array( - 'var', - 'int', - 'int', - '', - '' - ), - array( - 'var', - 'int $bob', - 'int', - '$bob', - '' - ), - array( - 'var', - 'int $bob Number of bobs', - 'int', - '$bob', - 'Number of bobs' - ), - array( - 'var', - '', - '', - '', - '' - ), - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VersionTagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VersionTagTest.php deleted file mode 100644 index e145386d4..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Tag/VersionTagTest.php +++ /dev/null @@ -1,115 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Tag; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\VersionTag - * - * @author Vasil Rangelov - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class VersionTagTest extends \PHPUnit_Framework_TestCase -{ - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\LinkTag can create - * a link for the @version doc block. - * - * @param string $type - * @param string $content - * @param string $exContent - * @param string $exDescription - * @param string $exVersion - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag\VersionTag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exContent, - $exDescription, - $exVersion - ) { - $tag = new VersionTag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($exContent, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - $this->assertEquals($exVersion, $tag->getVersion()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exContent, $exDescription, $exVersion - return array( - array( - 'version', - '1.0 First release.', - '1.0 First release.', - 'First release.', - '1.0' - ), - array( - 'version', - "1.0\nFirst release.", - "1.0\nFirst release.", - 'First release.', - '1.0' - ), - array( - 'version', - "1.0\nFirst\nrelease.", - "1.0\nFirst\nrelease.", - "First\nrelease.", - '1.0' - ), - array( - 'version', - 'Unfinished release', - 'Unfinished release', - 'Unfinished release', - '' - ), - array( - 'version', - '1.0', - '1.0', - '', - '1.0' - ), - array( - 'version', - 'GIT: $Id$', - 'GIT: $Id$', - '', - 'GIT: $Id$' - ), - array( - 'version', - 'GIT: $Id$ Dev build', - 'GIT: $Id$ Dev build', - 'Dev build', - 'GIT: $Id$' - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/TagTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/TagTest.php deleted file mode 100644 index 9e873ecb5..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/TagTest.php +++ /dev/null @@ -1,313 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock; - -use phpDocumentor\Reflection\DocBlock; -use phpDocumentor\Reflection\DocBlock\Context; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Tag\VarTag - * - * @author Daniel O'Connor - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class TagTest extends \PHPUnit_Framework_TestCase -{ - - /** - * @expectedException \InvalidArgumentException - * - * @return void - */ - public function testInvalidTagLine() - { - Tag::createInstance('Invalid tag line'); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * - * @return void - */ - public function testTagHandlerUnregistration() - { - $currentHandler = __NAMESPACE__ . '\Tag\VarTag'; - $tagPreUnreg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPreUnreg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreUnreg - ); - - Tag::registerTagHandler('var', null); - - $tagPostUnreg = Tag::createInstance('@var mixed'); - $this->assertNotInstanceOf( - $currentHandler, - $tagPostUnreg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostUnreg - ); - - Tag::registerTagHandler('var', $currentHandler); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * - * @return void - */ - public function testTagHandlerCorrectRegistration() - { - if (0 == ini_get('allow_url_include')) { - $this->markTestSkipped('"data" URIs for includes are required.'); - } - $currentHandler = __NAMESPACE__ . '\Tag\VarTag'; - $tagPreReg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPreReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreReg - ); - - include 'data:text/plain;base64,'. base64_encode( -<<assertTrue(Tag::registerTagHandler('var', '\MyTagHandler')); - - $tagPostReg = Tag::createInstance('@var mixed'); - $this->assertNotInstanceOf( - $currentHandler, - $tagPostReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostReg - ); - $this->assertInstanceOf( - '\MyTagHandler', - $tagPostReg - ); - - $this->assertTrue(Tag::registerTagHandler('var', $currentHandler)); - } - - /** - * @depends testTagHandlerCorrectRegistration - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * @covers \phpDocumentor\Reflection\DocBlock\Tag::createInstance - * - * @return void - */ - public function testNamespacedTagHandlerCorrectRegistration() - { - $tagPreReg = Tag::createInstance('@T something'); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreReg - ); - $this->assertNotInstanceOf( - '\MyTagHandler', - $tagPreReg - ); - - $this->assertTrue( - Tag::registerTagHandler('\MyNamespace\MyTag', '\MyTagHandler') - ); - - $tagPostReg = Tag::createInstance( - '@T something', - new DocBlock( - '', - new Context('', array('T' => '\MyNamespace\MyTag')) - ) - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostReg - ); - $this->assertInstanceOf( - '\MyTagHandler', - $tagPostReg - ); - - $this->assertTrue( - Tag::registerTagHandler('\MyNamespace\MyTag', null) - ); - } - - /** - * @depends testTagHandlerCorrectRegistration - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * @covers \phpDocumentor\Reflection\DocBlock\Tag::createInstance - * - * @return void - */ - public function testNamespacedTagHandlerIncorrectRegistration() - { - $tagPreReg = Tag::createInstance('@T something'); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreReg - ); - $this->assertNotInstanceOf( - '\MyTagHandler', - $tagPreReg - ); - - $this->assertFalse( - Tag::registerTagHandler('MyNamespace\MyTag', '\MyTagHandler') - ); - - $tagPostReg = Tag::createInstance( - '@T something', - new DocBlock( - '', - new Context('', array('T' => '\MyNamespace\MyTag')) - ) - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostReg - ); - $this->assertNotInstanceOf( - '\MyTagHandler', - $tagPostReg - ); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * - * @return void - */ - public function testNonExistentTagHandlerRegistration() - { - $currentHandler = __NAMESPACE__ . '\Tag\VarTag'; - $tagPreReg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPreReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreReg - ); - - $this->assertFalse(Tag::registerTagHandler('var', 'Non existent')); - - $tagPostReg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPostReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostReg - ); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock\Tag::registerTagHandler - * - * @return void - */ - public function testIncompatibleTagHandlerRegistration() - { - $currentHandler = __NAMESPACE__ . '\Tag\VarTag'; - $tagPreReg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPreReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPreReg - ); - - $this->assertFalse( - Tag::registerTagHandler('var', __NAMESPACE__ . '\TagTest') - ); - - $tagPostReg = Tag::createInstance('@var mixed'); - $this->assertInstanceOf( - $currentHandler, - $tagPostReg - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\Tag', - $tagPostReg - ); - } - - /** - * Test that the \phpDocumentor\Reflection\DocBlock\Tag\VarTag can - * understand the @var doc block. - * - * @param string $type - * @param string $content - * @param string $exDescription - * - * @covers \phpDocumentor\Reflection\DocBlock\Tag - * @dataProvider provideDataForConstuctor - * - * @return void - */ - public function testConstructorParesInputsIntoCorrectFields( - $type, - $content, - $exDescription - ) { - $tag = new Tag($type, $content); - - $this->assertEquals($type, $tag->getName()); - $this->assertEquals($content, $tag->getContent()); - $this->assertEquals($exDescription, $tag->getDescription()); - } - - /** - * Data provider for testConstructorParesInputsIntoCorrectFields - * - * @return array - */ - public function provideDataForConstuctor() - { - // $type, $content, $exDescription - return array( - array( - 'unknown', - 'some content', - 'some content', - ), - array( - 'unknown', - '', - '', - ) - ); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Type/CollectionTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Type/CollectionTest.php deleted file mode 100644 index 78c7306d6..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/Type/CollectionTest.php +++ /dev/null @@ -1,195 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection\DocBlock\Type; - -use phpDocumentor\Reflection\DocBlock\Context; - -/** - * Test class for \phpDocumentor\Reflection\DocBlock\Type\Collection - * - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class CollectionTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::__construct - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::getContext - * - * @return void - */ - public function testConstruct() - { - $collection = new Collection(); - $this->assertCount(0, $collection); - $this->assertEquals('', $collection->getContext()->getNamespace()); - $this->assertCount(0, $collection->getContext()->getNamespaceAliases()); - } - - /** - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::__construct - * - * @return void - */ - public function testConstructWithTypes() - { - $collection = new Collection(array('integer', 'string')); - $this->assertCount(2, $collection); - } - - /** - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::__construct - * - * @return void - */ - public function testConstructWithNamespace() - { - $collection = new Collection(array(), new Context('\My\Space')); - $this->assertEquals('My\Space', $collection->getContext()->getNamespace()); - - $collection = new Collection(array(), new Context('My\Space')); - $this->assertEquals('My\Space', $collection->getContext()->getNamespace()); - - $collection = new Collection(array(), null); - $this->assertEquals('', $collection->getContext()->getNamespace()); - } - - /** - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::__construct - * - * @return void - */ - public function testConstructWithNamespaceAliases() - { - $fixture = array('a' => 'b'); - $collection = new Collection(array(), new Context(null, $fixture)); - $this->assertEquals( - array('a' => '\b'), - $collection->getContext()->getNamespaceAliases() - ); - } - - /** - * @param string $fixture - * @param array $expected - * - * @dataProvider provideTypesToExpand - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::add - * - * @return void - */ - public function testAdd($fixture, $expected) - { - $collection = new Collection( - array(), - new Context('\My\Space', array('Alias' => '\My\Space\Aliasing')) - ); - $collection->add($fixture); - - $this->assertSame($expected, $collection->getArrayCopy()); - } - - /** - * @param string $fixture - * @param array $expected - * - * @dataProvider provideTypesToExpandWithoutNamespace - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::add - * - * @return void - */ - public function testAddWithoutNamespace($fixture, $expected) - { - $collection = new Collection( - array(), - new Context(null, array('Alias' => '\My\Space\Aliasing')) - ); - $collection->add($fixture); - - $this->assertSame($expected, $collection->getArrayCopy()); - } - - /** - * @covers phpDocumentor\Reflection\DocBlock\Type\Collection::add - * @expectedException InvalidArgumentException - * - * @return void - */ - public function testAddWithInvalidArgument() - { - $collection = new Collection(); - $collection->add(array()); - } - - /** - * Returns the types and their expected values to test the retrieval of - * types. - * - * @param string $method Name of the method consuming this data provider. - * @param string $namespace Name of the namespace to user as basis. - * - * @return string[] - */ - public function provideTypesToExpand($method, $namespace = '\My\Space\\') - { - return array( - array('', array()), - array(' ', array()), - array('int', array('int')), - array('int ', array('int')), - array('string', array('string')), - array('DocBlock', array($namespace.'DocBlock')), - array('DocBlock[]', array($namespace.'DocBlock[]')), - array(' DocBlock ', array($namespace.'DocBlock')), - array('\My\Space\DocBlock', array('\My\Space\DocBlock')), - array('Alias\DocBlock', array('\My\Space\Aliasing\DocBlock')), - array( - 'DocBlock|Tag', - array($namespace .'DocBlock', $namespace .'Tag') - ), - array( - 'DocBlock|null', - array($namespace.'DocBlock', 'null') - ), - array( - '\My\Space\DocBlock|Tag', - array('\My\Space\DocBlock', $namespace.'Tag') - ), - array( - 'DocBlock[]|null', - array($namespace.'DocBlock[]', 'null') - ), - array( - 'DocBlock[]|int[]', - array($namespace.'DocBlock[]', 'int[]') - ), - ); - } - - /** - * Returns the types and their expected values to test the retrieval of - * types when no namespace is available. - * - * @param string $method Name of the method consuming this data provider. - * - * @return string[] - */ - public function provideTypesToExpandWithoutNamespace($method) - { - return $this->provideTypesToExpand($method, '\\'); - } -} diff --git a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlockTest.php b/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlockTest.php deleted file mode 100644 index 30eedfc58..000000000 --- a/vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlockTest.php +++ /dev/null @@ -1,337 +0,0 @@ - - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ - -namespace phpDocumentor\Reflection; - -use phpDocumentor\Reflection\DocBlock\Context; -use phpDocumentor\Reflection\DocBlock\Location; -use phpDocumentor\Reflection\DocBlock\Tag\ReturnTag; - -/** - * Test class for phpDocumentor\Reflection\DocBlock - * - * @author Mike van Riel - * @copyright 2010-2011 Mike van Riel / Naenius. (http://www.naenius.com) - * @license http://www.opensource.org/licenses/mit-license.php MIT - * @link http://phpdoc.org - */ -class DocBlockTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers \phpDocumentor\Reflection\DocBlock - * - * @return void - */ - public function testConstruct() - { - $fixture = << '\phpDocumentor')), - new Location(2) - ); - $this->assertEquals( - 'This is a short description', - $object->getShortDescription() - ); - $this->assertEquals( - 'This is a long description', - $object->getLongDescription()->getContents() - ); - $this->assertCount(2, $object->getTags()); - $this->assertTrue($object->hasTag('see')); - $this->assertTrue($object->hasTag('return')); - $this->assertFalse($object->hasTag('category')); - - $this->assertSame('MyNamespace', $object->getContext()->getNamespace()); - $this->assertSame( - array('PHPDoc' => '\phpDocumentor'), - $object->getContext()->getNamespaceAliases() - ); - $this->assertSame(2, $object->getLocation()->getLineNumber()); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::splitDocBlock - * - * @return void - */ - public function testConstructWithTagsOnly() - { - $fixture = <<assertEquals('', $object->getShortDescription()); - $this->assertEquals('', $object->getLongDescription()->getContents()); - $this->assertCount(2, $object->getTags()); - $this->assertTrue($object->hasTag('see')); - $this->assertTrue($object->hasTag('return')); - $this->assertFalse($object->hasTag('category')); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::isTemplateStart - */ - public function testIfStartOfTemplateIsDiscovered() - { - $fixture = <<assertEquals('', $object->getShortDescription()); - $this->assertEquals('', $object->getLongDescription()->getContents()); - $this->assertCount(2, $object->getTags()); - $this->assertTrue($object->hasTag('see')); - $this->assertTrue($object->hasTag('return')); - $this->assertFalse($object->hasTag('category')); - $this->assertTrue($object->isTemplateStart()); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::isTemplateEnd - */ - public function testIfEndOfTemplateIsDiscovered() - { - $fixture = <<assertEquals('', $object->getShortDescription()); - $this->assertEquals('', $object->getLongDescription()->getContents()); - $this->assertTrue($object->isTemplateEnd()); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::cleanInput - * - * @return void - */ - public function testConstructOneLiner() - { - $fixture = '/** Short description and nothing more. */'; - $object = new DocBlock($fixture); - $this->assertEquals( - 'Short description and nothing more.', - $object->getShortDescription() - ); - $this->assertEquals('', $object->getLongDescription()->getContents()); - $this->assertCount(0, $object->getTags()); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::__construct - * - * @return void - */ - public function testConstructFromReflector() - { - $object = new DocBlock(new \ReflectionClass($this)); - $this->assertEquals( - 'Test class for phpDocumentor\Reflection\DocBlock', - $object->getShortDescription() - ); - $this->assertEquals('', $object->getLongDescription()->getContents()); - $this->assertCount(4, $object->getTags()); - $this->assertTrue($object->hasTag('author')); - $this->assertTrue($object->hasTag('copyright')); - $this->assertTrue($object->hasTag('license')); - $this->assertTrue($object->hasTag('link')); - $this->assertFalse($object->hasTag('category')); - } - - /** - * @expectedException \InvalidArgumentException - * - * @return void - */ - public function testExceptionOnInvalidObject() - { - new DocBlock($this); - } - - public function testDotSeperation() - { - $fixture = <<assertEquals( - 'This is a short description.', - $object->getShortDescription() - ); - $this->assertEquals( - "This is a long description.\nThis is a continuation of the long " - ."description.", - $object->getLongDescription()->getContents() - ); - } - - /** - * @covers \phpDocumentor\Reflection\DocBlock::parseTags - * @expectedException \LogicException - * - * @return void - */ - public function testInvalidTagBlock() - { - if (0 == ini_get('allow_url_include')) { - $this->markTestSkipped('"data" URIs for includes are required.'); - } - - include 'data:text/plain;base64,'. base64_encode( - <<assertEquals( - 'This is a short description.', - $object->getShortDescription() - ); - $this->assertEquals( - 'This is a long description.', - $object->getLongDescription()->getContents() - ); - $tags = $object->getTags(); - $this->assertCount(2, $tags); - $this->assertTrue($object->hasTag('method')); - $this->assertTrue($object->hasTag('Method')); - $this->assertInstanceOf( - __NAMESPACE__ . '\DocBlock\Tag\MethodTag', - $tags[0] - ); - $this->assertInstanceOf( - __NAMESPACE__ . '\DocBlock\Tag', - $tags[1] - ); - $this->assertNotInstanceOf( - __NAMESPACE__ . '\DocBlock\Tag\MethodTag', - $tags[1] - ); - } - - /** - * @depends testConstructFromReflector - * @covers \phpDocumentor\Reflection\DocBlock::getTagsByName - * - * @return void - */ - public function testGetTagsByNameZeroAndOneMatch() - { - $object = new DocBlock(new \ReflectionClass($this)); - $this->assertEmpty($object->getTagsByName('category')); - $this->assertCount(1, $object->getTagsByName('author')); - } - - /** - * @depends testConstructWithTagsOnly - * @covers \phpDocumentor\Reflection\DocBlock::parseTags - * - * @return void - */ - public function testParseMultilineTag() - { - $fixture = <<assertCount(1, $object->getTags()); - } - - /** - * @depends testConstructWithTagsOnly - * @covers \phpDocumentor\Reflection\DocBlock::parseTags - * - * @return void - */ - public function testParseMultilineTagWithLineBreaks() - { - $fixture = <<assertCount(1, $tags = $object->getTags()); - /** @var ReturnTag $tag */ - $tag = reset($tags); - $this->assertEquals("Content on\n multiple lines.\n\n One more, after the break.", $tag->getDescription()); - } - - /** - * @depends testConstructWithTagsOnly - * @covers \phpDocumentor\Reflection\DocBlock::getTagsByName - * - * @return void - */ - public function testGetTagsByNameMultipleMatch() - { - $fixture = <<assertEmpty($object->getTagsByName('category')); - $this->assertCount(1, $object->getTagsByName('return')); - $this->assertCount(2, $object->getTagsByName('param')); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/FilterTest.php b/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/FilterTest.php deleted file mode 100644 index 66f8bb42f..000000000 --- a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/FilterTest.php +++ /dev/null @@ -1,281 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -if (!defined('TEST_FILES_PATH')) { - define( - 'TEST_FILES_PATH', - dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . - '_files' . DIRECTORY_SEPARATOR - ); -} - -/** - * Tests for the PHP_CodeCoverage_Filter class. - * - * @since Class available since Release 1.0.0 - */ -class PHP_CodeCoverage_FilterTest extends PHPUnit_Framework_TestCase -{ - protected $filter; - protected $files; - - protected function setUp() - { - $this->filter = unserialize('O:23:"PHP_CodeCoverage_Filter":0:{}'); - - $this->files = array( - TEST_FILES_PATH . 'BankAccount.php', - TEST_FILES_PATH . 'BankAccountTest.php', - TEST_FILES_PATH . 'CoverageClassExtendedTest.php', - TEST_FILES_PATH . 'CoverageClassTest.php', - TEST_FILES_PATH . 'CoverageFunctionParenthesesTest.php', - TEST_FILES_PATH . 'CoverageFunctionParenthesesWhitespaceTest.php', - TEST_FILES_PATH . 'CoverageFunctionTest.php', - TEST_FILES_PATH . 'CoverageMethodOneLineAnnotationTest.php', - TEST_FILES_PATH . 'CoverageMethodParenthesesTest.php', - TEST_FILES_PATH . 'CoverageMethodParenthesesWhitespaceTest.php', - TEST_FILES_PATH . 'CoverageMethodTest.php', - TEST_FILES_PATH . 'CoverageNoneTest.php', - TEST_FILES_PATH . 'CoverageNotPrivateTest.php', - TEST_FILES_PATH . 'CoverageNotProtectedTest.php', - TEST_FILES_PATH . 'CoverageNotPublicTest.php', - TEST_FILES_PATH . 'CoverageNothingTest.php', - TEST_FILES_PATH . 'CoveragePrivateTest.php', - TEST_FILES_PATH . 'CoverageProtectedTest.php', - TEST_FILES_PATH . 'CoveragePublicTest.php', - TEST_FILES_PATH . 'CoverageTwoDefaultClassAnnotations.php', - TEST_FILES_PATH . 'CoveredClass.php', - TEST_FILES_PATH . 'CoveredFunction.php', - TEST_FILES_PATH . 'NamespaceCoverageClassExtendedTest.php', - TEST_FILES_PATH . 'NamespaceCoverageClassTest.php', - TEST_FILES_PATH . 'NamespaceCoverageCoversClassPublicTest.php', - TEST_FILES_PATH . 'NamespaceCoverageCoversClassTest.php', - TEST_FILES_PATH . 'NamespaceCoverageMethodTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotPrivateTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotProtectedTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotPublicTest.php', - TEST_FILES_PATH . 'NamespaceCoveragePrivateTest.php', - TEST_FILES_PATH . 'NamespaceCoverageProtectedTest.php', - TEST_FILES_PATH . 'NamespaceCoveragePublicTest.php', - TEST_FILES_PATH . 'NamespaceCoveredClass.php', - TEST_FILES_PATH . 'NotExistingCoveredElementTest.php', - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php', - TEST_FILES_PATH . 'source_with_ignore.php', - TEST_FILES_PATH . 'source_with_namespace.php', - TEST_FILES_PATH . 'source_with_oneline_annotations.php', - TEST_FILES_PATH . 'source_without_ignore.php', - TEST_FILES_PATH . 'source_without_namespace.php' - ); - } - - /** - * @covers PHP_CodeCoverage_Filter::addFileToBlacklist - * @covers PHP_CodeCoverage_Filter::getBlacklist - */ - public function testAddingAFileToTheBlacklistWorks() - { - $this->filter->addFileToBlacklist($this->files[0]); - - $this->assertEquals( - array($this->files[0]), - $this->filter->getBlacklist() - ); - } - - /** - * @covers PHP_CodeCoverage_Filter::removeFileFromBlacklist - * @covers PHP_CodeCoverage_Filter::getBlacklist - */ - public function testRemovingAFileFromTheBlacklistWorks() - { - $this->filter->addFileToBlacklist($this->files[0]); - $this->filter->removeFileFromBlacklist($this->files[0]); - - $this->assertEquals(array(), $this->filter->getBlacklist()); - } - - /** - * @covers PHP_CodeCoverage_Filter::addDirectoryToBlacklist - * @covers PHP_CodeCoverage_Filter::getBlacklist - * @depends testAddingAFileToTheBlacklistWorks - */ - public function testAddingADirectoryToTheBlacklistWorks() - { - $this->filter->addDirectoryToBlacklist(TEST_FILES_PATH); - - $blacklist = $this->filter->getBlacklist(); - sort($blacklist); - - $this->assertEquals($this->files, $blacklist); - } - - /** - * @covers PHP_CodeCoverage_Filter::addFilesToBlacklist - * @covers PHP_CodeCoverage_Filter::getBlacklist - */ - public function testAddingFilesToTheBlacklistWorks() - { - $facade = new File_Iterator_Facade; - $files = $facade->getFilesAsArray( - TEST_FILES_PATH, - $suffixes = '.php' - ); - - $this->filter->addFilesToBlacklist($files); - - $blacklist = $this->filter->getBlacklist(); - sort($blacklist); - - $this->assertEquals($this->files, $blacklist); - } - - /** - * @covers PHP_CodeCoverage_Filter::removeDirectoryFromBlacklist - * @covers PHP_CodeCoverage_Filter::getBlacklist - * @depends testAddingADirectoryToTheBlacklistWorks - */ - public function testRemovingADirectoryFromTheBlacklistWorks() - { - $this->filter->addDirectoryToBlacklist(TEST_FILES_PATH); - $this->filter->removeDirectoryFromBlacklist(TEST_FILES_PATH); - - $this->assertEquals(array(), $this->filter->getBlacklist()); - } - - /** - * @covers PHP_CodeCoverage_Filter::addFileToWhitelist - * @covers PHP_CodeCoverage_Filter::getWhitelist - */ - public function testAddingAFileToTheWhitelistWorks() - { - $this->filter->addFileToWhitelist($this->files[0]); - - $this->assertEquals( - array($this->files[0]), - $this->filter->getWhitelist() - ); - } - - /** - * @covers PHP_CodeCoverage_Filter::removeFileFromWhitelist - * @covers PHP_CodeCoverage_Filter::getWhitelist - */ - public function testRemovingAFileFromTheWhitelistWorks() - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->filter->removeFileFromWhitelist($this->files[0]); - - $this->assertEquals(array(), $this->filter->getWhitelist()); - } - - /** - * @covers PHP_CodeCoverage_Filter::addDirectoryToWhitelist - * @covers PHP_CodeCoverage_Filter::getWhitelist - * @depends testAddingAFileToTheWhitelistWorks - */ - public function testAddingADirectoryToTheWhitelistWorks() - { - $this->filter->addDirectoryToWhitelist(TEST_FILES_PATH); - - $whitelist = $this->filter->getWhitelist(); - sort($whitelist); - - $this->assertEquals($this->files, $whitelist); - } - - /** - * @covers PHP_CodeCoverage_Filter::addFilesToWhitelist - * @covers PHP_CodeCoverage_Filter::getBlacklist - */ - public function testAddingFilesToTheWhitelistWorks() - { - $facade = new File_Iterator_Facade; - $files = $facade->getFilesAsArray( - TEST_FILES_PATH, - $suffixes = '.php' - ); - - $this->filter->addFilesToWhitelist($files); - - $whitelist = $this->filter->getWhitelist(); - sort($whitelist); - - $this->assertEquals($this->files, $whitelist); - } - - /** - * @covers PHP_CodeCoverage_Filter::removeDirectoryFromWhitelist - * @covers PHP_CodeCoverage_Filter::getWhitelist - * @depends testAddingADirectoryToTheWhitelistWorks - */ - public function testRemovingADirectoryFromTheWhitelistWorks() - { - $this->filter->addDirectoryToWhitelist(TEST_FILES_PATH); - $this->filter->removeDirectoryFromWhitelist(TEST_FILES_PATH); - - $this->assertEquals(array(), $this->filter->getWhitelist()); - } - - /** - * @covers PHP_CodeCoverage_Filter::isFile - */ - public function testIsFile() - { - $this->assertFalse($this->filter->isFile('vfs://root/a/path')); - $this->assertFalse($this->filter->isFile('xdebug://debug-eval')); - $this->assertFalse($this->filter->isFile('eval()\'d code')); - $this->assertFalse($this->filter->isFile('runtime-created function')); - $this->assertFalse($this->filter->isFile('assert code')); - $this->assertFalse($this->filter->isFile('regexp code')); - $this->assertTrue($this->filter->isFile(__FILE__)); - } - - /** - * @covers PHP_CodeCoverage_Filter::isFiltered - */ - public function testBlacklistedFileIsFiltered() - { - $this->filter->addFileToBlacklist($this->files[0]); - $this->assertTrue($this->filter->isFiltered($this->files[0])); - } - - /** - * @covers PHP_CodeCoverage_Filter::isFiltered - */ - public function testWhitelistedFileIsNotFiltered() - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->assertFalse($this->filter->isFiltered($this->files[0])); - } - - /** - * @covers PHP_CodeCoverage_Filter::isFiltered - */ - public function testNotWhitelistedFileIsFiltered() - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->assertTrue($this->filter->isFiltered($this->files[1])); - } - - /** - * @covers PHP_CodeCoverage_Filter::isFiltered - * @covers PHP_CodeCoverage_Filter::isFile - */ - public function testNonFilesAreFiltered() - { - $this->assertTrue($this->filter->isFiltered('vfs://root/a/path')); - $this->assertTrue($this->filter->isFiltered('xdebug://debug-eval')); - $this->assertTrue($this->filter->isFiltered('eval()\'d code')); - $this->assertTrue($this->filter->isFiltered('runtime-created function')); - $this->assertTrue($this->filter->isFiltered('assert code')); - $this->assertTrue($this->filter->isFiltered('regexp code')); - $this->assertFalse($this->filter->isFiltered(__FILE__)); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/CloverTest.php b/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/CloverTest.php deleted file mode 100644 index 8d860bd2d..000000000 --- a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/CloverTest.php +++ /dev/null @@ -1,66 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -if (!defined('TEST_FILES_PATH')) { - define( - 'TEST_FILES_PATH', - dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . - '_files' . DIRECTORY_SEPARATOR - ); -} - -require_once TEST_FILES_PATH . '../TestCase.php'; - -/** - * Tests for the PHP_CodeCoverage_Report_Clover class. - * - * @since Class available since Release 1.0.0 - */ -class PHP_CodeCoverage_Report_CloverTest extends PHP_CodeCoverage_TestCase -{ - /** - * @covers PHP_CodeCoverage_Report_Clover - */ - public function testCloverForBankAccountTest() - { - $clover = new PHP_CodeCoverage_Report_Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'BankAccount-clover.xml', - $clover->process($this->getCoverageForBankAccount(), null, 'BankAccount') - ); - } - - /** - * @covers PHP_CodeCoverage_Report_Clover - */ - public function testCloverForFileWithIgnoredLines() - { - $clover = new PHP_CodeCoverage_Report_Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'ignored-lines-clover.xml', - $clover->process($this->getCoverageForFileWithIgnoredLines()) - ); - } - - /** - * @covers PHP_CodeCoverage_Report_Clover - */ - public function testCloverForClassWithAnonymousFunction() - { - $clover = new PHP_CodeCoverage_Report_Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'class-with-anonymous-function-clover.xml', - $clover->process($this->getCoverageForClassWithAnonymousFunction()) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/FactoryTest.php b/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/FactoryTest.php deleted file mode 100644 index 84f14aea7..000000000 --- a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/Report/FactoryTest.php +++ /dev/null @@ -1,222 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -if (!defined('TEST_FILES_PATH')) { - define( - 'TEST_FILES_PATH', - dirname(dirname(dirname(dirname(__FILE__)))) . DIRECTORY_SEPARATOR . - '_files' . DIRECTORY_SEPARATOR - ); -} - -require_once TEST_FILES_PATH . '../TestCase.php'; - -/** - * Tests for the PHP_CodeCoverage_Report_Factory class. - * - * @since Class available since Release 1.1.0 - */ -class PHP_CodeCoverage_Report_FactoryTest extends PHP_CodeCoverage_TestCase -{ - protected $factory; - - protected function setUp() - { - $this->factory = new PHP_CodeCoverage_Report_Factory; - } - - public function testSomething() - { - $root = $this->getCoverageForBankAccount()->getReport(); - - $expectedPath = rtrim(TEST_FILES_PATH, DIRECTORY_SEPARATOR); - $this->assertEquals($expectedPath, $root->getName()); - $this->assertEquals($expectedPath, $root->getPath()); - $this->assertEquals(10, $root->getNumExecutableLines()); - $this->assertEquals(5, $root->getNumExecutedLines()); - $this->assertEquals(1, $root->getNumClasses()); - $this->assertEquals(0, $root->getNumTestedClasses()); - $this->assertEquals(4, $root->getNumMethods()); - $this->assertEquals(3, $root->getNumTestedMethods()); - $this->assertEquals('0.00%', $root->getTestedClassesPercent()); - $this->assertEquals('75.00%', $root->getTestedMethodsPercent()); - $this->assertEquals('50.00%', $root->getLineExecutedPercent()); - $this->assertEquals(0, $root->getNumFunctions()); - $this->assertEquals(0, $root->getNumTestedFunctions()); - $this->assertNull($root->getParent()); - $this->assertEquals(array(), $root->getDirectories()); - #$this->assertEquals(array(), $root->getFiles()); - #$this->assertEquals(array(), $root->getChildNodes()); - - $this->assertEquals( - array( - 'BankAccount' => array( - 'methods' => array( - 'getBalance' => array( - 'signature' => 'getBalance()', - 'startLine' => 6, - 'endLine' => 9, - 'executableLines' => 1, - 'executedLines' => 1, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#6', - 'methodName' => 'getBalance' - ), - 'setBalance' => array( - 'signature' => 'setBalance($balance)', - 'startLine' => 11, - 'endLine' => 18, - 'executableLines' => 5, - 'executedLines' => 0, - 'ccn' => 2, - 'coverage' => 0, - 'crap' => 6, - 'link' => 'BankAccount.php.html#11', - 'methodName' => 'setBalance' - ), - 'depositMoney' => array( - 'signature' => 'depositMoney($balance)', - 'startLine' => 20, - 'endLine' => 25, - 'executableLines' => 2, - 'executedLines' => 2, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#20', - 'methodName' => 'depositMoney' - ), - 'withdrawMoney' => array( - 'signature' => 'withdrawMoney($balance)', - 'startLine' => 27, - 'endLine' => 32, - 'executableLines' => 2, - 'executedLines' => 2, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#27', - 'methodName' => 'withdrawMoney' - ), - ), - 'startLine' => 2, - 'executableLines' => 10, - 'executedLines' => 5, - 'ccn' => 5, - 'coverage' => 50, - 'crap' => '8.12', - 'package' => array( - 'namespace' => '', - 'fullPackage' => '', - 'category' => '', - 'package' => '', - 'subpackage' => '' - ), - 'link' => 'BankAccount.php.html#2', - 'className' => 'BankAccount' - ) - ), - $root->getClasses() - ); - - $this->assertEquals(array(), $root->getFunctions()); - } - - /** - * @covers PHP_CodeCoverage_Report_Factory::buildDirectoryStructure - */ - public function testBuildDirectoryStructure() - { - $method = new ReflectionMethod( - 'PHP_CodeCoverage_Report_Factory', - 'buildDirectoryStructure' - ); - - $method->setAccessible(true); - - $this->assertEquals( - array( - 'src' => array( - 'Money.php/f' => array(), - 'MoneyBag.php/f' => array() - ) - ), - $method->invoke( - $this->factory, - array('src/Money.php' => array(), 'src/MoneyBag.php' => array()) - ) - ); - } - - /** - * @covers PHP_CodeCoverage_Report_Factory::reducePaths - * @dataProvider reducePathsProvider - */ - public function testReducePaths($reducedPaths, $commonPath, $paths) - { - $method = new ReflectionMethod( - 'PHP_CodeCoverage_Report_Factory', - 'reducePaths' - ); - - $method->setAccessible(true); - - $_commonPath = $method->invokeArgs($this->factory, array(&$paths)); - - $this->assertEquals($reducedPaths, $paths); - $this->assertEquals($commonPath, $_commonPath); - } - - public function reducePathsProvider() - { - return array( - array( - array( - 'Money.php' => array(), - 'MoneyBag.php' => array() - ), - '/home/sb/Money', - array( - '/home/sb/Money/Money.php' => array(), - '/home/sb/Money/MoneyBag.php' => array() - ) - ), - array( - array( - 'Money.php' => array() - ), - '/home/sb/Money/', - array( - '/home/sb/Money/Money.php' => array() - ) - ), - array( - array(), - '.', - array() - ), - array( - array( - 'Money.php' => array(), - 'MoneyBag.php' => array(), - 'Cash.phar/Cash.php' => array(), - ), - '/home/sb/Money', - array( - '/home/sb/Money/Money.php' => array(), - '/home/sb/Money/MoneyBag.php' => array(), - 'phar:///home/sb/Money/Cash.phar/Cash.php' => array(), - ), - ), - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/UtilTest.php b/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/UtilTest.php deleted file mode 100644 index 0b4caea97..000000000 --- a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverage/UtilTest.php +++ /dev/null @@ -1,30 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_CodeCoverage_Util class. - * - * @since Class available since Release 1.0.0 - */ -class PHP_CodeCoverage_UtilTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHP_CodeCoverage_Util::percent - */ - public function testPercent() - { - $this->assertEquals(100, PHP_CodeCoverage_Util::percent(100, 0)); - $this->assertEquals(100, PHP_CodeCoverage_Util::percent(100, 100)); - $this->assertEquals( - '100.00%', - PHP_CodeCoverage_Util::percent(100, 100, true) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverageTest.php b/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverageTest.php deleted file mode 100644 index a755b8812..000000000 --- a/vendor/phpunit/php-code-coverage/tests/PHP/CodeCoverageTest.php +++ /dev/null @@ -1,487 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -if (!defined('TEST_FILES_PATH')) { - define( - 'TEST_FILES_PATH', - dirname(dirname(__FILE__)) . DIRECTORY_SEPARATOR . - '_files' . DIRECTORY_SEPARATOR - ); -} - -require_once TEST_FILES_PATH . '../TestCase.php'; -require_once TEST_FILES_PATH . 'BankAccount.php'; -require_once TEST_FILES_PATH . 'BankAccountTest.php'; - -/** - * Tests for the PHP_CodeCoverage class. - * - * @since Class available since Release 1.0.0 - */ -class PHP_CodeCoverageTest extends PHP_CodeCoverage_TestCase -{ - /** - * @var PHP_CodeCoverage - */ - private $coverage; - - protected function setUp() - { - $this->coverage = new PHP_CodeCoverage; - } - - /** - * @covers PHP_CodeCoverage::__construct - * @covers PHP_CodeCoverage::filter - */ - public function testConstructor() - { - $this->assertAttributeInstanceOf( - 'PHP_CodeCoverage_Driver_Xdebug', - 'driver', - $this->coverage - ); - - $this->assertAttributeInstanceOf( - 'PHP_CodeCoverage_Filter', - 'filter', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::__construct - * @covers PHP_CodeCoverage::filter - */ - public function testConstructor2() - { - $filter = new PHP_CodeCoverage_Filter; - $coverage = new PHP_CodeCoverage(null, $filter); - - $this->assertAttributeInstanceOf( - 'PHP_CodeCoverage_Driver_Xdebug', - 'driver', - $coverage - ); - - $this->assertSame($filter, $coverage->filter()); - } - - /** - * @covers PHP_CodeCoverage::start - * @expectedException PHP_CodeCoverage_Exception - */ - public function testStartThrowsExceptionForInvalidArgument() - { - $this->coverage->start(null, array(), null); - } - - /** - * @covers PHP_CodeCoverage::stop - * @expectedException PHP_CodeCoverage_Exception - */ - public function testStopThrowsExceptionForInvalidArgument() - { - $this->coverage->stop(null); - } - - /** - * @covers PHP_CodeCoverage::stop - * @expectedException PHP_CodeCoverage_Exception - */ - public function testStopThrowsExceptionForInvalidArgument2() - { - $this->coverage->stop(true, null); - } - - /** - * @covers PHP_CodeCoverage::append - * @expectedException PHP_CodeCoverage_Exception - */ - public function testAppendThrowsExceptionForInvalidArgument() - { - $this->coverage->append(array(), null); - } - - /** - * @covers PHP_CodeCoverage::setCacheTokens - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetCacheTokensThrowsExceptionForInvalidArgument() - { - $this->coverage->setCacheTokens(null); - } - - /** - * @covers PHP_CodeCoverage::setCacheTokens - */ - public function testSetCacheTokens() - { - $this->coverage->setCacheTokens(true); - $this->assertAttributeEquals(true, 'cacheTokens', $this->coverage); - } - - /** - * @covers PHP_CodeCoverage::setCheckForUnintentionallyCoveredCode - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetCheckForUnintentionallyCoveredCodeThrowsExceptionForInvalidArgument() - { - $this->coverage->setCheckForUnintentionallyCoveredCode(null); - } - - /** - * @covers PHP_CodeCoverage::setCheckForUnintentionallyCoveredCode - */ - public function testSetCheckForUnintentionallyCoveredCode() - { - $this->coverage->setCheckForUnintentionallyCoveredCode(true); - $this->assertAttributeEquals( - true, - 'checkForUnintentionallyCoveredCode', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::setForceCoversAnnotation - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetForceCoversAnnotationThrowsExceptionForInvalidArgument() - { - $this->coverage->setForceCoversAnnotation(null); - } - - /** - * @covers PHP_CodeCoverage::setForceCoversAnnotation - */ - public function testSetForceCoversAnnotation() - { - $this->coverage->setForceCoversAnnotation(true); - $this->assertAttributeEquals( - true, - 'forceCoversAnnotation', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::setAddUncoveredFilesFromWhitelist - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetAddUncoveredFilesFromWhitelistThrowsExceptionForInvalidArgument() - { - $this->coverage->setAddUncoveredFilesFromWhitelist(null); - } - - /** - * @covers PHP_CodeCoverage::setAddUncoveredFilesFromWhitelist - */ - public function testSetAddUncoveredFilesFromWhitelist() - { - $this->coverage->setAddUncoveredFilesFromWhitelist(true); - $this->assertAttributeEquals( - true, - 'addUncoveredFilesFromWhitelist', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::setProcessUncoveredFilesFromWhitelist - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetProcessUncoveredFilesFromWhitelistThrowsExceptionForInvalidArgument() - { - $this->coverage->setProcessUncoveredFilesFromWhitelist(null); - } - - /** - * @covers PHP_CodeCoverage::setProcessUncoveredFilesFromWhitelist - */ - public function testSetProcessUncoveredFilesFromWhitelist() - { - $this->coverage->setProcessUncoveredFilesFromWhitelist(true); - $this->assertAttributeEquals( - true, - 'processUncoveredFilesFromWhitelist', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::setMapTestClassNameToCoveredClassName - */ - public function testSetMapTestClassNameToCoveredClassName() - { - $this->coverage->setMapTestClassNameToCoveredClassName(true); - $this->assertAttributeEquals( - true, - 'mapTestClassNameToCoveredClassName', - $this->coverage - ); - } - - /** - * @covers PHP_CodeCoverage::setMapTestClassNameToCoveredClassName - * @expectedException PHP_CodeCoverage_Exception - */ - public function testSetMapTestClassNameToCoveredClassNameThrowsExceptionForInvalidArgument() - { - $this->coverage->setMapTestClassNameToCoveredClassName(null); - } - - /** - * @covers PHP_CodeCoverage::clear - */ - public function testClear() - { - $this->coverage->clear(); - - $this->assertAttributeEquals(null, 'currentId', $this->coverage); - $this->assertAttributeEquals(array(), 'data', $this->coverage); - $this->assertAttributeEquals(array(), 'tests', $this->coverage); - } - - /** - * @covers PHP_CodeCoverage::start - * @covers PHP_CodeCoverage::stop - * @covers PHP_CodeCoverage::append - * @covers PHP_CodeCoverage::applyListsFilter - * @covers PHP_CodeCoverage::initializeFilesThatAreSeenTheFirstTime - * @covers PHP_CodeCoverage::applyCoversAnnotationFilter - * @covers PHP_CodeCoverage::getTests - */ - public function testCollect() - { - $coverage = $this->getCoverageForBankAccount(); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - - if (version_compare(PHPUnit_Runner_Version::id(), '4.7', '>=')) { - $size = 'unknown'; - } else { - $size = 'small'; - } - - $this->assertEquals( - array( - 'BankAccountTest::testBalanceIsInitiallyZero' => array('size' => $size, 'status' => null), - 'BankAccountTest::testBalanceCannotBecomeNegative' => array('size' => $size, 'status' => null), - 'BankAccountTest::testBalanceCannotBecomeNegative2' => array('size' => $size, 'status' => null), - 'BankAccountTest::testDepositWithdrawMoney' => array('size' => $size, 'status' => null) - ), - $coverage->getTests() - ); - } - - /** - * @covers PHP_CodeCoverage::getData - * @covers PHP_CodeCoverage::merge - */ - public function testMerge() - { - $coverage = $this->getCoverageForBankAccountForFirstTwoTests(); - $coverage->merge($this->getCoverageForBankAccountForLastTwoTests()); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - } - - /** - * @covers PHP_CodeCoverage::getData - * @covers PHP_CodeCoverage::merge - */ - public function testMerge2() - { - $coverage = new PHP_CodeCoverage( - $this->getMock('PHP_CodeCoverage_Driver_Xdebug'), - new PHP_CodeCoverage_Filter - ); - - $coverage->merge($this->getCoverageForBankAccount()); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - } - - /** - * @covers PHP_CodeCoverage::getLinesToBeIgnored - */ - public function testGetLinesToBeIgnored() - { - $this->assertEquals( - array( - 1, - 3, - 4, - 5, - 7, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 16, - 17, - 18, - 19, - 20, - 21, - 22, - 23, - 24, - 25, - 26, - 27, - 28, - 30, - 32, - 33, - 34, - 35, - 36, - 37, - 38 - ), - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_ignore.php' - ) - ); - } - - /** - * @covers PHP_CodeCoverage::getLinesToBeIgnored - */ - public function testGetLinesToBeIgnored2() - { - $this->assertEquals( - array(1, 5), - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_without_ignore.php' - ) - ); - } - - /** - * @covers PHP_CodeCoverage::getLinesToBeIgnored - */ - public function testGetLinesToBeIgnored3() - { - $this->assertEquals( - array( - 1, - 2, - 3, - 4, - 5, - 8, - 11, - 15, - 16, - 19, - 20 - ), - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php' - ) - ); - } - - /** - * @covers PHP_CodeCoverage::getLinesToBeIgnored - */ - public function testGetLinesToBeIgnoredOneLineAnnotations() - { - $this->assertEquals( - array( - 1, - 2, - 3, - 4, - 5, - 6, - 7, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 16, - 18, - 20, - 21, - 23, - 24, - 25, - 27, - 28, - 29, - 30, - 31, - 32, - 33, - 34, - 37 - ), - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_oneline_annotations.php' - ) - ); - } - - /** - * @return ReflectionMethod - */ - private function getLinesToBeIgnored() - { - $getLinesToBeIgnored = new ReflectionMethod( - 'PHP_CodeCoverage', - 'getLinesToBeIgnored' - ); - - $getLinesToBeIgnored->setAccessible(true); - - return $getLinesToBeIgnored; - } - - /** - * @covers PHP_CodeCoverage::getLinesToBeIgnored - */ - public function testGetLinesToBeIgnoredWhenIgnoreIsDisabled() - { - $this->coverage->setDisableIgnoredLines(true); - - $this->assertEquals( - array(), - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_ignore.php' - ) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/TestCase.php b/vendor/phpunit/php-code-coverage/tests/TestCase.php deleted file mode 100644 index f98242824..000000000 --- a/vendor/phpunit/php-code-coverage/tests/TestCase.php +++ /dev/null @@ -1,311 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Abstract base class for test case classes. - * - * @since Class available since Release 1.0.0 - */ -abstract class PHP_CodeCoverage_TestCase extends PHPUnit_Framework_TestCase -{ - protected function getXdebugDataForBankAccount() - { - return array( - array( - TEST_FILES_PATH . 'BankAccount.php' => array( - 8 => 1, - 9 => -2, - 13 => -1, - 14 => -1, - 15 => -1, - 16 => -1, - 18 => -1, - 22 => -1, - 24 => -1, - 25 => -2, - 29 => -1, - 31 => -1, - 32 => -2 - ) - ), - array( - TEST_FILES_PATH . 'BankAccount.php' => array( - 8 => 1, - 13 => 1, - 16 => 1, - 29 => 1, - ) - ), - array( - TEST_FILES_PATH . 'BankAccount.php' => array( - 8 => 1, - 13 => 1, - 16 => 1, - 22 => 1, - ) - ), - array( - TEST_FILES_PATH . 'BankAccount.php' => array( - 8 => 1, - 13 => 1, - 14 => 1, - 15 => 1, - 18 => 1, - 22 => 1, - 24 => 1, - 29 => 1, - 31 => 1, - ) - ) - ); - } - - protected function getCoverageForBankAccount() - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->getMock('PHP_CodeCoverage_Driver_Xdebug'); - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[0], - $data[1], - $data[2], - $data[3] - )); - - $coverage = new PHP_CodeCoverage($stub, new PHP_CodeCoverage_Filter); - - $coverage->start( - new BankAccountTest('testBalanceIsInitiallyZero'), - true - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(6, 9)) - ); - - $coverage->start( - new BankAccountTest('testBalanceCannotBecomeNegative') - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(27, 32)) - ); - - $coverage->start( - new BankAccountTest('testBalanceCannotBecomeNegative2') - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(20, 25)) - ); - - $coverage->start( - new BankAccountTest('testDepositWithdrawMoney') - ); - - $coverage->stop( - true, - array( - TEST_FILES_PATH . 'BankAccount.php' => array_merge( - range(6, 9), - range(20, 25), - range(27, 32) - ) - ) - ); - - return $coverage; - } - - protected function getCoverageForBankAccountForFirstTwoTests() - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->getMock('PHP_CodeCoverage_Driver_Xdebug'); - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[0], - $data[1] - )); - - $coverage = new PHP_CodeCoverage($stub, new PHP_CodeCoverage_Filter); - - $coverage->start( - new BankAccountTest('testBalanceIsInitiallyZero'), - true - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(6, 9)) - ); - - $coverage->start( - new BankAccountTest('testBalanceCannotBecomeNegative') - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(27, 32)) - ); - - return $coverage; - } - - protected function getCoverageForBankAccountForLastTwoTests() - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->getMock('PHP_CodeCoverage_Driver_Xdebug'); - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[2], - $data[3] - )); - - $coverage = new PHP_CodeCoverage($stub, new PHP_CodeCoverage_Filter); - - $coverage->start( - new BankAccountTest('testBalanceCannotBecomeNegative2') - ); - - $coverage->stop( - true, - array(TEST_FILES_PATH . 'BankAccount.php' => range(20, 25)) - ); - - $coverage->start( - new BankAccountTest('testDepositWithdrawMoney') - ); - - $coverage->stop( - true, - array( - TEST_FILES_PATH . 'BankAccount.php' => array_merge( - range(6, 9), - range(20, 25), - range(27, 32) - ) - ) - ); - - return $coverage; - } - - protected function getExpectedDataArrayForBankAccount() - { - return array( - TEST_FILES_PATH . 'BankAccount.php' => array( - 8 => array( - 0 => 'BankAccountTest::testBalanceIsInitiallyZero', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ), - 9 => null, - 13 => array(), - 14 => array(), - 15 => array(), - 16 => array(), - 18 => array(), - 22 => array( - 0 => 'BankAccountTest::testBalanceCannotBecomeNegative2', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ), - 24 => array( - 0 => 'BankAccountTest::testDepositWithdrawMoney', - ), - 25 => null, - 29 => array( - 0 => 'BankAccountTest::testBalanceCannotBecomeNegative', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ), - 31 => array( - 0 => 'BankAccountTest::testDepositWithdrawMoney' - ), - 32 => null - ) - ); - } - - protected function getCoverageForFileWithIgnoredLines() - { - $coverage = new PHP_CodeCoverage( - $this->setUpXdebugStubForFileWithIgnoredLines(), - new PHP_CodeCoverage_Filter - ); - - $coverage->start('FileWithIgnoredLines', true); - $coverage->stop(); - - return $coverage; - } - - protected function setUpXdebugStubForFileWithIgnoredLines() - { - $stub = $this->getMock('PHP_CodeCoverage_Driver_Xdebug'); - $stub->expects($this->any()) - ->method('stop') - ->will($this->returnValue( - array( - TEST_FILES_PATH . 'source_with_ignore.php' => array( - 2 => 1, - 4 => -1, - 6 => -1, - 7 => 1 - ) - ) - )); - - return $stub; - } - - protected function getCoverageForClassWithAnonymousFunction() - { - $coverage = new PHP_CodeCoverage( - $this->setUpXdebugStubForClassWithAnonymousFunction(), - new PHP_CodeCoverage_Filter - ); - - $coverage->start('ClassWithAnonymousFunction', true); - $coverage->stop(); - - return $coverage; - } - - protected function setUpXdebugStubForClassWithAnonymousFunction() - { - $stub = $this->getMock('PHP_CodeCoverage_Driver_Xdebug'); - $stub->expects($this->any()) - ->method('stop') - ->will($this->returnValue( - array( - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php' => array( - 7 => 1, - 9 => 1, - 10 => -1, - 11 => 1, - 12 => 1, - 13 => 1, - 14 => 1, - 17 => 1, - 18 => 1 - ) - ) - )); - - return $stub; - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml deleted file mode 100644 index 578a7ccc1..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php deleted file mode 100644 index 4238c1559..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php +++ /dev/null @@ -1,33 +0,0 @@ -balance; - } - - protected function setBalance($balance) - { - if ($balance >= 0) { - $this->balance = $balance; - } else { - throw new RuntimeException; - } - } - - public function depositMoney($balance) - { - $this->setBalance($this->getBalance() + $balance); - - return $this->getBalance(); - } - - public function withdrawMoney($balance) - { - $this->setBalance($this->getBalance() - $balance); - - return $this->getBalance(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php b/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php deleted file mode 100644 index 3a6277ba2..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php +++ /dev/null @@ -1,66 +0,0 @@ -ba = new BankAccount; - } - - /** - * @covers BankAccount::getBalance - */ - public function testBalanceIsInitiallyZero() - { - $this->assertEquals(0, $this->ba->getBalance()); - } - - /** - * @covers BankAccount::withdrawMoney - */ - public function testBalanceCannotBecomeNegative() - { - try { - $this->ba->withdrawMoney(1); - } catch (RuntimeException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::depositMoney - */ - public function testBalanceCannotBecomeNegative2() - { - try { - $this->ba->depositMoney(-1); - } catch (RuntimeException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::getBalance - * @covers BankAccount::depositMoney - * @covers BankAccount::withdrawMoney - */ - public function testDepositWithdrawMoney() - { - $this->assertEquals(0, $this->ba->getBalance()); - $this->ba->depositMoney(1); - $this->assertEquals(1, $this->ba->getBalance()); - $this->ba->withdrawMoney(1); - $this->assertEquals(0, $this->ba->getBalance()); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php deleted file mode 100644 index df12d3470..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php deleted file mode 100644 index 7f569ae60..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php deleted file mode 100644 index 33b5fe3de..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php +++ /dev/null @@ -1,11 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php deleted file mode 100644 index 422300457..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php deleted file mode 100644 index d1be1c6cf..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php deleted file mode 100644 index 167b3db4c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php deleted file mode 100644 index 0b414c2ef..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php +++ /dev/null @@ -1,9 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php deleted file mode 100644 index 12b56e80e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php deleted file mode 100644 index c69d261de..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php deleted file mode 100644 index aebfe4bd9..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php deleted file mode 100644 index 5d5680d93..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php +++ /dev/null @@ -1,13 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php deleted file mode 100644 index f09560d3a..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php deleted file mode 100644 index 9b3acbf6c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php deleted file mode 100644 index 480a522b4..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php deleted file mode 100644 index 7ffc5c992..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php +++ /dev/null @@ -1,18 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } - -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php deleted file mode 100644 index f382ce99b..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php +++ /dev/null @@ -1,36 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php deleted file mode 100644 index 9989eb02e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php +++ /dev/null @@ -1,4 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php deleted file mode 100644 index 63912c089..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php deleted file mode 100644 index 45f583b77..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php +++ /dev/null @@ -1,15 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php deleted file mode 100644 index b33674546..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php +++ /dev/null @@ -1,20 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php deleted file mode 100644 index 35dfb8b1d..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php deleted file mode 100644 index 552c9ec50..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php deleted file mode 100644 index 33fc8c72c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php deleted file mode 100644 index ccbc5009c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php deleted file mode 100644 index cce7ba9d6..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php deleted file mode 100644 index dbbcc1c31..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php deleted file mode 100644 index bf1bff8c4..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php deleted file mode 100644 index 5bd0ddfb2..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php +++ /dev/null @@ -1,38 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php deleted file mode 100644 index be07ef45e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php +++ /dev/null @@ -1,24 +0,0 @@ - - */ - public function testThree() - { - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml deleted file mode 100644 index ac43b8061..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml deleted file mode 100644 index cda929cd3..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php b/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php deleted file mode 100644 index eaba387d6..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php +++ /dev/null @@ -1,19 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for PHP_Timer. - * - * @since Class available since Release 1.0.0 - */ -class PHP_TimerTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHP_Timer::start - * @covers PHP_Timer::stop - */ - public function testStartStop() - { - $this->assertInternalType('float', PHP_Timer::stop()); - } - - /** - * @covers PHP_Timer::secondsToTimeString - * @dataProvider secondsProvider - */ - public function testSecondsToTimeString($string, $seconds) - { - $this->assertEquals( - $string, - PHP_Timer::secondsToTimeString($seconds) - ); - } - - /** - * @covers PHP_Timer::timeSinceStartOfRequest - */ - public function testTimeSinceStartOfRequest() - { - $this->assertStringMatchesFormat( - '%f %s', - PHP_Timer::timeSinceStartOfRequest() - ); - } - - - /** - * @covers PHP_Timer::resourceUsage - */ - public function testResourceUsage() - { - $this->assertStringMatchesFormat( - 'Time: %s, Memory: %s', - PHP_Timer::resourceUsage() - ); - } - - public function secondsProvider() - { - return array( - array('0 ms', 0), - array('1 ms', .001), - array('10 ms', .01), - array('100 ms', .1), - array('999 ms', .999), - array('1 second', .9999), - array('1 second', 1), - array('2 seconds', 2), - array('59.9 seconds', 59.9), - array('59.99 seconds', 59.99), - array('59.99 seconds', 59.999), - array('1 minute', 59.9999), - array('59 seconds', 59.001), - array('59.01 seconds', 59.01), - array('1 minute', 60), - array('1.01 minutes', 61), - array('2 minutes', 120), - array('2.01 minutes', 121), - array('59.99 minutes', 3599.9), - array('59.99 minutes', 3599.99), - array('59.99 minutes', 3599.999), - array('1 hour', 3599.9999), - array('59.98 minutes', 3599.001), - array('59.98 minutes', 3599.01), - array('1 hour', 3600), - array('1 hour', 3601), - array('1 hour', 3601.9), - array('1 hour', 3601.99), - array('1 hour', 3601.999), - array('1 hour', 3601.9999), - array('1.01 hours', 3659.9999), - array('1.01 hours', 3659.001), - array('1.01 hours', 3659.01), - array('2 hours', 7199.9999), - ); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/ClassTest.php b/vendor/phpunit/php-token-stream/tests/Token/ClassTest.php deleted file mode 100644 index 4ba029652..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/ClassTest.php +++ /dev/null @@ -1,112 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_CLASS class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Laurent Laville - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.2 - */ -class PHP_Token_ClassTest extends PHPUnit_Framework_TestCase -{ - protected $class; - protected $function; - - protected function setUp() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'source2.php'); - - foreach ($ts as $token) { - if ($token instanceof PHP_Token_CLASS) { - $this->class = $token; - } - - if ($token instanceof PHP_Token_FUNCTION) { - $this->function = $token; - break; - } - } - } - - /** - * @covers PHP_Token_CLASS::getKeywords - */ - public function testGetClassKeywords() - { - $this->assertEquals('abstract', $this->class->getKeywords()); - } - - /** - * @covers PHP_Token_FUNCTION::getKeywords - */ - public function testGetFunctionKeywords() - { - $this->assertEquals('abstract,static', $this->function->getKeywords()); - } - - /** - * @covers PHP_Token_FUNCTION::getVisibility - */ - public function testGetFunctionVisibility() - { - $this->assertEquals('public', $this->function->getVisibility()); - } - - public function testIssue19() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'issue19.php'); - - foreach ($ts as $token) { - if ($token instanceof PHP_Token_CLASS) { - $this->assertFalse($token->hasInterfaces()); - } - } - } - - public function testIssue30() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'issue30.php'); - $this->assertCount(1, $ts->getClasses()); - } - - /** - * @requires PHP 7 - */ - public function testAnonymousClassesAreHandledCorrectly() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'class_with_method_that_declares_anonymous_class.php'); - - $classes = $ts->getClasses(); - - $this->assertEquals(array('class_with_method_that_declares_anonymous_class'), array_keys($classes)); - } - - /** - * @requires PHP 7 - * @ticket https://github.com/sebastianbergmann/php-token-stream/issues/52 - */ - public function testAnonymousClassesAreHandledCorrectly2() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'class_with_method_that_declares_anonymous_class2.php'); - - $classes = $ts->getClasses(); - - $this->assertEquals(array('Test'), array_keys($classes)); - $this->assertEquals(array('methodOne', 'methodTwo'), array_keys($classes['Test']['methods'])); - - $this->assertEmpty($ts->getFunctions()); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/ClosureTest.php b/vendor/phpunit/php-token-stream/tests/Token/ClosureTest.php deleted file mode 100644 index f1e508cf2..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/ClosureTest.php +++ /dev/null @@ -1,85 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_FUNCTION class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Sebastian Bergmann - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.0 - */ -class PHP_Token_ClosureTest extends PHPUnit_Framework_TestCase -{ - protected $functions; - - protected function setUp() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'closure.php'); - - foreach ($ts as $token) { - if ($token instanceof PHP_Token_FUNCTION) { - $this->functions[] = $token; - } - } - } - - /** - * @covers PHP_Token_FUNCTION::getArguments - */ - public function testGetArguments() - { - $this->assertEquals(array('$foo' => null, '$bar' => null), $this->functions[0]->getArguments()); - $this->assertEquals(array('$foo' => 'Foo', '$bar' => null), $this->functions[1]->getArguments()); - $this->assertEquals(array('$foo' => null, '$bar' => null, '$baz' => null), $this->functions[2]->getArguments()); - $this->assertEquals(array('$foo' => 'Foo', '$bar' => null, '$baz' => null), $this->functions[3]->getArguments()); - $this->assertEquals(array(), $this->functions[4]->getArguments()); - $this->assertEquals(array(), $this->functions[5]->getArguments()); - } - - /** - * @covers PHP_Token_FUNCTION::getName - */ - public function testGetName() - { - $this->assertEquals('anonymous function', $this->functions[0]->getName()); - $this->assertEquals('anonymous function', $this->functions[1]->getName()); - $this->assertEquals('anonymous function', $this->functions[2]->getName()); - $this->assertEquals('anonymous function', $this->functions[3]->getName()); - $this->assertEquals('anonymous function', $this->functions[4]->getName()); - $this->assertEquals('anonymous function', $this->functions[5]->getName()); - } - - /** - * @covers PHP_Token::getLine - */ - public function testGetLine() - { - $this->assertEquals(2, $this->functions[0]->getLine()); - $this->assertEquals(3, $this->functions[1]->getLine()); - $this->assertEquals(4, $this->functions[2]->getLine()); - $this->assertEquals(5, $this->functions[3]->getLine()); - } - - /** - * @covers PHP_TokenWithScope::getEndLine - */ - public function testGetEndLine() - { - $this->assertEquals(2, $this->functions[0]->getLine()); - $this->assertEquals(3, $this->functions[1]->getLine()); - $this->assertEquals(4, $this->functions[2]->getLine()); - $this->assertEquals(5, $this->functions[3]->getLine()); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/FunctionTest.php b/vendor/phpunit/php-token-stream/tests/Token/FunctionTest.php deleted file mode 100644 index 4f23c39d8..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/FunctionTest.php +++ /dev/null @@ -1,146 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_FUNCTION class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Sebastian Bergmann - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.0 - */ -class PHP_Token_FunctionTest extends PHPUnit_Framework_TestCase -{ - protected $functions; - - protected function setUp() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'source.php'); - - foreach ($ts as $token) { - if ($token instanceof PHP_Token_FUNCTION) { - $this->functions[] = $token; - } - } - } - - /** - * @covers PHP_Token_FUNCTION::getArguments - */ - public function testGetArguments() - { - $this->assertEquals(array(), $this->functions[0]->getArguments()); - - $this->assertEquals( - array('$baz' => 'Baz'), $this->functions[1]->getArguments() - ); - - $this->assertEquals( - array('$foobar' => 'Foobar'), $this->functions[2]->getArguments() - ); - - $this->assertEquals( - array('$barfoo' => 'Barfoo'), $this->functions[3]->getArguments() - ); - - $this->assertEquals(array(), $this->functions[4]->getArguments()); - - $this->assertEquals(array('$x' => null, '$y' => null), $this->functions[5]->getArguments()); - } - - /** - * @covers PHP_Token_FUNCTION::getName - */ - public function testGetName() - { - $this->assertEquals('foo', $this->functions[0]->getName()); - $this->assertEquals('bar', $this->functions[1]->getName()); - $this->assertEquals('foobar', $this->functions[2]->getName()); - $this->assertEquals('barfoo', $this->functions[3]->getName()); - $this->assertEquals('baz', $this->functions[4]->getName()); - } - - /** - * @covers PHP_Token::getLine - */ - public function testGetLine() - { - $this->assertEquals(5, $this->functions[0]->getLine()); - $this->assertEquals(10, $this->functions[1]->getLine()); - $this->assertEquals(17, $this->functions[2]->getLine()); - $this->assertEquals(21, $this->functions[3]->getLine()); - $this->assertEquals(29, $this->functions[4]->getLine()); - } - - /** - * @covers PHP_TokenWithScope::getEndLine - */ - public function testGetEndLine() - { - $this->assertEquals(5, $this->functions[0]->getEndLine()); - $this->assertEquals(12, $this->functions[1]->getEndLine()); - $this->assertEquals(19, $this->functions[2]->getEndLine()); - $this->assertEquals(23, $this->functions[3]->getEndLine()); - $this->assertEquals(31, $this->functions[4]->getEndLine()); - } - - /** - * @covers PHP_Token_FUNCTION::getDocblock - */ - public function testGetDocblock() - { - $this->assertNull($this->functions[0]->getDocblock()); - - $this->assertEquals( - "/**\n * @param Baz \$baz\n */", - $this->functions[1]->getDocblock() - ); - - $this->assertEquals( - "/**\n * @param Foobar \$foobar\n */", - $this->functions[2]->getDocblock() - ); - - $this->assertNull($this->functions[3]->getDocblock()); - $this->assertNull($this->functions[4]->getDocblock()); - } - - public function testSignature() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'source5.php'); - $f = $ts->getFunctions(); - $c = $ts->getClasses(); - $i = $ts->getInterfaces(); - - $this->assertEquals( - 'foo($a, array $b, array $c = array())', - $f['foo']['signature'] - ); - - $this->assertEquals( - 'm($a, array $b, array $c = array())', - $c['c']['methods']['m']['signature'] - ); - - $this->assertEquals( - 'm($a, array $b, array $c = array())', - $c['a']['methods']['m']['signature'] - ); - - $this->assertEquals( - 'm($a, array $b, array $c = array())', - $i['i']['methods']['m']['signature'] - ); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/IncludeTest.php b/vendor/phpunit/php-token-stream/tests/Token/IncludeTest.php deleted file mode 100644 index 1e4335129..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/IncludeTest.php +++ /dev/null @@ -1,73 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_REQUIRE_ONCE, PHP_Token_REQUIRE - * PHP_Token_INCLUDE_ONCE and PHP_Token_INCLUDE_ONCE classes. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Laurent Laville - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.2 - */ -class PHP_Token_IncludeTest extends PHPUnit_Framework_TestCase -{ - protected $ts; - - protected function setUp() - { - $this->ts = new PHP_Token_Stream(TEST_FILES_PATH . 'source3.php'); - } - - /** - * @covers PHP_Token_Includes::getName - * @covers PHP_Token_Includes::getType - */ - public function testGetIncludes() - { - $this->assertSame( - array('test4.php', 'test3.php', 'test2.php', 'test1.php'), - $this->ts->getIncludes() - ); - } - - /** - * @covers PHP_Token_Includes::getName - * @covers PHP_Token_Includes::getType - */ - public function testGetIncludesCategorized() - { - $this->assertSame( - array( - 'require_once' => array('test4.php'), - 'require' => array('test3.php'), - 'include_once' => array('test2.php'), - 'include' => array('test1.php') - ), - $this->ts->getIncludes(TRUE) - ); - } - - /** - * @covers PHP_Token_Includes::getName - * @covers PHP_Token_Includes::getType - */ - public function testGetIncludesCategory() - { - $this->assertSame( - array('test4.php'), - $this->ts->getIncludes(TRUE, 'require_once') - ); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/InterfaceTest.php b/vendor/phpunit/php-token-stream/tests/Token/InterfaceTest.php deleted file mode 100644 index 56caede2a..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/InterfaceTest.php +++ /dev/null @@ -1,191 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_INTERFACE class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Sebastian Bergmann - * @author Laurent Laville - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.0 - */ -class PHP_Token_InterfaceTest extends PHPUnit_Framework_TestCase -{ - protected $class; - protected $interfaces; - - protected function setUp() - { - $ts = new PHP_Token_Stream(TEST_FILES_PATH . 'source4.php'); - $i = 0; - foreach ($ts as $token) { - if ($token instanceof PHP_Token_CLASS) { - $this->class = $token; - } - elseif ($token instanceof PHP_Token_INTERFACE) { - $this->interfaces[$i] = $token; - $i++; - } - } - } - - /** - * @covers PHP_Token_INTERFACE::getName - */ - public function testGetName() - { - $this->assertEquals( - 'iTemplate', $this->interfaces[0]->getName() - ); - } - - /** - * @covers PHP_Token_INTERFACE::getParent - */ - public function testGetParentNotExists() - { - $this->assertFalse( - $this->interfaces[0]->getParent() - ); - } - - /** - * @covers PHP_Token_INTERFACE::hasParent - */ - public function testHasParentNotExists() - { - $this->assertFalse( - $this->interfaces[0]->hasParent() - ); - } - - /** - * @covers PHP_Token_INTERFACE::getParent - */ - public function testGetParentExists() - { - $this->assertEquals( - 'a', $this->interfaces[2]->getParent() - ); - } - - /** - * @covers PHP_Token_INTERFACE::hasParent - */ - public function testHasParentExists() - { - $this->assertTrue( - $this->interfaces[2]->hasParent() - ); - } - - /** - * @covers PHP_Token_INTERFACE::getInterfaces - */ - public function testGetInterfacesExists() - { - $this->assertEquals( - array('b'), - $this->class->getInterfaces() - ); - } - - /** - * @covers PHP_Token_INTERFACE::hasInterfaces - */ - public function testHasInterfacesExists() - { - $this->assertTrue( - $this->class->hasInterfaces() - ); - } - /** - * @covers PHP_Token_INTERFACE::getPackage - */ - public function testGetPackageNamespace() { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInNamespace.php'); - foreach($tokenStream as $token) { - if($token instanceOf PHP_Token_INTERFACE) { - $package = $token->getPackage(); - $this->assertSame('Foo\\Bar', $package['namespace']); - } - } - } - - - public function provideFilesWithClassesWithinMultipleNamespaces() { - return array( - array(TEST_FILES_PATH . 'multipleNamespacesWithOneClassUsingBraces.php'), - array(TEST_FILES_PATH . 'multipleNamespacesWithOneClassUsingNonBraceSyntax.php'), - ); - } - - /** - * @dataProvider provideFilesWithClassesWithinMultipleNamespaces - * @covers PHP_Token_INTERFACE::getPackage - */ - public function testGetPackageNamespaceForFileWithMultipleNamespaces($filepath) { - $tokenStream = new PHP_Token_Stream($filepath); - $firstClassFound = false; - foreach($tokenStream as $token) { - if($firstClassFound === false && $token instanceOf PHP_Token_INTERFACE) { - $package = $token->getPackage(); - $this->assertSame('TestClassInBar', $token->getName()); - $this->assertSame('Foo\\Bar', $package['namespace']); - $firstClassFound = true; - continue; - } - // Secound class - if($token instanceOf PHP_Token_INTERFACE) { - $package = $token->getPackage(); - $this->assertSame('TestClassInBaz', $token->getName()); - $this->assertSame('Foo\\Baz', $package['namespace']); - return; - } - } - $this->fail("Seachring for 2 classes failed"); - } - - public function testGetPackageNamespaceIsEmptyForInterfacesThatAreNotWithinNamespaces() { - foreach($this->interfaces as $token) { - $package = $token->getPackage(); - $this->assertSame("", $package['namespace']); - } - } - - /** - * @covers PHP_Token_INTERFACE::getPackage - */ - public function testGetPackageNamespaceWhenExtentingFromNamespaceClass() { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classExtendsNamespacedClass.php'); - $firstClassFound = false; - foreach($tokenStream as $token) { - if($firstClassFound === false && $token instanceOf PHP_Token_INTERFACE) { - $package = $token->getPackage(); - $this->assertSame('Baz', $token->getName()); - $this->assertSame('Foo\\Bar', $package['namespace']); - $firstClassFound = true; - continue; - } - if($token instanceOf PHP_Token_INTERFACE) { - $package = $token->getPackage(); - $this->assertSame('Extender', $token->getName()); - $this->assertSame('Other\\Space', $package['namespace']); - return; - } - } - $this->fail("Searching for 2 classes failed"); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php b/vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php deleted file mode 100644 index 469f78726..000000000 --- a/vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php +++ /dev/null @@ -1,80 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token_NAMESPACE class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Sebastian Bergmann - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.0 - */ -class PHP_Token_NamespaceTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHP_Token_NAMESPACE::getName - */ - public function testGetName() - { - $tokenStream = new PHP_Token_Stream( - TEST_FILES_PATH . 'classInNamespace.php' - ); - - foreach ($tokenStream as $token) { - if ($token instanceof PHP_Token_NAMESPACE) { - $this->assertSame('Foo\\Bar', $token->getName()); - } - } - } - - public function testGetStartLineWithUnscopedNamespace() - { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInNamespace.php'); - foreach($tokenStream as $token) { - if($token instanceOf PHP_Token_NAMESPACE) { - $this->assertSame(2, $token->getLine()); - } - } - } - - public function testGetEndLineWithUnscopedNamespace() - { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInNamespace.php'); - foreach($tokenStream as $token) { - if($token instanceOf PHP_Token_NAMESPACE) { - $this->assertSame(2, $token->getEndLine()); - } - } - } - public function testGetStartLineWithScopedNamespace() - { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInScopedNamespace.php'); - foreach($tokenStream as $token) { - if($token instanceOf PHP_Token_NAMESPACE) { - $this->assertSame(2, $token->getLine()); - } - } - } - - public function testGetEndLineWithScopedNamespace() - { - $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInScopedNamespace.php'); - foreach($tokenStream as $token) { - if($token instanceOf PHP_Token_NAMESPACE) { - $this->assertSame(8, $token->getEndLine()); - } - } - } - -} diff --git a/vendor/phpunit/php-token-stream/tests/TokenTest.php b/vendor/phpunit/php-token-stream/tests/TokenTest.php deleted file mode 100644 index 67bf79a05..000000000 --- a/vendor/phpunit/php-token-stream/tests/TokenTest.php +++ /dev/null @@ -1,42 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the PHP_Token class. - * - * @package PHP_TokenStream - * @subpackage Tests - * @author Sebastian Bergmann - * @copyright Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @version Release: @package_version@ - * @link http://github.com/sebastianbergmann/php-token-stream/ - * @since Class available since Release 1.0.0 - */ -class PHP_TokenTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHP_Token::__construct - * @covers PHP_Token::__toString - */ - public function testToString() - { - $this->markTestIncomplete(); - } - - /** - * @covers PHP_Token::__construct - * @covers PHP_Token::getLine - */ - public function testGetLine() - { - $this->markTestIncomplete(); - } -} diff --git a/vendor/phpunit/php-token-stream/tests/_fixture/classExtendsNamespacedClass.php b/vendor/phpunit/php-token-stream/tests/_fixture/classExtendsNamespacedClass.php deleted file mode 100644 index 560eec94c..000000000 --- a/vendor/phpunit/php-token-stream/tests/_fixture/classExtendsNamespacedClass.php +++ /dev/null @@ -1,10 +0,0 @@ -method_in_anonymous_class(); - } - - public function methodTwo() { - return false; - } -} diff --git a/vendor/phpunit/php-token-stream/tests/_fixture/closure.php b/vendor/phpunit/php-token-stream/tests/_fixture/closure.php deleted file mode 100644 index a0e3a81d6..000000000 --- a/vendor/phpunit/php-token-stream/tests/_fixture/closure.php +++ /dev/null @@ -1,7 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -class Extensions_PhptTestCaseTest extends \PHPUnit_Framework_TestCase -{ - public function testParseIniSection() - { - $phptTestCase = new PhpTestCaseProxy(__FILE__); - $settings = $phptTestCase->parseIniSection("foo=1\nbar = 2\rbaz = 3\r\nempty=\nignore"); - - $expected = array( - 'foo=1', - 'bar = 2', - 'baz = 3', - 'empty=', - 'ignore', - ); - - $this->assertEquals($expected, $settings); - - } -} - -class PhpTestCaseProxy extends PHPUnit_Extensions_PhptTestCase -{ - public function parseIniSection($content) - { - return parent::parseIniSection($content); - } -} diff --git a/vendor/phpunit/phpunit/tests/Extensions/RepeatedTestTest.php b/vendor/phpunit/phpunit/tests/Extensions/RepeatedTestTest.php deleted file mode 100644 index de83fb5fe..000000000 --- a/vendor/phpunit/phpunit/tests/Extensions/RepeatedTestTest.php +++ /dev/null @@ -1,64 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.0.0 - * @covers PHPUnit_Extensions_RepeatedTest - */ -class Extensions_RepeatedTestTest extends PHPUnit_Framework_TestCase -{ - protected $suite; - - public function __construct() - { - $this->suite = new PHPUnit_Framework_TestSuite; - - $this->suite->addTest(new Success); - $this->suite->addTest(new Success); - } - - public function testRepeatedOnce() - { - $test = new PHPUnit_Extensions_RepeatedTest($this->suite, 1); - $this->assertEquals(2, count($test)); - - $result = $test->run(); - $this->assertEquals(2, count($result)); - } - - public function testRepeatedMoreThanOnce() - { - $test = new PHPUnit_Extensions_RepeatedTest($this->suite, 3); - $this->assertEquals(6, count($test)); - - $result = $test->run(); - $this->assertEquals(6, count($result)); - } - - public function testRepeatedZero() - { - $test = new PHPUnit_Extensions_RepeatedTest($this->suite, 0); - $this->assertEquals(0, count($test)); - - $result = $test->run(); - $this->assertEquals(0, count($result)); - } - - public function testRepeatedNegative() - { - try { - $test = new PHPUnit_Extensions_RepeatedTest($this->suite, -1); - } catch (Exception $e) { - return; - } - - $this->fail('Should throw an Exception'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Fail/fail.phpt b/vendor/phpunit/phpunit/tests/Fail/fail.phpt deleted file mode 100644 index b88454fdf..000000000 --- a/vendor/phpunit/phpunit/tests/Fail/fail.phpt +++ /dev/null @@ -1,5 +0,0 @@ ---TEST-- -// This test intentionally fails and it is checked by Travis. ---FILE-- ---EXPECTF-- -unexpected diff --git a/vendor/phpunit/phpunit/tests/Framework/AssertTest.php b/vendor/phpunit/phpunit/tests/Framework/AssertTest.php deleted file mode 100644 index 3406be840..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/AssertTest.php +++ /dev/null @@ -1,4130 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.0.0 - */ -class Framework_AssertTest extends PHPUnit_Framework_TestCase -{ - /** - * @var string - */ - private $filesDirectory; - - protected function setUp() - { - $this->filesDirectory = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR; - } - - /** - * @covers PHPUnit_Framework_Assert::fail - */ - public function testFail() - { - try { - $this->fail(); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - throw new PHPUnit_Framework_AssertionFailedError('Fail did not throw fail exception'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertSplObjectStorageContainsObject() - { - $a = new stdClass; - $b = new stdClass; - $c = new SplObjectStorage; - $c->attach($a); - - $this->assertContains($a, $c); - - try { - $this->assertContains($b, $c); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertArrayContainsObject() - { - $a = new stdClass; - $b = new stdClass; - - $this->assertContains($a, array($a)); - - try { - $this->assertContains($a, array($b)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertArrayContainsString() - { - $this->assertContains('foo', array('foo')); - - try { - $this->assertContains('foo', array('bar')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertArrayContainsNonObject() - { - $this->assertContains('foo', array(true)); - - try { - $this->assertContains('foo', array(true), '', false, true, true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContainsOnlyInstancesOf - */ - public function testAssertContainsOnlyInstancesOf() - { - $test = array( - new Book(), - new Book - ); - $this->assertContainsOnlyInstancesOf('Book', $test); - $this->assertContainsOnlyInstancesOf('stdClass', array(new stdClass())); - - $test2 = array( - new Author('Test') - ); - try { - $this->assertContainsOnlyInstancesOf('Book', $test2); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertArrayHasKeyThrowsExceptionForInvalidFirstArgument() - { - $this->assertArrayHasKey(null, array()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertArrayHasKeyThrowsExceptionForInvalidSecondArgument() - { - $this->assertArrayHasKey(0, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - */ - public function testAssertArrayHasIntegerKey() - { - $this->assertArrayHasKey(0, array('foo')); - - try { - $this->assertArrayHasKey(1, array('foo')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArraySubset - * @covers PHPUnit_Framework_Constraint_ArraySubset - */ - public function testAssertArraySubset() - { - $array = array( - 'a' => 'item a', - 'b' => 'item b', - 'c' => array('a2' => 'item a2', 'b2' => 'item b2'), - 'd' => array('a2' => array('a3' => 'item a3', 'b3' => 'item b3')) - ); - - $this->assertArraySubset(array('a' => 'item a', 'c' => array('a2' => 'item a2')), $array); - $this->assertArraySubset(array('a' => 'item a', 'd' => array('a2' => array('b3' => 'item b3'))), $array); - - try { - $this->assertArraySubset(array('a' => 'bad value'), $array); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - } - - try { - $this->assertArraySubset(array('d' => array('a2' => array('bad index' => 'item b3'))), $array); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArraySubset - * @covers PHPUnit_Framework_Constraint_ArraySubset - */ - public function testAssertArraySubsetWithDeepNestedArrays() - { - $array = array( - 'path' => array( - 'to' => array( - 'the' => array( - 'cake' => 'is a lie' - ) - ) - ) - ); - - $this->assertArraySubset(array('path' => array()), $array); - $this->assertArraySubset(array('path' => array('to' => array())), $array); - $this->assertArraySubset(array('path' => array('to' => array('the' => array()))), $array); - $this->assertArraySubset(array('path' => array('to' => array('the' => array('cake' => 'is a lie')))), $array); - - try { - $this->assertArraySubset(array('path' => array('to' => array('the' => array('cake' => 'is not a lie')))), $array); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArraySubset - * @covers PHPUnit_Framework_Constraint_ArraySubset - */ - public function testAssertArraySubsetWithNoStrictCheckAndObjects() - { - $obj = new \stdClass; - $reference = &$obj; - $array = array('a' => $obj); - - $this->assertArraySubset(array('a' => $reference), $array); - $this->assertArraySubset(array('a' => new \stdClass), $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArraySubset - * @covers PHPUnit_Framework_Constraint_ArraySubset - */ - public function testAssertArraySubsetWithStrictCheckAndObjects() - { - $obj = new \stdClass; - $reference = &$obj; - $array = array('a' => $obj); - - $this->assertArraySubset(array('a' => $reference), $array, true); - - try { - $this->assertArraySubset(array('a' => new \stdClass), $array, true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail('Strict recursive array check fail.'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArraySubset - * @covers PHPUnit_Framework_Constraint_ArraySubset - * @expectedException PHPUnit_Framework_Exception - * @expectedExceptionMessage array or ArrayAccess - * @dataProvider assertArraySubsetInvalidArgumentProvider - */ - public function testAssertArraySubsetRaisesExceptionForInvalidArguments($partial, $subject) - { - $this->assertArraySubset($partial, $subject); - } - - /** - * @return array - */ - public function assertArraySubsetInvalidArgumentProvider() - { - return array( - array(false, array()), - array(array(), false), - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertArrayNotHasKeyThrowsExceptionForInvalidFirstArgument() - { - $this->assertArrayNotHasKey(null, array()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertArrayNotHasKeyThrowsExceptionForInvalidSecondArgument() - { - $this->assertArrayNotHasKey(0, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - */ - public function testAssertArrayNotHasIntegerKey() - { - $this->assertArrayNotHasKey(1, array('foo')); - - try { - $this->assertArrayNotHasKey(0, array('foo')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - */ - public function testAssertArrayHasStringKey() - { - $this->assertArrayHasKey('foo', array('foo' => 'bar')); - - try { - $this->assertArrayHasKey('bar', array('foo' => 'bar')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - */ - public function testAssertArrayNotHasStringKey() - { - $this->assertArrayNotHasKey('bar', array('foo' => 'bar')); - - try { - $this->assertArrayNotHasKey('foo', array('foo' => 'bar')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - */ - public function testAssertArrayHasKeyAcceptsArrayObjectValue() - { - $array = new ArrayObject(); - $array['foo'] = 'bar'; - $this->assertArrayHasKey('foo', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - * @expectedException PHPUnit_Framework_AssertionFailedError - */ - public function testAssertArrayHasKeyProperlyFailsWithArrayObjectValue() - { - $array = new ArrayObject(); - $array['bar'] = 'bar'; - $this->assertArrayHasKey('foo', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - */ - public function testAssertArrayHasKeyAcceptsArrayAccessValue() - { - $array = new SampleArrayAccess(); - $array['foo'] = 'bar'; - $this->assertArrayHasKey('foo', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayHasKey - * @expectedException PHPUnit_Framework_AssertionFailedError - */ - public function testAssertArrayHasKeyProperlyFailsWithArrayAccessValue() - { - $array = new SampleArrayAccess(); - $array['bar'] = 'bar'; - $this->assertArrayHasKey('foo', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - */ - public function testAssertArrayNotHasKeyAcceptsArrayAccessValue() - { - $array = new ArrayObject(); - $array['foo'] = 'bar'; - $this->assertArrayNotHasKey('bar', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertArrayNotHasKey - * @expectedException PHPUnit_Framework_AssertionFailedError - */ - public function testAssertArrayNotHasKeyPropertlyFailsWithArrayAccessValue() - { - $array = new ArrayObject(); - $array['bar'] = 'bar'; - $this->assertArrayNotHasKey('bar', $array); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertContainsThrowsException() - { - $this->assertContains(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertIteratorContainsObject() - { - $foo = new stdClass; - - $this->assertContains($foo, new TestIterator(array($foo))); - - try { - $this->assertContains($foo, new TestIterator(array(new stdClass))); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertIteratorContainsString() - { - $this->assertContains('foo', new TestIterator(array('foo'))); - - try { - $this->assertContains('foo', new TestIterator(array('bar'))); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContains - */ - public function testAssertStringContainsString() - { - $this->assertContains('foo', 'foobar'); - - try { - $this->assertContains('foo', 'bar'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotContainsThrowsException() - { - $this->assertNotContains(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - */ - public function testAssertSplObjectStorageNotContainsObject() - { - $a = new stdClass; - $b = new stdClass; - $c = new SplObjectStorage; - $c->attach($a); - - $this->assertNotContains($b, $c); - - try { - $this->assertNotContains($a, $c); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - */ - public function testAssertArrayNotContainsObject() - { - $a = new stdClass; - $b = new stdClass; - - $this->assertNotContains($a, array($b)); - - try { - $this->assertNotContains($a, array($a)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - */ - public function testAssertArrayNotContainsString() - { - $this->assertNotContains('foo', array('bar')); - - try { - $this->assertNotContains('foo', array('foo')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - */ - public function testAssertArrayNotContainsNonObject() - { - $this->assertNotContains('foo', array(true), '', false, true, true); - - try { - $this->assertNotContains('foo', array(true)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContains - */ - public function testAssertStringNotContainsString() - { - $this->assertNotContains('foo', 'bar'); - - try { - $this->assertNotContains('foo', 'foo'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContainsOnly - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertContainsOnlyThrowsException() - { - $this->assertContainsOnly(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContainsOnly - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotContainsOnlyThrowsException() - { - $this->assertNotContainsOnly(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContainsOnlyInstancesOf - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertContainsOnlyInstancesOfThrowsException() - { - $this->assertContainsOnlyInstancesOf(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContainsOnly - */ - public function testAssertArrayContainsOnlyIntegers() - { - $this->assertContainsOnly('integer', array(1, 2, 3)); - - try { - $this->assertContainsOnly('integer', array('1', 2, 3)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContainsOnly - */ - public function testAssertArrayNotContainsOnlyIntegers() - { - $this->assertNotContainsOnly('integer', array('1', 2, 3)); - - try { - $this->assertNotContainsOnly('integer', array(1, 2, 3)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertContainsOnly - */ - public function testAssertArrayContainsOnlyStdClass() - { - $this->assertContainsOnly('StdClass', array(new stdClass)); - - try { - $this->assertContainsOnly('StdClass', array('StdClass')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotContainsOnly - */ - public function testAssertArrayNotContainsOnlyStdClass() - { - $this->assertNotContainsOnly('StdClass', array('StdClass')); - - try { - $this->assertNotContainsOnly('StdClass', array(new stdClass)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - protected function sameValues() - { - $object = new SampleClass(4, 8, 15); - // cannot use $filesDirectory, because neither setUp() nor - // setUpBeforeClass() are executed before the data providers - $file = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'foo.xml'; - $resource = fopen($file, 'r'); - - return array( - // null - array(null, null), - // strings - array('a', 'a'), - // integers - array(0, 0), - // floats - array(2.3, 2.3), - array(1/3, 1 - 2/3), - array(log(0), log(0)), - // arrays - array(array(), array()), - array(array(0 => 1), array(0 => 1)), - array(array(0 => null), array(0 => null)), - array(array('a', 'b' => array(1, 2)), array('a', 'b' => array(1, 2))), - // objects - array($object, $object), - // resources - array($resource, $resource), - ); - } - - protected function notEqualValues() - { - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratch'); - $book2->author->books[] = $book2; - - $book3 = new Book; - $book3->author = 'Terry Pratchett'; - $book4 = new stdClass; - $book4->author = 'Terry Pratchett'; - - $object1 = new SampleClass(4, 8, 15); - $object2 = new SampleClass(16, 23, 42); - $object3 = new SampleClass(4, 8, 15); - $storage1 = new SplObjectStorage; - $storage1->attach($object1); - $storage2 = new SplObjectStorage; - $storage2->attach($object3); // same content, different object - - // cannot use $filesDirectory, because neither setUp() nor - // setUpBeforeClass() are executed before the data providers - $file = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'foo.xml'; - - return array( - // strings - array('a', 'b'), - array('a', 'A'), - // https://github.com/sebastianbergmann/phpunit/issues/1023 - array('9E6666666','9E7777777'), - // integers - array(1, 2), - array(2, 1), - // floats - array(2.3, 4.2), - array(2.3, 4.2, 0.5), - array(array(2.3), array(4.2), 0.5), - array(array(array(2.3)), array(array(4.2)), 0.5), - array(new Struct(2.3), new Struct(4.2), 0.5), - array(array(new Struct(2.3)), array(new Struct(4.2)), 0.5), - // NAN - array(NAN, NAN), - // arrays - array(array(), array(0 => 1)), - array(array(0 => 1), array()), - array(array(0 => null), array()), - array(array(0 => 1, 1 => 2), array(0 => 1, 1 => 3)), - array(array('a', 'b' => array(1, 2)), array('a', 'b' => array(2, 1))), - // objects - array(new SampleClass(4, 8, 15), new SampleClass(16, 23, 42)), - array($object1, $object2), - array($book1, $book2), - array($book3, $book4), // same content, different class - // resources - array(fopen($file, 'r'), fopen($file, 'r')), - // SplObjectStorage - array($storage1, $storage2), - // DOMDocument - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(' bar '), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(' bar '), - PHPUnit_Util_XML::load(' bir '), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')), - 3500 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 05:13:35', new DateTimeZone('America/New_York')), - 3500 - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - 43200 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - 3500 - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T04:13:35-0600'), - ), - array( - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T05:13:35-0500'), - ), - // Exception - //array(new Exception('Exception 1'), new Exception('Exception 2')), - // different types - array(new SampleClass(4, 8, 15), false), - array(false, new SampleClass(4, 8, 15)), - array(array(0 => 1, 1 => 2), false), - array(false, array(0 => 1, 1 => 2)), - array(array(), new stdClass), - array(new stdClass, array()), - // PHP: 0 == 'Foobar' => true! - // We want these values to differ - array(0, 'Foobar'), - array('Foobar', 0), - array(3, acos(8)), - array(acos(8), 3) - ); - } - - protected function equalValues() - { - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratchett'); - $book2->author->books[] = $book2; - - $object1 = new SampleClass(4, 8, 15); - $object2 = new SampleClass(4, 8, 15); - $storage1 = new SplObjectStorage; - $storage1->attach($object1); - $storage2 = new SplObjectStorage; - $storage2->attach($object1); - - return array( - // strings - array('a', 'A', 0, false, true), // ignore case - // arrays - array(array('a' => 1, 'b' => 2), array('b' => 2, 'a' => 1)), - array(array(1), array('1')), - array(array(3, 2, 1), array(2, 3, 1), 0, true), // canonicalized comparison - // floats - array(2.3, 2.5, 0.5), - array(array(2.3), array(2.5), 0.5), - array(array(array(2.3)), array(array(2.5)), 0.5), - array(new Struct(2.3), new Struct(2.5), 0.5), - array(array(new Struct(2.3)), array(new Struct(2.5)), 0.5), - // numeric with delta - array(1, 2, 1), - // objects - array($object1, $object2), - array($book1, $book2), - // SplObjectStorage - array($storage1, $storage2), - // DOMDocument - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load(''), - PHPUnit_Util_XML::load(''), - ), - array( - PHPUnit_Util_XML::load("\n \n"), - PHPUnit_Util_XML::load(''), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:25', new DateTimeZone('America/New_York')), - 10 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:14:40', new DateTimeZone('America/New_York')), - 65 - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:49', new DateTimeZone('America/Chicago')), - 15 - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:01:30', new DateTimeZone('America/Chicago')), - 100 - ), - array( - new DateTime('@1364616000'), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-29T05:13:35-0500'), - new DateTime('2013-03-29T04:13:35-0600'), - ), - // Exception - //array(new Exception('Exception 1'), new Exception('Exception 1')), - // mixed types - array(0, '0'), - array('0', 0), - array(2.3, '2.3'), - array('2.3', 2.3), - array((string) (1/3), 1 - 2/3), - array(1/3, (string) (1 - 2/3)), - array('string representation', new ClassWithToString), - array(new ClassWithToString, 'string representation'), - ); - } - - public function equalProvider() - { - // same |= equal - return array_merge($this->equalValues(), $this->sameValues()); - } - - public function notEqualProvider() - { - return $this->notEqualValues(); - } - - public function sameProvider() - { - return $this->sameValues(); - } - - public function notSameProvider() - { - // not equal |= not same - // equal, ¬same |= not same - return array_merge($this->notEqualValues(), $this->equalValues()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEquals - * @dataProvider equalProvider - */ - public function testAssertEqualsSucceeds($a, $b, $delta = 0.0, $canonicalize = false, $ignoreCase = false) - { - $this->assertEquals($a, $b, '', $delta, 10, $canonicalize, $ignoreCase); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEquals - * @dataProvider notEqualProvider - */ - public function testAssertEqualsFails($a, $b, $delta = 0.0, $canonicalize = false, $ignoreCase = false) - { - try { - $this->assertEquals($a, $b, '', $delta, 10, $canonicalize, $ignoreCase); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotEquals - * @dataProvider notEqualProvider - */ - public function testAssertNotEqualsSucceeds($a, $b, $delta = 0.0, $canonicalize = false, $ignoreCase = false) - { - $this->assertNotEquals($a, $b, '', $delta, 10, $canonicalize, $ignoreCase); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotEquals - * @dataProvider equalProvider - */ - public function testAssertNotEqualsFails($a, $b, $delta = 0.0, $canonicalize = false, $ignoreCase = false) - { - try { - $this->assertNotEquals($a, $b, '', $delta, 10, $canonicalize, $ignoreCase); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSame - * @dataProvider sameProvider - */ - public function testAssertSameSucceeds($a, $b) - { - $this->assertSame($a, $b); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSame - * @dataProvider notSameProvider - */ - public function testAssertSameFails($a, $b) - { - try { - $this->assertSame($a, $b); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSame - * @dataProvider notSameProvider - */ - public function testAssertNotSameSucceeds($a, $b) - { - $this->assertNotSame($a, $b); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSame - * @dataProvider sameProvider - */ - public function testAssertNotSameFails($a, $b) - { - try { - $this->assertNotSame($a, $b); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlFileEqualsXmlFile - */ - public function testAssertXmlFileEqualsXmlFile() - { - $this->assertXmlFileEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'foo.xml' - ); - - try { - $this->assertXmlFileEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'bar.xml' - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlFileNotEqualsXmlFile - */ - public function testAssertXmlFileNotEqualsXmlFile() - { - $this->assertXmlFileNotEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'bar.xml' - ); - - try { - $this->assertXmlFileNotEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'foo.xml' - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlStringEqualsXmlFile - */ - public function testAssertXmlStringEqualsXmlFile() - { - $this->assertXmlStringEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'foo.xml') - ); - - try { - $this->assertXmlStringEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'bar.xml') - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlStringNotEqualsXmlFile - */ - public function testXmlStringNotEqualsXmlFile() - { - $this->assertXmlStringNotEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'bar.xml') - ); - - try { - $this->assertXmlStringNotEqualsXmlFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'foo.xml') - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlStringEqualsXmlString - */ - public function testAssertXmlStringEqualsXmlString() - { - $this->assertXmlStringEqualsXmlString('', ''); - - try { - $this->assertXmlStringEqualsXmlString('', ''); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @expectedException PHPUnit_Framework_Exception - * @covers PHPUnit_Framework_Assert::assertXmlStringEqualsXmlString - * @ticket 1860 - */ - public function testAssertXmlStringEqualsXmlString2() - { - $this->assertXmlStringEqualsXmlString('', ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlStringEqualsXmlString - * @ticket 1860 - */ - public function testAssertXmlStringEqualsXmlString3() - { - $expected = << - - - -XML; - - $actual = << - - - -XML; - - $this->assertXmlStringEqualsXmlString($expected, $actual); - } - - /** - * @covers PHPUnit_Framework_Assert::assertXmlStringNotEqualsXmlString - */ - public function testAssertXmlStringNotEqualsXmlString() - { - $this->assertXmlStringNotEqualsXmlString('', ''); - - try { - $this->assertXmlStringNotEqualsXmlString('', ''); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - */ - public function testXMLStructureIsSame() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureExpected.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - * @expectedException PHPUnit_Framework_ExpectationFailedException - */ - public function testXMLStructureWrongNumberOfAttributes() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureWrongNumberOfAttributes.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - * @expectedException PHPUnit_Framework_ExpectationFailedException - */ - public function testXMLStructureWrongNumberOfNodes() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureWrongNumberOfNodes.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - */ - public function testXMLStructureIsSameButDataIsNot() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureIsSameButDataIsNot.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - */ - public function testXMLStructureAttributesAreSameButValuesAreNot() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureAttributesAreSameButValuesAreNot.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEqualXMLStructure - */ - public function testXMLStructureIgnoreTextNodes() - { - $expected = new DOMDocument; - $expected->load($this->filesDirectory . 'structureExpected.xml'); - - $actual = new DOMDocument; - $actual->load($this->filesDirectory . 'structureIgnoreTextNodes.xml'); - - $this->assertEqualXMLStructure( - $expected->firstChild, $actual->firstChild, true - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEquals - */ - public function testAssertStringEqualsNumeric() - { - $this->assertEquals('0', 0); - - try { - $this->assertEquals('0', 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotEquals - */ - public function testAssertStringEqualsNumeric2() - { - $this->assertNotEquals('A', 0); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileExists - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertFileExistsThrowsException() - { - $this->assertFileExists(null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileExists - */ - public function testAssertFileExists() - { - $this->assertFileExists(__FILE__); - - try { - $this->assertFileExists(__DIR__ . DIRECTORY_SEPARATOR . 'NotExisting'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileNotExists - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertFileNotExistsThrowsException() - { - $this->assertFileNotExists(null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileNotExists - */ - public function testAssertFileNotExists() - { - $this->assertFileNotExists(__DIR__ . DIRECTORY_SEPARATOR . 'NotExisting'); - - try { - $this->assertFileNotExists(__FILE__); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - */ - public function testAssertObjectHasAttribute() - { - $o = new Author('Terry Pratchett'); - - $this->assertObjectHasAttribute('name', $o); - - try { - $this->assertObjectHasAttribute('foo', $o); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - */ - public function testAssertObjectNotHasAttribute() - { - $o = new Author('Terry Pratchett'); - - $this->assertObjectNotHasAttribute('foo', $o); - - try { - $this->assertObjectNotHasAttribute('name', $o); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNull - */ - public function testAssertNull() - { - $this->assertNull(null); - - try { - $this->assertNull(new stdClass); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotNull - */ - public function testAssertNotNull() - { - $this->assertNotNull(new stdClass); - - try { - $this->assertNotNull(null); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertTrue - */ - public function testAssertTrue() - { - $this->assertTrue(true); - - try { - $this->assertTrue(false); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotTrue - */ - public function testAssertNotTrue() - { - $this->assertNotTrue(false); - $this->assertNotTrue(1); - $this->assertNotTrue('true'); - - try { - $this->assertNotTrue(true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFalse - */ - public function testAssertFalse() - { - $this->assertFalse(false); - - try { - $this->assertFalse(true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotFalse - */ - public function testAssertNotFalse() - { - $this->assertNotFalse(true); - $this->assertNotFalse(0); - $this->assertNotFalse(''); - - try { - $this->assertNotFalse(false); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertRegExp - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertRegExpThrowsException() - { - $this->assertRegExp(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertRegExp - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertRegExpThrowsException2() - { - $this->assertRegExp('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotRegExp - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotRegExpThrowsException() - { - $this->assertNotRegExp(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotRegExp - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotRegExpThrowsException2() - { - $this->assertNotRegExp('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertRegExp - */ - public function testAssertRegExp() - { - $this->assertRegExp('/foo/', 'foobar'); - - try { - $this->assertRegExp('/foo/', 'bar'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotRegExp - */ - public function testAssertNotRegExp() - { - $this->assertNotRegExp('/foo/', 'bar'); - - try { - $this->assertNotRegExp('/foo/', 'foobar'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSame - */ - public function testAssertSame() - { - $o = new stdClass; - - $this->assertSame($o, $o); - - try { - $this->assertSame( - new stdClass, - new stdClass - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSame - */ - public function testAssertSame2() - { - $this->assertSame(true, true); - $this->assertSame(false, false); - - try { - $this->assertSame(true, false); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSame - */ - public function testAssertNotSame() - { - $this->assertNotSame( - new stdClass, - null - ); - - $this->assertNotSame( - null, - new stdClass - ); - - $this->assertNotSame( - new stdClass, - new stdClass - ); - - $o = new stdClass; - - try { - $this->assertNotSame($o, $o); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSame - */ - public function testAssertNotSame2() - { - $this->assertNotSame(true, false); - $this->assertNotSame(false, true); - - try { - $this->assertNotSame(true, true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSame - */ - public function testAssertNotSameFailsNull() - { - try { - $this->assertNotSame(null, null); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertGreaterThan - */ - public function testGreaterThan() - { - $this->assertGreaterThan(1, 2); - - try { - $this->assertGreaterThan(2, 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeGreaterThan - */ - public function testAttributeGreaterThan() - { - $this->assertAttributeGreaterThan( - 1, 'bar', new ClassWithNonPublicAttributes - ); - - try { - $this->assertAttributeGreaterThan( - 1, 'foo', new ClassWithNonPublicAttributes - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertGreaterThanOrEqual - */ - public function testGreaterThanOrEqual() - { - $this->assertGreaterThanOrEqual(1, 2); - - try { - $this->assertGreaterThanOrEqual(2, 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeGreaterThanOrEqual - */ - public function testAttributeGreaterThanOrEqual() - { - $this->assertAttributeGreaterThanOrEqual( - 1, 'bar', new ClassWithNonPublicAttributes - ); - - try { - $this->assertAttributeGreaterThanOrEqual( - 2, 'foo', new ClassWithNonPublicAttributes - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertLessThan - */ - public function testLessThan() - { - $this->assertLessThan(2, 1); - - try { - $this->assertLessThan(1, 2); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeLessThan - */ - public function testAttributeLessThan() - { - $this->assertAttributeLessThan( - 2, 'foo', new ClassWithNonPublicAttributes - ); - - try { - $this->assertAttributeLessThan( - 1, 'bar', new ClassWithNonPublicAttributes - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertLessThanOrEqual - */ - public function testLessThanOrEqual() - { - $this->assertLessThanOrEqual(2, 1); - - try { - $this->assertLessThanOrEqual(1, 2); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeLessThanOrEqual - */ - public function testAttributeLessThanOrEqual() - { - $this->assertAttributeLessThanOrEqual( - 2, 'foo', new ClassWithNonPublicAttributes - ); - - try { - $this->assertAttributeLessThanOrEqual( - 1, 'bar', new ClassWithNonPublicAttributes - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - */ - public function testReadAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertEquals('foo', $this->readAttribute($obj, 'publicAttribute')); - $this->assertEquals('bar', $this->readAttribute($obj, 'protectedAttribute')); - $this->assertEquals('baz', $this->readAttribute($obj, 'privateAttribute')); - $this->assertEquals('bar', $this->readAttribute($obj, 'protectedParentAttribute')); - //$this->assertEquals('bar', $this->readAttribute($obj, 'privateParentAttribute')); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - */ - public function testReadAttribute2() - { - $this->assertEquals('foo', $this->readAttribute('ClassWithNonPublicAttributes', 'publicStaticAttribute')); - $this->assertEquals('bar', $this->readAttribute('ClassWithNonPublicAttributes', 'protectedStaticAttribute')); - $this->assertEquals('baz', $this->readAttribute('ClassWithNonPublicAttributes', 'privateStaticAttribute')); - $this->assertEquals('foo', $this->readAttribute('ClassWithNonPublicAttributes', 'protectedStaticParentAttribute')); - $this->assertEquals('foo', $this->readAttribute('ClassWithNonPublicAttributes', 'privateStaticParentAttribute')); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testReadAttribute3() - { - $this->readAttribute('StdClass', null); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testReadAttribute4() - { - $this->readAttribute('NotExistingClass', 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testReadAttribute5() - { - $this->readAttribute(null, 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::readAttribute - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testReadAttributeIfAttributeNameIsNotValid() - { - $this->readAttribute('StdClass', '2'); - } - - /** - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetStaticAttributeRaisesExceptionForInvalidFirstArgument() - { - $this->getStaticAttribute(null, 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetStaticAttributeRaisesExceptionForInvalidFirstArgument2() - { - $this->getStaticAttribute('NotExistingClass', 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetStaticAttributeRaisesExceptionForInvalidSecondArgument() - { - $this->getStaticAttribute('stdClass', null); - } - - /** - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetStaticAttributeRaisesExceptionForInvalidSecondArgument2() - { - $this->getStaticAttribute('stdClass', '0'); - } - - /** - * @covers PHPUnit_Framework_Assert::getStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetStaticAttributeRaisesExceptionForInvalidSecondArgument3() - { - $this->getStaticAttribute('stdClass', 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetObjectAttributeRaisesExceptionForInvalidFirstArgument() - { - $this->getObjectAttribute(null, 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetObjectAttributeRaisesExceptionForInvalidSecondArgument() - { - $this->getObjectAttribute(new stdClass, null); - } - - /** - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetObjectAttributeRaisesExceptionForInvalidSecondArgument2() - { - $this->getObjectAttribute(new stdClass, '0'); - } - - /** - * @covers PHPUnit_Framework_Assert::getObjectAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testGetObjectAttributeRaisesExceptionForInvalidSecondArgument3() - { - $this->getObjectAttribute(new stdClass, 'foo'); - } - - /** - * @covers PHPUnit_Framework_Assert::getObjectAttribute - */ - public function testGetObjectAttributeWorksForInheritedAttributes() - { - $this->assertEquals( - 'bar', - $this->getObjectAttribute(new ClassWithNonPublicAttributes, 'privateParentAttribute') - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeContains - */ - public function testAssertPublicAttributeContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeContains('foo', 'publicArray', $obj); - - try { - $this->assertAttributeContains('bar', 'publicArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeContainsOnly - */ - public function testAssertPublicAttributeContainsOnly() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeContainsOnly('string', 'publicArray', $obj); - - try { - $this->assertAttributeContainsOnly('integer', 'publicArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotContains - */ - public function testAssertPublicAttributeNotContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotContains('bar', 'publicArray', $obj); - - try { - $this->assertAttributeNotContains('foo', 'publicArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotContainsOnly - */ - public function testAssertPublicAttributeNotContainsOnly() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotContainsOnly('integer', 'publicArray', $obj); - - try { - $this->assertAttributeNotContainsOnly('string', 'publicArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeContains - */ - public function testAssertProtectedAttributeContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeContains('bar', 'protectedArray', $obj); - - try { - $this->assertAttributeContains('foo', 'protectedArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotContains - */ - public function testAssertProtectedAttributeNotContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotContains('foo', 'protectedArray', $obj); - - try { - $this->assertAttributeNotContains('bar', 'protectedArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeContains - */ - public function testAssertPrivateAttributeContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeContains('baz', 'privateArray', $obj); - - try { - $this->assertAttributeContains('foo', 'privateArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotContains - */ - public function testAssertPrivateAttributeNotContains() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotContains('foo', 'privateArray', $obj); - - try { - $this->assertAttributeNotContains('baz', 'privateArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeContains - */ - public function testAssertAttributeContainsNonObject() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeContains(true, 'privateArray', $obj); - - try { - $this->assertAttributeContains(true, 'privateArray', $obj, '', false, true, true); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotContains - */ - public function testAssertAttributeNotContainsNonObject() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotContains(true, 'privateArray', $obj, '', false, true, true); - - try { - $this->assertAttributeNotContains(true, 'privateArray', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertPublicAttributeEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeEquals('foo', 'publicAttribute', $obj); - - try { - $this->assertAttributeEquals('bar', 'publicAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertPublicAttributeNotEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotEquals('bar', 'publicAttribute', $obj); - - try { - $this->assertAttributeNotEquals('foo', 'publicAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeSame - */ - public function testAssertPublicAttributeSame() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeSame('foo', 'publicAttribute', $obj); - - try { - $this->assertAttributeSame('bar', 'publicAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotSame - */ - public function testAssertPublicAttributeNotSame() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotSame('bar', 'publicAttribute', $obj); - - try { - $this->assertAttributeNotSame('foo', 'publicAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertProtectedAttributeEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeEquals('bar', 'protectedAttribute', $obj); - - try { - $this->assertAttributeEquals('foo', 'protectedAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertProtectedAttributeNotEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotEquals('foo', 'protectedAttribute', $obj); - - try { - $this->assertAttributeNotEquals('bar', 'protectedAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertPrivateAttributeEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeEquals('baz', 'privateAttribute', $obj); - - try { - $this->assertAttributeEquals('foo', 'privateAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertPrivateAttributeNotEquals() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertAttributeNotEquals('foo', 'privateAttribute', $obj); - - try { - $this->assertAttributeNotEquals('baz', 'privateAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertPublicStaticAttributeEquals() - { - $this->assertAttributeEquals('foo', 'publicStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeEquals('bar', 'publicStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertPublicStaticAttributeNotEquals() - { - $this->assertAttributeNotEquals('bar', 'publicStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeNotEquals('foo', 'publicStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertProtectedStaticAttributeEquals() - { - $this->assertAttributeEquals('bar', 'protectedStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeEquals('foo', 'protectedStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertProtectedStaticAttributeNotEquals() - { - $this->assertAttributeNotEquals('foo', 'protectedStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeNotEquals('bar', 'protectedStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEquals - */ - public function testAssertPrivateStaticAttributeEquals() - { - $this->assertAttributeEquals('baz', 'privateStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeEquals('foo', 'privateStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEquals - */ - public function testAssertPrivateStaticAttributeNotEquals() - { - $this->assertAttributeNotEquals('foo', 'privateStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertAttributeNotEquals('baz', 'privateStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasAttributeThrowsException() - { - $this->assertClassHasAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasAttributeThrowsException2() - { - $this->assertClassHasAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertClassHasAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasAttributeThrowsException() - { - $this->assertClassNotHasAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasAttributeThrowsException2() - { - $this->assertClassNotHasAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertClassNotHasAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasStaticAttributeThrowsException() - { - $this->assertClassHasStaticAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasStaticAttributeThrowsException2() - { - $this->assertClassHasStaticAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassHasStaticAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertClassHasStaticAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasStaticAttributeThrowsException() - { - $this->assertClassNotHasStaticAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasStaticAttributeThrowsException2() - { - $this->assertClassNotHasStaticAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasStaticAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertClassNotHasStaticAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertClassNotHasStaticAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectHasAttributeThrowsException() - { - $this->assertObjectHasAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectHasAttributeThrowsException2() - { - $this->assertObjectHasAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectHasAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertObjectHasAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectNotHasAttributeThrowsException() - { - $this->assertObjectNotHasAttribute(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectNotHasAttributeThrowsException2() - { - $this->assertObjectNotHasAttribute('foo', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertObjectNotHasAttributeThrowsExceptionIfAttributeNameIsNotValid() - { - $this->assertObjectNotHasAttribute('1', 'ClassWithNonPublicAttributes'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasAttribute - */ - public function testClassHasPublicAttribute() - { - $this->assertClassHasAttribute('publicAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertClassHasAttribute('attribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasAttribute - */ - public function testClassNotHasPublicAttribute() - { - $this->assertClassNotHasAttribute('attribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertClassNotHasAttribute('publicAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassHasStaticAttribute - */ - public function testClassHasPublicStaticAttribute() - { - $this->assertClassHasStaticAttribute('publicStaticAttribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertClassHasStaticAttribute('attribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertClassNotHasStaticAttribute - */ - public function testClassNotHasPublicStaticAttribute() - { - $this->assertClassNotHasStaticAttribute('attribute', 'ClassWithNonPublicAttributes'); - - try { - $this->assertClassNotHasStaticAttribute('publicStaticAttribute', 'ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - */ - public function testObjectHasPublicAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectHasAttribute('publicAttribute', $obj); - - try { - $this->assertObjectHasAttribute('attribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - */ - public function testObjectNotHasPublicAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectNotHasAttribute('attribute', $obj); - - try { - $this->assertObjectNotHasAttribute('publicAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - */ - public function testObjectHasOnTheFlyAttribute() - { - $obj = new stdClass; - $obj->foo = 'bar'; - - $this->assertObjectHasAttribute('foo', $obj); - - try { - $this->assertObjectHasAttribute('bar', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - */ - public function testObjectNotHasOnTheFlyAttribute() - { - $obj = new stdClass; - $obj->foo = 'bar'; - - $this->assertObjectNotHasAttribute('bar', $obj); - - try { - $this->assertObjectNotHasAttribute('foo', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - */ - public function testObjectHasProtectedAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectHasAttribute('protectedAttribute', $obj); - - try { - $this->assertObjectHasAttribute('attribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - */ - public function testObjectNotHasProtectedAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectNotHasAttribute('attribute', $obj); - - try { - $this->assertObjectNotHasAttribute('protectedAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectHasAttribute - */ - public function testObjectHasPrivateAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectHasAttribute('privateAttribute', $obj); - - try { - $this->assertObjectHasAttribute('attribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertObjectNotHasAttribute - */ - public function testObjectNotHasPrivateAttribute() - { - $obj = new ClassWithNonPublicAttributes; - - $this->assertObjectNotHasAttribute('attribute', $obj); - - try { - $this->assertObjectNotHasAttribute('privateAttribute', $obj); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::attribute - * @covers PHPUnit_Framework_Assert::equalTo - */ - public function testAssertThatAttributeEquals() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->attribute( - $this->equalTo('foo'), - 'publicAttribute' - ) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::attribute - * @covers PHPUnit_Framework_Assert::equalTo - * @expectedException PHPUnit_Framework_AssertionFailedError - */ - public function testAssertThatAttributeEquals2() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->attribute( - $this->equalTo('bar'), - 'publicAttribute' - ) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::attribute - * @covers PHPUnit_Framework_Assert::equalTo - */ - public function testAssertThatAttributeEqualTo() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->attributeEqualTo('publicAttribute', 'foo') - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::anything - */ - public function testAssertThatAnything() - { - $this->assertThat('anything', $this->anything()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isTrue - */ - public function testAssertThatIsTrue() - { - $this->assertThat(true, $this->isTrue()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isFalse - */ - public function testAssertThatIsFalse() - { - $this->assertThat(false, $this->isFalse()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isJson - */ - public function testAssertThatIsJson() - { - $this->assertThat('{}', $this->isJson()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::anything - * @covers PHPUnit_Framework_Assert::logicalAnd - */ - public function testAssertThatAnythingAndAnything() - { - $this->assertThat( - 'anything', - $this->logicalAnd( - $this->anything(), $this->anything() - ) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::anything - * @covers PHPUnit_Framework_Assert::logicalOr - */ - public function testAssertThatAnythingOrAnything() - { - $this->assertThat( - 'anything', - $this->logicalOr( - $this->anything(), $this->anything() - ) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::anything - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Assert::logicalXor - */ - public function testAssertThatAnythingXorNotAnything() - { - $this->assertThat( - 'anything', - $this->logicalXor( - $this->anything(), - $this->logicalNot($this->anything()) - ) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::contains - */ - public function testAssertThatContains() - { - $this->assertThat(array('foo'), $this->contains('foo')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::stringContains - */ - public function testAssertThatStringContains() - { - $this->assertThat('barfoobar', $this->stringContains('foo')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::containsOnly - */ - public function testAssertThatContainsOnly() - { - $this->assertThat(array('foo'), $this->containsOnly('string')); - } - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::containsOnlyInstancesOf - */ - public function testAssertThatContainsOnlyInstancesOf() - { - $this->assertThat(array(new Book), $this->containsOnlyInstancesOf('Book')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::arrayHasKey - */ - public function testAssertThatArrayHasKey() - { - $this->assertThat(array('foo' => 'bar'), $this->arrayHasKey('foo')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::classHasAttribute - */ - public function testAssertThatClassHasAttribute() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->classHasAttribute('publicAttribute') - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::classHasStaticAttribute - */ - public function testAssertThatClassHasStaticAttribute() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->classHasStaticAttribute('publicStaticAttribute') - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::objectHasAttribute - */ - public function testAssertThatObjectHasAttribute() - { - $this->assertThat( - new ClassWithNonPublicAttributes, - $this->objectHasAttribute('publicAttribute') - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::equalTo - */ - public function testAssertThatEqualTo() - { - $this->assertThat('foo', $this->equalTo('foo')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::identicalTo - */ - public function testAssertThatIdenticalTo() - { - $value = new stdClass; - $constraint = $this->identicalTo($value); - - $this->assertThat($value, $constraint); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isInstanceOf - */ - public function testAssertThatIsInstanceOf() - { - $this->assertThat(new stdClass, $this->isInstanceOf('StdClass')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isType - */ - public function testAssertThatIsType() - { - $this->assertThat('string', $this->isType('string')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::isEmpty - */ - public function testAssertThatIsEmpty() - { - $this->assertThat(array(), $this->isEmpty()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::fileExists - */ - public function testAssertThatFileExists() - { - $this->assertThat(__FILE__, $this->fileExists()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::greaterThan - */ - public function testAssertThatGreaterThan() - { - $this->assertThat(2, $this->greaterThan(1)); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::greaterThanOrEqual - */ - public function testAssertThatGreaterThanOrEqual() - { - $this->assertThat(2, $this->greaterThanOrEqual(1)); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::lessThan - */ - public function testAssertThatLessThan() - { - $this->assertThat(1, $this->lessThan(2)); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::lessThanOrEqual - */ - public function testAssertThatLessThanOrEqual() - { - $this->assertThat(1, $this->lessThanOrEqual(2)); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::matchesRegularExpression - */ - public function testAssertThatMatchesRegularExpression() - { - $this->assertThat('foobar', $this->matchesRegularExpression('/foo/')); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::callback - */ - public function testAssertThatCallback() - { - $this->assertThat( - null, - $this->callback(function ($other) { return true; }) - ); - } - - /** - * @covers PHPUnit_Framework_Assert::assertThat - * @covers PHPUnit_Framework_Assert::countOf - */ - public function testAssertThatCountOf() - { - $this->assertThat(array(1), $this->countOf(1)); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileEquals - */ - public function testAssertFileEquals() - { - $this->assertFileEquals( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'foo.xml' - ); - - try { - $this->assertFileEquals( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'bar.xml' - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertFileNotEquals - */ - public function testAssertFileNotEquals() - { - $this->assertFileNotEquals( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'bar.xml' - ); - - try { - $this->assertFileNotEquals( - $this->filesDirectory . 'foo.xml', - $this->filesDirectory . 'foo.xml' - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEqualsFile - */ - public function testAssertStringEqualsFile() - { - $this->assertStringEqualsFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'foo.xml') - ); - - try { - $this->assertStringEqualsFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'bar.xml') - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotEqualsFile - */ - public function testAssertStringNotEqualsFile() - { - $this->assertStringNotEqualsFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'bar.xml') - ); - - try { - $this->assertStringNotEqualsFile( - $this->filesDirectory . 'foo.xml', - file_get_contents($this->filesDirectory . 'foo.xml') - ); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringStartsWithThrowsException() - { - $this->assertStringStartsWith(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringStartsWithThrowsException2() - { - $this->assertStringStartsWith('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsNotWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringStartsNotWithThrowsException() - { - $this->assertStringStartsNotWith(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsNotWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringStartsNotWithThrowsException2() - { - $this->assertStringStartsNotWith('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringEndsWithThrowsException() - { - $this->assertStringEndsWith(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringEndsWithThrowsException2() - { - $this->assertStringEndsWith('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsNotWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringEndsNotWithThrowsException() - { - $this->assertStringEndsNotWith(null, null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsNotWith - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringEndsNotWithThrowsException2() - { - $this->assertStringEndsNotWith('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsWith - */ - public function testAssertStringStartsWith() - { - $this->assertStringStartsWith('prefix', 'prefixfoo'); - - try { - $this->assertStringStartsWith('prefix', 'foo'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringStartsNotWith - */ - public function testAssertStringStartsNotWith() - { - $this->assertStringStartsNotWith('prefix', 'foo'); - - try { - $this->assertStringStartsNotWith('prefix', 'prefixfoo'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsWith - */ - public function testAssertStringEndsWith() - { - $this->assertStringEndsWith('suffix', 'foosuffix'); - - try { - $this->assertStringEndsWith('suffix', 'foo'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringEndsNotWith - */ - public function testAssertStringEndsNotWith() - { - $this->assertStringEndsNotWith('suffix', 'foo'); - - try { - $this->assertStringEndsNotWith('suffix', 'foosuffix'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormat - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringMatchesFormatRaisesExceptionForInvalidFirstArgument() - { - $this->assertStringMatchesFormat(null, ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormat - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringMatchesFormatRaisesExceptionForInvalidSecondArgument() - { - $this->assertStringMatchesFormat('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormat - */ - public function testAssertStringMatchesFormat() - { - $this->assertStringMatchesFormat('*%s*', '***'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormat - * @expectedException PHPUnit_Framework_AssertionFailedError - */ - public function testAssertStringMatchesFormatFailure() - { - $this->assertStringMatchesFormat('*%s*', '**'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormat - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringNotMatchesFormatRaisesExceptionForInvalidFirstArgument() - { - $this->assertStringNotMatchesFormat(null, ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormat - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringNotMatchesFormatRaisesExceptionForInvalidSecondArgument() - { - $this->assertStringNotMatchesFormat('', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormat - */ - public function testAssertStringNotMatchesFormat() - { - $this->assertStringNotMatchesFormat('*%s*', '**'); - - try { - $this->assertStringMatchesFormat('*%s*', '**'); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertEmpty - */ - public function testAssertEmpty() - { - $this->assertEmpty(array()); - - try { - $this->assertEmpty(array('foo')); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotEmpty - */ - public function testAssertNotEmpty() - { - $this->assertNotEmpty(array('foo')); - - try { - $this->assertNotEmpty(array()); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeEmpty - */ - public function testAssertAttributeEmpty() - { - $o = new stdClass; - $o->a = array(); - - $this->assertAttributeEmpty('a', $o); - - try { - $o->a = array('b'); - $this->assertAttributeEmpty('a', $o); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotEmpty - */ - public function testAssertAttributeNotEmpty() - { - $o = new stdClass; - $o->a = array('b'); - - $this->assertAttributeNotEmpty('a', $o); - - try { - $o->a = array(); - $this->assertAttributeNotEmpty('a', $o); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::markTestIncomplete - */ - public function testMarkTestIncomplete() - { - try { - $this->markTestIncomplete('incomplete'); - } catch (PHPUnit_Framework_IncompleteTestError $e) { - $this->assertEquals('incomplete', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::markTestSkipped - */ - public function testMarkTestSkipped() - { - try { - $this->markTestSkipped('skipped'); - } catch (PHPUnit_Framework_SkippedTestError $e) { - $this->assertEquals('skipped', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertCount - */ - public function testAssertCount() - { - $this->assertCount(2, array(1, 2)); - - try { - $this->assertCount(2, array(1, 2, 3)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertCount - */ - public function testAssertCountTraversable() - { - $this->assertCount(2, new ArrayIterator(array(1, 2))); - - try { - $this->assertCount(2, new ArrayIterator(array(1, 2, 3))); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertCount - */ - public function testAssertCountThrowsExceptionIfExpectedCountIsNoInteger() - { - try { - $this->assertCount('a', array()); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Argument #1 (No Value) of PHPUnit_Framework_Assert::assertCount() must be a integer', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertCount - */ - public function testAssertCountThrowsExceptionIfElementIsNotCountable() - { - try { - $this->assertCount(2, ''); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Argument #2 (No Value) of PHPUnit_Framework_Assert::assertCount() must be a countable or traversable', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeCount - */ - public function testAssertAttributeCount() - { - $o = new stdClass; - $o->a = array(); - - $this->assertAttributeCount(0, 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotCount - */ - public function testAssertNotCount() - { - $this->assertNotCount(2, array(1, 2, 3)); - - try { - $this->assertNotCount(2, array(1, 2)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotCount - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotCountThrowsExceptionIfExpectedCountIsNoInteger() - { - $this->assertNotCount('a', array()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotCount - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotCountThrowsExceptionIfElementIsNotCountable() - { - $this->assertNotCount(2, ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotCount - */ - public function testAssertAttributeNotCount() - { - $o = new stdClass; - $o->a = array(); - - $this->assertAttributeNotCount(1, 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSameSize - */ - public function testAssertSameSize() - { - $this->assertSameSize(array(1, 2), array(3, 4)); - - try { - $this->assertSameSize(array(1, 2), array(1, 2, 3)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSameSize - */ - public function testAssertSameSizeThrowsExceptionIfExpectedIsNotCountable() - { - try { - $this->assertSameSize('a', array()); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Argument #1 (No Value) of PHPUnit_Framework_Assert::assertSameSize() must be a countable or traversable', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertSameSize - */ - public function testAssertSameSizeThrowsExceptionIfActualIsNotCountable() - { - try { - $this->assertSameSize(array(), ''); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Argument #2 (No Value) of PHPUnit_Framework_Assert::assertSameSize() must be a countable or traversable', $e->getMessage()); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSameSize - */ - public function testAssertNotSameSize() - { - $this->assertNotSameSize(array(1, 2), array(1, 2, 3)); - - try { - $this->assertNotSameSize(array(1, 2), array(3, 4)); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSameSize - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotSameSizeThrowsExceptionIfExpectedIsNotCountable() - { - $this->assertNotSameSize('a', array()); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotSameSize - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotSameSizeThrowsExceptionIfActualIsNotCountable() - { - $this->assertNotSameSize(array(), ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJson - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertJsonRaisesExceptionForInvalidArgument() - { - $this->assertJson(null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJson - */ - public function testAssertJson() - { - $this->assertJson('{}'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringEqualsJsonString - */ - public function testAssertJsonStringEqualsJsonString() - { - $expected = '{"Mascott" : "Tux"}'; - $actual = '{"Mascott" : "Tux"}'; - $message = 'Given Json strings do not match'; - - $this->assertJsonStringEqualsJsonString($expected, $actual, $message); - } - - /** - * @dataProvider validInvalidJsonDataprovider - * @covers PHPUnit_Framework_Assert::assertJsonStringEqualsJsonString - */ - public function testAssertJsonStringEqualsJsonStringErrorRaised($expected, $actual) - { - try { - $this->assertJsonStringEqualsJsonString($expected, $actual); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - $this->fail('Expected exception not found'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringNotEqualsJsonString - */ - public function testAssertJsonStringNotEqualsJsonString() - { - $expected = '{"Mascott" : "Beastie"}'; - $actual = '{"Mascott" : "Tux"}'; - $message = 'Given Json strings do match'; - - $this->assertJsonStringNotEqualsJsonString($expected, $actual, $message); - } - - /** - * @dataProvider validInvalidJsonDataprovider - * @covers PHPUnit_Framework_Assert::assertJsonStringNotEqualsJsonString - */ - public function testAssertJsonStringNotEqualsJsonStringErrorRaised($expected, $actual) - { - try { - $this->assertJsonStringNotEqualsJsonString($expected, $actual); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - $this->fail('Expected exception not found'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringEqualsJsonFile - */ - public function testAssertJsonStringEqualsJsonFile() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - $actual = json_encode(array('Mascott' => 'Tux')); - $message = ''; - $this->assertJsonStringEqualsJsonFile($file, $actual, $message); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringEqualsJsonFile - */ - public function testAssertJsonStringEqualsJsonFileExpectingExpectationFailedException() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - $actual = json_encode(array('Mascott' => 'Beastie')); - $message = ''; - try { - $this->assertJsonStringEqualsJsonFile($file, $actual, $message); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - 'Failed asserting that \'{"Mascott":"Beastie"}\' matches JSON string "{"Mascott":"Tux"}".', - $e->getMessage() - ); - - return; - } - - $this->fail('Expected Exception not thrown.'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringEqualsJsonFile - */ - public function testAssertJsonStringEqualsJsonFileExpectingException() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - try { - $this->assertJsonStringEqualsJsonFile($file, null); - } catch (PHPUnit_Framework_Exception $e) { - return; - } - $this->fail('Expected Exception not thrown.'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringNotEqualsJsonFile - */ - public function testAssertJsonStringNotEqualsJsonFile() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - $actual = json_encode(array('Mascott' => 'Beastie')); - $message = ''; - $this->assertJsonStringNotEqualsJsonFile($file, $actual, $message); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonStringNotEqualsJsonFile - */ - public function testAssertJsonStringNotEqualsJsonFileExpectingException() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - try { - $this->assertJsonStringNotEqualsJsonFile($file, null); - } catch (PHPUnit_Framework_Exception $e) { - return; - } - $this->fail('Expected exception not found.'); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonFileNotEqualsJsonFile - */ - public function testAssertJsonFileNotEqualsJsonFile() - { - $fileExpected = __DIR__ . '/../_files/JsonData/simpleObject.json'; - $fileActual = __DIR__ . '/../_files/JsonData/arrayObject.json'; - $message = ''; - $this->assertJsonFileNotEqualsJsonFile($fileExpected, $fileActual, $message); - } - - /** - * @covers PHPUnit_Framework_Assert::assertJsonFileEqualsJsonFile - */ - public function testAssertJsonFileEqualsJsonFile() - { - $file = __DIR__ . '/../_files/JsonData/simpleObject.json'; - $message = ''; - $this->assertJsonFileEqualsJsonFile($file, $file, $message); - } - - /** - * @covers PHPUnit_Framework_Assert::assertInstanceOf - */ - public function testAssertInstanceOf() - { - $this->assertInstanceOf('stdClass', new stdClass); - - try { - $this->assertInstanceOf('Exception', new stdClass); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertInstanceOf - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertInstanceOfThrowsExceptionForInvalidArgument() - { - $this->assertInstanceOf(null, new stdClass); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeInstanceOf - */ - public function testAssertAttributeInstanceOf() - { - $o = new stdClass; - $o->a = new stdClass; - - $this->assertAttributeInstanceOf('stdClass', 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotInstanceOf - */ - public function testAssertNotInstanceOf() - { - $this->assertNotInstanceOf('Exception', new stdClass); - - try { - $this->assertNotInstanceOf('stdClass', new stdClass); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotInstanceOf - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotInstanceOfThrowsExceptionForInvalidArgument() - { - $this->assertNotInstanceOf(null, new stdClass); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotInstanceOf - */ - public function testAssertAttributeNotInstanceOf() - { - $o = new stdClass; - $o->a = new stdClass; - - $this->assertAttributeNotInstanceOf('Exception', 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertInternalType - */ - public function testAssertInternalType() - { - $this->assertInternalType('integer', 1); - - try { - $this->assertInternalType('string', 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertInternalType - */ - public function testAssertInternalTypeDouble() - { - $this->assertInternalType('double', 1.0); - - try { - $this->assertInternalType('double', 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertInternalType - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertInternalTypeThrowsExceptionForInvalidArgument() - { - $this->assertInternalType(null, 1); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeInternalType - */ - public function testAssertAttributeInternalType() - { - $o = new stdClass; - $o->a = 1; - - $this->assertAttributeInternalType('integer', 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotInternalType - */ - public function testAssertNotInternalType() - { - $this->assertNotInternalType('string', 1); - - try { - $this->assertNotInternalType('integer', 1); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertNotInternalType - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertNotInternalTypeThrowsExceptionForInvalidArgument() - { - $this->assertNotInternalType(null, 1); - } - - /** - * @covers PHPUnit_Framework_Assert::assertAttributeNotInternalType - */ - public function testAssertAttributeNotInternalType() - { - $o = new stdClass; - $o->a = 1; - - $this->assertAttributeNotInternalType('string', 'a', $o); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormatFile - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringMatchesFormatFileThrowsExceptionForInvalidArgument() - { - $this->assertStringMatchesFormatFile('not_existing_file', ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormatFile - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringMatchesFormatFileThrowsExceptionForInvalidArgument2() - { - $this->assertStringMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringMatchesFormatFile - */ - public function testAssertStringMatchesFormatFile() - { - $this->assertStringMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', "FOO\n"); - - try { - $this->assertStringMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', "BAR\n"); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormatFile - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringNotMatchesFormatFileThrowsExceptionForInvalidArgument() - { - $this->assertStringNotMatchesFormatFile('not_existing_file', ''); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormatFile - * @expectedException PHPUnit_Framework_Exception - */ - public function testAssertStringNotMatchesFormatFileThrowsExceptionForInvalidArgument2() - { - $this->assertStringNotMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', null); - } - - /** - * @covers PHPUnit_Framework_Assert::assertStringNotMatchesFormatFile - */ - public function testAssertStringNotMatchesFormatFile() - { - $this->assertStringNotMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', "BAR\n"); - - try { - $this->assertStringNotMatchesFormatFile($this->filesDirectory . 'expectedFileFormat.txt', "FOO\n"); - } catch (PHPUnit_Framework_AssertionFailedError $e) { - return; - } - - $this->fail(); - } - - /** - * @return array - */ - public static function validInvalidJsonDataprovider() - { - return array( - 'error syntax in expected JSON' => array('{"Mascott"::}', '{"Mascott" : "Tux"}'), - 'error UTF-8 in actual JSON' => array('{"Mascott" : "Tux"}', '{"Mascott" : :}'), - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/BaseTestListenerTest.php b/vendor/phpunit/phpunit/tests/Framework/BaseTestListenerTest.php deleted file mode 100644 index 0d426cf05..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/BaseTestListenerTest.php +++ /dev/null @@ -1,34 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 4.0.0 - */ -class Framework_BaseTestListenerTest extends PHPUnit_Framework_TestCase -{ - /** - * @var PHPUnit_Framework_TestResult - */ - private $result; - - /** - * @covers PHPUnit_Framework_TestResult - */ - public function testEndEventsAreCounted() - { - $this->result = new PHPUnit_Framework_TestResult; - $listener = new BaseTestListenerSample(); - $this->result->addListener($listener); - $test = new Success; - $test->run($this->result); - - $this->assertEquals(1, $listener->endCount); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/Constraint/CountTest.php b/vendor/phpunit/phpunit/tests/Framework/Constraint/CountTest.php deleted file mode 100644 index 79e99e888..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/Constraint/CountTest.php +++ /dev/null @@ -1,63 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 3.7.30 - * @covers PHPUnit_Framework_Constraint_Count - */ -class CountTest extends PHPUnit_Framework_TestCase -{ - public function testCount() - { - $countConstraint = new PHPUnit_Framework_Constraint_Count(3); - $this->assertTrue($countConstraint->evaluate(array(1, 2, 3), '', true)); - - $countConstraint = new PHPUnit_Framework_Constraint_Count(0); - $this->assertTrue($countConstraint->evaluate(array(), '', true)); - - $countConstraint = new PHPUnit_Framework_Constraint_Count(2); - $it = new TestIterator(array(1, 2)); - $this->assertTrue($countConstraint->evaluate($it, '', true)); - } - - public function testCountDoesNotChangeIteratorKey() - { - $countConstraint = new PHPUnit_Framework_Constraint_Count(2); - - // test with 1st implementation of Iterator - $it = new TestIterator(array(1, 2)); - - $countConstraint->evaluate($it, '', true); - $this->assertEquals(1, $it->current()); - - $it->next(); - $countConstraint->evaluate($it, '', true); - $this->assertEquals(2, $it->current()); - - $it->next(); - $countConstraint->evaluate($it, '', true); - $this->assertFalse($it->valid()); - - // test with 2nd implementation of Iterator - $it = new TestIterator2(array(1, 2)); - - $countConstraint = new PHPUnit_Framework_Constraint_Count(2); - $countConstraint->evaluate($it, '', true); - $this->assertEquals(1, $it->current()); - - $it->next(); - $countConstraint->evaluate($it, '', true); - $this->assertEquals(2, $it->current()); - - $it->next(); - $countConstraint->evaluate($it, '', true); - $this->assertFalse($it->valid()); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageRegExpTest.php b/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageRegExpTest.php deleted file mode 100644 index 1c02a12ba..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageRegExpTest.php +++ /dev/null @@ -1,56 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 4.3.0 - * @covers PHPUnit_Framework_Constraint_ExceptionMessageRegExp - */ -class ExceptionMessageRegExpTest extends PHPUnit_Framework_TestCase -{ - /** - * @expectedException \Exception - * @expectedExceptionMessageRegExp /^A polymorphic \w+ message/ - */ - public function testRegexMessage() - { - throw new Exception('A polymorphic exception message'); - } - - /** - * @expectedException \Exception - * @expectedExceptionMessageRegExp /^a poly[a-z]+ [a-zA-Z0-9_]+ me(s){2}age$/i - */ - public function testRegexMessageExtreme() - { - throw new Exception('A polymorphic exception message'); - } - - /** - * @runInSeparateProcess - * @requires extension xdebug - * @expectedException \Exception - * @expectedExceptionMessageRegExp #Screaming preg_match# - */ - public function testMessageXdebugScreamCompatibility() - { - ini_set('xdebug.scream', '1'); - throw new Exception('Screaming preg_match'); - } - - /** - * @coversNothing - * @expectedException \Exception variadic - * @expectedExceptionMessageRegExp /^A variadic \w+ message/ - */ - public function testSimultaneousLiteralAndRegExpExceptionMessage() - { - throw new Exception('A variadic exception message'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageTest.php b/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageTest.php deleted file mode 100644 index 33f4319bd..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/Constraint/ExceptionMessageTest.php +++ /dev/null @@ -1,52 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 4.0.20 - * @covers PHPUnit_Framework_Constraint_ExceptionMessage - */ -class ExceptionMessageTest extends PHPUnit_Framework_TestCase -{ - /** - * @expectedException \Exception - * @expectedExceptionMessage A literal exception message - */ - public function testLiteralMessage() - { - throw new Exception('A literal exception message'); - } - - /** - * @expectedException \Exception - * @expectedExceptionMessage A partial - */ - public function testPatialMessageBegin() - { - throw new Exception('A partial exception message'); - } - - /** - * @expectedException \Exception - * @expectedExceptionMessage partial exception - */ - public function testPatialMessageMiddle() - { - throw new Exception('A partial exception message'); - } - - /** - * @expectedException \Exception - * @expectedExceptionMessage exception message - */ - public function testPatialMessageEnd() - { - throw new Exception('A partial exception message'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatches/ErrorMessageProviderTest.php b/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatches/ErrorMessageProviderTest.php deleted file mode 100644 index 852902629..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatches/ErrorMessageProviderTest.php +++ /dev/null @@ -1,83 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since File available since Release 3.7.0 - */ -class Framework_Constraint_JsonMatches_ErrorMessageProviderTest extends PHPUnit_Framework_TestCase -{ - /** - * @dataProvider translateTypeToPrefixDataprovider - * @covers PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider::translateTypeToPrefix - */ - public function testTranslateTypeToPrefix($expected, $type) - { - $this->assertEquals( - $expected, - PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider::translateTypeToPrefix($type) - ); - } - - /** - * @dataProvider determineJsonErrorDataprovider - * @covers PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider::determineJsonError - */ - public function testDetermineJsonError($expected, $error, $prefix) - { - $this->assertEquals( - $expected, - PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider::determineJsonError( - $error, - $prefix - ) - ); - } - - public static function determineJsonErrorDataprovider() - { - return array( - 'JSON_ERROR_NONE' => array( - null, 'json_error_none', '' - ), - 'JSON_ERROR_DEPTH' => array( - 'Maximum stack depth exceeded', JSON_ERROR_DEPTH, '' - ), - 'prefixed JSON_ERROR_DEPTH' => array( - 'TUX: Maximum stack depth exceeded', JSON_ERROR_DEPTH, 'TUX: ' - ), - 'JSON_ERROR_STATE_MISMatch' => array( - 'Underflow or the modes mismatch', JSON_ERROR_STATE_MISMATCH, '' - ), - 'JSON_ERROR_CTRL_CHAR' => array( - 'Unexpected control character found', JSON_ERROR_CTRL_CHAR, '' - ), - 'JSON_ERROR_SYNTAX' => array( - 'Syntax error, malformed JSON', JSON_ERROR_SYNTAX, '' - ), - 'JSON_ERROR_UTF8`' => array( - 'Malformed UTF-8 characters, possibly incorrectly encoded', - JSON_ERROR_UTF8, - '' - ), - 'Invalid error indicator' => array( - 'Unknown error', 55, '' - ), - ); - } - - public static function translateTypeToPrefixDataprovider() - { - return array( - 'expected' => array('Expected value JSON decode error - ', 'expected'), - 'actual' => array('Actual value JSON decode error - ', 'actual'), - 'default' => array('', ''), - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatchesTest.php b/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatchesTest.php deleted file mode 100644 index 3203100a6..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/Constraint/JsonMatchesTest.php +++ /dev/null @@ -1,48 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since File available since Release 3.7.0 - */ -class Framework_Constraint_JsonMatchesTest extends PHPUnit_Framework_TestCase -{ - /** - * @dataProvider evaluateDataprovider - * @covers PHPUnit_Framework_Constraint_JsonMatches::evaluate - * @covers PHPUnit_Framework_Constraint_JsonMatches::matches - * @covers PHPUnit_Framework_Constraint_JsonMatches::__construct - */ - public function testEvaluate($expected, $jsonOther, $jsonValue) - { - $constraint = new PHPUnit_Framework_Constraint_JsonMatches($jsonValue); - $this->assertEquals($expected, $constraint->evaluate($jsonOther, '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_JsonMatches::toString - */ - public function testToString() - { - $jsonValue = json_encode(array('Mascott' => 'Tux')); - $constraint = new PHPUnit_Framework_Constraint_JsonMatches($jsonValue); - - $this->assertEquals('matches JSON string "' . $jsonValue . '"', $constraint->toString()); - } - - public static function evaluateDataprovider() - { - return array( - 'valid JSON' => array(true, json_encode(array('Mascott' => 'Tux')), json_encode(array('Mascott' => 'Tux'))), - 'error syntax' => array(false, '{"Mascott"::}', json_encode(array('Mascott' => 'Tux'))), - 'error UTF-8' => array(false, json_encode('\xB1\x31'), json_encode(array('Mascott' => 'Tux'))), - 'invalid JSON in class instantiation' => array(false, json_encode(array('Mascott' => 'Tux')), '{"Mascott"::}'), - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/ConstraintTest.php b/vendor/phpunit/phpunit/tests/Framework/ConstraintTest.php deleted file mode 100644 index f617133fb..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/ConstraintTest.php +++ /dev/null @@ -1,3490 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 3.0.0 - */ -class Framework_ConstraintTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHPUnit_Framework_Constraint_ArrayHasKey - * @covers PHPUnit_Framework_Assert::arrayHasKey - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayHasKey() - { - $constraint = PHPUnit_Framework_Assert::arrayHasKey(0); - - $this->assertFalse($constraint->evaluate(array(), '', true)); - $this->assertEquals('has the key 0', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(array()); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ArrayHasKey - * @covers PHPUnit_Framework_Assert::arrayHasKey - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayHasKey2() - { - $constraint = PHPUnit_Framework_Assert::arrayHasKey(0); - - try { - $constraint->evaluate(array(), 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ArrayHasKey - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::arrayHasKey - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayNotHasKey() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::arrayHasKey(0) - ); - - $this->assertFalse($constraint->evaluate(array(0 => 1), '', true)); - $this->assertEquals('does not have the key 0', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(array(0 => 1)); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ArrayHasKey - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::arrayHasKey - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayNotHasKey2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::arrayHasKey(0) - ); - - try { - $constraint->evaluate(array(0), 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_FileExists - * @covers PHPUnit_Framework_Assert::fileExists - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintFileExists() - { - $constraint = PHPUnit_Framework_Assert::fileExists(); - - $this->assertFalse($constraint->evaluate('foo', '', true)); - $this->assertEquals('file exists', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('foo'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_FileExists - * @covers PHPUnit_Framework_Assert::fileExists - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintFileExists2() - { - $constraint = PHPUnit_Framework_Assert::fileExists(); - - try { - $constraint->evaluate('foo', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_FileExists - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Assert::fileExists - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintFileNotExists() - { - $file = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'ClassWithNonPublicAttributes.php'; - - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::fileExists() - ); - - $this->assertFalse($constraint->evaluate($file, '', true)); - $this->assertEquals('file does not exist', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate($file); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_FileExists - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Assert::fileExists - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintFileNotExists2() - { - $file = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'ClassWithNonPublicAttributes.php'; - - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::fileExists() - ); - - try { - $constraint->evaluate($file, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Assert::greaterThan - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintGreaterThan() - { - $constraint = PHPUnit_Framework_Assert::greaterThan(1); - - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertTrue($constraint->evaluate(2, '', true)); - $this->assertEquals('is greater than 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(0); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Assert::greaterThan - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintGreaterThan2() - { - $constraint = PHPUnit_Framework_Assert::greaterThan(1); - - try { - $constraint->evaluate(0, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::greaterThan - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotGreaterThan() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::greaterThan(1) - ); - - $this->assertTrue($constraint->evaluate(1, '', true)); - $this->assertEquals('is not greater than 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(2); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::greaterThan - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotGreaterThan2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::greaterThan(1) - ); - - try { - $constraint->evaluate(2, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Assert::greaterThanOrEqual - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintGreaterThanOrEqual() - { - $constraint = PHPUnit_Framework_Assert::greaterThanOrEqual(1); - - $this->assertTrue($constraint->evaluate(1, '', true)); - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertEquals('is equal to 1 or is greater than 1', $constraint->toString()); - $this->assertEquals(2, count($constraint)); - - try { - $constraint->evaluate(0); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Assert::greaterThanOrEqual - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintGreaterThanOrEqual2() - { - $constraint = PHPUnit_Framework_Assert::greaterThanOrEqual(1); - - try { - $constraint->evaluate(0, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::greaterThanOrEqual - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotGreaterThanOrEqual() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::greaterThanOrEqual(1) - ); - - $this->assertFalse($constraint->evaluate(1, '', true)); - $this->assertEquals('not( is equal to 1 or is greater than 1 )', $constraint->toString()); - $this->assertEquals(2, count($constraint)); - - try { - $constraint->evaluate(1); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_GreaterThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::greaterThanOrEqual - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotGreaterThanOrEqual2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::greaterThanOrEqual(1) - ); - - try { - $constraint->evaluate(1, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsAnything - * @covers PHPUnit_Framework_Assert::anything - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsAnything() - { - $constraint = PHPUnit_Framework_Assert::anything(); - - $this->assertTrue($constraint->evaluate(null, '', true)); - $this->assertNull($constraint->evaluate(null)); - $this->assertEquals('is anything', $constraint->toString()); - $this->assertEquals(0, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsAnything - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::anything - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotIsAnything() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::anything() - ); - - $this->assertFalse($constraint->evaluate(null, '', true)); - $this->assertEquals('is not anything', $constraint->toString()); - $this->assertEquals(0, count($constraint)); - - try { - $constraint->evaluate(null); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Assert::equalTo - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsEqual() - { - $constraint = PHPUnit_Framework_Assert::equalTo(1); - - $this->assertTrue($constraint->evaluate(1, '', true)); - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertEquals('is equal to 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(0); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - public function isEqualProvider() - { - $a = new stdClass; - $a->foo = 'bar'; - $b = new stdClass; - $ahash = spl_object_hash($a); - $bhash = spl_object_hash($b); - - $c = new stdClass; - $c->foo = 'bar'; - $c->int = 1; - $c->array = array(0, array(1), array(2), 3); - $c->related = new stdClass; - $c->related->foo = "a\nb\nc\nd\ne\nf\ng\nh\ni\nj\nk"; - $c->self = $c; - $c->c = $c; - $d = new stdClass; - $d->foo = 'bar'; - $d->int = 2; - $d->array = array(0, array(4), array(2), 3); - $d->related = new stdClass; - $d->related->foo = "a\np\nc\nd\ne\nf\ng\nh\ni\nw\nk"; - $d->self = $d; - $d->c = $c; - - $storage1 = new SplObjectStorage; - $storage1->attach($a); - $storage1->attach($b); - $storage2 = new SplObjectStorage; - $storage2->attach($b); - $storage1hash = spl_object_hash($storage1); - $storage2hash = spl_object_hash($storage2); - - $dom1 = new DOMDocument; - $dom1->preserveWhiteSpace = false; - $dom1->loadXML(''); - $dom2 = new DOMDocument; - $dom2->preserveWhiteSpace = false; - $dom2->loadXML(''); - - $data = array( - array(1, 0, << 0 -+ 0 => 1 - ) - -EOF - ), - array(array(true), array('true'), << true -+ 0 => 'true' - ) - -EOF - ), - array(array(0, array(1), array(2), 3), array(0, array(4), array(2), 3), << 0 - 1 => Array ( -- 0 => 1 -+ 0 => 4 - ) - 2 => Array (...) - 3 => 3 - ) - -EOF - ), - array($a, array(0), << 'bar' - ) - -EOF - ), - array($c, $d, << 'bar' -- 'int' => 1 -+ 'int' => 2 - 'array' => Array ( - 0 => 0 - 1 => Array ( -- 0 => 1 -+ 0 => 4 - -@@ @@ - 'foo' => 'a -- b -+ p - -@@ @@ - i -- j -+ w - k' - ) - 'self' => stdClass Object (...) - 'c' => stdClass Object (...) - ) - -EOF - ), - array($dom1, $dom2, << -- -+ -+ -+ - -EOF - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - << Array &0 ( -- 'obj' => stdClass Object &$ahash ( -- 'foo' => 'bar' -- ) -+SplObjectStorage Object &$storage2hash ( -+ '$bhash' => Array &0 ( -+ 'obj' => stdClass Object &$bhash () - 'inf' => null - ) -- '$bhash' => Array &0 - ) - -EOF - ); - } else { - $data[] = array($storage1, $storage2, << Array &0 ( -- 'obj' => stdClass Object &$ahash ( -- 'foo' => 'bar' -- ) -- 'inf' => null -- ) -- '$bhash' => Array &1 ( -+SplObjectStorage Object &$storage2hash ( -+ '$bhash' => Array &0 ( - 'obj' => stdClass Object &$bhash () - 'inf' => null - ) - ) - -EOF - ); - } - - return $data; - } - - /** - * @dataProvider isEqualProvider - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Assert::equalTo - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsEqual2($expected, $actual, $message) - { - $constraint = PHPUnit_Framework_Assert::equalTo($expected); - - try { - $constraint->evaluate($actual, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - "custom message\n$message", - $this->trimnl(PHPUnit_Framework_TestFailure::exceptionToString($e)) - ); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::equalTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotEqual() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::equalTo(1) - ); - - $this->assertTrue($constraint->evaluate(0, '', true)); - $this->assertFalse($constraint->evaluate(1, '', true)); - $this->assertEquals('is not equal to 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(1); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::equalTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotEqual2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::equalTo(1) - ); - - try { - $constraint->evaluate(1, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsIdentical() - { - $a = new stdClass; - $b = new stdClass; - - $constraint = PHPUnit_Framework_Assert::identicalTo($a); - - $this->assertFalse($constraint->evaluate($b, '', true)); - $this->assertTrue($constraint->evaluate($a, '', true)); - $this->assertEquals('is identical to an object of class "stdClass"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate($b); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsIdentical2() - { - $a = new stdClass; - $b = new stdClass; - - $constraint = PHPUnit_Framework_Assert::identicalTo($a); - - try { - $constraint->evaluate($b, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsIdentical3() - { - $constraint = PHPUnit_Framework_Assert::identicalTo('a'); - - try { - $constraint->evaluate('b', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotIdentical() - { - $a = new stdClass; - $b = new stdClass; - - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::identicalTo($a) - ); - - $this->assertTrue($constraint->evaluate($b, '', true)); - $this->assertFalse($constraint->evaluate($a, '', true)); - $this->assertEquals('is not identical to an object of class "stdClass"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate($a); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<trimnl(PHPUnit_Framework_TestFailure::exceptionToString($e)) - ); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotIdentical2() - { - $a = new stdClass; - - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::identicalTo($a) - ); - - try { - $constraint->evaluate($a, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsIdentical - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::identicalTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotIdentical3() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::identicalTo('a') - ); - - try { - $constraint->evaluate('a', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<trimnl(PHPUnit_Framework_TestFailure::exceptionToString($e)) - ); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsInstanceOf - * @covers PHPUnit_Framework_Assert::isInstanceOf - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsInstanceOf() - { - $constraint = PHPUnit_Framework_Assert::isInstanceOf('Exception'); - - $this->assertFalse($constraint->evaluate(new stdClass, '', true)); - $this->assertTrue($constraint->evaluate(new Exception, '', true)); - $this->assertEquals('is instance of class "Exception"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - $interfaceConstraint = PHPUnit_Framework_Assert::isInstanceOf('Countable'); - $this->assertFalse($interfaceConstraint->evaluate(new stdClass, '', true)); - $this->assertTrue($interfaceConstraint->evaluate(new ArrayObject, '', true)); - $this->assertEquals('is instance of interface "Countable"', $interfaceConstraint->toString()); - - try { - $constraint->evaluate(new stdClass); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsInstanceOf - * @covers PHPUnit_Framework_Assert::isInstanceOf - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsInstanceOf2() - { - $constraint = PHPUnit_Framework_Assert::isInstanceOf('Exception'); - - try { - $constraint->evaluate(new stdClass, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsInstanceOf - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isInstanceOf - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotInstanceOf() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isInstanceOf('stdClass') - ); - - $this->assertFalse($constraint->evaluate(new stdClass, '', true)); - $this->assertTrue($constraint->evaluate(new Exception, '', true)); - $this->assertEquals('is not instance of class "stdClass"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(new stdClass); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsInstanceOf - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isInstanceOf - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotInstanceOf2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isInstanceOf('stdClass') - ); - - try { - $constraint->evaluate(new stdClass, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsType - * @covers PHPUnit_Framework_Assert::isType - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsType() - { - $constraint = PHPUnit_Framework_Assert::isType('string'); - - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertTrue($constraint->evaluate('', '', true)); - $this->assertEquals('is of type "string"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(new stdClass); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertStringMatchesFormat(<<trimnl(PHPUnit_Framework_TestFailure::exceptionToString($e)) - ); - - return; - } - - $this->fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsType - * @covers PHPUnit_Framework_Assert::isType - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsType2() - { - $constraint = PHPUnit_Framework_Assert::isType('string'); - - try { - $constraint->evaluate(new stdClass, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertStringMatchesFormat(<<trimnl(PHPUnit_Framework_TestFailure::exceptionToString($e)) - ); - - return; - } - - $this->fail(); - } - - public function resources() - { - $fh = fopen(__FILE__, 'r'); - fclose($fh); - - return array( - 'open resource' => array(fopen(__FILE__, 'r')), - 'closed resource' => array($fh), - ); - } - - /** - * @dataProvider resources - * @covers PHPUnit_Framework_Constraint_IsType - * @covers PHPUnit_Framework_Assert::isType - */ - public function testConstraintIsResourceTypeEvaluatesCorrectlyWithResources($resource) - { - $constraint = PHPUnit_Framework_Assert::isType('resource'); - - $this->assertTrue($constraint->evaluate($resource, '', true)); - - @fclose($resource); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsType - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isType - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotType() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isType('string') - ); - - $this->assertTrue($constraint->evaluate(0, '', true)); - $this->assertFalse($constraint->evaluate('', '', true)); - $this->assertEquals('is not of type "string"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(''); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsType - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isType - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotType2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isType('string') - ); - - try { - $constraint->evaluate('', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsNull - * @covers PHPUnit_Framework_Assert::isNull - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNull() - { - $constraint = PHPUnit_Framework_Assert::isNull(); - - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertTrue($constraint->evaluate(null, '', true)); - $this->assertEquals('is null', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(0); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsNull - * @covers PHPUnit_Framework_Assert::isNull - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNull2() - { - $constraint = PHPUnit_Framework_Assert::isNull(); - - try { - $constraint->evaluate(0, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsNull - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isNull - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotNull() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isNull() - ); - - $this->assertFalse($constraint->evaluate(null, '', true)); - $this->assertTrue($constraint->evaluate(0, '', true)); - $this->assertEquals('is not null', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(null); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsNull - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::isNull - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsNotNull2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::isNull() - ); - - try { - $constraint->evaluate(null, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Assert::lessThan - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintLessThan() - { - $constraint = PHPUnit_Framework_Assert::lessThan(1); - - $this->assertTrue($constraint->evaluate(0, '', true)); - $this->assertFalse($constraint->evaluate(1, '', true)); - $this->assertEquals('is less than 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(1); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Assert::lessThan - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintLessThan2() - { - $constraint = PHPUnit_Framework_Assert::lessThan(1); - - try { - $constraint->evaluate(1, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::lessThan - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotLessThan() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::lessThan(1) - ); - - $this->assertTrue($constraint->evaluate(1, '', true)); - $this->assertFalse($constraint->evaluate(0, '', true)); - $this->assertEquals('is not less than 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(0); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::lessThan - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotLessThan2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::lessThan(1) - ); - - try { - $constraint->evaluate(0, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Assert::lessThanOrEqual - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintLessThanOrEqual() - { - $constraint = PHPUnit_Framework_Assert::lessThanOrEqual(1); - - $this->assertTrue($constraint->evaluate(1, '', true)); - $this->assertFalse($constraint->evaluate(2, '', true)); - $this->assertEquals('is equal to 1 or is less than 1', $constraint->toString()); - $this->assertEquals(2, count($constraint)); - - try { - $constraint->evaluate(2); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_Callback - */ - public function testConstraintCallback() - { - $closureReflect = function ($parameter) { - return $parameter; - }; - - $closureWithoutParameter = function () { - return true; - }; - - $constraint = PHPUnit_Framework_Assert::callback($closureWithoutParameter); - $this->assertTrue($constraint->evaluate('', '', true)); - - $constraint = PHPUnit_Framework_Assert::callback($closureReflect); - $this->assertTrue($constraint->evaluate(true, '', true)); - $this->assertFalse($constraint->evaluate(false, '', true)); - - $callback = array($this, 'callbackReturningTrue'); - $constraint = PHPUnit_Framework_Assert::callback($callback); - $this->assertTrue($constraint->evaluate(false, '', true)); - - $callback = array('Framework_ConstraintTest', 'staticCallbackReturningTrue'); - $constraint = PHPUnit_Framework_Assert::callback($callback); - $this->assertTrue($constraint->evaluate(null, '', true)); - - $this->assertEquals('is accepted by specified callback', $constraint->toString()); - } - - /** - * @covers PHPUnit_Framework_Constraint_Callback - * @expectedException PHPUnit_Framework_ExpectationFailedException - * @expectedExceptionMessage Failed asserting that 'This fails' is accepted by specified callback. - */ - public function testConstraintCallbackFailure() - { - $constraint = PHPUnit_Framework_Assert::callback(function () { - return false; - }); - $constraint->evaluate('This fails'); - } - - public function callbackReturningTrue() - { - return true; - } - - public static function staticCallbackReturningTrue() - { - return true; - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Assert::lessThanOrEqual - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintLessThanOrEqual2() - { - $constraint = PHPUnit_Framework_Assert::lessThanOrEqual(1); - - try { - $constraint->evaluate(2, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::lessThanOrEqual - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotLessThanOrEqual() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::lessThanOrEqual(1) - ); - - $this->assertTrue($constraint->evaluate(2, '', true)); - $this->assertFalse($constraint->evaluate(1, '', true)); - $this->assertEquals('not( is equal to 1 or is less than 1 )', $constraint->toString()); - $this->assertEquals(2, count($constraint)); - - try { - $constraint->evaluate(1); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEqual - * @covers PHPUnit_Framework_Constraint_LessThan - * @covers PHPUnit_Framework_Constraint_Or - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::lessThanOrEqual - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotLessThanOrEqual2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::lessThanOrEqual(1) - ); - - try { - $constraint->evaluate(1, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasAttribute - * @covers PHPUnit_Framework_Assert::classHasAttribute - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassHasAttribute() - { - $constraint = PHPUnit_Framework_Assert::classHasAttribute('privateAttribute'); - - $this->assertTrue($constraint->evaluate('ClassWithNonPublicAttributes', '', true)); - $this->assertFalse($constraint->evaluate('stdClass', '', true)); - $this->assertEquals('has attribute "privateAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('stdClass'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasAttribute - * @covers PHPUnit_Framework_Assert::classHasAttribute - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassHasAttribute2() - { - $constraint = PHPUnit_Framework_Assert::classHasAttribute('privateAttribute'); - - try { - $constraint->evaluate('stdClass', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::classHasAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassNotHasAttribute() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::classHasAttribute('privateAttribute') - ); - - $this->assertTrue($constraint->evaluate('stdClass', '', true)); - $this->assertFalse($constraint->evaluate('ClassWithNonPublicAttributes', '', true)); - $this->assertEquals('does not have attribute "privateAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::classHasAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassNotHasAttribute2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::classHasAttribute('privateAttribute') - ); - - try { - $constraint->evaluate('ClassWithNonPublicAttributes', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasStaticAttribute - * @covers PHPUnit_Framework_Assert::classHasStaticAttribute - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassHasStaticAttribute() - { - $constraint = PHPUnit_Framework_Assert::classHasStaticAttribute('privateStaticAttribute'); - - $this->assertTrue($constraint->evaluate('ClassWithNonPublicAttributes', '', true)); - $this->assertFalse($constraint->evaluate('stdClass', '', true)); - $this->assertEquals('has static attribute "privateStaticAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('stdClass'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasStaticAttribute - * @covers PHPUnit_Framework_Assert::classHasStaticAttribute - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassHasStaticAttribute2() - { - $constraint = PHPUnit_Framework_Assert::classHasStaticAttribute('foo'); - - try { - $constraint->evaluate('stdClass', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasStaticAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::classHasStaticAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassNotHasStaticAttribute() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::classHasStaticAttribute('privateStaticAttribute') - ); - - $this->assertTrue($constraint->evaluate('stdClass', '', true)); - $this->assertFalse($constraint->evaluate('ClassWithNonPublicAttributes', '', true)); - $this->assertEquals('does not have static attribute "privateStaticAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('ClassWithNonPublicAttributes'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ClassHasStaticAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::classHasStaticAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintClassNotHasStaticAttribute2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::classHasStaticAttribute('privateStaticAttribute') - ); - - try { - $constraint->evaluate('ClassWithNonPublicAttributes', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ObjectHasAttribute - * @covers PHPUnit_Framework_Assert::objectHasAttribute - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintObjectHasAttribute() - { - $constraint = PHPUnit_Framework_Assert::objectHasAttribute('privateAttribute'); - - $this->assertTrue($constraint->evaluate(new ClassWithNonPublicAttributes, '', true)); - $this->assertFalse($constraint->evaluate(new stdClass, '', true)); - $this->assertEquals('has attribute "privateAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(new stdClass); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ObjectHasAttribute - * @covers PHPUnit_Framework_Assert::objectHasAttribute - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintObjectHasAttribute2() - { - $constraint = PHPUnit_Framework_Assert::objectHasAttribute('privateAttribute'); - - try { - $constraint->evaluate(new stdClass, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ObjectHasAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::objectHasAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintObjectNotHasAttribute() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::objectHasAttribute('privateAttribute') - ); - - $this->assertTrue($constraint->evaluate(new stdClass, '', true)); - $this->assertFalse($constraint->evaluate(new ClassWithNonPublicAttributes, '', true)); - $this->assertEquals('does not have attribute "privateAttribute"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(new ClassWithNonPublicAttributes); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_ObjectHasAttribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::objectHasAttribute - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintObjectNotHasAttribute2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::objectHasAttribute('privateAttribute') - ); - - try { - $constraint->evaluate(new ClassWithNonPublicAttributes, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_PCREMatch - * @covers PHPUnit_Framework_Assert::matchesRegularExpression - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintPCREMatch() - { - $constraint = PHPUnit_Framework_Assert::matchesRegularExpression('/foo/'); - - $this->assertFalse($constraint->evaluate('barbazbar', '', true)); - $this->assertTrue($constraint->evaluate('barfoobar', '', true)); - $this->assertEquals('matches PCRE pattern "/foo/"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('barbazbar'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_PCREMatch - * @covers PHPUnit_Framework_Assert::matchesRegularExpression - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintPCREMatch2() - { - $constraint = PHPUnit_Framework_Assert::matchesRegularExpression('/foo/'); - - try { - $constraint->evaluate('barbazbar', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_PCREMatch - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::matchesRegularExpression - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintPCRENotMatch() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::matchesRegularExpression('/foo/') - ); - - $this->assertTrue($constraint->evaluate('barbazbar', '', true)); - $this->assertFalse($constraint->evaluate('barfoobar', '', true)); - $this->assertEquals('does not match PCRE pattern "/foo/"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('barfoobar'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_PCREMatch - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::matchesRegularExpression - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintPCRENotMatch2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::matchesRegularExpression('/foo/') - ); - - try { - $constraint->evaluate('barfoobar', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals(<<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches() - { - $constraint = PHPUnit_Framework_Assert::matches('*%c*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('***', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*.\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches2() - { - $constraint = PHPUnit_Framework_Assert::matches('*%s*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('***', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*[^\r\n]+\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches3() - { - $constraint = PHPUnit_Framework_Assert::matches('*%i*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('*0*', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*[+-]?\d+\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches4() - { - $constraint = PHPUnit_Framework_Assert::matches('*%d*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('*0*', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*\d+\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches5() - { - $constraint = PHPUnit_Framework_Assert::matches('*%x*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('*0f0f0f*', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*[0-9a-fA-F]+\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringMatches - * @covers PHPUnit_Framework_Assert::matches - * @covers PHPUnit_Framework_Constraint::count - */ - public function testConstraintStringMatches6() - { - $constraint = PHPUnit_Framework_Assert::matches('*%f*'); - $this->assertFalse($constraint->evaluate('**', '', true)); - $this->assertTrue($constraint->evaluate('*1.0*', '', true)); - $this->assertEquals('matches PCRE pattern "/^\*[+-]?\.?\d+\.?\d*(?:[Ee][+-]?\d+)?\*$/s"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringStartsWith - * @covers PHPUnit_Framework_Assert::stringStartsWith - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringStartsWith() - { - $constraint = PHPUnit_Framework_Assert::stringStartsWith('prefix'); - - $this->assertFalse($constraint->evaluate('foo', '', true)); - $this->assertTrue($constraint->evaluate('prefixfoo', '', true)); - $this->assertEquals('starts with "prefix"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('foo'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringStartsWith - * @covers PHPUnit_Framework_Assert::stringStartsWith - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringStartsWith2() - { - $constraint = PHPUnit_Framework_Assert::stringStartsWith('prefix'); - - try { - $constraint->evaluate('foo', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringStartsWith - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::stringStartsWith - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringStartsNotWith() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringStartsWith('prefix') - ); - - $this->assertTrue($constraint->evaluate('foo', '', true)); - $this->assertFalse($constraint->evaluate('prefixfoo', '', true)); - $this->assertEquals('starts not with "prefix"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('prefixfoo'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringStartsWith - * @covers PHPUnit_Framework_Assert::stringStartsWith - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringStartsNotWith2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringStartsWith('prefix') - ); - - try { - $constraint->evaluate('prefixfoo', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringContains - * @covers PHPUnit_Framework_Assert::stringContains - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringContains() - { - $constraint = PHPUnit_Framework_Assert::stringContains('foo'); - - $this->assertFalse($constraint->evaluate('barbazbar', '', true)); - $this->assertTrue($constraint->evaluate('barfoobar', '', true)); - $this->assertEquals('contains "foo"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('barbazbar'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringContains - * @covers PHPUnit_Framework_Assert::stringContains - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringContains2() - { - $constraint = PHPUnit_Framework_Assert::stringContains('foo'); - - try { - $constraint->evaluate('barbazbar', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringContains - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::stringContains - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringNotContains() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringContains('foo') - ); - - $this->assertTrue($constraint->evaluate('barbazbar', '', true)); - $this->assertFalse($constraint->evaluate('barfoobar', '', true)); - $this->assertEquals('does not contain "foo"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('barfoobar'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringContains - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::stringContains - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringNotContains2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringContains('foo') - ); - - try { - $constraint->evaluate('barfoobar', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringEndsWith - * @covers PHPUnit_Framework_Assert::stringEndsWith - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringEndsWith() - { - $constraint = PHPUnit_Framework_Assert::stringEndsWith('suffix'); - - $this->assertFalse($constraint->evaluate('foo', '', true)); - $this->assertTrue($constraint->evaluate('foosuffix', '', true)); - $this->assertEquals('ends with "suffix"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('foo'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringEndsWith - * @covers PHPUnit_Framework_Assert::stringEndsWith - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringEndsWith2() - { - $constraint = PHPUnit_Framework_Assert::stringEndsWith('suffix'); - - try { - $constraint->evaluate('foo', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringEndsWith - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::stringEndsWith - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringEndsNotWith() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringEndsWith('suffix') - ); - - $this->assertTrue($constraint->evaluate('foo', '', true)); - $this->assertFalse($constraint->evaluate('foosuffix', '', true)); - $this->assertEquals('ends not with "suffix"', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate('foosuffix'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_StringEndsWith - * @covers PHPUnit_Framework_Assert::stringEndsWith - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintStringEndsNotWith2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::stringEndsWith('suffix') - ); - - try { - $constraint->evaluate('foosuffix', 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - */ - public function testConstraintArrayContainsCheckForObjectIdentity() - { - // Check for primitive type. - $constraint = new PHPUnit_Framework_Constraint_TraversableContains('foo', true, true); - - $this->assertFalse($constraint->evaluate(array(0), '', true)); - $this->assertFalse($constraint->evaluate(array(true), '', true)); - - // Default case. - $constraint = new PHPUnit_Framework_Constraint_TraversableContains('foo'); - - $this->assertTrue($constraint->evaluate(array(0), '', true)); - $this->assertTrue($constraint->evaluate(array(true), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayContains() - { - $constraint = new PHPUnit_Framework_Constraint_TraversableContains('foo'); - - $this->assertFalse($constraint->evaluate(array('bar'), '', true)); - $this->assertTrue($constraint->evaluate(array('foo'), '', true)); - $this->assertEquals("contains 'foo'", $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(array('bar')); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayContains2() - { - $constraint = new PHPUnit_Framework_Constraint_TraversableContains('foo'); - - try { - $constraint->evaluate(array('bar'), 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayNotContains() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - new PHPUnit_Framework_Constraint_TraversableContains('foo') - ); - - $this->assertTrue($constraint->evaluate(array('bar'), '', true)); - $this->assertFalse($constraint->evaluate(array('foo'), '', true)); - $this->assertEquals("does not contain 'foo'", $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(array('foo')); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintArrayNotContains2() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - new PHPUnit_Framework_Constraint_TraversableContains('foo') - ); - - try { - $constraint->evaluate(array('foo'), 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintSplObjectStorageContains() - { - $object = new StdClass; - $constraint = new PHPUnit_Framework_Constraint_TraversableContains($object); - $this->assertStringMatchesFormat('contains stdClass Object &%s ()', $constraint->toString()); - - $storage = new SplObjectStorage; - $this->assertFalse($constraint->evaluate($storage, '', true)); - - $storage->attach($object); - $this->assertTrue($constraint->evaluate($storage, '', true)); - - try { - $constraint->evaluate(new SplObjectStorage); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertStringMatchesFormat( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_TraversableContains - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintSplObjectStorageContains2() - { - $object = new StdClass; - $constraint = new PHPUnit_Framework_Constraint_TraversableContains($object); - - try { - $constraint->evaluate(new SplObjectStorage, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertStringMatchesFormat( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::attributeEqualTo - * @covers PHPUnit_Framework_Constraint_Attribute - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testAttributeEqualTo() - { - $object = new ClassWithNonPublicAttributes; - $constraint = PHPUnit_Framework_Assert::attributeEqualTo('foo', 1); - - $this->assertTrue($constraint->evaluate($object, '', true)); - $this->assertEquals('attribute "foo" is equal to 1', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - $constraint = PHPUnit_Framework_Assert::attributeEqualTo('foo', 2); - - $this->assertFalse($constraint->evaluate($object, '', true)); - - try { - $constraint->evaluate($object); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::attributeEqualTo - * @covers PHPUnit_Framework_Constraint_Attribute - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testAttributeEqualTo2() - { - $object = new ClassWithNonPublicAttributes; - $constraint = PHPUnit_Framework_Assert::attributeEqualTo('foo', 2); - - try { - $constraint->evaluate($object, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::attributeEqualTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Constraint_Attribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testAttributeNotEqualTo() - { - $object = new ClassWithNonPublicAttributes; - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::attributeEqualTo('foo', 2) - ); - - $this->assertTrue($constraint->evaluate($object, '', true)); - $this->assertEquals('attribute "foo" is not equal to 2', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::attributeEqualTo('foo', 1) - ); - - $this->assertFalse($constraint->evaluate($object, '', true)); - - try { - $constraint->evaluate($object); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Assert::attributeEqualTo - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_Constraint_Attribute - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testAttributeNotEqualTo2() - { - $object = new ClassWithNonPublicAttributes; - $constraint = PHPUnit_Framework_Assert::logicalNot( - PHPUnit_Framework_Assert::attributeEqualTo('foo', 1) - ); - - try { - $constraint->evaluate($object, 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEmpty - * @covers PHPUnit_Framework_Constraint::count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsEmpty() - { - $constraint = new PHPUnit_Framework_Constraint_IsEmpty; - - $this->assertFalse($constraint->evaluate(array('foo'), '', true)); - $this->assertTrue($constraint->evaluate(array(), '', true)); - $this->assertFalse($constraint->evaluate(new ArrayObject(array('foo')), '', true)); - $this->assertTrue($constraint->evaluate(new ArrayObject(array()), '', true)); - $this->assertEquals('is empty', $constraint->toString()); - $this->assertEquals(1, count($constraint)); - - try { - $constraint->evaluate(array('foo')); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_IsEmpty - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintIsEmpty2() - { - $constraint = new PHPUnit_Framework_Constraint_IsEmpty; - - try { - $constraint->evaluate(array('foo'), 'custom message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_Count - */ - public function testConstraintCountWithAnArray() - { - $constraint = new PHPUnit_Framework_Constraint_Count(5); - - $this->assertTrue($constraint->evaluate(array(1, 2, 3, 4, 5), '', true)); - $this->assertFalse($constraint->evaluate(array(1, 2, 3, 4), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_Count - */ - public function testConstraintCountWithAnIteratorWhichDoesNotImplementCountable() - { - $constraint = new PHPUnit_Framework_Constraint_Count(5); - - $this->assertTrue($constraint->evaluate(new TestIterator(array(1, 2, 3, 4, 5)), '', true)); - $this->assertFalse($constraint->evaluate(new TestIterator(array(1, 2, 3, 4)), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_Count - */ - public function testConstraintCountWithAnObjectImplementingCountable() - { - $constraint = new PHPUnit_Framework_Constraint_Count(5); - - $this->assertTrue($constraint->evaluate(new ArrayObject(array(1, 2, 3, 4, 5)), '', true)); - $this->assertFalse($constraint->evaluate(new ArrayObject(array(1, 2, 3, 4)), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_Count - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintCountFailing() - { - $constraint = new PHPUnit_Framework_Constraint_Count(5); - - try { - $constraint->evaluate(array(1, 2)); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_Count - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotCountFailing() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - new PHPUnit_Framework_Constraint_Count(2) - ); - - try { - $constraint->evaluate(array(1, 2)); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_SameSize - */ - public function testConstraintSameSizeWithAnArray() - { - $constraint = new PHPUnit_Framework_Constraint_SameSize(array(1, 2, 3, 4, 5)); - - $this->assertTrue($constraint->evaluate(array(6, 7, 8, 9, 10), '', true)); - $this->assertFalse($constraint->evaluate(array(1, 2, 3, 4), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_SameSize - */ - public function testConstraintSameSizeWithAnIteratorWhichDoesNotImplementCountable() - { - $constraint = new PHPUnit_Framework_Constraint_SameSize(new TestIterator(array(1, 2, 3, 4, 5))); - - $this->assertTrue($constraint->evaluate(new TestIterator(array(6, 7, 8, 9, 10)), '', true)); - $this->assertFalse($constraint->evaluate(new TestIterator(array(1, 2, 3, 4)), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_SameSize - */ - public function testConstraintSameSizeWithAnObjectImplementingCountable() - { - $constraint = new PHPUnit_Framework_Constraint_SameSize(new ArrayObject(array(1, 2, 3, 4, 5))); - - $this->assertTrue($constraint->evaluate(new ArrayObject(array(6, 7, 8, 9, 10)), '', true)); - $this->assertFalse($constraint->evaluate(new ArrayObject(array(1, 2, 3, 4)), '', true)); - } - - /** - * @covers PHPUnit_Framework_Constraint_SameSize - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintSameSizeFailing() - { - $constraint = new PHPUnit_Framework_Constraint_SameSize(array(1, 2, 3, 4, 5)); - - try { - $constraint->evaluate(array(1, 2)); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_SameSize - * @covers PHPUnit_Framework_Constraint_Not - * @covers PHPUnit_Framework_Assert::logicalNot - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintNotSameSizeFailing() - { - $constraint = PHPUnit_Framework_Assert::logicalNot( - new PHPUnit_Framework_Constraint_SameSize(array(1, 2)) - ); - - try { - $constraint->evaluate(array(3, 4)); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * @covers PHPUnit_Framework_Constraint_Exception - * @covers PHPUnit_Framework_TestFailure::exceptionToString - */ - public function testConstraintException() - { - $constraint = new PHPUnit_Framework_Constraint_Exception('FoobarException'); - $exception = new DummyException('Test'); - $stackTrace = $exception->getTraceAsString(); - - try { - $constraint->evaluate($exception); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $this->assertEquals( - <<fail(); - } - - /** - * Removes spaces in front of newlines - * - * @param string $string - * @return string - */ - private function trimnl($string) - { - return preg_replace('/[ ]*\n/', "\n", $string); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/SuiteTest.php b/vendor/phpunit/phpunit/tests/Framework/SuiteTest.php deleted file mode 100644 index e3f58b3d3..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/SuiteTest.php +++ /dev/null @@ -1,242 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'BeforeAndAfterTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'BeforeClassAndAfterClassTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'TestWithTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'DataProviderSkippedTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'DataProviderIncompleteTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'InheritedTestCase.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'NoTestCaseClass.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'NoTestCases.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'NotPublicTestCase.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'NotVoidTestCase.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'OverrideTestCase.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'RequirementsClassBeforeClassHookTest.php'; - -/** - * @since Class available since Release 2.0.0 - * @covers PHPUnit_Framework_TestSuite - */ -class Framework_SuiteTest extends PHPUnit_Framework_TestCase -{ - protected $result; - - protected function setUp() - { - $this->result = new PHPUnit_Framework_TestResult; - } - - public static function suite() - { - $suite = new PHPUnit_Framework_TestSuite; - - $suite->addTest(new self('testAddTestSuite')); - $suite->addTest(new self('testInheritedTests')); - $suite->addTest(new self('testNoTestCases')); - $suite->addTest(new self('testNoTestCaseClass')); - $suite->addTest(new self('testNotExistingTestCase')); - $suite->addTest(new self('testNotPublicTestCase')); - $suite->addTest(new self('testNotVoidTestCase')); - $suite->addTest(new self('testOneTestCase')); - $suite->addTest(new self('testShadowedTests')); - $suite->addTest(new self('testBeforeClassAndAfterClassAnnotations')); - $suite->addTest(new self('testBeforeAnnotation')); - $suite->addTest(new self('testTestWithAnnotation')); - $suite->addTest(new self('testSkippedTestDataProvider')); - $suite->addTest(new self('testIncompleteTestDataProvider')); - $suite->addTest(new self('testRequirementsBeforeClassHook')); - $suite->addTest(new self('testDontSkipInheritedClass')); - - return $suite; - } - - public function testAddTestSuite() - { - $suite = new PHPUnit_Framework_TestSuite( - 'OneTestCase' - ); - - $suite->run($this->result); - - $this->assertEquals(1, count($this->result)); - } - - public function testInheritedTests() - { - $suite = new PHPUnit_Framework_TestSuite( - 'InheritedTestCase' - ); - - $suite->run($this->result); - - $this->assertTrue($this->result->wasSuccessful()); - $this->assertEquals(2, count($this->result)); - } - - public function testNoTestCases() - { - $suite = new PHPUnit_Framework_TestSuite( - 'NoTestCases' - ); - - $suite->run($this->result); - - $this->assertTrue(!$this->result->wasSuccessful()); - $this->assertEquals(1, $this->result->failureCount()); - $this->assertEquals(1, count($this->result)); - } - - /** - * @expectedException PHPUnit_Framework_Exception - */ - public function testNoTestCaseClass() - { - $suite = new PHPUnit_Framework_TestSuite('NoTestCaseClass'); - } - - public function testNotExistingTestCase() - { - $suite = new self('notExistingMethod'); - - $suite->run($this->result); - - $this->assertEquals(0, $this->result->errorCount()); - $this->assertEquals(1, $this->result->failureCount()); - $this->assertEquals(1, count($this->result)); - } - - public function testNotPublicTestCase() - { - $suite = new PHPUnit_Framework_TestSuite( - 'NotPublicTestCase' - ); - - $this->assertEquals(2, count($suite)); - } - - public function testNotVoidTestCase() - { - $suite = new PHPUnit_Framework_TestSuite( - 'NotVoidTestCase' - ); - - $this->assertEquals(1, count($suite)); - } - - public function testOneTestCase() - { - $suite = new PHPUnit_Framework_TestSuite( - 'OneTestCase' - ); - - $suite->run($this->result); - - $this->assertEquals(0, $this->result->errorCount()); - $this->assertEquals(0, $this->result->failureCount()); - $this->assertEquals(1, count($this->result)); - $this->assertTrue($this->result->wasSuccessful()); - } - - public function testShadowedTests() - { - $suite = new PHPUnit_Framework_TestSuite( - 'OverrideTestCase' - ); - - $suite->run($this->result); - - $this->assertEquals(1, count($this->result)); - } - - public function testBeforeClassAndAfterClassAnnotations() - { - $suite = new PHPUnit_Framework_TestSuite( - 'BeforeClassAndAfterClassTest' - ); - - BeforeClassAndAfterClassTest::resetProperties(); - $suite->run($this->result); - - $this->assertEquals(1, BeforeClassAndAfterClassTest::$beforeClassWasRun, '@beforeClass method was not run once for the whole suite.'); - $this->assertEquals(1, BeforeClassAndAfterClassTest::$afterClassWasRun, '@afterClass method was not run once for the whole suite.'); - } - - public function testBeforeAnnotation() - { - $test = new PHPUnit_Framework_TestSuite( - 'BeforeAndAfterTest' - ); - - BeforeAndAfterTest::resetProperties(); - $result = $test->run(); - - $this->assertEquals(2, BeforeAndAfterTest::$beforeWasRun); - $this->assertEquals(2, BeforeAndAfterTest::$afterWasRun); - } - - public function testTestWithAnnotation() - { - $test = new PHPUnit_Framework_TestSuite( - 'TestWithTest' - ); - - BeforeAndAfterTest::resetProperties(); - $result = $test->run(); - - $this->assertEquals(4, count($result->passed())); - } - - public function testSkippedTestDataProvider() - { - $suite = new PHPUnit_Framework_TestSuite('DataProviderSkippedTest'); - - $suite->run($this->result); - - $this->assertEquals(3, $this->result->count()); - $this->assertEquals(1, $this->result->skippedCount()); - } - - public function testIncompleteTestDataProvider() - { - $suite = new PHPUnit_Framework_TestSuite('DataProviderIncompleteTest'); - - $suite->run($this->result); - - $this->assertEquals(3, $this->result->count()); - $this->assertEquals(1, $this->result->notImplementedCount()); - } - - public function testRequirementsBeforeClassHook() - { - $suite = new PHPUnit_Framework_TestSuite( - 'RequirementsClassBeforeClassHookTest' - ); - - $suite->run($this->result); - - $this->assertEquals(0, $this->result->errorCount()); - $this->assertEquals(1, $this->result->skippedCount()); - } - - public function testDontSkipInheritedClass() - { - $suite = new PHPUnit_Framework_TestSuite( - 'DontSkipInheritedClass' - ); - - $dir = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'Inheritance' . DIRECTORY_SEPARATOR; - - $suite->addTestFile($dir . 'InheritanceA.php'); - $suite->addTestFile($dir . 'InheritanceB.php'); - $result = $suite->run(); - $this->assertEquals(2, count($result)); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/TestCaseTest.php b/vendor/phpunit/phpunit/tests/Framework/TestCaseTest.php deleted file mode 100644 index 913327865..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/TestCaseTest.php +++ /dev/null @@ -1,550 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'NoArgTestCaseTest.php'; -require_once dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'Singleton.php'; - -$GLOBALS['a'] = 'a'; -$_ENV['b'] = 'b'; -$_POST['c'] = 'c'; -$_GET['d'] = 'd'; -$_COOKIE['e'] = 'e'; -$_SERVER['f'] = 'f'; -$_FILES['g'] = 'g'; -$_REQUEST['h'] = 'h'; -$GLOBALS['i'] = 'i'; - -/** - * @since Class available since Release 2.0.0 - * @covers PHPUnit_Framework_TestCase - */ -class Framework_TestCaseTest extends PHPUnit_Framework_TestCase -{ - protected $backupGlobalsBlacklist = array('i', 'singleton'); - - /** - * Used be testStaticAttributesBackupPre - */ - protected static $_testStatic = 0; - - public function testCaseToString() - { - $this->assertEquals( - 'Framework_TestCaseTest::testCaseToString', - $this->toString() - ); - } - - public function testSuccess() - { - $test = new Success; - $result = $test->run(); - - $this->assertEquals(PHPUnit_Runner_BaseTestRunner::STATUS_PASSED, $test->getStatus()); - $this->assertEquals(0, $result->errorCount()); - $this->assertEquals(0, $result->failureCount()); - $this->assertEquals(0, $result->skippedCount()); - $this->assertEquals(1, count($result)); - } - - public function testFailure() - { - $test = new Failure; - $result = $test->run(); - - $this->assertEquals(PHPUnit_Runner_BaseTestRunner::STATUS_FAILURE, $test->getStatus()); - $this->assertEquals(0, $result->errorCount()); - $this->assertEquals(1, $result->failureCount()); - $this->assertEquals(0, $result->skippedCount()); - $this->assertEquals(1, count($result)); - } - - public function testError() - { - $test = new TestError; - $result = $test->run(); - - $this->assertEquals(PHPUnit_Runner_BaseTestRunner::STATUS_ERROR, $test->getStatus()); - $this->assertEquals(1, $result->errorCount()); - $this->assertEquals(0, $result->failureCount()); - $this->assertEquals(0, $result->skippedCount()); - $this->assertEquals(1, count($result)); - } - - public function testSkipped() - { - $test = new TestSkipped(); - $result = $test->run(); - - $this->assertEquals(PHPUnit_Runner_BaseTestRunner::STATUS_SKIPPED, $test->getStatus()); - $this->assertEquals('Skipped test', $test->getStatusMessage()); - $this->assertEquals(0, $result->errorCount()); - $this->assertEquals(0, $result->failureCount()); - $this->assertEquals(1, $result->skippedCount()); - $this->assertEquals(1, count($result)); - } - - public function testIncomplete() - { - $test = new TestIncomplete(); - $result = $test->run(); - - $this->assertEquals(PHPUnit_Runner_BaseTestRunner::STATUS_INCOMPLETE, $test->getStatus()); - $this->assertEquals('Incomplete test', $test->getStatusMessage()); - $this->assertEquals(0, $result->errorCount()); - $this->assertEquals(0, $result->failureCount()); - $this->assertEquals(0, $result->skippedCount()); - $this->assertEquals(1, count($result)); - } - - public function testExceptionInSetUp() - { - $test = new ExceptionInSetUpTest('testSomething'); - $result = $test->run(); - - $this->assertTrue($test->setUp); - $this->assertFalse($test->assertPreConditions); - $this->assertFalse($test->testSomething); - $this->assertFalse($test->assertPostConditions); - $this->assertTrue($test->tearDown); - } - - public function testExceptionInAssertPreConditions() - { - $test = new ExceptionInAssertPreConditionsTest('testSomething'); - $result = $test->run(); - - $this->assertTrue($test->setUp); - $this->assertTrue($test->assertPreConditions); - $this->assertFalse($test->testSomething); - $this->assertFalse($test->assertPostConditions); - $this->assertTrue($test->tearDown); - } - - public function testExceptionInTest() - { - $test = new ExceptionInTest('testSomething'); - $result = $test->run(); - - $this->assertTrue($test->setUp); - $this->assertTrue($test->assertPreConditions); - $this->assertTrue($test->testSomething); - $this->assertFalse($test->assertPostConditions); - $this->assertTrue($test->tearDown); - } - - public function testExceptionInAssertPostConditions() - { - $test = new ExceptionInAssertPostConditionsTest('testSomething'); - $result = $test->run(); - - $this->assertTrue($test->setUp); - $this->assertTrue($test->assertPreConditions); - $this->assertTrue($test->testSomething); - $this->assertTrue($test->assertPostConditions); - $this->assertTrue($test->tearDown); - } - - public function testExceptionInTearDown() - { - $test = new ExceptionInTearDownTest('testSomething'); - $result = $test->run(); - - $this->assertTrue($test->setUp); - $this->assertTrue($test->assertPreConditions); - $this->assertTrue($test->testSomething); - $this->assertTrue($test->assertPostConditions); - $this->assertTrue($test->tearDown); - } - - public function testNoArgTestCasePasses() - { - $result = new PHPUnit_Framework_TestResult; - $t = new PHPUnit_Framework_TestSuite('NoArgTestCaseTest'); - - $t->run($result); - - $this->assertEquals(1, count($result)); - $this->assertEquals(0, $result->failureCount()); - $this->assertEquals(0, $result->errorCount()); - } - - public function testWasRun() - { - $test = new WasRun; - $test->run(); - - $this->assertTrue($test->wasRun); - } - - public function testException() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedException('RuntimeException'); - - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExceptionWithMessage() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedException('RuntimeException', 'A runtime error occurred'); - - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExceptionWithWrongMessage() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedException('RuntimeException', 'A logic error occurred'); - - $result = $test->run(); - - $this->assertEquals(1, $result->failureCount()); - $this->assertEquals(1, count($result)); - $this->assertEquals( - "Failed asserting that exception message 'A runtime error occurred' contains 'A logic error occurred'.", - $test->getStatusMessage() - ); - } - - public function testExceptionWithRegexpMessage() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedExceptionRegExp('RuntimeException', '/runtime .*? occurred/'); - - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExceptionWithWrongRegexpMessage() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedExceptionRegExp('RuntimeException', '/logic .*? occurred/'); - - $result = $test->run(); - - $this->assertEquals(1, $result->failureCount()); - $this->assertEquals(1, count($result)); - $this->assertEquals( - "Failed asserting that exception message 'A runtime error occurred' matches '/logic .*? occurred/'.", - $test->getStatusMessage() - ); - } - - /** - * @covers PHPUnit_Framework_Constraint_ExceptionMessageRegExp - */ - public function testExceptionWithInvalidRegexpMessage() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedExceptionRegExp('RuntimeException', '#runtime .*? occurred/'); // wrong delimiter - - $result = $test->run(); - - $this->assertEquals( - "Invalid expected exception message regex given: '#runtime .*? occurred/'", - $test->getStatusMessage() - ); - } - - public function testNoException() - { - $test = new ThrowNoExceptionTestCase('test'); - $test->setExpectedException('RuntimeException'); - - $result = $test->run(); - - $this->assertEquals(1, $result->failureCount()); - $this->assertEquals(1, count($result)); - } - - public function testWrongException() - { - $test = new ThrowExceptionTestCase('test'); - $test->setExpectedException('InvalidArgumentException'); - - $result = $test->run(); - - $this->assertEquals(1, $result->failureCount()); - $this->assertEquals(1, count($result)); - } - - /** - * @backupGlobals enabled - */ - public function testGlobalsBackupPre() - { - global $a; - global $i; - - $this->assertEquals('a', $a); - $this->assertEquals('a', $GLOBALS['a']); - $this->assertEquals('b', $_ENV['b']); - $this->assertEquals('c', $_POST['c']); - $this->assertEquals('d', $_GET['d']); - $this->assertEquals('e', $_COOKIE['e']); - $this->assertEquals('f', $_SERVER['f']); - $this->assertEquals('g', $_FILES['g']); - $this->assertEquals('h', $_REQUEST['h']); - $this->assertEquals('i', $i); - $this->assertEquals('i', $GLOBALS['i']); - - $GLOBALS['a'] = 'aa'; - $GLOBALS['foo'] = 'bar'; - $_ENV['b'] = 'bb'; - $_POST['c'] = 'cc'; - $_GET['d'] = 'dd'; - $_COOKIE['e'] = 'ee'; - $_SERVER['f'] = 'ff'; - $_FILES['g'] = 'gg'; - $_REQUEST['h'] = 'hh'; - $GLOBALS['i'] = 'ii'; - - $this->assertEquals('aa', $a); - $this->assertEquals('aa', $GLOBALS['a']); - $this->assertEquals('bar', $GLOBALS['foo']); - $this->assertEquals('bb', $_ENV['b']); - $this->assertEquals('cc', $_POST['c']); - $this->assertEquals('dd', $_GET['d']); - $this->assertEquals('ee', $_COOKIE['e']); - $this->assertEquals('ff', $_SERVER['f']); - $this->assertEquals('gg', $_FILES['g']); - $this->assertEquals('hh', $_REQUEST['h']); - $this->assertEquals('ii', $i); - $this->assertEquals('ii', $GLOBALS['i']); - } - - public function testGlobalsBackupPost() - { - global $a; - global $i; - - $this->assertEquals('a', $a); - $this->assertEquals('a', $GLOBALS['a']); - $this->assertEquals('b', $_ENV['b']); - $this->assertEquals('c', $_POST['c']); - $this->assertEquals('d', $_GET['d']); - $this->assertEquals('e', $_COOKIE['e']); - $this->assertEquals('f', $_SERVER['f']); - $this->assertEquals('g', $_FILES['g']); - $this->assertEquals('h', $_REQUEST['h']); - $this->assertEquals('ii', $i); - $this->assertEquals('ii', $GLOBALS['i']); - - $this->assertArrayNotHasKey('foo', $GLOBALS); - } - - /** - * @backupGlobals enabled - * @backupStaticAttributes enabled - */ - public function testStaticAttributesBackupPre() - { - $GLOBALS['singleton'] = Singleton::getInstance(); - self::$_testStatic = 123; - } - - /** - * @depends testStaticAttributesBackupPre - */ - public function testStaticAttributesBackupPost() - { - $this->assertNotSame($GLOBALS['singleton'], Singleton::getInstance()); - $this->assertSame(0, self::$_testStatic); - } - - public function testIsInIsolationReturnsFalse() - { - $test = new IsolationTest('testIsInIsolationReturnsFalse'); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testIsInIsolationReturnsTrue() - { - $test = new IsolationTest('testIsInIsolationReturnsTrue'); - $test->setRunTestInSeparateProcess(true); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExpectOutputStringFooActualFoo() - { - $test = new OutputTestCase('testExpectOutputStringFooActualFoo'); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExpectOutputStringFooActualBar() - { - $test = new OutputTestCase('testExpectOutputStringFooActualBar'); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertFalse($result->wasSuccessful()); - } - - public function testExpectOutputRegexFooActualFoo() - { - $test = new OutputTestCase('testExpectOutputRegexFooActualFoo'); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertTrue($result->wasSuccessful()); - } - - public function testExpectOutputRegexFooActualBar() - { - $test = new OutputTestCase('testExpectOutputRegexFooActualBar'); - $result = $test->run(); - - $this->assertEquals(1, count($result)); - $this->assertFalse($result->wasSuccessful()); - } - - public function testSkipsIfRequiresHigherVersionOfPHPUnit() - { - $test = new RequirementsTest('testAlwaysSkip'); - $result = $test->run(); - - $this->assertEquals(1, $result->skippedCount()); - $this->assertEquals( - 'PHPUnit 1111111 (or later) is required.', - $test->getStatusMessage() - ); - } - - public function testSkipsIfRequiresHigherVersionOfPHP() - { - $test = new RequirementsTest('testAlwaysSkip2'); - $result = $test->run(); - - $this->assertEquals(1, $result->skippedCount()); - $this->assertEquals( - 'PHP 9999999 (or later) is required.', - $test->getStatusMessage() - ); - } - - public function testSkipsIfRequiresNonExistingOs() - { - $test = new RequirementsTest('testAlwaysSkip3'); - $result = $test->run(); - - $this->assertEquals(1, $result->skippedCount()); - $this->assertEquals( - 'Operating system matching /DOESNOTEXIST/i is required.', - $test->getStatusMessage() - ); - } - - public function testSkipsIfRequiresNonExistingFunction() - { - $test = new RequirementsTest('testNine'); - $result = $test->run(); - - $this->assertEquals(1, $result->skippedCount()); - $this->assertEquals( - 'Function testFunc is required.', - $test->getStatusMessage() - ); - } - - public function testSkipsIfRequiresNonExistingExtension() - { - $test = new RequirementsTest('testTen'); - $result = $test->run(); - - $this->assertEquals( - 'Extension testExt is required.', - $test->getStatusMessage() - ); - } - - public function testSkipsProvidesMessagesForAllSkippingReasons() - { - $test = new RequirementsTest('testAllPossibleRequirements'); - $result = $test->run(); - - $this->assertEquals( - 'PHP 99-dev (or later) is required.' . PHP_EOL . - 'PHPUnit 9-dev (or later) is required.' . PHP_EOL . - 'Operating system matching /DOESNOTEXIST/i is required.' . PHP_EOL . - 'Function testFuncOne is required.' . PHP_EOL . - 'Function testFuncTwo is required.' . PHP_EOL . - 'Extension testExtOne is required.' . PHP_EOL . - 'Extension testExtTwo is required.', - $test->getStatusMessage() - ); - } - - public function testRequiringAnExistingMethodDoesNotSkip() - { - $test = new RequirementsTest('testExistingMethod'); - $result = $test->run(); - $this->assertEquals(0, $result->skippedCount()); - } - - public function testRequiringAnExistingFunctionDoesNotSkip() - { - $test = new RequirementsTest('testExistingFunction'); - $result = $test->run(); - $this->assertEquals(0, $result->skippedCount()); - } - - public function testRequiringAnExistingExtensionDoesNotSkip() - { - $test = new RequirementsTest('testExistingExtension'); - $result = $test->run(); - $this->assertEquals(0, $result->skippedCount()); - } - - public function testRequiringAnExistingOsDoesNotSkip() - { - $test = new RequirementsTest('testExistingOs'); - $result = $test->run(); - $this->assertEquals(0, $result->skippedCount()); - } - - public function testCurrentWorkingDirectoryIsRestored() - { - $expectedCwd = getcwd(); - - $test = new ChangeCurrentWorkingDirectoryTest('testSomethingThatChangesTheCwd'); - $test->run(); - - $this->assertSame($expectedCwd, getcwd()); - } - - /** - * @requires PHP 7 - * @expectedException TypeError - */ - public function testTypeErrorCanBeExpected() - { - $o = new ClassWithScalarTypeDeclarations; - $o->foo(null, null); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/TestFailureTest.php b/vendor/phpunit/phpunit/tests/Framework/TestFailureTest.php deleted file mode 100644 index 8df0a3945..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/TestFailureTest.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since File available since Release 3.7.20 - */ -class Framework_TestFailureTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHPUnit_Framework_TestFailure::toString - */ - public function testToString() - { - $test = new self(__FUNCTION__); - $exception = new PHPUnit_Framework_Exception('message'); - $failure = new PHPUnit_Framework_TestFailure($test, $exception); - - $this->assertEquals(__METHOD__ . ': message', $failure->toString()); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/TestImplementorTest.php b/vendor/phpunit/phpunit/tests/Framework/TestImplementorTest.php deleted file mode 100644 index f10a5098a..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/TestImplementorTest.php +++ /dev/null @@ -1,30 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.0.0 - */ -class Framework_TestImplementorTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHPUnit_Framework_TestCase - */ - public function testSuccessfulRun() - { - $result = new PHPUnit_Framework_TestResult; - - $test = new DoubleTestCase(new Success); - $test->run($result); - - $this->assertEquals(count($test), count($result)); - $this->assertEquals(0, $result->errorCount()); - $this->assertEquals(0, $result->failureCount()); - } -} diff --git a/vendor/phpunit/phpunit/tests/Framework/TestListenerTest.php b/vendor/phpunit/phpunit/tests/Framework/TestListenerTest.php deleted file mode 100644 index 589741bfd..000000000 --- a/vendor/phpunit/phpunit/tests/Framework/TestListenerTest.php +++ /dev/null @@ -1,108 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.0.0 - * @covers PHPUnit_Framework_TestCase - */ -class Framework_TestListenerTest extends PHPUnit_Framework_TestCase implements PHPUnit_Framework_TestListener -{ - protected $endCount; - protected $errorCount; - protected $failureCount; - protected $notImplementedCount; - protected $riskyCount; - protected $skippedCount; - protected $result; - protected $startCount; - - public function addError(PHPUnit_Framework_Test $test, Exception $e, $time) - { - $this->errorCount++; - } - - public function addFailure(PHPUnit_Framework_Test $test, PHPUnit_Framework_AssertionFailedError $e, $time) - { - $this->failureCount++; - } - - public function addIncompleteTest(PHPUnit_Framework_Test $test, Exception $e, $time) - { - $this->notImplementedCount++; - } - - public function addRiskyTest(PHPUnit_Framework_Test $test, Exception $e, $time) - { - $this->riskyCount++; - } - - public function addSkippedTest(PHPUnit_Framework_Test $test, Exception $e, $time) - { - $this->skippedCount++; - } - - public function startTestSuite(PHPUnit_Framework_TestSuite $suite) - { - } - - public function endTestSuite(PHPUnit_Framework_TestSuite $suite) - { - } - - public function startTest(PHPUnit_Framework_Test $test) - { - $this->startCount++; - } - - public function endTest(PHPUnit_Framework_Test $test, $time) - { - $this->endCount++; - } - - protected function setUp() - { - $this->result = new PHPUnit_Framework_TestResult; - $this->result->addListener($this); - - $this->endCount = 0; - $this->failureCount = 0; - $this->notImplementedCount = 0; - $this->riskyCount = 0; - $this->skippedCount = 0; - $this->startCount = 0; - } - - public function testError() - { - $test = new TestError; - $test->run($this->result); - - $this->assertEquals(1, $this->errorCount); - $this->assertEquals(1, $this->endCount); - } - - public function testFailure() - { - $test = new Failure; - $test->run($this->result); - - $this->assertEquals(1, $this->failureCount); - $this->assertEquals(1, $this->endCount); - } - - public function testStartStop() - { - $test = new Success; - $test->run($this->result); - - $this->assertEquals(1, $this->startCount); - $this->assertEquals(1, $this->endCount); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/1021.phpt b/vendor/phpunit/phpunit/tests/Regression/1021.phpt deleted file mode 100644 index 45f4708d4..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/1021.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -#1021: Depending on a test that uses a data provider does not work ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/Regression/1021/Issue1021Test.php b/vendor/phpunit/phpunit/tests/Regression/1021/Issue1021Test.php deleted file mode 100644 index 5814e94c3..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/1021/Issue1021Test.php +++ /dev/null @@ -1,23 +0,0 @@ -assertTrue($data); - } - - /** - * @depends testSomething - */ - public function testSomethingElse() - { - } - - public function provider() - { - return array(array(true)); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/523.phpt b/vendor/phpunit/phpunit/tests/Regression/523.phpt deleted file mode 100644 index 6ba2e4224..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/523.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -#523: assertAttributeEquals does not work with classes extending ArrayIterator ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/Regression/523/Issue523Test.php b/vendor/phpunit/phpunit/tests/Regression/523/Issue523Test.php deleted file mode 100644 index 80124f1da..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/523/Issue523Test.php +++ /dev/null @@ -1,13 +0,0 @@ -assertAttributeEquals('foo', 'field', new Issue523()); - } -}; - -class Issue523 extends ArrayIterator -{ - protected $field = 'foo'; -} diff --git a/vendor/phpunit/phpunit/tests/Regression/578.phpt b/vendor/phpunit/phpunit/tests/Regression/578.phpt deleted file mode 100644 index c50d2e306..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/578.phpt +++ /dev/null @@ -1,37 +0,0 @@ ---TEST-- -#578: Double printing of trace line for exceptions from notices and warnings ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -EEE - -Time: %s, Memory: %sMb - -There were 3 errors: - -1) Issue578Test::testNoticesDoublePrintStackTrace -Invalid error type specified - -%sIssue578Test.php:%i - -2) Issue578Test::testWarningsDoublePrintStackTrace -Invalid error type specified - -%sIssue578Test.php:%i - -3) Issue578Test::testUnexpectedExceptionsPrintsCorrectly -Exception: Double printed exception - -%sIssue578Test.php:%i - -FAILURES! -Tests: 3, Assertions: 0, Errors: 3. diff --git a/vendor/phpunit/phpunit/tests/Regression/578/Issue578Test.php b/vendor/phpunit/phpunit/tests/Regression/578/Issue578Test.php deleted file mode 100644 index 262d97f64..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/578/Issue578Test.php +++ /dev/null @@ -1,20 +0,0 @@ -iniSet('error_reporting', E_ALL | E_NOTICE); - trigger_error('Stack Trace Test Notice', E_NOTICE); - } - - public function testWarningsDoublePrintStackTrace() - { - $this->iniSet('error_reporting', E_ALL | E_NOTICE); - trigger_error('Stack Trace Test Notice', E_WARNING); - } - - public function testUnexpectedExceptionsPrintsCorrectly() - { - throw new Exception('Double printed exception'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/684.phpt b/vendor/phpunit/phpunit/tests/Regression/684.phpt deleted file mode 100644 index ca88a5504..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/684.phpt +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -#684: Unable to find test class when no test methods exists ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Warning -No tests found in class "Foo_Bar_Issue684Test". - -FAILURES! -Tests: 1, Assertions: 0, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/684/Issue684Test.php b/vendor/phpunit/phpunit/tests/Regression/684/Issue684Test.php deleted file mode 100644 index e8e5d87ec..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/684/Issue684Test.php +++ /dev/null @@ -1,4 +0,0 @@ - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 0 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/783/ChildSuite.php b/vendor/phpunit/phpunit/tests/Regression/783/ChildSuite.php deleted file mode 100644 index 8bac5144b..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/783/ChildSuite.php +++ /dev/null @@ -1,15 +0,0 @@ -addTestSuite('OneTest'); - $suite->addTestSuite('TwoTest'); - - return $suite; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/783/OneTest.php b/vendor/phpunit/phpunit/tests/Regression/783/OneTest.php deleted file mode 100644 index 71951582e..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/783/OneTest.php +++ /dev/null @@ -1,10 +0,0 @@ -addTest(ChildSuite::suite()); - - return $suite; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/783/TwoTest.php b/vendor/phpunit/phpunit/tests/Regression/783/TwoTest.php deleted file mode 100644 index 580246ce9..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/783/TwoTest.php +++ /dev/null @@ -1,10 +0,0 @@ - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.1.2 - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1149/Issue1149Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1149/Issue1149Test.php deleted file mode 100644 index 01ac870a0..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1149/Issue1149Test.php +++ /dev/null @@ -1,18 +0,0 @@ -assertTrue(true); - print '1'; - } - - /** - * @runInSeparateProcess - */ - public function testTwo() - { - $this->assertTrue(true); - print '2'; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1216.phpt deleted file mode 100644 index d13403b4b..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216.phpt +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -GH-1216: PHPUnit bootstrap must take globals vars even when the file is specified in command line ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'Issue1216Test::testConfigAvailableInBootstrap'. -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/Issue1216Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/Issue1216Test.php deleted file mode 100644 index cfceaf582..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/Issue1216Test.php +++ /dev/null @@ -1,8 +0,0 @@ -assertTrue($_ENV['configAvailableInBootstrap']); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/bootstrap1216.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/bootstrap1216.php deleted file mode 100644 index cec2724aa..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1216/bootstrap1216.php +++ /dev/null @@ -1,2 +0,0 @@ - - - Issue1216Test.php - - - - - diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1265.phpt deleted file mode 100644 index a179d5d45..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -GH-1265: Could not use "PHPUnit_Runner_StandardTestSuiteLoader" as loader ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/Issue1265Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/Issue1265Test.php deleted file mode 100644 index 68d71b3c0..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/Issue1265Test.php +++ /dev/null @@ -1,8 +0,0 @@ -assertTrue(true); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/phpunit1265.xml b/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/phpunit1265.xml deleted file mode 100644 index 27fdd529f..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1265/phpunit1265.xml +++ /dev/null @@ -1,2 +0,0 @@ - - diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1330.phpt deleted file mode 100644 index c31073ecd..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330.phpt +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -GH-1330: Allow non-ambiguous shortened longopts ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'Issue1330Test::testTrue'. -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/Issue1330Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/Issue1330Test.php deleted file mode 100644 index 0829cb95b..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/Issue1330Test.php +++ /dev/null @@ -1,8 +0,0 @@ -assertTrue(PHPUNIT_1330); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/phpunit1330.xml b/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/phpunit1330.xml deleted file mode 100644 index a61e0cc10..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1330/phpunit1330.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1335.phpt deleted file mode 100644 index cd6aade15..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -GH-1335: exportVariable multiple backslash problem ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -............ - -Time: %s, Memory: %sMb - -OK (12 tests, 12 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/Issue1335Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/Issue1335Test.php deleted file mode 100644 index 4407ec8df..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/Issue1335Test.php +++ /dev/null @@ -1,67 +0,0 @@ -assertEquals('Hello', $GLOBALS['globalString']); - } - - public function testGlobalIntTruthy() - { - $this->assertEquals(1, $GLOBALS['globalIntTruthy']); - } - - public function testGlobalIntFalsey() - { - $this->assertEquals(0, $GLOBALS['globalIntFalsey']); - } - - public function testGlobalFloat() - { - $this->assertEquals(1.123, $GLOBALS['globalFloat']); - } - - public function testGlobalBoolTrue() - { - $this->assertEquals(true, $GLOBALS['globalBoolTrue']); - } - - public function testGlobalBoolFalse() - { - $this->assertEquals(false, $GLOBALS['globalBoolFalse']); - } - - public function testGlobalNull() - { - $this->assertEquals(null, $GLOBALS['globalNull']); - } - - public function testGlobalArray() - { - $this->assertEquals(array('foo'), $GLOBALS['globalArray']); - } - - public function testGlobalNestedArray() - { - $this->assertEquals(array(array('foo')), $GLOBALS['globalNestedArray']); - } - - public function testGlobalObject() - { - $this->assertEquals((object) array('foo'=> 'bar'), $GLOBALS['globalObject']); - } - - public function testGlobalObjectWithBackSlashString() - { - $this->assertEquals((object) array('foo'=> 'back\\slash'), $GLOBALS['globalObjectWithBackSlashString']); - } - - public function testGlobalObjectWithDoubleBackSlashString() - { - $this->assertEquals((object) array('foo'=> 'back\\\\slash'), $GLOBALS['globalObjectWithDoubleBackSlashString']); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/bootstrap1335.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/bootstrap1335.php deleted file mode 100644 index 073a87e35..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1335/bootstrap1335.php +++ /dev/null @@ -1,13 +0,0 @@ - 'bar'); -$globalObjectWithBackSlashString = (object) array('foo'=> 'back\\slash'); -$globalObjectWithDoubleBackSlashString = (object) array('foo'=> 'back\\\\slash'); diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1337.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1337.phpt deleted file mode 100644 index 9c1d76f23..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1337.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -GH-1337: Data Provider with \ at the end of the name breaks with process isolation ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) \ No newline at end of file diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1337/Issue1337Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1337/Issue1337Test.php deleted file mode 100644 index b972b2ade..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1337/Issue1337Test.php +++ /dev/null @@ -1,19 +0,0 @@ -assertTrue($a); - } - - public function dataProvider() - { - return array( - 'c:\\'=> array(true), - 0.9 => array(true) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1348.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1348.phpt deleted file mode 100644 index 82f94ec6e..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1348.phpt +++ /dev/null @@ -1,35 +0,0 @@ ---TEST-- -GH-1348: STDOUT/STDERR IO streams should exist in process isolation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. -STDOUT does not break test result -E - -Time: %s, Memory: %sMb - -There was 1 error: - -1) Issue1348Test::testSTDERR -PHPUnit_Framework_Exception: STDERR works as usual. - -FAILURES! -Tests: 2, Assertions: 1, Errors: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1348/Issue1348Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1348/Issue1348Test.php deleted file mode 100644 index d3c82f0e8..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1348/Issue1348Test.php +++ /dev/null @@ -1,14 +0,0 @@ -assertTrue(true); - } - - public function testSTDERR() - { - fwrite(STDERR, 'STDERR works as usual.'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1351.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1351.phpt deleted file mode 100644 index 2dbc2af74..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1351.phpt +++ /dev/null @@ -1,48 +0,0 @@ ---TEST-- -GH-1351: Test result does not serialize test class in process isolation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F.E.E - -Time: %s, Memory: %sMb - -There were 2 errors: - -1) Issue1351Test::testExceptionPre -RuntimeException: Expected rethrown exception. -%A -Caused by -LogicException: Expected exception. -%A - -2) Issue1351Test::testPhpCoreLanguageException -PDOException: SQLSTATE[HY000]: General error: 1 no such table: php_wtf -%A - --- - -There was 1 failure: - -1) Issue1351Test::testFailurePre -Expected failure. -%A -FAILURES! -Tests: 5, Assertions: 5, Errors: 2, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1351/ChildProcessClass1351.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1351/ChildProcessClass1351.php deleted file mode 100644 index 24c053766..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1351/ChildProcessClass1351.php +++ /dev/null @@ -1,4 +0,0 @@ -instance = new ChildProcessClass1351(); - $this->assertFalse(true, 'Expected failure.'); - } - - public function testFailurePost() - { - $this->assertNull($this->instance); - $this->assertFalse(class_exists('ChildProcessClass1351', false), 'ChildProcessClass1351 is not loaded.'); - } - - /** - * @runInSeparateProcess - */ - public function testExceptionPre() - { - $this->instance = new ChildProcessClass1351(); - try { - throw new LogicException('Expected exception.'); - } catch (LogicException $e) { - throw new RuntimeException('Expected rethrown exception.', 0, $e); - } - } - - public function testExceptionPost() - { - $this->assertNull($this->instance); - $this->assertFalse(class_exists('ChildProcessClass1351', false), 'ChildProcessClass1351 is not loaded.'); - } - - public function testPhpCoreLanguageException() - { - // User-space code cannot instantiate a PDOException with a string code, - // so trigger a real one. - $connection = new PDO('sqlite::memory:'); - $connection->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); - $connection->query("DELETE FROM php_wtf WHERE exception_code = 'STRING'"); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1374.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1374.phpt deleted file mode 100644 index 84d13be22..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1374.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -GH-1374: tearDown() is called despite unmet requirements ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -S - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Skipped: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1374/Issue1374Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1374/Issue1374Test.php deleted file mode 100644 index ad6a3bf09..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1374/Issue1374Test.php +++ /dev/null @@ -1,21 +0,0 @@ -fail('This should not be reached'); - } - - protected function tearDown() - { - print __FUNCTION__; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1437.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1437.phpt deleted file mode 100644 index f9bd41bf3..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1437.phpt +++ /dev/null @@ -1,28 +0,0 @@ ---TEST-- -GH-1437: Risky test messages mask failures ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue1437Test::testFailure -Failed asserting that false is true. - -%sIssue1437Test.php:%i - -FAILURES! -Tests: 1, Assertions: 1, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1437/Issue1437Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1437/Issue1437Test.php deleted file mode 100644 index bff4b205a..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1437/Issue1437Test.php +++ /dev/null @@ -1,9 +0,0 @@ -assertTrue(false); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1468.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1468.phpt deleted file mode 100644 index 23c410b1f..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1468.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -GH-1468: Incomplete and @todo annotated tests are counted twice ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -I - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Incomplete: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1468/Issue1468Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1468/Issue1468Test.php deleted file mode 100644 index 535b25b99..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1468/Issue1468Test.php +++ /dev/null @@ -1,11 +0,0 @@ -markTestIncomplete(); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1471.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1471.phpt deleted file mode 100644 index 631d6e6dc..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1471.phpt +++ /dev/null @@ -1,28 +0,0 @@ ---TEST-- -GH-1471: Output made while test is running is printed although expectOutputString() is used when an assertion fails ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue1471Test::testFailure -Failed asserting that false is true. - -%s/Issue1471Test.php:10 - -FAILURES! -Tests: 1, Assertions: 1, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1471/Issue1471Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1471/Issue1471Test.php deleted file mode 100644 index 28f127485..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1471/Issue1471Test.php +++ /dev/null @@ -1,12 +0,0 @@ -expectOutputString('*'); - - print '*'; - - $this->assertTrue(false); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1472.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1472.phpt deleted file mode 100644 index 3e605b406..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1472.phpt +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -GH-1472: assertEqualXMLStructure modifies the tested elements ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 4 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1472/Issue1472Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1472/Issue1472Test.php deleted file mode 100644 index a392773a9..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1472/Issue1472Test.php +++ /dev/null @@ -1,21 +0,0 @@ -loadXML(''); - - $xpath = new DOMXPath($doc); - - $labelElement = $doc->getElementsByTagName('label')->item(0); - - $this->assertEquals(1, $xpath->evaluate('count(//label[text() = "text content"])')); - - $expectedElmt = $doc->createElement('label', 'text content'); - $this->assertEqualXMLStructure($expectedElmt, $labelElement); - - // the following assertion fails, even though it passed before - which is due to the assertEqualXMLStructure() has modified the $labelElement - $this->assertEquals(1, $xpath->evaluate('count(//label[text() = "text content"])')); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1570.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/1570.phpt deleted file mode 100644 index a94b961ac..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1570.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -GH-1570: Test that prints output is marked as failure and not as risky when --disallow-test-output is used ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -R* - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Risky: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/1570/Issue1570Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/1570/Issue1570Test.php deleted file mode 100644 index 0cb1b65de..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/1570/Issue1570Test.php +++ /dev/null @@ -1,8 +0,0 @@ - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.FFF - -Time: %s, Memory: %sMb - -There were 3 failures: - -1) Issue244Test::testFails -Failed asserting that '123StringCode' is equal to expected exception code 'OtherString'. - -2) Issue244Test::testFailsTooIfExpectationIsANumber -Failed asserting that '123StringCode' is equal to expected exception code 123. - -3) Issue244Test::testFailsTooIfExceptionCodeIsANumber -Failed asserting that 123 is equal to expected exception code '123String'. - -FAILURES! -Tests: 4, Assertions: 8, Failures: 3. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/244/Issue244Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/244/Issue244Test.php deleted file mode 100644 index 621c4cf54..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/244/Issue244Test.php +++ /dev/null @@ -1,55 +0,0 @@ -code = '123StringCode'; - } -} - -class Issue244ExceptionIntCode extends Exception -{ - public function __construct() - { - $this->code = 123; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/322.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/322.phpt deleted file mode 100644 index 0d892c720..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/322.phpt +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -GH-322: group commandline option should override group/exclude setting in phpunit.xml ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'Issue322Test::testOne'. -. - -Time: %s, Memory: %sMb - -OK (1 test, 0 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/322/Issue322Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/322/Issue322Test.php deleted file mode 100644 index 618bcaa19..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/322/Issue322Test.php +++ /dev/null @@ -1,17 +0,0 @@ - - - Test.php - - - - - one - - - diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/433.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/433.phpt deleted file mode 100644 index ead9437c3..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/433.phpt +++ /dev/null @@ -1,31 +0,0 @@ ---TEST-- -GH-433: expectOutputString not completely working as expected ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -..F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue433Test::testNotMatchingOutput -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ --'foo' -+'bar' - -FAILURES! -Tests: 3, Assertions: 3, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/433/Issue433Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/433/Issue433Test.php deleted file mode 100644 index e0a91b35b..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/433/Issue433Test.php +++ /dev/null @@ -1,21 +0,0 @@ -expectOutputString('test'); - print 'test'; - } - - public function testOutputWithExpectationAfter() - { - print 'test'; - $this->expectOutputString('test'); - } - - public function testNotMatchingOutput() - { - print 'bar'; - $this->expectOutputString('foo'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/445.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/445.phpt deleted file mode 100644 index e57e7fbf0..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/445.phpt +++ /dev/null @@ -1,32 +0,0 @@ ---TEST-- -GH-455: expectOutputString not working in strict mode ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -..F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue445Test::testNotMatchingOutput -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ --'foo' -+'bar' - -FAILURES! -Tests: 3, Assertions: 3, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/445/Issue445Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/445/Issue445Test.php deleted file mode 100644 index c3090259e..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/445/Issue445Test.php +++ /dev/null @@ -1,21 +0,0 @@ -expectOutputString('test'); - print 'test'; - } - - public function testOutputWithExpectationAfter() - { - print 'test'; - $this->expectOutputString('test'); - } - - public function testNotMatchingOutput() - { - print 'bar'; - $this->expectOutputString('foo'); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/498.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/498.phpt deleted file mode 100644 index 51dbe759c..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/498.phpt +++ /dev/null @@ -1,29 +0,0 @@ ---TEST-- -GH-498: The test methods won't be run if a dataProvider throws Exception and --group is added in command line ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Warning -The data provider specified for Issue498Test::shouldBeFalse is invalid. -Can't create the data - -FAILURES! -Tests: 1, Assertions: 0, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/498/Issue498Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/498/Issue498Test.php deleted file mode 100644 index 49fa76454..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/498/Issue498Test.php +++ /dev/null @@ -1,44 +0,0 @@ -assertTrue(true); - } - - /** - * @test - * @dataProvider shouldBeFalseDataProvider - * @group trueOnly - */ - public function shouldBeFalse($testData) - { - $this->assertFalse(false); - } - - public function shouldBeTrueDataProvider() - { - - //throw new Exception("Can't create the data"); - return array( - array(true), - array(false) - ); - } - - public function shouldBeFalseDataProvider() - { - throw new Exception("Can't create the data"); - - return array( - array(true), - array(false) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/503.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/503.phpt deleted file mode 100644 index 2e7b30f3b..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/503.phpt +++ /dev/null @@ -1,33 +0,0 @@ ---TEST-- -GH-503: assertEquals() Line Ending Differences Are Obscure ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue503Test::testCompareDifferentLineEndings -Failed asserting that two strings are identical. ---- Expected -+++ Actual -@@ @@ - #Warning: Strings contain different line endings! - foo - -%s:%i - -FAILURES! -Tests: 1, Assertions: 1, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/503/Issue503Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/503/Issue503Test.php deleted file mode 100644 index 75ca8d454..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/503/Issue503Test.php +++ /dev/null @@ -1,11 +0,0 @@ -assertSame( - "foo\n", - "foo\r\n" - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/581.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/581.phpt deleted file mode 100644 index c2d654593..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/581.phpt +++ /dev/null @@ -1,42 +0,0 @@ ---TEST-- -GH-581: PHPUnit_Util_Type::export adds extra newlines in Windows ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Issue581Test::testExportingObjectsDoesNotBreakWindowsLineFeeds -Failed asserting that two objects are equal. ---- Expected -+++ Actual -@@ @@ - stdClass Object ( - 0 => 1 - 1 => 2 - 2 => 'Test\n' - 3 => 4 -- 4 => 5 -+ 4 => 1 - 5 => 6 - 6 => 7 - 7 => 8 - ) - -%s:%i - -FAILURES! -Tests: 1, Assertions: 1, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/581/Issue581Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/581/Issue581Test.php deleted file mode 100644 index 51de83b18..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/581/Issue581Test.php +++ /dev/null @@ -1,11 +0,0 @@ -assertEquals( - (object) array(1, 2, "Test\r\n", 4, 5, 6, 7, 8), - (object) array(1, 2, "Test\r\n", 4, 1, 6, 7, 8) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/74.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/74.phpt deleted file mode 100644 index 8a4f79dc8..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/74.phpt +++ /dev/null @@ -1,28 +0,0 @@ ---TEST-- -GH-74: catchable fatal error in 3.5 ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -E - -Time: %s, Memory: %sMb - -There was 1 error: - -1) Issue74Test::testCreateAndThrowNewExceptionInProcessIsolation -NewException: Testing GH-74 - -%sIssue74Test.php:7 - -FAILURES! -Tests: 1, Assertions: 0, Errors: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/74/Issue74Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/74/Issue74Test.php deleted file mode 100644 index 72f35928a..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/74/Issue74Test.php +++ /dev/null @@ -1,9 +0,0 @@ - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Warning -The data provider specified for Issue765Test::testDependent is invalid. - -FAILURES! -Tests: 2, Assertions: 1, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/765/Issue765Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/765/Issue765Test.php deleted file mode 100644 index a47474b27..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/765/Issue765Test.php +++ /dev/null @@ -1,22 +0,0 @@ -assertTrue(true); - } - - /** - * @depends testDependee - * @dataProvider dependentProvider - */ - public function testDependent($a) - { - $this->assertTrue(true); - } - - public function dependentProvider() - { - throw new Exception; - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/797.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/797.phpt deleted file mode 100644 index 4a6490f0f..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/797.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -GH-797: Disabled $preserveGlobalState does not load bootstrap.php. ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) \ No newline at end of file diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/797/Issue797Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/797/Issue797Test.php deleted file mode 100644 index b1c1b8f92..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/797/Issue797Test.php +++ /dev/null @@ -1,10 +0,0 @@ -assertEquals(GITHUB_ISSUE, 797); - } -} diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/797/bootstrap797.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/797/bootstrap797.php deleted file mode 100644 index 03890a35a..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/797/bootstrap797.php +++ /dev/null @@ -1,6 +0,0 @@ - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -............................................................... 63 / 150 ( 42%) -............................................................... 126 / 150 ( 84%) -........................ - -Time: %s, Memory: %sMb - -OK (150 tests, 150 assertions) diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php5.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php5.phpt deleted file mode 100644 index 89b740235..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php5.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -GH-873: PHPUnit suppresses exceptions thrown outside of test case function ---SKIPIF-- - 5) { - print 'skip: PHP 5 is required'; -} -?> ---FILE-- - ---EXPECTF-- - -Fatal error: Uncaught exception 'Exception' with message 'PHPUnit suppresses exceptions thrown outside of test case function' in %s:%i -Stack trace: -%a diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php7.phpt b/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php7.phpt deleted file mode 100644 index b022f9976..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/873-php7.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -GH-873: PHPUnit suppresses exceptions thrown outside of test case function ---SKIPIF-- - ---FILE-- - ---EXPECTF-- - -Fatal error: Uncaught Exception: PHPUnit suppresses exceptions thrown outside of test case function in %s:%i -Stack trace: -%a diff --git a/vendor/phpunit/phpunit/tests/Regression/GitHub/873/Issue873Test.php b/vendor/phpunit/phpunit/tests/Regression/GitHub/873/Issue873Test.php deleted file mode 100644 index 70fd90464..000000000 --- a/vendor/phpunit/phpunit/tests/Regression/GitHub/873/Issue873Test.php +++ /dev/null @@ -1,9 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.0.0 - * @covers PHPUnit_Runner_BaseTestRunner - */ -class Runner_BaseTestRunnerTest extends PHPUnit_Framework_TestCase -{ - public function testInvokeNonStaticSuite() - { - $runner = new MockRunner; - $runner->getTest('NonStatic'); - } -} diff --git a/vendor/phpunit/phpunit/tests/TextUI/abstract-test-class.phpt b/vendor/phpunit/phpunit/tests/TextUI/abstract-test-class.phpt deleted file mode 100644 index 8d6c07a32..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/abstract-test-class.phpt +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -phpunit AbstractTest ../_files/AbstractTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Warning -Cannot instantiate class "AbstractTest". - -FAILURES! -Tests: 1, Assertions: 0, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/colors-always.phpt b/vendor/phpunit/phpunit/tests/TextUI/colors-always.phpt deleted file mode 100644 index 28b527d68..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/colors-always.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit --colors=always BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -%s[30;42mOK (3 tests, 3 assertions)%s[0m diff --git a/vendor/phpunit/phpunit/tests/TextUI/concrete-test-class.phpt b/vendor/phpunit/phpunit/tests/TextUI/concrete-test-class.phpt deleted file mode 100644 index f01bd7995..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/concrete-test-class.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit ConcreteTest ../_files/ConcreteTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 0 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/custom-printer-debug.phpt b/vendor/phpunit/phpunit/tests/TextUI/custom-printer-debug.phpt deleted file mode 100644 index 19b9e0596..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/custom-printer-debug.phpt +++ /dev/null @@ -1,27 +0,0 @@ ---TEST-- -phpunit -c ../_files/configuration.custom-printer.xml --debug BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'BankAccountTest::testBalanceIsInitiallyZero'. -. -Starting test 'BankAccountTest::testBalanceCannotBecomeNegative'. -. -Starting test 'BankAccountTest::testBalanceCannotBecomeNegative2'. -. - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/custom-printer-verbose.phpt b/vendor/phpunit/phpunit/tests/TextUI/custom-printer-verbose.phpt deleted file mode 100644 index 2e2a99099..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/custom-printer-verbose.phpt +++ /dev/null @@ -1,32 +0,0 @@ ---TEST-- -phpunit -c ../_files/configuration.custom-printer.xml --verbose IncompleteTest ../_files/IncompleteTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Runtime: %s -Configuration: %sconfiguration.custom-printer.xml - -I - -Time: %s, Memory: %sMb - -There was 1 incomplete test: - -1) IncompleteTest::testIncomplete -Test incomplete - -%s - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Incomplete: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-debug.phpt b/vendor/phpunit/phpunit/tests/TextUI/dataprovider-debug.phpt deleted file mode 100644 index e7e49b4eb..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-debug.phpt +++ /dev/null @@ -1,34 +0,0 @@ ---TEST-- -phpunit --debug DataProviderDebugTest ../_files/DataProviderDebugTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'DataProviderDebugTest::testProvider with data set #0 (null, true, 1, 1.0)'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #1 (1.2, resource(%d) of type (stream), '1')'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #2 (array(array(1, 2, 3), array(3, 4, 5)))'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #3 ('this\nis\na\nvery\nvery\nvery\nvery...g\ntext')'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #4 (stdClass Object (), stdClass Object (...), array(), SplObjectStorage Object (...), stdClass Object (...))'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #5 (Binary String: 0x000102030405, Binary String: 0x0e0f101112131...c1d1e1f)'. -. -Starting test 'DataProviderDebugTest::testProvider with data set #6 (Binary String: 0x0009)'. -. - -Time: %s, Memory: %sMb - -OK (7 tests, 7 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml-isolation.phpt deleted file mode 100644 index e1c4571d5..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml-isolation.phpt +++ /dev/null @@ -1,47 +0,0 @@ ---TEST-- -phpunit --process-isolation --log-junit php://stdout DataProviderTest ../_files/DataProviderTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -..F. - - - - - - - DataProviderTest::testAdd with data set #2 (1, 1, 3) -Failed asserting that 2 matches expected 3. - -%s:%i - - - - - - - - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) DataProviderTest::testAdd with data set #2 (1, 1, 3) -Failed asserting that 2 matches expected 3. - -%s:%i - -FAILURES! -Tests: 4, Assertions: 4, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml.phpt b/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml.phpt deleted file mode 100644 index a14b4664a..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-log-xml.phpt +++ /dev/null @@ -1,46 +0,0 @@ ---TEST-- -phpunit --log-junit php://stdout DataProviderTest ../_files/DataProviderTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -..F. - - - - - - - DataProviderTest::testAdd with data set #2 (1, 1, 3) -Failed asserting that 2 matches expected 3. - -%s:%i - - - - - - - - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) DataProviderTest::testAdd with data set #2 (1, 1, 3) -Failed asserting that 2 matches expected 3. - -%s:%i - -FAILURES! -Tests: 4, Assertions: 4, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-testdox.phpt b/vendor/phpunit/phpunit/tests/TextUI/dataprovider-testdox.phpt deleted file mode 100644 index 75973feaa..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dataprovider-testdox.phpt +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -phpunit --testdox DataProviderTest ../_files/DataProviderTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -DataProvider - [ ] Add diff --git a/vendor/phpunit/phpunit/tests/TextUI/debug.phpt b/vendor/phpunit/phpunit/tests/TextUI/debug.phpt deleted file mode 100644 index 1639484ca..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/debug.phpt +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -phpunit --debug BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - -Starting test 'BankAccountTest::testBalanceIsInitiallyZero'. -. -Starting test 'BankAccountTest::testBalanceCannotBecomeNegative'. -. -Starting test 'BankAccountTest::testBalanceCannotBecomeNegative2'. -. - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/default-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/default-isolation.phpt deleted file mode 100644 index 864484c82..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/default-isolation.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -phpunit --process-isolation BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/default.phpt b/vendor/phpunit/phpunit/tests/TextUI/default.phpt deleted file mode 100644 index 9fefe1a1b..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/default.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies-isolation.phpt deleted file mode 100644 index 226d3d834..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies-isolation.phpt +++ /dev/null @@ -1,40 +0,0 @@ ---TEST-- -phpunit --process-isolation --verbose DependencyTestSuite ../_files/DependencyTestSuite.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Runtime: %s - -...FSS - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) DependencyFailureTest::testOne - -%s:%i - --- - -There were 2 skipped tests: - -1) DependencyFailureTest::testTwo -This test depends on "DependencyFailureTest::testOne" to pass. - -2) DependencyFailureTest::testThree -This test depends on "DependencyFailureTest::testTwo" to pass. - -FAILURES! -Tests: 4, Assertions: 0, Failures: 1, Skipped: 2. diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies.phpt deleted file mode 100644 index 593088f99..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies.phpt +++ /dev/null @@ -1,39 +0,0 @@ ---TEST-- -phpunit --verbose DependencyTestSuite ../_files/DependencyTestSuite.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Runtime: %s - -...FSS - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) DependencyFailureTest::testOne - -%s:%i - --- - -There were 2 skipped tests: - -1) DependencyFailureTest::testTwo -This test depends on "DependencyFailureTest::testOne" to pass. - -2) DependencyFailureTest::testThree -This test depends on "DependencyFailureTest::testTwo" to pass. - -FAILURES! -Tests: 4, Assertions: 0, Failures: 1, Skipped: 2. diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies2-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies2-isolation.phpt deleted file mode 100644 index bd88351a5..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies2-isolation.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -phpunit --process-isolation StackTest ../_files/StackTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 5 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies2.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies2.phpt deleted file mode 100644 index d05b79d8f..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies2.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit StackTest ../_files/StackTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 5 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies3-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies3-isolation.phpt deleted file mode 100644 index 37d2e639c..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies3-isolation.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -phpunit --process-isolation MultiDependencyTest ../_files/MultiDependencyTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/dependencies3.phpt b/vendor/phpunit/phpunit/tests/TextUI/dependencies3.phpt deleted file mode 100644 index 6c5d3b1c9..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/dependencies3.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit MultiDependencyTest ../_files/MultiDependencyTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/empty-testcase.phpt b/vendor/phpunit/phpunit/tests/TextUI/empty-testcase.phpt deleted file mode 100644 index 3de7055a5..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/empty-testcase.phpt +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -phpunit EmptyTestCaseTest ../_files/EmptyTestCaseTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -F - -Time: %s, Memory: %sMb - -There was 1 failure: - -1) Warning -No tests found in class "EmptyTestCaseTest". - -FAILURES! -Tests: 1, Assertions: 0, Failures: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/exception-stack.phpt b/vendor/phpunit/phpunit/tests/TextUI/exception-stack.phpt deleted file mode 100644 index db585bf05..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/exception-stack.phpt +++ /dev/null @@ -1,65 +0,0 @@ ---TEST-- -phpunit ExceptionStackTest ../_files/ExceptionStackTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -EE - -Time: %s, Memory: %sMb - -There were 2 errors: - -1) ExceptionStackTest::testPrintingChildException -PHPUnit_Framework_Exception: Child exception -message -Failed asserting that two arrays are equal. ---- Expected -+++ Actual -@@ @@ - Array ( -- 0 => 1 -+ 0 => 2 - ) - - -%s:%i - -Caused by -message -Failed asserting that two arrays are equal. ---- Expected -+++ Actual -@@ @@ - Array ( -- 0 => 1 -+ 0 => 2 - ) - -%s:%i - -2) ExceptionStackTest::testNestedExceptions -Exception: One - -%s:%i - -Caused by -InvalidArgumentException: Two - -%s:%i - -Caused by -Exception: Three - -%s:%i - -FAILURES! -Tests: 2, Assertions: 1, Errors: 2. diff --git a/vendor/phpunit/phpunit/tests/TextUI/exclude-group-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/exclude-group-isolation.phpt deleted file mode 100644 index 736feda80..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/exclude-group-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --exclude-group balanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/exclude-group.phpt b/vendor/phpunit/phpunit/tests/TextUI/exclude-group.phpt deleted file mode 100644 index f75d61156..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/exclude-group.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --exclude-group balanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/failure-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/failure-isolation.phpt deleted file mode 100644 index 7df4f1013..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/failure-isolation.phpt +++ /dev/null @@ -1,142 +0,0 @@ ---TEST-- -phpunit --process-isolation FailureTest ../_files/FailureTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -FFFFFFFFFFFFF - -Time: %s, Memory: %sMb - -There were 13 failures: - -1) FailureTest::testAssertArrayEqualsArray -message -Failed asserting that two arrays are equal. ---- Expected -+++ Actual -@@ @@ - Array ( -- 0 => 1 -+ 0 => 2 - ) - -%s:%i - -2) FailureTest::testAssertIntegerEqualsInteger -message -Failed asserting that 2 matches expected 1. - -%s:%i - -3) FailureTest::testAssertObjectEqualsObject -message -Failed asserting that two objects are equal. ---- Expected -+++ Actual -@@ @@ - stdClass Object ( -- 'foo' => 'bar' -+ 'bar' => 'foo' - ) - -%s:%i - -4) FailureTest::testAssertNullEqualsString -message -Failed asserting that 'bar' matches expected null. - -%s:%i - -5) FailureTest::testAssertStringEqualsString -message -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ --'foo' -+'bar' - -%s:%i - -6) FailureTest::testAssertTextEqualsText -message -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ - 'foo --bar -+baz - ' - -%s:%i - -7) FailureTest::testAssertStringMatchesFormat -message -Failed asserting that format description matches text. ---- Expected -+++ Actual -@@ @@ --*%s* -+** - -%s:%i - -8) FailureTest::testAssertNumericEqualsNumeric -message -Failed asserting that 2 matches expected 1. - -%s:%i - -9) FailureTest::testAssertTextSameText -message -Failed asserting that two strings are identical. ---- Expected -+++ Actual -@@ @@ --foo -+bar - -%s:%i - -10) FailureTest::testAssertObjectSameObject -message -Failed asserting that two variables reference the same object. - -%s:%i - -11) FailureTest::testAssertObjectSameNull -message -Failed asserting that null is identical to an object of class "stdClass". - -%s:%i - -12) FailureTest::testAssertFloatSameFloat -message -Failed asserting that 1.5 is identical to 1.0. - -%s:%i - -13) FailureTest::testAssertStringMatchesFormatFile -Failed asserting that format description matches text. ---- Expected -+++ Actual -@@ @@ --FOO -- -+...BAR... - -%s:%i - -FAILURES! -Tests: 13, Assertions: 14, Failures: 13. diff --git a/vendor/phpunit/phpunit/tests/TextUI/failure.phpt b/vendor/phpunit/phpunit/tests/TextUI/failure.phpt deleted file mode 100644 index 23415e94a..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/failure.phpt +++ /dev/null @@ -1,141 +0,0 @@ ---TEST-- -phpunit FailureTest ../_files/FailureTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -FFFFFFFFFFFFF - -Time: %s, Memory: %sMb - -There were 13 failures: - -1) FailureTest::testAssertArrayEqualsArray -message -Failed asserting that two arrays are equal. ---- Expected -+++ Actual -@@ @@ - Array ( -- 0 => 1 -+ 0 => 2 - ) - -%s:%i - -2) FailureTest::testAssertIntegerEqualsInteger -message -Failed asserting that 2 matches expected 1. - -%s:%i - -3) FailureTest::testAssertObjectEqualsObject -message -Failed asserting that two objects are equal. ---- Expected -+++ Actual -@@ @@ - stdClass Object ( -- 'foo' => 'bar' -+ 'bar' => 'foo' - ) - -%s:%i - -4) FailureTest::testAssertNullEqualsString -message -Failed asserting that 'bar' matches expected null. - -%s:%i - -5) FailureTest::testAssertStringEqualsString -message -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ --'foo' -+'bar' - -%s:%i - -6) FailureTest::testAssertTextEqualsText -message -Failed asserting that two strings are equal. ---- Expected -+++ Actual -@@ @@ - 'foo --bar -+baz - ' - -%s:%i - -7) FailureTest::testAssertStringMatchesFormat -message -Failed asserting that format description matches text. ---- Expected -+++ Actual -@@ @@ --*%s* -+** - -%s:%i - -8) FailureTest::testAssertNumericEqualsNumeric -message -Failed asserting that 2 matches expected 1. - -%s:%i - -9) FailureTest::testAssertTextSameText -message -Failed asserting that two strings are identical. ---- Expected -+++ Actual -@@ @@ --foo -+bar - -%s:%i - -10) FailureTest::testAssertObjectSameObject -message -Failed asserting that two variables reference the same object. - -%s:%i - -11) FailureTest::testAssertObjectSameNull -message -Failed asserting that null is identical to an object of class "stdClass". - -%s:%i - -12) FailureTest::testAssertFloatSameFloat -message -Failed asserting that 1.5 is identical to 1.0. - -%s:%i - -13) FailureTest::testAssertStringMatchesFormatFile -Failed asserting that format description matches text. ---- Expected -+++ Actual -@@ @@ --FOO -- -+...BAR... - -%s:%i - -FAILURES! -Tests: 13, Assertions: 14, Failures: 13. diff --git a/vendor/phpunit/phpunit/tests/TextUI/fatal-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/fatal-isolation.phpt deleted file mode 100644 index ec7f91a9d..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/fatal-isolation.phpt +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -phpunit FatalTest --process-isolation ../_files/FatalTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -E - -Time: %s, Memory: %sMb - -There was 1 error: - -1) FatalTest::testFatalError -%s - -FAILURES! -Tests: 1, Assertions: 0, Errors: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-class-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-class-isolation.phpt deleted file mode 100644 index 31cf060d7..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-class-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter BankAccountTest BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-class.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-class.phpt deleted file mode 100644 index 7b3c8dd83..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-class.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter BankAccountTest BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range-isolation.phpt deleted file mode 100644 index f90a69170..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter DataProviderFilterTest#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range.phpt deleted file mode 100644 index 9c1e68979..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-classname-and-range.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter DataProviderFilterTest#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number-isolation.phpt deleted file mode 100644 index 0d2ea778a..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testTrue#3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number.phpt deleted file mode 100644 index 79bf6430e..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-number.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter testTrue#3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range-isolation.phpt deleted file mode 100644 index 2dfdd0c83..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter \#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range.phpt deleted file mode 100644 index c3d344cdc..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-range.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter \#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp-isolation.phpt deleted file mode 100644 index d109cfb3c..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter @false.* DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp.phpt deleted file mode 100644 index d87b3045b..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-regexp.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter @false.* DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string-isolation.phpt deleted file mode 100644 index 07c4002df..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter @false\ test DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string.phpt deleted file mode 100644 index 0cf91eb78..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-only-string.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter @false\ test DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range-isolation.phpt deleted file mode 100644 index 2231b4d1b..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testTrue#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range.phpt deleted file mode 100644 index 2f2aa1d78..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-range.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter testTrue#1-3 DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp-isolation.phpt deleted file mode 100644 index 3a46c510e..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testFalse@false.* DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp.phpt deleted file mode 100644 index fdbd8bd35..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-regexp.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter testFalse@false.* DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -.. - -Time: %s, Memory: %sMb - -OK (2 tests, 2 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string-isolation.phpt deleted file mode 100644 index d91ca73f6..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testFalse@false\ test DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string.phpt deleted file mode 100644 index eb3e6afdb..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-dataprovider-by-string.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter testFalse@false\ test DataProviderFilterTest ../_files/DataProviderFilterTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-insensitive.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-insensitive.phpt deleted file mode 100644 index 55519a1ca..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-insensitive.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter /balanceIsInitiallyZero/i BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-sensitive-no-result.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-sensitive-no-result.phpt deleted file mode 100644 index 0551054da..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-method-case-sensitive-no-result.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter balanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - - -Time: %s, Memory: %sMb - -No tests executed! diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-method-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-method-isolation.phpt deleted file mode 100644 index 9cd16eff1..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-method-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testBalanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-method.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-method.phpt deleted file mode 100644 index 9f5b01cb4..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-method.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter testBalanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/filter-no-results.phpt b/vendor/phpunit/phpunit/tests/TextUI/filter-no-results.phpt deleted file mode 100644 index a2720c862..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/filter-no-results.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --filter doesNotExist BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - - - -Time: %s, Memory: %sMb - -No tests executed! diff --git a/vendor/phpunit/phpunit/tests/TextUI/group-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/group-isolation.phpt deleted file mode 100644 index 9fc0d02d3..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/group-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation --group balanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/group.phpt b/vendor/phpunit/phpunit/tests/TextUI/group.phpt deleted file mode 100644 index 858456bda..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/group.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --group balanceIsInitiallyZero BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/help.phpt b/vendor/phpunit/phpunit/tests/TextUI/help.phpt deleted file mode 100644 index c56cbe372..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/help.phpt +++ /dev/null @@ -1,87 +0,0 @@ ---TEST-- -phpunit ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Usage: phpunit [options] UnitTest [UnitTest.php] - phpunit [options] - -Code Coverage Options: - - --coverage-clover Generate code coverage report in Clover XML format. - --coverage-crap4j Generate code coverage report in Crap4J XML format. - --coverage-html Generate code coverage report in HTML format. - --coverage-php Export PHP_CodeCoverage object to file. - --coverage-text= Generate code coverage report in text format. - Default: Standard output. - --coverage-xml Generate code coverage report in PHPUnit XML format. - -Logging Options: - - --log-junit Log test execution in JUnit XML format to file. - --log-tap Log test execution in TAP format to file. - --log-json Log test execution in JSON format. - --testdox-html Write agile documentation in HTML format to file. - --testdox-text Write agile documentation in Text format to file. - -Test Selection Options: - - --filter Filter which tests to run. - --testsuite Filter which testsuite to run. - --group ... Only runs tests from the specified group(s). - --exclude-group ... Exclude tests from the specified group(s). - --list-groups List available test groups. - --test-suffix ... Only search for test in files with specified - suffix(es). Default: Test.php,.phpt - -Test Execution Options: - - --report-useless-tests Be strict about tests that do not test anything. - --strict-coverage Be strict about unintentionally covered code. - --strict-global-state Be strict about changes to global state - --disallow-test-output Be strict about output during tests. - --enforce-time-limit Enforce time limit based on test size. - --disallow-todo-tests Disallow @todo-annotated tests. - - --process-isolation Run each test in a separate PHP process. - --no-globals-backup Do not backup and restore $GLOBALS for each test. - --static-backup Backup and restore static attributes for each test. - - --colors= Use colors in output ("never", "auto" or "always"). - --columns Number of columns to use for progress output. - --columns max Use maximum number of columns for progress output. - --stderr Write to STDERR instead of STDOUT. - --stop-on-error Stop execution upon first error. - --stop-on-failure Stop execution upon first error or failure. - --stop-on-risky Stop execution upon first risky test. - --stop-on-skipped Stop execution upon first skipped test. - --stop-on-incomplete Stop execution upon first incomplete test. - -v|--verbose Output more verbose information. - --debug Display debugging information during test execution. - - --loader TestSuiteLoader implementation to use. - --repeat Runs the test(s) repeatedly. - --tap Report test execution progress in TAP format. - --testdox Report test execution progress in TestDox format. - --printer TestListener implementation to use. - -Configuration Options: - - --bootstrap A "bootstrap" PHP file that is run before the tests. - -c|--configuration Read configuration from XML file. - --no-configuration Ignore default configuration file (phpunit.xml). - --no-coverage Ignore code coverage configuration. - --include-path Prepend PHP's include_path with given path(s). - -d key[=value] Sets a php.ini value. - -Miscellaneous Options: - - -h|--help Prints this usage information. - --version Prints the version and exits. diff --git a/vendor/phpunit/phpunit/tests/TextUI/help2.phpt b/vendor/phpunit/phpunit/tests/TextUI/help2.phpt deleted file mode 100644 index 97d69db2f..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/help2.phpt +++ /dev/null @@ -1,88 +0,0 @@ ---TEST-- -phpunit --help ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Usage: phpunit [options] UnitTest [UnitTest.php] - phpunit [options] - -Code Coverage Options: - - --coverage-clover Generate code coverage report in Clover XML format. - --coverage-crap4j Generate code coverage report in Crap4J XML format. - --coverage-html Generate code coverage report in HTML format. - --coverage-php Export PHP_CodeCoverage object to file. - --coverage-text= Generate code coverage report in text format. - Default: Standard output. - --coverage-xml Generate code coverage report in PHPUnit XML format. - -Logging Options: - - --log-junit Log test execution in JUnit XML format to file. - --log-tap Log test execution in TAP format to file. - --log-json Log test execution in JSON format. - --testdox-html Write agile documentation in HTML format to file. - --testdox-text Write agile documentation in Text format to file. - -Test Selection Options: - - --filter Filter which tests to run. - --testsuite Filter which testsuite to run. - --group ... Only runs tests from the specified group(s). - --exclude-group ... Exclude tests from the specified group(s). - --list-groups List available test groups. - --test-suffix ... Only search for test in files with specified - suffix(es). Default: Test.php,.phpt - -Test Execution Options: - - --report-useless-tests Be strict about tests that do not test anything. - --strict-coverage Be strict about unintentionally covered code. - --strict-global-state Be strict about changes to global state - --disallow-test-output Be strict about output during tests. - --enforce-time-limit Enforce time limit based on test size. - --disallow-todo-tests Disallow @todo-annotated tests. - - --process-isolation Run each test in a separate PHP process. - --no-globals-backup Do not backup and restore $GLOBALS for each test. - --static-backup Backup and restore static attributes for each test. - - --colors= Use colors in output ("never", "auto" or "always"). - --columns Number of columns to use for progress output. - --columns max Use maximum number of columns for progress output. - --stderr Write to STDERR instead of STDOUT. - --stop-on-error Stop execution upon first error. - --stop-on-failure Stop execution upon first error or failure. - --stop-on-risky Stop execution upon first risky test. - --stop-on-skipped Stop execution upon first skipped test. - --stop-on-incomplete Stop execution upon first incomplete test. - -v|--verbose Output more verbose information. - --debug Display debugging information during test execution. - - --loader TestSuiteLoader implementation to use. - --repeat Runs the test(s) repeatedly. - --tap Report test execution progress in TAP format. - --testdox Report test execution progress in TestDox format. - --printer TestListener implementation to use. - -Configuration Options: - - --bootstrap A "bootstrap" PHP file that is run before the tests. - -c|--configuration Read configuration from XML file. - --no-configuration Ignore default configuration file (phpunit.xml). - --no-coverage Ignore code coverage configuration. - --include-path Prepend PHP's include_path with given path(s). - -d key[=value] Sets a php.ini value. - -Miscellaneous Options: - - -h|--help Prints this usage information. - --version Prints the version and exits. diff --git a/vendor/phpunit/phpunit/tests/TextUI/ini-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/ini-isolation.phpt deleted file mode 100644 index ee002df53..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/ini-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --process-isolation -d default_mimetype=application/x-test IniTest ../_files/IniTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/list-groups.phpt b/vendor/phpunit/phpunit/tests/TextUI/list-groups.phpt deleted file mode 100644 index fba986854..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/list-groups.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit --list-groups BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -Available test group(s): - - balanceCannotBecomeNegative - - balanceIsInitiallyZero - - specification diff --git a/vendor/phpunit/phpunit/tests/TextUI/log-json-no-pretty-print.phpt b/vendor/phpunit/phpunit/tests/TextUI/log-json-no-pretty-print.phpt deleted file mode 100644 index b2b4ae875..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/log-json-no-pretty-print.phpt +++ /dev/null @@ -1,27 +0,0 @@ ---TEST-- -phpunit --log-json php://stdout BankAccountTest ../_files/BankAccountTest.php ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -{"event":"suiteStart","suite":"BankAccountTest","tests":3}{"event":"testStart","suite":"BankAccountTest","test":"BankAccountTest::testBalanceIsInitiallyZero"}.{"event":"test","suite":"BankAccountTest","test":"BankAccountTest::testBalanceIsInitiallyZero","status":"pass","time":%f,"trace":[],"message":"","output":""}{"event":"testStart","suite":"BankAccountTest","test":"BankAccountTest::testBalanceCannotBecomeNegative"}.{"event":"test","suite":"BankAccountTest","test":"BankAccountTest::testBalanceCannotBecomeNegative","status":"pass","time":%f,"trace":[],"message":"","output":""}{"event":"testStart","suite":"BankAccountTest","test":"BankAccountTest::testBalanceCannotBecomeNegative2"}.{"event":"test","suite":"BankAccountTest","test":"BankAccountTest::testBalanceCannotBecomeNegative2","status":"pass","time":%f,"trace":[],"message":"","output":""} - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/log-json-post-66021.phpt b/vendor/phpunit/phpunit/tests/TextUI/log-json-post-66021.phpt deleted file mode 100644 index 9a853143d..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/log-json-post-66021.phpt +++ /dev/null @@ -1,72 +0,0 @@ ---TEST-- -phpunit --log-json php://stdout BankAccountTest ../_files/BankAccountTest.php ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -{ - "event": "suiteStart", - "suite": "BankAccountTest", - "tests": 3 -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceIsInitiallyZero" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceIsInitiallyZero", - "status": "pass", - "time": %f, - "trace": [], - "message": "", - "output": "" -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative", - "status": "pass", - "time": %f, - "trace": [], - "message": "", - "output": "" -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative2" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative2", - "status": "pass", - "time": %f, - "trace": [], - "message": "", - "output": "" -} - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/log-json-pre-66021.phpt b/vendor/phpunit/phpunit/tests/TextUI/log-json-pre-66021.phpt deleted file mode 100644 index 866134a67..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/log-json-pre-66021.phpt +++ /dev/null @@ -1,78 +0,0 @@ ---TEST-- -phpunit --log-json php://stdout BankAccountTest ../_files/BankAccountTest.php ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -{ - "event": "suiteStart", - "suite": "BankAccountTest", - "tests": 3 -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceIsInitiallyZero" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceIsInitiallyZero", - "status": "pass", - "time": %f, - "trace": [ - - ], - "message": "", - "output": "" -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative", - "status": "pass", - "time": %f, - "trace": [ - - ], - "message": "", - "output": "" -}{ - "event": "testStart", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative2" -}.{ - "event": "test", - "suite": "BankAccountTest", - "test": "BankAccountTest::testBalanceCannotBecomeNegative2", - "status": "pass", - "time": %f, - "trace": [ - - ], - "message": "", - "output": "" -} - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/log-tap.phpt b/vendor/phpunit/phpunit/tests/TextUI/log-tap.phpt deleted file mode 100644 index 6e13626bd..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/log-tap.phpt +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -phpunit --log-tap php://stdout BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -TAP version 13 -.ok 1 - BankAccountTest::testBalanceIsInitiallyZero -.ok 2 - BankAccountTest::testBalanceCannotBecomeNegative -.ok 3 - BankAccountTest::testBalanceCannotBecomeNegative2 -1..3 - - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/log-xml.phpt b/vendor/phpunit/phpunit/tests/TextUI/log-xml.phpt deleted file mode 100644 index a031c85b9..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/log-xml.phpt +++ /dev/null @@ -1,29 +0,0 @@ ---TEST-- -phpunit --log-junit php://stdout BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - - - - - - - - - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/options-after-arguments.phpt b/vendor/phpunit/phpunit/tests/TextUI/options-after-arguments.phpt deleted file mode 100644 index d4cdc1af5..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/options-after-arguments.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit BankAccountTest ../_files/BankAccountTest.php --colors ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -%s[30;42mOK (3 tests, 3 assertions)%s[0m diff --git a/vendor/phpunit/phpunit/tests/TextUI/output-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/output-isolation.phpt deleted file mode 100644 index 128a7e264..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/output-isolation.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --process-isolation --filter testExpectOutputStringFooActualFoo ../_files/OutputTestCase.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -. - -Time: %s, Memory: %sMb - -OK (1 test, 1 assertion) diff --git a/vendor/phpunit/phpunit/tests/TextUI/repeat.phpt b/vendor/phpunit/phpunit/tests/TextUI/repeat.phpt deleted file mode 100644 index db5eddb2c..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/repeat.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --repeat 3 BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -......... - -Time: %s, Memory: %sMb - -OK (9 tests, 9 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-incomplete.phpt b/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-incomplete.phpt deleted file mode 100644 index 9bc4c2dcd..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-incomplete.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --report-useless-tests IncompleteTest ../_files/IncompleteTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -I - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Incomplete: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-isolation.phpt b/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-isolation.phpt deleted file mode 100644 index 9401b269f..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests-isolation.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -phpunit --report-useless-tests --process-isolation IncompleteTest ../_files/IncompleteTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -R - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Risky: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests.phpt b/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests.phpt deleted file mode 100644 index 9eb22dfc7..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/report-useless-tests.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --report-useless-tests NothingTest ../_files/NothingTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -R - -Time: %s, Memory: %sMb - -OK, but incomplete, skipped, or risky tests! -Tests: 1, Assertions: 0, Risky: 1. diff --git a/vendor/phpunit/phpunit/tests/TextUI/tap.phpt b/vendor/phpunit/phpunit/tests/TextUI/tap.phpt deleted file mode 100644 index ca5676df5..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/tap.phpt +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -phpunit --tap BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -TAP version 13 -ok 1 - BankAccountTest::testBalanceIsInitiallyZero -ok 2 - BankAccountTest::testBalanceCannotBecomeNegative -ok 3 - BankAccountTest::testBalanceCannotBecomeNegative2 -1..3 diff --git a/vendor/phpunit/phpunit/tests/TextUI/test-suffix-multiple.phpt b/vendor/phpunit/phpunit/tests/TextUI/test-suffix-multiple.phpt deleted file mode 100644 index 417f06582..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/test-suffix-multiple.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -phpunit --test-suffix .test.php,.my.php ../_files/ ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -..... - -Time: %s, Memory: %sMb - -OK (5 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/test-suffix-single.phpt b/vendor/phpunit/phpunit/tests/TextUI/test-suffix-single.phpt deleted file mode 100644 index 6c3593715..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/test-suffix-single.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -phpunit --test-suffix .test.php ../_files/ ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -... - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/testdox-html.phpt b/vendor/phpunit/phpunit/tests/TextUI/testdox-html.phpt deleted file mode 100644 index 95e440572..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/testdox-html.phpt +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -phpunit --testdox-html php://stdout BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -

    BankAccount

      ...
    • Balance is initially zero
    • Balance cannot become negative
    - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/testdox-text.phpt b/vendor/phpunit/phpunit/tests/TextUI/testdox-text.phpt deleted file mode 100644 index 79c675536..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/testdox-text.phpt +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -phpunit --testdox-text php://stdout BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -BankAccount -... [x] Balance is initially zero - [x] Balance cannot become negative - - - -Time: %s, Memory: %sMb - -OK (3 tests, 3 assertions) diff --git a/vendor/phpunit/phpunit/tests/TextUI/testdox.phpt b/vendor/phpunit/phpunit/tests/TextUI/testdox.phpt deleted file mode 100644 index fb24e94a7..000000000 --- a/vendor/phpunit/phpunit/tests/TextUI/testdox.phpt +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -phpunit --testdox php://stdout BankAccountTest ../_files/BankAccountTest.php ---FILE-- - ---EXPECTF-- -PHPUnit %s by Sebastian Bergmann and contributors. - -BankAccount - [x] Balance is initially zero - [x] Balance cannot become negative - diff --git a/vendor/phpunit/phpunit/tests/Util/ConfigurationTest.php b/vendor/phpunit/phpunit/tests/Util/ConfigurationTest.php deleted file mode 100644 index 8bccf14a5..000000000 --- a/vendor/phpunit/phpunit/tests/Util/ConfigurationTest.php +++ /dev/null @@ -1,500 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 3.3.0 - */ -class Util_ConfigurationTest extends PHPUnit_Framework_TestCase -{ - protected $configuration; - - protected function setUp() - { - $this->configuration = PHPUnit_Util_Configuration::getInstance( - dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration.xml' - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getInstance - * @expectedException PHPUnit_Framework_Exception - */ - public function testExceptionIsThrownForNotExistingConfigurationFile() - { - PHPUnit_Util_Configuration::getInstance('not_existing_file.xml'); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - */ - public function testShouldReadColorsWhenTrueInConfigurationfile() - { - $configurationFilename = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration.colors.true.xml'; - $configurationInstance = PHPUnit_Util_Configuration::getInstance($configurationFilename); - $configurationValues = $configurationInstance->getPHPUnitConfiguration(); - - $this->assertEquals(PHPUnit_TextUI_ResultPrinter::COLOR_AUTO, $configurationValues['colors']); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - */ - public function testShouldReadColorsWhenFalseInConfigurationfile() - { - $configurationFilename = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration.colors.false.xml'; - $configurationInstance = PHPUnit_Util_Configuration::getInstance($configurationFilename); - $configurationValues = $configurationInstance->getPHPUnitConfiguration(); - - $this->assertEquals(PHPUnit_TextUI_ResultPrinter::COLOR_NEVER, $configurationValues['colors']); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - */ - public function testShouldReadColorsWhenEmptyInConfigurationfile() - { - $configurationFilename = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration.colors.empty.xml'; - $configurationInstance = PHPUnit_Util_Configuration::getInstance($configurationFilename); - $configurationValues = $configurationInstance->getPHPUnitConfiguration(); - - $this->assertEquals(PHPUnit_TextUI_ResultPrinter::COLOR_NEVER, $configurationValues['colors']); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - */ - public function testShouldReadColorsWhenInvalidInConfigurationfile() - { - $configurationFilename = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration.colors.invalid.xml'; - $configurationInstance = PHPUnit_Util_Configuration::getInstance($configurationFilename); - $configurationValues = $configurationInstance->getPHPUnitConfiguration(); - - $this->assertEquals(PHPUnit_TextUI_ResultPrinter::COLOR_NEVER, $configurationValues['colors']); - } - - /** - * @covers PHPUnit_Util_Configuration::getFilterConfiguration - */ - public function testFilterConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 'blacklist' => - array( - 'include' => - array( - 'directory' => - array( - 0 => - array( - 'path' => '/path/to/files', - 'prefix' => '', - 'suffix' => '.php', - 'group' => 'DEFAULT' - ), - ), - 'file' => - array( - 0 => '/path/to/file', - ), - ), - 'exclude' => - array( - 'directory' => - array( - 0 => - array( - 'path' => '/path/to/files', - 'prefix' => '', - 'suffix' => '.php', - 'group' => 'DEFAULT' - ), - ), - 'file' => - array( - 0 => '/path/to/file', - ), - ), - ), - 'whitelist' => - array( - 'addUncoveredFilesFromWhitelist' => true, - 'processUncoveredFilesFromWhitelist' => false, - 'include' => - array( - 'directory' => - array( - 0 => - array( - 'path' => '/path/to/files', - 'prefix' => '', - 'suffix' => '.php', - 'group' => 'DEFAULT' - ), - ), - 'file' => - array( - 0 => '/path/to/file', - ), - ), - 'exclude' => - array( - 'directory' => - array( - 0 => - array( - 'path' => '/path/to/files', - 'prefix' => '', - 'suffix' => '.php', - 'group' => 'DEFAULT' - ), - ), - 'file' => - array( - 0 => '/path/to/file', - ), - ), - ), - ), - $this->configuration->getFilterConfiguration() - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getGroupConfiguration - */ - public function testGroupConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 'include' => - array( - 0 => 'name', - ), - 'exclude' => - array( - 0 => 'name', - ), - ), - $this->configuration->getGroupConfiguration() - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getListenerConfiguration - */ - public function testListenerConfigurationIsReadCorrectly() - { - $dir = __DIR__; - $includePath = ini_get('include_path'); - - ini_set('include_path', $dir . PATH_SEPARATOR . $includePath); - - $this->assertEquals( - array( - 0 => - array( - 'class' => 'MyListener', - 'file' => '/optional/path/to/MyListener.php', - 'arguments' => - array( - 0 => - array( - 0 => 'Sebastian', - ), - 1 => 22, - 2 => 'April', - 3 => 19.78, - 4 => null, - 5 => new stdClass, - 6 => dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'MyTestFile.php', - 7 => dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'MyRelativePath', - ), - ), - array( - 'class' => 'IncludePathListener', - 'file' => __FILE__, - 'arguments' => array() - ), - array( - 'class' => 'CompactArgumentsListener', - 'file' => '/CompactArgumentsListener.php', - 'arguments' => - array( - 0 => 42 - ), - ), - ), - $this->configuration->getListenerConfiguration() - ); - - ini_set('include_path', $includePath); - } - - /** - * @covers PHPUnit_Util_Configuration::getLoggingConfiguration - */ - public function testLoggingConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 'lowUpperBound' => '50', - 'highLowerBound' => '90', - 'coverage-html' => '/tmp/report', - 'coverage-clover' => '/tmp/clover.xml', - 'json' => '/tmp/logfile.json', - 'plain' => '/tmp/logfile.txt', - 'tap' => '/tmp/logfile.tap', - 'logIncompleteSkipped' => false, - 'junit' => '/tmp/logfile.xml', - 'testdox-html' => '/tmp/testdox.html', - 'testdox-text' => '/tmp/testdox.txt', - ), - $this->configuration->getLoggingConfiguration() - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPConfiguration - */ - public function testPHPConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 'include_path' => - array( - dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . '.', - '/path/to/lib' - ), - 'ini' => array('foo' => 'bar'), - 'const' => array('FOO' => false, 'BAR' => true), - 'var' => array('foo' => false), - 'env' => array('foo' => true), - 'post' => array('foo' => 'bar'), - 'get' => array('foo' => 'bar'), - 'cookie' => array('foo' => 'bar'), - 'server' => array('foo' => 'bar'), - 'files' => array('foo' => 'bar'), - 'request'=> array('foo' => 'bar'), - ), - $this->configuration->getPHPConfiguration() - ); - } - - /** - * @backupGlobals enabled - * @covers PHPUnit_Util_Configuration::handlePHPConfiguration - */ - public function testPHPConfigurationIsHandledCorrectly() - { - $this->configuration->handlePHPConfiguration(); - - $path = dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . '.' . PATH_SEPARATOR . '/path/to/lib'; - $this->assertStringStartsWith($path, ini_get('include_path')); - $this->assertEquals(false, FOO); - $this->assertEquals(true, BAR); - $this->assertEquals(false, $GLOBALS['foo']); - $this->assertEquals(true, $_ENV['foo']); - $this->assertEquals(true, getenv('foo')); - $this->assertEquals('bar', $_POST['foo']); - $this->assertEquals('bar', $_GET['foo']); - $this->assertEquals('bar', $_COOKIE['foo']); - $this->assertEquals('bar', $_SERVER['foo']); - $this->assertEquals('bar', $_FILES['foo']); - $this->assertEquals('bar', $_REQUEST['foo']); - } - - /** - * @backupGlobals enabled - * @see https://github.com/sebastianbergmann/phpunit/issues/1181 - */ - public function testHandlePHPConfigurationDoesNotOverwrittenExistingEnvArrayVariables() - { - $_ENV['foo'] = false; - $this->configuration->handlePHPConfiguration(); - - $this->assertEquals(false, $_ENV['foo']); - $this->assertEquals(true, getenv('foo')); - } - - /** - * @backupGlobals enabled - * @see https://github.com/sebastianbergmann/phpunit/issues/1181 - */ - public function testHandlePHPConfigurationDoesNotOverriteVariablesFromPutEnv() - { - putenv('foo=putenv'); - $this->configuration->handlePHPConfiguration(); - - $this->assertEquals(true, $_ENV['foo']); - $this->assertEquals('putenv', getenv('foo')); - } - - /** - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - */ - public function testPHPUnitConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 'backupGlobals' => true, - 'backupStaticAttributes' => false, - 'disallowChangesToGlobalState' => false, - 'bootstrap' => '/path/to/bootstrap.php', - 'cacheTokens' => false, - 'columns' => 80, - 'colors' => 'never', - 'stderr' => false, - 'convertErrorsToExceptions' => true, - 'convertNoticesToExceptions' => true, - 'convertWarningsToExceptions' => true, - 'forceCoversAnnotation' => false, - 'mapTestClassNameToCoveredClassName' => false, - 'printerClass' => 'PHPUnit_TextUI_ResultPrinter', - 'stopOnFailure' => false, - 'reportUselessTests' => false, - 'strictCoverage' => false, - 'disallowTestOutput' => false, - 'enforceTimeLimit' => false, - 'disallowTodoAnnotatedTests' => false, - 'testSuiteLoaderClass' => 'PHPUnit_Runner_StandardTestSuiteLoader', - 'verbose' => false, - 'timeoutForSmallTests' => 1, - 'timeoutForMediumTests' => 10, - 'timeoutForLargeTests' => 60 - ), - $this->configuration->getPHPUnitConfiguration() - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getSeleniumBrowserConfiguration - */ - public function testSeleniumBrowserConfigurationIsReadCorrectly() - { - $this->assertEquals( - array( - 0 => - array( - 'name' => 'Firefox on Linux', - 'browser' => '*firefox /usr/lib/firefox/firefox-bin', - 'host' => 'my.linux.box', - 'port' => 4444, - 'timeout' => 30000, - ), - ), - $this->configuration->getSeleniumBrowserConfiguration() - ); - } - - /** - * @covers PHPUnit_Util_Configuration::getInstance - */ - public function testXincludeInConfiguration() - { - $configurationWithXinclude = PHPUnit_Util_Configuration::getInstance( - dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration_xinclude.xml' - ); - - $this->assertConfigurationEquals( - $this->configuration, - $configurationWithXinclude - ); - } - - /** - * @ticket 1311 - * @covers PHPUnit_Util_Configuration::getLoggingConfiguration - * @covers PHPUnit_Util_Configuration::getPHPConfiguration - * @covers PHPUnit_Util_Configuration::getPHPUnitConfiguration - * @covers PHPUnit_Util_Configuration::getTestSuiteConfiguration - * @covers PHPUnit_Util_Configuration::getFilterConfiguration - * @uses PHPUnit_Util_Configuration::getInstance - */ - public function testWithEmptyConfigurations() - { - $emptyConfiguration = PHPUnit_Util_Configuration::getInstance( - dirname(__DIR__) . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR . 'configuration_empty.xml' - ); - - $logging = $emptyConfiguration->getLoggingConfiguration(); - $this->assertEmpty($logging); - - $php = $emptyConfiguration->getPHPConfiguration(); - $this->assertEmpty($php['include_path']); - - $phpunit = $emptyConfiguration->getPHPUnitConfiguration(); - $this->assertArrayNotHasKey('bootstrap', $phpunit); - $this->assertArrayNotHasKey('testSuiteLoaderFile', $phpunit); - $this->assertArrayNotHasKey('printerFile', $phpunit); - - $suite = $emptyConfiguration->getTestSuiteConfiguration(); - $this->assertEmpty($suite->getGroups()); - - $filter = $emptyConfiguration->getFilterConfiguration(); - $this->assertEmpty($filter['blacklist']['include']['directory']); - $this->assertEmpty($filter['blacklist']['include']['file']); - $this->assertEmpty($filter['blacklist']['exclude']['directory']); - $this->assertEmpty($filter['blacklist']['exclude']['file']); - $this->assertEmpty($filter['whitelist']['include']['directory']); - $this->assertEmpty($filter['whitelist']['include']['file']); - $this->assertEmpty($filter['whitelist']['exclude']['directory']); - $this->assertEmpty($filter['whitelist']['exclude']['file']); - } - - /** - * Asserts that the values in $actualConfiguration equal $expectedConfiguration. - * - * @param PHPUnit_Util_Configuration $expectedConfiguration - * @param PHPUnit_Util_Configuration $actualConfiguration - */ - protected function assertConfigurationEquals(PHPUnit_Util_Configuration $expectedConfiguration, PHPUnit_Util_Configuration $actualConfiguration) - { - $this->assertEquals( - $expectedConfiguration->getFilterConfiguration(), - $actualConfiguration->getFilterConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getGroupConfiguration(), - $actualConfiguration->getGroupConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getListenerConfiguration(), - $actualConfiguration->getListenerConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getLoggingConfiguration(), - $actualConfiguration->getLoggingConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getPHPConfiguration(), - $actualConfiguration->getPHPConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getPHPUnitConfiguration(), - $actualConfiguration->getPHPUnitConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getSeleniumBrowserConfiguration(), - $actualConfiguration->getSeleniumBrowserConfiguration() - ); - - $this->assertEquals( - $expectedConfiguration->getTestSuiteConfiguration(), - $actualConfiguration->getTestSuiteConfiguration() - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/GetoptTest.php b/vendor/phpunit/phpunit/tests/Util/GetoptTest.php deleted file mode 100644 index 8e7ad4dcf..000000000 --- a/vendor/phpunit/phpunit/tests/Util/GetoptTest.php +++ /dev/null @@ -1,62 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - */ -class Util_GetoptTest extends PHPUnit_Framework_TestCase -{ - public function testItIncludeTheLongOptionsAfterTheArgument() - { - $args = array( - 'command', - 'myArgument', - '--colors', - ); - $actual = PHPUnit_Util_Getopt::getopt($args, '', array('colors==')); - - $expected = array( - array( - array( - '--colors', - null, - ), - ), - array( - 'myArgument', - ), - ); - - $this->assertEquals($expected, $actual); - } - - public function testItIncludeTheShortOptionsAfterTheArgument() - { - $args = array( - 'command', - 'myArgument', - '-v', - ); - $actual = PHPUnit_Util_Getopt::getopt($args, 'v'); - - $expected = array( - array( - array( - 'v', - null, - ), - ), - array( - 'myArgument', - ), - ); - - $this->assertEquals($expected, $actual); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/GlobalStateTest.php b/vendor/phpunit/phpunit/tests/Util/GlobalStateTest.php deleted file mode 100644 index 5810ee396..000000000 --- a/vendor/phpunit/phpunit/tests/Util/GlobalStateTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - */ -class Util_GlobalStateTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHPUnit_Util_GlobalState::processIncludedFilesAsString - */ - public function testIncludedFilesAsStringSkipsVfsProtocols() - { - $dir = __DIR__; - $files = array( - 'phpunit', // The 0 index is not used - $dir . '/ConfigurationTest.php', - $dir . '/GlobalStateTest.php', - 'vfs://' . $dir . '/RegexTest.php', - 'phpvfs53e46260465c7://' . $dir . '/TestTest.php', - 'file://' . $dir . '/XMLTest.php' - ); - - $this->assertEquals( - "require_once '" . $dir . "/ConfigurationTest.php';\n" . - "require_once '" . $dir . "/GlobalStateTest.php';\n" . - "require_once 'file://" . $dir . "/XMLTest.php';\n", PHPUnit_Util_GlobalState::processIncludedFilesAsString($files)); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/RegexTest.php b/vendor/phpunit/phpunit/tests/Util/RegexTest.php deleted file mode 100644 index 7242654fd..000000000 --- a/vendor/phpunit/phpunit/tests/Util/RegexTest.php +++ /dev/null @@ -1,52 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 4.2.0 - */ -class Util_RegexTest extends PHPUnit_Framework_TestCase -{ - public function validRegexpProvider() - { - return array( - array('#valid regexp#', 'valid regexp', 1), - array(';val.*xp;', 'valid regexp', 1), - array('/val.*xp/i', 'VALID REGEXP', 1), - array('/a val.*p/','valid regexp', 0), - ); - } - - public function invalidRegexpProvider() - { - return array( - array('valid regexp', 'valid regexp'), - array(';val.*xp', 'valid regexp'), - array('val.*xp/i', 'VALID REGEXP'), - ); - } - - /** - * @dataProvider validRegexpProvider - * @covers PHPUnit_Util_Regex::pregMatchSafe - */ - public function testValidRegex($pattern, $subject, $return) - { - $this->assertEquals($return, PHPUnit_Util_Regex::pregMatchSafe($pattern, $subject)); - } - - /** - * @dataProvider invalidRegexpProvider - * @covers PHPUnit_Util_Regex::pregMatchSafe - */ - public function testInvalidRegex($pattern, $subject) - { - $this->assertFalse(PHPUnit_Util_Regex::pregMatchSafe($pattern, $subject)); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/TestDox/NamePrettifierTest.php b/vendor/phpunit/phpunit/tests/Util/TestDox/NamePrettifierTest.php deleted file mode 100644 index 30b9be4c9..000000000 --- a/vendor/phpunit/phpunit/tests/Util/TestDox/NamePrettifierTest.php +++ /dev/null @@ -1,81 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 2.1.0 - */ -class Util_TestDox_NamePrettifierTest extends PHPUnit_Framework_TestCase -{ - protected $namePrettifier; - - protected function setUp() - { - $this->namePrettifier = new PHPUnit_Util_TestDox_NamePrettifier; - } - - /** - * @covers PHPUnit_Util_TestDox_NamePrettifier::prettifyTestClass - */ - public function testTitleHasSensibleDefaults() - { - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('FooTest')); - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('TestFoo')); - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('TestFooTest')); - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('Test\FooTest')); - } - - /** - * @covers PHPUnit_Util_TestDox_NamePrettifier::prettifyTestClass - */ - public function testCaterForUserDefinedSuffix() - { - $this->namePrettifier->setSuffix('TestCase'); - $this->namePrettifier->setPrefix(null); - - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('FooTestCase')); - $this->assertEquals('TestFoo', $this->namePrettifier->prettifyTestClass('TestFoo')); - $this->assertEquals('FooTest', $this->namePrettifier->prettifyTestClass('FooTest')); - } - - /** - * @covers PHPUnit_Util_TestDox_NamePrettifier::prettifyTestClass - */ - public function testCaterForUserDefinedPrefix() - { - $this->namePrettifier->setSuffix(null); - $this->namePrettifier->setPrefix('XXX'); - - $this->assertEquals('Foo', $this->namePrettifier->prettifyTestClass('XXXFoo')); - $this->assertEquals('TestXXX', $this->namePrettifier->prettifyTestClass('TestXXX')); - $this->assertEquals('XXX', $this->namePrettifier->prettifyTestClass('XXXXXX')); - } - - /** - * @covers PHPUnit_Util_TestDox_NamePrettifier::prettifyTestMethod - */ - public function testTestNameIsConvertedToASentence() - { - $this->assertEquals('This is a test', $this->namePrettifier->prettifyTestMethod('testThisIsATest')); - $this->assertEquals('This is a test', $this->namePrettifier->prettifyTestMethod('testThisIsATest2')); - $this->assertEquals('this is a test', $this->namePrettifier->prettifyTestMethod('this_is_a_test')); - $this->assertEquals('Foo for bar is 0', $this->namePrettifier->prettifyTestMethod('testFooForBarIs0')); - $this->assertEquals('Foo for baz is 1', $this->namePrettifier->prettifyTestMethod('testFooForBazIs1')); - } - - /** - * @covers PHPUnit_Util_TestDox_NamePrettifier::prettifyTestMethod - * @ticket 224 - */ - public function testTestNameIsNotGroupedWhenNotInSequence() - { - $this->assertEquals('Sets redirect header on 301', $this->namePrettifier->prettifyTestMethod('testSetsRedirectHeaderOn301')); - $this->assertEquals('Sets redirect header on 302', $this->namePrettifier->prettifyTestMethod('testSetsRedirectHeaderOn302')); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/TestTest.php b/vendor/phpunit/phpunit/tests/Util/TestTest.php deleted file mode 100644 index 0eb13faae..000000000 --- a/vendor/phpunit/phpunit/tests/Util/TestTest.php +++ /dev/null @@ -1,669 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -if (!defined('TEST_FILES_PATH')) { - define( - 'TEST_FILES_PATH', - dirname(__DIR__) . DIRECTORY_SEPARATOR . - '_files' . DIRECTORY_SEPARATOR - ); -} - -require TEST_FILES_PATH . 'CoverageNamespacedFunctionTest.php'; -require TEST_FILES_PATH . 'NamespaceCoveredFunction.php'; - -/** - * @since Class available since Release 3.3.6 - */ -class Util_TestTest extends PHPUnit_Framework_TestCase -{ - /** - * @covers PHPUnit_Util_Test::getExpectedException - * @todo Split up in separate tests - */ - public function testGetExpectedException() - { - $this->assertArraySubset( - array('class' => 'FooBarBaz', 'code' => null, 'message' => ''), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testOne') - ); - - $this->assertArraySubset( - array('class' => 'Foo_Bar_Baz', 'code' => null, 'message' => ''), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testTwo') - ); - - $this->assertArraySubset( - array('class' => 'Foo\Bar\Baz', 'code' => null, 'message' => ''), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testThree') - ); - - $this->assertArraySubset( - array('class' => 'ほげ', 'code' => null, 'message' => ''), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testFour') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => 1234, 'message' => 'Message'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testFive') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => 1234, 'message' => 'Message'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testSix') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => 'ExceptionCode', 'message' => 'Message'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testSeven') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => 0, 'message' => 'Message'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testEight') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => ExceptionTest::ERROR_CODE, 'message' => ExceptionTest::ERROR_MESSAGE), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testNine') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => null, 'message' => ''), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testSingleLine') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => My\Space\ExceptionNamespaceTest::ERROR_CODE, 'message' => My\Space\ExceptionNamespaceTest::ERROR_MESSAGE), - PHPUnit_Util_Test::getExpectedException('My\Space\ExceptionNamespaceTest', 'testConstants') - ); - - // Ensure the Class::CONST expression is only evaluated when the constant really exists - $this->assertArraySubset( - array('class' => 'Class', 'code' => 'ExceptionTest::UNKNOWN_CODE_CONSTANT', 'message' => 'ExceptionTest::UNKNOWN_MESSAGE_CONSTANT'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testUnknownConstants') - ); - - $this->assertArraySubset( - array('class' => 'Class', 'code' => 'My\Space\ExceptionNamespaceTest::UNKNOWN_CODE_CONSTANT', 'message' => 'My\Space\ExceptionNamespaceTest::UNKNOWN_MESSAGE_CONSTANT'), - PHPUnit_Util_Test::getExpectedException('My\Space\ExceptionNamespaceTest', 'testUnknownConstants') - ); - } - - /** - * @covers PHPUnit_Util_Test::getExpectedException - */ - public function testGetExpectedRegExp() - { - $this->assertArraySubset( - array('message_regex' => '#regex#'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testWithRegexMessage') - ); - - $this->assertArraySubset( - array('message_regex' => '#regex#'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testWithRegexMessageFromClassConstant') - ); - - $this->assertArraySubset( - array('message_regex' => 'ExceptionTest::UNKNOWN_MESSAGE_REGEX_CONSTANT'), - PHPUnit_Util_Test::getExpectedException('ExceptionTest', 'testWithUnknowRegexMessageFromClassConstant') - ); - } - - /** - * @covers PHPUnit_Util_Test::getRequirements - * @dataProvider requirementsProvider - */ - public function testGetRequirements($test, $result) - { - $this->assertEquals( - $result, - PHPUnit_Util_Test::getRequirements('RequirementsTest', $test) - ); - } - - public function requirementsProvider() - { - return array( - array('testOne', array()), - array('testTwo', array('PHPUnit' => '1.0')), - array('testThree', array('PHP' => '2.0')), - array('testFour', array('PHPUnit'=>'2.0', 'PHP' => '1.0')), - array('testFive', array('PHP' => '5.4.0RC6')), - array('testSix', array('PHP' => '5.4.0-alpha1')), - array('testSeven', array('PHP' => '5.4.0beta2')), - array('testEight', array('PHP' => '5.4-dev')), - array('testNine', array('functions' => array('testFunc'))), - array('testTen', array('extensions' => array('testExt'))), - array('testEleven', array('OS' => '/Linux/i')), - array( - 'testSpace', - array( - 'extensions' => array('spl'), - 'OS' => '/.*/i' - ) - ), - array( - 'testAllPossibleRequirements', - array( - 'PHP' => '99-dev', - 'PHPUnit' => '9-dev', - 'OS' => '/DOESNOTEXIST/i', - 'functions' => array( - 'testFuncOne', - 'testFuncTwo', - ), - 'extensions' => array( - 'testExtOne', - 'testExtTwo', - ) - ) - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getRequirements - */ - public function testGetRequirementsMergesClassAndMethodDocBlocks() - { - $expectedAnnotations = array( - 'PHP' => '5.4', - 'PHPUnit' => '3.7', - 'OS' => '/WINNT/i', - 'functions' => array( - 'testFuncClass', - 'testFuncMethod', - ), - 'extensions' => array( - 'testExtClass', - 'testExtMethod', - ) - ); - - $this->assertEquals( - $expectedAnnotations, - PHPUnit_Util_Test::getRequirements('RequirementsClassDocBlockTest', 'testMethod') - ); - } - - /** - * @covers PHPUnit_Util_Test::getMissingRequirements - * @dataProvider missingRequirementsProvider - */ - public function testGetMissingRequirements($test, $result) - { - $this->assertEquals( - $result, - PHPUnit_Util_Test::getMissingRequirements('RequirementsTest', $test) - ); - } - - public function missingRequirementsProvider() - { - return array( - array('testOne', array()), - array('testNine', array('Function testFunc is required.')), - array('testTen', array('Extension testExt is required.')), - array('testAlwaysSkip', array('PHPUnit 1111111 (or later) is required.')), - array('testAlwaysSkip2', array('PHP 9999999 (or later) is required.')), - array('testAlwaysSkip3', array('Operating system matching /DOESNOTEXIST/i is required.')), - array('testAllPossibleRequirements', array( - 'PHP 99-dev (or later) is required.', - 'PHPUnit 9-dev (or later) is required.', - 'Operating system matching /DOESNOTEXIST/i is required.', - 'Function testFuncOne is required.', - 'Function testFuncTwo is required.', - 'Extension testExtOne is required.', - 'Extension testExtTwo is required.', - )), - ); - } - - /** - * @coversNothing - * @todo This test does not really test functionality of PHPUnit_Util_Test - */ - public function testGetProvidedDataRegEx() - { - $result = preg_match(PHPUnit_Util_Test::REGEX_DATA_PROVIDER, '@dataProvider method', $matches); - $this->assertEquals(1, $result); - $this->assertEquals('method', $matches[1]); - - $result = preg_match(PHPUnit_Util_Test::REGEX_DATA_PROVIDER, '@dataProvider class::method', $matches); - $this->assertEquals(1, $result); - $this->assertEquals('class::method', $matches[1]); - - $result = preg_match(PHPUnit_Util_Test::REGEX_DATA_PROVIDER, '@dataProvider namespace\class::method', $matches); - $this->assertEquals(1, $result); - $this->assertEquals('namespace\class::method', $matches[1]); - - $result = preg_match(PHPUnit_Util_Test::REGEX_DATA_PROVIDER, '@dataProvider namespace\namespace\class::method', $matches); - $this->assertEquals(1, $result); - $this->assertEquals('namespace\namespace\class::method', $matches[1]); - - $result = preg_match(PHPUnit_Util_Test::REGEX_DATA_PROVIDER, '@dataProvider メソッド', $matches); - $this->assertEquals(1, $result); - $this->assertEquals('メソッド', $matches[1]); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithEmptyAnnotation() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation("/**\n * @anotherAnnotation\n */"); - $this->assertNull($result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithSimpleCase() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith [1] - */'); - $this->assertEquals(array(array(1)), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithMultiLineMultiParameterCase() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith [1, 2] - * [3, 4] - */'); - $this->assertEquals(array(array(1, 2), array(3, 4)), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithVariousTypes() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith ["ab"] - * [true] - * [null] - */'); - $this->assertEquals(array(array('ab'), array(true), array(null)), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithAnnotationAfter() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith [1] - * [2] - * @annotation - */'); - $this->assertEquals(array(array(1), array(2)), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithSimpleTextAfter() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith [1] - * [2] - * blah blah - */'); - $this->assertEquals(array(array(1), array(2)), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithCharacterEscape() - { - $result = PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith ["\"", "\""] - */'); - $this->assertEquals(array(array('"', '"')), $result); - } - - /** - * @covers PHPUnit_Util_Test::getDataFromTestWithAnnotation - */ - public function testTestWithThrowsProperExceptionIfDatasetCannotBeParsed() - { - $this->setExpectedExceptionRegExp( - 'PHPUnit_Framework_Exception', - '/^The dataset for the @testWith annotation cannot be parsed.$/' - ); - PHPUnit_Util_Test::getDataFromTestWithAnnotation('/** - * @testWith [s] - */'); - } - - /** - * @covers PHPUnit_Util_Test::getDependencies - * @todo Not sure what this test tests (name is misleading at least) - */ - public function testParseAnnotation() - { - $this->assertEquals( - array('Foo', 'ほげ'), - PHPUnit_Util_Test::getDependencies(get_class($this), 'methodForTestParseAnnotation') - ); - } - - /** - * @depends Foo - * @depends ほげ - * @todo Remove fixture from test class - */ - public function methodForTestParseAnnotation() - { - } - - /** - * @covers PHPUnit_Util_Test::getDependencies - */ - public function testParseAnnotationThatIsOnlyOneLine() - { - $this->assertEquals( - array('Bar'), - PHPUnit_Util_Test::getDependencies(get_class($this), 'methodForTestParseAnnotationThatIsOnlyOneLine') - ); - } - - /** @depends Bar */ - public function methodForTestParseAnnotationThatIsOnlyOneLine() - { - // TODO Remove fixture from test class - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - * @covers PHPUnit_Util_Test::resolveElementToReflectionObjects - * @dataProvider getLinesToBeCoveredProvider - */ - public function testGetLinesToBeCovered($test, $lines) - { - if (strpos($test, 'Namespace') === 0) { - $expected = array( - TEST_FILES_PATH . 'NamespaceCoveredClass.php' => $lines - ); - } elseif ($test === 'CoverageNoneTest') { - $expected = array(); - } elseif ($test === 'CoverageNothingTest') { - $expected = false; - } elseif ($test === 'CoverageFunctionTest') { - $expected = array( - TEST_FILES_PATH . 'CoveredFunction.php' => $lines - ); - } else { - $expected = array(TEST_FILES_PATH . 'CoveredClass.php' => $lines); - } - - $this->assertEquals( - $expected, - PHPUnit_Util_Test::getLinesToBeCovered( - $test, 'testSomething' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - * @covers PHPUnit_Util_Test::resolveElementToReflectionObjects - * @expectedException PHPUnit_Framework_CodeCoverageException - */ - public function testGetLinesToBeCovered2() - { - PHPUnit_Util_Test::getLinesToBeCovered( - 'NotExistingCoveredElementTest', 'testOne' - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - * @covers PHPUnit_Util_Test::resolveElementToReflectionObjects - * @expectedException PHPUnit_Framework_CodeCoverageException - */ - public function testGetLinesToBeCovered3() - { - PHPUnit_Util_Test::getLinesToBeCovered( - 'NotExistingCoveredElementTest', 'testTwo' - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - * @covers PHPUnit_Util_Test::resolveElementToReflectionObjects - * @expectedException PHPUnit_Framework_CodeCoverageException - */ - public function testGetLinesToBeCovered4() - { - PHPUnit_Util_Test::getLinesToBeCovered( - 'NotExistingCoveredElementTest', 'testThree' - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testGetLinesToBeCoveredSkipsNonExistentMethods() - { - $this->assertSame( - array(), - PHPUnit_Util_Test::getLinesToBeCovered( - 'NotExistingCoveredElementTest', - 'methodDoesNotExist' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - * @expectedException PHPUnit_Framework_CodeCoverageException - */ - public function testTwoCoversDefaultClassAnnoationsAreNotAllowed() - { - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageTwoDefaultClassAnnotations', - 'testSomething' - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testFunctionParenthesesAreAllowed() - { - $this->assertSame( - array(TEST_FILES_PATH . 'CoveredFunction.php' => range(2, 4)), - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageFunctionParenthesesTest', - 'testSomething' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testFunctionParenthesesAreAllowedWithWhitespace() - { - $this->assertSame( - array(TEST_FILES_PATH . 'CoveredFunction.php' => range(2, 4)), - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageFunctionParenthesesWhitespaceTest', - 'testSomething' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testMethodParenthesesAreAllowed() - { - $this->assertSame( - array(TEST_FILES_PATH . 'CoveredClass.php' => range(31, 35)), - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageMethodParenthesesTest', - 'testSomething' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testMethodParenthesesAreAllowedWithWhitespace() - { - $this->assertSame( - array(TEST_FILES_PATH . 'CoveredClass.php' => range(31, 35)), - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageMethodParenthesesWhitespaceTest', - 'testSomething' - ) - ); - } - - /** - * @covers PHPUnit_Util_Test::getLinesToBeCovered - * @covers PHPUnit_Util_Test::getLinesToBeCoveredOrUsed - */ - public function testNamespacedFunctionCanBeCoveredOrUsed() - { - $this->assertEquals( - array( - TEST_FILES_PATH . 'NamespaceCoveredFunction.php' => range(4, 7) - ), - PHPUnit_Util_Test::getLinesToBeCovered( - 'CoverageNamespacedFunctionTest', - 'testFunc' - ) - ); - } - - public function getLinesToBeCoveredProvider() - { - return array( - array( - 'CoverageNoneTest', - array() - ), - array( - 'CoverageClassExtendedTest', - array_merge(range(19, 36), range(2, 17)) - ), - array( - 'CoverageClassTest', - range(19, 36) - ), - array( - 'CoverageMethodTest', - range(31, 35) - ), - array( - 'CoverageMethodOneLineAnnotationTest', - range(31, 35) - ), - array( - 'CoverageNotPrivateTest', - array_merge(range(25, 29), range(31, 35)) - ), - array( - 'CoverageNotProtectedTest', - array_merge(range(21, 23), range(31, 35)) - ), - array( - 'CoverageNotPublicTest', - array_merge(range(21, 23), range(25, 29)) - ), - array( - 'CoveragePrivateTest', - range(21, 23) - ), - array( - 'CoverageProtectedTest', - range(25, 29) - ), - array( - 'CoveragePublicTest', - range(31, 35) - ), - array( - 'CoverageFunctionTest', - range(2, 4) - ), - array( - 'NamespaceCoverageClassExtendedTest', - array_merge(range(21, 38), range(4, 19)) - ), - array( - 'NamespaceCoverageClassTest', - range(21, 38) - ), - array( - 'NamespaceCoverageMethodTest', - range(33, 37) - ), - array( - 'NamespaceCoverageNotPrivateTest', - array_merge(range(27, 31), range(33, 37)) - ), - array( - 'NamespaceCoverageNotProtectedTest', - array_merge(range(23, 25), range(33, 37)) - ), - array( - 'NamespaceCoverageNotPublicTest', - array_merge(range(23, 25), range(27, 31)) - ), - array( - 'NamespaceCoveragePrivateTest', - range(23, 25) - ), - array( - 'NamespaceCoverageProtectedTest', - range(27, 31) - ), - array( - 'NamespaceCoveragePublicTest', - range(33, 37) - ), - array( - 'NamespaceCoverageCoversClassTest', - array_merge(range(23, 25), range(27, 31), range(33, 37), range(6, 8), range(10, 13), range(15, 18)) - ), - array( - 'NamespaceCoverageCoversClassPublicTest', - range(33, 37) - ), - array( - 'CoverageNothingTest', - false - ) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/Util/XMLTest.php b/vendor/phpunit/phpunit/tests/Util/XMLTest.php deleted file mode 100644 index 086b738c1..000000000 --- a/vendor/phpunit/phpunit/tests/Util/XMLTest.php +++ /dev/null @@ -1,318 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * @since Class available since Release 3.3.0 - * @covers PHPUnit_Util_XML - */ -class Util_XMLTest extends PHPUnit_Framework_TestCase -{ - public function testAssertValidKeysValidKeys() - { - $options = array('testA' => 1, 'testB' => 2, 'testC' => 3); - $valid = array('testA', 'testB', 'testC'); - $expected = array('testA' => 1, 'testB' => 2, 'testC' => 3); - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - - $this->assertEquals($expected, $validated); - } - - public function testAssertValidKeysValidKeysEmpty() - { - $options = array('testA' => 1, 'testB' => 2); - $valid = array('testA', 'testB', 'testC'); - $expected = array('testA' => 1, 'testB' => 2, 'testC' => null); - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - - $this->assertEquals($expected, $validated); - } - - public function testAssertValidKeysDefaultValuesA() - { - $options = array('testA' => 1, 'testB' => 2); - $valid = array('testA' => 23, 'testB' => 24, 'testC' => 25); - $expected = array('testA' => 1, 'testB' => 2, 'testC' => 25); - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - - $this->assertEquals($expected, $validated); - } - - public function testAssertValidKeysDefaultValuesB() - { - $options = array(); - $valid = array('testA' => 23, 'testB' => 24, 'testC' => 25); - $expected = array('testA' => 23, 'testB' => 24, 'testC' => 25); - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - - $this->assertEquals($expected, $validated); - } - - public function testAssertValidKeysInvalidKey() - { - $options = array('testA' => 1, 'testB' => 2, 'testD' => 3); - $valid = array('testA', 'testB', 'testC'); - - try { - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - $this->fail(); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Unknown key(s): testD', $e->getMessage()); - } - } - - public function testAssertValidKeysInvalidKeys() - { - $options = array('testA' => 1, 'testD' => 2, 'testE' => 3); - $valid = array('testA', 'testB', 'testC'); - - try { - $validated = PHPUnit_Util_XML::assertValidKeys($options, $valid); - $this->fail(); - } catch (PHPUnit_Framework_Exception $e) { - $this->assertEquals('Unknown key(s): testD, testE', $e->getMessage()); - } - } - - public function testConvertAssertSelect() - { - $selector = 'div#folder.open a[href="http://www.xerox.com"][title="xerox"].selected.big > span + h1'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', - 'id' => 'folder', - 'class' => 'open', - 'descendant' => array('tag' => 'a', - 'class' => 'selected big', - 'attributes' => array('href' => 'http://www.xerox.com', - 'title' => 'xerox'), - 'child' => array('tag' => 'span', - 'adjacent-sibling' => array('tag' => 'h1')))); - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectElt() - { - $selector = 'div'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertClass() - { - $selector = '.foo'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('class' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertId() - { - $selector = '#foo'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('id' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertAttribute() - { - $selector = '[foo="bar"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('attributes' => array('foo' => 'bar')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertAttributeSpaces() - { - $selector = '[foo="bar baz"] div[value="foo bar"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('attributes' => array('foo' => 'bar baz'), - 'descendant' => array('tag' => 'div', - 'attributes' => array('value' => 'foo bar'))); - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertAttributeMultipleSpaces() - { - $selector = '[foo="bar baz"] div[value="foo bar baz"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('attributes' => array('foo' => 'bar baz'), - 'descendant' => array('tag' => 'div', - 'attributes' => array('value' => 'foo bar baz'))); - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltClass() - { - $selector = 'div.foo'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'class' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltId() - { - $selector = 'div#foo'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'id' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltAttrEqual() - { - $selector = 'div[foo="bar"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'attributes' => array('foo' => 'bar')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltMultiAttrEqual() - { - $selector = 'div[foo="bar"][baz="fob"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'attributes' => array('foo' => 'bar', 'baz' => 'fob')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltAttrHasOne() - { - $selector = 'div[foo~="bar"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'attributes' => array('foo' => 'regexp:/.*\bbar\b.*/')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltAttrContains() - { - $selector = 'div[foo*="bar"]'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'attributes' => array('foo' => 'regexp:/.*bar.*/')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltChild() - { - $selector = 'div > a'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'child' => array('tag' => 'a')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltAdjacentSibling() - { - $selector = 'div + a'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'adjacent-sibling' => array('tag' => 'a')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectEltDescendant() - { - $selector = 'div a'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector); - $tag = array('tag' => 'div', 'descendant' => array('tag' => 'a')); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectContent() - { - $selector = '#foo'; - $content = 'div contents'; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector, $content); - $tag = array('id' => 'foo', 'content' => 'div contents'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectTrue() - { - $selector = '#foo'; - $content = true; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector, $content); - $tag = array('id' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertSelectFalse() - { - $selector = '#foo'; - $content = false; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector, $content); - $tag = array('id' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertNumber() - { - $selector = '.foo'; - $content = 3; - $converted = PHPUnit_Util_XML::convertSelectToTag($selector, $content); - $tag = array('class' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - public function testConvertAssertRange() - { - $selector = '#foo'; - $content = array('greater_than' => 5, 'less_than' => 10); - $converted = PHPUnit_Util_XML::convertSelectToTag($selector, $content); - $tag = array('id' => 'foo'); - - $this->assertEquals($tag, $converted); - } - - /** - * @dataProvider charProvider - */ - public function testPrepareString($char) - { - $e = null; - - $escapedString = PHPUnit_Util_XML::prepareString($char); - $xml = "$escapedString"; - $dom = new DomDocument('1.0', 'UTF-8'); - - try { - $dom->loadXML($xml); - } catch (Exception $e) { - } - - $this->assertNull($e, sprintf( - 'PHPUnit_Util_XML::prepareString("\x%02x") should not crash DomDocument', - ord($char) - )); - } - - public function charProvider() - { - $data = array(); - - for ($i = 0; $i < 256; $i++) { - $data[] = array(chr($i)); - } - - return $data; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/AbstractTest.php b/vendor/phpunit/phpunit/tests/_files/AbstractTest.php deleted file mode 100644 index 556e7dbc0..000000000 --- a/vendor/phpunit/phpunit/tests/_files/AbstractTest.php +++ /dev/null @@ -1,7 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * An author. - * - * @since Class available since Release 3.6.0 - */ -class Author -{ - // the order of properties is important for testing the cycle! - public $books = array(); - - private $name = ''; - - public function __construct($name) - { - $this->name = $name; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/BankAccount.php b/vendor/phpunit/phpunit/tests/_files/BankAccount.php deleted file mode 100644 index 7b13443a7..000000000 --- a/vendor/phpunit/phpunit/tests/_files/BankAccount.php +++ /dev/null @@ -1,79 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -class BankAccountException extends RuntimeException -{ -} - -/** - * A bank account. - * - * @since Class available since Release 2.3.0 - */ -class BankAccount -{ - /** - * The bank account's balance. - * - * @var float - */ - protected $balance = 0; - - /** - * Returns the bank account's balance. - * - * @return float - */ - public function getBalance() - { - return $this->balance; - } - - /** - * Sets the bank account's balance. - * - * @param float $balance - * @throws BankAccountException - */ - protected function setBalance($balance) - { - if ($balance >= 0) { - $this->balance = $balance; - } else { - throw new BankAccountException; - } - } - - /** - * Deposits an amount of money to the bank account. - * - * @param float $balance - * @throws BankAccountException - */ - public function depositMoney($balance) - { - $this->setBalance($this->getBalance() + $balance); - - return $this->getBalance(); - } - - /** - * Withdraws an amount of money from the bank account. - * - * @param float $balance - * @throws BankAccountException - */ - public function withdrawMoney($balance) - { - $this->setBalance($this->getBalance() - $balance); - - return $this->getBalance(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/BankAccountTest.php b/vendor/phpunit/phpunit/tests/_files/BankAccountTest.php deleted file mode 100644 index b8e7061ea..000000000 --- a/vendor/phpunit/phpunit/tests/_files/BankAccountTest.php +++ /dev/null @@ -1,87 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the BankAccount class. - * - * @since Class available since Release 2.3.0 - */ -class BankAccountTest extends PHPUnit_Framework_TestCase -{ - protected $ba; - - protected function setUp() - { - $this->ba = new BankAccount; - } - - /** - * @covers BankAccount::getBalance - * @group balanceIsInitiallyZero - * @group specification - */ - public function testBalanceIsInitiallyZero() - { - $this->assertEquals(0, $this->ba->getBalance()); - } - - /** - * @covers BankAccount::withdrawMoney - * @group balanceCannotBecomeNegative - * @group specification - */ - public function testBalanceCannotBecomeNegative() - { - try { - $this->ba->withdrawMoney(1); - } catch (BankAccountException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::depositMoney - * @group balanceCannotBecomeNegative - * @group specification - */ - public function testBalanceCannotBecomeNegative2() - { - try { - $this->ba->depositMoney(-1); - } catch (BankAccountException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /* - * @covers BankAccount::getBalance - * @covers BankAccount::depositMoney - * @covers BankAccount::withdrawMoney - * @group balanceCannotBecomeNegative - */ - /* - public function testDepositingAndWithdrawingMoneyWorks() - { - $this->assertEquals(0, $this->ba->getBalance()); - $this->ba->depositMoney(1); - $this->assertEquals(1, $this->ba->getBalance()); - $this->ba->withdrawMoney(1); - $this->assertEquals(0, $this->ba->getBalance()); - } - */ -} diff --git a/vendor/phpunit/phpunit/tests/_files/BankAccountTest.test.php b/vendor/phpunit/phpunit/tests/_files/BankAccountTest.test.php deleted file mode 100644 index 371cc7711..000000000 --- a/vendor/phpunit/phpunit/tests/_files/BankAccountTest.test.php +++ /dev/null @@ -1,87 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * Tests for the BankAccount class. - * - * @since Class available since Release 2.3.0 - */ -class BankAccountWithCustomExtensionTest extends PHPUnit_Framework_TestCase -{ - protected $ba; - - protected function setUp() - { - $this->ba = new BankAccount; - } - - /** - * @covers BankAccount::getBalance - * @group balanceIsInitiallyZero - * @group specification - */ - public function testBalanceIsInitiallyZero() - { - $this->assertEquals(0, $this->ba->getBalance()); - } - - /** - * @covers BankAccount::withdrawMoney - * @group balanceCannotBecomeNegative - * @group specification - */ - public function testBalanceCannotBecomeNegative() - { - try { - $this->ba->withdrawMoney(1); - } catch (BankAccountException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::depositMoney - * @group balanceCannotBecomeNegative - * @group specification - */ - public function testBalanceCannotBecomeNegative2() - { - try { - $this->ba->depositMoney(-1); - } catch (BankAccountException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /* - * @covers BankAccount::getBalance - * @covers BankAccount::depositMoney - * @covers BankAccount::withdrawMoney - * @group balanceCannotBecomeNegative - */ - /* - public function testDepositingAndWithdrawingMoneyWorks() - { - $this->assertEquals(0, $this->ba->getBalance()); - $this->ba->depositMoney(1); - $this->assertEquals(1, $this->ba->getBalance()); - $this->ba->withdrawMoney(1); - $this->assertEquals(0, $this->ba->getBalance()); - } - */ -} diff --git a/vendor/phpunit/phpunit/tests/_files/BaseTestListenerSample.php b/vendor/phpunit/phpunit/tests/_files/BaseTestListenerSample.php deleted file mode 100644 index 7753b280a..000000000 --- a/vendor/phpunit/phpunit/tests/_files/BaseTestListenerSample.php +++ /dev/null @@ -1,11 +0,0 @@ -endCount++; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/BeforeAndAfterTest.php b/vendor/phpunit/phpunit/tests/_files/BeforeAndAfterTest.php deleted file mode 100644 index 0b52526ae..000000000 --- a/vendor/phpunit/phpunit/tests/_files/BeforeAndAfterTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * A book. - * - * @since Class available since Release 3.6.0 - */ -class Book -{ - // the order of properties is important for testing the cycle! - public $author = null; -} diff --git a/vendor/phpunit/phpunit/tests/_files/Calculator.php b/vendor/phpunit/phpunit/tests/_files/Calculator.php deleted file mode 100644 index e269bd6ca..000000000 --- a/vendor/phpunit/phpunit/tests/_files/Calculator.php +++ /dev/null @@ -1,14 +0,0 @@ -assertTrue(true); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ClassWithNonPublicAttributes.php b/vendor/phpunit/phpunit/tests/_files/ClassWithNonPublicAttributes.php deleted file mode 100644 index abc8ff66d..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ClassWithNonPublicAttributes.php +++ /dev/null @@ -1,29 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/** - * A class with a __toString() method. - * - * @since Class available since Release 3.6.0 - */ -class ClassWithToString -{ - public function __toString() - { - return 'string representation'; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ConcreteTest.my.php b/vendor/phpunit/phpunit/tests/_files/ConcreteTest.my.php deleted file mode 100644 index fe01ceed5..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ConcreteTest.my.php +++ /dev/null @@ -1,7 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageClassTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageClassTest.php deleted file mode 100644 index 7f569ae60..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageClassTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageFunctionParenthesesTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageFunctionParenthesesTest.php deleted file mode 100644 index 33b5fe3de..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageFunctionParenthesesTest.php +++ /dev/null @@ -1,11 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesTest.php deleted file mode 100644 index 422300457..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesWhitespaceTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesWhitespaceTest.php deleted file mode 100644 index d1be1c6cf..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageMethodParenthesesWhitespaceTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageMethodTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageMethodTest.php deleted file mode 100644 index 167b3db4c..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageMethodTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageNamespacedFunctionTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageNamespacedFunctionTest.php deleted file mode 100644 index 9fc056fa3..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageNamespacedFunctionTest.php +++ /dev/null @@ -1,11 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageNotPrivateTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageNotPrivateTest.php deleted file mode 100644 index 12b56e80e..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageNotPrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageNotProtectedTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageNotProtectedTest.php deleted file mode 100644 index c69d261de..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageNotProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageNotPublicTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageNotPublicTest.php deleted file mode 100644 index aebfe4bd9..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageNotPublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageNothingTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageNothingTest.php deleted file mode 100644 index 5d5680d93..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageNothingTest.php +++ /dev/null @@ -1,13 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoveragePrivateTest.php b/vendor/phpunit/phpunit/tests/_files/CoveragePrivateTest.php deleted file mode 100644 index f09560d3a..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoveragePrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageProtectedTest.php b/vendor/phpunit/phpunit/tests/_files/CoverageProtectedTest.php deleted file mode 100644 index 9b3acbf6c..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoveragePublicTest.php b/vendor/phpunit/phpunit/tests/_files/CoveragePublicTest.php deleted file mode 100644 index 480a522b4..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoveragePublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoverageTwoDefaultClassAnnotations.php b/vendor/phpunit/phpunit/tests/_files/CoverageTwoDefaultClassAnnotations.php deleted file mode 100644 index 1011769f7..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoverageTwoDefaultClassAnnotations.php +++ /dev/null @@ -1,17 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoveredClass.php b/vendor/phpunit/phpunit/tests/_files/CoveredClass.php deleted file mode 100644 index f382ce99b..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoveredClass.php +++ /dev/null @@ -1,36 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/CoveredFunction.php b/vendor/phpunit/phpunit/tests/_files/CoveredFunction.php deleted file mode 100644 index 9989eb02e..000000000 --- a/vendor/phpunit/phpunit/tests/_files/CoveredFunction.php +++ /dev/null @@ -1,4 +0,0 @@ -assertTrue(true); - } - - public static function provider() - { - $obj2 = new \stdClass(); - $obj2->foo = 'bar'; - - $obj3 = (object) array(1,2,"Test\r\n",4,5,6,7,8); - - $obj = new \stdClass(); - //@codingStandardsIgnoreStart - $obj->null = null; - //@codingStandardsIgnoreEnd - $obj->boolean = true; - $obj->integer = 1; - $obj->double = 1.2; - $obj->string = '1'; - $obj->text = "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"; - $obj->object = $obj2; - $obj->objectagain = $obj2; - $obj->array = array('foo' => 'bar'); - $obj->self = $obj; - - $storage = new \SplObjectStorage(); - $storage->attach($obj2); - $storage->foo = $obj2; - - return array( - array(null, true, 1, 1.0), - array(1.2, fopen('php://memory', 'r'), '1'), - array(array(array(1,2,3), array(3,4,5))), - // \n\r and \r is converted to \n - array("this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"), - array(new \stdClass(), $obj, array(), $storage, $obj3), - array(chr(0) . chr(1) . chr(2) . chr(3) . chr(4) . chr(5), implode('', array_map('chr', range(0x0e, 0x1f)))), - array(chr(0x00) . chr(0x09)) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DataProviderFilterTest.php b/vendor/phpunit/phpunit/tests/_files/DataProviderFilterTest.php deleted file mode 100644 index a872bc992..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DataProviderFilterTest.php +++ /dev/null @@ -1,39 +0,0 @@ -assertTrue($truth); - } - - public static function truthProvider() - { - return array( - array(true), - array(true), - array(true), - array(true) - ); - } - - /** - * @dataProvider falseProvider - */ - public function testFalse($false) - { - $this->assertFalse($false); - } - - public static function falseProvider() - { - return array( - 'false test' => array(false), - 'false test 2' => array(false), - 'other false test' => array(false), - 'other false test2'=> array(false) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DataProviderIncompleteTest.php b/vendor/phpunit/phpunit/tests/_files/DataProviderIncompleteTest.php deleted file mode 100644 index e0efb5bc0..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DataProviderIncompleteTest.php +++ /dev/null @@ -1,37 +0,0 @@ -assertTrue(true); - } - - /** - * @dataProvider providerMethod - */ - public function testAdd($a, $b, $c) - { - $this->assertEquals($c, $a + $b); - } - - public function incompleteTestProviderMethod() - { - $this->markTestIncomplete('incomplete'); - - return array( - array(0, 0, 0), - array(0, 1, 1), - ); - } - - public static function providerMethod() - { - return array( - array(0, 0, 0), - array(0, 1, 1), - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DataProviderSkippedTest.php b/vendor/phpunit/phpunit/tests/_files/DataProviderSkippedTest.php deleted file mode 100644 index ec67ce55f..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DataProviderSkippedTest.php +++ /dev/null @@ -1,37 +0,0 @@ -assertTrue(true); - } - - /** - * @dataProvider providerMethod - */ - public function testAdd($a, $b, $c) - { - $this->assertEquals($c, $a + $b); - } - - public function skippedTestProviderMethod() - { - $this->markTestSkipped('skipped'); - - return array( - array(0, 0, 0), - array(0, 1, 1), - ); - } - - public static function providerMethod() - { - return array( - array(0, 0, 0), - array(0, 1, 1), - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DataProviderTest.php b/vendor/phpunit/phpunit/tests/_files/DataProviderTest.php deleted file mode 100644 index d940a0595..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DataProviderTest.php +++ /dev/null @@ -1,21 +0,0 @@ -assertEquals($c, $a + $b); - } - - public static function providerMethod() - { - return array( - array(0, 0, 0), - array(0, 1, 1), - array(1, 1, 3), - array(1, 0, 1) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DependencyFailureTest.php b/vendor/phpunit/phpunit/tests/_files/DependencyFailureTest.php deleted file mode 100644 index d83aecd82..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DependencyFailureTest.php +++ /dev/null @@ -1,22 +0,0 @@ -fail(); - } - - /** - * @depends testOne - */ - public function testTwo() - { - } - - /** - * @depends testTwo - */ - public function testThree() - { - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DependencySuccessTest.php b/vendor/phpunit/phpunit/tests/_files/DependencySuccessTest.php deleted file mode 100644 index 0e4b5ddeb..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DependencySuccessTest.php +++ /dev/null @@ -1,21 +0,0 @@ -addTestSuite('DependencySuccessTest'); - $suite->addTestSuite('DependencyFailureTest'); - - return $suite; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DoubleTestCase.php b/vendor/phpunit/phpunit/tests/_files/DoubleTestCase.php deleted file mode 100644 index b1f00a8ff..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DoubleTestCase.php +++ /dev/null @@ -1,25 +0,0 @@ -testCase = $testCase; - } - - public function count() - { - return 2; - } - - public function run(PHPUnit_Framework_TestResult $result = null) - { - $result->startTest($this); - - $this->testCase->runBare(); - $this->testCase->runBare(); - - $result->endTest($this, 0); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/DummyException.php b/vendor/phpunit/phpunit/tests/_files/DummyException.php deleted file mode 100644 index 29a69b997..000000000 --- a/vendor/phpunit/phpunit/tests/_files/DummyException.php +++ /dev/null @@ -1,5 +0,0 @@ -setUp = true; - } - - protected function assertPreConditions() - { - $this->assertPreConditions = true; - } - - public function testSomething() - { - $this->testSomething = true; - } - - protected function assertPostConditions() - { - $this->assertPostConditions = true; - throw new Exception; - } - - protected function tearDown() - { - $this->tearDown = true; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionInAssertPreConditionsTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionInAssertPreConditionsTest.php deleted file mode 100644 index a375d0508..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionInAssertPreConditionsTest.php +++ /dev/null @@ -1,35 +0,0 @@ -setUp = true; - } - - protected function assertPreConditions() - { - $this->assertPreConditions = true; - throw new Exception; - } - - public function testSomething() - { - $this->testSomething = true; - } - - protected function assertPostConditions() - { - $this->assertPostConditions = true; - } - - protected function tearDown() - { - $this->tearDown = true; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionInSetUpTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionInSetUpTest.php deleted file mode 100644 index 193b9a822..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionInSetUpTest.php +++ /dev/null @@ -1,35 +0,0 @@ -setUp = true; - throw new Exception; - } - - protected function assertPreConditions() - { - $this->assertPreConditions = true; - } - - public function testSomething() - { - $this->testSomething = true; - } - - protected function assertPostConditions() - { - $this->assertPostConditions = true; - } - - protected function tearDown() - { - $this->tearDown = true; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionInTearDownTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionInTearDownTest.php deleted file mode 100644 index 5ee4a9d13..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionInTearDownTest.php +++ /dev/null @@ -1,35 +0,0 @@ -setUp = true; - } - - protected function assertPreConditions() - { - $this->assertPreConditions = true; - } - - public function testSomething() - { - $this->testSomething = true; - } - - protected function assertPostConditions() - { - $this->assertPostConditions = true; - } - - protected function tearDown() - { - $this->tearDown = true; - throw new Exception; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionInTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionInTest.php deleted file mode 100644 index 32c7e24a8..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionInTest.php +++ /dev/null @@ -1,35 +0,0 @@ -setUp = true; - } - - protected function assertPreConditions() - { - $this->assertPreConditions = true; - } - - public function testSomething() - { - $this->testSomething = true; - throw new Exception; - } - - protected function assertPostConditions() - { - $this->assertPostConditions = true; - } - - protected function tearDown() - { - $this->tearDown = true; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionNamespaceTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionNamespaceTest.php deleted file mode 100644 index 22f3760b5..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionNamespaceTest.php +++ /dev/null @@ -1,38 +0,0 @@ -assertEquals(array(1), array(2), 'message'); - } catch (PHPUnit_Framework_ExpectationFailedException $e) { - $message = $e->getMessage() . $e->getComparisonFailure()->getDiff(); - throw new PHPUnit_Framework_Exception("Child exception\n$message", 101, $e); - } - } - - public function testNestedExceptions() - { - $exceptionThree = new Exception('Three'); - $exceptionTwo = new InvalidArgumentException('Two', 0, $exceptionThree); - $exceptionOne = new Exception('One', 0, $exceptionTwo); - throw $exceptionOne; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ExceptionTest.php b/vendor/phpunit/phpunit/tests/_files/ExceptionTest.php deleted file mode 100644 index 021380529..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ExceptionTest.php +++ /dev/null @@ -1,139 +0,0 @@ -fail(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/FailureTest.php b/vendor/phpunit/phpunit/tests/_files/FailureTest.php deleted file mode 100644 index e9df755ae..000000000 --- a/vendor/phpunit/phpunit/tests/_files/FailureTest.php +++ /dev/null @@ -1,75 +0,0 @@ -assertEquals(array(1), array(2), 'message'); - } - - public function testAssertIntegerEqualsInteger() - { - $this->assertEquals(1, 2, 'message'); - } - - public function testAssertObjectEqualsObject() - { - $a = new StdClass; - $a->foo = 'bar'; - - $b = new StdClass; - $b->bar = 'foo'; - - $this->assertEquals($a, $b, 'message'); - } - - public function testAssertNullEqualsString() - { - $this->assertEquals(null, 'bar', 'message'); - } - - public function testAssertStringEqualsString() - { - $this->assertEquals('foo', 'bar', 'message'); - } - - public function testAssertTextEqualsText() - { - $this->assertEquals("foo\nbar\n", "foo\nbaz\n", 'message'); - } - - public function testAssertStringMatchesFormat() - { - $this->assertStringMatchesFormat('*%s*', '**', 'message'); - } - - public function testAssertNumericEqualsNumeric() - { - $this->assertEquals(1, 2, 'message'); - } - - public function testAssertTextSameText() - { - $this->assertSame('foo', 'bar', 'message'); - } - - public function testAssertObjectSameObject() - { - $this->assertSame(new StdClass, new StdClass, 'message'); - } - - public function testAssertObjectSameNull() - { - $this->assertSame(new StdClass, null, 'message'); - } - - public function testAssertFloatSameFloat() - { - $this->assertSame(1.0, 1.5, 'message'); - } - - // Note that due to the implementation of this assertion it counts as 2 asserts - public function testAssertStringMatchesFormatFile() - { - $this->assertStringMatchesFormatFile(__DIR__ . '/expectedFileFormat.txt', '...BAR...'); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/FatalTest.php b/vendor/phpunit/phpunit/tests/_files/FatalTest.php deleted file mode 100644 index bf005f992..000000000 --- a/vendor/phpunit/phpunit/tests/_files/FatalTest.php +++ /dev/null @@ -1,13 +0,0 @@ -markTestIncomplete('Test incomplete'); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/Inheritance/InheritanceA.php b/vendor/phpunit/phpunit/tests/_files/Inheritance/InheritanceA.php deleted file mode 100644 index e189b7d2a..000000000 --- a/vendor/phpunit/phpunit/tests/_files/Inheritance/InheritanceA.php +++ /dev/null @@ -1,7 +0,0 @@ -assertEquals('application/x-test', ini_get('default_mimetype')); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/IsolationTest.php b/vendor/phpunit/phpunit/tests/_files/IsolationTest.php deleted file mode 100644 index df95c9168..000000000 --- a/vendor/phpunit/phpunit/tests/_files/IsolationTest.php +++ /dev/null @@ -1,13 +0,0 @@ -assertFalse($this->isInIsolation()); - } - - public function testIsInIsolationReturnsTrue() - { - $this->assertTrue($this->isInIsolation()); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/JsonData/arrayObject.json b/vendor/phpunit/phpunit/tests/_files/JsonData/arrayObject.json deleted file mode 100644 index 8a74fc587..000000000 --- a/vendor/phpunit/phpunit/tests/_files/JsonData/arrayObject.json +++ /dev/null @@ -1 +0,0 @@ -["Mascott", "Tux", "OS", "Linux"] diff --git a/vendor/phpunit/phpunit/tests/_files/JsonData/simpleObject.json b/vendor/phpunit/phpunit/tests/_files/JsonData/simpleObject.json deleted file mode 100644 index 27085be25..000000000 --- a/vendor/phpunit/phpunit/tests/_files/JsonData/simpleObject.json +++ /dev/null @@ -1 +0,0 @@ -{"Mascott":"Tux"} \ No newline at end of file diff --git a/vendor/phpunit/phpunit/tests/_files/MockRunner.php b/vendor/phpunit/phpunit/tests/_files/MockRunner.php deleted file mode 100644 index b3bc0cc48..000000000 --- a/vendor/phpunit/phpunit/tests/_files/MockRunner.php +++ /dev/null @@ -1,7 +0,0 @@ -assertEquals('foo', $a); - $this->assertEquals('bar', $b); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassExtendedTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassExtendedTest.php deleted file mode 100644 index d0954cba9..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassExtendedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassTest.php deleted file mode 100644 index 63912c089..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageClassTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassPublicTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassPublicTest.php deleted file mode 100644 index 45f583b77..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassPublicTest.php +++ /dev/null @@ -1,15 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassTest.php deleted file mode 100644 index b33674546..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageCoversClassTest.php +++ /dev/null @@ -1,20 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageMethodTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageMethodTest.php deleted file mode 100644 index 35dfb8b1d..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageMethodTest.php +++ /dev/null @@ -1,12 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPrivateTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPrivateTest.php deleted file mode 100644 index 552c9ec50..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotProtectedTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotProtectedTest.php deleted file mode 100644 index 33fc8c72c..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPublicTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPublicTest.php deleted file mode 100644 index ccbc5009c..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageNotPublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePrivateTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePrivateTest.php deleted file mode 100644 index cce7ba9d6..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePrivateTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageProtectedTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageProtectedTest.php deleted file mode 100644 index dbbcc1c31..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoverageProtectedTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePublicTest.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePublicTest.php deleted file mode 100644 index bf1bff8c4..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveragePublicTest.php +++ /dev/null @@ -1,12 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredClass.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredClass.php deleted file mode 100644 index 5bd0ddfb2..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredClass.php +++ /dev/null @@ -1,38 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredFunction.php b/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredFunction.php deleted file mode 100644 index afc00d7c3..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NamespaceCoveredFunction.php +++ /dev/null @@ -1,7 +0,0 @@ - - */ - public function testThree() - { - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/NotPublicTestCase.php b/vendor/phpunit/phpunit/tests/_files/NotPublicTestCase.php deleted file mode 100644 index a39101000..000000000 --- a/vendor/phpunit/phpunit/tests/_files/NotPublicTestCase.php +++ /dev/null @@ -1,11 +0,0 @@ -expectOutputString('foo'); - print 'foo'; - } - - public function testExpectOutputStringFooActualBar() - { - $this->expectOutputString('foo'); - print 'bar'; - } - - public function testExpectOutputRegexFooActualFoo() - { - $this->expectOutputRegex('/foo/'); - print 'foo'; - } - - public function testExpectOutputRegexFooActualBar() - { - $this->expectOutputRegex('/foo/'); - print 'bar'; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/OverrideTestCase.php b/vendor/phpunit/phpunit/tests/_files/OverrideTestCase.php deleted file mode 100644 index fcc276c50..000000000 --- a/vendor/phpunit/phpunit/tests/_files/OverrideTestCase.php +++ /dev/null @@ -1,7 +0,0 @@ -container = array(); - } - public function offsetSet($offset, $value) - { - if (is_null($offset)) { - $this->container[] = $value; - } else { - $this->container[$offset] = $value; - } - } - public function offsetExists($offset) - { - return isset($this->container[$offset]); - } - public function offsetUnset($offset) - { - unset($this->container[$offset]); - } - public function offsetGet($offset) - { - return isset($this->container[$offset]) ? $this->container[$offset] : null; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/SampleClass.php b/vendor/phpunit/phpunit/tests/_files/SampleClass.php deleted file mode 100644 index 06c51c510..000000000 --- a/vendor/phpunit/phpunit/tests/_files/SampleClass.php +++ /dev/null @@ -1,14 +0,0 @@ -a = $a; - $this->b = $b; - $this->c = $c; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/Singleton.php b/vendor/phpunit/phpunit/tests/_files/Singleton.php deleted file mode 100644 index bfdf3bb0a..000000000 --- a/vendor/phpunit/phpunit/tests/_files/Singleton.php +++ /dev/null @@ -1,22 +0,0 @@ -assertEquals(0, count($stack)); - - array_push($stack, 'foo'); - $this->assertEquals('foo', $stack[count($stack)-1]); - $this->assertEquals(1, count($stack)); - - return $stack; - } - - /** - * @depends testPush - */ - public function testPop(array $stack) - { - $this->assertEquals('foo', array_pop($stack)); - $this->assertEquals(0, count($stack)); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/Struct.php b/vendor/phpunit/phpunit/tests/_files/Struct.php deleted file mode 100644 index 12977a996..000000000 --- a/vendor/phpunit/phpunit/tests/_files/Struct.php +++ /dev/null @@ -1,10 +0,0 @@ -var = $var; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/Success.php b/vendor/phpunit/phpunit/tests/_files/Success.php deleted file mode 100644 index 6d3dd6188..000000000 --- a/vendor/phpunit/phpunit/tests/_files/Success.php +++ /dev/null @@ -1,7 +0,0 @@ -assertTrue(true); - } - - public function testTwo() - { - print __METHOD__ . "\n"; - $this->assertTrue(false); - } - - protected function assertPostConditions() - { - print __METHOD__ . "\n"; - } - - protected function tearDown() - { - print __METHOD__ . "\n"; - } - - public static function tearDownAfterClass() - { - print __METHOD__ . "\n"; - } - - protected function onNotSuccessfulTest(Exception $e) - { - print __METHOD__ . "\n"; - throw $e; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/TestIncomplete.php b/vendor/phpunit/phpunit/tests/_files/TestIncomplete.php deleted file mode 100644 index 743a761cc..000000000 --- a/vendor/phpunit/phpunit/tests/_files/TestIncomplete.php +++ /dev/null @@ -1,8 +0,0 @@ -markTestIncomplete('Incomplete test'); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/TestIterator.php b/vendor/phpunit/phpunit/tests/_files/TestIterator.php deleted file mode 100644 index 01135e3b3..000000000 --- a/vendor/phpunit/phpunit/tests/_files/TestIterator.php +++ /dev/null @@ -1,36 +0,0 @@ -array = $array; - } - - public function rewind() - { - $this->position = 0; - } - - public function valid() - { - return $this->position < count($this->array); - } - - public function key() - { - return $this->position; - } - - public function current() - { - return $this->array[$this->position]; - } - - public function next() - { - $this->position++; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/TestIterator2.php b/vendor/phpunit/phpunit/tests/_files/TestIterator2.php deleted file mode 100644 index 3b47fa367..000000000 --- a/vendor/phpunit/phpunit/tests/_files/TestIterator2.php +++ /dev/null @@ -1,35 +0,0 @@ -data = $array; - } - - public function current() - { - return current($this->data); - } - - public function next() - { - next($this->data); - } - - public function key() - { - return key($this->data); - } - - public function valid() - { - return key($this->data) !== null; - } - - public function rewind() - { - reset($this->data); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/TestSkipped.php b/vendor/phpunit/phpunit/tests/_files/TestSkipped.php deleted file mode 100644 index c2d68b246..000000000 --- a/vendor/phpunit/phpunit/tests/_files/TestSkipped.php +++ /dev/null @@ -1,8 +0,0 @@ -markTestSkipped('Skipped test'); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/TestTestError.php b/vendor/phpunit/phpunit/tests/_files/TestTestError.php deleted file mode 100644 index 6f61b8ed6..000000000 --- a/vendor/phpunit/phpunit/tests/_files/TestTestError.php +++ /dev/null @@ -1,8 +0,0 @@ -assertEquals($c, $a + $b); - } - - public static function providerMethod() - { - return array( - array(0, 0, 0), - array(0, 1, 1), - array(1, 1, 3), - array(1, 0, 1) - ); - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/ThrowExceptionTestCase.php b/vendor/phpunit/phpunit/tests/_files/ThrowExceptionTestCase.php deleted file mode 100644 index 1d2a769ae..000000000 --- a/vendor/phpunit/phpunit/tests/_files/ThrowExceptionTestCase.php +++ /dev/null @@ -1,8 +0,0 @@ -wasRun = true; - } -} diff --git a/vendor/phpunit/phpunit/tests/_files/bar.xml b/vendor/phpunit/phpunit/tests/_files/bar.xml deleted file mode 100644 index 5d3fa282a..000000000 --- a/vendor/phpunit/phpunit/tests/_files/bar.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.colors.empty.xml b/vendor/phpunit/phpunit/tests/_files/configuration.colors.empty.xml deleted file mode 100644 index 5f9e05565..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.colors.empty.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.colors.false.xml b/vendor/phpunit/phpunit/tests/_files/configuration.colors.false.xml deleted file mode 100644 index dcd4aa47e..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.colors.false.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.colors.invalid.xml b/vendor/phpunit/phpunit/tests/_files/configuration.colors.invalid.xml deleted file mode 100644 index c5bd6990e..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.colors.invalid.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.colors.true.xml b/vendor/phpunit/phpunit/tests/_files/configuration.colors.true.xml deleted file mode 100644 index 1efe41325..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.colors.true.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.custom-printer.xml b/vendor/phpunit/phpunit/tests/_files/configuration.custom-printer.xml deleted file mode 100644 index 7a5a1f1d9..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.custom-printer.xml +++ /dev/null @@ -1,2 +0,0 @@ - - \ No newline at end of file diff --git a/vendor/phpunit/phpunit/tests/_files/configuration.xml b/vendor/phpunit/phpunit/tests/_files/configuration.xml deleted file mode 100644 index e83bfd3a5..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration.xml +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - /path/to/files - /path/to/MyTest.php - - - - - - name - - - name - - - - - - /path/to/files - /path/to/file - - /path/to/files - /path/to/file - - - - /path/to/files - /path/to/file - - /path/to/files - /path/to/file - - - - - - - - - - Sebastian - - - 22 - April - 19.78 - - - MyTestFile.php - MyRelativePath - - - - 42 - - - - - - - - - - - - - - - . - /path/to/lib - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration_empty.xml b/vendor/phpunit/phpunit/tests/_files/configuration_empty.xml deleted file mode 100644 index 13c8b71d5..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration_empty.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/phpunit/tests/_files/configuration_xinclude.xml b/vendor/phpunit/phpunit/tests/_files/configuration_xinclude.xml deleted file mode 100644 index 43076297d..000000000 --- a/vendor/phpunit/phpunit/tests/_files/configuration_xinclude.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - - - - - - - - - - - . - /path/to/lib - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/phpunit/tests/_files/expectedFileFormat.txt b/vendor/phpunit/phpunit/tests/_files/expectedFileFormat.txt deleted file mode 100644 index b7d6715e2..000000000 --- a/vendor/phpunit/phpunit/tests/_files/expectedFileFormat.txt +++ /dev/null @@ -1 +0,0 @@ -FOO diff --git a/vendor/phpunit/phpunit/tests/_files/foo.xml b/vendor/phpunit/phpunit/tests/_files/foo.xml deleted file mode 100644 index f1999f80c..000000000 --- a/vendor/phpunit/phpunit/tests/_files/foo.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/phpunit/phpunit/tests/_files/structureAttributesAreSameButValuesAreNot.xml b/vendor/phpunit/phpunit/tests/_files/structureAttributesAreSameButValuesAreNot.xml deleted file mode 100644 index a5d9ab335..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureAttributesAreSameButValuesAreNot.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - Image 1: Dette er en test caption - - - diff --git a/vendor/phpunit/phpunit/tests/_files/structureExpected.xml b/vendor/phpunit/phpunit/tests/_files/structureExpected.xml deleted file mode 100644 index d9001059e..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureExpected.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - Image 1: Dette er en test caption - - - diff --git a/vendor/phpunit/phpunit/tests/_files/structureIgnoreTextNodes.xml b/vendor/phpunit/phpunit/tests/_files/structureIgnoreTextNodes.xml deleted file mode 100644 index 0771b60ca..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureIgnoreTextNodes.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - textnode - - textnode - - textnode - Image 1: Dette er en test caption - textnode - - - diff --git a/vendor/phpunit/phpunit/tests/_files/structureIsSameButDataIsNot.xml b/vendor/phpunit/phpunit/tests/_files/structureIsSameButDataIsNot.xml deleted file mode 100644 index 2ba21b981..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureIsSameButDataIsNot.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - Image is not the same 1: Dette er en test caption - - - diff --git a/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfAttributes.xml b/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfAttributes.xml deleted file mode 100644 index af9b97416..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfAttributes.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - Image 1: Dette er en test caption - - - diff --git a/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfNodes.xml b/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfNodes.xml deleted file mode 100644 index 9a394e232..000000000 --- a/vendor/phpunit/phpunit/tests/_files/structureWrongNumberOfNodes.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/vendor/phpunit/phpunit/tests/bootstrap.php b/vendor/phpunit/phpunit/tests/bootstrap.php deleted file mode 100644 index cc79889b7..000000000 --- a/vendor/phpunit/phpunit/tests/bootstrap.php +++ /dev/null @@ -1,6 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\ArrayComparator - * - */ -class ArrayComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new ArrayComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsFailsProvider() - { - return array( - array(array(), null), - array(null, array()), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array( - array('a' => 1, 'b' => 2), - array('b' => 2, 'a' => 1) - ), - array( - array(1), - array('1') - ), - array( - array(3, 2, 1), - array(2, 3, 1), - 0, - true - ), - array( - array(2.3), - array(2.5), - 0.5 - ), - array( - array(array(2.3)), - array(array(2.5)), - 0.5 - ), - array( - array(new Struct(2.3)), - array(new Struct(2.5)), - 0.5 - ), - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array( - array(), - array(0 => 1) - ), - array( - array(0 => 1), - array() - ), - array( - array(0 => null), - array() - ), - array( - array(0 => 1, 1 => 2), - array(0 => 1, 1 => 3) - ), - array( - array('a', 'b' => array(1, 2)), - array('a', 'b' => array(2, 1)) - ), - array( - array(2.3), - array(4.2), - 0.5 - ), - array( - array(array(2.3)), - array(array(4.2)), - 0.5 - ), - array( - array(new Struct(2.3)), - array(new Struct(4.2)), - 0.5 - ) - ); - } - - /** - * @covers ::accepts - */ - public function testAcceptsSucceeds() - { - $this->assertTrue( - $this->comparator->accepts(array(), array()) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0, $canonicalize = false) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta, $canonicalize); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual,$delta = 0.0, $canonicalize = false) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', - 'Failed asserting that two arrays are equal' - ); - $this->comparator->assertEquals($expected, $actual, $delta, $canonicalize); - } -} diff --git a/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php b/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php deleted file mode 100644 index a769b84ca..000000000 --- a/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php +++ /dev/null @@ -1,162 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use DOMNode; -use DOMDocument; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\DOMNodeComparator - * - */ -class DOMNodeComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new DOMNodeComparator; - } - - public function acceptsSucceedsProvider() - { - $document = new DOMDocument; - $node = new DOMNode; - - return array( - array($document, $document), - array($node, $node), - array($document, $node), - array($node, $document) - ); - } - - public function acceptsFailsProvider() - { - $document = new DOMDocument; - - return array( - array($document, null), - array(null, $document), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument("\n \n"), - $this->createDOMDocument('') - ), - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(' bar '), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(''), - $this->createDOMDocument('') - ), - array( - $this->createDOMDocument(' bar '), - $this->createDOMDocument(' bir ') - ) - ); - } - - private function createDOMDocument($content) - { - $document = new DOMDocument; - $document->preserveWhiteSpace = false; - $document->loadXML($content); - - return $document; - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', - 'Failed asserting that two DOM' - ); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php b/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php deleted file mode 100644 index 9abcff761..000000000 --- a/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php +++ /dev/null @@ -1,216 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use DateTime; -use DateTimeImmutable; -use DateTimeZone; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\DateTimeComparator - * - */ -class DateTimeComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new DateTimeComparator; - } - - public function acceptsFailsProvider() - { - $datetime = new DateTime; - - return array( - array($datetime, null), - array(null, $datetime), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')) - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:25', new DateTimeZone('America/New_York')), - 10 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:14:40', new DateTimeZone('America/New_York')), - 65 - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29', new DateTimeZone('America/New_York')) - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/Chicago')) - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:49', new DateTimeZone('America/Chicago')), - 15 - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')) - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:01:30', new DateTimeZone('America/Chicago')), - 100 - ), - array( - new DateTime('@1364616000'), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')) - ), - array( - new DateTime('2013-03-29T05:13:35-0500'), - new DateTime('2013-03-29T04:13:35-0600') - ) - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')) - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')), - 3500 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 05:13:35', new DateTimeZone('America/New_York')), - 3500 - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')) - ), - array( - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - 43200 - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - ), - array( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - 3500 - ), - array( - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/Chicago')) - ), - array( - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T04:13:35-0600') - ), - array( - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T05:13:35-0500') - ), - ); - } - - /** - * @covers ::accepts - */ - public function testAcceptsSucceeds() - { - $this->assertTrue( - $this->comparator->accepts( - new DateTime, - new DateTime - ) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', - 'Failed asserting that two DateTime objects are equal.' - ); - $this->comparator->assertEquals($expected, $actual, $delta); - } - - /** - * @requires PHP 5.5 - * @covers ::accepts - */ - public function testAcceptsDateTimeInterface() - { - $this->assertTrue($this->comparator->accepts(new DateTime, new DateTimeImmutable)); - } - - /** - * @requires PHP 5.5 - * @covers ::assertEquals - */ - public function testSupportsDateTimeInterface() - { - $this->comparator->assertEquals( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTimeImmutable('2013-03-29 04:13:35', new DateTimeZone('America/New_York')) - ); - } -} diff --git a/vendor/sebastian/comparator/tests/DoubleComparatorTest.php b/vendor/sebastian/comparator/tests/DoubleComparatorTest.php deleted file mode 100644 index 6b898bab5..000000000 --- a/vendor/sebastian/comparator/tests/DoubleComparatorTest.php +++ /dev/null @@ -1,134 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\DoubleComparator - * - */ -class DoubleComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new DoubleComparator; - } - - public function acceptsSucceedsProvider() - { - return array( - array(0, 5.0), - array(5.0, 0), - array('5', 4.5), - array(1.2e3, 7E-10), - array(3, acos(8)), - array(acos(8), 3), - array(acos(8), acos(8)) - ); - } - - public function acceptsFailsProvider() - { - return array( - array(5, 5), - array('4.5', 5), - array(0x539, 02471), - array(5.0, false), - array(null, 5.0) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array(2.3, 2.3), - array('2.3', 2.3), - array(5.0, 5), - array(5, 5.0), - array(5.0, '5'), - array(1.2e3, 1200), - array(2.3, 2.5, 0.5), - array(3, 3.05, 0.05), - array(1.2e3, 1201, 1), - array((string)(1/3), 1 - 2/3), - array(1/3, (string)(1 - 2/3)) - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array(2.3, 4.2), - array('2.3', 4.2), - array(5.0, '4'), - array(5.0, 6), - array(1.2e3, 1201), - array(2.3, 2.5, 0.2), - array(3, 3.05, 0.04), - array(3, acos(8)), - array(acos(8), 3), - array(acos(8), acos(8)) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', 'matches expected' - ); - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php b/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php deleted file mode 100644 index fa8cc0a34..000000000 --- a/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php +++ /dev/null @@ -1,136 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use \Exception; -use \RuntimeException; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\ExceptionComparator - * - */ -class ExceptionComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new ExceptionComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - return array( - array(new Exception, new Exception), - array(new RuntimeException, new RuntimeException), - array(new Exception, new RuntimeException) - ); - } - - public function acceptsFailsProvider() - { - return array( - array(new Exception, null), - array(null, new Exception), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - $exception1 = new Exception; - $exception2 = new Exception; - - $exception3 = new RunTimeException('Error', 100); - $exception4 = new RunTimeException('Error', 100); - - return array( - array($exception1, $exception1), - array($exception1, $exception2), - array($exception3, $exception3), - array($exception3, $exception4) - ); - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - $exception1 = new Exception('Error', 100); - $exception2 = new Exception('Error', 101); - $exception3 = new Exception('Errors', 101); - - $exception4 = new RunTimeException('Error', 100); - $exception5 = new RunTimeException('Error', 101); - - return array( - array($exception1, $exception2, $equalMessage), - array($exception1, $exception3, $equalMessage), - array($exception1, $exception4, $typeMessage), - array($exception2, $exception3, $equalMessage), - array($exception4, $exception5, $equalMessage) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', $message - ); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/FactoryTest.php b/vendor/sebastian/comparator/tests/FactoryTest.php deleted file mode 100644 index cb58c20c7..000000000 --- a/vendor/sebastian/comparator/tests/FactoryTest.php +++ /dev/null @@ -1,115 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\Factory - * - */ -class FactoryTest extends \PHPUnit_Framework_TestCase -{ - public function instanceProvider() - { - $tmpfile = tmpfile(); - - return array( - array(NULL, NULL, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(NULL, TRUE, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(TRUE, NULL, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(TRUE, TRUE, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(FALSE, FALSE, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(TRUE, FALSE, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(FALSE, TRUE, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array('', '', 'SebastianBergmann\\Comparator\\ScalarComparator'), - array('0', '0', 'SebastianBergmann\\Comparator\\ScalarComparator'), - array('0', 0, 'SebastianBergmann\\Comparator\\NumericComparator'), - array(0, '0', 'SebastianBergmann\\Comparator\\NumericComparator'), - array(0, 0, 'SebastianBergmann\\Comparator\\NumericComparator'), - array(1.0, 0, 'SebastianBergmann\\Comparator\\DoubleComparator'), - array(0, 1.0, 'SebastianBergmann\\Comparator\\DoubleComparator'), - array(1.0, 1.0, 'SebastianBergmann\\Comparator\\DoubleComparator'), - array(array(1), array(1), 'SebastianBergmann\\Comparator\\ArrayComparator'), - array($tmpfile, $tmpfile, 'SebastianBergmann\\Comparator\\ResourceComparator'), - array(new \stdClass, new \stdClass, 'SebastianBergmann\\Comparator\\ObjectComparator'), - array(new \DateTime, new \DateTime, 'SebastianBergmann\\Comparator\\DateTimeComparator'), - array(new \SplObjectStorage, new \SplObjectStorage, 'SebastianBergmann\\Comparator\\SplObjectStorageComparator'), - array(new \Exception, new \Exception, 'SebastianBergmann\\Comparator\\ExceptionComparator'), - array(new \DOMDocument, new \DOMDocument, 'SebastianBergmann\\Comparator\\DOMNodeComparator'), - // mixed types - array($tmpfile, array(1), 'SebastianBergmann\\Comparator\\TypeComparator'), - array(array(1), $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'), - array($tmpfile, '1', 'SebastianBergmann\\Comparator\\TypeComparator'), - array('1', $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'), - array($tmpfile, new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(new \stdClass, $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(new \stdClass, array(1), 'SebastianBergmann\\Comparator\\TypeComparator'), - array(array(1), new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(new \stdClass, '1', 'SebastianBergmann\\Comparator\\TypeComparator'), - array('1', new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(new ClassWithToString, '1', 'SebastianBergmann\\Comparator\\ScalarComparator'), - array('1', new ClassWithToString, 'SebastianBergmann\\Comparator\\ScalarComparator'), - array(1.0, new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(new \stdClass, 1.0, 'SebastianBergmann\\Comparator\\TypeComparator'), - array(1.0, array(1), 'SebastianBergmann\\Comparator\\TypeComparator'), - array(array(1), 1.0, 'SebastianBergmann\\Comparator\\TypeComparator'), - ); - } - - /** - * @dataProvider instanceProvider - * @covers ::getComparatorFor - * @covers ::__construct - */ - public function testGetComparatorFor($a, $b, $expected) - { - $factory = new Factory; - $actual = $factory->getComparatorFor($a, $b); - $this->assertInstanceOf($expected, $actual); - } - - /** - * @covers ::register - */ - public function testRegister() - { - $comparator = new TestClassComparator; - - $factory = new Factory; - $factory->register($comparator); - - $a = new TestClass; - $b = new TestClass; - $expected = 'SebastianBergmann\\Comparator\\TestClassComparator'; - $actual = $factory->getComparatorFor($a, $b); - - $factory->unregister($comparator); - $this->assertInstanceOf($expected, $actual); - } - - /** - * @covers ::unregister - */ - public function testUnregister() - { - $comparator = new TestClassComparator; - - $factory = new Factory; - $factory->register($comparator); - $factory->unregister($comparator); - - $a = new TestClass; - $b = new TestClass; - $expected = 'SebastianBergmann\\Comparator\\ObjectComparator'; - $actual = $factory->getComparatorFor($a, $b); - - $this->assertInstanceOf($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php b/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php deleted file mode 100644 index 7910ad7a4..000000000 --- a/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php +++ /dev/null @@ -1,166 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\MockObjectComparator - * - */ -class MockObjectComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new MockObjectComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - $testmock = $this->getMock('SebastianBergmann\\Comparator\\TestClass'); - $stdmock = $this->getMock('stdClass'); - - return array( - array($testmock, $testmock), - array($stdmock, $stdmock), - array($stdmock, $testmock) - ); - } - - public function acceptsFailsProvider() - { - $stdmock = $this->getMock('stdClass'); - - return array( - array($stdmock, null), - array(null, $stdmock), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - // cyclic dependencies - $book1 = $this->getMock('SebastianBergmann\\Comparator\\Book', null); - $book1->author = $this->getMock('SebastianBergmann\\Comparator\\Author', null, array('Terry Pratchett')); - $book1->author->books[] = $book1; - $book2 = $this->getMock('SebastianBergmann\\Comparator\\Book', null); - $book2->author = $this->getMock('SebastianBergmann\\Comparator\\Author', null, array('Terry Pratchett')); - $book2->author->books[] = $book2; - - $object1 = $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(4, 8, 15)); - $object2 = $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(4, 8, 15)); - - return array( - array($object1, $object1), - array($object1, $object2), - array($book1, $book1), - array($book1, $book2), - array( - $this->getMock('SebastianBergmann\\Comparator\\Struct', null, array(2.3)), - $this->getMock('SebastianBergmann\\Comparator\\Struct', null, array(2.5)), - 0.5 - ) - ); - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'is not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - // cyclic dependencies - $book1 = $this->getMock('SebastianBergmann\\Comparator\\Book', null); - $book1->author = $this->getMock('SebastianBergmann\\Comparator\\Author', null, array('Terry Pratchett')); - $book1->author->books[] = $book1; - $book2 = $this->getMock('SebastianBergmann\\Comparator\\Book', null); - $book2->author = $this->getMock('SebastianBergmann\\Comparator\\Author', null, array('Terry Pratch')); - $book2->author->books[] = $book2; - - $book3 = $this->getMock('SebastianBergmann\\Comparator\\Book', null); - $book3->author = 'Terry Pratchett'; - $book4 = $this->getMock('stdClass'); - $book4->author = 'Terry Pratchett'; - - $object1 = $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(4, 8, 15)); - $object2 = $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(16, 23, 42)); - - return array( - array( - $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(4, 8, 15)), - $this->getMock('SebastianBergmann\\Comparator\\SampleClass', null, array(16, 23, 42)), - $equalMessage - ), - array($object1, $object2, $equalMessage), - array($book1, $book2, $equalMessage), - array($book3, $book4, $typeMessage), - array( - $this->getMock('SebastianBergmann\\Comparator\\Struct', null, array(2.3)), - $this->getMock('SebastianBergmann\\Comparator\\Struct', null, array(4.2)), - $equalMessage, - 0.5 - ) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message, $delta = 0.0) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', $message - ); - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/NumericComparatorTest.php b/vendor/sebastian/comparator/tests/NumericComparatorTest.php deleted file mode 100644 index fec7d00ad..000000000 --- a/vendor/sebastian/comparator/tests/NumericComparatorTest.php +++ /dev/null @@ -1,122 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\NumericComparator - * - */ -class NumericComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new NumericComparator; - } - - public function acceptsSucceedsProvider() - { - return array( - array(5, 10), - array(8, '0'), - array('10', 0), - array(0x74c3b00c, 42), - array(0755, 0777) - ); - } - - public function acceptsFailsProvider() - { - return array( - array('5', '10'), - array(8, 5.0), - array(5.0, 8), - array(10, null), - array(false, 12) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array(1337, 1337), - array('1337', 1337), - array(0x539, 1337), - array(02471, 1337), - array(1337, 1338, 1), - array('1337', 1340, 5), - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array(1337, 1338), - array('1338', 1337), - array(0x539, 1338), - array(1337, 1339, 1), - array('1337', 1340, 2), - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', 'matches expected' - ); - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ObjectComparatorTest.php b/vendor/sebastian/comparator/tests/ObjectComparatorTest.php deleted file mode 100644 index a95823253..000000000 --- a/vendor/sebastian/comparator/tests/ObjectComparatorTest.php +++ /dev/null @@ -1,150 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use stdClass; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\ObjectComparator - * - */ -class ObjectComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new ObjectComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - return array( - array(new TestClass, new TestClass), - array(new stdClass, new stdClass), - array(new stdClass, new TestClass) - ); - } - - public function acceptsFailsProvider() - { - return array( - array(new stdClass, null), - array(null, new stdClass), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratchett'); - $book2->author->books[] = $book2; - - $object1 = new SampleClass(4, 8, 15); - $object2 = new SampleClass(4, 8, 15); - - return array( - array($object1, $object1), - array($object1, $object2), - array($book1, $book1), - array($book1, $book2), - array(new Struct(2.3), new Struct(2.5), 0.5) - ); - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'is not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratch'); - $book2->author->books[] = $book2; - - $book3 = new Book; - $book3->author = 'Terry Pratchett'; - $book4 = new stdClass; - $book4->author = 'Terry Pratchett'; - - $object1 = new SampleClass( 4, 8, 15); - $object2 = new SampleClass(16, 23, 42); - - return array( - array(new SampleClass(4, 8, 15), new SampleClass(16, 23, 42), $equalMessage), - array($object1, $object2, $equalMessage), - array($book1, $book2, $equalMessage), - array($book3, $book4, $typeMessage), - array(new Struct(2.3), new Struct(4.2), $equalMessage, 0.5) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message, $delta = 0.0) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', $message - ); - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ResourceComparatorTest.php b/vendor/sebastian/comparator/tests/ResourceComparatorTest.php deleted file mode 100644 index a9e9e9552..000000000 --- a/vendor/sebastian/comparator/tests/ResourceComparatorTest.php +++ /dev/null @@ -1,120 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\ResourceComparator - * - */ -class ResourceComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new ResourceComparator; - } - - public function acceptsSucceedsProvider() - { - $tmpfile1 = tmpfile(); - $tmpfile2 = tmpfile(); - - return array( - array($tmpfile1, $tmpfile1), - array($tmpfile2, $tmpfile2), - array($tmpfile1, $tmpfile2) - ); - } - - public function acceptsFailsProvider() - { - $tmpfile1 = tmpfile(); - - return array( - array($tmpfile1, null), - array(null, $tmpfile1), - array(null, null) - ); - } - - public function assertEqualsSucceedsProvider() - { - $tmpfile1 = tmpfile(); - $tmpfile2 = tmpfile(); - - return array( - array($tmpfile1, $tmpfile1), - array($tmpfile2, $tmpfile2) - ); - } - - public function assertEqualsFailsProvider() - { - $tmpfile1 = tmpfile(); - $tmpfile2 = tmpfile(); - - return array( - array($tmpfile1, $tmpfile2), - array($tmpfile2, $tmpfile1) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual) - { - $this->setExpectedException('SebastianBergmann\\Comparator\\ComparisonFailure'); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/ScalarComparatorTest.php b/vendor/sebastian/comparator/tests/ScalarComparatorTest.php deleted file mode 100644 index e5156aa39..000000000 --- a/vendor/sebastian/comparator/tests/ScalarComparatorTest.php +++ /dev/null @@ -1,158 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\ScalarComparator - * - */ -class ScalarComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new ScalarComparator; - } - - public function acceptsSucceedsProvider() - { - return array( - array("string", "string"), - array(new ClassWithToString, "string"), - array("string", new ClassWithToString), - array("string", null), - array(false, "string"), - array(false, true), - array(null, false), - array(null, null), - array("10", 10), - array("", false), - array("1", true), - array(1, true), - array(0, false), - array(0.1, "0.1") - ); - } - - public function acceptsFailsProvider() - { - return array( - array(array(), array()), - array("string", array()), - array(new ClassWithToString, new ClassWithToString), - array(false, new ClassWithToString), - array(tmpfile(), tmpfile()) - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array("string", "string"), - array(new ClassWithToString, new ClassWithToString), - array("string representation", new ClassWithToString), - array(new ClassWithToString, "string representation"), - array("string", "STRING", true), - array("STRING", "string", true), - array("String Representation", new ClassWithToString, true), - array(new ClassWithToString, "String Representation", true), - array("10", 10), - array("", false), - array("1", true), - array(1, true), - array(0, false), - array(0.1, "0.1"), - array(false, null), - array(false, false), - array(true, true), - array(null, null) - ); - } - - public function assertEqualsFailsProvider() - { - $stringException = 'Failed asserting that two strings are equal.'; - $otherException = 'matches expected'; - - return array( - array("string", "other string", $stringException), - array("string", "STRING", $stringException), - array("STRING", "string", $stringException), - array("string", "other string", $stringException), - // https://github.com/sebastianbergmann/phpunit/issues/1023 - array('9E6666666','9E7777777', $stringException), - array(new ClassWithToString, "does not match", $otherException), - array("does not match", new ClassWithToString, $otherException), - array(0, 'Foobar', $otherException), - array('Foobar', 0, $otherException), - array("10", 25, $otherException), - array("1", false, $otherException), - array("", true, $otherException), - array(false, true, $otherException), - array(true, false, $otherException), - array(null, true, $otherException), - array(0, true, $otherException) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $ignoreCase = false) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, 0.0, false, $ignoreCase); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', $message - ); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php b/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php deleted file mode 100644 index 766dd2df3..000000000 --- a/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php +++ /dev/null @@ -1,137 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use SplObjectStorage; -use stdClass; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\SplObjectStorageComparator - * - */ -class SplObjectStorageComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new SplObjectStorageComparator; - } - - public function acceptsFailsProvider() - { - return array( - array(new SplObjectStorage, new stdClass), - array(new stdClass, new SplObjectStorage), - array(new stdClass, new stdClass) - ); - } - - public function assertEqualsSucceedsProvider() - { - $object1 = new stdClass(); - $object2 = new stdClass(); - - $storage1 = new SplObjectStorage(); - $storage2 = new SplObjectStorage(); - - $storage3 = new SplObjectStorage(); - $storage3->attach($object1); - $storage3->attach($object2); - - $storage4 = new SplObjectStorage(); - $storage4->attach($object2); - $storage4->attach($object1); - - return array( - array($storage1, $storage1), - array($storage1, $storage2), - array($storage3, $storage3), - array($storage3, $storage4) - ); - } - - public function assertEqualsFailsProvider() - { - $object1 = new stdClass; - $object2 = new stdClass; - - $storage1 = new SplObjectStorage; - - $storage2 = new SplObjectStorage; - $storage2->attach($object1); - - $storage3 = new SplObjectStorage; - $storage3->attach($object2); - $storage3->attach($object1); - - return array( - array($storage1, $storage2), - array($storage1, $storage3), - array($storage2, $storage3), - ); - } - - /** - * @covers ::accepts - */ - public function testAcceptsSucceeds() - { - $this->assertTrue( - $this->comparator->accepts( - new SplObjectStorage, - new SplObjectStorage - ) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual) - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual) - { - $this->setExpectedException( - 'SebastianBergmann\\Comparator\\ComparisonFailure', - 'Failed asserting that two objects are equal.' - ); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/TypeComparatorTest.php b/vendor/sebastian/comparator/tests/TypeComparatorTest.php deleted file mode 100644 index bb51f8a14..000000000 --- a/vendor/sebastian/comparator/tests/TypeComparatorTest.php +++ /dev/null @@ -1,104 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -use stdClass; - -/** - * @coversDefaultClass SebastianBergmann\Comparator\TypeComparator - * - */ -class TypeComparatorTest extends \PHPUnit_Framework_TestCase -{ - private $comparator; - - protected function setUp() - { - $this->comparator = new TypeComparator; - } - - public function acceptsSucceedsProvider() - { - return array( - array(true, 1), - array(false, array(1)), - array(null, new stdClass), - array(1.0, 5), - array("", "") - ); - } - - public function assertEqualsSucceedsProvider() - { - return array( - array(true, true), - array(true, false), - array(false, false), - array(null, null), - array(new stdClass, new stdClass), - array(0, 0), - array(1.0, 2.0), - array("hello", "world"), - array("", ""), - array(array(), array(1,2,3)) - ); - } - - public function assertEqualsFailsProvider() - { - return array( - array(true, null), - array(null, false), - array(1.0, 0), - array(new stdClass, array()), - array("1", 1) - ); - } - - /** - * @covers ::accepts - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual) - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual) - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } - - catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @covers ::assertEquals - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual) - { - $this->setExpectedException('SebastianBergmann\\Comparator\\ComparisonFailure', 'does not match expected type'); - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/_files/Author.php b/vendor/sebastian/comparator/tests/_files/Author.php deleted file mode 100644 index ae698c3c0..000000000 --- a/vendor/sebastian/comparator/tests/_files/Author.php +++ /dev/null @@ -1,28 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * An author. - * - */ -class Author -{ - // the order of properties is important for testing the cycle! - public $books = array(); - - private $name = ''; - - public function __construct($name) - { - $this->name = $name; - } -} diff --git a/vendor/sebastian/comparator/tests/_files/Book.php b/vendor/sebastian/comparator/tests/_files/Book.php deleted file mode 100644 index 6171bc33e..000000000 --- a/vendor/sebastian/comparator/tests/_files/Book.php +++ /dev/null @@ -1,21 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * A book. - * - */ -class Book -{ - // the order of properties is important for testing the cycle! - public $author = null; -} diff --git a/vendor/sebastian/comparator/tests/_files/ClassWithToString.php b/vendor/sebastian/comparator/tests/_files/ClassWithToString.php deleted file mode 100644 index e8e03bc7f..000000000 --- a/vendor/sebastian/comparator/tests/_files/ClassWithToString.php +++ /dev/null @@ -1,19 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -class ClassWithToString -{ - public function __toString() - { - return 'string representation'; - } -} diff --git a/vendor/sebastian/comparator/tests/_files/SampleClass.php b/vendor/sebastian/comparator/tests/_files/SampleClass.php deleted file mode 100644 index 6079dd343..000000000 --- a/vendor/sebastian/comparator/tests/_files/SampleClass.php +++ /dev/null @@ -1,29 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * A sample class. - * - */ -class SampleClass -{ - public $a; - protected $b; - protected $c; - - public function __construct($a, $b, $c) - { - $this->a = $a; - $this->b = $b; - $this->c = $c; - } -} diff --git a/vendor/sebastian/comparator/tests/_files/Struct.php b/vendor/sebastian/comparator/tests/_files/Struct.php deleted file mode 100644 index 79ec559a8..000000000 --- a/vendor/sebastian/comparator/tests/_files/Struct.php +++ /dev/null @@ -1,25 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -/** - * A struct. - * - */ -class Struct -{ - public $var; - - public function __construct($var) - { - $this->var = $var; - } -} diff --git a/vendor/sebastian/comparator/tests/_files/TestClass.php b/vendor/sebastian/comparator/tests/_files/TestClass.php deleted file mode 100644 index e4c9b78ca..000000000 --- a/vendor/sebastian/comparator/tests/_files/TestClass.php +++ /dev/null @@ -1,14 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -class TestClass { -} diff --git a/vendor/sebastian/comparator/tests/_files/TestClassComparator.php b/vendor/sebastian/comparator/tests/_files/TestClassComparator.php deleted file mode 100644 index 52aac3fdf..000000000 --- a/vendor/sebastian/comparator/tests/_files/TestClassComparator.php +++ /dev/null @@ -1,14 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Comparator; - -class TestClassComparator extends ObjectComparator { -} diff --git a/vendor/sebastian/comparator/tests/autoload.php b/vendor/sebastian/comparator/tests/autoload.php deleted file mode 100644 index f4d9bbcc8..000000000 --- a/vendor/sebastian/comparator/tests/autoload.php +++ /dev/null @@ -1,38 +0,0 @@ - '/ArrayComparatorTest.php', - 'sebastianbergmann\\comparator\\author' => '/_files/Author.php', - 'sebastianbergmann\\comparator\\book' => '/_files/Book.php', - 'sebastianbergmann\\comparator\\classwithtostring' => '/_files/ClassWithToString.php', - 'sebastianbergmann\\comparator\\datetimecomparatortest' => '/DateTimeComparatorTest.php', - 'sebastianbergmann\\comparator\\domnodecomparatortest' => '/DOMNodeComparatorTest.php', - 'sebastianbergmann\\comparator\\doublecomparatortest' => '/DoubleComparatorTest.php', - 'sebastianbergmann\\comparator\\exceptioncomparatortest' => '/ExceptionComparatorTest.php', - 'sebastianbergmann\\comparator\\factorytest' => '/FactoryTest.php', - 'sebastianbergmann\\comparator\\mockobjectcomparatortest' => '/MockObjectComparatorTest.php', - 'sebastianbergmann\\comparator\\numericcomparatortest' => '/NumericComparatorTest.php', - 'sebastianbergmann\\comparator\\objectcomparatortest' => '/ObjectComparatorTest.php', - 'sebastianbergmann\\comparator\\resourcecomparatortest' => '/ResourceComparatorTest.php', - 'sebastianbergmann\\comparator\\sampleclass' => '/_files/SampleClass.php', - 'sebastianbergmann\\comparator\\scalarcomparatortest' => '/ScalarComparatorTest.php', - 'sebastianbergmann\\comparator\\splobjectstoragecomparatortest' => '/SplObjectStorageComparatorTest.php', - 'sebastianbergmann\\comparator\\struct' => '/_files/Struct.php', - 'sebastianbergmann\\comparator\\testclass' => '/_files/TestClass.php', - 'sebastianbergmann\\comparator\\testclasscomparator' => '/_files/TestClassComparator.php', - 'sebastianbergmann\\comparator\\typecomparatortest' => '/TypeComparatorTest.php' - ); - } - $cn = strtolower($class); - if (isset($classes[$cn])) { - require __DIR__ . $classes[$cn]; - } - } -); -// @codeCoverageIgnoreEnd diff --git a/vendor/sebastian/comparator/tests/bootstrap.php b/vendor/sebastian/comparator/tests/bootstrap.php deleted file mode 100644 index 8f1c57c32..000000000 --- a/vendor/sebastian/comparator/tests/bootstrap.php +++ /dev/null @@ -1,7 +0,0 @@ -?K$Qo3odsxhVhrW_E33 zgN<ec|!-+j4e8k9=IUK@( z{+&LsL!d z%)yK^gFKmh1k_-HYtI~=fg(eoK2j8mPM8aZusL)ec^{2zE6NNM-h8^b2jt&AIzazq zJKw+cn9DB#OIv&o?2a(^uP^WVU)aQUo;$;#shiB=pC@3$1YU$isoXtt!V-BEeN0_f z1cNyUh_D}=S%$j;ukxZ0cy!wW^4rdr?jM~i@*AnQL&FzWS7J~N4|cDSt_BW4{-Xnk zIX(yE{E<2y25;y{{7xP7k#a_M4e%p#JjSVGbEachhBHgYs1ld)`)O%kFiCVMco!p9 zeJ`0ovjri?h@d3={<;hVGL%jTbsYK({Ore6DDps&bNLzb!g?UPL&u&ZeByTS!JwSp zIQFAyFh@%E{}qtv_9Js#gal7QB1qtxhSv1#3q+WS9}{UsDtNLyzt09RcjoTpkQhSa zEt@*b^;54qL{OL1`oL}>XPCo`dlx(tQFE=k(S$8Y?*`7TNJqjCw-X`=Dast)`Ey3c zZYj(d4zLWg=bDlTj*wXqagSh%0@~kCNe4gPn@T{~s zE@v*cC!ZLFqABXf7k1NA)h)ISDo8Es9jPUbPis>6RDQL zM{F&M5#IB2a(>>os zo!*FAqJOxsj62ah38QZiX^h#js;@AkTCI{U^!cVm#{j-uCSTc8-|`JoVXVGv&~md- zQY)k$XHo&1(*ky;(T)!T5*}YF5P~Pt@gYl4;>G86y1g6fK+B_Ppx$Mu@klAe`B>7G zM6jTO`W?!?Qg~4cgNvoVLn@+hkB1*MdODFrk!Q3&LNDk%bJ3tk(& z2v7LNw|ptL9mZ#lCHvu0B=H1abO`e;VR-&Yq^QfrLrwEGCHv8gMpAsFBuM58>>H3= zY*yxJAgLh3m)TKA1T4~mq{!F;Ujp!iVHD^C#5tG6AU&YZV9_AnBz-$J(Ye>x3X(pj z&tMa3iG)Oi31meEHx(y3m^*$gqo^@w$Yd3;MJy0zp|r^8=IjdcX+5(-e#m52tW_Xv zD^`U-Zqq7M6TvTIwJoc%=ingZh)mH+Fl>vK83xOoi6NG3)(K^?kpq#D@p;8a>xJf< z{GYFb#gyhJzMGTT7nhQ6S`^bj3&?bEhrF#!qyqtO zlwqxo_lcOlk?fKP-?p}=gF!5VL@aS`L4*;2>y?=_C z0nK(i18`t1lHS4Jh5ecDi45!2+?DeMYiU;z-mk!FCHE1q7cuGB{EHdipgDzo!`azc zr+ckXP1RmZt=8^p^%JeQVryK~8rqAiH5yuRX9d{~9t9TLt_ITVv2nKIz;jXLLHZ>LCAJ>wRgvf8H z^}vv)fhMo;l;nXUcV9sRU?;gXAP&SIqxe({#-_!DbB+V&B!~DKh>Kc1EyPH+!{J;Y z0NzRlE{Nfl3GSmr5`gwPJgTY|+pp-@l}Yy&M8fac5CIx|1fqKG5H)g!=+%$g#-~~H z4bx1mWtnF!B+fL?PP5H3b)B{J7o_$76Ky!`$1Fy2=F6#{gNX*ISyt6L{E?83b2j%) zt@-N_fs?A?xV7>J=_DVJu++jM3ft+ghvXH1AJMzqA%bF(hkir^O@s|=t>{QLUTf8p zHxyee(ChcK*^8~ - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\LCS; - -use PHPUnit_Framework_TestCase; - -/** - * Some of these tests are volontary stressfull, in order to give some approximative benchmark hints. - */ -class TimeEfficientImplementationTest extends PHPUnit_Framework_TestCase -{ - private $implementation; - private $memory_limit; - private $stress_sizes = array(1, 2, 3, 100, 500, 1000, 2000); - - protected function setUp() - { - $this->memory_limit = ini_get('memory_limit'); - ini_set('memory_limit', '256M'); - - $this->implementation = new TimeEfficientImplementation; - } - - protected function tearDown() - { - ini_set('memory_limit', $this->memory_limit); - } - - public function testBothEmpty() - { - $from = array(); - $to = array(); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals(array(), $common); - } - - public function testIsStrictComparison() - { - $from = array( - false, 0, 0.0, '', null, array(), - true, 1, 1.0, 'foo', array('foo', 'bar'), array('foo' => 'bar') - ); - $to = $from; - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($from, $common); - - $to = array( - false, false, false, false, false, false, - true, true, true, true, true, true - ); - $expected = array( - false, - true, - ); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($expected, $common); - } - - public function testEqualSequences() - { - foreach ($this->stress_sizes as $size) { - $range = range(1, $size); - $from = $range; - $to = $range; - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($range, $common); - } - } - - public function testDistinctSequences() - { - $from = array('A'); - $to = array('B'); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals(array(), $common); - - $from = array('A', 'B', 'C'); - $to = array('D', 'E', 'F'); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals(array(), $common); - - foreach ($this->stress_sizes as $size) { - $from = range(1, $size); - $to = range($size + 1, $size * 2); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals(array(), $common); - } - } - - public function testCommonSubsequence() - { - $from = array('A', 'C', 'E', 'F', 'G' ); - $to = array('A', 'B', 'D', 'E', 'H'); - $expected = array('A', 'E' ); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals($expected, $common); - - $from = array('A', 'C', 'E', 'F', 'G' ); - $to = array( 'B', 'C', 'D', 'E', 'F', 'H'); - $expected = array('C', 'E', 'F' ); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals($expected, $common); - - foreach ($this->stress_sizes as $size) { - $from = $size < 2 ? array(1) : range(1, $size + 1, 2); - $to = $size < 3 ? array(1) : range(1, $size + 1, 3); - $expected = $size < 6 ? array(1) : range(1, $size + 1, 6); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($expected, $common); - } - } - - public function testSingleElementSubsequenceAtStart() - { - foreach ($this->stress_sizes as $size) { - $from = range(1, $size); - $to = array_slice($from, 0, 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($to, $common); - } - } - - public function testSingleElementSubsequenceAtMiddle() - { - foreach ($this->stress_sizes as $size) { - $from = range(1, $size); - $to = array_slice($from, (int) $size / 2, 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($to, $common); - } - } - - public function testSingleElementSubsequenceAtEnd() - { - foreach ($this->stress_sizes as $size) { - $from = range(1, $size); - $to = array_slice($from, $size - 1, 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals($to, $common); - } - } - - public function testReversedSequences() - { - $from = array('A', 'B'); - $to = array('B', 'A'); - $expected = array('A'); - $common = $this->implementation->calculate($from, $to); - $this->assertEquals($expected, $common); - - foreach ($this->stress_sizes as $size) { - $from = range(1, $size); - $to = array_reverse($from); - $common = $this->implementation->calculate($from, $to); - - $this->assertEquals(array(1), $common); - } - } -} diff --git a/vendor/sebastian/diff/tests/ParserTest.php b/vendor/sebastian/diff/tests/ParserTest.php deleted file mode 100644 index 3a7b97204..000000000 --- a/vendor/sebastian/diff/tests/ParserTest.php +++ /dev/null @@ -1,62 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit_Framework_TestCase; - -class ParserTest extends PHPUnit_Framework_TestCase -{ - /** - * @var Parser - */ - private $parser; - - protected function setUp() - { - $this->parser = new Parser; - } - - public function testParse() - { - $content = file_get_contents(__DIR__ . '/fixtures/patch.txt'); - - $diffs = $this->parser->parse($content); - - $this->assertCount(1, $diffs); - - $chunks = $diffs[0]->getChunks(); - $this->assertCount(1, $chunks); - - $this->assertEquals(20, $chunks[0]->getStart()); - - $this->assertCount(5, $chunks[0]->getLines()); - } - - public function testParseWithMultipleChunks() - { - $content = file_get_contents(__DIR__ . '/fixtures/patch2.txt'); - - $diffs = $this->parser->parse($content); - - $this->assertCount(1, $diffs); - - $chunks = $diffs[0]->getChunks(); - $this->assertCount(3, $chunks); - - $this->assertEquals(20, $chunks[0]->getStart()); - $this->assertEquals(320, $chunks[1]->getStart()); - $this->assertEquals(600, $chunks[2]->getStart()); - - $this->assertCount(5, $chunks[0]->getLines()); - $this->assertCount(5, $chunks[1]->getLines()); - $this->assertCount(5, $chunks[2]->getLines()); - } -} diff --git a/vendor/sebastian/diff/tests/fixtures/patch.txt b/vendor/sebastian/diff/tests/fixtures/patch.txt deleted file mode 100644 index 144b61d01..000000000 --- a/vendor/sebastian/diff/tests/fixtures/patch.txt +++ /dev/null @@ -1,9 +0,0 @@ -diff --git a/Foo.php b/Foo.php -index abcdefg..abcdefh 100644 ---- a/Foo.php -+++ b/Foo.php -@@ -20,4 +20,5 @@ class Foo - const ONE = 1; - const TWO = 2; -+ const THREE = 3; - const FOUR = 4; diff --git a/vendor/sebastian/diff/tests/fixtures/patch2.txt b/vendor/sebastian/diff/tests/fixtures/patch2.txt deleted file mode 100644 index 41fbc9597..000000000 --- a/vendor/sebastian/diff/tests/fixtures/patch2.txt +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/Foo.php b/Foo.php -index abcdefg..abcdefh 100644 ---- a/Foo.php -+++ b/Foo.php -@@ -20,4 +20,5 @@ class Foo - const ONE = 1; - const TWO = 2; -+ const THREE = 3; - const FOUR = 4; - -@@ -320,4 +320,5 @@ class Foo - const A = 'A'; - const B = 'B'; -+ const C = 'C'; - const D = 'D'; - -@@ -600,4 +600,5 @@ class Foo - public function doSomething() { - -+ return 'foo'; - } diff --git a/vendor/sebastian/environment/tests/ConsoleTest.php b/vendor/sebastian/environment/tests/ConsoleTest.php deleted file mode 100644 index 6b40172b0..000000000 --- a/vendor/sebastian/environment/tests/ConsoleTest.php +++ /dev/null @@ -1,60 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Environment; - -use PHPUnit_Framework_TestCase; - -class ConsoleTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \SebastianBergmann\Environment\Console - */ - private $console; - - protected function setUp() - { - $this->console = new Console; - } - - /** - * @covers \SebastianBergmann\Environment\Console::isInteractive - */ - public function testCanDetectIfStdoutIsInteractiveByDefault() - { - $this->assertInternalType('boolean', $this->console->isInteractive()); - } - - /** - * @covers \SebastianBergmann\Environment\Console::isInteractive - */ - public function testCanDetectIfFileDescriptorIsInteractive() - { - $this->assertInternalType('boolean', $this->console->isInteractive(STDOUT)); - } - - /** - * @covers \SebastianBergmann\Environment\Console::hasColorSupport - * @uses \SebastianBergmann\Environment\Console::isInteractive - */ - public function testCanDetectColorSupport() - { - $this->assertInternalType('boolean', $this->console->hasColorSupport()); - } - - /** - * @covers \SebastianBergmann\Environment\Console::getNumberOfColumns - * @uses \SebastianBergmann\Environment\Console::isInteractive - */ - public function testCanDetectNumberOfColumns() - { - $this->assertInternalType('integer', $this->console->getNumberOfColumns()); - } -} diff --git a/vendor/sebastian/environment/tests/RuntimeTest.php b/vendor/sebastian/environment/tests/RuntimeTest.php deleted file mode 100644 index 8ea837305..000000000 --- a/vendor/sebastian/environment/tests/RuntimeTest.php +++ /dev/null @@ -1,112 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Environment; - -use PHPUnit_Framework_TestCase; - -class RuntimeTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \SebastianBergmann\Environment\Runtime - */ - private $env; - - protected function setUp() - { - $this->env = new Runtime; - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::canCollectCodeCoverage - * @uses \SebastianBergmann\Environment\Runtime::hasXdebug - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - * @uses \SebastianBergmann\Environment\Runtime::isPHP - */ - public function testAbilityToCollectCodeCoverageCanBeAssessed() - { - $this->assertInternalType('boolean', $this->env->canCollectCodeCoverage()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::getBinary - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testBinaryCanBeRetrieved() - { - $this->assertInternalType('string', $this->env->getBinary()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testCanBeDetected() - { - $this->assertInternalType('boolean', $this->env->isHHVM()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::isPHP - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testCanBeDetected2() - { - $this->assertInternalType('boolean', $this->env->isPHP()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::hasXdebug - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - * @uses \SebastianBergmann\Environment\Runtime::isPHP - */ - public function testXdebugCanBeDetected() - { - $this->assertInternalType('boolean', $this->env->hasXdebug()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::getNameWithVersion - * @uses \SebastianBergmann\Environment\Runtime::getName - * @uses \SebastianBergmann\Environment\Runtime::getVersion - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - * @uses \SebastianBergmann\Environment\Runtime::isPHP - */ - public function testNameAndVersionCanBeRetrieved() - { - $this->assertInternalType('string', $this->env->getNameWithVersion()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::getName - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testNameCanBeRetrieved() - { - $this->assertInternalType('string', $this->env->getName()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::getVersion - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testVersionCanBeRetrieved() - { - $this->assertInternalType('string', $this->env->getVersion()); - } - - /** - * @covers \SebastianBergmann\Environment\Runtime::getVendorUrl - * @uses \SebastianBergmann\Environment\Runtime::isHHVM - */ - public function testVendorUrlCanBeRetrieved() - { - $this->assertInternalType('string', $this->env->getVendorUrl()); - } -} diff --git a/vendor/sebastian/exporter/tests/ExporterTest.php b/vendor/sebastian/exporter/tests/ExporterTest.php deleted file mode 100644 index 6b590bfb3..000000000 --- a/vendor/sebastian/exporter/tests/ExporterTest.php +++ /dev/null @@ -1,333 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Exporter; - -/** - * @covers SebastianBergmann\Exporter\Exporter - */ -class ExporterTest extends \PHPUnit_Framework_TestCase -{ - /** - * @var Exporter - */ - private $exporter; - - protected function setUp() - { - $this->exporter = new Exporter; - } - - public function exportProvider() - { - $obj2 = new \stdClass; - $obj2->foo = 'bar'; - - $obj3 = (object)array(1,2,"Test\r\n",4,5,6,7,8); - - $obj = new \stdClass; - //@codingStandardsIgnoreStart - $obj->null = null; - //@codingStandardsIgnoreEnd - $obj->boolean = true; - $obj->integer = 1; - $obj->double = 1.2; - $obj->string = '1'; - $obj->text = "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"; - $obj->object = $obj2; - $obj->objectagain = $obj2; - $obj->array = array('foo' => 'bar'); - $obj->self = $obj; - - $storage = new \SplObjectStorage; - $storage->attach($obj2); - $storage->foo = $obj2; - - return array( - array(null, 'null'), - array(true, 'true'), - array(false, 'false'), - array(1, '1'), - array(1.0, '1.0'), - array(1.2, '1.2'), - array(fopen('php://memory', 'r'), 'resource(%d) of type (stream)'), - array('1', "'1'"), - array(array(array(1,2,3), array(3,4,5)), - << Array &1 ( - 0 => 1 - 1 => 2 - 2 => 3 - ) - 1 => Array &2 ( - 0 => 3 - 1 => 4 - 2 => 5 - ) -) -EOF - ), - // \n\r and \r is converted to \n - array("this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", - << null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this -is -a -very -very -very -very -very -very -long -text' - 'object' => stdClass Object &%x ( - 'foo' => 'bar' - ) - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => stdClass Object &%x -) -EOF - ), - array(array(), 'Array &%d ()'), - array($storage, - << stdClass Object &%x ( - 'foo' => 'bar' - ) - '%x' => Array &0 ( - 'obj' => stdClass Object &%x - 'inf' => null - ) -) -EOF - ), - array($obj3, - << 1 - 1 => 2 - 2 => 'Test\n' - 3 => 4 - 4 => 5 - 5 => 6 - 6 => 7 - 7 => 8 -) -EOF - ), - array( - chr(0) . chr(1) . chr(2) . chr(3) . chr(4) . chr(5), - 'Binary String: 0x000102030405' - ), - array( - implode('', array_map('chr', range(0x0e, 0x1f))), - 'Binary String: 0x0e0f101112131415161718191a1b1c1d1e1f' - ), - array( - chr(0x00) . chr(0x09), - 'Binary String: 0x0009' - ), - array( - '', - "''" - ), - ); - } - - /** - * @dataProvider exportProvider - */ - public function testExport($value, $expected) - { - $this->assertStringMatchesFormat( - $expected, - $this->trimNewline($this->exporter->export($value)) - ); - } - - public function testExport2() - { - if (PHP_VERSION === '5.3.3') { - $this->markTestSkipped('Skipped due to "Nesting level too deep - recursive dependency?" fatal error'); - } - - $obj = new \stdClass; - $obj->foo = 'bar'; - - $array = array( - 0 => 0, - 'null' => null, - 'boolean' => true, - 'integer' => 1, - 'double' => 1.2, - 'string' => '1', - 'text' => "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", - 'object' => $obj, - 'objectagain' => $obj, - 'array' => array('foo' => 'bar'), - ); - - $array['self'] = &$array; - - $expected = << 0 - 'null' => null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this -is -a -very -very -very -very -very -very -long -text' - 'object' => stdClass Object &%x ( - 'foo' => 'bar' - ) - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => Array &%d ( - 0 => 0 - 'null' => null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this -is -a -very -very -very -very -very -very -long -text' - 'object' => stdClass Object &%x - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => Array &%d - ) -) -EOF; - - $this->assertStringMatchesFormat( - $expected, - $this->trimNewline($this->exporter->export($array)) - ); - } - - public function shortenedExportProvider() - { - $obj = new \stdClass; - $obj->foo = 'bar'; - - $array = array( - 'foo' => 'bar', - ); - - return array( - array(null, 'null'), - array(true, 'true'), - array(1, '1'), - array(1.0, '1.0'), - array(1.2, '1.2'), - array('1', "'1'"), - // \n\r and \r is converted to \n - array("this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", "'this\\nis\\na\\nvery\\nvery\\nvery\\nvery...g\\ntext'"), - array(new \stdClass, 'stdClass Object ()'), - array($obj, 'stdClass Object (...)'), - array(array(), 'Array ()'), - array($array, 'Array (...)'), - ); - } - - /** - * @dataProvider shortenedExportProvider - */ - public function testShortenedExport($value, $expected) - { - $this->assertSame( - $expected, - $this->trimNewline($this->exporter->shortenedExport($value)) - ); - } - - public function provideNonBinaryMultibyteStrings() - { - return array( - array(implode('', array_map('chr', range(0x09, 0x0d))), 5), - array(implode('', array_map('chr', range(0x20, 0x7f))), 96), - array(implode('', array_map('chr', range(0x80, 0xff))), 128), - ); - } - - - /** - * @dataProvider provideNonBinaryMultibyteStrings - */ - public function testNonBinaryStringExport($value, $expectedLength) - { - $this->assertRegExp( - "~'.{{$expectedLength}}'\$~s", - $this->exporter->export($value) - ); - } - - public function testNonObjectCanBeReturnedAsArray() - { - $this->assertEquals(array(true), $this->exporter->toArray(true)); - } - - private function trimNewline($string) - { - return preg_replace('/[ ]*\n/', "\n", $string); - } -} diff --git a/vendor/sebastian/global-state/tests/BlacklistTest.php b/vendor/sebastian/global-state/tests/BlacklistTest.php deleted file mode 100644 index d5a2a75a8..000000000 --- a/vendor/sebastian/global-state/tests/BlacklistTest.php +++ /dev/null @@ -1,149 +0,0 @@ -. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * * Neither the name of Sebastian Bergmann nor the names of his - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ - -namespace SebastianBergmann\GlobalState; - -use PHPUnit_Framework_TestCase; - -/** - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ -class BlacklistTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \SebastianBergmann\GlobalState\Blacklist - */ - private $blacklist; - - protected function setUp() - { - $this->blacklist = new Blacklist; - } - - public function testGlobalVariableThatIsNotBlacklistedIsNotTreatedAsBlacklisted() - { - $this->assertFalse($this->blacklist->isGlobalVariableBlacklisted('variable')); - } - - public function testGlobalVariableCanBeBlacklisted() - { - $this->blacklist->addGlobalVariable('variable'); - - $this->assertTrue($this->blacklist->isGlobalVariableBlacklisted('variable')); - } - - public function testStaticAttributeThatIsNotBlacklistedIsNotTreatedAsBlacklisted() - { - $this->assertFalse( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedClass', - 'attribute' - ) - ); - } - - public function testClassCanBeBlacklisted() - { - $this->blacklist->addClass('SebastianBergmann\GlobalState\TestFixture\BlacklistedClass'); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedClass', - 'attribute' - ) - ); - } - - public function testSubclassesCanBeBlacklisted() - { - $this->blacklist->addSubclassesOf('SebastianBergmann\GlobalState\TestFixture\BlacklistedClass'); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedChildClass', - 'attribute' - ) - ); - } - - public function testImplementorsCanBeBlacklisted() - { - $this->blacklist->addImplementorsOf('SebastianBergmann\GlobalState\TestFixture\BlacklistedInterface'); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedImplementor', - 'attribute' - ) - ); - } - - public function testClassNamePrefixesCanBeBlacklisted() - { - $this->blacklist->addClassNamePrefix('SebastianBergmann\GlobalState'); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedClass', - 'attribute' - ) - ); - } - - public function testStaticAttributeCanBeBlacklisted() - { - $this->blacklist->addStaticAttribute( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedClass', - 'attribute' - ); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - 'SebastianBergmann\GlobalState\TestFixture\BlacklistedClass', - 'attribute' - ) - ); - } -} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php b/vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php deleted file mode 100644 index 99f7fdb05..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php +++ /dev/null @@ -1,53 +0,0 @@ -. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * * Neither the name of Sebastian Bergmann nor the names of his - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ - -namespace SebastianBergmann\GlobalState\TestFixture; - -/** - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ -class BlacklistedChildClass extends BlacklistedClass -{ -} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php b/vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php deleted file mode 100644 index f1582c7d7..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php +++ /dev/null @@ -1,54 +0,0 @@ -. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * * Neither the name of Sebastian Bergmann nor the names of his - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ - -namespace SebastianBergmann\GlobalState\TestFixture; - -/** - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ -class BlacklistedClass -{ - private static $attribute; -} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php b/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php deleted file mode 100644 index c80d98738..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php +++ /dev/null @@ -1,54 +0,0 @@ -. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * * Neither the name of Sebastian Bergmann nor the names of his - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ - -namespace SebastianBergmann\GlobalState\TestFixture; - -/** - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ -class BlacklistedImplementor implements BlacklistedInterface -{ - private static $attribute; -} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php b/vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php deleted file mode 100644 index f3941fdec..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php +++ /dev/null @@ -1,53 +0,0 @@ -. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * * Neither the name of Sebastian Bergmann nor the names of his - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ - -namespace SebastianBergmann\GlobalState\TestFixture; - -/** - * @author Sebastian Bergmann - * @copyright 2001-2014 Sebastian Bergmann - * @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License - * @link http://www.github.com/sebastianbergmann/global-state - */ -interface BlacklistedInterface -{ -} diff --git a/vendor/sebastian/recursion-context/tests/ContextTest.php b/vendor/sebastian/recursion-context/tests/ContextTest.php deleted file mode 100644 index 8e8cc56fa..000000000 --- a/vendor/sebastian/recursion-context/tests/ContextTest.php +++ /dev/null @@ -1,144 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\RecursionContext; - -use PHPUnit_Framework_TestCase; - -/** - * @covers SebastianBergmann\RecursionContext\Context - */ -class ContextTest extends PHPUnit_Framework_TestCase -{ - /** - * @var \SebastianBergmann\RecursionContext\Context - */ - private $context; - - protected function setUp() - { - $this->context = new Context(); - } - - public function failsProvider() - { - return array( - array(true), - array(false), - array(null), - array('string'), - array(1), - array(1.5), - array(fopen('php://memory', 'r')) - ); - } - - public function valuesProvider() - { - $obj2 = new \stdClass(); - $obj2->foo = 'bar'; - - $obj3 = (object) array(1,2,"Test\r\n",4,5,6,7,8); - - $obj = new \stdClass(); - //@codingStandardsIgnoreStart - $obj->null = null; - //@codingStandardsIgnoreEnd - $obj->boolean = true; - $obj->integer = 1; - $obj->double = 1.2; - $obj->string = '1'; - $obj->text = "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"; - $obj->object = $obj2; - $obj->objectagain = $obj2; - $obj->array = array('foo' => 'bar'); - $obj->array2 = array(1,2,3,4,5,6); - $obj->array3 = array($obj, $obj2, $obj3); - $obj->self = $obj; - - $storage = new \SplObjectStorage(); - $storage->attach($obj2); - $storage->foo = $obj2; - - return array( - array($obj, spl_object_hash($obj)), - array($obj2, spl_object_hash($obj2)), - array($obj3, spl_object_hash($obj3)), - array($storage, spl_object_hash($storage)), - array($obj->array, 0), - array($obj->array2, 0), - array($obj->array3, 0) - ); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::add - * @uses SebastianBergmann\RecursionContext\InvalidArgumentException - * @dataProvider failsProvider - */ - public function testAddFails($value) - { - $this->setExpectedException( - 'SebastianBergmann\\RecursionContext\\Exception', - 'Only arrays and objects are supported' - ); - $this->context->add($value); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @uses SebastianBergmann\RecursionContext\InvalidArgumentException - * @dataProvider failsProvider - */ - public function testContainsFails($value) - { - $this->setExpectedException( - 'SebastianBergmann\\RecursionContext\\Exception', - 'Only arrays and objects are supported' - ); - $this->context->contains($value); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::add - * @dataProvider valuesProvider - */ - public function testAdd($value, $key) - { - $this->assertEquals($key, $this->context->add($value)); - - // Test we get the same key on subsequent adds - $this->assertEquals($key, $this->context->add($value)); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @uses SebastianBergmann\RecursionContext\Context::add - * @depends testAdd - * @dataProvider valuesProvider - */ - public function testContainsFound($value, $key) - { - $this->context->add($value); - $this->assertEquals($key, $this->context->contains($value)); - - // Test we get the same key on subsequent calls - $this->assertEquals($key, $this->context->contains($value)); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @dataProvider valuesProvider - */ - public function testContainsNotFound($value) - { - $this->assertFalse($this->context->contains($value)); - } -} diff --git a/vendor/stack/builder/tests/functional/SilexApplicationTest.php b/vendor/stack/builder/tests/functional/SilexApplicationTest.php deleted file mode 100644 index 5636336a8..000000000 --- a/vendor/stack/builder/tests/functional/SilexApplicationTest.php +++ /dev/null @@ -1,60 +0,0 @@ -get('/foo', function () { - return 'bar'; - }); - - $finished = false; - - $app->finish(function () use (&$finished) { - $finished = true; - }); - - $stack = new Builder(); - $stack - ->push('functional\Append', '.A') - ->push('functional\Append', '.B'); - - $app = $stack->resolve($app); - - $request = Request::create('/foo'); - $response = $app->handle($request); - $app->terminate($request, $response); - - $this->assertSame('bar.B.A', $response->getContent()); - $this->assertTrue($finished); - } -} - -class Append implements HttpKernelInterface -{ - private $app; - private $appendix; - - public function __construct(HttpKernelInterface $app, $appendix) - { - $this->app = $app; - $this->appendix = $appendix; - } - - public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true) - { - $response = clone $this->app->handle($request, $type, $catch); - $response->setContent($response->getContent().$this->appendix); - - return $response; - } -} diff --git a/vendor/stack/builder/tests/unit/Stack/BuilderTest.php b/vendor/stack/builder/tests/unit/Stack/BuilderTest.php deleted file mode 100644 index 4092d01a5..000000000 --- a/vendor/stack/builder/tests/unit/Stack/BuilderTest.php +++ /dev/null @@ -1,215 +0,0 @@ -getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertInstanceOf('Stack\StackedHttpKernel', $resolved); - $this->assertSame('ok', $response->getContent()); - } - - /** @test */ - public function resolvedKernelShouldDelegateTerminateCalls() - { - $app = $this->getTerminableMock(); - - $stack = new Builder(); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = new Response('ok'); - - $resolved->handle($request); - $resolved->terminate($request, $response); - } - - /** @test */ - public function pushShouldReturnSelf() - { - $stack = new Builder(); - $this->assertSame($stack, $stack->push('Stack\AppendA')); - } - - /** @test */ - public function pushShouldThrowOnInvalidInput() - { - $this->setExpectedException('InvalidArgumentException', 'Missing argument(s) when calling push'); - $stack = new Builder(); - $stack->push(); - } - - /** @test */ - public function unshiftShouldReturnSelf() - { - $stack = new Builder(); - $this->assertSame($stack, $stack->unshift('Stack\AppendA')); - } - - /** @test */ - public function unshiftShouldThrowOnInvalidInput() - { - $this->setExpectedException('InvalidArgumentException', 'Missing argument(s) when calling unshift'); - $stack = new Builder(); - $stack->unshift(); - } - - /** @test */ - public function appendMiddlewareShouldAppendToBody() - { - $app = $this->getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $stack->push('Stack\AppendA'); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertSame('ok.A', $response->getContent()); - } - - /** @test */ - public function unshiftMiddlewareShouldPutMiddlewareBeforePushed() - { - $app = $this->getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $stack->push('Stack\Append', '2.'); - $stack->unshift('Stack\Append', '1.'); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertSame('ok2.1.', $response->getContent()); - } - - /** @test */ - public function stackedMiddlewaresShouldWrapInReverseOrder() - { - $app = $this->getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $stack->push('Stack\AppendA'); - $stack->push('Stack\AppendB'); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertSame('ok.B.A', $response->getContent()); - } - - /** @test */ - public function resolveShouldPassPushArgumentsToMiddlewareConstructor() - { - $app = $this->getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $stack->push('Stack\Append', '.foo'); - $stack->push('Stack\Append', '.bar'); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertSame('ok.bar.foo', $response->getContent()); - } - - /** @test */ - public function resolveShouldCallSpecFactories() - { - $app = $this->getHttpKernelMock(new Response('ok')); - - $stack = new Builder(); - $stack->push(function ($app) { return new Append($app, '.foo'); }); - $stack->push(function ($app) { return new Append($app, '.bar'); }); - $resolved = $stack->resolve($app); - - $request = Request::create('/'); - $response = $resolved->handle($request); - - $this->assertSame('ok.bar.foo', $response->getContent()); - } - - private function getHttpKernelMock(Response $response) - { - $app = $this->getMock('Symfony\Component\HttpKernel\HttpKernelInterface'); - $app->expects($this->any()) - ->method('handle') - ->with($this->isInstanceOf('Symfony\Component\HttpFoundation\Request')) - ->will($this->returnValue($response)); - - return $app; - } - - private function getTerminableMock() - { - $app = $this->getMock('Stack\TerminableHttpKernel'); - $app->expects($this->once()) - ->method('terminate') - ->with( - $this->isInstanceOf('Symfony\Component\HttpFoundation\Request'), - $this->isInstanceOf('Symfony\Component\HttpFoundation\Response') - ); - - return $app; - } -} - -abstract class TerminableHttpKernel implements HttpKernelInterface, TerminableInterface -{ -} - -class Append implements HttpKernelInterface -{ - private $app; - private $appendix; - - public function __construct(HttpKernelInterface $app, $appendix) - { - $this->app = $app; - $this->appendix = $appendix; - } - - public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true) - { - $response = clone $this->app->handle($request, $type, $catch); - $response->setContent($response->getContent().$this->appendix); - - return $response; - } -} - -class AppendA extends Append -{ - public function __construct(HttpKernelInterface $app) - { - parent::__construct($app, '.A'); - } -} - -class AppendB extends Append -{ - public function __construct(HttpKernelInterface $app) - { - parent::__construct($app, '.B'); - } -} diff --git a/vendor/stack/builder/tests/unit/Stack/StackedHttpKernelTest.php b/vendor/stack/builder/tests/unit/Stack/StackedHttpKernelTest.php deleted file mode 100644 index 545e1f818..000000000 --- a/vendor/stack/builder/tests/unit/Stack/StackedHttpKernelTest.php +++ /dev/null @@ -1,155 +0,0 @@ -getHttpKernelMock(new Response('ok')); - $kernel = new StackedHttpKernel($app, array($app)); - - $request = Request::create('/'); - $response = $kernel->handle($request); - - $this->assertSame('ok', $response->getContent()); - } - - /** @test */ - public function handleShouldStillDelegateToAppWithMiddlewares() - { - $app = $this->getHttpKernelMock(new Response('ok')); - $bar = $this->getHttpKernelMock(new Response('bar')); - $foo = $this->getHttpKernelMock(new Response('foo')); - $kernel = new StackedHttpKernel($app, array($foo, $bar, $app)); - - $request = Request::create('/'); - $response = $kernel->handle($request); - - $this->assertSame('ok', $response->getContent()); - } - - /** @test */ - public function terminateShouldDelegateToMiddlewares() - { - $first = new TerminableKernelSpy(); - $second = new TerminableKernelSpy($first); - $third = new KernelSpy($second); - $fourth = new TerminableKernelSpy($third); - $fifth = new TerminableKernelSpy($fourth); - - $kernel = new StackedHttpKernel($fifth, $middlewares = array($fifth, $fourth, $third, $second, $first)); - - $request = Request::create('/'); - $response = $kernel->handle($request); - $kernel->terminate($request, $response); - - $this->assertTerminablesCalledOnce($middlewares); - } - - private function assertTerminablesCalledOnce(array $middlewares) - { - foreach ($middlewares as $kernel) { - if ($kernel instanceof TerminableInterface) { - $this->assertEquals(1, $kernel->terminateCallCount(), "Terminate was called {$kernel->terminateCallCount()} times"); - } - } - } - - private function getHttpKernelMock(Response $response) - { - $app = $this->getMock('Symfony\Component\HttpKernel\HttpKernelInterface'); - $app->expects($this->any()) - ->method('handle') - ->with($this->isInstanceOf('Symfony\Component\HttpFoundation\Request')) - ->will($this->returnValue($response)); - - return $app; - } - - private function getTerminableMock(Response $response = null) - { - $app = $this->getMock('Stack\TerminableHttpKernel'); - if ($response) { - $app->expects($this->any()) - ->method('handle') - ->with($this->isInstanceOf('Symfony\Component\HttpFoundation\Request')) - ->will($this->returnValue($response)); - } - $app->expects($this->once()) - ->method('terminate') - ->with( - $this->isInstanceOf('Symfony\Component\HttpFoundation\Request'), - $this->isInstanceOf('Symfony\Component\HttpFoundation\Response') - ); - - return $app; - } - - private function getDelegatingTerminableMock(TerminableInterface $next) - { - $app = $this->getMock('Stack\TerminableHttpKernel'); - $app->expects($this->once()) - ->method('terminate') - ->with( - $this->isInstanceOf('Symfony\Component\HttpFoundation\Request'), - $this->isInstanceOf('Symfony\Component\HttpFoundation\Response') - ) - ->will($this->returnCallback(function ($request, $response) use ($next) { - $next->terminate($request, $response); - })); - - return $app; - } -} - -class KernelSpy implements HttpKernelInterface -{ - private $handleCallCount = 0; - - public function __construct(HttpKernelInterface $kernel = null) - { - $this->kernel = $kernel; - } - - public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true) - { - $this->handleCallCount++; - - if ($this->kernel) { - return $this->kernel->handle($request, $type, $catch); - } - - return new Response('OK'); - } - - public function handleCallCount() - { - return $this->handleCallCount; - } -} - -class TerminableKernelSpy extends KernelSpy implements TerminableInterface -{ - private $terminateCallCount = 0; - - public function terminate(Request $request, Response $response) - { - $this->terminateCallCount++; - - if ($this->kernel && $this->kernel instanceof TerminableInterface) { - return $this->kernel->terminate($request, $response); - } - } - - public function terminateCallCount() - { - return $this->terminateCallCount; - } -} diff --git a/vendor/symfony-cmf/routing/Test/CmfUnitTestCase.php b/vendor/symfony-cmf/routing/Test/CmfUnitTestCase.php deleted file mode 100644 index f0e9ea158..000000000 --- a/vendor/symfony-cmf/routing/Test/CmfUnitTestCase.php +++ /dev/null @@ -1,23 +0,0 @@ -getMockBuilder($class) - ->disableOriginalConstructor() - ->setMethods($methods) - ->getMock(); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Candidates/CandidatesTest.php b/vendor/symfony-cmf/routing/Tests/Candidates/CandidatesTest.php deleted file mode 100644 index 322c052de..000000000 --- a/vendor/symfony-cmf/routing/Tests/Candidates/CandidatesTest.php +++ /dev/null @@ -1,105 +0,0 @@ -assertTrue($candidates->isCandidate('/routes')); - $this->assertTrue($candidates->isCandidate('/routes/my/path')); - } - - /** - * Nothing should be called on the query builder - */ - public function testRestrictQuery() - { - $candidates = new Candidates(); - $candidates->restrictQuery(null); - } - - public function testGetCandidates() - { - $request = Request::create('/my/path.html'); - - $candidates = new Candidates(); - $paths = $candidates->getCandidates($request); - - $this->assertEquals( - array( - '/my/path.html', - '/my/path', - '/my', - '/', - ), - $paths - ); - } - - public function testGetCandidatesLocales() - { - $candidates = new Candidates(array('de', 'fr')); - - $request = Request::create('/fr/path.html'); - $paths = $candidates->getCandidates($request); - - $this->assertEquals( - array( - '/fr/path.html', - '/fr/path', - '/fr', - '/', - '/path.html', - '/path' - ), - $paths - ); - - $request = Request::create('/it/path.html'); - $paths = $candidates->getCandidates($request); - - $this->assertEquals( - array( - '/it/path.html', - '/it/path', - '/it', - '/', - ), - $paths - ); - } - - public function testGetCandidatesLimit() - { - $candidates = new Candidates(array(), 1); - - $request = Request::create('/my/path/is/deep.html'); - - $paths = $candidates->getCandidates($request); - - $this->assertEquals( - array( - '/my/path/is/deep.html', - '/my/path/is/deep', - ), - $paths - ); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRouteEnhancersPassTest.php b/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRouteEnhancersPassTest.php deleted file mode 100644 index 021388534..000000000 --- a/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRouteEnhancersPassTest.php +++ /dev/null @@ -1,71 +0,0 @@ - array( - 0 => array( - 'id' => 'foo_enhancer' - ) - ), - ); - - $definition = new Definition('router'); - $builder = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder'); - $builder->expects($this->at(0)) - ->method('hasDefinition') - ->with('cmf_routing.dynamic_router') - ->will($this->returnValue(true)) - ; - $builder->expects($this->once()) - ->method('findTaggedServiceIds') - ->will($this->returnValue($serviceIds)) - ; - $builder->expects($this->once()) - ->method('getDefinition') - ->with('cmf_routing.dynamic_router') - ->will($this->returnValue($definition)) - ; - - $pass = new RegisterRouteEnhancersPass(); - $pass->process($builder); - - $calls = $definition->getMethodCalls(); - $this->assertEquals(1, count($calls)); - $this->assertEquals('addRouteEnhancer', $calls[0][0]); - } - - /** - * If there is no dynamic router defined in the container builder, nothing - * should be processed. - */ - public function testNoDynamicRouter() - { - $builder = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder'); - $builder->expects($this->once()) - ->method('hasDefinition') - ->with('cmf_routing.dynamic_router') - ->will($this->returnValue(false)) - ; - - $pass = new RegisterRouteEnhancersPass(); - $pass->process($builder); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRoutersPassTest.php b/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRoutersPassTest.php deleted file mode 100644 index f66c2d8fe..000000000 --- a/vendor/symfony-cmf/routing/Tests/DependencyInjection/Compiler/RegisterRoutersPassTest.php +++ /dev/null @@ -1,98 +0,0 @@ -markTestSkipped('PHPUnit version too old for this test'); - } - $services = array(); - $services[$name] = array(0 => array('priority' => $priority)); - - $priority = $priority ?: 0; - - $definition = $this->getMock('Symfony\Component\DependencyInjection\Definition'); - $definition->expects($this->atLeastOnce()) - ->method('addMethodCall') - ->with($this->equalTo('add'), $this->callback(function ($arg) use ($name, $priority) { - if (!$arg[0] instanceof Reference || $name !== $arg[0]->__toString()) { - return false; - } - - if ($priority !== $arg[1]) { - return false; - } - - return true; - })); - - $builder = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder', array('hasDefinition', 'findTaggedServiceIds', 'getDefinition')); - $builder->expects($this->any()) - ->method('hasDefinition') - ->with('cmf_routing.router') - ->will($this->returnValue(true)); - - $builder->expects($this->atLeastOnce()) - ->method('findTaggedServiceIds') - ->will($this->returnValue($services)); - - $builder->expects($this->atLeastOnce()) - ->method('getDefinition') - ->will($this->returnValue($definition)); - - $registerRoutersPass = new RegisterRoutersPass(); - $registerRoutersPass->process($builder); - } - - public function getValidRoutersData() - { - return array( - array('my_router'), - array('my_primary_router', 99), - array('my_router', 0), - ); - } - - /** - * If there is no chain router defined in the container builder, nothing - * should be processed. - */ - public function testNoChainRouter() - { - $builder = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder', array('hasDefinition', 'findTaggedServiceIds', 'getDefinition')); - $builder->expects($this->once()) - ->method('hasDefinition') - ->with('cmf_routing.router') - ->will($this->returnValue(false)) - ; - - $builder->expects($this->never()) - ->method('findTaggedServiceIds') - ; - $builder->expects($this->never()) - ->method('getDefinition') - ; - - $registerRoutersPass = new RegisterRoutersPass(); - $registerRoutersPass->process($builder); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldByClassEnhancerTest.php b/vendor/symfony-cmf/routing/Tests/Enhancer/FieldByClassEnhancerTest.php deleted file mode 100644 index 9dc80b035..000000000 --- a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldByClassEnhancerTest.php +++ /dev/null @@ -1,71 +0,0 @@ -document = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Enhancer\RouteObject'); - - $mapping = array('Symfony\Cmf\Component\Routing\Tests\Enhancer\RouteObject' - => 'cmf_content.controller:indexAction'); - - $this->mapper = new FieldByClassEnhancer('_content', '_controller', $mapping); - - $this->request = Request::create('/test'); - } - - public function testClassFoundInMapping() - { - // this is the mock, thus a child class to make sure we properly check with instanceof - $defaults = array('_content' => $this->document); - $expected = array( - '_content' => $this->document, - '_controller' => 'cmf_content.controller:indexAction', - ); - $this->assertEquals($expected, $this->mapper->enhance($defaults, $this->request)); - } - - public function testFieldAlreadyThere() - { - $defaults = array( - '_content' => $this->document, - '_controller' => 'custom.controller:indexAction', - ); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testClassNotFoundInMapping() - { - $defaults = array('_content' => $this); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testNoClass() - { - $defaults = array('foo' => 'bar'); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldMapEnhancerTest.php b/vendor/symfony-cmf/routing/Tests/Enhancer/FieldMapEnhancerTest.php deleted file mode 100644 index c7a902d2b..000000000 --- a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldMapEnhancerTest.php +++ /dev/null @@ -1,69 +0,0 @@ -request = Request::create('/test'); - $mapping = array('static_pages' => 'cmf_content.controller:indexAction'); - - $this->enhancer = new FieldMapEnhancer('type', '_controller', $mapping); - } - - public function testFieldFoundInMapping() - { - $defaults = array('type' => 'static_pages'); - $expected = array( - 'type' => 'static_pages', - '_controller' => 'cmf_content.controller:indexAction', - ); - $this->assertEquals($expected, $this->enhancer->enhance($defaults, $this->request)); - } - - public function testFieldAlreadyThere() - { - $defaults = array( - 'type' => 'static_pages', - '_controller' => 'custom.controller:indexAction', - ); - $this->assertEquals($defaults, $this->enhancer->enhance($defaults, $this->request)); - } - - public function testNoType() - { - $defaults = array(); - $this->assertEquals(array(), $this->enhancer->enhance($defaults, $this->request)); - } - - public function testNotFoundInMapping() - { - $defaults = array('type' => 'unknown_route'); - $this->assertEquals($defaults, $this->enhancer->enhance($defaults, $this->request)); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldPresenceEnhancerTest.php b/vendor/symfony-cmf/routing/Tests/Enhancer/FieldPresenceEnhancerTest.php deleted file mode 100644 index 8a2b75428..000000000 --- a/vendor/symfony-cmf/routing/Tests/Enhancer/FieldPresenceEnhancerTest.php +++ /dev/null @@ -1,71 +0,0 @@ -mapper = new FieldPresenceEnhancer('_template', '_controller', 'cmf_content.controller:indexAction'); - - $this->request = Request::create('/test'); - } - - public function testHasTemplate() - { - $defaults = array('_template' => 'Bundle:Topic:template.html.twig'); - $expected = array( - '_template' => 'Bundle:Topic:template.html.twig', - '_controller' => 'cmf_content.controller:indexAction', - ); - $this->assertEquals($expected, $this->mapper->enhance($defaults, $this->request)); - } - - public function testFieldAlreadyThere() - { - $defaults = array( - '_template' => 'Bundle:Topic:template.html.twig', - '_controller' => 'custom.controller:indexAction', - ); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testHasNoSourceValue() - { - $defaults = array('foo' => 'bar'); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testHasNoSource() - { - $this->mapper = new FieldPresenceEnhancer(null, '_controller', 'cmf_content.controller:indexAction'); - - $defaults = array('foo' => 'bar'); - $expected = array( - 'foo' => 'bar', - '_controller' => 'cmf_content.controller:indexAction', - ); - $this->assertEquals($expected, $this->mapper->enhance($defaults, $this->request)); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Enhancer/RouteContentEnhancerTest.php b/vendor/symfony-cmf/routing/Tests/Enhancer/RouteContentEnhancerTest.php deleted file mode 100644 index 06b091160..000000000 --- a/vendor/symfony-cmf/routing/Tests/Enhancer/RouteContentEnhancerTest.php +++ /dev/null @@ -1,87 +0,0 @@ -document = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Enhancer\RouteObject', - array('getContent', 'getRouteDefaults', 'getUrl')); - - $this->mapper = new RouteContentEnhancer(RouteObjectInterface::ROUTE_OBJECT, '_content'); - - $this->request = Request::create('/test'); - } - - public function testContent() - { - $targetDocument = new TargetDocument(); - $this->document->expects($this->once()) - ->method('getContent') - ->will($this->returnValue($targetDocument)); - - $defaults = array(RouteObjectInterface::ROUTE_OBJECT => $this->document); - $expected = array(RouteObjectInterface::ROUTE_OBJECT => $this->document, '_content' => $targetDocument); - - $this->assertEquals($expected, $this->mapper->enhance($defaults, $this->request)); - } - - public function testFieldAlreadyThere() - { - $this->document->expects($this->never()) - ->method('getContent') - ; - - $defaults = array(RouteObjectInterface::ROUTE_OBJECT => $this->document, '_content' => 'foo'); - - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testNoContent() - { - $this->document->expects($this->once()) - ->method('getContent') - ->will($this->returnValue(null)); - - $defaults = array(RouteObjectInterface::ROUTE_OBJECT => $this->document); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } - - public function testNoCmfRoute() - { - $defaults = array(RouteObjectInterface::ROUTE_OBJECT => $this->buildMock('Symfony\Component\Routing\Route')); - $this->assertEquals($defaults, $this->mapper->enhance($defaults, $this->request)); - } -} - -class TargetDocument -{ -} - -class UnknownDocument -{ -} diff --git a/vendor/symfony-cmf/routing/Tests/Enhancer/RouteObject.php b/vendor/symfony-cmf/routing/Tests/Enhancer/RouteObject.php deleted file mode 100644 index 752b8e000..000000000 --- a/vendor/symfony-cmf/routing/Tests/Enhancer/RouteObject.php +++ /dev/null @@ -1,27 +0,0 @@ -provider = $this->buildMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $this->routeFilter1 = $this->buildMock('Symfony\Cmf\Component\Routing\NestedMatcher\RouteFilterInterface'); - $this->routeFilter2 = $this->buildMock('Symfony\Cmf\Component\Routing\NestedMatcher\RouteFilterInterface'); - $this->finalMatcher = $this->buildMock('Symfony\Cmf\Component\Routing\NestedMatcher\FinalMatcherInterface'); - } - - public function testNestedMatcher() - { - $request = Request::create('/path/one'); - $routeCollection = new RouteCollection(); - $route = $this->getMockBuilder('Symfony\Component\Routing\Route')->disableOriginalConstructor()->getMock(); - $routeCollection->add('route', $route); - - $this->provider->expects($this->once()) - ->method('getRouteCollectionForRequest') - ->with($request) - ->will($this->returnValue($routeCollection)) - ; - $this->routeFilter1->expects($this->once()) - ->method('filter') - ->with($routeCollection, $request) - ->will($this->returnValue($routeCollection)) - ; - $this->routeFilter2->expects($this->once()) - ->method('filter') - ->with($routeCollection, $request) - ->will($this->returnValue($routeCollection)) - ; - $this->finalMatcher->expects($this->once()) - ->method('finalMatch') - ->with($routeCollection, $request) - ->will($this->returnValue(array('foo' => 'bar'))) - ; - - $matcher = new NestedMatcher($this->provider, $this->finalMatcher); - $matcher->addRouteFilter($this->routeFilter1); - $matcher->addRouteFilter($this->routeFilter2); - - $attributes = $matcher->matchRequest($request); - - $this->assertEquals(array('foo' => 'bar'), $attributes); - } - - /** - * Test priorities and exception handling - */ - public function testNestedMatcherPriority() - { - $request = Request::create('/path/one'); - $routeCollection = new RouteCollection(); - $route = $this->getMockBuilder('Symfony\Component\Routing\Route')->disableOriginalConstructor()->getMock(); - $routeCollection->add('route', $route); - - $wrongProvider = $this->buildMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $wrongProvider->expects($this->never()) - ->method('getRouteCollectionForRequest') - ; - $this->provider->expects($this->once()) - ->method('getRouteCollectionForRequest') - ->with($request) - ->will($this->returnValue($routeCollection)) - ; - $this->routeFilter1->expects($this->once()) - ->method('filter') - ->with($routeCollection, $request) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $this->routeFilter2->expects($this->never()) - ->method('filter') - ; - $this->finalMatcher->expects($this->never()) - ->method('finalMatch') - ; - - $matcher = new NestedMatcher($wrongProvider, $this->finalMatcher); - $matcher->setRouteProvider($this->provider); - $matcher->addRouteFilter($this->routeFilter2, 10); - $matcher->addRouteFilter($this->routeFilter1, 20); - - try { - $matcher->matchRequest($request); - fail('nested matcher is eating exception'); - } catch (ResourceNotFoundException $e) { - // expected - } - } - - public function testProviderNoMatch() - { - $request = Request::create('/path/one'); - $routeCollection = new RouteCollection(); - $this->provider->expects($this->once()) - ->method('getRouteCollectionForRequest') - ->with($request) - ->will($this->returnValue($routeCollection)) - ; - $this->finalMatcher->expects($this->never()) - ->method('finalMatch') - ; - - $matcher = new NestedMatcher($this->provider, $this->finalMatcher); - - $this->setExpectedException('Symfony\Component\Routing\Exception\ResourceNotFoundException'); - $matcher->matchRequest($request); - } - -} diff --git a/vendor/symfony-cmf/routing/Tests/NestedMatcher/UrlMatcherTest.php b/vendor/symfony-cmf/routing/Tests/NestedMatcher/UrlMatcherTest.php deleted file mode 100644 index d5b563510..000000000 --- a/vendor/symfony-cmf/routing/Tests/NestedMatcher/UrlMatcherTest.php +++ /dev/null @@ -1,152 +0,0 @@ -routeDocument = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'getRouteKey', 'compile')); - $this->routeCompiled = $this->buildMock('Symfony\Component\Routing\CompiledRoute'); - - $this->context = $this->buildMock('Symfony\Component\Routing\RequestContext'); - $this->request = Request::create($this->url); - - $this->matcher = new UrlMatcher(new RouteCollection(), $this->context); - } - - public function testMatchRouteKey() - { - $this->doTestMatchRouteKey($this->url); - } - - public function testMatchNoKey() - { - $this->doTestMatchRouteKey(null); - } - - public function doTestMatchRouteKey($routeKey) - { - $this->routeCompiled->expects($this->atLeastOnce()) - ->method('getStaticPrefix') - ->will($this->returnValue($this->url)) - ; - $this->routeCompiled->expects($this->atLeastOnce()) - ->method('getRegex') - ->will($this->returnValue('#'.str_replace('/', '\/', $this->url).'#')) - ; - $this->routeDocument->expects($this->atLeastOnce()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - $this->routeDocument->expects($this->atLeastOnce()) - ->method('getRouteKey') - ->will($this->returnValue($routeKey)) - ; - $this->routeDocument->expects($this->atLeastOnce()) - ->method('getDefaults') - ->will($this->returnValue(array('foo' => 'bar'))) - ; - - $mockCompiled = $this->buildMock('Symfony\Component\Routing\CompiledRoute'); - $mockCompiled->expects($this->any()) - ->method('getStaticPrefix') - ->will($this->returnValue('/no/match')) - ; - $mockRoute = $this->getMockBuilder('Symfony\Component\Routing\Route')->disableOriginalConstructor()->getMock(); - $mockRoute->expects($this->any()) - ->method('compile') - ->will($this->returnValue($mockCompiled)) - ; - $routeCollection = new RouteCollection(); - $routeCollection->add('some', $mockRoute); - $routeCollection->add('_company_more', $this->routeDocument); - $routeCollection->add('other', $mockRoute); - - $results = $this->matcher->finalMatch($routeCollection, $this->request); - - $expected = array( - RouteObjectInterface::ROUTE_NAME => ($routeKey) ? $routeKey : '_company_more', - RouteObjectInterface::ROUTE_OBJECT => $this->routeDocument, - 'foo' => 'bar', - ); - - $this->assertEquals($expected, $results); - } - - public function testMatchNoRouteObject() - { - $this->routeCompiled->expects($this->atLeastOnce()) - ->method('getStaticPrefix') - ->will($this->returnValue($this->url)) - ; - $this->routeCompiled->expects($this->atLeastOnce()) - ->method('getRegex') - ->will($this->returnValue('#'.str_replace('/', '\/', $this->url).'#')) - ; - $this->routeDocument = $this->getMockBuilder('Symfony\Component\Routing\Route')->disableOriginalConstructor()->getMock(); - $this->routeDocument->expects($this->atLeastOnce()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - $this->routeDocument->expects($this->never()) - ->method('getRouteKey') - ; - $this->routeDocument->expects($this->atLeastOnce()) - ->method('getDefaults') - ->will($this->returnValue(array('foo' => 'bar'))) - ; - - $mockCompiled = $this->buildMock('Symfony\Component\Routing\CompiledRoute'); - $mockCompiled->expects($this->any()) - ->method('getStaticPrefix') - ->will($this->returnValue('/no/match')) - ; - $mockRoute = $this->getMockBuilder('Symfony\Component\Routing\Route')->disableOriginalConstructor()->getMock(); - $mockRoute->expects($this->any()) - ->method('compile') - ->will($this->returnValue($mockCompiled)) - ; - $routeCollection = new RouteCollection(); - $routeCollection->add('some', $mockRoute); - $routeCollection->add('_company_more', $this->routeDocument); - $routeCollection->add('other', $mockRoute); - - $results = $this->matcher->finalMatch($routeCollection, $this->request); - - $expected = array( - RouteObjectInterface::ROUTE_NAME => '_company_more', - RouteObjectInterface::ROUTE_OBJECT => $this->routeDocument, - 'foo' => 'bar', - ); - - $this->assertEquals($expected, $results); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/ChainRouterTest.php b/vendor/symfony-cmf/routing/Tests/Routing/ChainRouterTest.php deleted file mode 100644 index e8b8e3c7b..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/ChainRouterTest.php +++ /dev/null @@ -1,730 +0,0 @@ -router = new ChainRouter($this->getMock('Psr\Log\LoggerInterface')); - $this->context = $this->getMock('Symfony\Component\Routing\RequestContext'); - } - - public function testPriority() - { - $this->assertEquals(array(), $this->router->all()); - - list($low, $high) = $this->createRouterMocks(); - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->assertEquals(array( - $high, - $low, - ), $this->router->all()); - } - - /** - * Routers are supposed to be sorted only once. - * This test will check that by trying to get all routers several times. - * - * @covers \Symfony\Cmf\Component\Routing\ChainRouter::sortRouters - * @covers \Symfony\Cmf\Component\Routing\ChainRouter::all - */ - public function testSortRouters() - { - list($low, $medium, $high) = $this->createRouterMocks(); - // We're using a mock here and not $this->router because we need to ensure that the sorting operation is done only once. - /** @var $router ChainRouter|\PHPUnit_Framework_MockObject_MockObject */ - $router = $this->buildMock('Symfony\Cmf\Component\Routing\ChainRouter', array('sortRouters')); - $router - ->expects($this->once()) - ->method('sortRouters') - ->will( - $this->returnValue( - array($high, $medium, $low) - ) - ) - ; - - $router->add($low, 10); - $router->add($medium, 50); - $router->add($high, 100); - $expectedSortedRouters = array($high, $medium, $low); - // Let's get all routers 5 times, we should only sort once. - for ($i = 0; $i < 5; ++$i) { - $this->assertSame($expectedSortedRouters, $router->all()); - } - } - - /** - * This test ensures that if a router is being added on the fly, the sorting is reset. - * - * @covers \Symfony\Cmf\Component\Routing\ChainRouter::sortRouters - * @covers \Symfony\Cmf\Component\Routing\ChainRouter::all - * @covers \Symfony\Cmf\Component\Routing\ChainRouter::add - */ - public function testReSortRouters() - { - list($low, $medium, $high) = $this->createRouterMocks(); - $highest = clone $high; - // We're using a mock here and not $this->router because we need to ensure that the sorting operation is done only once. - /** @var $router ChainRouter|\PHPUnit_Framework_MockObject_MockObject */ - $router = $this->buildMock('Symfony\Cmf\Component\Routing\ChainRouter', array('sortRouters')); - $router - ->expects($this->at(0)) - ->method('sortRouters') - ->will( - $this->returnValue( - array($high, $medium, $low) - ) - ) - ; - // The second time sortRouters() is called, we're supposed to get the newly added router ($highest) - $router - ->expects($this->at(1)) - ->method('sortRouters') - ->will( - $this->returnValue( - array($highest, $high, $medium, $low) - ) - ) - ; - - $router->add($low, 10); - $router->add($medium, 50); - $router->add($high, 100); - $this->assertSame(array($high, $medium, $low), $router->all()); - - // Now adding another router on the fly, sorting must have been reset - $router->add($highest, 101); - $this->assertSame(array($highest, $high, $medium, $low), $router->all()); - } - - /** - * context must be propagated to chained routers and be stored locally - */ - public function testContext() - { - list($low, $high) = $this->createRouterMocks(); - - $low - ->expects($this->once()) - ->method('setContext') - ->with($this->context) - ; - - $high - ->expects($this->once()) - ->method('setContext') - ->with($this->context) - ; - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->setContext($this->context); - $this->assertSame($this->context, $this->router->getContext()); - } - - /** - * context must be propagated also when routers are added after context is set - */ - public function testContextOrder() - { - list($low, $high) = $this->createRouterMocks(); - - $low - ->expects($this->once()) - ->method('setContext') - ->with($this->context) - ; - - $high - ->expects($this->once()) - ->method('setContext') - ->with($this->context) - ; - - $this->router->setContext($this->context); - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->all(); - - $this->assertSame($this->context, $this->router->getContext()); - } - - /** - * The first usable match is used, no further routers are queried once a match is found - */ - public function testMatch() - { - $url = '/test'; - list($lower, $low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\ResourceNotFoundException)) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->returnValue(array('test'))) - ; - $lower - ->expects($this->never()) - ->method('match'); - $this->router->add($lower, 5); - $this->router->add($low, 10); - $this->router->add($high, 100); - - $result = $this->router->match('/test'); - $this->assertEquals(array('test'), $result); - } - - /** - * The first usable match is used, no further routers are queried once a match is found - */ - public function testMatchRequest() - { - $url = '/test'; - list($lower, $low, $high) = $this->createRouterMocks(); - - $highest = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\RequestMatcher'); - - $request = Request::create('/test'); - - $highest - ->expects($this->once()) - ->method('matchRequest') - ->will($this->throwException(new \Symfony\Component\Routing\Exception\ResourceNotFoundException)) - ; - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\ResourceNotFoundException)) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->returnValue(array('test'))) - ; - $lower - ->expects($this->never()) - ->method('match') - ; - - $this->router->add($lower, 5); - $this->router->add($low, 10); - $this->router->add($high, 100); - $this->router->add($highest, 200); - - $result = $this->router->matchRequest($request); - $this->assertEquals(array('test'), $result); - } - - /** - * Call match on ChainRouter that has RequestMatcher in the chain. - */ - public function testMatchWithRequestMatchers() - { - $url = '/test'; - - list($low) = $this->createRouterMocks(); - - $high = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\RequestMatcher'); - - $high - ->expects($this->once()) - ->method('matchRequest') - ->with($this->callback(function (Request $r) use ($url) { - return $r->getPathInfo() === $url; - })) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\ResourceNotFoundException)) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->returnValue(array('test'))) - ; - - $this->router->add($low, 10); - $this->router->add($high, 20); - - $result = $this->router->match($url); - $this->assertEquals(array('test'), $result); - } - - /** - * If there is a method not allowed but another router matches, that one is used - */ - public function testMatchAndNotAllowed() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\MethodNotAllowedException(array()))) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->returnValue(array('test'))) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $result = $this->router->match('/test'); - $this->assertEquals(array('test'), $result); - } - - /** - * If there is a method not allowed but another router matches, that one is used - */ - public function testMatchRequestAndNotAllowed() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\MethodNotAllowedException(array()))) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->returnValue(array('test'))) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $result = $this->router->matchRequest(Request::create('/test')); - $this->assertEquals(array('test'), $result); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\ResourceNotFoundException - */ - public function testMatchNotFound() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->match('/test'); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\ResourceNotFoundException - */ - public function testMatchRequestNotFound() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->matchRequest(Request::create('/test')); - } - - /** - * Call match on ChainRouter that has RequestMatcher in the chain. - * - * @expectedException \Symfony\Component\Routing\Exception\ResourceNotFoundException - * @expectedExceptionMessage None of the routers in the chain matched url '/test' - */ - public function testMatchWithRequestMatchersNotFound() - { - $url = '/test'; - $request = Request::create('/test'); - - $high = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\RequestMatcher'); - - $high - ->expects($this->once()) - ->method('matchRequest') - ->with($request) - ->will($this->throwException(new \Symfony\Component\Routing\Exception\ResourceNotFoundException)) - ; - - $this->router->add($high, 20); - - $this->router->match($url); - } - - /** - * If any of the routers throws a not allowed exception and no other matches, we need to see this - * - * @expectedException \Symfony\Component\Routing\Exception\MethodNotAllowedException - */ - public function testMatchMethodNotAllowed() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new MethodNotAllowedException(array()))) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->match('/test'); - } - - /** - * If any of the routers throws a not allowed exception and no other matches, we need to see this - * - * @expectedException \Symfony\Component\Routing\Exception\MethodNotAllowedException - */ - public function testMatchRequestMethodNotAllowed() - { - $url = '/test'; - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new MethodNotAllowedException(array()))) - ; - $low - ->expects($this->once()) - ->method('match') - ->with($url) - ->will($this->throwException(new ResourceNotFoundException())) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->matchRequest(Request::create('/test')); - } - - public function testGenerate() - { - $url = '/test'; - $name = 'test'; - $parameters = array('test' => 'value'); - list($lower, $low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->throwException(new RouteNotFoundException())) - ; - $low - ->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->returnValue($url)) - ; - $lower - ->expects($this->never()) - ->method('generate') - ; - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $result = $this->router->generate($name, $parameters); - $this->assertEquals($url, $result); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNotFound() - { - $name = 'test'; - $parameters = array('test' => 'value'); - list($low, $high) = $this->createRouterMocks(); - - $high - ->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->throwException(new RouteNotFoundException())) - ; - $low->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->throwException(new RouteNotFoundException())) - ; - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->generate($name, $parameters); - } - - /** - * Route is an object but no versatile generator around to do the debug message. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateObjectNotFound() - { - $name = new \stdClass(); - $parameters = array('test' => 'value'); - - $defaultRouter = $this->getMock('Symfony\Component\Routing\RouterInterface'); - - $defaultRouter - ->expects($this->never()) - ->method('generate') - ; - - $this->router->add($defaultRouter, 200); - - $this->router->generate($name, $parameters); - } - - /** - * A versatile router will generate the debug message. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateObjectNotFoundVersatile() - { - $name = new \stdClass(); - $parameters = array('test' => 'value'); - - $chainedRouter = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\VersatileRouter'); - $chainedRouter - ->expects($this->once()) - ->method('supports') - ->will($this->returnValue(true)) - ; - $chainedRouter->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->throwException(new RouteNotFoundException())) - ; - $chainedRouter->expects($this->once()) - ->method('getRouteDebugMessage') - ->with($name, $parameters) - ->will($this->returnValue('message')) - ; - - $this->router->add($chainedRouter, 10); - - $this->router->generate($name, $parameters); - } - - public function testGenerateObjectName() - { - $name = new \stdClass(); - $parameters = array('test' => 'value'); - - $defaultRouter = $this->getMock('Symfony\Component\Routing\RouterInterface'); - $chainedRouter = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\VersatileRouter'); - - $defaultRouter - ->expects($this->never()) - ->method('generate') - ; - $chainedRouter - ->expects($this->once()) - ->method('supports') - ->will($this->returnValue(true)) - ; - $chainedRouter - ->expects($this->once()) - ->method('generate') - ->with($name, $parameters, false) - ->will($this->returnValue($name)) - ; - - $this->router->add($defaultRouter, 200); - $this->router->add($chainedRouter, 100); - - $result = $this->router->generate($name, $parameters); - $this->assertEquals($name, $result); - } - - public function testWarmup() - { - $dir = 'test_dir'; - list($low) = $this->createRouterMocks(); - - $low - ->expects($this->never()) - ->method('warmUp') - ; - $high = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\WarmableRouterMock'); - $high - ->expects($this->once()) - ->method('warmUp') - ->with($dir) - ; - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $this->router->warmUp($dir); - } - - public function testRouteCollection() - { - list($low, $high) = $this->createRouterMocks(); - $lowcol = new RouteCollection(); - $lowcol->add('low', $this->buildMock('Symfony\Component\Routing\Route')); - $highcol = new RouteCollection(); - $highcol->add('high', $this->buildMock('Symfony\Component\Routing\Route')); - - $low - ->expects($this->once()) - ->method('getRouteCollection') - ->will($this->returnValue($lowcol)) - ; - $high - ->expects($this->once()) - ->method('getRouteCollection') - ->will($this->returnValue($highcol)) - ; - - $this->router->add($low, 10); - $this->router->add($high, 100); - - $collection = $this->router->getRouteCollection(); - $this->assertInstanceOf('Symfony\Component\Routing\RouteCollection', $collection); - - $names = array(); - foreach ($collection->all() as $name => $route) { - $this->assertInstanceOf('Symfony\Component\Routing\Route', $route); - $names[] = $name; - } - $this->assertEquals(array('high', 'low'), $names); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testSupport() - { - - $router = $this->getMock('Symfony\Cmf\Component\Routing\Tests\Routing\VersatileRouter'); - $router - ->expects($this->once()) - ->method('supports') - ->will($this->returnValue(false)) - ; - - $router - ->expects($this->never()) - ->method('generate') - ->will($this->returnValue(false)) - ; - - $this->router->add($router); - - $this->router->generate('foobar'); - } - - /** - * @return RouterInterface[]|\PHPUnit_Framework_MockObject_MockObject[] - */ - protected function createRouterMocks() - { - return array( - $this->getMock('Symfony\Component\Routing\RouterInterface'), - $this->getMock('Symfony\Component\Routing\RouterInterface'), - $this->getMock('Symfony\Component\Routing\RouterInterface'), - ); - } -} - -abstract class WarmableRouterMock implements RouterInterface, WarmableInterface -{ -} - -abstract class RequestMatcher implements RouterInterface, RequestMatcherInterface -{ -} - -abstract class VersatileRouter implements VersatileGeneratorInterface, RequestMatcherInterface -{ -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php b/vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php deleted file mode 100644 index 3d089747c..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php +++ /dev/null @@ -1,457 +0,0 @@ -contentDocument = $this->buildMock('Symfony\Cmf\Component\Routing\RouteReferrersReadInterface'); - $this->routeDocument = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile')); - $this->routeCompiled = $this->buildMock('Symfony\Component\Routing\CompiledRoute'); - $this->provider = $this->buildMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $this->context = $this->buildMock('Symfony\Component\Routing\RequestContext'); - - $this->generator = new TestableContentAwareGenerator($this->provider); - } - - public function testGenerateFromContent() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($this->routeDocument))) - ; - $this->routeDocument->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($this->contentDocument)); - } - - public function testGenerateFromContentId() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - - $contentRepository = $this->buildMock('Symfony\Cmf\Component\Routing\ContentRepositoryInterface', array('findById', 'getContentId')); - $contentRepository->expects($this->once()) - ->method('findById') - ->with('/content/id') - ->will($this->returnValue($this->contentDocument)) - ; - $this->generator->setContentRepository($contentRepository); - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($this->routeDocument))) - ; - - $this->routeDocument->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate('', array('content_id' => '/content/id'))); - } - - public function testGenerateEmptyRouteString() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($this->routeDocument))) - ; - - $this->routeDocument->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($this->contentDocument)); - } - - public function testGenerateRouteMultilang() - { - $route_en = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile', 'getContent')); - $route_en->setLocale('en'); - $route_de = $this->routeDocument; - $route_de->setLocale('de'); - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($route_en, $route_de))) - ; - $route_en->expects($this->once()) - ->method('getContent') - ->will($this->returnValue($this->contentDocument)) - ; - $route_en->expects($this->never()) - ->method('compile') - ; - $route_de->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($route_en, array('_locale' => 'de'))); - } - - public function testGenerateRouteMultilangDefaultLocale() - { - $route = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock'); - $route->expects($this->any()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - $route->expects($this->any()) - ->method('getRequirement') - ->with('_locale') - ->will($this->returnValue('de|en')) - ; - $route->expects($this->any()) - ->method('getDefault') - ->with('_locale') - ->will($this->returnValue('en')) - ; - $this->routeCompiled->expects($this->any()) - ->method('getVariables') - ->will($this->returnValue(array())) - ; - - $this->assertEquals('result_url', $this->generator->generate($route, array('_locale' => 'en'))); - } - - public function testGenerateRouteMultilangLocaleNomatch() - { - $route_en = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile', 'getContent')); - $route_en->setLocale('en'); - $route_de = $this->routeDocument; - $route_de->setLocale('de'); - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($route_en, $route_de))) - ; - $route_en->expects($this->once()) - ->method('getContent') - ->will($this->returnValue($this->contentDocument)) - ; - $route_en->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - $route_de->expects($this->never()) - ->method('compile') - ; - - $this->assertEquals('result_url', $this->generator->generate($route_en, array('_locale' => 'fr'))); - } - - public function testGenerateNoncmfRouteMultilang() - { - $route_en = $this->buildMock('Symfony\Component\Routing\Route', array('getDefaults', 'compile', 'getContent')); - - $route_en->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($route_en, array('_locale' => 'de'))); - } - - public function testGenerateRoutenameMultilang() - { - $name = 'foo/bar'; - $route_en = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile', 'getContent')); - $route_en->setLocale('en'); - $route_de = $this->routeDocument; - $route_de->setLocale('de'); - - $this->provider->expects($this->once()) - ->method('getRouteByName') - ->with($name) - ->will($this->returnValue($route_en)) - ; - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($route_en, $route_de))) - ; - $route_en->expects($this->once()) - ->method('getContent') - ->will($this->returnValue($this->contentDocument)) - ; - $route_en->expects($this->never()) - ->method('compile') - ; - $route_de->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($name, array('_locale' => 'de'))); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateRoutenameMultilangNotFound() - { - $name = 'foo/bar'; - - $this->provider->expects($this->once()) - ->method('getRouteByName') - ->with($name) - ->will($this->returnValue(null)) - ; - - $this->generator->generate($name, array('_locale' => 'de')); - } - - public function testGenerateDocumentMultilang() - { - $route_en = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile')); - $route_en->setLocale('en'); - $route_de = $this->routeDocument; - $route_de->setLocale('de'); - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($route_en, $route_de))) - ; - $route_en->expects($this->never()) - ->method('compile') - ; - $route_de->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($this->contentDocument, array('_locale' => 'de'))); - } - - public function testGenerateDocumentMultilangLocaleNomatch() - { - $route_en = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults', 'compile')); - $route_en->setLocale('en'); - $route_de = $this->routeDocument; - $route_de->setLocale('de'); - - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($route_en, $route_de))) - ; - $route_en->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - $route_de->expects($this->never()) - ->method('compile') - ; - - $this->assertEquals('result_url', $this->generator->generate($this->contentDocument, array('_locale' => 'fr'))); - } - - /** - * Generate without any information. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNoContent() - { - $this->generator->generate('', array()); - } - - /** - * Generate with an object that is neither a route nor route aware. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateInvalidContent() - { - $this->generator->generate($this); - } - - /** - * Generate with a content_id but there is no content repository. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNoContentRepository() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - - $this->generator->generate('', array('content_id' => '/content/id')); - } - - /** - * Generate with content_id but the content is not found. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNoContentFoundInRepository() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - - $contentRepository = $this->buildMock('Symfony\Cmf\Component\Routing\ContentRepositoryInterface', array('findById', 'getContentId')); - $contentRepository->expects($this->once()) - ->method('findById') - ->with('/content/id') - ->will($this->returnValue(null)) - ; - $this->generator->setContentRepository($contentRepository); - - $this->generator->generate('', array('content_id' => '/content/id')); - } - - /** - * Generate with content_id but the object at id is not route aware. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateWrongContentClassInRepository() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - - $contentRepository = $this->buildMock('Symfony\Cmf\Component\Routing\ContentRepositoryInterface', array('findById', 'getContentId')); - $contentRepository->expects($this->once()) - ->method('findById') - ->with('/content/id') - ->will($this->returnValue($this)) - ; - $this->generator->setContentRepository($contentRepository); - - $this->generator->generate('', array('content_id' => '/content/id')); - } - - /** - * Generate from a content that has no routes associated. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNoRoutes() - { - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array())); - - $this->generator->generate($this->contentDocument); - } - /** - * Generate from a content that returns something that is not a route as route. - * - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateInvalidRoute() - { - $this->contentDocument->expects($this->once()) - ->method('getRoutes') - ->will($this->returnValue(array($this))); - - $this->generator->generate($this->contentDocument); - } - - public function testGetLocaleAttribute() - { - $this->generator->setDefaultLocale('en'); - - $attributes = array('_locale' => 'fr'); - $this->assertEquals('fr', $this->generator->getLocale($attributes)); - } - - public function testGetLocaleDefault() - { - $this->generator->setDefaultLocale('en'); - - $attributes = array(); - $this->assertEquals('en', $this->generator->getLocale($attributes)); - } - - public function testGetLocaleContext() - { - $this->generator->setDefaultLocale('en'); - - $this->generator->getContext()->setParameter('_locale', 'de'); - - $attributes = array(); - $this->assertEquals('de', $this->generator->getLocale($attributes)); - } - - public function testSupports() - { - $this->assertTrue($this->generator->supports('')); - $this->assertTrue($this->generator->supports(null)); - $this->assertTrue($this->generator->supports($this->contentDocument)); - $this->assertFalse($this->generator->supports($this)); - } - - public function testGetRouteDebugMessage() - { - $this->assertContains('/some/content', $this->generator->getRouteDebugMessage(null, array('content_id' => '/some/content'))); - $this->assertContains('Route aware content Symfony\Cmf\Component\Routing\Tests\Routing\RouteAware', $this->generator->getRouteDebugMessage(new RouteAware())); - $this->assertContains('/some/content', $this->generator->getRouteDebugMessage('/some/content')); - } -} - -/** - * Overwrite doGenerate to reduce amount of mocking needed - */ -class TestableContentAwareGenerator extends ContentAwareGenerator -{ - protected function doGenerate($variables, $defaults, $requirements, $tokens, $parameters, $name, $referenceType, $hostTokens, array $requiredSchemes = array()) - { - return 'result_url'; - } - - // expose as public - public function getLocale($parameters) - { - return parent::getLocale($parameters); - } -} - -class RouteAware implements RouteReferrersReadInterface -{ - public function getRoutes() - { - return array(); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/DynamicRouterTest.php b/vendor/symfony-cmf/routing/Tests/Routing/DynamicRouterTest.php deleted file mode 100644 index f3e24e92f..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/DynamicRouterTest.php +++ /dev/null @@ -1,330 +0,0 @@ -routeDocument = $this->buildMock('Symfony\Cmf\Component\Routing\Tests\Routing\RouteMock', array('getDefaults')); - - $this->matcher = $this->buildMock('Symfony\Component\Routing\Matcher\UrlMatcherInterface'); - $this->generator = $this->buildMock('Symfony\Cmf\Component\Routing\VersatileGeneratorInterface', array('supports', 'generate', 'setContext', 'getContext', 'getRouteDebugMessage')); - $this->enhancer = $this->buildMock('Symfony\Cmf\Component\Routing\Enhancer\RouteEnhancerInterface', array('enhance')); - - $this->context = $this->buildMock('Symfony\Component\Routing\RequestContext'); - $this->request = Request::create($this->url); - - $this->router = new DynamicRouter($this->context, $this->matcher, $this->generator); - $this->router->addRouteEnhancer($this->enhancer); - } - - /** - * rather trivial, but we want 100% coverage - */ - public function testContext() - { - $this->router->setContext($this->context); - $this->assertSame($this->context, $this->router->getContext()); - } - - public function testRouteCollectionEmpty() - { - $collection = $this->router->getRouteCollection(); - $this->assertInstanceOf('Symfony\Component\Routing\RouteCollection', $collection); - } - - public function testRouteCollectionLazy() - { - $provider = $this->getMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $router = new DynamicRouter($this->context, $this->matcher, $this->generator, '', null, $provider); - - $collection = $router->getRouteCollection(); - $this->assertInstanceOf('Symfony\Cmf\Component\Routing\LazyRouteCollection', $collection); - } - - /// generator tests /// - - public function testGetGenerator() - { - $this->generator->expects($this->once()) - ->method('setContext') - ->with($this->equalTo($this->context)); - - $generator = $this->router->getGenerator(); - $this->assertInstanceOf('Symfony\Component\Routing\Generator\UrlGeneratorInterface', $generator); - $this->assertSame($this->generator, $generator); - } - - public function testGenerate() - { - $name = 'my_route_name'; - $parameters = array('foo' => 'bar'); - $absolute = true; - - $this->generator->expects($this->once()) - ->method('generate') - ->with($name, $parameters, $absolute) - ->will($this->returnValue('http://test')) - ; - - $url = $this->router->generate($name, $parameters, $absolute); - $this->assertEquals('http://test', $url); - } - - public function testSupports() - { - $name = 'foo/bar'; - $this->generator->expects($this->once()) - ->method('supports') - ->with($this->equalTo($name)) - ->will($this->returnValue(true)) - ; - - $this->assertTrue($this->router->supports($name)); - } - - public function testSupportsNonversatile() - { - $generator = $this->buildMock('Symfony\Component\Routing\Generator\UrlGeneratorInterface', array('generate', 'setContext', 'getContext')); - $router = new DynamicRouter($this->context, $this->matcher, $generator); - $this->assertInternalType('string', $router->getRouteDebugMessage('test')); - - $this->assertTrue($router->supports('some string')); - $this->assertFalse($router->supports($this)); - } - - /// match tests /// - - public function testGetMatcher() - { - $this->matcher->expects($this->once()) - ->method('setContext') - ->with($this->equalTo($this->context)); - - $matcher = $this->router->getMatcher(); - $this->assertInstanceOf('Symfony\Component\Routing\Matcher\UrlMatcherInterface', $matcher); - $this->assertSame($this->matcher, $matcher); - } - - public function testMatchUrl() - { - $routeDefaults = array('foo' => 'bar'); - $this->matcher->expects($this->once()) - ->method('match') - ->with($this->url) - ->will($this->returnValue($routeDefaults)) - ; - - $expected = array('this' => 'that'); - $this->enhancer->expects($this->once()) - ->method('enhance') - ->with($this->equalTo($routeDefaults), $this->equalTo($this->request)) - ->will($this->returnValue($expected)) - ; - - $results = $this->router->match($this->url); - - $this->assertEquals($expected, $results); - } - - public function testMatchRequestWithUrlMatcher() - { - $routeDefaults = array('foo' => 'bar'); - - $this->matcher->expects($this->once()) - ->method('match') - ->with($this->url) - ->will($this->returnValue($routeDefaults)) - ; - - $expected = array('this' => 'that'); - $this->enhancer->expects($this->once()) - ->method('enhance') - // somehow request object gets confused, check on instance only - ->with($this->equalTo($routeDefaults), $this->isInstanceOf('Symfony\Component\HttpFoundation\Request')) - ->will($this->returnValue($expected)) - ; - - $results = $this->router->matchRequest($this->request); - - $this->assertEquals($expected, $results); - } - - public function testMatchRequest() - { - $routeDefaults = array('foo' => 'bar'); - - $matcher = $this->buildMock('Symfony\Component\Routing\Matcher\RequestMatcherInterface', array('matchRequest', 'setContext', 'getContext')); - $router = new DynamicRouter($this->context, $matcher, $this->generator); - - $matcher->expects($this->once()) - ->method('matchRequest') - ->with($this->request) - ->will($this->returnValue($routeDefaults)) - ; - - $expected = array('this' => 'that'); - $this->enhancer->expects($this->once()) - ->method('enhance') - ->with($this->equalTo($routeDefaults), $this->equalTo($this->request)) - ->will($this->returnValue($expected)) - ; - - $router->addRouteEnhancer($this->enhancer); - - $this->assertEquals($expected, $router->matchRequest($this->request)); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\ResourceNotFoundException - */ - public function testMatchFilter() - { - $router = new DynamicRouter($this->context, $this->matcher, $this->generator, '#/different/prefix.*#'); - $router->addRouteEnhancer($this->enhancer); - - $this->matcher->expects($this->never()) - ->method('match') - ; - - $this->enhancer->expects($this->never()) - ->method('enhance') - ; - - $router->match($this->url); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\ResourceNotFoundException - */ - public function testMatchRequestFilter() - { - $matcher = $this->buildMock('Symfony\Component\Routing\Matcher\RequestMatcherInterface', array('matchRequest', 'setContext', 'getContext')); - - $router = new DynamicRouter($this->context, $matcher, $this->generator, '#/different/prefix.*#'); - $router->addRouteEnhancer($this->enhancer); - - $matcher->expects($this->never()) - ->method('matchRequest') - ; - - $this->enhancer->expects($this->never()) - ->method('enhance') - ; - - $router->matchRequest($this->request); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testMatchUrlWithRequestMatcher() - { - $matcher = $this->buildMock('Symfony\Component\Routing\Matcher\RequestMatcherInterface', array('matchRequest', 'setContext', 'getContext')); - $router = new DynamicRouter($this->context, $matcher, $this->generator); - - $router->match($this->url); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testInvalidMatcher() - { - new DynamicRouter($this->context, $this, $this->generator); - } - - public function testRouteDebugMessage() - { - $this->generator->expects($this->once()) - ->method('getRouteDebugMessage') - ->with($this->equalTo('test'), $this->equalTo(array())) - ->will($this->returnValue('debug message')) - ; - - $this->assertEquals('debug message', $this->router->getRouteDebugMessage('test')); - } - - public function testRouteDebugMessageNonversatile() - { - $generator = $this->buildMock('Symfony\Component\Routing\Generator\UrlGeneratorInterface', array('generate', 'setContext', 'getContext')); - $router = new DynamicRouter($this->context, $this->matcher, $generator); - $this->assertInternalType('string', $router->getRouteDebugMessage('test')); - } - - public function testEventHandler() - { - $eventDispatcher = $this->buildMock('Symfony\Component\EventDispatcher\EventDispatcherInterface'); - $router = new DynamicRouter($this->context, $this->matcher, $this->generator, '', $eventDispatcher); - - $eventDispatcher->expects($this->once()) - ->method('dispatch') - ->with(Events::PRE_DYNAMIC_MATCH, $this->equalTo(new RouterMatchEvent())) - ; - - $routeDefaults = array('foo' => 'bar'); - $this->matcher->expects($this->once()) - ->method('match') - ->with($this->url) - ->will($this->returnValue($routeDefaults)) - ; - - $this->assertEquals($routeDefaults, $router->match($this->url)); - } - - public function testEventHandlerRequest() - { - $eventDispatcher = $this->buildMock('Symfony\Component\EventDispatcher\EventDispatcherInterface'); - $router = new DynamicRouter($this->context, $this->matcher, $this->generator, '', $eventDispatcher); - - $that = $this; - $eventDispatcher->expects($this->once()) - ->method('dispatch') - ->with(Events::PRE_DYNAMIC_MATCH_REQUEST, $this->callback(function ($event) use ($that) { - $that->assertInstanceOf('Symfony\Cmf\Component\Routing\Event\RouterMatchEvent', $event); - $that->assertEquals($that->request, $event->getRequest()); - - return true; - })) - ; - - $routeDefaults = array('foo' => 'bar'); - $this->matcher->expects($this->once()) - ->method('match') - ->with($this->url) - ->will($this->returnValue($routeDefaults)) - ; - - $this->assertEquals($routeDefaults, $router->matchRequest($this->request)); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/LazyRouteCollectionTest.php b/vendor/symfony-cmf/routing/Tests/Routing/LazyRouteCollectionTest.php deleted file mode 100644 index 95d3ad227..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/LazyRouteCollectionTest.php +++ /dev/null @@ -1,42 +0,0 @@ -getMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $testRoutes = array( - 'route_1' => new Route('/route-1'), - 'route_2"' => new Route('/route-2'), - ); - $routeProvider->expects($this->exactly(2)) - ->method('getRoutesByNames') - ->with(null) - ->will($this->returnValue($testRoutes)); - $lazyRouteCollection = new LazyRouteCollection($routeProvider); - $this->assertEquals($testRoutes, iterator_to_array($lazyRouteCollection->getIterator())); - $this->assertEquals($testRoutes, $lazyRouteCollection->all()); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/PagedRouteCollectionTest.php b/vendor/symfony-cmf/routing/Tests/Routing/PagedRouteCollectionTest.php deleted file mode 100644 index 741beaa53..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/PagedRouteCollectionTest.php +++ /dev/null @@ -1,132 +0,0 @@ -routeProvider = $this->getMock('Symfony\Cmf\Component\Routing\PagedRouteProviderInterface'); - } - - /** - * Tests iterating a small amount of routes. - * - * @dataProvider providerIterator - */ - public function testIterator($amountRoutes, $routesLoadedInParallel, $expectedCalls = array()) - { - $routes = array(); - for ($i = 0; $i < $amountRoutes; $i++) { - $routes['test_' . $i] = new Route("/example-$i"); - } - $names = array_keys($routes); - - foreach ($expectedCalls as $i => $range) - { - $this->routeProvider->expects($this->at($i)) - ->method('getRoutesPaged') - ->with($range[0], $range[1]) - ->will($this->returnValue(array_slice($routes, $range[0], $range[1]))); - } - - $route_collection = new PagedRouteCollection($this->routeProvider, $routesLoadedInParallel); - - $counter = 0; - foreach ($route_collection as $route_name => $route) { - // Ensure the route did not changed. - $this->assertEquals($routes[$route_name], $route); - // Ensure that the order did not changed. - $this->assertEquals($route_name, $names[$counter]); - $counter++; - } - } - - /** - * Provides test data for testIterator(). - */ - public function providerIterator() - { - $data = array(); - // Non total routes. - $data[] = array(0, 20, array(array(0, 20))); - // Less total routes than loaded in parallel. - $data[] = array(10, 20, array(array(0, 20))); - // Exact the same amount of routes then loaded in parallel. - $data[] = array(20, 20, array(array(0, 20), array(20, 20))); - // Less than twice the amount. - $data[] = array(39, 20, array(array(0, 20), array(20, 20))); - // More total routes than loaded in parallel. - $data[] = array(40, 20, array(array(0, 20), array(20, 20), array(40, 20))); - $data[] = array(41, 20, array(array(0, 20), array(20, 20), array(40, 20))); - // why not. - $data[] = array(42, 23, array(array(0, 23), array(23, 23))); - return $data; - } - - /** - * Tests the count() method. - */ - public function testCount() - { - $this->routeProvider->expects($this->once()) - ->method('getRoutesCount') - ->will($this->returnValue(12)); - $routeCollection = new PagedRouteCollection($this->routeProvider); - $this->assertEquals(12, $routeCollection->count()); - } - - /** - * Tests the rewind method once the iterator is at the end. - */ - public function testIteratingAndRewind() - { - $routes = array(); - for ($i = 0; $i < 30; $i++) { - $routes['test_' . $i] = new Route("/example-$i"); - } - $this->routeProvider->expects($this->any()) - ->method('getRoutesPaged') - ->will($this->returnValueMap(array( - array(0, 10, array_slice($routes, 0, 10)), - array(10, 10, array_slice($routes, 9, 10)), - array(20, 10, array()), - ))); - - $routeCollection = new PagedRouteCollection($this->routeProvider, 10); - - // Force the iterating process. - $routeCollection->rewind(); - for ($i = 0; $i < 29; $i++) { - $routeCollection->next(); - } - $routeCollection->rewind(); - - $this->assertEquals('test_0', $routeCollection->key()); - $this->assertEquals($routes['test_0'], $routeCollection->current()); - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/ProviderBasedGeneratorTest.php b/vendor/symfony-cmf/routing/Tests/Routing/ProviderBasedGeneratorTest.php deleted file mode 100644 index 955f9fc54..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/ProviderBasedGeneratorTest.php +++ /dev/null @@ -1,149 +0,0 @@ -routeDocument = $this->buildMock('Symfony\Component\Routing\Route', array('getDefaults', 'compile')); - $this->routeCompiled = $this->buildMock('Symfony\Component\Routing\CompiledRoute'); - $this->provider = $this->buildMock('Symfony\Cmf\Component\Routing\RouteProviderInterface'); - $this->context = $this->buildMock('Symfony\Component\Routing\RequestContext'); - - $this->generator= new TestableProviderBasedGenerator($this->provider); - } - - public function testGenerateFromName() - { - $name = 'foo/bar'; - - $this->provider->expects($this->once()) - ->method('getRouteByName') - ->with($name) - ->will($this->returnValue($this->routeDocument)) - ; - $this->routeDocument->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($name)); - } - - /** - * @expectedException \Symfony\Component\Routing\Exception\RouteNotFoundException - */ - public function testGenerateNotFound() - { - $name = 'foo/bar'; - - $this->provider->expects($this->once()) - ->method('getRouteByName') - ->with($name) - ->will($this->returnValue(null)) - ; - - $this->generator->generate($name); - } - - public function testGenerateFromRoute() - { - $this->provider->expects($this->never()) - ->method('getRouteByName') - ; - $this->routeDocument->expects($this->once()) - ->method('compile') - ->will($this->returnValue($this->routeCompiled)) - ; - - $this->assertEquals('result_url', $this->generator->generate($this->routeDocument)); - } - - public function testSupports() - { - $this->assertTrue($this->generator->supports('foo/bar')); - $this->assertTrue($this->generator->supports($this->routeDocument)); - $this->assertFalse($this->generator->supports($this)); - } - - public function testGetRouteDebugMessage() - { - $this->assertContains('/some/key', $this->generator->getRouteDebugMessage(new RouteObject())); - $this->assertContains('/de/test', $this->generator->getRouteDebugMessage(new Route('/de/test'))); - $this->assertContains('/some/route', $this->generator->getRouteDebugMessage('/some/route')); - $this->assertContains('a:1:{s:10:"route_name";s:7:"example";}', $this->generator->getRouteDebugMessage(array('route_name' => 'example'))); - } - - /** - * Tests the generate method with passing in a route object into generate(). - * - * @expectedException \Symfony\Component\Routing\Exception\InvalidParameterException - */ - public function testGenerateByRoute() - { - $this->generator = new ProviderBasedGenerator($this->provider); - - // Setup a route with a numeric parameter, but pass in a string, so it - // fails and getRouteDebugMessage should be triggered. - $route = new Route('/test'); - $route->setPath('/test/{number}'); - $route->setRequirement('number', '\+d'); - - $this->generator->setStrictRequirements(true); - - $context = new RequestContext(); - $this->generator->setContext($context); - - $this->assertSame(null, $this->generator->generate($route, array('number' => 'string'))); - - } -} - -/** - * Overwrite doGenerate to reduce amount of mocking needed - */ -class TestableProviderBasedGenerator extends ProviderBasedGenerator -{ - protected function doGenerate($variables, $defaults, $requirements, $tokens, $parameters, $name, $referenceType, $hostTokens, array $requiredSchemes = array()) - { - return 'result_url'; - } -} - -class RouteObject implements RouteObjectInterface -{ - public function getRouteKey() - { - return '/some/key'; - } - - public function getContent() - { - return null; - } -} diff --git a/vendor/symfony-cmf/routing/Tests/Routing/RouteMock.php b/vendor/symfony-cmf/routing/Tests/Routing/RouteMock.php deleted file mode 100644 index 7b1440a2a..000000000 --- a/vendor/symfony-cmf/routing/Tests/Routing/RouteMock.php +++ /dev/null @@ -1,55 +0,0 @@ -locale = $locale; - } - - public function getContent() - { - return null; - } - - public function getDefaults() - { - $defaults = array(); - if (! is_null($this->locale)) { - $defaults['_locale'] = $this->locale; - } - - return $defaults; - } - - public function getRequirement($key) - { - if (! $key == '_locale') { - throw new \Exception; - } - - return $this->locale; - } - - public function getRouteKey() - { - return null; - } -} diff --git a/vendor/symfony-cmf/routing/Tests/bootstrap.php b/vendor/symfony-cmf/routing/Tests/bootstrap.php deleted file mode 100644 index 157e59fbf..000000000 --- a/vendor/symfony-cmf/routing/Tests/bootstrap.php +++ /dev/null @@ -1,20 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\Client; -use Symfony\Component\BrowserKit\History; -use Symfony\Component\BrowserKit\CookieJar; -use Symfony\Component\BrowserKit\Response; - -class SpecialResponse extends Response -{ -} - -class TestClient extends Client -{ - protected $nextResponse = null; - protected $nextScript = null; - - public function setNextResponse(Response $response) - { - $this->nextResponse = $response; - } - - public function setNextScript($script) - { - $this->nextScript = $script; - } - - protected function doRequest($request) - { - if (null === $this->nextResponse) { - return new Response(); - } - - $response = $this->nextResponse; - $this->nextResponse = null; - - return $response; - } - - protected function filterResponse($response) - { - if ($response instanceof SpecialResponse) { - return new Response($response->getContent(), $response->getStatus(), $response->getHeaders()); - } - - return $response; - } - - protected function getScript($request) - { - $r = new \ReflectionClass('Symfony\Component\BrowserKit\Response'); - $path = $r->getFileName(); - - return <<nextScript); -EOF; - } -} - -class ClientTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\BrowserKit\Client::getHistory - */ - public function testGetHistory() - { - $client = new TestClient(array(), $history = new History()); - $this->assertSame($history, $client->getHistory(), '->getHistory() returns the History'); - } - - /** - * @covers Symfony\Component\BrowserKit\Client::getCookieJar - */ - public function testGetCookieJar() - { - $client = new TestClient(array(), null, $cookieJar = new CookieJar()); - $this->assertSame($cookieJar, $client->getCookieJar(), '->getCookieJar() returns the CookieJar'); - } - - /** - * @covers Symfony\Component\BrowserKit\Client::getRequest - */ - public function testGetRequest() - { - $client = new TestClient(); - $client->request('GET', 'http://example.com/'); - - $this->assertEquals('http://example.com/', $client->getRequest()->getUri(), '->getCrawler() returns the Request of the last request'); - } - - public function testGetRequestWithIpAsHost() - { - $client = new TestClient(); - $client->request('GET', 'https://example.com/foo', array(), array(), array('HTTP_HOST' => '127.0.0.1')); - - $this->assertEquals('https://127.0.0.1/foo', $client->getRequest()->getUri()); - } - - public function testGetResponse() - { - $client = new TestClient(); - $client->setNextResponse(new Response('foo')); - $client->request('GET', 'http://example.com/'); - - $this->assertEquals('foo', $client->getResponse()->getContent(), '->getCrawler() returns the Response of the last request'); - $this->assertInstanceOf('Symfony\Component\BrowserKit\Response', $client->getResponse(), '->getCrawler() returns the Response of the last request'); - } - - public function testGetInternalResponse() - { - $client = new TestClient(); - $client->setNextResponse(new SpecialResponse('foo')); - $client->request('GET', 'http://example.com/'); - - $this->assertInstanceOf('Symfony\Component\BrowserKit\Response', $client->getInternalResponse()); - $this->assertNotInstanceOf('Symfony\Component\BrowserKit\Tests\SpecialResponse', $client->getInternalResponse()); - $this->assertInstanceOf('Symfony\Component\BrowserKit\Tests\SpecialResponse', $client->getResponse()); - } - - public function testGetContent() - { - $json = '{"jsonrpc":"2.0","method":"echo","id":7,"params":["Hello World"]}'; - - $client = new TestClient(); - $client->request('POST', 'http://example.com/jsonrpc', array(), array(), array(), $json); - $this->assertEquals($json, $client->getRequest()->getContent()); - } - - /** - * @covers Symfony\Component\BrowserKit\Client::getCrawler - */ - public function testGetCrawler() - { - $client = new TestClient(); - $client->setNextResponse(new Response('foo')); - $crawler = $client->request('GET', 'http://example.com/'); - - $this->assertSame($crawler, $client->getCrawler(), '->getCrawler() returns the Crawler of the last request'); - } - - public function testRequestHttpHeaders() - { - $client = new TestClient(); - $client->request('GET', '/'); - $headers = $client->getRequest()->getServer(); - $this->assertEquals('localhost', $headers['HTTP_HOST'], '->request() sets the HTTP_HOST header'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com'); - $headers = $client->getRequest()->getServer(); - $this->assertEquals('www.example.com', $headers['HTTP_HOST'], '->request() sets the HTTP_HOST header'); - - $client->request('GET', 'https://www.example.com'); - $headers = $client->getRequest()->getServer(); - $this->assertTrue($headers['HTTPS'], '->request() sets the HTTPS header'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com:8080'); - $headers = $client->getRequest()->getServer(); - $this->assertEquals('www.example.com:8080', $headers['HTTP_HOST'], '->request() sets the HTTP_HOST header with port'); - } - - public function testRequestURIConversion() - { - $client = new TestClient(); - $client->request('GET', '/foo'); - $this->assertEquals('http://localhost/foo', $client->getRequest()->getUri(), '->request() converts the URI to an absolute one'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com'); - $this->assertEquals('http://www.example.com', $client->getRequest()->getUri(), '->request() does not change absolute URIs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/'); - $client->request('GET', '/foo'); - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo'); - $client->request('GET', '#'); - $this->assertEquals('http://www.example.com/foo#', $client->getRequest()->getUri(), '->request() uses the previous request for #'); - $client->request('GET', '#'); - $this->assertEquals('http://www.example.com/foo#', $client->getRequest()->getUri(), '->request() uses the previous request for #'); - $client->request('GET', '#foo'); - $this->assertEquals('http://www.example.com/foo#foo', $client->getRequest()->getUri(), '->request() uses the previous request for #'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/'); - $client->request('GET', 'bar'); - $this->assertEquals('http://www.example.com/foo/bar', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->request('GET', 'bar'); - $this->assertEquals('http://www.example.com/foo/bar', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/'); - $client->request('GET', 'http'); - $this->assertEquals('http://www.example.com/foo/http', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo'); - $client->request('GET', 'http/bar'); - $this->assertEquals('http://www.example.com/http/bar', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/'); - $client->request('GET', 'http'); - $this->assertEquals('http://www.example.com/http', $client->getRequest()->getUri(), '->request() uses the previous request for relative URLs'); - } - - public function testRequestURIConversionByServerHost() - { - $client = new TestClient(); - - $server = array('HTTP_HOST' => 'www.exampl+e.com:8000'); - $parameters = array(); - $files = array(); - - $client->request('GET', 'http://exampl+e.com', $parameters, $files, $server); - $this->assertEquals('http://www.exampl+e.com:8000', $client->getRequest()->getUri(), '->request() uses HTTP_HOST to add port'); - - $client->request('GET', 'http://exampl+e.com:8888', $parameters, $files, $server); - $this->assertEquals('http://www.exampl+e.com:8000', $client->getRequest()->getUri(), '->request() uses HTTP_HOST to modify existing port'); - - $client->request('GET', 'http://exampl+e.com:8000', $parameters, $files, $server); - $this->assertEquals('http://www.exampl+e.com:8000', $client->getRequest()->getUri(), '->request() uses HTTP_HOST respects correct set port'); - } - - public function testRequestReferer() - { - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->request('GET', 'bar'); - $server = $client->getRequest()->getServer(); - $this->assertEquals('http://www.example.com/foo/foobar', $server['HTTP_REFERER'], '->request() sets the referer'); - } - - public function testRequestHistory() - { - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->request('GET', 'bar'); - - $this->assertEquals('http://www.example.com/foo/bar', $client->getHistory()->current()->getUri(), '->request() updates the History'); - $this->assertEquals('http://www.example.com/foo/foobar', $client->getHistory()->back()->getUri(), '->request() updates the History'); - } - - public function testRequestCookies() - { - $client = new TestClient(); - $client->setNextResponse(new Response('foo', 200, array('Set-Cookie' => 'foo=bar'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->assertEquals(array('foo' => 'bar'), $client->getCookieJar()->allValues('http://www.example.com/foo/foobar'), '->request() updates the CookieJar'); - - $client->request('GET', 'bar'); - $this->assertEquals(array('foo' => 'bar'), $client->getCookieJar()->allValues('http://www.example.com/foo/foobar'), '->request() updates the CookieJar'); - } - - public function testRequestSecureCookies() - { - $client = new TestClient(); - $client->setNextResponse(new Response('foo', 200, array('Set-Cookie' => 'foo=bar; path=/; secure'))); - $client->request('GET', 'https://www.example.com/foo/foobar'); - - $this->assertTrue($client->getCookieJar()->get('foo', '/', 'www.example.com')->isSecure()); - } - - public function testClick() - { - $client = new TestClient(); - $client->setNextResponse(new Response('foo')); - $crawler = $client->request('GET', 'http://www.example.com/foo/foobar'); - - $client->click($crawler->filter('a')->link()); - - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->click() clicks on links'); - } - - public function testClickForm() - { - $client = new TestClient(); - $client->setNextResponse(new Response('
    ')); - $crawler = $client->request('GET', 'http://www.example.com/foo/foobar'); - - $client->click($crawler->filter('input')->form()); - - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->click() Form submit forms'); - } - - public function testSubmit() - { - $client = new TestClient(); - $client->setNextResponse(new Response('
    ')); - $crawler = $client->request('GET', 'http://www.example.com/foo/foobar'); - - $client->submit($crawler->filter('input')->form()); - - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->submit() submit forms'); - } - - public function testSubmitPreserveAuth() - { - $client = new TestClient(array('PHP_AUTH_USER' => 'foo', 'PHP_AUTH_PW' => 'bar')); - $client->setNextResponse(new Response('
    ')); - $crawler = $client->request('GET', 'http://www.example.com/foo/foobar'); - - $server = $client->getRequest()->getServer(); - $this->assertArrayHasKey('PHP_AUTH_USER', $server); - $this->assertEquals('foo', $server['PHP_AUTH_USER']); - $this->assertArrayHasKey('PHP_AUTH_PW', $server); - $this->assertEquals('bar', $server['PHP_AUTH_PW']); - - $client->submit($crawler->filter('input')->form()); - - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->submit() submit forms'); - - $server = $client->getRequest()->getServer(); - $this->assertArrayHasKey('PHP_AUTH_USER', $server); - $this->assertEquals('foo', $server['PHP_AUTH_USER']); - $this->assertArrayHasKey('PHP_AUTH_PW', $server); - $this->assertEquals('bar', $server['PHP_AUTH_PW']); - } - - public function testFollowRedirect() - { - $client = new TestClient(); - $client->followRedirects(false); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - try { - $client->followRedirect(); - $this->fail('->followRedirect() throws a \LogicException if the request was not redirected'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->followRedirect() throws a \LogicException if the request was not redirected'); - } - - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->followRedirect(); - - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() follows a redirect if any'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() automatically follows redirects if followRedirects is true'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 201, array('Location' => 'http://www.example.com/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - $this->assertEquals('http://www.example.com/foo/foobar', $client->getRequest()->getUri(), '->followRedirect() does not follow redirect if HTTP Code is not 30x'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 201, array('Location' => 'http://www.example.com/redirected'))); - $client->followRedirects(false); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - try { - $client->followRedirect(); - $this->fail('->followRedirect() throws a \LogicException if the request did not respond with 30x HTTP Code'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->followRedirect() throws a \LogicException if the request did not respond with 30x HTTP Code'); - } - } - - public function testFollowRelativeRedirect() - { - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array('Location' => '/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() follows a redirect if any'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array('Location' => '/redirected:1234'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->assertEquals('http://www.example.com/redirected:1234', $client->getRequest()->getUri(), '->followRedirect() follows relative urls'); - } - - public function testFollowRedirectWithMaxRedirects() - { - $client = new TestClient(); - $client->setMaxRedirects(1); - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() follows a redirect if any'); - - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected2'))); - try { - $client->followRedirect(); - $this->fail('->followRedirect() throws a \LogicException if the request was redirected and limit of redirections was reached'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->followRedirect() throws a \LogicException if the request was redirected and limit of redirections was reached'); - } - - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() follows a redirect if any'); - - $client->setNextResponse(new Response('', 302, array('Location' => '/redirected'))); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - $this->assertEquals('http://www.example.com/redirected', $client->getRequest()->getUri(), '->followRedirect() follows relative URLs'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array('Location' => '//www.example.org/'))); - $client->request('GET', 'https://www.example.com/'); - - $this->assertEquals('https://www.example.org/', $client->getRequest()->getUri(), '->followRedirect() follows protocol-relative URLs'); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array('Location' => 'http://www.example.com/redirected'))); - $client->request('POST', 'http://www.example.com/foo/foobar', array('name' => 'bar')); - - $this->assertEquals('get', $client->getRequest()->getMethod(), '->followRedirect() uses a get for 302'); - $this->assertEquals(array(), $client->getRequest()->getParameters(), '->followRedirect() does not submit parameters when changing the method'); - } - - public function testFollowRedirectWithCookies() - { - $client = new TestClient(); - $client->followRedirects(false); - $client->setNextResponse(new Response('', 302, array( - 'Location' => 'http://www.example.com/redirected', - 'Set-Cookie' => 'foo=bar', - ))); - $client->request('GET', 'http://www.example.com/'); - $this->assertEquals(array(), $client->getRequest()->getCookies()); - $client->followRedirect(); - $this->assertEquals(array('foo' => 'bar'), $client->getRequest()->getCookies()); - } - - public function testFollowRedirectWithHeaders() - { - $headers = array( - 'HTTP_HOST' => 'www.example.com', - 'HTTP_USER_AGENT' => 'Symfony2 BrowserKit', - 'CONTENT_TYPE' => 'application/vnd.custom+xml', - 'HTTPS' => false, - ); - - $client = new TestClient(); - $client->followRedirects(false); - $client->setNextResponse(new Response('', 302, array( - 'Location' => 'http://www.example.com/redirected', - ))); - $client->request('GET', 'http://www.example.com/', array(), array(), array( - 'CONTENT_TYPE' => 'application/vnd.custom+xml', - )); - - $this->assertEquals($headers, $client->getRequest()->getServer()); - - $client->followRedirect(); - - $headers['HTTP_REFERER'] = 'http://www.example.com/'; - - $this->assertEquals($headers, $client->getRequest()->getServer()); - } - - public function testFollowRedirectWithPort() - { - $headers = array( - 'HTTP_HOST' => 'www.example.com:8080', - 'HTTP_USER_AGENT' => 'Symfony2 BrowserKit', - 'HTTPS' => false, - 'HTTP_REFERER' => 'http://www.example.com:8080/', - ); - - $client = new TestClient(); - $client->setNextResponse(new Response('', 302, array( - 'Location' => 'http://www.example.com:8080/redirected', - ))); - $client->request('GET', 'http://www.example.com:8080/'); - - $this->assertEquals($headers, $client->getRequest()->getServer()); - } - - public function testBack() - { - $client = new TestClient(); - - $parameters = array('foo' => 'bar'); - $files = array('myfile.foo' => 'baz'); - $server = array('X_TEST_FOO' => 'bazbar'); - $content = 'foobarbaz'; - - $client->request('GET', 'http://www.example.com/foo/foobar', $parameters, $files, $server, $content); - $client->request('GET', 'http://www.example.com/foo'); - $client->back(); - - $this->assertEquals('http://www.example.com/foo/foobar', $client->getRequest()->getUri(), '->back() goes back in the history'); - $this->assertArrayHasKey('foo', $client->getRequest()->getParameters(), '->back() keeps parameters'); - $this->assertArrayHasKey('myfile.foo', $client->getRequest()->getFiles(), '->back() keeps files'); - $this->assertArrayHasKey('X_TEST_FOO', $client->getRequest()->getServer(), '->back() keeps $_SERVER'); - $this->assertEquals($content, $client->getRequest()->getContent(), '->back() keeps content'); - } - - public function testForward() - { - $client = new TestClient(); - - $parameters = array('foo' => 'bar'); - $files = array('myfile.foo' => 'baz'); - $server = array('X_TEST_FOO' => 'bazbar'); - $content = 'foobarbaz'; - - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->request('GET', 'http://www.example.com/foo', $parameters, $files, $server, $content); - $client->back(); - $client->forward(); - - $this->assertEquals('http://www.example.com/foo', $client->getRequest()->getUri(), '->forward() goes forward in the history'); - $this->assertArrayHasKey('foo', $client->getRequest()->getParameters(), '->forward() keeps parameters'); - $this->assertArrayHasKey('myfile.foo', $client->getRequest()->getFiles(), '->forward() keeps files'); - $this->assertArrayHasKey('X_TEST_FOO', $client->getRequest()->getServer(), '->forward() keeps $_SERVER'); - $this->assertEquals($content, $client->getRequest()->getContent(), '->forward() keeps content'); - } - - public function testReload() - { - $client = new TestClient(); - - $parameters = array('foo' => 'bar'); - $files = array('myfile.foo' => 'baz'); - $server = array('X_TEST_FOO' => 'bazbar'); - $content = 'foobarbaz'; - - $client->request('GET', 'http://www.example.com/foo/foobar', $parameters, $files, $server, $content); - $client->reload(); - - $this->assertEquals('http://www.example.com/foo/foobar', $client->getRequest()->getUri(), '->reload() reloads the current page'); - $this->assertArrayHasKey('foo', $client->getRequest()->getParameters(), '->reload() keeps parameters'); - $this->assertArrayHasKey('myfile.foo', $client->getRequest()->getFiles(), '->reload() keeps files'); - $this->assertArrayHasKey('X_TEST_FOO', $client->getRequest()->getServer(), '->reload() keeps $_SERVER'); - $this->assertEquals($content, $client->getRequest()->getContent(), '->reload() keeps content'); - } - - public function testRestart() - { - $client = new TestClient(); - $client->request('GET', 'http://www.example.com/foo/foobar'); - $client->restart(); - - $this->assertTrue($client->getHistory()->isEmpty(), '->restart() clears the history'); - $this->assertEquals(array(), $client->getCookieJar()->all(), '->restart() clears the cookies'); - } - - public function testInsulatedRequests() - { - $client = new TestClient(); - $client->insulate(); - $client->setNextScript("new Symfony\Component\BrowserKit\Response('foobar')"); - $client->request('GET', 'http://www.example.com/foo/foobar'); - - $this->assertEquals('foobar', $client->getResponse()->getContent(), '->insulate() process the request in a forked process'); - - $client->setNextScript("new Symfony\Component\BrowserKit\Response('foobar)"); - - try { - $client->request('GET', 'http://www.example.com/foo/foobar'); - $this->fail('->request() throws a \RuntimeException if the script has an error'); - } catch (\Exception $e) { - $this->assertInstanceOf('RuntimeException', $e, '->request() throws a \RuntimeException if the script has an error'); - } - } - - public function testGetServerParameter() - { - $client = new TestClient(); - $this->assertEquals('localhost', $client->getServerParameter('HTTP_HOST')); - $this->assertEquals('Symfony2 BrowserKit', $client->getServerParameter('HTTP_USER_AGENT')); - $this->assertEquals('testvalue', $client->getServerParameter('testkey', 'testvalue')); - } - - public function testSetServerParameter() - { - $client = new TestClient(); - - $this->assertEquals('localhost', $client->getServerParameter('HTTP_HOST')); - $this->assertEquals('Symfony2 BrowserKit', $client->getServerParameter('HTTP_USER_AGENT')); - - $client->setServerParameter('HTTP_HOST', 'testhost'); - $this->assertEquals('testhost', $client->getServerParameter('HTTP_HOST')); - - $client->setServerParameter('HTTP_USER_AGENT', 'testua'); - $this->assertEquals('testua', $client->getServerParameter('HTTP_USER_AGENT')); - } - - public function testSetServerParameterInRequest() - { - $client = new TestClient(); - - $this->assertEquals('localhost', $client->getServerParameter('HTTP_HOST')); - $this->assertEquals('Symfony2 BrowserKit', $client->getServerParameter('HTTP_USER_AGENT')); - - $client->request('GET', 'https://www.example.com/https/www.example.com', array(), array(), array( - 'HTTP_HOST' => 'testhost', - 'HTTP_USER_AGENT' => 'testua', - 'HTTPS' => false, - 'NEW_SERVER_KEY' => 'new-server-key-value', - )); - - $this->assertEquals('localhost', $client->getServerParameter('HTTP_HOST')); - $this->assertEquals('Symfony2 BrowserKit', $client->getServerParameter('HTTP_USER_AGENT')); - - $this->assertEquals('http://testhost/https/www.example.com', $client->getRequest()->getUri()); - - $server = $client->getRequest()->getServer(); - - $this->assertArrayHasKey('HTTP_USER_AGENT', $server); - $this->assertEquals('testua', $server['HTTP_USER_AGENT']); - - $this->assertArrayHasKey('HTTP_HOST', $server); - $this->assertEquals('testhost', $server['HTTP_HOST']); - - $this->assertArrayHasKey('NEW_SERVER_KEY', $server); - $this->assertEquals('new-server-key-value', $server['NEW_SERVER_KEY']); - - $this->assertArrayHasKey('HTTPS', $server); - $this->assertFalse($server['HTTPS']); - } -} diff --git a/vendor/symfony/browser-kit/Tests/CookieJarTest.php b/vendor/symfony/browser-kit/Tests/CookieJarTest.php deleted file mode 100644 index 4da4404e2..000000000 --- a/vendor/symfony/browser-kit/Tests/CookieJarTest.php +++ /dev/null @@ -1,231 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\CookieJar; -use Symfony\Component\BrowserKit\Cookie; -use Symfony\Component\BrowserKit\Response; - -class CookieJarTest extends \PHPUnit_Framework_TestCase -{ - public function testSetGet() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie = new Cookie('foo', 'bar')); - - $this->assertEquals($cookie, $cookieJar->get('foo'), '->set() sets a cookie'); - - $this->assertNull($cookieJar->get('foobar'), '->get() returns null if the cookie does not exist'); - - $cookieJar->set($cookie = new Cookie('foo', 'bar', time() - 86400)); - $this->assertNull($cookieJar->get('foo'), '->get() returns null if the cookie is expired'); - } - - public function testExpire() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie = new Cookie('foo', 'bar')); - $cookieJar->expire('foo'); - $this->assertNull($cookieJar->get('foo'), '->get() returns null if the cookie is expired'); - } - - public function testAll() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar')); - $cookieJar->set($cookie2 = new Cookie('bar', 'foo')); - - $this->assertEquals(array($cookie1, $cookie2), $cookieJar->all(), '->all() returns all cookies in the jar'); - } - - public function testClear() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar')); - $cookieJar->set($cookie2 = new Cookie('bar', 'foo')); - - $cookieJar->clear(); - - $this->assertEquals(array(), $cookieJar->all(), '->clear() expires all cookies'); - } - - public function testUpdateFromResponse() - { - $response = new Response('', 200, array('Set-Cookie' => 'foo=foo')); - - $cookieJar = new CookieJar(); - $cookieJar->updateFromResponse($response); - - $this->assertEquals('foo', $cookieJar->get('foo')->getValue(), '->updateFromResponse() updates cookies from a Response objects'); - } - - public function testUpdateFromSetCookie() - { - $setCookies = array('foo=foo'); - - $cookieJar = new CookieJar(); - $cookieJar->set(new Cookie('bar', 'bar')); - $cookieJar->updateFromSetCookie($setCookies); - - $this->assertInstanceOf('Symfony\Component\BrowserKit\Cookie', $cookieJar->get('foo')); - $this->assertInstanceOf('Symfony\Component\BrowserKit\Cookie', $cookieJar->get('bar')); - $this->assertEquals('foo', $cookieJar->get('foo')->getValue(), '->updateFromSetCookie() updates cookies from a Set-Cookie header'); - $this->assertEquals('bar', $cookieJar->get('bar')->getValue(), '->updateFromSetCookie() keeps existing cookies'); - } - - public function testUpdateFromEmptySetCookie() - { - $cookieJar = new CookieJar(); - $cookieJar->updateFromSetCookie(array('')); - $this->assertEquals(array(), $cookieJar->all()); - } - - public function testUpdateFromSetCookieWithMultipleCookies() - { - $timestamp = time() + 3600; - $date = gmdate('D, d M Y H:i:s \G\M\T', $timestamp); - $setCookies = array(sprintf('foo=foo; expires=%s; domain=.symfony.com; path=/, bar=bar; domain=.blog.symfony.com, PHPSESSID=id; expires=%s', $date, $date)); - - $cookieJar = new CookieJar(); - $cookieJar->updateFromSetCookie($setCookies); - - $fooCookie = $cookieJar->get('foo', '/', '.symfony.com'); - $barCookie = $cookieJar->get('bar', '/', '.blog.symfony.com'); - $phpCookie = $cookieJar->get('PHPSESSID'); - - $this->assertInstanceOf('Symfony\Component\BrowserKit\Cookie', $fooCookie); - $this->assertInstanceOf('Symfony\Component\BrowserKit\Cookie', $barCookie); - $this->assertInstanceOf('Symfony\Component\BrowserKit\Cookie', $phpCookie); - $this->assertEquals('foo', $fooCookie->getValue()); - $this->assertEquals('bar', $barCookie->getValue()); - $this->assertEquals('id', $phpCookie->getValue()); - $this->assertEquals($timestamp, $fooCookie->getExpiresTime()); - $this->assertNull($barCookie->getExpiresTime()); - $this->assertEquals($timestamp, $phpCookie->getExpiresTime()); - } - - /** - * @dataProvider provideAllValuesValues - */ - public function testAllValues($uri, $values) - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo_nothing', 'foo')); - $cookieJar->set($cookie2 = new Cookie('foo_expired', 'foo', time() - 86400)); - $cookieJar->set($cookie3 = new Cookie('foo_path', 'foo', null, '/foo')); - $cookieJar->set($cookie4 = new Cookie('foo_domain', 'foo', null, '/', '.example.com')); - $cookieJar->set($cookie4 = new Cookie('foo_strict_domain', 'foo', null, '/', '.www4.example.com')); - $cookieJar->set($cookie5 = new Cookie('foo_secure', 'foo', null, '/', '', true)); - - $this->assertEquals($values, array_keys($cookieJar->allValues($uri)), '->allValues() returns the cookie for a given URI'); - } - - public function provideAllValuesValues() - { - return array( - array('http://www.example.com', array('foo_nothing', 'foo_domain')), - array('http://www.example.com/', array('foo_nothing', 'foo_domain')), - array('http://foo.example.com/', array('foo_nothing', 'foo_domain')), - array('http://foo.example1.com/', array('foo_nothing')), - array('https://foo.example.com/', array('foo_nothing', 'foo_secure', 'foo_domain')), - array('http://www.example.com/foo/bar', array('foo_nothing', 'foo_path', 'foo_domain')), - array('http://www4.example.com/', array('foo_nothing', 'foo_domain', 'foo_strict_domain')), - ); - } - - public function testEncodedValues() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie = new Cookie('foo', 'bar%3Dbaz', null, '/', '', false, true, true)); - - $this->assertEquals(array('foo' => 'bar=baz'), $cookieJar->allValues('/')); - $this->assertEquals(array('foo' => 'bar%3Dbaz'), $cookieJar->allRawValues('/')); - } - - public function testCookieExpireWithSameNameButDifferentPaths() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar1', null, '/foo')); - $cookieJar->set($cookie2 = new Cookie('foo', 'bar2', null, '/bar')); - $cookieJar->expire('foo', '/foo'); - - $this->assertNull($cookieJar->get('foo'), '->get() returns null if the cookie is expired'); - $this->assertEquals(array(), array_keys($cookieJar->allValues('http://example.com/'))); - $this->assertEquals(array(), $cookieJar->allValues('http://example.com/foo')); - $this->assertEquals(array('foo' => 'bar2'), $cookieJar->allValues('http://example.com/bar')); - } - - public function testCookieExpireWithNullPaths() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar1', null, '/')); - $cookieJar->expire('foo', null); - - $this->assertNull($cookieJar->get('foo'), '->get() returns null if the cookie is expired'); - $this->assertEquals(array(), array_keys($cookieJar->allValues('http://example.com/'))); - } - - public function testCookieWithSameNameButDifferentPaths() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar1', null, '/foo')); - $cookieJar->set($cookie2 = new Cookie('foo', 'bar2', null, '/bar')); - - $this->assertEquals(array(), array_keys($cookieJar->allValues('http://example.com/'))); - $this->assertEquals(array('foo' => 'bar1'), $cookieJar->allValues('http://example.com/foo')); - $this->assertEquals(array('foo' => 'bar2'), $cookieJar->allValues('http://example.com/bar')); - } - - public function testCookieWithSameNameButDifferentDomains() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar1', null, '/', 'foo.example.com')); - $cookieJar->set($cookie2 = new Cookie('foo', 'bar2', null, '/', 'bar.example.com')); - - $this->assertEquals(array(), array_keys($cookieJar->allValues('http://example.com/'))); - $this->assertEquals(array('foo' => 'bar1'), $cookieJar->allValues('http://foo.example.com/')); - $this->assertEquals(array('foo' => 'bar2'), $cookieJar->allValues('http://bar.example.com/')); - } - - public function testCookieGetWithSubdomain() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar', null, '/', '.example.com')); - $cookieJar->set($cookie2 = new Cookie('foo1', 'bar', null, '/', 'test.example.com')); - - $this->assertEquals($cookie1, $cookieJar->get('foo', '/', 'foo.example.com')); - $this->assertEquals($cookie1, $cookieJar->get('foo', '/', 'example.com')); - $this->assertEquals($cookie2, $cookieJar->get('foo1', '/', 'test.example.com')); - } - - public function testCookieGetWithSubdirectory() - { - $cookieJar = new CookieJar(); - $cookieJar->set($cookie1 = new Cookie('foo', 'bar', null, '/test', '.example.com')); - $cookieJar->set($cookie2 = new Cookie('foo1', 'bar1', null, '/', '.example.com')); - - $this->assertNull($cookieJar->get('foo', '/', '.example.com')); - $this->assertNull($cookieJar->get('foo', '/bar', '.example.com')); - $this->assertEquals($cookie1, $cookieJar->get('foo', '/test', 'example.com')); - $this->assertEquals($cookie2, $cookieJar->get('foo1', '/', 'example.com')); - $this->assertEquals($cookie2, $cookieJar->get('foo1', '/bar', 'example.com')); - } - - public function testCookieWithWildcardDomain() - { - $cookieJar = new CookieJar(); - $cookieJar->set(new Cookie('foo', 'bar', null, '/', '.example.com')); - - $this->assertEquals(array('foo' => 'bar'), $cookieJar->allValues('http://www.example.com')); - $this->assertEmpty($cookieJar->allValues('http://wwwexample.com')); - } -} diff --git a/vendor/symfony/browser-kit/Tests/CookieTest.php b/vendor/symfony/browser-kit/Tests/CookieTest.php deleted file mode 100644 index e1dd0df2c..000000000 --- a/vendor/symfony/browser-kit/Tests/CookieTest.php +++ /dev/null @@ -1,179 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\Cookie; - -class CookieTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider getTestsForToFromString - */ - public function testToFromString($cookie, $url = null) - { - $this->assertEquals($cookie, (string) Cookie::fromString($cookie, $url)); - } - - public function getTestsForToFromString() - { - return array( - array('foo=bar; path=/'), - array('foo=bar; path=/foo'), - array('foo=bar; domain=google.com; path=/'), - array('foo=bar; domain=example.com; path=/; secure', 'https://example.com/'), - array('foo=bar; path=/; httponly'), - array('foo=bar; domain=google.com; path=/foo; secure; httponly', 'https://google.com/'), - array('foo=bar=baz; path=/'), - array('foo=bar%3Dbaz; path=/'), - ); - } - - public function testFromStringIgnoreSecureFlag() - { - $this->assertFalse(Cookie::fromString('foo=bar; secure')->isSecure()); - $this->assertFalse(Cookie::fromString('foo=bar; secure', 'http://example.com/')->isSecure()); - } - - /** - * @dataProvider getExpireCookieStrings - */ - public function testFromStringAcceptsSeveralExpiresDateFormats($cookie) - { - $this->assertEquals(1596185377, Cookie::fromString($cookie)->getExpiresTime()); - } - - public function getExpireCookieStrings() - { - return array( - array('foo=bar; expires=Fri, 31-Jul-2020 08:49:37 GMT'), - array('foo=bar; expires=Fri, 31 Jul 2020 08:49:37 GMT'), - array('foo=bar; expires=Fri, 31-07-2020 08:49:37 GMT'), - array('foo=bar; expires=Fri, 31-07-20 08:49:37 GMT'), - array('foo=bar; expires=Friday, 31-Jul-20 08:49:37 GMT'), - array('foo=bar; expires=Fri Jul 31 08:49:37 2020'), - array('foo=bar; expires=\'Fri Jul 31 08:49:37 2020\''), - array('foo=bar; expires=Friday July 31st 2020, 08:49:37 GMT'), - ); - } - - public function testFromStringWithCapitalization() - { - $this->assertEquals('Foo=Bar; path=/', (string) Cookie::fromString('Foo=Bar')); - $this->assertEquals('foo=bar; expires=Fri, 31 Dec 2010 23:59:59 GMT; path=/', (string) Cookie::fromString('foo=bar; Expires=Fri, 31 Dec 2010 23:59:59 GMT')); - $this->assertEquals('foo=bar; domain=www.example.org; path=/; httponly', (string) Cookie::fromString('foo=bar; DOMAIN=www.example.org; HttpOnly')); - } - - public function testFromStringWithUrl() - { - $this->assertEquals('foo=bar; domain=www.example.com; path=/', (string) Cookie::fromString('foo=bar', 'http://www.example.com/')); - $this->assertEquals('foo=bar; domain=www.example.com; path=/', (string) Cookie::fromString('foo=bar', 'http://www.example.com')); - $this->assertEquals('foo=bar; domain=www.example.com; path=/', (string) Cookie::fromString('foo=bar', 'http://www.example.com?foo')); - $this->assertEquals('foo=bar; domain=www.example.com; path=/foo', (string) Cookie::fromString('foo=bar', 'http://www.example.com/foo/bar')); - $this->assertEquals('foo=bar; domain=www.example.com; path=/', (string) Cookie::fromString('foo=bar; path=/', 'http://www.example.com/foo/bar')); - $this->assertEquals('foo=bar; domain=www.myotherexample.com; path=/', (string) Cookie::fromString('foo=bar; domain=www.myotherexample.com', 'http://www.example.com/')); - } - - public function testFromStringThrowsAnExceptionIfCookieIsNotValid() - { - $this->setExpectedException('InvalidArgumentException'); - Cookie::fromString('foo'); - } - - public function testFromStringThrowsAnExceptionIfCookieDateIsNotValid() - { - $this->setExpectedException('InvalidArgumentException'); - Cookie::fromString('foo=bar; expires=Flursday July 31st 2020, 08:49:37 GMT'); - } - - public function testFromStringThrowsAnExceptionIfUrlIsNotValid() - { - $this->setExpectedException('InvalidArgumentException'); - Cookie::fromString('foo=bar', 'foobar'); - } - - public function testGetName() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertEquals('foo', $cookie->getName(), '->getName() returns the cookie name'); - } - - public function testGetValue() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertEquals('bar', $cookie->getValue(), '->getValue() returns the cookie value'); - - $cookie = new Cookie('foo', 'bar%3Dbaz', null, '/', '', false, true, true); // raw value - $this->assertEquals('bar=baz', $cookie->getValue(), '->getValue() returns the urldecoded cookie value'); - } - - public function testGetRawValue() - { - $cookie = new Cookie('foo', 'bar=baz'); // decoded value - $this->assertEquals('bar%3Dbaz', $cookie->getRawValue(), '->getRawValue() returns the urlencoded cookie value'); - $cookie = new Cookie('foo', 'bar%3Dbaz', null, '/', '', false, true, true); // raw value - $this->assertEquals('bar%3Dbaz', $cookie->getRawValue(), '->getRawValue() returns the non-urldecoded cookie value'); - } - - public function testGetPath() - { - $cookie = new Cookie('foo', 'bar', 0); - $this->assertEquals('/', $cookie->getPath(), '->getPath() returns / is no path is defined'); - - $cookie = new Cookie('foo', 'bar', 0, '/foo'); - $this->assertEquals('/foo', $cookie->getPath(), '->getPath() returns the cookie path'); - } - - public function testGetDomain() - { - $cookie = new Cookie('foo', 'bar', 0, '/', 'foo.com'); - $this->assertEquals('foo.com', $cookie->getDomain(), '->getDomain() returns the cookie domain'); - } - - public function testIsSecure() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertFalse($cookie->isSecure(), '->isSecure() returns false if not defined'); - - $cookie = new Cookie('foo', 'bar', 0, '/', 'foo.com', true); - $this->assertTrue($cookie->isSecure(), '->isSecure() returns the cookie secure flag'); - } - - public function testIsHttponly() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertTrue($cookie->isHttpOnly(), '->isHttpOnly() returns false if not defined'); - - $cookie = new Cookie('foo', 'bar', 0, '/', 'foo.com', false, true); - $this->assertTrue($cookie->isHttpOnly(), '->isHttpOnly() returns the cookie httponly flag'); - } - - public function testGetExpiresTime() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertNull($cookie->getExpiresTime(), '->getExpiresTime() returns the expires time'); - - $cookie = new Cookie('foo', 'bar', $time = time() - 86400); - $this->assertEquals($time, $cookie->getExpiresTime(), '->getExpiresTime() returns the expires time'); - } - - public function testIsExpired() - { - $cookie = new Cookie('foo', 'bar'); - $this->assertFalse($cookie->isExpired(), '->isExpired() returns false when the cookie never expires (null as expires time)'); - - $cookie = new Cookie('foo', 'bar', time() - 86400); - $this->assertTrue($cookie->isExpired(), '->isExpired() returns true when the cookie is expired'); - - $cookie = new Cookie('foo', 'bar', 0); - $this->assertFalse($cookie->isExpired()); - } -} diff --git a/vendor/symfony/browser-kit/Tests/HistoryTest.php b/vendor/symfony/browser-kit/Tests/HistoryTest.php deleted file mode 100644 index d6d830e83..000000000 --- a/vendor/symfony/browser-kit/Tests/HistoryTest.php +++ /dev/null @@ -1,101 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\History; -use Symfony\Component\BrowserKit\Request; - -class HistoryTest extends \PHPUnit_Framework_TestCase -{ - public function testAdd() - { - $history = new History(); - $history->add(new Request('http://www.example1.com/', 'get')); - $this->assertSame('http://www.example1.com/', $history->current()->getUri(), '->add() adds a request to the history'); - - $history->add(new Request('http://www.example2.com/', 'get')); - $this->assertSame('http://www.example2.com/', $history->current()->getUri(), '->add() adds a request to the history'); - - $history->add(new Request('http://www.example3.com/', 'get')); - $history->back(); - $history->add(new Request('http://www.example4.com/', 'get')); - $this->assertSame('http://www.example4.com/', $history->current()->getUri(), '->add() adds a request to the history'); - - $history->back(); - $this->assertSame('http://www.example2.com/', $history->current()->getUri(), '->add() adds a request to the history'); - } - - public function testClearIsEmpty() - { - $history = new History(); - $history->add(new Request('http://www.example.com/', 'get')); - - $this->assertFalse($history->isEmpty(), '->isEmpty() returns false if the history is not empty'); - - $history->clear(); - - $this->assertTrue($history->isEmpty(), '->isEmpty() true if the history is empty'); - } - - public function testCurrent() - { - $history = new History(); - - try { - $history->current(); - $this->fail('->current() throws a \LogicException if the history is empty'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->current() throws a \LogicException if the history is empty'); - } - - $history->add(new Request('http://www.example.com/', 'get')); - - $this->assertSame('http://www.example.com/', $history->current()->getUri(), '->current() returns the current request in the history'); - } - - public function testBack() - { - $history = new History(); - $history->add(new Request('http://www.example.com/', 'get')); - - try { - $history->back(); - $this->fail('->back() throws a \LogicException if the history is already on the first page'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->current() throws a \LogicException if the history is already on the first page'); - } - - $history->add(new Request('http://www.example1.com/', 'get')); - $history->back(); - - $this->assertSame('http://www.example.com/', $history->current()->getUri(), '->back() returns the previous request in the history'); - } - - public function testForward() - { - $history = new History(); - $history->add(new Request('http://www.example.com/', 'get')); - $history->add(new Request('http://www.example1.com/', 'get')); - - try { - $history->forward(); - $this->fail('->forward() throws a \LogicException if the history is already on the last page'); - } catch (\Exception $e) { - $this->assertInstanceOf('LogicException', $e, '->forward() throws a \LogicException if the history is already on the last page'); - } - - $history->back(); - $history->forward(); - - $this->assertSame('http://www.example1.com/', $history->current()->getUri(), '->forward() returns the next request in the history'); - } -} diff --git a/vendor/symfony/browser-kit/Tests/RequestTest.php b/vendor/symfony/browser-kit/Tests/RequestTest.php deleted file mode 100644 index b75b5fb5c..000000000 --- a/vendor/symfony/browser-kit/Tests/RequestTest.php +++ /dev/null @@ -1,53 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\Request; - -class RequestTest extends \PHPUnit_Framework_TestCase -{ - public function testGetUri() - { - $request = new Request('http://www.example.com/', 'get'); - $this->assertEquals('http://www.example.com/', $request->getUri(), '->getUri() returns the URI of the request'); - } - - public function testGetMethod() - { - $request = new Request('http://www.example.com/', 'get'); - $this->assertEquals('get', $request->getMethod(), '->getMethod() returns the method of the request'); - } - - public function testGetParameters() - { - $request = new Request('http://www.example.com/', 'get', array('foo' => 'bar')); - $this->assertEquals(array('foo' => 'bar'), $request->getParameters(), '->getParameters() returns the parameters of the request'); - } - - public function testGetFiles() - { - $request = new Request('http://www.example.com/', 'get', array(), array('foo' => 'bar')); - $this->assertEquals(array('foo' => 'bar'), $request->getFiles(), '->getFiles() returns the uploaded files of the request'); - } - - public function testGetCookies() - { - $request = new Request('http://www.example.com/', 'get', array(), array(), array('foo' => 'bar')); - $this->assertEquals(array('foo' => 'bar'), $request->getCookies(), '->getCookies() returns the cookies of the request'); - } - - public function testGetServer() - { - $request = new Request('http://www.example.com/', 'get', array(), array(), array(), array('foo' => 'bar')); - $this->assertEquals(array('foo' => 'bar'), $request->getServer(), '->getServer() returns the server parameters of the request'); - } -} diff --git a/vendor/symfony/browser-kit/Tests/ResponseTest.php b/vendor/symfony/browser-kit/Tests/ResponseTest.php deleted file mode 100644 index bfe3cd52c..000000000 --- a/vendor/symfony/browser-kit/Tests/ResponseTest.php +++ /dev/null @@ -1,76 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\BrowserKit\Tests; - -use Symfony\Component\BrowserKit\Response; - -class ResponseTest extends \PHPUnit_Framework_TestCase -{ - public function testGetUri() - { - $response = new Response('foo'); - $this->assertEquals('foo', $response->getContent(), '->getContent() returns the content of the response'); - } - - public function testGetStatus() - { - $response = new Response('foo', 304); - $this->assertEquals('304', $response->getStatus(), '->getStatus() returns the status of the response'); - } - - public function testGetHeaders() - { - $response = new Response('foo', 200, array('foo' => 'bar')); - $this->assertEquals(array('foo' => 'bar'), $response->getHeaders(), '->getHeaders() returns the headers of the response'); - } - - public function testGetHeader() - { - $response = new Response('foo', 200, array( - 'Content-Type' => 'text/html', - 'Set-Cookie' => array('foo=bar', 'bar=foo'), - )); - - $this->assertEquals('text/html', $response->getHeader('Content-Type'), '->getHeader() returns a header of the response'); - $this->assertEquals('text/html', $response->getHeader('content-type'), '->getHeader() returns a header of the response'); - $this->assertEquals('text/html', $response->getHeader('content_type'), '->getHeader() returns a header of the response'); - $this->assertEquals('foo=bar', $response->getHeader('Set-Cookie'), '->getHeader() returns the first header value'); - $this->assertEquals(array('foo=bar', 'bar=foo'), $response->getHeader('Set-Cookie', false), '->getHeader() returns all header values if first is false'); - - $this->assertNull($response->getHeader('foo'), '->getHeader() returns null if the header is not defined'); - $this->assertEquals(array(), $response->getHeader('foo', false), '->getHeader() returns an empty array if the header is not defined and first is set to false'); - } - - public function testMagicToString() - { - $response = new Response('foo', 304, array('foo' => 'bar')); - - $this->assertEquals("foo: bar\n\nfoo", $response->__toString(), '->__toString() returns the headers and the content as a string'); - } - - public function testMagicToStringWithMultipleSetCookieHeader() - { - $headers = array( - 'content-type' => 'text/html; charset=utf-8', - 'set-cookie' => array('foo=bar', 'bar=foo'), - ); - - $expected = 'content-type: text/html; charset=utf-8'."\n"; - $expected .= 'set-cookie: foo=bar'."\n"; - $expected .= 'set-cookie: bar=foo'."\n\n"; - $expected .= 'foo'; - - $response = new Response('foo', 304, $headers); - - $this->assertEquals($expected, $response->__toString(), '->__toString() returns the headers and the content as a string'); - } -} diff --git a/vendor/symfony/class-loader/Tests/ClassCollectionLoaderTest.php b/vendor/symfony/class-loader/Tests/ClassCollectionLoaderTest.php deleted file mode 100644 index e821e4506..000000000 --- a/vendor/symfony/class-loader/Tests/ClassCollectionLoaderTest.php +++ /dev/null @@ -1,292 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\ClassCollectionLoader; - -require_once __DIR__.'/Fixtures/ClassesWithParents/GInterface.php'; -require_once __DIR__.'/Fixtures/ClassesWithParents/CInterface.php'; -require_once __DIR__.'/Fixtures/ClassesWithParents/B.php'; -require_once __DIR__.'/Fixtures/ClassesWithParents/A.php'; - -class ClassCollectionLoaderTest extends \PHPUnit_Framework_TestCase -{ - public function testTraitDependencies() - { - if (PHP_VERSION_ID < 50400) { - $this->markTestSkipped('Requires PHP > 5.4'); - - return; - } - - require_once __DIR__.'/Fixtures/deps/traits.php'; - - $r = new \ReflectionClass('Symfony\Component\ClassLoader\ClassCollectionLoader'); - $m = $r->getMethod('getOrderedClasses'); - $m->setAccessible(true); - - $ordered = $m->invoke('Symfony\Component\ClassLoader\ClassCollectionLoader', array('CTFoo')); - - $this->assertEquals( - array('TD', 'TC', 'TB', 'TA', 'TZ', 'CTFoo'), - array_map(function ($class) { return $class->getName(); }, $ordered) - ); - - $ordered = $m->invoke('Symfony\Component\ClassLoader\ClassCollectionLoader', array('CTBar')); - - $this->assertEquals( - array('TD', 'TZ', 'TC', 'TB', 'TA', 'CTBar'), - array_map(function ($class) { return $class->getName(); }, $ordered) - ); - } - - /** - * @dataProvider getDifferentOrders - */ - public function testClassReordering(array $classes) - { - $expected = array( - 'ClassesWithParents\\GInterface', - 'ClassesWithParents\\CInterface', - 'ClassesWithParents\\B', - 'ClassesWithParents\\A', - ); - - $r = new \ReflectionClass('Symfony\Component\ClassLoader\ClassCollectionLoader'); - $m = $r->getMethod('getOrderedClasses'); - $m->setAccessible(true); - - $ordered = $m->invoke('Symfony\Component\ClassLoader\ClassCollectionLoader', $classes); - - $this->assertEquals($expected, array_map(function ($class) { return $class->getName(); }, $ordered)); - } - - public function getDifferentOrders() - { - return array( - array(array( - 'ClassesWithParents\\A', - 'ClassesWithParents\\CInterface', - 'ClassesWithParents\\GInterface', - 'ClassesWithParents\\B', - )), - array(array( - 'ClassesWithParents\\B', - 'ClassesWithParents\\A', - 'ClassesWithParents\\CInterface', - )), - array(array( - 'ClassesWithParents\\CInterface', - 'ClassesWithParents\\B', - 'ClassesWithParents\\A', - )), - array(array( - 'ClassesWithParents\\A', - )), - ); - } - - /** - * @dataProvider getDifferentOrdersForTraits - */ - public function testClassWithTraitsReordering(array $classes) - { - if (PHP_VERSION_ID < 50400) { - $this->markTestSkipped('Requires PHP > 5.4'); - - return; - } - - require_once __DIR__.'/Fixtures/ClassesWithParents/ATrait.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/BTrait.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/CTrait.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/D.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/E.php'; - - $expected = array( - 'ClassesWithParents\\GInterface', - 'ClassesWithParents\\CInterface', - 'ClassesWithParents\\ATrait', - 'ClassesWithParents\\BTrait', - 'ClassesWithParents\\CTrait', - 'ClassesWithParents\\B', - 'ClassesWithParents\\A', - 'ClassesWithParents\\D', - 'ClassesWithParents\\E', - ); - - $r = new \ReflectionClass('Symfony\Component\ClassLoader\ClassCollectionLoader'); - $m = $r->getMethod('getOrderedClasses'); - $m->setAccessible(true); - - $ordered = $m->invoke('Symfony\Component\ClassLoader\ClassCollectionLoader', $classes); - - $this->assertEquals($expected, array_map(function ($class) { return $class->getName(); }, $ordered)); - } - - public function getDifferentOrdersForTraits() - { - return array( - array(array( - 'ClassesWithParents\\E', - 'ClassesWithParents\\ATrait', - )), - array(array( - 'ClassesWithParents\\E', - )), - ); - } - - public function testFixClassWithTraitsOrdering() - { - if (PHP_VERSION_ID < 50400) { - $this->markTestSkipped('Requires PHP > 5.4'); - - return; - } - - require_once __DIR__.'/Fixtures/ClassesWithParents/CTrait.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/F.php'; - require_once __DIR__.'/Fixtures/ClassesWithParents/G.php'; - - $classes = array( - 'ClassesWithParents\\F', - 'ClassesWithParents\\G', - ); - - $expected = array( - 'ClassesWithParents\\CTrait', - 'ClassesWithParents\\F', - 'ClassesWithParents\\G', - ); - - $r = new \ReflectionClass('Symfony\Component\ClassLoader\ClassCollectionLoader'); - $m = $r->getMethod('getOrderedClasses'); - $m->setAccessible(true); - - $ordered = $m->invoke('Symfony\Component\ClassLoader\ClassCollectionLoader', $classes); - - $this->assertEquals($expected, array_map(function ($class) { return $class->getName(); }, $ordered)); - } - - /** - * @dataProvider getFixNamespaceDeclarationsData - */ - public function testFixNamespaceDeclarations($source, $expected) - { - $this->assertEquals('assertEquals('assertEquals(<< - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\ClassLoader; - -class ClassLoaderTest extends \PHPUnit_Framework_TestCase -{ - public function testGetPrefixes() - { - $loader = new ClassLoader(); - $loader->addPrefix('Foo', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Bar', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Bas', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $prefixes = $loader->getPrefixes(); - $this->assertArrayHasKey('Foo', $prefixes); - $this->assertArrayNotHasKey('Foo1', $prefixes); - $this->assertArrayHasKey('Bar', $prefixes); - $this->assertArrayHasKey('Bas', $prefixes); - } - - public function testGetFallbackDirs() - { - $loader = new ClassLoader(); - $loader->addPrefix(null, __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix(null, __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $fallback_dirs = $loader->getFallbackDirs(); - $this->assertCount(2, $fallback_dirs); - } - - /** - * @dataProvider getLoadClassTests - */ - public function testLoadClass($className, $testClassName, $message) - { - $loader = new ClassLoader(); - $loader->addPrefix('Namespaced2\\', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Pearlike2_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->loadClass($testClassName); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassTests() - { - return array( - array('\\Namespaced2\\Foo', 'Namespaced2\\Foo', '->loadClass() loads Namespaced2\Foo class'), - array('\\Pearlike2_Foo', 'Pearlike2_Foo', '->loadClass() loads Pearlike2_Foo class'), - ); - } - - /** - * @dataProvider getLoadNonexistentClassTests - */ - public function testLoadNonexistentClass($className, $testClassName, $message) - { - $loader = new ClassLoader(); - $loader->addPrefix('Namespaced2\\', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Pearlike2_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->loadClass($testClassName); - $this->assertFalse(class_exists($className), $message); - } - - public function getLoadNonexistentClassTests() - { - return array( - array('\\Pearlike3_Bar', '\\Pearlike3_Bar', '->loadClass() loads non existing Pearlike3_Bar class with a leading slash'), - ); - } - - public function testAddPrefix() - { - $loader = new ClassLoader(); - $loader->addPrefix('Foo', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Foo', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $prefixes = $loader->getPrefixes(); - $this->assertArrayHasKey('Foo', $prefixes); - $this->assertCount(2, $prefixes['Foo']); - } - - public function testUseIncludePath() - { - $loader = new ClassLoader(); - $this->assertFalse($loader->getUseIncludePath()); - - $this->assertNull($loader->findFile('Foo')); - - $includePath = get_include_path(); - - $loader->setUseIncludePath(true); - $this->assertTrue($loader->getUseIncludePath()); - - set_include_path(__DIR__.'/Fixtures/includepath'.PATH_SEPARATOR.$includePath); - - $this->assertEquals(__DIR__.DIRECTORY_SEPARATOR.'Fixtures'.DIRECTORY_SEPARATOR.'includepath'.DIRECTORY_SEPARATOR.'Foo.php', $loader->findFile('Foo')); - - set_include_path($includePath); - } - - /** - * @dataProvider getLoadClassFromFallbackTests - */ - public function testLoadClassFromFallback($className, $testClassName, $message) - { - $loader = new ClassLoader(); - $loader->addPrefix('Namespaced2\\', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('Pearlike2_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->addPrefix('', array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/fallback')); - $loader->loadClass($testClassName); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassFromFallbackTests() - { - return array( - array('\\Namespaced2\\Baz', 'Namespaced2\\Baz', '->loadClass() loads Namespaced2\Baz class'), - array('\\Pearlike2_Baz', 'Pearlike2_Baz', '->loadClass() loads Pearlike2_Baz class'), - array('\\Namespaced2\\FooBar', 'Namespaced2\\FooBar', '->loadClass() loads Namespaced2\Baz class from fallback dir'), - array('\\Pearlike2_FooBar', 'Pearlike2_FooBar', '->loadClass() loads Pearlike2_Baz class from fallback dir'), - ); - } - - /** - * @dataProvider getLoadClassNamespaceCollisionTests - */ - public function testLoadClassNamespaceCollision($namespaces, $className, $message) - { - $loader = new ClassLoader(); - $loader->addPrefixes($namespaces); - - $loader->loadClass($className); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassNamespaceCollisionTests() - { - return array( - array( - array( - 'NamespaceCollision\\C' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'NamespaceCollision\\C\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'NamespaceCollision\C\Foo', - '->loadClass() loads NamespaceCollision\C\Foo from alpha.', - ), - array( - array( - 'NamespaceCollision\\C\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'NamespaceCollision\\C' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'NamespaceCollision\C\Bar', - '->loadClass() loads NamespaceCollision\C\Bar from alpha.', - ), - array( - array( - 'NamespaceCollision\\C' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'NamespaceCollision\\C\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'NamespaceCollision\C\B\Foo', - '->loadClass() loads NamespaceCollision\C\B\Foo from beta.', - ), - array( - array( - 'NamespaceCollision\\C\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'NamespaceCollision\\C' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'NamespaceCollision\C\B\Bar', - '->loadClass() loads NamespaceCollision\C\B\Bar from beta.', - ), - array( - array( - 'PrefixCollision_C_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'PrefixCollision_C_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'PrefixCollision_C_Foo', - '->loadClass() loads PrefixCollision_C_Foo from alpha.', - ), - array( - array( - 'PrefixCollision_C_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'PrefixCollision_C_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'PrefixCollision_C_Bar', - '->loadClass() loads PrefixCollision_C_Bar from alpha.', - ), - array( - array( - 'PrefixCollision_C_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'PrefixCollision_C_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'PrefixCollision_C_B_Foo', - '->loadClass() loads PrefixCollision_C_B_Foo from beta.', - ), - array( - array( - 'PrefixCollision_C_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'PrefixCollision_C_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'PrefixCollision_C_B_Bar', - '->loadClass() loads PrefixCollision_C_B_Bar from beta.', - ), - ); - } -} diff --git a/vendor/symfony/class-loader/Tests/ClassMapGeneratorTest.php b/vendor/symfony/class-loader/Tests/ClassMapGeneratorTest.php deleted file mode 100644 index 7bdf5aa0d..000000000 --- a/vendor/symfony/class-loader/Tests/ClassMapGeneratorTest.php +++ /dev/null @@ -1,150 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\ClassMapGenerator; - -class ClassMapGeneratorTest extends \PHPUnit_Framework_TestCase -{ - /** - * @var string|null - */ - private $workspace = null; - - public function prepare_workspace() - { - $this->workspace = rtrim(sys_get_temp_dir(), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.time().mt_rand(0, 1000); - mkdir($this->workspace, 0777, true); - $this->workspace = realpath($this->workspace); - } - - /** - * @param string $file - */ - private function clean($file) - { - if (is_dir($file) && !is_link($file)) { - $dir = new \FilesystemIterator($file); - foreach ($dir as $childFile) { - $this->clean($childFile); - } - - rmdir($file); - } else { - unlink($file); - } - } - - /** - * @dataProvider getTestCreateMapTests - */ - public function testDump($directory) - { - $this->prepare_workspace(); - - $file = $this->workspace.'/file'; - - $generator = new ClassMapGenerator(); - $generator->dump($directory, $file); - $this->assertFileExists($file); - - $this->clean($this->workspace); - } - - /** - * @dataProvider getTestCreateMapTests - */ - public function testCreateMap($directory, $expected) - { - $this->assertEqualsNormalized($expected, ClassMapGenerator::createMap($directory)); - } - - public function getTestCreateMapTests() - { - $data = array( - array(__DIR__.'/Fixtures/Namespaced', array( - 'Namespaced\\Bar' => realpath(__DIR__).'/Fixtures/Namespaced/Bar.php', - 'Namespaced\\Foo' => realpath(__DIR__).'/Fixtures/Namespaced/Foo.php', - 'Namespaced\\Baz' => realpath(__DIR__).'/Fixtures/Namespaced/Baz.php', - 'Namespaced\\WithComments' => realpath(__DIR__).'/Fixtures/Namespaced/WithComments.php', - ), - ), - array(__DIR__.'/Fixtures/beta/NamespaceCollision', array( - 'NamespaceCollision\\A\\B\\Bar' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/A/B/Bar.php', - 'NamespaceCollision\\A\\B\\Foo' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/A/B/Foo.php', - 'NamespaceCollision\\C\\B\\Bar' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/C/B/Bar.php', - 'NamespaceCollision\\C\\B\\Foo' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/C/B/Foo.php', - )), - array(__DIR__.'/Fixtures/Pearlike', array( - 'Pearlike_Foo' => realpath(__DIR__).'/Fixtures/Pearlike/Foo.php', - 'Pearlike_Bar' => realpath(__DIR__).'/Fixtures/Pearlike/Bar.php', - 'Pearlike_Baz' => realpath(__DIR__).'/Fixtures/Pearlike/Baz.php', - 'Pearlike_WithComments' => realpath(__DIR__).'/Fixtures/Pearlike/WithComments.php', - )), - array(__DIR__.'/Fixtures/classmap', array( - 'Foo\\Bar\\A' => realpath(__DIR__).'/Fixtures/classmap/sameNsMultipleClasses.php', - 'Foo\\Bar\\B' => realpath(__DIR__).'/Fixtures/classmap/sameNsMultipleClasses.php', - 'A' => realpath(__DIR__).'/Fixtures/classmap/multipleNs.php', - 'Alpha\\A' => realpath(__DIR__).'/Fixtures/classmap/multipleNs.php', - 'Alpha\\B' => realpath(__DIR__).'/Fixtures/classmap/multipleNs.php', - 'Beta\\A' => realpath(__DIR__).'/Fixtures/classmap/multipleNs.php', - 'Beta\\B' => realpath(__DIR__).'/Fixtures/classmap/multipleNs.php', - 'ClassMap\\SomeInterface' => realpath(__DIR__).'/Fixtures/classmap/SomeInterface.php', - 'ClassMap\\SomeParent' => realpath(__DIR__).'/Fixtures/classmap/SomeParent.php', - 'ClassMap\\SomeClass' => realpath(__DIR__).'/Fixtures/classmap/SomeClass.php', - )), - ); - - if (PHP_VERSION_ID >= 50400) { - $data[] = array(__DIR__.'/Fixtures/php5.4', array( - 'TFoo' => __DIR__.'/Fixtures/php5.4/traits.php', - 'CFoo' => __DIR__.'/Fixtures/php5.4/traits.php', - 'Foo\\TBar' => __DIR__.'/Fixtures/php5.4/traits.php', - 'Foo\\IBar' => __DIR__.'/Fixtures/php5.4/traits.php', - 'Foo\\TFooBar' => __DIR__.'/Fixtures/php5.4/traits.php', - 'Foo\\CBar' => __DIR__.'/Fixtures/php5.4/traits.php', - )); - } - - if (PHP_VERSION_ID >= 50500) { - $data[] = array(__DIR__.'/Fixtures/php5.5', array( - 'ClassCons\\Foo' => __DIR__.'/Fixtures/php5.5/class_cons.php', - )); - } - - return $data; - } - - public function testCreateMapFinderSupport() - { - $finder = new \Symfony\Component\Finder\Finder(); - $finder->files()->in(__DIR__.'/Fixtures/beta/NamespaceCollision'); - - $this->assertEqualsNormalized(array( - 'NamespaceCollision\\A\\B\\Bar' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/A/B/Bar.php', - 'NamespaceCollision\\A\\B\\Foo' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/A/B/Foo.php', - 'NamespaceCollision\\C\\B\\Bar' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/C/B/Bar.php', - 'NamespaceCollision\\C\\B\\Foo' => realpath(__DIR__).'/Fixtures/beta/NamespaceCollision/C/B/Foo.php', - ), ClassMapGenerator::createMap($finder)); - } - - protected function assertEqualsNormalized($expected, $actual, $message = null) - { - foreach ($expected as $ns => $path) { - $expected[$ns] = str_replace('\\', '/', $path); - } - foreach ($actual as $ns => $path) { - $actual[$ns] = str_replace('\\', '/', $path); - } - $this->assertEquals($expected, $actual, $message); - } -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Bar.php deleted file mode 100644 index 4259f1451..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Bar.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\Namespaced; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Baz.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Baz.php deleted file mode 100644 index 3ddb595e2..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Baz.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\Namespaced; - -class Baz -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Foo.php deleted file mode 100644 index cf0a4b741..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\Namespaced; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/FooBar.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/FooBar.php deleted file mode 100644 index bbbc81515..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Namespaced/FooBar.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\Namespaced; - -class FooBar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Bar.php deleted file mode 100644 index e774cb9bf..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/Pearlike/Bar.php +++ /dev/null @@ -1,6 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\NamespaceCollision\A; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/NamespaceCollision/A/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/NamespaceCollision/A/Foo.php deleted file mode 100644 index 184a1b1da..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/alpha/Apc/NamespaceCollision/A/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\NamespaceCollision\A; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/ApcPrefixCollision/A/B/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/ApcPrefixCollision/A/B/Bar.php deleted file mode 100644 index 3892f7068..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/ApcPrefixCollision/A/B/Bar.php +++ /dev/null @@ -1,6 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\NamespaceCollision\A\B; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/NamespaceCollision/A/B/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/NamespaceCollision/A/B/Foo.php deleted file mode 100644 index 450eeb50b..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/beta/Apc/NamespaceCollision/A/B/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\NamespaceCollision\A\B; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Apc/fallback/Apc/Pearlike/FooBar.php b/vendor/symfony/class-loader/Tests/Fixtures/Apc/fallback/Apc/Pearlike/FooBar.php deleted file mode 100644 index 96f2f76c6..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Apc/fallback/Apc/Pearlike/FooBar.php +++ /dev/null @@ -1,6 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Apc\Namespaced; - -class FooBar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/A.php b/vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/A.php deleted file mode 100644 index b0f942595..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/ClassesWithParents/A.php +++ /dev/null @@ -1,7 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Namespaced; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Baz.php b/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Baz.php deleted file mode 100644 index 0b0bbd057..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Baz.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Namespaced; - -class Baz -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Foo.php deleted file mode 100644 index df5e1f4ce..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Namespaced; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/WithComments.php b/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/WithComments.php deleted file mode 100644 index 361e53de1..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Namespaced/WithComments.php +++ /dev/null @@ -1,37 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Namespaced; - -class WithComments -{ - /** @Boolean */ - public static $loaded = true; -} - -$string = 'string should not be modified {$string}'; - -$heredoc = (<< - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -class Pearlike_WithComments -{ - /** @Boolean */ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Bar.php deleted file mode 100644 index 7f5f79773..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/Pearlike2/Bar.php +++ /dev/null @@ -1,6 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace NamespaceCollision\A; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/A/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/A/Foo.php deleted file mode 100644 index aee6a080d..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/A/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace NamespaceCollision\A; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/C/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/C/Bar.php deleted file mode 100644 index c1b8dd65d..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/alpha/NamespaceCollision/C/Bar.php +++ /dev/null @@ -1,8 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace NamespaceCollision\A\B; - -class Bar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/A/B/Foo.php b/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/A/B/Foo.php deleted file mode 100644 index f5f2d727e..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/A/B/Foo.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace NamespaceCollision\A\B; - -class Foo -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/C/B/Bar.php b/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/C/B/Bar.php deleted file mode 100644 index 4bb03dc7f..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/beta/NamespaceCollision/C/B/Bar.php +++ /dev/null @@ -1,8 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace ClassMap; - -class SomeClass extends SomeParent implements SomeInterface -{ -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeInterface.php b/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeInterface.php deleted file mode 100644 index 1fe5e09aa..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeInterface.php +++ /dev/null @@ -1,16 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace ClassMap; - -interface SomeInterface -{ -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeParent.php b/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeParent.php deleted file mode 100644 index ce2f9fc6c..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/classmap/SomeParent.php +++ /dev/null @@ -1,16 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace ClassMap; - -abstract class SomeParent -{ -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/classmap/multipleNs.php b/vendor/symfony/class-loader/Tests/Fixtures/classmap/multipleNs.php deleted file mode 100644 index c7cec646f..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/classmap/multipleNs.php +++ /dev/null @@ -1,25 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Foo\Bar; - -class A -{ -} -class B -{ -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/deps/traits.php b/vendor/symfony/class-loader/Tests/Fixtures/deps/traits.php deleted file mode 100644 index 82b30a6f9..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/deps/traits.php +++ /dev/null @@ -1,37 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Namespaced; - -class FooBar -{ - public static $loaded = true; -} diff --git a/vendor/symfony/class-loader/Tests/Fixtures/fallback/Namespaced2/FooBar.php b/vendor/symfony/class-loader/Tests/Fixtures/fallback/Namespaced2/FooBar.php deleted file mode 100644 index 1036d4359..000000000 --- a/vendor/symfony/class-loader/Tests/Fixtures/fallback/Namespaced2/FooBar.php +++ /dev/null @@ -1,8 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\ApcUniversalClassLoader; - -/** - * @group legacy - */ -class LegacyApcUniversalClassLoaderTest extends \PHPUnit_Framework_TestCase -{ - protected function setUp() - { - if (!extension_loaded('apc')) { - $this->markTestSkipped('The apc extension is not available.'); - } - - if (!(ini_get('apc.enabled') && ini_get('apc.enable_cli'))) { - $this->markTestSkipped('The apc extension is available, but not enabled.'); - } else { - apc_clear_cache('user'); - } - } - - protected function tearDown() - { - if (ini_get('apc.enabled') && ini_get('apc.enable_cli')) { - apc_clear_cache('user'); - } - } - - public function testConstructor() - { - $loader = new ApcUniversalClassLoader('test.prefix.'); - $loader->registerNamespace('Apc\Namespaced', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - - $this->assertEquals($loader->findFile('\Apc\Namespaced\FooBar'), apc_fetch('test.prefix.\Apc\Namespaced\FooBar'), '__construct() takes a prefix as its first argument'); - } - - /** - * @dataProvider getLoadClassTests - */ - public function testLoadClass($className, $testClassName, $message) - { - $loader = new ApcUniversalClassLoader('test.prefix.'); - $loader->registerNamespace('Apc\Namespaced', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Apc_Pearlike_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->loadClass($testClassName); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassTests() - { - return array( - array('\\Apc\\Namespaced\\Foo', 'Apc\\Namespaced\\Foo', '->loadClass() loads Apc\Namespaced\Foo class'), - array('Apc_Pearlike_Foo', 'Apc_Pearlike_Foo', '->loadClass() loads Apc_Pearlike_Foo class'), - ); - } - - /** - * @dataProvider getLoadClassFromFallbackTests - */ - public function testLoadClassFromFallback($className, $testClassName, $message) - { - $loader = new ApcUniversalClassLoader('test.prefix.fallback'); - $loader->registerNamespace('Apc\Namespaced', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Apc_Pearlike_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerNamespaceFallbacks(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/fallback')); - $loader->registerPrefixFallbacks(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/fallback')); - $loader->loadClass($testClassName); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassFromFallbackTests() - { - return array( - array('\\Apc\\Namespaced\\Baz', 'Apc\\Namespaced\\Baz', '->loadClass() loads Apc\Namespaced\Baz class'), - array('Apc_Pearlike_Baz', 'Apc_Pearlike_Baz', '->loadClass() loads Apc_Pearlike_Baz class'), - array('\\Apc\\Namespaced\\FooBar', 'Apc\\Namespaced\\FooBar', '->loadClass() loads Apc\Namespaced\Baz class from fallback dir'), - array('Apc_Pearlike_FooBar', 'Apc_Pearlike_FooBar', '->loadClass() loads Apc_Pearlike_Baz class from fallback dir'), - ); - } - - /** - * @dataProvider getLoadClassNamespaceCollisionTests - */ - public function testLoadClassNamespaceCollision($namespaces, $className, $message) - { - $loader = new ApcUniversalClassLoader('test.prefix.collision.'); - $loader->registerNamespaces($namespaces); - - $loader->loadClass($className); - - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassNamespaceCollisionTests() - { - return array( - array( - array( - 'Apc\\NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha', - 'Apc\\NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta', - ), - 'Apc\NamespaceCollision\A\Foo', - '->loadClass() loads NamespaceCollision\A\Foo from alpha.', - ), - array( - array( - 'Apc\\NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta', - 'Apc\\NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha', - ), - 'Apc\NamespaceCollision\A\Bar', - '->loadClass() loads NamespaceCollision\A\Bar from alpha.', - ), - array( - array( - 'Apc\\NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha', - 'Apc\\NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta', - ), - 'Apc\NamespaceCollision\A\B\Foo', - '->loadClass() loads NamespaceCollision\A\B\Foo from beta.', - ), - array( - array( - 'Apc\\NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta', - 'Apc\\NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha', - ), - 'Apc\NamespaceCollision\A\B\Bar', - '->loadClass() loads NamespaceCollision\A\B\Bar from beta.', - ), - ); - } - - /** - * @dataProvider getLoadClassPrefixCollisionTests - */ - public function testLoadClassPrefixCollision($prefixes, $className, $message) - { - $loader = new ApcUniversalClassLoader('test.prefix.collision.'); - $loader->registerPrefixes($prefixes); - - $loader->loadClass($className); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassPrefixCollisionTests() - { - return array( - array( - array( - 'ApcPrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha/Apc', - 'ApcPrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta/Apc', - ), - 'ApcPrefixCollision_A_Foo', - '->loadClass() loads ApcPrefixCollision_A_Foo from alpha.', - ), - array( - array( - 'ApcPrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta/Apc', - 'ApcPrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha/Apc', - ), - 'ApcPrefixCollision_A_Bar', - '->loadClass() loads ApcPrefixCollision_A_Bar from alpha.', - ), - array( - array( - 'ApcPrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha/Apc', - 'ApcPrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta/Apc', - ), - 'ApcPrefixCollision_A_B_Foo', - '->loadClass() loads ApcPrefixCollision_A_B_Foo from beta.', - ), - array( - array( - 'ApcPrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/beta/Apc', - 'ApcPrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/Apc/alpha/Apc', - ), - 'ApcPrefixCollision_A_B_Bar', - '->loadClass() loads ApcPrefixCollision_A_B_Bar from beta.', - ), - ); - } -} diff --git a/vendor/symfony/class-loader/Tests/LegacyUniversalClassLoaderTest.php b/vendor/symfony/class-loader/Tests/LegacyUniversalClassLoaderTest.php deleted file mode 100644 index 2588e9603..000000000 --- a/vendor/symfony/class-loader/Tests/LegacyUniversalClassLoaderTest.php +++ /dev/null @@ -1,223 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\UniversalClassLoader; - -/** - * @group legacy - */ -class LegacyUniversalClassLoaderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider getLoadClassTests - */ - public function testLoadClass($className, $testClassName, $message) - { - $loader = new UniversalClassLoader(); - $loader->registerNamespace('Namespaced', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Pearlike_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $this->assertTrue($loader->loadClass($testClassName)); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassTests() - { - return array( - array('\\Namespaced\\Foo', 'Namespaced\\Foo', '->loadClass() loads Namespaced\Foo class'), - array('\\Pearlike_Foo', 'Pearlike_Foo', '->loadClass() loads Pearlike_Foo class'), - ); - } - - public function testUseIncludePath() - { - $loader = new UniversalClassLoader(); - $this->assertFalse($loader->getUseIncludePath()); - - $this->assertNull($loader->findFile('Foo')); - - $includePath = get_include_path(); - - $loader->useIncludePath(true); - $this->assertTrue($loader->getUseIncludePath()); - - set_include_path(__DIR__.'/Fixtures/includepath'.PATH_SEPARATOR.$includePath); - - $this->assertEquals(__DIR__.DIRECTORY_SEPARATOR.'Fixtures'.DIRECTORY_SEPARATOR.'includepath'.DIRECTORY_SEPARATOR.'Foo.php', $loader->findFile('Foo')); - - set_include_path($includePath); - } - - public function testGetNamespaces() - { - $loader = new UniversalClassLoader(); - $loader->registerNamespace('Foo', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerNamespace('Bar', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerNamespace('Bas', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $namespaces = $loader->getNamespaces(); - $this->assertArrayHasKey('Foo', $namespaces); - $this->assertArrayNotHasKey('Foo1', $namespaces); - $this->assertArrayHasKey('Bar', $namespaces); - $this->assertArrayHasKey('Bas', $namespaces); - } - - public function testGetPrefixes() - { - $loader = new UniversalClassLoader(); - $loader->registerPrefix('Foo', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Bar', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Bas', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $prefixes = $loader->getPrefixes(); - $this->assertArrayHasKey('Foo', $prefixes); - $this->assertArrayNotHasKey('Foo1', $prefixes); - $this->assertArrayHasKey('Bar', $prefixes); - $this->assertArrayHasKey('Bas', $prefixes); - } - - /** - * @dataProvider getLoadClassFromFallbackTests - */ - public function testLoadClassFromFallback($className, $testClassName, $message) - { - $loader = new UniversalClassLoader(); - $loader->registerNamespace('Namespaced', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerPrefix('Pearlike_', __DIR__.DIRECTORY_SEPARATOR.'Fixtures'); - $loader->registerNamespaceFallbacks(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/fallback')); - $loader->registerPrefixFallbacks(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/fallback')); - $this->assertTrue($loader->loadClass($testClassName)); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassFromFallbackTests() - { - return array( - array('\\Namespaced\\Baz', 'Namespaced\\Baz', '->loadClass() loads Namespaced\Baz class'), - array('\\Pearlike_Baz', 'Pearlike_Baz', '->loadClass() loads Pearlike_Baz class'), - array('\\Namespaced\\FooBar', 'Namespaced\\FooBar', '->loadClass() loads Namespaced\Baz class from fallback dir'), - array('\\Pearlike_FooBar', 'Pearlike_FooBar', '->loadClass() loads Pearlike_Baz class from fallback dir'), - ); - } - - public function testRegisterPrefixFallback() - { - $loader = new UniversalClassLoader(); - $loader->registerPrefixFallback(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/fallback'); - $this->assertEquals(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/fallback'), $loader->getPrefixFallbacks()); - } - - public function testRegisterNamespaceFallback() - { - $loader = new UniversalClassLoader(); - $loader->registerNamespaceFallback(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/Namespaced/fallback'); - $this->assertEquals(array(__DIR__.DIRECTORY_SEPARATOR.'Fixtures/Namespaced/fallback'), $loader->getNamespaceFallbacks()); - } - - /** - * @dataProvider getLoadClassNamespaceCollisionTests - */ - public function testLoadClassNamespaceCollision($namespaces, $className, $message) - { - $loader = new UniversalClassLoader(); - $loader->registerNamespaces($namespaces); - - $this->assertTrue($loader->loadClass($className)); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassNamespaceCollisionTests() - { - return array( - array( - array( - 'NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'NamespaceCollision\A\Foo', - '->loadClass() loads NamespaceCollision\A\Foo from alpha.', - ), - array( - array( - 'NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'NamespaceCollision\A\Bar', - '->loadClass() loads NamespaceCollision\A\Bar from alpha.', - ), - array( - array( - 'NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'NamespaceCollision\A\B\Foo', - '->loadClass() loads NamespaceCollision\A\B\Foo from beta.', - ), - array( - array( - 'NamespaceCollision\\A\\B' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'NamespaceCollision\\A' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'NamespaceCollision\A\B\Bar', - '->loadClass() loads NamespaceCollision\A\B\Bar from beta.', - ), - ); - } - - /** - * @dataProvider getLoadClassPrefixCollisionTests - */ - public function testLoadClassPrefixCollision($prefixes, $className, $message) - { - $loader = new UniversalClassLoader(); - $loader->registerPrefixes($prefixes); - - $this->assertTrue($loader->loadClass($className)); - $this->assertTrue(class_exists($className), $message); - } - - public function getLoadClassPrefixCollisionTests() - { - return array( - array( - array( - 'PrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'PrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'PrefixCollision_A_Foo', - '->loadClass() loads PrefixCollision_A_Foo from alpha.', - ), - array( - array( - 'PrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'PrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'PrefixCollision_A_Bar', - '->loadClass() loads PrefixCollision_A_Bar from alpha.', - ), - array( - array( - 'PrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - 'PrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - ), - 'PrefixCollision_A_B_Foo', - '->loadClass() loads PrefixCollision_A_B_Foo from beta.', - ), - array( - array( - 'PrefixCollision_A_B_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/beta', - 'PrefixCollision_A_' => __DIR__.DIRECTORY_SEPARATOR.'Fixtures/alpha', - ), - 'PrefixCollision_A_B_Bar', - '->loadClass() loads PrefixCollision_A_B_Bar from beta.', - ), - ); - } -} diff --git a/vendor/symfony/class-loader/Tests/Psr4ClassLoaderTest.php b/vendor/symfony/class-loader/Tests/Psr4ClassLoaderTest.php deleted file mode 100644 index 21a7afbd6..000000000 --- a/vendor/symfony/class-loader/Tests/Psr4ClassLoaderTest.php +++ /dev/null @@ -1,71 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ClassLoader\Tests; - -use Symfony\Component\ClassLoader\Psr4ClassLoader; - -class Psr4ClassLoaderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @param string $className - * @dataProvider getLoadClassTests - */ - public function testLoadClass($className) - { - $loader = new Psr4ClassLoader(); - $loader->addPrefix( - 'Acme\\DemoLib', - __DIR__.DIRECTORY_SEPARATOR.'Fixtures'.DIRECTORY_SEPARATOR.'psr-4' - ); - $loader->loadClass($className); - $this->assertTrue(class_exists($className), sprintf('loadClass() should load %s', $className)); - } - - /** - * @return array - */ - public function getLoadClassTests() - { - return array( - array('Acme\\DemoLib\\Foo'), - array('Acme\\DemoLib\\Class_With_Underscores'), - array('Acme\\DemoLib\\Lets\\Go\\Deeper\\Foo'), - array('Acme\\DemoLib\\Lets\\Go\\Deeper\\Class_With_Underscores'), - ); - } - - /** - * @param string $className - * @dataProvider getLoadNonexistentClassTests - */ - public function testLoadNonexistentClass($className) - { - $loader = new Psr4ClassLoader(); - $loader->addPrefix( - 'Acme\\DemoLib', - __DIR__.DIRECTORY_SEPARATOR.'Fixtures'.DIRECTORY_SEPARATOR.'psr-4' - ); - $loader->loadClass($className); - $this->assertFalse(class_exists($className), sprintf('loadClass() should not load %s', $className)); - } - - /** - * @return array - */ - public function getLoadNonexistentClassTests() - { - return array( - array('Acme\\DemoLib\\I_Do_Not_Exist'), - array('UnknownVendor\\SomeLib\\I_Do_Not_Exist'), - ); - } -} diff --git a/vendor/symfony/console/Resources/bin/hiddeninput.exe b/vendor/symfony/console/Resources/bin/hiddeninput.exe index 9f4a2aa6357a7dd48f810a66982dc0f78a1c27f6..c8cf65e8d819e6e525121cf6b21f1c2429746038 100644 GIT binary patch delta 164 zcmez5-rzBzY-8zcSw`N;0&?bhyj%)EU{jo$Tw0V_QfUX_14W8b3rkarOHxw;iZaVG zb5he&i|u$P7sKSzay$1)Gwh(&7@&ytMqu7iHCjjFs$wf - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests; - -use Symfony\Component\Console\Application; -use Symfony\Component\Console\Helper\HelperSet; -use Symfony\Component\Console\Helper\FormatterHelper; -use Symfony\Component\Console\Input\ArgvInput; -use Symfony\Component\Console\Input\ArrayInput; -use Symfony\Component\Console\Input\InputInterface; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputOption; -use Symfony\Component\Console\Output\NullOutput; -use Symfony\Component\Console\Output\Output; -use Symfony\Component\Console\Output\OutputInterface; -use Symfony\Component\Console\Output\StreamOutput; -use Symfony\Component\Console\Tester\ApplicationTester; -use Symfony\Component\Console\Event\ConsoleCommandEvent; -use Symfony\Component\Console\Event\ConsoleExceptionEvent; -use Symfony\Component\Console\Event\ConsoleTerminateEvent; -use Symfony\Component\EventDispatcher\EventDispatcher; - -class ApplicationTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/Fixtures/'); - require_once self::$fixturesPath.'/FooCommand.php'; - require_once self::$fixturesPath.'/Foo1Command.php'; - require_once self::$fixturesPath.'/Foo2Command.php'; - require_once self::$fixturesPath.'/Foo3Command.php'; - require_once self::$fixturesPath.'/Foo4Command.php'; - require_once self::$fixturesPath.'/Foo5Command.php'; - require_once self::$fixturesPath.'/FoobarCommand.php'; - require_once self::$fixturesPath.'/BarBucCommand.php'; - require_once self::$fixturesPath.'/FooSubnamespaced1Command.php'; - require_once self::$fixturesPath.'/FooSubnamespaced2Command.php'; - } - - protected function normalizeLineBreaks($text) - { - return str_replace(PHP_EOL, "\n", $text); - } - - /** - * Replaces the dynamic placeholders of the command help text with a static version. - * The placeholder %command.full_name% includes the script path that is not predictable - * and can not be tested against. - */ - protected function ensureStaticCommandHelp(Application $application) - { - foreach ($application->all() as $command) { - $command->setHelp(str_replace('%command.full_name%', 'app/console %command.name%', $command->getHelp())); - } - } - - public function testConstructor() - { - $application = new Application('foo', 'bar'); - $this->assertEquals('foo', $application->getName(), '__construct() takes the application name as its first argument'); - $this->assertEquals('bar', $application->getVersion(), '__construct() takes the application version as its second argument'); - $this->assertEquals(array('help', 'list'), array_keys($application->all()), '__construct() registered the help and list commands by default'); - } - - public function testSetGetName() - { - $application = new Application(); - $application->setName('foo'); - $this->assertEquals('foo', $application->getName(), '->setName() sets the name of the application'); - } - - public function testSetGetVersion() - { - $application = new Application(); - $application->setVersion('bar'); - $this->assertEquals('bar', $application->getVersion(), '->setVersion() sets the version of the application'); - } - - public function testGetLongVersion() - { - $application = new Application('foo', 'bar'); - $this->assertEquals('foo version bar', $application->getLongVersion(), '->getLongVersion() returns the long version of the application'); - } - - public function testHelp() - { - $application = new Application(); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_gethelp.txt', $this->normalizeLineBreaks($application->getHelp()), '->getHelp() returns a help message'); - } - - public function testAll() - { - $application = new Application(); - $commands = $application->all(); - $this->assertInstanceOf('Symfony\\Component\\Console\\Command\\HelpCommand', $commands['help'], '->all() returns the registered commands'); - - $application->add(new \FooCommand()); - $commands = $application->all('foo'); - $this->assertCount(1, $commands, '->all() takes a namespace as its first argument'); - } - - public function testRegister() - { - $application = new Application(); - $command = $application->register('foo'); - $this->assertEquals('foo', $command->getName(), '->register() registers a new command'); - } - - public function testAdd() - { - $application = new Application(); - $application->add($foo = new \FooCommand()); - $commands = $application->all(); - $this->assertEquals($foo, $commands['foo:bar'], '->add() registers a command'); - - $application = new Application(); - $application->addCommands(array($foo = new \FooCommand(), $foo1 = new \Foo1Command())); - $commands = $application->all(); - $this->assertEquals(array($foo, $foo1), array($commands['foo:bar'], $commands['foo:bar1']), '->addCommands() registers an array of commands'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Command class "Foo5Command" is not correctly initialized. You probably forgot to call the parent constructor. - */ - public function testAddCommandWithEmptyConstructor() - { - $application = new Application(); - $application->add(new \Foo5Command()); - } - - public function testHasGet() - { - $application = new Application(); - $this->assertTrue($application->has('list'), '->has() returns true if a named command is registered'); - $this->assertFalse($application->has('afoobar'), '->has() returns false if a named command is not registered'); - - $application->add($foo = new \FooCommand()); - $this->assertTrue($application->has('afoobar'), '->has() returns true if an alias is registered'); - $this->assertEquals($foo, $application->get('foo:bar'), '->get() returns a command by name'); - $this->assertEquals($foo, $application->get('afoobar'), '->get() returns a command by alias'); - - $application = new Application(); - $application->add($foo = new \FooCommand()); - // simulate --help - $r = new \ReflectionObject($application); - $p = $r->getProperty('wantHelps'); - $p->setAccessible(true); - $p->setValue($application, true); - $command = $application->get('foo:bar'); - $this->assertInstanceOf('Symfony\Component\Console\Command\HelpCommand', $command, '->get() returns the help command if --help is provided as the input'); - } - - public function testSilentHelp() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $tester = new ApplicationTester($application); - $tester->run(array('-h' => true, '-q' => true), array('decorated' => false)); - - $this->assertEmpty($tester->getDisplay(true)); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The command "foofoo" does not exist. - */ - public function testGetInvalidCommand() - { - $application = new Application(); - $application->get('foofoo'); - } - - public function testGetNamespaces() - { - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $this->assertEquals(array('foo'), $application->getNamespaces(), '->getNamespaces() returns an array of unique used namespaces'); - } - - public function testFindNamespace() - { - $application = new Application(); - $application->add(new \FooCommand()); - $this->assertEquals('foo', $application->findNamespace('foo'), '->findNamespace() returns the given namespace if it exists'); - $this->assertEquals('foo', $application->findNamespace('f'), '->findNamespace() finds a namespace given an abbreviation'); - $application->add(new \Foo2Command()); - $this->assertEquals('foo', $application->findNamespace('foo'), '->findNamespace() returns the given namespace if it exists'); - } - - public function testFindNamespaceWithSubnamespaces() - { - $application = new Application(); - $application->add(new \FooSubnamespaced1Command()); - $application->add(new \FooSubnamespaced2Command()); - $this->assertEquals('foo', $application->findNamespace('foo'), '->findNamespace() returns commands even if the commands are only contained in subnamespaces'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The namespace "f" is ambiguous (foo, foo1). - */ - public function testFindAmbiguousNamespace() - { - $application = new Application(); - $application->add(new \BarBucCommand()); - $application->add(new \FooCommand()); - $application->add(new \Foo2Command()); - $application->findNamespace('f'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage There are no commands defined in the "bar" namespace. - */ - public function testFindInvalidNamespace() - { - $application = new Application(); - $application->findNamespace('bar'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Command "foo1" is not defined - */ - public function testFindUniqueNameButNamespaceName() - { - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $application->add(new \Foo2Command()); - - $application->find($commandName = 'foo1'); - } - - public function testFind() - { - $application = new Application(); - $application->add(new \FooCommand()); - - $this->assertInstanceOf('FooCommand', $application->find('foo:bar'), '->find() returns a command if its name exists'); - $this->assertInstanceOf('Symfony\Component\Console\Command\HelpCommand', $application->find('h'), '->find() returns a command if its name exists'); - $this->assertInstanceOf('FooCommand', $application->find('f:bar'), '->find() returns a command if the abbreviation for the namespace exists'); - $this->assertInstanceOf('FooCommand', $application->find('f:b'), '->find() returns a command if the abbreviation for the namespace and the command name exist'); - $this->assertInstanceOf('FooCommand', $application->find('a'), '->find() returns a command if the abbreviation exists for an alias'); - } - - /** - * @dataProvider provideAmbiguousAbbreviations - */ - public function testFindWithAmbiguousAbbreviations($abbreviation, $expectedExceptionMessage) - { - $this->setExpectedException('InvalidArgumentException', $expectedExceptionMessage); - - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $application->add(new \Foo2Command()); - - $application->find($abbreviation); - } - - public function provideAmbiguousAbbreviations() - { - return array( - array('f', 'Command "f" is not defined.'), - array('a', 'Command "a" is ambiguous (afoobar, afoobar1 and 1 more).'), - array('foo:b', 'Command "foo:b" is ambiguous (foo:bar, foo:bar1 and 1 more).'), - ); - } - - public function testFindCommandEqualNamespace() - { - $application = new Application(); - $application->add(new \Foo3Command()); - $application->add(new \Foo4Command()); - - $this->assertInstanceOf('Foo3Command', $application->find('foo3:bar'), '->find() returns the good command even if a namespace has same name'); - $this->assertInstanceOf('Foo4Command', $application->find('foo3:bar:toh'), '->find() returns a command even if its namespace equals another command name'); - } - - public function testFindCommandWithAmbiguousNamespacesButUniqueName() - { - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \FoobarCommand()); - - $this->assertInstanceOf('FoobarCommand', $application->find('f:f')); - } - - public function testFindCommandWithMissingNamespace() - { - $application = new Application(); - $application->add(new \Foo4Command()); - - $this->assertInstanceOf('Foo4Command', $application->find('f::t')); - } - - /** - * @dataProvider provideInvalidCommandNamesSingle - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Did you mean this - */ - public function testFindAlternativeExceptionMessageSingle($name) - { - $application = new Application(); - $application->add(new \Foo3Command()); - $application->find($name); - } - - public function provideInvalidCommandNamesSingle() - { - return array( - array('foo3:baR'), - array('foO3:bar'), - ); - } - - public function testFindAlternativeExceptionMessageMultiple() - { - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $application->add(new \Foo2Command()); - - // Command + plural - try { - $application->find('foo:baR'); - $this->fail('->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - $this->assertRegExp('/Did you mean one of these/', $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - $this->assertRegExp('/foo1:bar/', $e->getMessage()); - $this->assertRegExp('/foo:bar/', $e->getMessage()); - } - - // Namespace + plural - try { - $application->find('foo2:bar'); - $this->fail('->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - $this->assertRegExp('/Did you mean one of these/', $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - $this->assertRegExp('/foo1/', $e->getMessage()); - } - - $application->add(new \Foo3Command()); - $application->add(new \Foo4Command()); - - // Subnamespace + plural - try { - $a = $application->find('foo3:'); - $this->fail('->find() should throw an \InvalidArgumentException if a command is ambiguous because of a subnamespace, with alternatives'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e); - $this->assertRegExp('/foo3:bar/', $e->getMessage()); - $this->assertRegExp('/foo3:bar:toh/', $e->getMessage()); - } - } - - public function testFindAlternativeCommands() - { - $application = new Application(); - - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $application->add(new \Foo2Command()); - - try { - $application->find($commandName = 'Unknown command'); - $this->fail('->find() throws an \InvalidArgumentException if command does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if command does not exist'); - $this->assertEquals(sprintf('Command "%s" is not defined.', $commandName), $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, without alternatives'); - } - - // Test if "bar1" command throw an "\InvalidArgumentException" and does not contain - // "foo:bar" as alternative because "bar1" is too far from "foo:bar" - try { - $application->find($commandName = 'bar1'); - $this->fail('->find() throws an \InvalidArgumentException if command does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if command does not exist'); - $this->assertRegExp(sprintf('/Command "%s" is not defined./', $commandName), $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, with alternatives'); - $this->assertRegExp('/afoobar1/', $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, with alternative : "afoobar1"'); - $this->assertRegExp('/foo:bar1/', $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, with alternative : "foo:bar1"'); - $this->assertNotRegExp('/foo:bar(?>!1)/', $e->getMessage(), '->find() throws an \InvalidArgumentException if command does not exist, without "foo:bar" alternative'); - } - } - - public function testFindAlternativeCommandsWithAnAlias() - { - $fooCommand = new \FooCommand(); - $fooCommand->setAliases(array('foo2')); - - $application = new Application(); - $application->add($fooCommand); - - $result = $application->find('foo'); - - $this->assertSame($fooCommand, $result); - } - - public function testFindAlternativeNamespace() - { - $application = new Application(); - - $application->add(new \FooCommand()); - $application->add(new \Foo1Command()); - $application->add(new \Foo2Command()); - $application->add(new \foo3Command()); - - try { - $application->find('Unknown-namespace:Unknown-command'); - $this->fail('->find() throws an \InvalidArgumentException if namespace does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if namespace does not exist'); - $this->assertEquals('There are no commands defined in the "Unknown-namespace" namespace.', $e->getMessage(), '->find() throws an \InvalidArgumentException if namespace does not exist, without alternatives'); - } - - try { - $application->find('foo2:command'); - $this->fail('->find() throws an \InvalidArgumentException if namespace does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->find() throws an \InvalidArgumentException if namespace does not exist'); - $this->assertRegExp('/There are no commands defined in the "foo2" namespace./', $e->getMessage(), '->find() throws an \InvalidArgumentException if namespace does not exist, with alternative'); - $this->assertRegExp('/foo/', $e->getMessage(), '->find() throws an \InvalidArgumentException if namespace does not exist, with alternative : "foo"'); - $this->assertRegExp('/foo1/', $e->getMessage(), '->find() throws an \InvalidArgumentException if namespace does not exist, with alternative : "foo1"'); - $this->assertRegExp('/foo3/', $e->getMessage(), '->find() throws an \InvalidArgumentException if namespace does not exist, with alternative : "foo3"'); - } - } - - public function testFindNamespaceDoesNotFailOnDeepSimilarNamespaces() - { - $application = $this->getMock('Symfony\Component\Console\Application', array('getNamespaces')); - $application->expects($this->once()) - ->method('getNamespaces') - ->will($this->returnValue(array('foo:sublong', 'bar:sub'))); - - $this->assertEquals('foo:sublong', $application->findNamespace('f:sub')); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Command "foo::bar" is not defined. - */ - public function testFindWithDoubleColonInNameThrowsException() - { - $application = new Application(); - $application->add(new \FooCommand()); - $application->add(new \Foo4Command()); - $application->find('foo::bar'); - } - - public function testSetCatchExceptions() - { - $application = $this->getMock('Symfony\Component\Console\Application', array('getTerminalWidth')); - $application->setAutoExit(false); - $application->expects($this->any()) - ->method('getTerminalWidth') - ->will($this->returnValue(120)); - $tester = new ApplicationTester($application); - - $application->setCatchExceptions(true); - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception1.txt', $tester->getDisplay(true), '->setCatchExceptions() sets the catch exception flag'); - - $application->setCatchExceptions(false); - try { - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->fail('->setCatchExceptions() sets the catch exception flag'); - } catch (\Exception $e) { - $this->assertInstanceOf('\Exception', $e, '->setCatchExceptions() sets the catch exception flag'); - $this->assertEquals('Command "foo" is not defined.', $e->getMessage(), '->setCatchExceptions() sets the catch exception flag'); - } - } - - /** - * @group legacy - */ - public function testLegacyAsText() - { - $application = new Application(); - $application->add(new \FooCommand()); - $this->ensureStaticCommandHelp($application); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_astext1.txt', $this->normalizeLineBreaks($application->asText()), '->asText() returns a text representation of the application'); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_astext2.txt', $this->normalizeLineBreaks($application->asText('foo')), '->asText() returns a text representation of the application'); - } - - /** - * @group legacy - */ - public function testLegacyAsXml() - { - $application = new Application(); - $application->add(new \FooCommand()); - $this->ensureStaticCommandHelp($application); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/application_asxml1.txt', $application->asXml(), '->asXml() returns an XML representation of the application'); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/application_asxml2.txt', $application->asXml('foo'), '->asXml() returns an XML representation of the application'); - } - - public function testRenderException() - { - $application = $this->getMock('Symfony\Component\Console\Application', array('getTerminalWidth')); - $application->setAutoExit(false); - $application->expects($this->any()) - ->method('getTerminalWidth') - ->will($this->returnValue(120)); - $tester = new ApplicationTester($application); - - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception1.txt', $tester->getDisplay(true), '->renderException() renders a pretty exception'); - - $tester->run(array('command' => 'foo'), array('decorated' => false, 'verbosity' => Output::VERBOSITY_VERBOSE)); - $this->assertContains('Exception trace', $tester->getDisplay(), '->renderException() renders a pretty exception with a stack trace when verbosity is verbose'); - - $tester->run(array('command' => 'list', '--foo' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception2.txt', $tester->getDisplay(true), '->renderException() renders the command synopsis when an exception occurs in the context of a command'); - - $application->add(new \Foo3Command()); - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'foo3:bar'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception3.txt', $tester->getDisplay(true), '->renderException() renders a pretty exceptions with previous exceptions'); - - $tester->run(array('command' => 'foo3:bar'), array('decorated' => true)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception3decorated.txt', $tester->getDisplay(true), '->renderException() renders a pretty exceptions with previous exceptions'); - - $application = $this->getMock('Symfony\Component\Console\Application', array('getTerminalWidth')); - $application->setAutoExit(false); - $application->expects($this->any()) - ->method('getTerminalWidth') - ->will($this->returnValue(32)); - $tester = new ApplicationTester($application); - - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception4.txt', $tester->getDisplay(true), '->renderException() wraps messages when they are bigger than the terminal'); - } - - public function testRenderExceptionWithDoubleWidthCharacters() - { - if (!function_exists('mb_strwidth')) { - $this->markTestSkipped('The "mb_strwidth" function is not available'); - } - - $application = $this->getMock('Symfony\Component\Console\Application', array('getTerminalWidth')); - $application->setAutoExit(false); - $application->expects($this->any()) - ->method('getTerminalWidth') - ->will($this->returnValue(120)); - $application->register('foo')->setCode(function () { - throw new \Exception('エラーメッセージ'); - }); - $tester = new ApplicationTester($application); - - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception_doublewidth1.txt', $tester->getDisplay(true), '->renderException() renders a pretty exceptions with previous exceptions'); - - $tester->run(array('command' => 'foo'), array('decorated' => true)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception_doublewidth1decorated.txt', $tester->getDisplay(true), '->renderException() renders a pretty exceptions with previous exceptions'); - - $application = $this->getMock('Symfony\Component\Console\Application', array('getTerminalWidth')); - $application->setAutoExit(false); - $application->expects($this->any()) - ->method('getTerminalWidth') - ->will($this->returnValue(32)); - $application->register('foo')->setCode(function () { - throw new \Exception('コマンドの実行中にエラーが発生しました。'); - }); - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'foo'), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_renderexception_doublewidth2.txt', $tester->getDisplay(true), '->renderException() wraps messages when they are bigger than the terminal'); - } - - public function testRun() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - $application->add($command = new \Foo1Command()); - $_SERVER['argv'] = array('cli.php', 'foo:bar1'); - - ob_start(); - $application->run(); - ob_end_clean(); - - $this->assertInstanceOf('Symfony\Component\Console\Input\ArgvInput', $command->input, '->run() creates an ArgvInput by default if none is given'); - $this->assertInstanceOf('Symfony\Component\Console\Output\ConsoleOutput', $command->output, '->run() creates a ConsoleOutput by default if none is given'); - - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $this->ensureStaticCommandHelp($application); - $tester = new ApplicationTester($application); - - $tester->run(array(), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run1.txt', $tester->getDisplay(true), '->run() runs the list command if no argument is passed'); - - $tester->run(array('--help' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run2.txt', $tester->getDisplay(true), '->run() runs the help command if --help is passed'); - - $tester->run(array('-h' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run2.txt', $tester->getDisplay(true), '->run() runs the help command if -h is passed'); - - $tester->run(array('command' => 'list', '--help' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run3.txt', $tester->getDisplay(true), '->run() displays the help if --help is passed'); - - $tester->run(array('command' => 'list', '-h' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run3.txt', $tester->getDisplay(true), '->run() displays the help if -h is passed'); - - $tester->run(array('--ansi' => true)); - $this->assertTrue($tester->getOutput()->isDecorated(), '->run() forces color output if --ansi is passed'); - - $tester->run(array('--no-ansi' => true)); - $this->assertFalse($tester->getOutput()->isDecorated(), '->run() forces color output to be disabled if --no-ansi is passed'); - - $tester->run(array('--version' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run4.txt', $tester->getDisplay(true), '->run() displays the program version if --version is passed'); - - $tester->run(array('-V' => true), array('decorated' => false)); - $this->assertStringEqualsFile(self::$fixturesPath.'/application_run4.txt', $tester->getDisplay(true), '->run() displays the program version if -v is passed'); - - $tester->run(array('command' => 'list', '--quiet' => true)); - $this->assertSame('', $tester->getDisplay(), '->run() removes all output if --quiet is passed'); - - $tester->run(array('command' => 'list', '-q' => true)); - $this->assertSame('', $tester->getDisplay(), '->run() removes all output if -q is passed'); - - $tester->run(array('command' => 'list', '--verbose' => true)); - $this->assertSame(Output::VERBOSITY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if --verbose is passed'); - - $tester->run(array('command' => 'list', '--verbose' => 1)); - $this->assertSame(Output::VERBOSITY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if --verbose=1 is passed'); - - $tester->run(array('command' => 'list', '--verbose' => 2)); - $this->assertSame(Output::VERBOSITY_VERY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to very verbose if --verbose=2 is passed'); - - $tester->run(array('command' => 'list', '--verbose' => 3)); - $this->assertSame(Output::VERBOSITY_DEBUG, $tester->getOutput()->getVerbosity(), '->run() sets the output to debug if --verbose=3 is passed'); - - $tester->run(array('command' => 'list', '--verbose' => 4)); - $this->assertSame(Output::VERBOSITY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if unknown --verbose level is passed'); - - $tester->run(array('command' => 'list', '-v' => true)); - $this->assertSame(Output::VERBOSITY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if -v is passed'); - - $tester->run(array('command' => 'list', '-vv' => true)); - $this->assertSame(Output::VERBOSITY_VERY_VERBOSE, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if -v is passed'); - - $tester->run(array('command' => 'list', '-vvv' => true)); - $this->assertSame(Output::VERBOSITY_DEBUG, $tester->getOutput()->getVerbosity(), '->run() sets the output to verbose if -v is passed'); - - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - $application->add(new \FooCommand()); - $tester = new ApplicationTester($application); - - $tester->run(array('command' => 'foo:bar', '--no-interaction' => true), array('decorated' => false)); - $this->assertSame('called'.PHP_EOL, $tester->getDisplay(), '->run() does not call interact() if --no-interaction is passed'); - - $tester->run(array('command' => 'foo:bar', '-n' => true), array('decorated' => false)); - $this->assertSame('called'.PHP_EOL, $tester->getDisplay(), '->run() does not call interact() if -n is passed'); - } - - /** - * Issue #9285. - * - * If the "verbose" option is just before an argument in ArgvInput, - * an argument value should not be treated as verbosity value. - * This test will fail with "Not enough arguments." if broken - */ - public function testVerboseValueNotBreakArguments() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - $application->add(new \FooCommand()); - - $output = new StreamOutput(fopen('php://memory', 'w', false)); - - $input = new ArgvInput(array('cli.php', '-v', 'foo:bar')); - $application->run($input, $output); - - $input = new ArgvInput(array('cli.php', '--verbose', 'foo:bar')); - $application->run($input, $output); - } - - public function testRunReturnsIntegerExitCode() - { - $exception = new \Exception('', 4); - - $application = $this->getMock('Symfony\Component\Console\Application', array('doRun')); - $application->setAutoExit(false); - $application->expects($this->once()) - ->method('doRun') - ->will($this->throwException($exception)); - - $exitCode = $application->run(new ArrayInput(array()), new NullOutput()); - - $this->assertSame(4, $exitCode, '->run() returns integer exit code extracted from raised exception'); - } - - public function testRunReturnsExitCodeOneForExceptionCodeZero() - { - $exception = new \Exception('', 0); - - $application = $this->getMock('Symfony\Component\Console\Application', array('doRun')); - $application->setAutoExit(false); - $application->expects($this->once()) - ->method('doRun') - ->will($this->throwException($exception)); - - $exitCode = $application->run(new ArrayInput(array()), new NullOutput()); - - $this->assertSame(1, $exitCode, '->run() returns exit code 1 when exception code is 0'); - } - - /** - * @expectedException \LogicException - * @dataProvider getAddingAlreadySetDefinitionElementData - */ - public function testAddingAlreadySetDefinitionElementData($def) - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - $application - ->register('foo') - ->setDefinition(array($def)) - ->setCode(function (InputInterface $input, OutputInterface $output) {}) - ; - - $input = new ArrayInput(array('command' => 'foo')); - $output = new NullOutput(); - $application->run($input, $output); - } - - public function getAddingAlreadySetDefinitionElementData() - { - return array( - array(new InputArgument('command', InputArgument::REQUIRED)), - array(new InputOption('quiet', '', InputOption::VALUE_NONE)), - array(new InputOption('query', 'q', InputOption::VALUE_NONE)), - ); - } - - public function testGetDefaultHelperSetReturnsDefaultValues() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $helperSet = $application->getHelperSet(); - - $this->assertTrue($helperSet->has('formatter')); - $this->assertTrue($helperSet->has('dialog')); - $this->assertTrue($helperSet->has('progress')); - } - - public function testAddingSingleHelperSetOverwritesDefaultValues() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $application->setHelperSet(new HelperSet(array(new FormatterHelper()))); - - $helperSet = $application->getHelperSet(); - - $this->assertTrue($helperSet->has('formatter')); - - // no other default helper set should be returned - $this->assertFalse($helperSet->has('dialog')); - $this->assertFalse($helperSet->has('progress')); - } - - public function testOverwritingDefaultHelperSetOverwritesDefaultValues() - { - $application = new CustomApplication(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $application->setHelperSet(new HelperSet(array(new FormatterHelper()))); - - $helperSet = $application->getHelperSet(); - - $this->assertTrue($helperSet->has('formatter')); - - // no other default helper set should be returned - $this->assertFalse($helperSet->has('dialog')); - $this->assertFalse($helperSet->has('progress')); - } - - public function testGetDefaultInputDefinitionReturnsDefaultValues() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $inputDefinition = $application->getDefinition(); - - $this->assertTrue($inputDefinition->hasArgument('command')); - - $this->assertTrue($inputDefinition->hasOption('help')); - $this->assertTrue($inputDefinition->hasOption('quiet')); - $this->assertTrue($inputDefinition->hasOption('verbose')); - $this->assertTrue($inputDefinition->hasOption('version')); - $this->assertTrue($inputDefinition->hasOption('ansi')); - $this->assertTrue($inputDefinition->hasOption('no-ansi')); - $this->assertTrue($inputDefinition->hasOption('no-interaction')); - } - - public function testOverwritingDefaultInputDefinitionOverwritesDefaultValues() - { - $application = new CustomApplication(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $inputDefinition = $application->getDefinition(); - - // check whether the default arguments and options are not returned any more - $this->assertFalse($inputDefinition->hasArgument('command')); - - $this->assertFalse($inputDefinition->hasOption('help')); - $this->assertFalse($inputDefinition->hasOption('quiet')); - $this->assertFalse($inputDefinition->hasOption('verbose')); - $this->assertFalse($inputDefinition->hasOption('version')); - $this->assertFalse($inputDefinition->hasOption('ansi')); - $this->assertFalse($inputDefinition->hasOption('no-ansi')); - $this->assertFalse($inputDefinition->hasOption('no-interaction')); - - $this->assertTrue($inputDefinition->hasOption('custom')); - } - - public function testSettingCustomInputDefinitionOverwritesDefaultValues() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $application->setDefinition(new InputDefinition(array(new InputOption('--custom', '-c', InputOption::VALUE_NONE, 'Set the custom input definition.')))); - - $inputDefinition = $application->getDefinition(); - - // check whether the default arguments and options are not returned any more - $this->assertFalse($inputDefinition->hasArgument('command')); - - $this->assertFalse($inputDefinition->hasOption('help')); - $this->assertFalse($inputDefinition->hasOption('quiet')); - $this->assertFalse($inputDefinition->hasOption('verbose')); - $this->assertFalse($inputDefinition->hasOption('version')); - $this->assertFalse($inputDefinition->hasOption('ansi')); - $this->assertFalse($inputDefinition->hasOption('no-ansi')); - $this->assertFalse($inputDefinition->hasOption('no-interaction')); - - $this->assertTrue($inputDefinition->hasOption('custom')); - } - - public function testRunWithDispatcher() - { - $application = new Application(); - $application->setAutoExit(false); - $application->setDispatcher($this->getDispatcher()); - - $application->register('foo')->setCode(function (InputInterface $input, OutputInterface $output) { - $output->write('foo.'); - }); - - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'foo')); - $this->assertEquals('before.foo.after.'.PHP_EOL, $tester->getDisplay()); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage caught - */ - public function testRunWithExceptionAndDispatcher() - { - $application = new Application(); - $application->setDispatcher($this->getDispatcher()); - $application->setAutoExit(false); - $application->setCatchExceptions(false); - - $application->register('foo')->setCode(function (InputInterface $input, OutputInterface $output) { - throw new \RuntimeException('foo'); - }); - - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'foo')); - } - - public function testRunDispatchesAllEventsWithException() - { - $application = new Application(); - $application->setDispatcher($this->getDispatcher()); - $application->setAutoExit(false); - - $application->register('foo')->setCode(function (InputInterface $input, OutputInterface $output) { - $output->write('foo.'); - - throw new \RuntimeException('foo'); - }); - - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'foo')); - $this->assertContains('before.foo.caught.after.', $tester->getDisplay()); - } - - public function testRunWithDispatcherSkippingCommand() - { - $application = new Application(); - $application->setDispatcher($this->getDispatcher(true)); - $application->setAutoExit(false); - - $application->register('foo')->setCode(function (InputInterface $input, OutputInterface $output) { - $output->write('foo.'); - }); - - $tester = new ApplicationTester($application); - $exitCode = $tester->run(array('command' => 'foo')); - $this->assertContains('before.after.', $tester->getDisplay()); - $this->assertEquals(ConsoleCommandEvent::RETURN_CODE_DISABLED, $exitCode); - } - - public function testTerminalDimensions() - { - $application = new Application(); - $originalDimensions = $application->getTerminalDimensions(); - $this->assertCount(2, $originalDimensions); - - $width = 80; - if ($originalDimensions[0] == $width) { - $width = 100; - } - - $application->setTerminalDimensions($width, 80); - $this->assertSame(array($width, 80), $application->getTerminalDimensions()); - } - - protected function getDispatcher($skipCommand = false) - { - $dispatcher = new EventDispatcher(); - $dispatcher->addListener('console.command', function (ConsoleCommandEvent $event) use ($skipCommand) { - $event->getOutput()->write('before.'); - - if ($skipCommand) { - $event->disableCommand(); - } - }); - $dispatcher->addListener('console.terminate', function (ConsoleTerminateEvent $event) use ($skipCommand) { - $event->getOutput()->writeln('after.'); - - if (!$skipCommand) { - $event->setExitCode(113); - } - }); - $dispatcher->addListener('console.exception', function (ConsoleExceptionEvent $event) { - $event->getOutput()->write('caught.'); - - $event->setException(new \LogicException('caught.', $event->getExitCode(), $event->getException())); - }); - - return $dispatcher; - } - - public function testSetRunCustomDefaultCommand() - { - $command = new \FooCommand(); - - $application = new Application(); - $application->setAutoExit(false); - $application->add($command); - $application->setDefaultCommand($command->getName()); - - $tester = new ApplicationTester($application); - $tester->run(array()); - $this->assertEquals('interact called'.PHP_EOL.'called'.PHP_EOL, $tester->getDisplay(), 'Application runs the default set command if different from \'list\' command'); - - $application = new CustomDefaultCommandApplication(); - $application->setAutoExit(false); - - $tester = new ApplicationTester($application); - $tester->run(array()); - - $this->assertEquals('interact called'.PHP_EOL.'called'.PHP_EOL, $tester->getDisplay(), 'Application runs the default set command if different from \'list\' command'); - } - - public function testCanCheckIfTerminalIsInteractive() - { - if (!function_exists('posix_isatty')) { - $this->markTestSkipped('posix_isatty function is required'); - } - - $application = new CustomDefaultCommandApplication(); - $application->setAutoExit(false); - - $tester = new ApplicationTester($application); - $tester->run(array('command' => 'help')); - - $this->assertFalse($tester->getInput()->hasParameterOption(array('--no-interaction', '-n'))); - - $inputStream = $application->getHelperSet()->get('question')->getInputStream(); - $this->assertEquals($tester->getInput()->isInteractive(), @posix_isatty($inputStream)); - } -} - -class CustomApplication extends Application -{ - /** - * Overwrites the default input definition. - * - * @return InputDefinition An InputDefinition instance - */ - protected function getDefaultInputDefinition() - { - return new InputDefinition(array(new InputOption('--custom', '-c', InputOption::VALUE_NONE, 'Set the custom input definition.'))); - } - - /** - * Gets the default helper set with the helpers that should always be available. - * - * @return HelperSet A HelperSet instance - */ - protected function getDefaultHelperSet() - { - return new HelperSet(array(new FormatterHelper())); - } -} - -class CustomDefaultCommandApplication extends Application -{ - /** - * Overwrites the constructor in order to set a different default command. - */ - public function __construct() - { - parent::__construct(); - - $command = new \FooCommand(); - $this->add($command); - $this->setDefaultCommand($command->getName()); - } -} diff --git a/vendor/symfony/console/Tests/ClockMock.php b/vendor/symfony/console/Tests/ClockMock.php deleted file mode 100644 index 0e9231662..000000000 --- a/vendor/symfony/console/Tests/ClockMock.php +++ /dev/null @@ -1,41 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Helper; - -use Symfony\Component\Console\Tests; - -function time() -{ - return Tests\time(); -} - -namespace Symfony\Component\Console\Tests; - -function with_clock_mock($enable = null) -{ - static $enabled; - - if (null === $enable) { - return $enabled; - } - - $enabled = $enable; -} - -function time() -{ - if (!with_clock_mock()) { - return \time(); - } - - return $_SERVER['REQUEST_TIME']; -} diff --git a/vendor/symfony/console/Tests/Command/CommandTest.php b/vendor/symfony/console/Tests/Command/CommandTest.php deleted file mode 100644 index 7ab993bbc..000000000 --- a/vendor/symfony/console/Tests/Command/CommandTest.php +++ /dev/null @@ -1,337 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Command; - -use Symfony\Component\Console\Command\Command; -use Symfony\Component\Console\Helper\FormatterHelper; -use Symfony\Component\Console\Application; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; -use Symfony\Component\Console\Input\InputInterface; -use Symfony\Component\Console\Input\StringInput; -use Symfony\Component\Console\Output\OutputInterface; -use Symfony\Component\Console\Output\NullOutput; -use Symfony\Component\Console\Tester\CommandTester; - -class CommandTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = __DIR__.'/../Fixtures/'; - require_once self::$fixturesPath.'/TestCommand.php'; - } - - public function testConstructor() - { - $command = new Command('foo:bar'); - $this->assertEquals('foo:bar', $command->getName(), '__construct() takes the command name as its first argument'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage The command defined in "Symfony\Component\Console\Command\Command" cannot have an empty name. - */ - public function testCommandNameCannotBeEmpty() - { - new Command(); - } - - public function testSetApplication() - { - $application = new Application(); - $command = new \TestCommand(); - $command->setApplication($application); - $this->assertEquals($application, $command->getApplication(), '->setApplication() sets the current application'); - } - - public function testSetGetDefinition() - { - $command = new \TestCommand(); - $ret = $command->setDefinition($definition = new InputDefinition()); - $this->assertEquals($command, $ret, '->setDefinition() implements a fluent interface'); - $this->assertEquals($definition, $command->getDefinition(), '->setDefinition() sets the current InputDefinition instance'); - $command->setDefinition(array(new InputArgument('foo'), new InputOption('bar'))); - $this->assertTrue($command->getDefinition()->hasArgument('foo'), '->setDefinition() also takes an array of InputArguments and InputOptions as an argument'); - $this->assertTrue($command->getDefinition()->hasOption('bar'), '->setDefinition() also takes an array of InputArguments and InputOptions as an argument'); - $command->setDefinition(new InputDefinition()); - } - - public function testAddArgument() - { - $command = new \TestCommand(); - $ret = $command->addArgument('foo'); - $this->assertEquals($command, $ret, '->addArgument() implements a fluent interface'); - $this->assertTrue($command->getDefinition()->hasArgument('foo'), '->addArgument() adds an argument to the command'); - } - - public function testAddOption() - { - $command = new \TestCommand(); - $ret = $command->addOption('foo'); - $this->assertEquals($command, $ret, '->addOption() implements a fluent interface'); - $this->assertTrue($command->getDefinition()->hasOption('foo'), '->addOption() adds an option to the command'); - } - - public function testGetNamespaceGetNameSetName() - { - $command = new \TestCommand(); - $this->assertEquals('namespace:name', $command->getName(), '->getName() returns the command name'); - $command->setName('foo'); - $this->assertEquals('foo', $command->getName(), '->setName() sets the command name'); - - $ret = $command->setName('foobar:bar'); - $this->assertEquals($command, $ret, '->setName() implements a fluent interface'); - $this->assertEquals('foobar:bar', $command->getName(), '->setName() sets the command name'); - } - - /** - * @dataProvider provideInvalidCommandNames - */ - public function testInvalidCommandNames($name) - { - $this->setExpectedException('InvalidArgumentException', sprintf('Command name "%s" is invalid.', $name)); - - $command = new \TestCommand(); - $command->setName($name); - } - - public function provideInvalidCommandNames() - { - return array( - array(''), - array('foo:'), - ); - } - - public function testGetSetDescription() - { - $command = new \TestCommand(); - $this->assertEquals('description', $command->getDescription(), '->getDescription() returns the description'); - $ret = $command->setDescription('description1'); - $this->assertEquals($command, $ret, '->setDescription() implements a fluent interface'); - $this->assertEquals('description1', $command->getDescription(), '->setDescription() sets the description'); - } - - public function testGetSetHelp() - { - $command = new \TestCommand(); - $this->assertEquals('help', $command->getHelp(), '->getHelp() returns the help'); - $ret = $command->setHelp('help1'); - $this->assertEquals($command, $ret, '->setHelp() implements a fluent interface'); - $this->assertEquals('help1', $command->getHelp(), '->setHelp() sets the help'); - $command->setHelp(''); - $this->assertEquals('description', $command->getHelp(), '->getHelp() fallback to the description'); - } - - public function testGetProcessedHelp() - { - $command = new \TestCommand(); - $command->setHelp('The %command.name% command does... Example: php %command.full_name%.'); - $this->assertContains('The namespace:name command does...', $command->getProcessedHelp(), '->getProcessedHelp() replaces %command.name% correctly'); - $this->assertNotContains('%command.full_name%', $command->getProcessedHelp(), '->getProcessedHelp() replaces %command.full_name%'); - } - - public function testGetSetAliases() - { - $command = new \TestCommand(); - $this->assertEquals(array('name'), $command->getAliases(), '->getAliases() returns the aliases'); - $ret = $command->setAliases(array('name1')); - $this->assertEquals($command, $ret, '->setAliases() implements a fluent interface'); - $this->assertEquals(array('name1'), $command->getAliases(), '->setAliases() sets the aliases'); - } - - public function testGetSynopsis() - { - $command = new \TestCommand(); - $command->addOption('foo'); - $command->addArgument('bar'); - $this->assertEquals('namespace:name [--foo] [--] []', $command->getSynopsis(), '->getSynopsis() returns the synopsis'); - } - - public function testGetHelper() - { - $application = new Application(); - $command = new \TestCommand(); - $command->setApplication($application); - $formatterHelper = new FormatterHelper(); - $this->assertEquals($formatterHelper->getName(), $command->getHelper('formatter')->getName(), '->getHelper() returns the correct helper'); - } - - public function testMergeApplicationDefinition() - { - $application1 = new Application(); - $application1->getDefinition()->addArguments(array(new InputArgument('foo'))); - $application1->getDefinition()->addOptions(array(new InputOption('bar'))); - $command = new \TestCommand(); - $command->setApplication($application1); - $command->setDefinition($definition = new InputDefinition(array(new InputArgument('bar'), new InputOption('foo')))); - - $r = new \ReflectionObject($command); - $m = $r->getMethod('mergeApplicationDefinition'); - $m->setAccessible(true); - $m->invoke($command); - $this->assertTrue($command->getDefinition()->hasArgument('foo'), '->mergeApplicationDefinition() merges the application arguments and the command arguments'); - $this->assertTrue($command->getDefinition()->hasArgument('bar'), '->mergeApplicationDefinition() merges the application arguments and the command arguments'); - $this->assertTrue($command->getDefinition()->hasOption('foo'), '->mergeApplicationDefinition() merges the application options and the command options'); - $this->assertTrue($command->getDefinition()->hasOption('bar'), '->mergeApplicationDefinition() merges the application options and the command options'); - - $m->invoke($command); - $this->assertEquals(3, $command->getDefinition()->getArgumentCount(), '->mergeApplicationDefinition() does not try to merge twice the application arguments and options'); - } - - public function testMergeApplicationDefinitionWithoutArgsThenWithArgsAddsArgs() - { - $application1 = new Application(); - $application1->getDefinition()->addArguments(array(new InputArgument('foo'))); - $application1->getDefinition()->addOptions(array(new InputOption('bar'))); - $command = new \TestCommand(); - $command->setApplication($application1); - $command->setDefinition($definition = new InputDefinition(array())); - - $r = new \ReflectionObject($command); - $m = $r->getMethod('mergeApplicationDefinition'); - $m->setAccessible(true); - $m->invoke($command, false); - $this->assertTrue($command->getDefinition()->hasOption('bar'), '->mergeApplicationDefinition(false) merges the application and the command options'); - $this->assertFalse($command->getDefinition()->hasArgument('foo'), '->mergeApplicationDefinition(false) does not merge the application arguments'); - - $m->invoke($command, true); - $this->assertTrue($command->getDefinition()->hasArgument('foo'), '->mergeApplicationDefinition(true) merges the application arguments and the command arguments'); - - $m->invoke($command); - $this->assertEquals(2, $command->getDefinition()->getArgumentCount(), '->mergeApplicationDefinition() does not try to merge twice the application arguments'); - } - - public function testRunInteractive() - { - $tester = new CommandTester(new \TestCommand()); - - $tester->execute(array(), array('interactive' => true)); - - $this->assertEquals('interact called'.PHP_EOL.'execute called'.PHP_EOL, $tester->getDisplay(), '->run() calls the interact() method if the input is interactive'); - } - - public function testRunNonInteractive() - { - $tester = new CommandTester(new \TestCommand()); - - $tester->execute(array(), array('interactive' => false)); - - $this->assertEquals('execute called'.PHP_EOL, $tester->getDisplay(), '->run() does not call the interact() method if the input is not interactive'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage You must override the execute() method in the concrete command class. - */ - public function testExecuteMethodNeedsToBeOverridden() - { - $command = new Command('foo'); - $command->run(new StringInput(''), new NullOutput()); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "--bar" option does not exist. - */ - public function testRunWithInvalidOption() - { - $command = new \TestCommand(); - $tester = new CommandTester($command); - $tester->execute(array('--bar' => true)); - } - - public function testRunReturnsIntegerExitCode() - { - $command = new \TestCommand(); - $exitCode = $command->run(new StringInput(''), new NullOutput()); - $this->assertSame(0, $exitCode, '->run() returns integer exit code (treats null as 0)'); - - $command = $this->getMock('TestCommand', array('execute')); - $command->expects($this->once()) - ->method('execute') - ->will($this->returnValue('2.3')); - $exitCode = $command->run(new StringInput(''), new NullOutput()); - $this->assertSame(2, $exitCode, '->run() returns integer exit code (casts numeric to int)'); - } - - public function testRunReturnsAlwaysInteger() - { - $command = new \TestCommand(); - - $this->assertSame(0, $command->run(new StringInput(''), new NullOutput())); - } - - public function testSetCode() - { - $command = new \TestCommand(); - $ret = $command->setCode(function (InputInterface $input, OutputInterface $output) { - $output->writeln('from the code...'); - }); - $this->assertEquals($command, $ret, '->setCode() implements a fluent interface'); - $tester = new CommandTester($command); - $tester->execute(array()); - $this->assertEquals('interact called'.PHP_EOL.'from the code...'.PHP_EOL, $tester->getDisplay()); - } - - public function testSetCodeWithNonClosureCallable() - { - $command = new \TestCommand(); - $ret = $command->setCode(array($this, 'callableMethodCommand')); - $this->assertEquals($command, $ret, '->setCode() implements a fluent interface'); - $tester = new CommandTester($command); - $tester->execute(array()); - $this->assertEquals('interact called'.PHP_EOL.'from the code...'.PHP_EOL, $tester->getDisplay()); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Invalid callable provided to Command::setCode. - */ - public function testSetCodeWithNonCallable() - { - $command = new \TestCommand(); - $command->setCode(array($this, 'nonExistentMethod')); - } - - public function callableMethodCommand(InputInterface $input, OutputInterface $output) - { - $output->writeln('from the code...'); - } - - /** - * @group legacy - */ - public function testLegacyAsText() - { - $command = new \TestCommand(); - $command->setApplication(new Application()); - $tester = new CommandTester($command); - $tester->execute(array('command' => $command->getName())); - $this->assertStringEqualsFile(self::$fixturesPath.'/command_astext.txt', $command->asText(), '->asText() returns a text representation of the command'); - } - - /** - * @group legacy - */ - public function testLegacyAsXml() - { - $command = new \TestCommand(); - $command->setApplication(new Application()); - $tester = new CommandTester($command); - $tester->execute(array('command' => $command->getName())); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/command_asxml.txt', $command->asXml(), '->asXml() returns an XML representation of the command'); - } -} diff --git a/vendor/symfony/console/Tests/Command/HelpCommandTest.php b/vendor/symfony/console/Tests/Command/HelpCommandTest.php deleted file mode 100644 index 9e068587f..000000000 --- a/vendor/symfony/console/Tests/Command/HelpCommandTest.php +++ /dev/null @@ -1,70 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Command; - -use Symfony\Component\Console\Tester\CommandTester; -use Symfony\Component\Console\Command\HelpCommand; -use Symfony\Component\Console\Command\ListCommand; -use Symfony\Component\Console\Application; - -class HelpCommandTest extends \PHPUnit_Framework_TestCase -{ - public function testExecuteForCommandAlias() - { - $command = new HelpCommand(); - $command->setApplication(new Application()); - $commandTester = new CommandTester($command); - $commandTester->execute(array('command_name' => 'li'), array('decorated' => false)); - $this->assertContains('list [options] [--] []', $commandTester->getDisplay(), '->execute() returns a text help for the given command alias'); - $this->assertContains('format=FORMAT', $commandTester->getDisplay(), '->execute() returns a text help for the given command alias'); - $this->assertContains('raw', $commandTester->getDisplay(), '->execute() returns a text help for the given command alias'); - } - - public function testExecuteForCommand() - { - $command = new HelpCommand(); - $commandTester = new CommandTester($command); - $command->setCommand(new ListCommand()); - $commandTester->execute(array(), array('decorated' => false)); - $this->assertContains('list [options] [--] []', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - $this->assertContains('format=FORMAT', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - $this->assertContains('raw', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - } - - public function testExecuteForCommandWithXmlOption() - { - $command = new HelpCommand(); - $commandTester = new CommandTester($command); - $command->setCommand(new ListCommand()); - $commandTester->execute(array('--format' => 'xml')); - $this->assertContains('getDisplay(), '->execute() returns an XML help text if --xml is passed'); - } - - public function testExecuteForApplicationCommand() - { - $application = new Application(); - $commandTester = new CommandTester($application->get('help')); - $commandTester->execute(array('command_name' => 'list')); - $this->assertContains('list [options] [--] []', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - $this->assertContains('format=FORMAT', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - $this->assertContains('raw', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - } - - public function testExecuteForApplicationCommandWithXmlOption() - { - $application = new Application(); - $commandTester = new CommandTester($application->get('help')); - $commandTester->execute(array('command_name' => 'list', '--format' => 'xml')); - $this->assertContains('list [--xml] [--raw] [--format FORMAT] [--] [<namespace>]', $commandTester->getDisplay(), '->execute() returns a text help for the given command'); - $this->assertContains('getDisplay(), '->execute() returns an XML help text if --format=xml is passed'); - } -} diff --git a/vendor/symfony/console/Tests/Command/ListCommandTest.php b/vendor/symfony/console/Tests/Command/ListCommandTest.php deleted file mode 100644 index 3578d4885..000000000 --- a/vendor/symfony/console/Tests/Command/ListCommandTest.php +++ /dev/null @@ -1,64 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Command; - -use Symfony\Component\Console\Tester\CommandTester; -use Symfony\Component\Console\Application; - -class ListCommandTest extends \PHPUnit_Framework_TestCase -{ - public function testExecuteListsCommands() - { - $application = new Application(); - $commandTester = new CommandTester($command = $application->get('list')); - $commandTester->execute(array('command' => $command->getName()), array('decorated' => false)); - - $this->assertRegExp('/help\s{2,}Displays help for a command/', $commandTester->getDisplay(), '->execute() returns a list of available commands'); - } - - public function testExecuteListsCommandsWithXmlOption() - { - $application = new Application(); - $commandTester = new CommandTester($command = $application->get('list')); - $commandTester->execute(array('command' => $command->getName(), '--format' => 'xml')); - $this->assertRegExp('//', $commandTester->getDisplay(), '->execute() returns a list of available commands in XML if --xml is passed'); - } - - public function testExecuteListsCommandsWithRawOption() - { - $application = new Application(); - $commandTester = new CommandTester($command = $application->get('list')); - $commandTester->execute(array('command' => $command->getName(), '--raw' => true)); - $output = <<assertEquals($output, $commandTester->getDisplay(true)); - } - - public function testExecuteListsCommandsWithNamespaceArgument() - { - require_once realpath(__DIR__.'/../Fixtures/FooCommand.php'); - $application = new Application(); - $application->add(new \FooCommand()); - $commandTester = new CommandTester($command = $application->get('list')); - $commandTester->execute(array('command' => $command->getName(), 'namespace' => 'foo', '--raw' => true)); - $output = <<assertEquals($output, $commandTester->getDisplay(true)); - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/AbstractDescriptorTest.php b/vendor/symfony/console/Tests/Descriptor/AbstractDescriptorTest.php deleted file mode 100644 index f582e7f5a..000000000 --- a/vendor/symfony/console/Tests/Descriptor/AbstractDescriptorTest.php +++ /dev/null @@ -1,105 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Application; -use Symfony\Component\Console\Command\Command; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputOption; -use Symfony\Component\Console\Output\BufferedOutput; - -abstract class AbstractDescriptorTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getDescribeInputArgumentTestData */ - public function testDescribeInputArgument(InputArgument $argument, $expectedDescription) - { - $this->assertDescription($expectedDescription, $argument); - } - - /** @dataProvider getDescribeInputOptionTestData */ - public function testDescribeInputOption(InputOption $option, $expectedDescription) - { - $this->assertDescription($expectedDescription, $option); - } - - /** @dataProvider getDescribeInputDefinitionTestData */ - public function testDescribeInputDefinition(InputDefinition $definition, $expectedDescription) - { - $this->assertDescription($expectedDescription, $definition); - } - - /** @dataProvider getDescribeCommandTestData */ - public function testDescribeCommand(Command $command, $expectedDescription) - { - $this->assertDescription($expectedDescription, $command); - } - - /** @dataProvider getDescribeApplicationTestData */ - public function testDescribeApplication(Application $application, $expectedDescription) - { - // Replaces the dynamic placeholders of the command help text with a static version. - // The placeholder %command.full_name% includes the script path that is not predictable - // and can not be tested against. - foreach ($application->all() as $command) { - $command->setHelp(str_replace('%command.full_name%', 'app/console %command.name%', $command->getHelp())); - } - - $this->assertDescription($expectedDescription, $application); - } - - public function getDescribeInputArgumentTestData() - { - return $this->getDescriptionTestData(ObjectsProvider::getInputArguments()); - } - - public function getDescribeInputOptionTestData() - { - return $this->getDescriptionTestData(ObjectsProvider::getInputOptions()); - } - - public function getDescribeInputDefinitionTestData() - { - return $this->getDescriptionTestData(ObjectsProvider::getInputDefinitions()); - } - - public function getDescribeCommandTestData() - { - return $this->getDescriptionTestData(ObjectsProvider::getCommands()); - } - - public function getDescribeApplicationTestData() - { - return $this->getDescriptionTestData(ObjectsProvider::getApplications()); - } - - abstract protected function getDescriptor(); - abstract protected function getFormat(); - - private function getDescriptionTestData(array $objects) - { - $data = array(); - foreach ($objects as $name => $object) { - $description = file_get_contents(sprintf('%s/../Fixtures/%s.%s', __DIR__, $name, $this->getFormat())); - $data[] = array($object, $description); - } - - return $data; - } - - protected function assertDescription($expectedDescription, $describedObject) - { - $output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, true); - $this->getDescriptor()->describe($output, $describedObject, array('raw_output' => true)); - $this->assertEquals(trim($expectedDescription), trim(str_replace(PHP_EOL, "\n", $output->fetch()))); - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/JsonDescriptorTest.php b/vendor/symfony/console/Tests/Descriptor/JsonDescriptorTest.php deleted file mode 100644 index f9a15612b..000000000 --- a/vendor/symfony/console/Tests/Descriptor/JsonDescriptorTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Descriptor\JsonDescriptor; -use Symfony\Component\Console\Output\BufferedOutput; - -class JsonDescriptorTest extends AbstractDescriptorTest -{ - protected function getDescriptor() - { - return new JsonDescriptor(); - } - - protected function getFormat() - { - return 'json'; - } - - protected function assertDescription($expectedDescription, $describedObject) - { - $output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, true); - $this->getDescriptor()->describe($output, $describedObject, array('raw_output' => true)); - $this->assertEquals(json_decode(trim($expectedDescription), true), json_decode(trim(str_replace(PHP_EOL, "\n", $output->fetch())), true)); - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/MarkdownDescriptorTest.php b/vendor/symfony/console/Tests/Descriptor/MarkdownDescriptorTest.php deleted file mode 100644 index c85e8a594..000000000 --- a/vendor/symfony/console/Tests/Descriptor/MarkdownDescriptorTest.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Descriptor\MarkdownDescriptor; - -class MarkdownDescriptorTest extends AbstractDescriptorTest -{ - protected function getDescriptor() - { - return new MarkdownDescriptor(); - } - - protected function getFormat() - { - return 'md'; - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/ObjectsProvider.php b/vendor/symfony/console/Tests/Descriptor/ObjectsProvider.php deleted file mode 100644 index 45b3b2fff..000000000 --- a/vendor/symfony/console/Tests/Descriptor/ObjectsProvider.php +++ /dev/null @@ -1,77 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputOption; -use Symfony\Component\Console\Tests\Fixtures\DescriptorApplication1; -use Symfony\Component\Console\Tests\Fixtures\DescriptorApplication2; -use Symfony\Component\Console\Tests\Fixtures\DescriptorCommand1; -use Symfony\Component\Console\Tests\Fixtures\DescriptorCommand2; - -/** - * @author Jean-François Simon - */ -class ObjectsProvider -{ - public static function getInputArguments() - { - return array( - 'input_argument_1' => new InputArgument('argument_name', InputArgument::REQUIRED), - 'input_argument_2' => new InputArgument('argument_name', InputArgument::IS_ARRAY, 'argument description'), - 'input_argument_3' => new InputArgument('argument_name', InputArgument::OPTIONAL, 'argument description', 'default_value'), - 'input_argument_4' => new InputArgument('argument_name', InputArgument::REQUIRED, "multiline\nargument description"), - ); - } - - public static function getInputOptions() - { - return array( - 'input_option_1' => new InputOption('option_name', 'o', InputOption::VALUE_NONE), - 'input_option_2' => new InputOption('option_name', 'o', InputOption::VALUE_OPTIONAL, 'option description', 'default_value'), - 'input_option_3' => new InputOption('option_name', 'o', InputOption::VALUE_REQUIRED, 'option description'), - 'input_option_4' => new InputOption('option_name', 'o', InputOption::VALUE_IS_ARRAY | InputOption::VALUE_OPTIONAL, 'option description', array()), - 'input_option_5' => new InputOption('option_name', 'o', InputOption::VALUE_REQUIRED, "multiline\noption description"), - 'input_option_6' => new InputOption('option_name', array('o', 'O'), InputOption::VALUE_REQUIRED, 'option with multiple shortcuts'), - ); - } - - public static function getInputDefinitions() - { - return array( - 'input_definition_1' => new InputDefinition(), - 'input_definition_2' => new InputDefinition(array(new InputArgument('argument_name', InputArgument::REQUIRED))), - 'input_definition_3' => new InputDefinition(array(new InputOption('option_name', 'o', InputOption::VALUE_NONE))), - 'input_definition_4' => new InputDefinition(array( - new InputArgument('argument_name', InputArgument::REQUIRED), - new InputOption('option_name', 'o', InputOption::VALUE_NONE), - )), - ); - } - - public static function getCommands() - { - return array( - 'command_1' => new DescriptorCommand1(), - 'command_2' => new DescriptorCommand2(), - ); - } - - public static function getApplications() - { - return array( - 'application_1' => new DescriptorApplication1(), - 'application_2' => new DescriptorApplication2(), - ); - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/TextDescriptorTest.php b/vendor/symfony/console/Tests/Descriptor/TextDescriptorTest.php deleted file mode 100644 index 350b67950..000000000 --- a/vendor/symfony/console/Tests/Descriptor/TextDescriptorTest.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Descriptor\TextDescriptor; - -class TextDescriptorTest extends AbstractDescriptorTest -{ - protected function getDescriptor() - { - return new TextDescriptor(); - } - - protected function getFormat() - { - return 'txt'; - } -} diff --git a/vendor/symfony/console/Tests/Descriptor/XmlDescriptorTest.php b/vendor/symfony/console/Tests/Descriptor/XmlDescriptorTest.php deleted file mode 100644 index 59a5d1ed8..000000000 --- a/vendor/symfony/console/Tests/Descriptor/XmlDescriptorTest.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Descriptor; - -use Symfony\Component\Console\Descriptor\XmlDescriptor; - -class XmlDescriptorTest extends AbstractDescriptorTest -{ - protected function getDescriptor() - { - return new XmlDescriptor(); - } - - protected function getFormat() - { - return 'xml'; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/BarBucCommand.php b/vendor/symfony/console/Tests/Fixtures/BarBucCommand.php deleted file mode 100644 index 52b619e82..000000000 --- a/vendor/symfony/console/Tests/Fixtures/BarBucCommand.php +++ /dev/null @@ -1,11 +0,0 @@ -setName('bar:buc'); - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/DescriptorApplication1.php b/vendor/symfony/console/Tests/Fixtures/DescriptorApplication1.php deleted file mode 100644 index 132b6d57d..000000000 --- a/vendor/symfony/console/Tests/Fixtures/DescriptorApplication1.php +++ /dev/null @@ -1,18 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Fixtures; - -use Symfony\Component\Console\Application; - -class DescriptorApplication1 extends Application -{ -} diff --git a/vendor/symfony/console/Tests/Fixtures/DescriptorApplication2.php b/vendor/symfony/console/Tests/Fixtures/DescriptorApplication2.php deleted file mode 100644 index ff5513580..000000000 --- a/vendor/symfony/console/Tests/Fixtures/DescriptorApplication2.php +++ /dev/null @@ -1,24 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Fixtures; - -use Symfony\Component\Console\Application; - -class DescriptorApplication2 extends Application -{ - public function __construct() - { - parent::__construct('My Symfony application', 'v1.0'); - $this->add(new DescriptorCommand1()); - $this->add(new DescriptorCommand2()); - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/DescriptorCommand1.php b/vendor/symfony/console/Tests/Fixtures/DescriptorCommand1.php deleted file mode 100644 index ede05d7a7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/DescriptorCommand1.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Fixtures; - -use Symfony\Component\Console\Command\Command; - -class DescriptorCommand1 extends Command -{ - protected function configure() - { - $this - ->setName('descriptor:command1') - ->setAliases(array('alias1', 'alias2')) - ->setDescription('command 1 description') - ->setHelp('command 1 help') - ; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/DescriptorCommand2.php b/vendor/symfony/console/Tests/Fixtures/DescriptorCommand2.php deleted file mode 100644 index 51106b961..000000000 --- a/vendor/symfony/console/Tests/Fixtures/DescriptorCommand2.php +++ /dev/null @@ -1,32 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Fixtures; - -use Symfony\Component\Console\Command\Command; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; - -class DescriptorCommand2 extends Command -{ - protected function configure() - { - $this - ->setName('descriptor:command2') - ->setDescription('command 2 description') - ->setHelp('command 2 help') - ->addUsage('-o|--option_name ') - ->addUsage('') - ->addArgument('argument_name', InputArgument::REQUIRED) - ->addOption('option_name', 'o', InputOption::VALUE_NONE) - ; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/DummyOutput.php b/vendor/symfony/console/Tests/Fixtures/DummyOutput.php deleted file mode 100644 index 0070c0a48..000000000 --- a/vendor/symfony/console/Tests/Fixtures/DummyOutput.php +++ /dev/null @@ -1,36 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Fixtures; - -use Symfony\Component\Console\Output\BufferedOutput; - -/** - * Dummy output. - * - * @author Kévin Dunglas - */ -class DummyOutput extends BufferedOutput -{ - /** - * @return array - */ - public function getLogs() - { - $logs = array(); - foreach (explode("\n", trim($this->fetch())) as $message) { - preg_match('/^\[(.*)\] (.*)/', $message, $matches); - $logs[] = sprintf('%s %s', $matches[1], $matches[2]); - } - - return $logs; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Foo1Command.php b/vendor/symfony/console/Tests/Fixtures/Foo1Command.php deleted file mode 100644 index 254162f32..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Foo1Command.php +++ /dev/null @@ -1,26 +0,0 @@ -setName('foo:bar1') - ->setDescription('The foo:bar1 command') - ->setAliases(array('afoobar1')) - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $this->input = $input; - $this->output = $output; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Foo2Command.php b/vendor/symfony/console/Tests/Fixtures/Foo2Command.php deleted file mode 100644 index 8071dc8fb..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Foo2Command.php +++ /dev/null @@ -1,21 +0,0 @@ -setName('foo1:bar') - ->setDescription('The foo1:bar command') - ->setAliases(array('afoobar2')) - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Foo3Command.php b/vendor/symfony/console/Tests/Fixtures/Foo3Command.php deleted file mode 100644 index 6c890faff..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Foo3Command.php +++ /dev/null @@ -1,29 +0,0 @@ -setName('foo3:bar') - ->setDescription('The foo3:bar command') - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - try { - try { - throw new \Exception('First exception

    this is html

    '); - } catch (\Exception $e) { - throw new \Exception('Second exception comment', 0, $e); - } - } catch (\Exception $e) { - throw new \Exception('Third exception comment', 0, $e); - } - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Foo4Command.php b/vendor/symfony/console/Tests/Fixtures/Foo4Command.php deleted file mode 100644 index 1c5463995..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Foo4Command.php +++ /dev/null @@ -1,11 +0,0 @@ -setName('foo3:bar:toh'); - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Foo5Command.php b/vendor/symfony/console/Tests/Fixtures/Foo5Command.php deleted file mode 100644 index a1c60827a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Foo5Command.php +++ /dev/null @@ -1,10 +0,0 @@ -setName('foo:bar') - ->setDescription('The foo:bar command') - ->setAliases(array('afoobar')) - ; - } - - protected function interact(InputInterface $input, OutputInterface $output) - { - $output->writeln('interact called'); - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $this->input = $input; - $this->output = $output; - - $output->writeln('called'); - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced1Command.php b/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced1Command.php deleted file mode 100644 index fc50c72bf..000000000 --- a/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced1Command.php +++ /dev/null @@ -1,26 +0,0 @@ -setName('foo:bar:baz') - ->setDescription('The foo:bar:baz command') - ->setAliases(array('foobarbaz')) - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $this->input = $input; - $this->output = $output; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced2Command.php b/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced2Command.php deleted file mode 100644 index 1cf31ff11..000000000 --- a/vendor/symfony/console/Tests/Fixtures/FooSubnamespaced2Command.php +++ /dev/null @@ -1,26 +0,0 @@ -setName('foo:go:bret') - ->setDescription('The foo:bar:go command') - ->setAliases(array('foobargo')) - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $this->input = $input; - $this->output = $output; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/FoobarCommand.php b/vendor/symfony/console/Tests/Fixtures/FoobarCommand.php deleted file mode 100644 index 968162804..000000000 --- a/vendor/symfony/console/Tests/Fixtures/FoobarCommand.php +++ /dev/null @@ -1,25 +0,0 @@ -setName('foobar:foo') - ->setDescription('The foobar:foo command') - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $this->input = $input; - $this->output = $output; - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_0.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_0.php deleted file mode 100644 index 8fe7c0771..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_0.php +++ /dev/null @@ -1,11 +0,0 @@ -caution('Lorem ipsum dolor sit amet'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_1.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_1.php deleted file mode 100644 index e5c700d60..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_1.php +++ /dev/null @@ -1,13 +0,0 @@ -title('Title'); - $output->warning('Lorem ipsum dolor sit amet'); - $output->title('Title'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_2.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_2.php deleted file mode 100644 index 791b626f2..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_2.php +++ /dev/null @@ -1,16 +0,0 @@ -warning('Warning'); - $output->caution('Caution'); - $output->error('Error'); - $output->success('Success'); - $output->note('Note'); - $output->block('Custom block', 'CUSTOM', 'fg=white;bg=green', 'X ', true); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_3.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_3.php deleted file mode 100644 index 99253a6c0..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_3.php +++ /dev/null @@ -1,12 +0,0 @@ -title('First title'); - $output->title('Second title'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_4.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_4.php deleted file mode 100644 index 0c5d3fb26..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_4.php +++ /dev/null @@ -1,34 +0,0 @@ -write('Lorem ipsum dolor sit amet'); - $output->title('First title'); - - $output->writeln('Lorem ipsum dolor sit amet'); - $output->title('Second title'); - - $output->write('Lorem ipsum dolor sit amet'); - $output->write(''); - $output->title('Third title'); - - //Ensure edge case by appending empty strings to history: - $output->write('Lorem ipsum dolor sit amet'); - $output->write(array('', '', '')); - $output->title('Fourth title'); - - //Ensure have manual control over number of blank lines: - $output->writeln('Lorem ipsum dolor sit amet'); - $output->writeln(array('', '')); //Should append an extra blank line - $output->title('Fifth title'); - - $output->writeln('Lorem ipsum dolor sit amet'); - $output->newLine(2); //Should append an extra blank line - $output->title('Fifth title'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_5.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_5.php deleted file mode 100644 index 4543ad8cd..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_5.php +++ /dev/null @@ -1,29 +0,0 @@ -writeln('Lorem ipsum dolor sit amet'); - $output->listing(array( - 'Lorem ipsum dolor sit amet', - 'consectetur adipiscing elit', - )); - - //Even using write: - $output->write('Lorem ipsum dolor sit amet'); - $output->listing(array( - 'Lorem ipsum dolor sit amet', - 'consectetur adipiscing elit', - )); - - $output->write('Lorem ipsum dolor sit amet'); - $output->text(array( - 'Lorem ipsum dolor sit amet', - 'consectetur adipiscing elit', - )); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_6.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_6.php deleted file mode 100644 index 8031ec9c3..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_6.php +++ /dev/null @@ -1,16 +0,0 @@ -listing(array( - 'Lorem ipsum dolor sit amet', - 'consectetur adipiscing elit', - )); - $output->success('Lorem ipsum dolor sit amet'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_7.php b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_7.php deleted file mode 100644 index 203eb5b12..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/command/command_7.php +++ /dev/null @@ -1,15 +0,0 @@ -title('Title'); - $output->askHidden('Hidden question'); - $output->choice('Choice question with default', array('choice1', 'choice2'), 'choice1'); - $output->confirm('Confirmation with yes default', true); - $output->text('Duis aute irure dolor in reprehenderit in voluptate velit esse'); -}; diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_0.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_0.txt deleted file mode 100644 index a42e0f792..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_0.txt +++ /dev/null @@ -1,3 +0,0 @@ - - ! [CAUTION] Lorem ipsum dolor sit amet - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_1.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_1.txt deleted file mode 100644 index 334875f78..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_1.txt +++ /dev/null @@ -1,9 +0,0 @@ - -Title -===== - - [WARNING] Lorem ipsum dolor sit amet - -Title -===== - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_2.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_2.txt deleted file mode 100644 index ca609760c..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_2.txt +++ /dev/null @@ -1,13 +0,0 @@ - - [WARNING] Warning - - ! [CAUTION] Caution - - [ERROR] Error - - [OK] Success - - ! [NOTE] Note - -X [CUSTOM] Custom block - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_3.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_3.txt deleted file mode 100644 index f4b6d5827..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_3.txt +++ /dev/null @@ -1,7 +0,0 @@ - -First title -=========== - -Second title -============ - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_4.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_4.txt deleted file mode 100644 index 2646d858e..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_4.txt +++ /dev/null @@ -1,32 +0,0 @@ -Lorem ipsum dolor sit amet - -First title -=========== - -Lorem ipsum dolor sit amet - -Second title -============ - -Lorem ipsum dolor sit amet - -Third title -=========== - -Lorem ipsum dolor sit amet - -Fourth title -============ - -Lorem ipsum dolor sit amet - - -Fifth title -=========== - -Lorem ipsum dolor sit amet - - -Fifth title -=========== - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_5.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_5.txt deleted file mode 100644 index 910240fbf..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_5.txt +++ /dev/null @@ -1,11 +0,0 @@ -Lorem ipsum dolor sit amet - * Lorem ipsum dolor sit amet - * consectetur adipiscing elit - -Lorem ipsum dolor sit amet - * Lorem ipsum dolor sit amet - * consectetur adipiscing elit - -Lorem ipsum dolor sit amet - // Lorem ipsum dolor sit amet - // consectetur adipiscing elit diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_6.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_6.txt deleted file mode 100644 index 5f2d33c14..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_6.txt +++ /dev/null @@ -1,6 +0,0 @@ - - * Lorem ipsum dolor sit amet - * consectetur adipiscing elit - - [OK] Lorem ipsum dolor sit amet - diff --git a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_7.txt b/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_7.txt deleted file mode 100644 index ab18e5dc7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/Style/SymfonyStyle/output/output_7.txt +++ /dev/null @@ -1,5 +0,0 @@ - -Title -===== - - // Duis aute irure dolor in reprehenderit in voluptate velit esse diff --git a/vendor/symfony/console/Tests/Fixtures/TestCommand.php b/vendor/symfony/console/Tests/Fixtures/TestCommand.php deleted file mode 100644 index dcd32739c..000000000 --- a/vendor/symfony/console/Tests/Fixtures/TestCommand.php +++ /dev/null @@ -1,28 +0,0 @@ -setName('namespace:name') - ->setAliases(array('name')) - ->setDescription('description') - ->setHelp('help') - ; - } - - protected function execute(InputInterface $input, OutputInterface $output) - { - $output->writeln('execute called'); - } - - protected function interact(InputInterface $input, OutputInterface $output) - { - $output->writeln('interact called'); - } -} diff --git a/vendor/symfony/console/Tests/Fixtures/application_1.json b/vendor/symfony/console/Tests/Fixtures/application_1.json deleted file mode 100644 index b17b38d8a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_1.json +++ /dev/null @@ -1 +0,0 @@ -{"commands":[{"name":"help","usage":["help [--xml] [--format FORMAT] [--raw] [--] []"],"description":"Displays help for a command","help":"The help<\/info> command displays help for a given command:\n\n php app\/console help list<\/info>\n\nYou can also output the help in other formats by using the --format<\/comment> option:\n\n php app\/console help --format=xml list<\/info>\n\nTo display the list of available commands, please use the list<\/info> command.","definition":{"arguments":{"command_name":{"name":"command_name","is_required":false,"is_array":false,"description":"The command name","default":"help"}},"options":{"xml":{"name":"--xml","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output help as XML","default":false},"format":{"name":"--format","shortcut":"","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"The output format (txt, xml, json, or md)","default":"txt"},"raw":{"name":"--raw","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output raw command help","default":false},"help":{"name":"--help","shortcut":"-h","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this help message","default":false},"quiet":{"name":"--quiet","shortcut":"-q","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not output any message","default":false},"verbose":{"name":"--verbose","shortcut":"-v|-vv|-vvv","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug","default":false},"version":{"name":"--version","shortcut":"-V","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this application version","default":false},"ansi":{"name":"--ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Force ANSI output","default":false},"no-ansi":{"name":"--no-ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Disable ANSI output","default":false},"no-interaction":{"name":"--no-interaction","shortcut":"-n","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not ask any interactive question","default":false}}}},{"name":"list","usage":["list [--xml] [--raw] [--format FORMAT] [--] []"],"description":"Lists commands","help":"The list<\/info> command lists all commands:\n\n php app\/console list<\/info>\n\nYou can also display the commands for a specific namespace:\n\n php app\/console list test<\/info>\n\nYou can also output the information in other formats by using the --format<\/comment> option:\n\n php app\/console list --format=xml<\/info>\n\nIt's also possible to get raw list of commands (useful for embedding command runner):\n\n php app\/console list --raw<\/info>","definition":{"arguments":{"namespace":{"name":"namespace","is_required":false,"is_array":false,"description":"The namespace name","default":null}},"options":{"xml":{"name":"--xml","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output list as XML","default":false},"raw":{"name":"--raw","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output raw command list","default":false},"format":{"name":"--format","shortcut":"","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"The output format (txt, xml, json, or md)","default":"txt"}}}}],"namespaces":[{"id":"_global","commands":["help","list"]}]} diff --git a/vendor/symfony/console/Tests/Fixtures/application_1.md b/vendor/symfony/console/Tests/Fixtures/application_1.md deleted file mode 100644 index 82a605da6..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_1.md +++ /dev/null @@ -1,201 +0,0 @@ -UNKNOWN -======= - -* help -* list - -help ----- - -* Description: Displays help for a command -* Usage: - - * `help [--xml] [--format FORMAT] [--raw] [--] []` - -The help command displays help for a given command: - - php app/console help list - -You can also output the help in other formats by using the --format option: - - php app/console help --format=xml list - -To display the list of available commands, please use the list command. - -### Arguments: - -**command_name:** - -* Name: command_name -* Is required: no -* Is array: no -* Description: The command name -* Default: `'help'` - -### Options: - -**xml:** - -* Name: `--xml` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output help as XML -* Default: `false` - -**format:** - -* Name: `--format` -* Shortcut: -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: The output format (txt, xml, json, or md) -* Default: `'txt'` - -**raw:** - -* Name: `--raw` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output raw command help -* Default: `false` - -**help:** - -* Name: `--help` -* Shortcut: `-h` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this help message -* Default: `false` - -**quiet:** - -* Name: `--quiet` -* Shortcut: `-q` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not output any message -* Default: `false` - -**verbose:** - -* Name: `--verbose` -* Shortcut: `-v|-vv|-vvv` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug -* Default: `false` - -**version:** - -* Name: `--version` -* Shortcut: `-V` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this application version -* Default: `false` - -**ansi:** - -* Name: `--ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Force ANSI output -* Default: `false` - -**no-ansi:** - -* Name: `--no-ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Disable ANSI output -* Default: `false` - -**no-interaction:** - -* Name: `--no-interaction` -* Shortcut: `-n` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not ask any interactive question -* Default: `false` - -list ----- - -* Description: Lists commands -* Usage: - - * `list [--xml] [--raw] [--format FORMAT] [--] []` - -The list command lists all commands: - - php app/console list - -You can also display the commands for a specific namespace: - - php app/console list test - -You can also output the information in other formats by using the --format option: - - php app/console list --format=xml - -It's also possible to get raw list of commands (useful for embedding command runner): - - php app/console list --raw - -### Arguments: - -**namespace:** - -* Name: namespace -* Is required: no -* Is array: no -* Description: The namespace name -* Default: `NULL` - -### Options: - -**xml:** - -* Name: `--xml` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output list as XML -* Default: `false` - -**raw:** - -* Name: `--raw` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output raw command list -* Default: `false` - -**format:** - -* Name: `--format` -* Shortcut: -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: The output format (txt, xml, json, or md) -* Default: `'txt'` diff --git a/vendor/symfony/console/Tests/Fixtures/application_1.txt b/vendor/symfony/console/Tests/Fixtures/application_1.txt deleted file mode 100644 index c4cf8f216..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_1.txt +++ /dev/null @@ -1,17 +0,0 @@ -Console Tool - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Available commands: - help Displays help for a command - list Lists commands diff --git a/vendor/symfony/console/Tests/Fixtures/application_1.xml b/vendor/symfony/console/Tests/Fixtures/application_1.xml deleted file mode 100644 index 35d1db4dc..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_1.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - - - - help [--xml] [--format FORMAT] [--raw] [--] [<command_name>] - - Displays help for a command - The <info>help</info> command displays help for a given command: - - <info>php app/console help list</info> - - You can also output the help in other formats by using the <comment>--format</comment> option: - - <info>php app/console help --format=xml list</info> - - To display the list of available commands, please use the <info>list</info> command. - - - The command name - - help - - - - - - - - - - - - - - - - - - - list [--xml] [--raw] [--format FORMAT] [--] [<namespace>] - - Lists commands - The <info>list</info> command lists all commands: - - <info>php app/console list</info> - - You can also display the commands for a specific namespace: - - <info>php app/console list test</info> - - You can also output the information in other formats by using the <comment>--format</comment> option: - - <info>php app/console list --format=xml</info> - - It's also possible to get raw list of commands (useful for embedding command runner): - - <info>php app/console list --raw</info> - - - The namespace name - - - - - - - - - - - - - help - list - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_2.json b/vendor/symfony/console/Tests/Fixtures/application_2.json deleted file mode 100644 index e47a7a962..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_2.json +++ /dev/null @@ -1 +0,0 @@ -{"commands":[{"name":"help","usage":["help [--xml] [--format FORMAT] [--raw] [--] []"],"description":"Displays help for a command","help":"The help<\/info> command displays help for a given command:\n\n php app\/console help list<\/info>\n\nYou can also output the help in other formats by using the --format<\/comment> option:\n\n php app\/console help --format=xml list<\/info>\n\nTo display the list of available commands, please use the list<\/info> command.","definition":{"arguments":{"command_name":{"name":"command_name","is_required":false,"is_array":false,"description":"The command name","default":"help"}},"options":{"xml":{"name":"--xml","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output help as XML","default":false},"format":{"name":"--format","shortcut":"","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"The output format (txt, xml, json, or md)","default":"txt"},"raw":{"name":"--raw","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output raw command help","default":false},"help":{"name":"--help","shortcut":"-h","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this help message","default":false},"quiet":{"name":"--quiet","shortcut":"-q","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not output any message","default":false},"verbose":{"name":"--verbose","shortcut":"-v|-vv|-vvv","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug","default":false},"version":{"name":"--version","shortcut":"-V","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this application version","default":false},"ansi":{"name":"--ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Force ANSI output","default":false},"no-ansi":{"name":"--no-ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Disable ANSI output","default":false},"no-interaction":{"name":"--no-interaction","shortcut":"-n","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not ask any interactive question","default":false}}}},{"name":"list","usage":["list [--xml] [--raw] [--format FORMAT] [--] []"],"description":"Lists commands","help":"The list<\/info> command lists all commands:\n\n php app\/console list<\/info>\n\nYou can also display the commands for a specific namespace:\n\n php app\/console list test<\/info>\n\nYou can also output the information in other formats by using the --format<\/comment> option:\n\n php app\/console list --format=xml<\/info>\n\nIt's also possible to get raw list of commands (useful for embedding command runner):\n\n php app\/console list --raw<\/info>","definition":{"arguments":{"namespace":{"name":"namespace","is_required":false,"is_array":false,"description":"The namespace name","default":null}},"options":{"xml":{"name":"--xml","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output list as XML","default":false},"raw":{"name":"--raw","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"To output raw command list","default":false},"format":{"name":"--format","shortcut":"","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"The output format (txt, xml, json, or md)","default":"txt"}}}},{"name":"descriptor:command1","usage":["descriptor:command1", "alias1", "alias2"],"description":"command 1 description","help":"command 1 help","definition":{"arguments":[],"options":{"help":{"name":"--help","shortcut":"-h","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this help message","default":false},"quiet":{"name":"--quiet","shortcut":"-q","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not output any message","default":false},"verbose":{"name":"--verbose","shortcut":"-v|-vv|-vvv","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug","default":false},"version":{"name":"--version","shortcut":"-V","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this application version","default":false},"ansi":{"name":"--ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Force ANSI output","default":false},"no-ansi":{"name":"--no-ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Disable ANSI output","default":false},"no-interaction":{"name":"--no-interaction","shortcut":"-n","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not ask any interactive question","default":false}}}},{"name":"descriptor:command2","usage":["descriptor:command2 [-o|--option_name] [--] ", "descriptor:command2 -o|--option_name ", "descriptor:command2 "],"description":"command 2 description","help":"command 2 help","definition":{"arguments":{"argument_name":{"name":"argument_name","is_required":true,"is_array":false,"description":"","default":null}},"options":{"option_name":{"name":"--option_name","shortcut":"-o","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"","default":false},"help":{"name":"--help","shortcut":"-h","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this help message","default":false},"quiet":{"name":"--quiet","shortcut":"-q","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not output any message","default":false},"verbose":{"name":"--verbose","shortcut":"-v|-vv|-vvv","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug","default":false},"version":{"name":"--version","shortcut":"-V","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Display this application version","default":false},"ansi":{"name":"--ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Force ANSI output","default":false},"no-ansi":{"name":"--no-ansi","shortcut":"","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Disable ANSI output","default":false},"no-interaction":{"name":"--no-interaction","shortcut":"-n","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"Do not ask any interactive question","default":false}}}}],"namespaces":[{"id":"_global","commands":["alias1","alias2","help","list"]},{"id":"descriptor","commands":["descriptor:command1","descriptor:command2"]}]} \ No newline at end of file diff --git a/vendor/symfony/console/Tests/Fixtures/application_2.md b/vendor/symfony/console/Tests/Fixtures/application_2.md deleted file mode 100644 index f031c9e5c..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_2.md +++ /dev/null @@ -1,396 +0,0 @@ -My Symfony application -====================== - -* alias1 -* alias2 -* help -* list - -**descriptor:** - -* descriptor:command1 -* descriptor:command2 - -help ----- - -* Description: Displays help for a command -* Usage: - - * `help [--xml] [--format FORMAT] [--raw] [--] []` - -The help command displays help for a given command: - - php app/console help list - -You can also output the help in other formats by using the --format option: - - php app/console help --format=xml list - -To display the list of available commands, please use the list command. - -### Arguments: - -**command_name:** - -* Name: command_name -* Is required: no -* Is array: no -* Description: The command name -* Default: `'help'` - -### Options: - -**xml:** - -* Name: `--xml` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output help as XML -* Default: `false` - -**format:** - -* Name: `--format` -* Shortcut: -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: The output format (txt, xml, json, or md) -* Default: `'txt'` - -**raw:** - -* Name: `--raw` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output raw command help -* Default: `false` - -**help:** - -* Name: `--help` -* Shortcut: `-h` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this help message -* Default: `false` - -**quiet:** - -* Name: `--quiet` -* Shortcut: `-q` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not output any message -* Default: `false` - -**verbose:** - -* Name: `--verbose` -* Shortcut: `-v|-vv|-vvv` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug -* Default: `false` - -**version:** - -* Name: `--version` -* Shortcut: `-V` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this application version -* Default: `false` - -**ansi:** - -* Name: `--ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Force ANSI output -* Default: `false` - -**no-ansi:** - -* Name: `--no-ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Disable ANSI output -* Default: `false` - -**no-interaction:** - -* Name: `--no-interaction` -* Shortcut: `-n` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not ask any interactive question -* Default: `false` - -list ----- - -* Description: Lists commands -* Usage: - - * `list [--xml] [--raw] [--format FORMAT] [--] []` - -The list command lists all commands: - - php app/console list - -You can also display the commands for a specific namespace: - - php app/console list test - -You can also output the information in other formats by using the --format option: - - php app/console list --format=xml - -It's also possible to get raw list of commands (useful for embedding command runner): - - php app/console list --raw - -### Arguments: - -**namespace:** - -* Name: namespace -* Is required: no -* Is array: no -* Description: The namespace name -* Default: `NULL` - -### Options: - -**xml:** - -* Name: `--xml` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output list as XML -* Default: `false` - -**raw:** - -* Name: `--raw` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: To output raw command list -* Default: `false` - -**format:** - -* Name: `--format` -* Shortcut: -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: The output format (txt, xml, json, or md) -* Default: `'txt'` - -descriptor:command1 -------------------- - -* Description: command 1 description -* Usage: - - * `descriptor:command1` - * `alias1` - * `alias2` - -command 1 help - -### Options: - -**help:** - -* Name: `--help` -* Shortcut: `-h` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this help message -* Default: `false` - -**quiet:** - -* Name: `--quiet` -* Shortcut: `-q` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not output any message -* Default: `false` - -**verbose:** - -* Name: `--verbose` -* Shortcut: `-v|-vv|-vvv` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug -* Default: `false` - -**version:** - -* Name: `--version` -* Shortcut: `-V` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this application version -* Default: `false` - -**ansi:** - -* Name: `--ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Force ANSI output -* Default: `false` - -**no-ansi:** - -* Name: `--no-ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Disable ANSI output -* Default: `false` - -**no-interaction:** - -* Name: `--no-interaction` -* Shortcut: `-n` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not ask any interactive question -* Default: `false` - -descriptor:command2 -------------------- - -* Description: command 2 description -* Usage: - - * `descriptor:command2 [-o|--option_name] [--] ` - * `descriptor:command2 -o|--option_name ` - * `descriptor:command2 ` - -command 2 help - -### Arguments: - -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: -* Default: `NULL` - -### Options: - -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: -* Default: `false` - -**help:** - -* Name: `--help` -* Shortcut: `-h` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this help message -* Default: `false` - -**quiet:** - -* Name: `--quiet` -* Shortcut: `-q` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not output any message -* Default: `false` - -**verbose:** - -* Name: `--verbose` -* Shortcut: `-v|-vv|-vvv` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug -* Default: `false` - -**version:** - -* Name: `--version` -* Shortcut: `-V` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Display this application version -* Default: `false` - -**ansi:** - -* Name: `--ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Force ANSI output -* Default: `false` - -**no-ansi:** - -* Name: `--no-ansi` -* Shortcut: -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Disable ANSI output -* Default: `false` - -**no-interaction:** - -* Name: `--no-interaction` -* Shortcut: `-n` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: Do not ask any interactive question -* Default: `false` diff --git a/vendor/symfony/console/Tests/Fixtures/application_2.txt b/vendor/symfony/console/Tests/Fixtures/application_2.txt deleted file mode 100644 index 292aa829d..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_2.txt +++ /dev/null @@ -1,22 +0,0 @@ -My Symfony application version v1.0 - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Available commands: - alias1 command 1 description - alias2 command 1 description - help Displays help for a command - list Lists commands - descriptor - descriptor:command1 command 1 description - descriptor:command2 command 2 description diff --git a/vendor/symfony/console/Tests/Fixtures/application_2.xml b/vendor/symfony/console/Tests/Fixtures/application_2.xml deleted file mode 100644 index bc8ab219d..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_2.xml +++ /dev/null @@ -1,190 +0,0 @@ - - - - - - help [--xml] [--format FORMAT] [--raw] [--] [<command_name>] - - Displays help for a command - The <info>help</info> command displays help for a given command: - - <info>php app/console help list</info> - - You can also output the help in other formats by using the <comment>--format</comment> option: - - <info>php app/console help --format=xml list</info> - - To display the list of available commands, please use the <info>list</info> command. - - - The command name - - help - - - - - - - - - - - - - - - - - - - list [--xml] [--raw] [--format FORMAT] [--] [<namespace>] - - Lists commands - The <info>list</info> command lists all commands: - - <info>php app/console list</info> - - You can also display the commands for a specific namespace: - - <info>php app/console list test</info> - - You can also output the information in other formats by using the <comment>--format</comment> option: - - <info>php app/console list --format=xml</info> - - It's also possible to get raw list of commands (useful for embedding command runner): - - <info>php app/console list --raw</info> - - - The namespace name - - - - - - - - - - - - descriptor:command1 - alias1 - alias2 - - command 1 description - command 1 help - - - - - - - - - - - - - - descriptor:command2 [-o|--option_name] [--] <argument_name> - descriptor:command2 -o|--option_name <argument_name> - descriptor:command2 <argument_name> - - command 2 description - command 2 help - - - - - - - - - - - - - - - - - - - - - alias1 - alias2 - help - list - - - descriptor:command1 - descriptor:command2 - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_astext1.txt b/vendor/symfony/console/Tests/Fixtures/application_astext1.txt deleted file mode 100644 index 19dacb23b..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_astext1.txt +++ /dev/null @@ -1,20 +0,0 @@ -Console Tool - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Available commands: - afoobar The foo:bar command - help Displays help for a command - list Lists commands - foo - foo:bar The foo:bar command diff --git a/vendor/symfony/console/Tests/Fixtures/application_astext2.txt b/vendor/symfony/console/Tests/Fixtures/application_astext2.txt deleted file mode 100644 index c99ccdda7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_astext2.txt +++ /dev/null @@ -1,16 +0,0 @@ -Console Tool - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Available commands for the "foo" namespace: - foo:bar The foo:bar command diff --git a/vendor/symfony/console/Tests/Fixtures/application_asxml1.txt b/vendor/symfony/console/Tests/Fixtures/application_asxml1.txt deleted file mode 100644 index 8277d9e66..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_asxml1.txt +++ /dev/null @@ -1,146 +0,0 @@ - - - - - - help [--xml] [--format FORMAT] [--raw] [--] [<command_name>] - - Displays help for a command - The <info>help</info> command displays help for a given command: - - <info>php app/console help list</info> - - You can also output the help in other formats by using the <comment>--format</comment> option: - - <info>php app/console help --format=xml list</info> - - To display the list of available commands, please use the <info>list</info> command. - - - The command name - - help - - - - - - - - - - - - - - - - - - - list [--xml] [--raw] [--format FORMAT] [--] [<namespace>] - - Lists commands - The <info>list</info> command lists all commands: - - <info>php app/console list</info> - - You can also display the commands for a specific namespace: - - <info>php app/console list test</info> - - You can also output the information in other formats by using the <comment>--format</comment> option: - - <info>php app/console list --format=xml</info> - - It's also possible to get raw list of commands (useful for embedding command runner): - - <info>php app/console list --raw</info> - - - The namespace name - - - - - - - - - - - - foo:bar - afoobar - - The foo:bar command - The foo:bar command - - - - - - - - - - - - - - - afoobar - help - list - - - foo:bar - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_asxml2.txt b/vendor/symfony/console/Tests/Fixtures/application_asxml2.txt deleted file mode 100644 index 93d6d4e99..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_asxml2.txt +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - foo:bar - afoobar - - The foo:bar command - The foo:bar command - - - - - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_gethelp.txt b/vendor/symfony/console/Tests/Fixtures/application_gethelp.txt deleted file mode 100644 index 0c16e3c84..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_gethelp.txt +++ /dev/null @@ -1 +0,0 @@ -Console Tool \ No newline at end of file diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception1.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception1.txt deleted file mode 100644 index 4629345c1..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception1.txt +++ /dev/null @@ -1,8 +0,0 @@ - - - - [InvalidArgumentException] - Command "foo" is not defined. - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception2.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception2.txt deleted file mode 100644 index 3d9d363b6..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception2.txt +++ /dev/null @@ -1,11 +0,0 @@ - - - - [InvalidArgumentException] - The "--foo" option does not exist. - - - -list [--xml] [--raw] [--format FORMAT] [--] [] - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception3.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception3.txt deleted file mode 100644 index 72a72867f..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception3.txt +++ /dev/null @@ -1,27 +0,0 @@ - - - - [Exception] - Third exception comment - - - - - - - [Exception] - Second exception comment - - - - - - - [Exception] - First exception

    this is html

    - - - -foo3:bar - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception3decorated.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception3decorated.txt deleted file mode 100644 index b44d50b0e..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception3decorated.txt +++ /dev/null @@ -1,27 +0,0 @@ - - -  - [Exception]  - Third exception comment  -  - - - - -  - [Exception]  - Second exception comment  -  - - - - -  - [Exception]  - First exception 

    this is html

      -  - - -foo3:bar - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception4.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception4.txt deleted file mode 100644 index 19f893b0c..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception4.txt +++ /dev/null @@ -1,9 +0,0 @@ - - - - [InvalidArgumentException] - Command "foo" is not define - d. - - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1.txt deleted file mode 100644 index 6a9866036..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1.txt +++ /dev/null @@ -1,11 +0,0 @@ - - - - [Exception] - エラーメッセージ - - - -foo - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1decorated.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1decorated.txt deleted file mode 100644 index 8c8801b13..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth1decorated.txt +++ /dev/null @@ -1,11 +0,0 @@ - - -  - [Exception]  - エラーメッセージ  -  - - -foo - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth2.txt b/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth2.txt deleted file mode 100644 index 545cd7b0b..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_renderexception_doublewidth2.txt +++ /dev/null @@ -1,12 +0,0 @@ - - - - [Exception] - コマンドの実行中にエラーが - 発生しました。 - - - -foo - - diff --git a/vendor/symfony/console/Tests/Fixtures/application_run1.txt b/vendor/symfony/console/Tests/Fixtures/application_run1.txt deleted file mode 100644 index 0dc273098..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_run1.txt +++ /dev/null @@ -1,17 +0,0 @@ -Console Tool - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Available commands: - help Displays help for a command - list Lists commands diff --git a/vendor/symfony/console/Tests/Fixtures/application_run2.txt b/vendor/symfony/console/Tests/Fixtures/application_run2.txt deleted file mode 100644 index d28b928ec..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_run2.txt +++ /dev/null @@ -1,29 +0,0 @@ -Usage: - help [options] [--] [] - -Arguments: - command The command to execute - command_name The command name [default: "help"] - -Options: - --xml To output help as XML - --format=FORMAT The output format (txt, xml, json, or md) [default: "txt"] - --raw To output raw command help - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Help: - The help command displays help for a given command: - - php app/console help list - - You can also output the help in other formats by using the --format option: - - php app/console help --format=xml list - - To display the list of available commands, please use the list command. diff --git a/vendor/symfony/console/Tests/Fixtures/application_run3.txt b/vendor/symfony/console/Tests/Fixtures/application_run3.txt deleted file mode 100644 index bc51995f8..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_run3.txt +++ /dev/null @@ -1,27 +0,0 @@ -Usage: - list [options] [--] [] - -Arguments: - namespace The namespace name - -Options: - --xml To output list as XML - --raw To output raw command list - --format=FORMAT The output format (txt, xml, json, or md) [default: "txt"] - -Help: - The list command lists all commands: - - php app/console list - - You can also display the commands for a specific namespace: - - php app/console list test - - You can also output the information in other formats by using the --format option: - - php app/console list --format=xml - - It's also possible to get raw list of commands (useful for embedding command runner): - - php app/console list --raw diff --git a/vendor/symfony/console/Tests/Fixtures/application_run4.txt b/vendor/symfony/console/Tests/Fixtures/application_run4.txt deleted file mode 100644 index 47187fc26..000000000 --- a/vendor/symfony/console/Tests/Fixtures/application_run4.txt +++ /dev/null @@ -1 +0,0 @@ -Console Tool diff --git a/vendor/symfony/console/Tests/Fixtures/command_1.json b/vendor/symfony/console/Tests/Fixtures/command_1.json deleted file mode 100644 index 20f310b45..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_1.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"descriptor:command1","usage":["descriptor:command1", "alias1", "alias2"],"description":"command 1 description","help":"command 1 help","definition":{"arguments":[],"options":[]}} diff --git a/vendor/symfony/console/Tests/Fixtures/command_1.md b/vendor/symfony/console/Tests/Fixtures/command_1.md deleted file mode 100644 index 34ed3ea77..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_1.md +++ /dev/null @@ -1,11 +0,0 @@ -descriptor:command1 -------------------- - -* Description: command 1 description -* Usage: - - * `descriptor:command1` - * `alias1` - * `alias2` - -command 1 help diff --git a/vendor/symfony/console/Tests/Fixtures/command_1.txt b/vendor/symfony/console/Tests/Fixtures/command_1.txt deleted file mode 100644 index 28e14a057..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_1.txt +++ /dev/null @@ -1,7 +0,0 @@ -Usage: - descriptor:command1 - alias1 - alias2 - -Help: - command 1 help diff --git a/vendor/symfony/console/Tests/Fixtures/command_1.xml b/vendor/symfony/console/Tests/Fixtures/command_1.xml deleted file mode 100644 index 838b9bd91..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_1.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - descriptor:command1 - alias1 - alias2 - - command 1 description - command 1 help - - - diff --git a/vendor/symfony/console/Tests/Fixtures/command_2.json b/vendor/symfony/console/Tests/Fixtures/command_2.json deleted file mode 100644 index 38edd1e20..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_2.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"descriptor:command2","usage":["descriptor:command2 [-o|--option_name] [--] ", "descriptor:command2 -o|--option_name ", "descriptor:command2 "],"description":"command 2 description","help":"command 2 help","definition":{"arguments":{"argument_name":{"name":"argument_name","is_required":true,"is_array":false,"description":"","default":null}},"options":{"option_name":{"name":"--option_name","shortcut":"-o","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"","default":false}}}} diff --git a/vendor/symfony/console/Tests/Fixtures/command_2.md b/vendor/symfony/console/Tests/Fixtures/command_2.md deleted file mode 100644 index 6f538b640..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_2.md +++ /dev/null @@ -1,33 +0,0 @@ -descriptor:command2 -------------------- - -* Description: command 2 description -* Usage: - - * `descriptor:command2 [-o|--option_name] [--] ` - * `descriptor:command2 -o|--option_name ` - * `descriptor:command2 ` - -command 2 help - -### Arguments: - -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: -* Default: `NULL` - -### Options: - -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: -* Default: `false` diff --git a/vendor/symfony/console/Tests/Fixtures/command_2.txt b/vendor/symfony/console/Tests/Fixtures/command_2.txt deleted file mode 100644 index 72f7ce058..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_2.txt +++ /dev/null @@ -1,13 +0,0 @@ -Usage: - descriptor:command2 [options] [--] - descriptor:command2 -o|--option_name - descriptor:command2 - -Arguments: - argument_name - -Options: - -o, --option_name - -Help: - command 2 help diff --git a/vendor/symfony/console/Tests/Fixtures/command_2.xml b/vendor/symfony/console/Tests/Fixtures/command_2.xml deleted file mode 100644 index 67364caa4..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_2.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - descriptor:command2 [-o|--option_name] [--] <argument_name> - descriptor:command2 -o|--option_name <argument_name> - descriptor:command2 <argument_name> - - command 2 description - command 2 help - - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/command_astext.txt b/vendor/symfony/console/Tests/Fixtures/command_astext.txt deleted file mode 100644 index 7e2063880..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_astext.txt +++ /dev/null @@ -1,18 +0,0 @@ -Usage: - namespace:name - name - -Arguments: - command The command to execute - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug - -Help: - help diff --git a/vendor/symfony/console/Tests/Fixtures/command_asxml.txt b/vendor/symfony/console/Tests/Fixtures/command_asxml.txt deleted file mode 100644 index 5e776238a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/command_asxml.txt +++ /dev/null @@ -1,38 +0,0 @@ - - - - namespace:name - name - - description - help - - - The command to execute - - - - - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/definition_astext.txt b/vendor/symfony/console/Tests/Fixtures/definition_astext.txt deleted file mode 100644 index 0431c072a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/definition_astext.txt +++ /dev/null @@ -1,11 +0,0 @@ -Arguments: - foo The foo argument - baz The baz argument [default: true] - bar The bar argument [default: ["http://foo.com/"]] - -Options: - -f, --foo=FOO The foo option - --baz[=BAZ] The baz option [default: false] - -b, --bar[=BAR] The bar option [default: "bar"] - --qux[=QUX] The qux option [default: ["http://foo.com/","bar"]] (multiple values allowed) - --qux2[=QUX2] The qux2 option [default: {"foo":"bar"}] (multiple values allowed) \ No newline at end of file diff --git a/vendor/symfony/console/Tests/Fixtures/definition_asxml.txt b/vendor/symfony/console/Tests/Fixtures/definition_asxml.txt deleted file mode 100644 index eec8c079e..000000000 --- a/vendor/symfony/console/Tests/Fixtures/definition_asxml.txt +++ /dev/null @@ -1,39 +0,0 @@ - - - - - The foo argument - - - - The baz argument - - true - - - - The bar argument - - bar - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_1.json b/vendor/symfony/console/Tests/Fixtures/input_argument_1.json deleted file mode 100644 index b8173b6b3..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_1.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"argument_name","is_required":true,"is_array":false,"description":"","default":null} diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_1.md b/vendor/symfony/console/Tests/Fixtures/input_argument_1.md deleted file mode 100644 index 88f311ab5..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_1.md +++ /dev/null @@ -1,7 +0,0 @@ -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_1.txt b/vendor/symfony/console/Tests/Fixtures/input_argument_1.txt deleted file mode 100644 index 55035183f..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_1.txt +++ /dev/null @@ -1 +0,0 @@ - argument_name diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_1.xml b/vendor/symfony/console/Tests/Fixtures/input_argument_1.xml deleted file mode 100644 index cb37f812c..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_1.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_2.json b/vendor/symfony/console/Tests/Fixtures/input_argument_2.json deleted file mode 100644 index ef06b09a7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_2.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"argument_name","is_required":false,"is_array":true,"description":"argument description","default":[]} diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_2.md b/vendor/symfony/console/Tests/Fixtures/input_argument_2.md deleted file mode 100644 index 3cdb00cc8..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_2.md +++ /dev/null @@ -1,7 +0,0 @@ -**argument_name:** - -* Name: argument_name -* Is required: no -* Is array: yes -* Description: argument description -* Default: `array ()` diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_2.txt b/vendor/symfony/console/Tests/Fixtures/input_argument_2.txt deleted file mode 100644 index e71366074..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_2.txt +++ /dev/null @@ -1 +0,0 @@ - argument_name argument description diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_2.xml b/vendor/symfony/console/Tests/Fixtures/input_argument_2.xml deleted file mode 100644 index 629da5a98..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_2.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - argument description - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_3.json b/vendor/symfony/console/Tests/Fixtures/input_argument_3.json deleted file mode 100644 index de8484e6a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_3.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"argument_name","is_required":false,"is_array":false,"description":"argument description","default":"default_value"} diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_3.md b/vendor/symfony/console/Tests/Fixtures/input_argument_3.md deleted file mode 100644 index be1c443ae..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_3.md +++ /dev/null @@ -1,7 +0,0 @@ -**argument_name:** - -* Name: argument_name -* Is required: no -* Is array: no -* Description: argument description -* Default: `'default_value'` diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_3.txt b/vendor/symfony/console/Tests/Fixtures/input_argument_3.txt deleted file mode 100644 index 6b76639e0..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_3.txt +++ /dev/null @@ -1 +0,0 @@ - argument_name argument description [default: "default_value"] diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_3.xml b/vendor/symfony/console/Tests/Fixtures/input_argument_3.xml deleted file mode 100644 index 399a5c864..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_3.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - argument description - - default_value - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_4.json b/vendor/symfony/console/Tests/Fixtures/input_argument_4.json deleted file mode 100644 index 8067a4d1b..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_4.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"argument_name","is_required":true,"is_array":false,"description":"multiline argument description","default":null} diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_4.md b/vendor/symfony/console/Tests/Fixtures/input_argument_4.md deleted file mode 100644 index f026ab376..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_4.md +++ /dev/null @@ -1,8 +0,0 @@ -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: multiline - argument description -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_4.txt b/vendor/symfony/console/Tests/Fixtures/input_argument_4.txt deleted file mode 100644 index aa74e8ceb..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_4.txt +++ /dev/null @@ -1,2 +0,0 @@ - argument_name multiline - argument description diff --git a/vendor/symfony/console/Tests/Fixtures/input_argument_4.xml b/vendor/symfony/console/Tests/Fixtures/input_argument_4.xml deleted file mode 100644 index 5ca135ec2..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_argument_4.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - multiline -argument description - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_1.json b/vendor/symfony/console/Tests/Fixtures/input_definition_1.json deleted file mode 100644 index c7a7d838f..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_1.json +++ /dev/null @@ -1 +0,0 @@ -{"arguments":[],"options":[]} diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_1.md b/vendor/symfony/console/Tests/Fixtures/input_definition_1.md deleted file mode 100644 index e69de29bb..000000000 diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_1.txt b/vendor/symfony/console/Tests/Fixtures/input_definition_1.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_1.xml b/vendor/symfony/console/Tests/Fixtures/input_definition_1.xml deleted file mode 100644 index b5481ce12..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_1.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_2.json b/vendor/symfony/console/Tests/Fixtures/input_definition_2.json deleted file mode 100644 index 9964a55ae..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_2.json +++ /dev/null @@ -1 +0,0 @@ -{"arguments":{"argument_name":{"name":"argument_name","is_required":true,"is_array":false,"description":"","default":null}},"options":[]} diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_2.md b/vendor/symfony/console/Tests/Fixtures/input_definition_2.md deleted file mode 100644 index 923191cdc..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_2.md +++ /dev/null @@ -1,9 +0,0 @@ -### Arguments: - -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_2.txt b/vendor/symfony/console/Tests/Fixtures/input_definition_2.txt deleted file mode 100644 index 73b0f308a..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_2.txt +++ /dev/null @@ -1,2 +0,0 @@ -Arguments: - argument_name diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_2.xml b/vendor/symfony/console/Tests/Fixtures/input_definition_2.xml deleted file mode 100644 index 102efc148..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_2.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_3.json b/vendor/symfony/console/Tests/Fixtures/input_definition_3.json deleted file mode 100644 index 6a8605602..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_3.json +++ /dev/null @@ -1 +0,0 @@ -{"arguments":[],"options":{"option_name":{"name":"--option_name","shortcut":"-o","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"","default":false}}} diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_3.md b/vendor/symfony/console/Tests/Fixtures/input_definition_3.md deleted file mode 100644 index 40fd7b0a9..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_3.md +++ /dev/null @@ -1,11 +0,0 @@ -### Options: - -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: -* Default: `false` diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_3.txt b/vendor/symfony/console/Tests/Fixtures/input_definition_3.txt deleted file mode 100644 index c02766fd3..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_3.txt +++ /dev/null @@ -1,2 +0,0 @@ -Options: - -o, --option_name diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_3.xml b/vendor/symfony/console/Tests/Fixtures/input_definition_3.xml deleted file mode 100644 index bc9515154..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_3.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_4.json b/vendor/symfony/console/Tests/Fixtures/input_definition_4.json deleted file mode 100644 index c5a0019fe..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_4.json +++ /dev/null @@ -1 +0,0 @@ -{"arguments":{"argument_name":{"name":"argument_name","is_required":true,"is_array":false,"description":"","default":null}},"options":{"option_name":{"name":"--option_name","shortcut":"-o","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"","default":false}}} diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_4.md b/vendor/symfony/console/Tests/Fixtures/input_definition_4.md deleted file mode 100644 index a31feea47..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_4.md +++ /dev/null @@ -1,21 +0,0 @@ -### Arguments: - -**argument_name:** - -* Name: argument_name -* Is required: yes -* Is array: no -* Description: -* Default: `NULL` - -### Options: - -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: -* Default: `false` diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_4.txt b/vendor/symfony/console/Tests/Fixtures/input_definition_4.txt deleted file mode 100644 index 63aa81d2d..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_4.txt +++ /dev/null @@ -1,5 +0,0 @@ -Arguments: - argument_name - -Options: - -o, --option_name diff --git a/vendor/symfony/console/Tests/Fixtures/input_definition_4.xml b/vendor/symfony/console/Tests/Fixtures/input_definition_4.xml deleted file mode 100644 index cffceecef..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_definition_4.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_1.json b/vendor/symfony/console/Tests/Fixtures/input_option_1.json deleted file mode 100644 index 60c5b56cb..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_1.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o","accept_value":false,"is_value_required":false,"is_multiple":false,"description":"","default":false} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_1.md b/vendor/symfony/console/Tests/Fixtures/input_option_1.md deleted file mode 100644 index 6f9e9a7e0..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_1.md +++ /dev/null @@ -1,9 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: no -* Is value required: no -* Is multiple: no -* Description: -* Default: `false` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_1.txt b/vendor/symfony/console/Tests/Fixtures/input_option_1.txt deleted file mode 100644 index 3a5e4eede..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_1.txt +++ /dev/null @@ -1 +0,0 @@ - -o, --option_name diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_1.xml b/vendor/symfony/console/Tests/Fixtures/input_option_1.xml deleted file mode 100644 index 8a64ea652..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_1.xml +++ /dev/null @@ -1,4 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_2.json b/vendor/symfony/console/Tests/Fixtures/input_option_2.json deleted file mode 100644 index 04e4228ec..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_2.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o","accept_value":true,"is_value_required":false,"is_multiple":false,"description":"option description","default":"default_value"} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_2.md b/vendor/symfony/console/Tests/Fixtures/input_option_2.md deleted file mode 100644 index 634ac0b03..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_2.md +++ /dev/null @@ -1,9 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: yes -* Is value required: no -* Is multiple: no -* Description: option description -* Default: `'default_value'` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_2.txt b/vendor/symfony/console/Tests/Fixtures/input_option_2.txt deleted file mode 100644 index 1009eff16..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_2.txt +++ /dev/null @@ -1 +0,0 @@ - -o, --option_name[=OPTION_NAME] option description [default: "default_value"] diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_2.xml b/vendor/symfony/console/Tests/Fixtures/input_option_2.xml deleted file mode 100644 index 4afac5b04..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_2.xml +++ /dev/null @@ -1,7 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_3.json b/vendor/symfony/console/Tests/Fixtures/input_option_3.json deleted file mode 100644 index c1ea120c7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_3.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"option description","default":null} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_3.md b/vendor/symfony/console/Tests/Fixtures/input_option_3.md deleted file mode 100644 index 34282896b..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_3.md +++ /dev/null @@ -1,9 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: option description -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_3.txt b/vendor/symfony/console/Tests/Fixtures/input_option_3.txt deleted file mode 100644 index 947bb6527..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_3.txt +++ /dev/null @@ -1 +0,0 @@ - -o, --option_name=OPTION_NAME option description diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_3.xml b/vendor/symfony/console/Tests/Fixtures/input_option_3.xml deleted file mode 100644 index dcc0631cf..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_3.xml +++ /dev/null @@ -1,5 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_4.json b/vendor/symfony/console/Tests/Fixtures/input_option_4.json deleted file mode 100644 index 1b671d806..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_4.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o","accept_value":true,"is_value_required":false,"is_multiple":true,"description":"option description","default":[]} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_4.md b/vendor/symfony/console/Tests/Fixtures/input_option_4.md deleted file mode 100644 index 8ffba56e7..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_4.md +++ /dev/null @@ -1,9 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: yes -* Is value required: no -* Is multiple: yes -* Description: option description -* Default: `array ()` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_4.txt b/vendor/symfony/console/Tests/Fixtures/input_option_4.txt deleted file mode 100644 index 27edf77b4..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_4.txt +++ /dev/null @@ -1 +0,0 @@ - -o, --option_name[=OPTION_NAME] option description (multiple values allowed) diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_4.xml b/vendor/symfony/console/Tests/Fixtures/input_option_4.xml deleted file mode 100644 index 5e2418b14..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_4.xml +++ /dev/null @@ -1,5 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_5.json b/vendor/symfony/console/Tests/Fixtures/input_option_5.json deleted file mode 100644 index 35a1405fa..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_5.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"multiline option description","default":null} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_5.md b/vendor/symfony/console/Tests/Fixtures/input_option_5.md deleted file mode 100644 index 82f51cad3..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_5.md +++ /dev/null @@ -1,10 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o` -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: multiline - option description -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_5.txt b/vendor/symfony/console/Tests/Fixtures/input_option_5.txt deleted file mode 100644 index 4368883cc..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_5.txt +++ /dev/null @@ -1,2 +0,0 @@ - -o, --option_name=OPTION_NAME multiline - option description diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_5.xml b/vendor/symfony/console/Tests/Fixtures/input_option_5.xml deleted file mode 100644 index 90040ccd0..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_5.xml +++ /dev/null @@ -1,6 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_6.json b/vendor/symfony/console/Tests/Fixtures/input_option_6.json deleted file mode 100644 index d84e87214..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_6.json +++ /dev/null @@ -1 +0,0 @@ -{"name":"--option_name","shortcut":"-o|-O","accept_value":true,"is_value_required":true,"is_multiple":false,"description":"option with multiple shortcuts","default":null} diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_6.md b/vendor/symfony/console/Tests/Fixtures/input_option_6.md deleted file mode 100644 index ed1ea1c84..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_6.md +++ /dev/null @@ -1,9 +0,0 @@ -**option_name:** - -* Name: `--option_name` -* Shortcut: `-o|-O` -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Description: option with multiple shortcuts -* Default: `NULL` diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_6.txt b/vendor/symfony/console/Tests/Fixtures/input_option_6.txt deleted file mode 100644 index 0e6c9759b..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_6.txt +++ /dev/null @@ -1 +0,0 @@ - -o|O, --option_name=OPTION_NAME option with multiple shortcuts diff --git a/vendor/symfony/console/Tests/Fixtures/input_option_6.xml b/vendor/symfony/console/Tests/Fixtures/input_option_6.xml deleted file mode 100644 index 06126a2f5..000000000 --- a/vendor/symfony/console/Tests/Fixtures/input_option_6.xml +++ /dev/null @@ -1,5 +0,0 @@ - - diff --git a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleStackTest.php b/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleStackTest.php deleted file mode 100644 index 774df268b..000000000 --- a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleStackTest.php +++ /dev/null @@ -1,70 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Formatter; - -use Symfony\Component\Console\Formatter\OutputFormatterStyleStack; -use Symfony\Component\Console\Formatter\OutputFormatterStyle; - -class OutputFormatterStyleStackTest extends \PHPUnit_Framework_TestCase -{ - public function testPush() - { - $stack = new OutputFormatterStyleStack(); - $stack->push($s1 = new OutputFormatterStyle('white', 'black')); - $stack->push($s2 = new OutputFormatterStyle('yellow', 'blue')); - - $this->assertEquals($s2, $stack->getCurrent()); - - $stack->push($s3 = new OutputFormatterStyle('green', 'red')); - - $this->assertEquals($s3, $stack->getCurrent()); - } - - public function testPop() - { - $stack = new OutputFormatterStyleStack(); - $stack->push($s1 = new OutputFormatterStyle('white', 'black')); - $stack->push($s2 = new OutputFormatterStyle('yellow', 'blue')); - - $this->assertEquals($s2, $stack->pop()); - $this->assertEquals($s1, $stack->pop()); - } - - public function testPopEmpty() - { - $stack = new OutputFormatterStyleStack(); - $style = new OutputFormatterStyle(); - - $this->assertEquals($style, $stack->pop()); - } - - public function testPopNotLast() - { - $stack = new OutputFormatterStyleStack(); - $stack->push($s1 = new OutputFormatterStyle('white', 'black')); - $stack->push($s2 = new OutputFormatterStyle('yellow', 'blue')); - $stack->push($s3 = new OutputFormatterStyle('green', 'red')); - - $this->assertEquals($s2, $stack->pop($s2)); - $this->assertEquals($s1, $stack->pop()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testInvalidPop() - { - $stack = new OutputFormatterStyleStack(); - $stack->push(new OutputFormatterStyle('white', 'black')); - $stack->pop(new OutputFormatterStyle('yellow', 'blue')); - } -} diff --git a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php b/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php deleted file mode 100644 index 0abfb3ce2..000000000 --- a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php +++ /dev/null @@ -1,99 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Formatter; - -use Symfony\Component\Console\Formatter\OutputFormatterStyle; - -class OutputFormatterStyleTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $style = new OutputFormatterStyle('green', 'black', array('bold', 'underscore')); - $this->assertEquals("\033[32;40;1;4mfoo\033[39;49;22;24m", $style->apply('foo')); - - $style = new OutputFormatterStyle('red', null, array('blink')); - $this->assertEquals("\033[31;5mfoo\033[39;25m", $style->apply('foo')); - - $style = new OutputFormatterStyle(null, 'white'); - $this->assertEquals("\033[47mfoo\033[49m", $style->apply('foo')); - } - - public function testForeground() - { - $style = new OutputFormatterStyle(); - - $style->setForeground('black'); - $this->assertEquals("\033[30mfoo\033[39m", $style->apply('foo')); - - $style->setForeground('blue'); - $this->assertEquals("\033[34mfoo\033[39m", $style->apply('foo')); - - $style->setForeground('default'); - $this->assertEquals("\033[39mfoo\033[39m", $style->apply('foo')); - - $this->setExpectedException('InvalidArgumentException'); - $style->setForeground('undefined-color'); - } - - public function testBackground() - { - $style = new OutputFormatterStyle(); - - $style->setBackground('black'); - $this->assertEquals("\033[40mfoo\033[49m", $style->apply('foo')); - - $style->setBackground('yellow'); - $this->assertEquals("\033[43mfoo\033[49m", $style->apply('foo')); - - $style->setBackground('default'); - $this->assertEquals("\033[49mfoo\033[49m", $style->apply('foo')); - - $this->setExpectedException('InvalidArgumentException'); - $style->setBackground('undefined-color'); - } - - public function testOptions() - { - $style = new OutputFormatterStyle(); - - $style->setOptions(array('reverse', 'conceal')); - $this->assertEquals("\033[7;8mfoo\033[27;28m", $style->apply('foo')); - - $style->setOption('bold'); - $this->assertEquals("\033[7;8;1mfoo\033[27;28;22m", $style->apply('foo')); - - $style->unsetOption('reverse'); - $this->assertEquals("\033[8;1mfoo\033[28;22m", $style->apply('foo')); - - $style->setOption('bold'); - $this->assertEquals("\033[8;1mfoo\033[28;22m", $style->apply('foo')); - - $style->setOptions(array('bold')); - $this->assertEquals("\033[1mfoo\033[22m", $style->apply('foo')); - - try { - $style->setOption('foo'); - $this->fail('->setOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->setOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - $this->assertContains('Invalid option specified: "foo"', $e->getMessage(), '->setOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - } - - try { - $style->unsetOption('foo'); - $this->fail('->unsetOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->unsetOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - $this->assertContains('Invalid option specified: "foo"', $e->getMessage(), '->unsetOption() throws an \InvalidArgumentException when the option does not exist in the available options'); - } - } -} diff --git a/vendor/symfony/console/Tests/Formatter/OutputFormatterTest.php b/vendor/symfony/console/Tests/Formatter/OutputFormatterTest.php deleted file mode 100644 index 510a4e741..000000000 --- a/vendor/symfony/console/Tests/Formatter/OutputFormatterTest.php +++ /dev/null @@ -1,273 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Formatter; - -use Symfony\Component\Console\Formatter\OutputFormatter; -use Symfony\Component\Console\Formatter\OutputFormatterStyle; - -class OutputFormatterTest extends \PHPUnit_Framework_TestCase -{ - public function testEmptyTag() - { - $formatter = new OutputFormatter(true); - $this->assertEquals('foo<>bar', $formatter->format('foo<>bar')); - } - - public function testLGCharEscaping() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals('fooformat('foo\\assertEquals('some info', $formatter->format('\\some info\\')); - $this->assertEquals('\\some info\\', OutputFormatter::escape('some info')); - - $this->assertEquals( - "\033[33mSymfony\\Component\\Console does work very well!\033[39m", - $formatter->format('Symfony\Component\Console does work very well!') - ); - } - - public function testBundledStyles() - { - $formatter = new OutputFormatter(true); - - $this->assertTrue($formatter->hasStyle('error')); - $this->assertTrue($formatter->hasStyle('info')); - $this->assertTrue($formatter->hasStyle('comment')); - $this->assertTrue($formatter->hasStyle('question')); - - $this->assertEquals( - "\033[37;41msome error\033[39;49m", - $formatter->format('some error') - ); - $this->assertEquals( - "\033[32msome info\033[39m", - $formatter->format('some info') - ); - $this->assertEquals( - "\033[33msome comment\033[39m", - $formatter->format('some comment') - ); - $this->assertEquals( - "\033[30;46msome question\033[39;49m", - $formatter->format('some question') - ); - } - - public function testNestedStyles() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals( - "\033[37;41msome \033[39;49m\033[32msome info\033[39m\033[37;41m error\033[39;49m", - $formatter->format('some some info error') - ); - } - - public function testAdjacentStyles() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals( - "\033[37;41msome error\033[39;49m\033[32msome info\033[39m", - $formatter->format('some errorsome info') - ); - } - - public function testStyleMatchingNotGreedy() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals( - "(\033[32m>=2.0,<2.3\033[39m)", - $formatter->format('(>=2.0,<2.3)') - ); - } - - public function testStyleEscaping() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals( - "(\033[32mz>=2.0,format('('.$formatter->escape('z>=2.0,)') - ); - - $this->assertEquals( - "\033[32msome error\033[39m", - $formatter->format(''.$formatter->escape('some error').'') - ); - } - - public function testDeepNestedStyles() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals( - "\033[37;41merror\033[39;49m\033[32minfo\033[39m\033[33mcomment\033[39m\033[37;41merror\033[39;49m", - $formatter->format('errorinfocommenterror') - ); - } - - public function testNewStyle() - { - $formatter = new OutputFormatter(true); - - $style = new OutputFormatterStyle('blue', 'white'); - $formatter->setStyle('test', $style); - - $this->assertEquals($style, $formatter->getStyle('test')); - $this->assertNotEquals($style, $formatter->getStyle('info')); - - $style = new OutputFormatterStyle('blue', 'white'); - $formatter->setStyle('b', $style); - - $this->assertEquals("\033[34;47msome \033[39;49m\033[34;47mcustom\033[39;49m\033[34;47m msg\033[39;49m", $formatter->format('some custom msg')); - } - - public function testRedefineStyle() - { - $formatter = new OutputFormatter(true); - - $style = new OutputFormatterStyle('blue', 'white'); - $formatter->setStyle('info', $style); - - $this->assertEquals("\033[34;47msome custom msg\033[39;49m", $formatter->format('some custom msg')); - } - - public function testInlineStyle() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals("\033[34;41msome text\033[39;49m", $formatter->format('some text')); - $this->assertEquals("\033[34;41msome text\033[39;49m", $formatter->format('some text')); - } - - public function testNonStyleTag() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals("\033[32msome \033[39m\033[32m\033[39m\033[32m \033[39m\033[32m\033[39m\033[32m styled \033[39m\033[32m

    \033[39m\033[32msingle-char tag\033[39m\033[32m

    \033[39m", $formatter->format('some styled

    single-char tag

    ')); - } - - public function testFormatLongString() - { - $formatter = new OutputFormatter(true); - $long = str_repeat('\\', 14000); - $this->assertEquals("\033[37;41msome error\033[39;49m".$long, $formatter->format('some error'.$long)); - } - - public function testFormatToStringObject() - { - $formatter = new OutputFormatter(false); - $this->assertEquals( - 'some info', $formatter->format(new TableCell()) - ); - } - - public function testNotDecoratedFormatter() - { - $formatter = new OutputFormatter(false); - - $this->assertTrue($formatter->hasStyle('error')); - $this->assertTrue($formatter->hasStyle('info')); - $this->assertTrue($formatter->hasStyle('comment')); - $this->assertTrue($formatter->hasStyle('question')); - - $this->assertEquals( - 'some error', $formatter->format('some error') - ); - $this->assertEquals( - 'some info', $formatter->format('some info') - ); - $this->assertEquals( - 'some comment', $formatter->format('some comment') - ); - $this->assertEquals( - 'some question', $formatter->format('some question') - ); - - $formatter->setDecorated(true); - - $this->assertEquals( - "\033[37;41msome error\033[39;49m", $formatter->format('some error') - ); - $this->assertEquals( - "\033[32msome info\033[39m", $formatter->format('some info') - ); - $this->assertEquals( - "\033[33msome comment\033[39m", $formatter->format('some comment') - ); - $this->assertEquals( - "\033[30;46msome question\033[39;49m", $formatter->format('some question') - ); - } - - public function testContentWithLineBreaks() - { - $formatter = new OutputFormatter(true); - - $this->assertEquals(<<format(<< -some text
    -EOF - )); - - $this->assertEquals(<<format(<<some text -
    -EOF - )); - - $this->assertEquals(<<format(<< -some text -
    -EOF - )); - - $this->assertEquals(<<format(<< -some text -more text -
    -EOF - )); - } -} - -class TableCell -{ - public function __toString() - { - return 'some info'; - } -} diff --git a/vendor/symfony/console/Tests/Helper/FormatterHelperTest.php b/vendor/symfony/console/Tests/Helper/FormatterHelperTest.php deleted file mode 100644 index e33277475..000000000 --- a/vendor/symfony/console/Tests/Helper/FormatterHelperTest.php +++ /dev/null @@ -1,99 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\FormatterHelper; - -class FormatterHelperTest extends \PHPUnit_Framework_TestCase -{ - public function testFormatSection() - { - $formatter = new FormatterHelper(); - - $this->assertEquals( - '[cli] Some text to display', - $formatter->formatSection('cli', 'Some text to display'), - '::formatSection() formats a message in a section' - ); - } - - public function testFormatBlock() - { - $formatter = new FormatterHelper(); - - $this->assertEquals( - ' Some text to display ', - $formatter->formatBlock('Some text to display', 'error'), - '::formatBlock() formats a message in a block' - ); - - $this->assertEquals( - ' Some text to display '."\n". - ' foo bar ', - $formatter->formatBlock(array('Some text to display', 'foo bar'), 'error'), - '::formatBlock() formats a message in a block' - ); - - $this->assertEquals( - ' '."\n". - ' Some text to display '."\n". - ' ', - $formatter->formatBlock('Some text to display', 'error', true), - '::formatBlock() formats a message in a block' - ); - } - - public function testFormatBlockWithDiacriticLetters() - { - if (!function_exists('mb_detect_encoding')) { - $this->markTestSkipped('This test requires mbstring to work.'); - } - - $formatter = new FormatterHelper(); - - $this->assertEquals( - ' '."\n". - ' Du texte à afficher '."\n". - ' ', - $formatter->formatBlock('Du texte à afficher', 'error', true), - '::formatBlock() formats a message in a block' - ); - } - - public function testFormatBlockWithDoubleWidthDiacriticLetters() - { - if (!extension_loaded('mbstring')) { - $this->markTestSkipped('This test requires mbstring to work.'); - } - $formatter = new FormatterHelper(); - $this->assertEquals( - ' '."\n". - ' 表示するテキスト '."\n". - ' ', - $formatter->formatBlock('表示するテキスト', 'error', true), - '::formatBlock() formats a message in a block' - ); - } - - public function testFormatBlockLGEscaping() - { - $formatter = new FormatterHelper(); - - $this->assertEquals( - ' '."\n". - ' \some info\ '."\n". - ' ', - $formatter->formatBlock('some info', 'error', true), - '::formatBlock() escapes \'<\' chars' - ); - } -} diff --git a/vendor/symfony/console/Tests/Helper/HelperSetTest.php b/vendor/symfony/console/Tests/Helper/HelperSetTest.php deleted file mode 100644 index bf58a456e..000000000 --- a/vendor/symfony/console/Tests/Helper/HelperSetTest.php +++ /dev/null @@ -1,153 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\HelperSet; -use Symfony\Component\Console\Command\Command; - -class HelperSetTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::__construct - */ - public function testConstructor() - { - $mock_helper = $this->getGenericMockHelper('fake_helper'); - $helperset = new HelperSet(array('fake_helper_alias' => $mock_helper)); - - $this->assertEquals($mock_helper, $helperset->get('fake_helper_alias'), '__construct sets given helper to helpers'); - $this->assertTrue($helperset->has('fake_helper_alias'), '__construct sets helper alias for given helper'); - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::set - */ - public function testSet() - { - $helperset = new HelperSet(); - $helperset->set($this->getGenericMockHelper('fake_helper', $helperset)); - $this->assertTrue($helperset->has('fake_helper'), '->set() adds helper to helpers'); - - $helperset = new HelperSet(); - $helperset->set($this->getGenericMockHelper('fake_helper_01', $helperset)); - $helperset->set($this->getGenericMockHelper('fake_helper_02', $helperset)); - $this->assertTrue($helperset->has('fake_helper_01'), '->set() will set multiple helpers on consecutive calls'); - $this->assertTrue($helperset->has('fake_helper_02'), '->set() will set multiple helpers on consecutive calls'); - - $helperset = new HelperSet(); - $helperset->set($this->getGenericMockHelper('fake_helper', $helperset), 'fake_helper_alias'); - $this->assertTrue($helperset->has('fake_helper'), '->set() adds helper alias when set'); - $this->assertTrue($helperset->has('fake_helper_alias'), '->set() adds helper alias when set'); - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::has - */ - public function testHas() - { - $helperset = new HelperSet(array('fake_helper_alias' => $this->getGenericMockHelper('fake_helper'))); - $this->assertTrue($helperset->has('fake_helper'), '->has() finds set helper'); - $this->assertTrue($helperset->has('fake_helper_alias'), '->has() finds set helper by alias'); - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::get - */ - public function testGet() - { - $helper_01 = $this->getGenericMockHelper('fake_helper_01'); - $helper_02 = $this->getGenericMockHelper('fake_helper_02'); - $helperset = new HelperSet(array('fake_helper_01_alias' => $helper_01, 'fake_helper_02_alias' => $helper_02)); - $this->assertEquals($helper_01, $helperset->get('fake_helper_01'), '->get() returns correct helper by name'); - $this->assertEquals($helper_01, $helperset->get('fake_helper_01_alias'), '->get() returns correct helper by alias'); - $this->assertEquals($helper_02, $helperset->get('fake_helper_02'), '->get() returns correct helper by name'); - $this->assertEquals($helper_02, $helperset->get('fake_helper_02_alias'), '->get() returns correct helper by alias'); - - $helperset = new HelperSet(); - try { - $helperset->get('foo'); - $this->fail('->get() throws \InvalidArgumentException when helper not found'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->get() throws \InvalidArgumentException when helper not found'); - $this->assertContains('The helper "foo" is not defined.', $e->getMessage(), '->get() throws \InvalidArgumentException when helper not found'); - } - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::setCommand - */ - public function testSetCommand() - { - $cmd_01 = new Command('foo'); - $cmd_02 = new Command('bar'); - - $helperset = new HelperSet(); - $helperset->setCommand($cmd_01); - $this->assertEquals($cmd_01, $helperset->getCommand(), '->setCommand() stores given command'); - - $helperset = new HelperSet(); - $helperset->setCommand($cmd_01); - $helperset->setCommand($cmd_02); - $this->assertEquals($cmd_02, $helperset->getCommand(), '->setCommand() overwrites stored command with consecutive calls'); - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::getCommand - */ - public function testGetCommand() - { - $cmd = new Command('foo'); - $helperset = new HelperSet(); - $helperset->setCommand($cmd); - $this->assertEquals($cmd, $helperset->getCommand(), '->getCommand() retrieves stored command'); - } - - /** - * @covers \Symfony\Component\Console\Helper\HelperSet::getIterator - */ - public function testIteration() - { - $helperset = new HelperSet(); - $helperset->set($this->getGenericMockHelper('fake_helper_01', $helperset)); - $helperset->set($this->getGenericMockHelper('fake_helper_02', $helperset)); - - $helpers = array('fake_helper_01', 'fake_helper_02'); - $i = 0; - - foreach ($helperset as $helper) { - $this->assertEquals($helpers[$i++], $helper->getName()); - } - } - - /** - * Create a generic mock for the helper interface. Optionally check for a call to setHelperSet with a specific - * helperset instance. - * - * @param string $name - * @param HelperSet $helperset allows a mock to verify a particular helperset set is being added to the Helper - */ - private function getGenericMockHelper($name, HelperSet $helperset = null) - { - $mock_helper = $this->getMock('\Symfony\Component\Console\Helper\HelperInterface'); - $mock_helper->expects($this->any()) - ->method('getName') - ->will($this->returnValue($name)); - - if ($helperset) { - $mock_helper->expects($this->any()) - ->method('setHelperSet') - ->with($this->equalTo($helperset)); - } - - return $mock_helper; - } -} diff --git a/vendor/symfony/console/Tests/Helper/LegacyDialogHelperTest.php b/vendor/symfony/console/Tests/Helper/LegacyDialogHelperTest.php deleted file mode 100644 index e130cdc6b..000000000 --- a/vendor/symfony/console/Tests/Helper/LegacyDialogHelperTest.php +++ /dev/null @@ -1,195 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Input\ArrayInput; -use Symfony\Component\Console\Helper\DialogHelper; -use Symfony\Component\Console\Helper\HelperSet; -use Symfony\Component\Console\Helper\FormatterHelper; -use Symfony\Component\Console\Output\StreamOutput; - -/** - * @group legacy - */ -class LegacyDialogHelperTest extends \PHPUnit_Framework_TestCase -{ - public function testSelect() - { - $dialog = new DialogHelper(); - - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $heroes = array('Superman', 'Batman', 'Spiderman'); - - $dialog->setInputStream($this->getInputStream("\n1\n 1 \nFabien\n1\nFabien\n1\n0,2\n 0 , 2 \n\n\n")); - $this->assertEquals('2', $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, '2')); - $this->assertEquals('1', $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes)); - $this->assertEquals('1', $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes)); - $this->assertEquals('1', $dialog->select($output = $this->getOutputStream(), 'What is your favorite superhero?', $heroes, null, false, 'Input "%s" is not a superhero!', false)); - - rewind($output->getStream()); - $this->assertContains('Input "Fabien" is not a superhero!', stream_get_contents($output->getStream())); - - try { - $this->assertEquals('1', $dialog->select($output = $this->getOutputStream(), 'What is your favorite superhero?', $heroes, null, 1)); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('Value "Fabien" is invalid', $e->getMessage()); - } - - $this->assertEquals(array('1'), $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, null, false, 'Input "%s" is not a superhero!', true)); - $this->assertEquals(array('0', '2'), $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, null, false, 'Input "%s" is not a superhero!', true)); - $this->assertEquals(array('0', '2'), $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, null, false, 'Input "%s" is not a superhero!', true)); - $this->assertEquals(array('0', '1'), $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, '0,1', false, 'Input "%s" is not a superhero!', true)); - $this->assertEquals(array('0', '1'), $dialog->select($this->getOutputStream(), 'What is your favorite superhero?', $heroes, ' 0 , 1 ', false, 'Input "%s" is not a superhero!', true)); - } - - public function testAsk() - { - $dialog = new DialogHelper(); - - $dialog->setInputStream($this->getInputStream("\n8AM\n")); - - $this->assertEquals('2PM', $dialog->ask($this->getOutputStream(), 'What time is it?', '2PM')); - $this->assertEquals('8AM', $dialog->ask($output = $this->getOutputStream(), 'What time is it?', '2PM')); - - rewind($output->getStream()); - $this->assertEquals('What time is it?', stream_get_contents($output->getStream())); - } - - public function testAskWithAutocomplete() - { - if (!$this->hasSttyAvailable()) { - $this->markTestSkipped('`stty` is required to test autocomplete functionality'); - } - - // Acm - // AcsTest - // - // - // Test - // - // S - // F00oo - $inputStream = $this->getInputStream("Acm\nAc\177\177s\tTest\n\n\033[A\033[A\n\033[A\033[A\033[A\033[A\033[A\tTest\n\033[B\nS\177\177\033[B\033[B\nF00\177\177oo\t\n"); - - $dialog = new DialogHelper(); - $dialog->setInputStream($inputStream); - - $bundles = array('AcmeDemoBundle', 'AsseticBundle', 'SecurityBundle', 'FooBundle'); - - $this->assertEquals('AcmeDemoBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('AsseticBundleTest', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('FrameworkBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('SecurityBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('FooBundleTest', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('AcmeDemoBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('AsseticBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - $this->assertEquals('FooBundle', $dialog->ask($this->getOutputStream(), 'Please select a bundle', 'FrameworkBundle', $bundles)); - } - - /** - * @group tty - */ - public function testAskHiddenResponse() - { - if ('\\' === DIRECTORY_SEPARATOR) { - $this->markTestSkipped('This test is not supported on Windows'); - } - - $dialog = new DialogHelper(); - - $dialog->setInputStream($this->getInputStream("8AM\n")); - - $this->assertEquals('8AM', $dialog->askHiddenResponse($this->getOutputStream(), 'What time is it?')); - } - - public function testAskConfirmation() - { - $dialog = new DialogHelper(); - - $dialog->setInputStream($this->getInputStream("\n\n")); - $this->assertTrue($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?')); - $this->assertFalse($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?', false)); - - $dialog->setInputStream($this->getInputStream("y\nyes\n")); - $this->assertTrue($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?', false)); - $this->assertTrue($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?', false)); - - $dialog->setInputStream($this->getInputStream("n\nno\n")); - $this->assertFalse($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?', true)); - $this->assertFalse($dialog->askConfirmation($this->getOutputStream(), 'Do you like French fries?', true)); - } - - public function testAskAndValidate() - { - $dialog = new DialogHelper(); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = 'What color was the white horse of Henry IV?'; - $error = 'This is not a color!'; - $validator = function ($color) use ($error) { - if (!in_array($color, array('white', 'black'))) { - throw new \InvalidArgumentException($error); - } - - return $color; - }; - - $dialog->setInputStream($this->getInputStream("\nblack\n")); - $this->assertEquals('white', $dialog->askAndValidate($this->getOutputStream(), $question, $validator, 2, 'white')); - $this->assertEquals('black', $dialog->askAndValidate($this->getOutputStream(), $question, $validator, 2, 'white')); - - $dialog->setInputStream($this->getInputStream("green\nyellow\norange\n")); - try { - $this->assertEquals('white', $dialog->askAndValidate($this->getOutputStream(), $question, $validator, 2, 'white')); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertEquals($error, $e->getMessage()); - } - } - - public function testNoInteraction() - { - $dialog = new DialogHelper(); - - $input = new ArrayInput(array()); - $input->setInteractive(false); - - $dialog->setInput($input); - - $this->assertEquals('not yet', $dialog->ask($this->getOutputStream(), 'Do you have a job?', 'not yet')); - } - - protected function getInputStream($input) - { - $stream = fopen('php://memory', 'r+', false); - fwrite($stream, $input); - rewind($stream); - - return $stream; - } - - protected function getOutputStream() - { - return new StreamOutput(fopen('php://memory', 'r+', false)); - } - - private function hasSttyAvailable() - { - exec('stty 2>&1', $output, $exitcode); - - return $exitcode === 0; - } -} diff --git a/vendor/symfony/console/Tests/Helper/LegacyProgressHelperTest.php b/vendor/symfony/console/Tests/Helper/LegacyProgressHelperTest.php deleted file mode 100644 index e0272463e..000000000 --- a/vendor/symfony/console/Tests/Helper/LegacyProgressHelperTest.php +++ /dev/null @@ -1,240 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\ProgressHelper; -use Symfony\Component\Console\Output\StreamOutput; -use Symfony\Component\Console\Tests; - -require_once __DIR__.'/../ClockMock.php'; - -/** - * @group legacy - */ -class LegacyProgressHelperTest extends \PHPUnit_Framework_TestCase -{ - protected function setUp() - { - Tests\with_clock_mock(true); - } - - protected function tearDown() - { - Tests\with_clock_mock(false); - } - - public function testAdvance() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream()); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 1 [->--------------------------]'), stream_get_contents($output->getStream())); - } - - public function testAdvanceWithStep() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream()); - $progress->advance(5); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 5 [----->----------------------]'), stream_get_contents($output->getStream())); - } - - public function testAdvanceMultipleTimes() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream()); - $progress->advance(3); - $progress->advance(2); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 3 [--->------------------------]').$this->generateOutput(' 5 [----->----------------------]'), stream_get_contents($output->getStream())); - } - - public function testCustomizations() - { - $progress = new ProgressHelper(); - $progress->setBarWidth(10); - $progress->setBarCharacter('_'); - $progress->setEmptyBarCharacter(' '); - $progress->setProgressCharacter('/'); - $progress->setFormat(' %current%/%max% [%bar%] %percent%%'); - $progress->start($output = $this->getOutputStream(), 10); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 1/10 [_/ ] 10%'), stream_get_contents($output->getStream())); - } - - public function testPercent() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(), 50); - $progress->display(); - $progress->advance(); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 0/50 [>---------------------------] 0%').$this->generateOutput(' 1/50 [>---------------------------] 2%').$this->generateOutput(' 2/50 [=>--------------------------] 4%'), stream_get_contents($output->getStream())); - } - - public function testOverwriteWithShorterLine() - { - $progress = new ProgressHelper(); - $progress->setFormat(' %current%/%max% [%bar%] %percent%%'); - $progress->start($output = $this->getOutputStream(), 50); - $progress->display(); - $progress->advance(); - - // set shorter format - $progress->setFormat(' %current%/%max% [%bar%]'); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 1/50 [>---------------------------] 2%'). - $this->generateOutput(' 2/50 [=>--------------------------] '), - stream_get_contents($output->getStream()) - ); - } - - public function testSetCurrentProgress() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(), 50); - $progress->display(); - $progress->advance(); - $progress->setCurrent(15); - $progress->setCurrent(25); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 1/50 [>---------------------------] 2%'). - $this->generateOutput(' 15/50 [========>-------------------] 30%'). - $this->generateOutput(' 25/50 [==============>-------------] 50%'), - stream_get_contents($output->getStream()) - ); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage You must start the progress bar - */ - public function testSetCurrentBeforeStarting() - { - $progress = new ProgressHelper(); - $progress->setCurrent(15); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage You can't regress the progress bar - */ - public function testRegressProgress() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(), 50); - $progress->setCurrent(15); - $progress->setCurrent(10); - } - - public function testRedrawFrequency() - { - $progress = $this->getMock('Symfony\Component\Console\Helper\ProgressHelper', array('display')); - $progress->expects($this->exactly(4)) - ->method('display'); - - $progress->setRedrawFrequency(2); - - $progress->start($output = $this->getOutputStream(), 6); - $progress->setCurrent(1); - $progress->advance(2); - $progress->advance(2); - $progress->advance(1); - } - - public function testMultiByteSupport() - { - if (!function_exists('mb_strlen') || (false === $encoding = mb_detect_encoding('■'))) { - $this->markTestSkipped('The mbstring extension is needed for multi-byte support'); - } - - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream()); - $progress->setBarCharacter('■'); - $progress->advance(3); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 3 [■■■>------------------------]'), stream_get_contents($output->getStream())); - } - - public function testClear() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(), 50); - $progress->setCurrent(25); - $progress->clear(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 25/50 [==============>-------------] 50%').$this->generateOutput(''), - stream_get_contents($output->getStream()) - ); - } - - public function testPercentNotHundredBeforeComplete() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(), 200); - $progress->display(); - $progress->advance(199); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals($this->generateOutput(' 0/200 [>---------------------------] 0%').$this->generateOutput(' 199/200 [===========================>] 99%').$this->generateOutput(' 200/200 [============================] 100%'), stream_get_contents($output->getStream())); - } - - public function testNonDecoratedOutput() - { - $progress = new ProgressHelper(); - $progress->start($output = $this->getOutputStream(false)); - $progress->advance(); - - rewind($output->getStream()); - $this->assertEquals('', stream_get_contents($output->getStream())); - } - - protected function getOutputStream($decorated = true) - { - return new StreamOutput(fopen('php://memory', 'r+', false), StreamOutput::VERBOSITY_NORMAL, $decorated); - } - - protected $lastMessagesLength; - - protected function generateOutput($expected) - { - $expectedout = $expected; - - if ($this->lastMessagesLength !== null) { - $expectedout = str_pad($expected, $this->lastMessagesLength, "\x20", STR_PAD_RIGHT); - } - - $this->lastMessagesLength = strlen($expectedout); - - return "\x0D".$expectedout; - } -} diff --git a/vendor/symfony/console/Tests/Helper/LegacyTableHelperTest.php b/vendor/symfony/console/Tests/Helper/LegacyTableHelperTest.php deleted file mode 100644 index 3b324237e..000000000 --- a/vendor/symfony/console/Tests/Helper/LegacyTableHelperTest.php +++ /dev/null @@ -1,324 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\TableHelper; -use Symfony\Component\Console\Output\StreamOutput; - -/** - * @group legacy - */ -class LegacyTableHelperTest extends \PHPUnit_Framework_TestCase -{ - protected $stream; - - protected function setUp() - { - $this->stream = fopen('php://memory', 'r+'); - } - - protected function tearDown() - { - fclose($this->stream); - $this->stream = null; - } - - /** - * @dataProvider testRenderProvider - */ - public function testRender($headers, $rows, $layout, $expected) - { - $table = new TableHelper(); - $table - ->setHeaders($headers) - ->setRows($rows) - ->setLayout($layout) - ; - $table->render($output = $this->getOutputStream()); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - /** - * @dataProvider testRenderProvider - */ - public function testRenderAddRows($headers, $rows, $layout, $expected) - { - $table = new TableHelper(); - $table - ->setHeaders($headers) - ->addRows($rows) - ->setLayout($layout) - ; - $table->render($output = $this->getOutputStream()); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - /** - * @dataProvider testRenderProvider - */ - public function testRenderAddRowsOneByOne($headers, $rows, $layout, $expected) - { - $table = new TableHelper(); - $table - ->setHeaders($headers) - ->setLayout($layout) - ; - foreach ($rows as $row) { - $table->addRow($row); - } - $table->render($output = $this->getOutputStream()); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - public function testRenderProvider() - { - $books = array( - array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - array('960-425-059-0', 'The Lord of the Rings', 'J. R. R. Tolkien'), - array('80-902734-1-6', 'And Then There Were None', 'Agatha Christie'), - ); - - return array( - array( - array('ISBN', 'Title', 'Author'), - $books, - TableHelper::LAYOUT_DEFAULT, -<< array( - array('ISBN', 'Title', 'Author'), - array( - array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - ), - TableHelper::LAYOUT_DEFAULT, -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array('99921-58-10-700', 'Divine Com', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - ), - TableHelper::LAYOUT_DEFAULT, -<<
    99921-58-10-700 | Divine Com | Dante Alighieri | -| 9971-5-0210-0 | A Tale of Two Cities | Charles Dickens | -+----------------------------------+----------------------+-----------------+ - -TABLE - ), - ); - } - - public function testRenderMultiByte() - { - if (!function_exists('mb_strwidth')) { - $this->markTestSkipped('The "mbstring" extension is not available'); - } - - $table = new TableHelper(); - $table - ->setHeaders(array('■■')) - ->setRows(array(array(1234))) - ->setLayout(TableHelper::LAYOUT_DEFAULT) - ; - $table->render($output = $this->getOutputStream()); - - $expected = -<<
    assertEquals($expected, $this->getOutputContent($output)); - } - - public function testRenderFullWidthCharacters() - { - if (!function_exists('mb_strwidth')) { - $this->markTestSkipped('The "mbstring" extension is not available'); - } - - $table = new TableHelper(); - $table - ->setHeaders(array('あいうえお')) - ->setRows(array(array(1234567890))) - ->setLayout(TableHelper::LAYOUT_DEFAULT) - ; - $table->render($output = $this->getOutputStream()); - - $expected = - <<
    assertEquals($expected, $this->getOutputContent($output)); - } - - protected function getOutputStream() - { - return new StreamOutput($this->stream, StreamOutput::VERBOSITY_NORMAL, false); - } - - protected function getOutputContent(StreamOutput $output) - { - rewind($output->getStream()); - - return str_replace(PHP_EOL, "\n", stream_get_contents($output->getStream())); - } -} diff --git a/vendor/symfony/console/Tests/Helper/ProcessHelperTest.php b/vendor/symfony/console/Tests/Helper/ProcessHelperTest.php deleted file mode 100644 index a51fb4359..000000000 --- a/vendor/symfony/console/Tests/Helper/ProcessHelperTest.php +++ /dev/null @@ -1,117 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\DebugFormatterHelper; -use Symfony\Component\Console\Helper\HelperSet; -use Symfony\Component\Console\Output\StreamOutput; -use Symfony\Component\Console\Helper\ProcessHelper; -use Symfony\Component\Process\Process; - -class ProcessHelperTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider provideCommandsAndOutput - */ - public function testVariousProcessRuns($expected, $cmd, $verbosity, $error) - { - $helper = new ProcessHelper(); - $helper->setHelperSet(new HelperSet(array(new DebugFormatterHelper()))); - $output = $this->getOutputStream($verbosity); - $helper->run($output, $cmd, $error); - $this->assertEquals($expected, $this->getOutput($output)); - } - - public function testPassedCallbackIsExecuted() - { - $helper = new ProcessHelper(); - $helper->setHelperSet(new HelperSet(array(new DebugFormatterHelper()))); - $output = $this->getOutputStream(StreamOutput::VERBOSITY_NORMAL); - - $executed = false; - $callback = function () use (&$executed) { $executed = true; }; - - $helper->run($output, 'php -r "echo 42;"', null, $callback); - $this->assertTrue($executed); - } - - public function provideCommandsAndOutput() - { - $successOutputVerbose = <<42';" - OUT 42 - RES Command ran successfully - -EOT; - $successOutputProcessDebug = <<42\';"', StreamOutput::VERBOSITY_DEBUG, null), - array('', 'php -r "syntax error"', StreamOutput::VERBOSITY_VERBOSE, null), - array($syntaxErrorOutputVerbose, 'php -r "fwrite(STDERR, \'error message\');usleep(50000);fwrite(STDOUT, \'out message\');exit(252);"', StreamOutput::VERBOSITY_VERY_VERBOSE, null), - array($syntaxErrorOutputDebug, 'php -r "fwrite(STDERR, \'error message\');usleep(500000);fwrite(STDOUT, \'out message\');exit(252);"', StreamOutput::VERBOSITY_DEBUG, null), - array($errorMessage.PHP_EOL, 'php -r "fwrite(STDERR, \'error message\');usleep(50000);fwrite(STDOUT, \'out message\');exit(252);"', StreamOutput::VERBOSITY_VERBOSE, $errorMessage), - array($syntaxErrorOutputVerbose.$errorMessage.PHP_EOL, 'php -r "fwrite(STDERR, \'error message\');usleep(50000);fwrite(STDOUT, \'out message\');exit(252);"', StreamOutput::VERBOSITY_VERY_VERBOSE, $errorMessage), - array($syntaxErrorOutputDebug.$errorMessage.PHP_EOL, 'php -r "fwrite(STDERR, \'error message\');usleep(500000);fwrite(STDOUT, \'out message\');exit(252);"', StreamOutput::VERBOSITY_DEBUG, $errorMessage), - array($successOutputProcessDebug, array('php', '-r', 'echo 42;'), StreamOutput::VERBOSITY_DEBUG, null), - array($successOutputDebug, new Process('php -r "echo 42;"'), StreamOutput::VERBOSITY_DEBUG, null), - ); - } - - private function getOutputStream($verbosity) - { - return new StreamOutput(fopen('php://memory', 'r+', false), $verbosity, false); - } - - private function getOutput(StreamOutput $output) - { - rewind($output->getStream()); - - return stream_get_contents($output->getStream()); - } -} diff --git a/vendor/symfony/console/Tests/Helper/ProgressBarTest.php b/vendor/symfony/console/Tests/Helper/ProgressBarTest.php deleted file mode 100644 index e37853e40..000000000 --- a/vendor/symfony/console/Tests/Helper/ProgressBarTest.php +++ /dev/null @@ -1,612 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\ProgressBar; -use Symfony\Component\Console\Helper\Helper; -use Symfony\Component\Console\Output\StreamOutput; -use Symfony\Component\Console\Tests; - -class ProgressBarTest extends \PHPUnit_Framework_TestCase -{ - protected function setUp() - { - Tests\with_clock_mock(true); - } - - protected function tearDown() - { - Tests\with_clock_mock(false); - } - - public function testMultipleStart() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->start(); - $bar->advance(); - $bar->start(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'). - $this->generateOutput(' 1 [->--------------------------]'). - $this->generateOutput(' 0 [>---------------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testAdvance() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->start(); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'). - $this->generateOutput(' 1 [->--------------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testAdvanceWithStep() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->start(); - $bar->advance(5); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'). - $this->generateOutput(' 5 [----->----------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testAdvanceMultipleTimes() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->start(); - $bar->advance(3); - $bar->advance(2); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'). - $this->generateOutput(' 3 [--->------------------------]'). - $this->generateOutput(' 5 [----->----------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testAdvanceOverMax() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 10); - $bar->setProgress(9); - $bar->advance(); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 9/10 [=========================>--] 90%'). - $this->generateOutput(' 10/10 [============================] 100%'). - $this->generateOutput(' 11/11 [============================] 100%'), - stream_get_contents($output->getStream()) - ); - } - - public function testCustomizations() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 10); - $bar->setBarWidth(10); - $bar->setBarCharacter('_'); - $bar->setEmptyBarCharacter(' '); - $bar->setProgressCharacter('/'); - $bar->setFormat(' %current%/%max% [%bar%] %percent:3s%%'); - $bar->start(); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/10 [/ ] 0%'). - $this->generateOutput(' 1/10 [_/ ] 10%'), - stream_get_contents($output->getStream()) - ); - } - - public function testDisplayWithoutStart() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->display(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'), - stream_get_contents($output->getStream()) - ); - } - - public function testDisplayWithQuietVerbosity() - { - $bar = new ProgressBar($output = $this->getOutputStream(true, StreamOutput::VERBOSITY_QUIET), 50); - $bar->display(); - - rewind($output->getStream()); - $this->assertEquals( - '', - stream_get_contents($output->getStream()) - ); - } - - public function testFinishWithoutStart() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 50/50 [============================] 100%'), - stream_get_contents($output->getStream()) - ); - } - - public function testPercent() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->start(); - $bar->display(); - $bar->advance(); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 1/50 [>---------------------------] 2%'). - $this->generateOutput(' 2/50 [=>--------------------------] 4%'), - stream_get_contents($output->getStream()) - ); - } - - public function testOverwriteWithShorterLine() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->setFormat(' %current%/%max% [%bar%] %percent:3s%%'); - $bar->start(); - $bar->display(); - $bar->advance(); - - // set shorter format - $bar->setFormat(' %current%/%max% [%bar%]'); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 1/50 [>---------------------------] 2%'). - $this->generateOutput(' 2/50 [=>--------------------------] '), - stream_get_contents($output->getStream()) - ); - } - - public function testStartWithMax() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->setFormat('%current%/%max% [%bar%]'); - $bar->start(50); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------]'). - $this->generateOutput(' 1/50 [>---------------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testSetCurrentProgress() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->start(); - $bar->display(); - $bar->advance(); - $bar->setProgress(15); - $bar->setProgress(25); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 1/50 [>---------------------------] 2%'). - $this->generateOutput(' 15/50 [========>-------------------] 30%'). - $this->generateOutput(' 25/50 [==============>-------------] 50%'), - stream_get_contents($output->getStream()) - ); - } - - /** - */ - public function testSetCurrentBeforeStarting() - { - $bar = new ProgressBar($this->getOutputStream()); - $bar->setProgress(15); - $this->assertNotNull($bar->getStartTime()); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage You can't regress the progress bar - */ - public function testRegressProgress() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->start(); - $bar->setProgress(15); - $bar->setProgress(10); - } - - public function testRedrawFrequency() - { - $bar = $this->getMock('Symfony\Component\Console\Helper\ProgressBar', array('display'), array($output = $this->getOutputStream(), 6)); - $bar->expects($this->exactly(4))->method('display'); - - $bar->setRedrawFrequency(2); - $bar->start(); - $bar->setProgress(1); - $bar->advance(2); - $bar->advance(2); - $bar->advance(1); - } - - public function testMultiByteSupport() - { - if (!function_exists('mb_strlen') || (false === $encoding = mb_detect_encoding('■'))) { - $this->markTestSkipped('The mbstring extension is needed for multi-byte support'); - } - - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->start(); - $bar->setBarCharacter('■'); - $bar->advance(3); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'). - $this->generateOutput(' 3 [■■■>------------------------]'), - stream_get_contents($output->getStream()) - ); - } - - public function testClear() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 50); - $bar->start(); - $bar->setProgress(25); - $bar->clear(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/50 [>---------------------------] 0%'). - $this->generateOutput(' 25/50 [==============>-------------] 50%'). - $this->generateOutput(' '), - stream_get_contents($output->getStream()) - ); - } - - public function testPercentNotHundredBeforeComplete() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 200); - $bar->start(); - $bar->display(); - $bar->advance(199); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/200 [>---------------------------] 0%'). - $this->generateOutput(' 0/200 [>---------------------------] 0%'). - $this->generateOutput(' 199/200 [===========================>] 99%'). - $this->generateOutput(' 200/200 [============================] 100%'), - stream_get_contents($output->getStream()) - ); - } - - public function testNonDecoratedOutput() - { - $bar = new ProgressBar($output = $this->getOutputStream(false), 200); - $bar->start(); - - for ($i = 0; $i < 200; ++$i) { - $bar->advance(); - } - - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - ' 0/200 [>---------------------------] 0%'.PHP_EOL. - ' 20/200 [==>-------------------------] 10%'.PHP_EOL. - ' 40/200 [=====>----------------------] 20%'.PHP_EOL. - ' 60/200 [========>-------------------] 30%'.PHP_EOL. - ' 80/200 [===========>----------------] 40%'.PHP_EOL. - ' 100/200 [==============>-------------] 50%'.PHP_EOL. - ' 120/200 [================>-----------] 60%'.PHP_EOL. - ' 140/200 [===================>--------] 70%'.PHP_EOL. - ' 160/200 [======================>-----] 80%'.PHP_EOL. - ' 180/200 [=========================>--] 90%'.PHP_EOL. - ' 200/200 [============================] 100%', - stream_get_contents($output->getStream()) - ); - } - - public function testNonDecoratedOutputWithClear() - { - $bar = new ProgressBar($output = $this->getOutputStream(false), 50); - $bar->start(); - $bar->setProgress(25); - $bar->clear(); - $bar->setProgress(50); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - ' 0/50 [>---------------------------] 0%'.PHP_EOL. - ' 25/50 [==============>-------------] 50%'.PHP_EOL. - ' 50/50 [============================] 100%', - stream_get_contents($output->getStream()) - ); - } - - public function testNonDecoratedOutputWithoutMax() - { - $bar = new ProgressBar($output = $this->getOutputStream(false)); - $bar->start(); - $bar->advance(); - - rewind($output->getStream()); - $this->assertEquals( - ' 0 [>---------------------------]'.PHP_EOL. - ' 1 [->--------------------------]', - stream_get_contents($output->getStream()) - ); - } - - public function testParallelBars() - { - $output = $this->getOutputStream(); - $bar1 = new ProgressBar($output, 2); - $bar2 = new ProgressBar($output, 3); - $bar2->setProgressCharacter('#'); - $bar3 = new ProgressBar($output); - - $bar1->start(); - $output->write("\n"); - $bar2->start(); - $output->write("\n"); - $bar3->start(); - - for ($i = 1; $i <= 3; ++$i) { - // up two lines - $output->write("\033[2A"); - if ($i <= 2) { - $bar1->advance(); - } - $output->write("\n"); - $bar2->advance(); - $output->write("\n"); - $bar3->advance(); - } - $output->write("\033[2A"); - $output->write("\n"); - $output->write("\n"); - $bar3->finish(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/2 [>---------------------------] 0%')."\n". - $this->generateOutput(' 0/3 [#---------------------------] 0%')."\n". - rtrim($this->generateOutput(' 0 [>---------------------------]')). - - "\033[2A". - $this->generateOutput(' 1/2 [==============>-------------] 50%')."\n". - $this->generateOutput(' 1/3 [=========#------------------] 33%')."\n". - rtrim($this->generateOutput(' 1 [->--------------------------]')). - - "\033[2A". - $this->generateOutput(' 2/2 [============================] 100%')."\n". - $this->generateOutput(' 2/3 [==================#---------] 66%')."\n". - rtrim($this->generateOutput(' 2 [-->-------------------------]')). - - "\033[2A". - "\n". - $this->generateOutput(' 3/3 [============================] 100%')."\n". - rtrim($this->generateOutput(' 3 [--->------------------------]')). - - "\033[2A". - "\n". - "\n". - rtrim($this->generateOutput(' 3 [============================]')), - stream_get_contents($output->getStream()) - ); - } - - public function testWithoutMax() - { - $output = $this->getOutputStream(); - - $bar = new ProgressBar($output); - $bar->start(); - $bar->advance(); - $bar->advance(); - $bar->advance(); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - rtrim($this->generateOutput(' 0 [>---------------------------]')). - rtrim($this->generateOutput(' 1 [->--------------------------]')). - rtrim($this->generateOutput(' 2 [-->-------------------------]')). - rtrim($this->generateOutput(' 3 [--->------------------------]')). - rtrim($this->generateOutput(' 3 [============================]')), - stream_get_contents($output->getStream()) - ); - } - - public function testAddingPlaceholderFormatter() - { - ProgressBar::setPlaceholderFormatterDefinition('remaining_steps', function (ProgressBar $bar) { - return $bar->getMaxSteps() - $bar->getProgress(); - }); - $bar = new ProgressBar($output = $this->getOutputStream(), 3); - $bar->setFormat(' %remaining_steps% [%bar%]'); - - $bar->start(); - $bar->advance(); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 3 [>---------------------------]'). - $this->generateOutput(' 2 [=========>------------------]'). - $this->generateOutput(' 0 [============================]'), - stream_get_contents($output->getStream()) - ); - } - - public function testMultilineFormat() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 3); - $bar->setFormat("%bar%\nfoobar"); - - $bar->start(); - $bar->advance(); - $bar->clear(); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(">---------------------------\nfoobar"). - $this->generateOutput("=========>------------------\nfoobar "). - $this->generateOutput(" \n "). - $this->generateOutput("============================\nfoobar "), - stream_get_contents($output->getStream()) - ); - } - - /** - * @requires extension mbstring - */ - public function testAnsiColorsAndEmojis() - { - $bar = new ProgressBar($output = $this->getOutputStream(), 15); - ProgressBar::setPlaceholderFormatterDefinition('memory', function (ProgressBar $bar) { - static $i = 0; - $mem = 100000 * $i; - $colors = $i++ ? '41;37' : '44;37'; - - return "\033[".$colors.'m '.Helper::formatMemory($mem)." \033[0m"; - }); - $bar->setFormat(" \033[44;37m %title:-37s% \033[0m\n %current%/%max% %bar% %percent:3s%%\n 🏁 %remaining:-10s% %memory:37s%"); - $bar->setBarCharacter($done = "\033[32m●\033[0m"); - $bar->setEmptyBarCharacter($empty = "\033[31m●\033[0m"); - $bar->setProgressCharacter($progress = "\033[32m➤ \033[0m"); - - $bar->setMessage('Starting the demo... fingers crossed', 'title'); - $bar->start(); - $bar->setMessage('Looks good to me...', 'title'); - $bar->advance(4); - $bar->setMessage('Thanks, bye', 'title'); - $bar->finish(); - - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput( - " \033[44;37m Starting the demo... fingers crossed \033[0m\n". - ' 0/15 '.$progress.str_repeat($empty, 26)." 0%\n". - " \xf0\x9f\x8f\x81 1 sec \033[44;37m 0 B \033[0m" - ). - $this->generateOutput( - " \033[44;37m Looks good to me... \033[0m\n". - ' 4/15 '.str_repeat($done, 7).$progress.str_repeat($empty, 19)." 26%\n". - " \xf0\x9f\x8f\x81 1 sec \033[41;37m 97 KiB \033[0m" - ). - $this->generateOutput( - " \033[44;37m Thanks, bye \033[0m\n". - ' 15/15 '.str_repeat($done, 28)." 100%\n". - " \xf0\x9f\x8f\x81 1 sec \033[41;37m 195 KiB \033[0m" - ), - stream_get_contents($output->getStream()) - ); - } - - public function testSetFormat() - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->setFormat('normal'); - $bar->start(); - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0 [>---------------------------]'), - stream_get_contents($output->getStream()) - ); - - $bar = new ProgressBar($output = $this->getOutputStream(), 10); - $bar->setFormat('normal'); - $bar->start(); - rewind($output->getStream()); - $this->assertEquals( - $this->generateOutput(' 0/10 [>---------------------------] 0%'), - stream_get_contents($output->getStream()) - ); - } - - /** - * @dataProvider provideFormat - */ - public function testFormatsWithoutMax($format) - { - $bar = new ProgressBar($output = $this->getOutputStream()); - $bar->setFormat($format); - $bar->start(); - - rewind($output->getStream()); - $this->assertNotEmpty(stream_get_contents($output->getStream())); - } - - /** - * Provides each defined format. - * - * @return array - */ - public function provideFormat() - { - return array( - array('normal'), - array('verbose'), - array('very_verbose'), - array('debug'), - ); - } - - protected function getOutputStream($decorated = true, $verbosity = StreamOutput::VERBOSITY_NORMAL) - { - return new StreamOutput(fopen('php://memory', 'r+', false), $verbosity, $decorated); - } - - protected function generateOutput($expected) - { - $count = substr_count($expected, "\n"); - - return "\x0D".($count ? sprintf("\033[%dA", $count) : '').$expected; - } -} diff --git a/vendor/symfony/console/Tests/Helper/QuestionHelperTest.php b/vendor/symfony/console/Tests/Helper/QuestionHelperTest.php deleted file mode 100644 index a1f85b174..000000000 --- a/vendor/symfony/console/Tests/Helper/QuestionHelperTest.php +++ /dev/null @@ -1,383 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\QuestionHelper; -use Symfony\Component\Console\Helper\HelperSet; -use Symfony\Component\Console\Helper\FormatterHelper; -use Symfony\Component\Console\Output\StreamOutput; -use Symfony\Component\Console\Question\ChoiceQuestion; -use Symfony\Component\Console\Question\ConfirmationQuestion; -use Symfony\Component\Console\Question\Question; - -/** - * @group tty - */ -class QuestionHelperTest extends \PHPUnit_Framework_TestCase -{ - public function testAskChoice() - { - $questionHelper = new QuestionHelper(); - - $helperSet = new HelperSet(array(new FormatterHelper())); - $questionHelper->setHelperSet($helperSet); - - $heroes = array('Superman', 'Batman', 'Spiderman'); - - $questionHelper->setInputStream($this->getInputStream("\n1\n 1 \nFabien\n1\nFabien\n1\n0,2\n 0 , 2 \n\n\n")); - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes, '2'); - $question->setMaxAttempts(1); - // first answer is an empty answer, we're supposed to receive the default value - $this->assertEquals('Spiderman', $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes); - $question->setMaxAttempts(1); - $this->assertEquals('Batman', $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('Batman', $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes); - $question->setErrorMessage('Input "%s" is not a superhero!'); - $question->setMaxAttempts(2); - $this->assertEquals('Batman', $questionHelper->ask($this->createInputInterfaceMock(), $output = $this->createOutputInterface(), $question)); - - rewind($output->getStream()); - $stream = stream_get_contents($output->getStream()); - $this->assertContains('Input "Fabien" is not a superhero!', $stream); - - try { - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes, '1'); - $question->setMaxAttempts(1); - $questionHelper->ask($this->createInputInterfaceMock(), $output = $this->createOutputInterface(), $question); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('Value "Fabien" is invalid', $e->getMessage()); - } - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes, null); - $question->setMaxAttempts(1); - $question->setMultiselect(true); - - $this->assertEquals(array('Batman'), $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals(array('Superman', 'Spiderman'), $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals(array('Superman', 'Spiderman'), $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes, '0,1'); - $question->setMaxAttempts(1); - $question->setMultiselect(true); - - $this->assertEquals(array('Superman', 'Batman'), $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $question = new ChoiceQuestion('What is your favorite superhero?', $heroes, ' 0 , 1 '); - $question->setMaxAttempts(1); - $question->setMultiselect(true); - - $this->assertEquals(array('Superman', 'Batman'), $questionHelper->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - } - - public function testAsk() - { - $dialog = new QuestionHelper(); - - $dialog->setInputStream($this->getInputStream("\n8AM\n")); - - $question = new Question('What time is it?', '2PM'); - $this->assertEquals('2PM', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $question = new Question('What time is it?', '2PM'); - $this->assertEquals('8AM', $dialog->ask($this->createInputInterfaceMock(), $output = $this->createOutputInterface(), $question)); - - rewind($output->getStream()); - $this->assertEquals('What time is it?', stream_get_contents($output->getStream())); - } - - public function testAskWithAutocomplete() - { - if (!$this->hasSttyAvailable()) { - $this->markTestSkipped('`stty` is required to test autocomplete functionality'); - } - - // Acm - // AcsTest - // - // - // Test - // - // S - // F00oo - $inputStream = $this->getInputStream("Acm\nAc\177\177s\tTest\n\n\033[A\033[A\n\033[A\033[A\033[A\033[A\033[A\tTest\n\033[B\nS\177\177\033[B\033[B\nF00\177\177oo\t\n"); - - $dialog = new QuestionHelper(); - $dialog->setInputStream($inputStream); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = new Question('Please select a bundle', 'FrameworkBundle'); - $question->setAutocompleterValues(array('AcmeDemoBundle', 'AsseticBundle', 'SecurityBundle', 'FooBundle')); - - $this->assertEquals('AcmeDemoBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('AsseticBundleTest', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('FrameworkBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('SecurityBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('FooBundleTest', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('AcmeDemoBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('AsseticBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('FooBundle', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - } - - public function testAskHiddenResponse() - { - if ('\\' === DIRECTORY_SEPARATOR) { - $this->markTestSkipped('This test is not supported on Windows'); - } - - $dialog = new QuestionHelper(); - $dialog->setInputStream($this->getInputStream("8AM\n")); - - $question = new Question('What time is it?'); - $question->setHidden(true); - - $this->assertEquals('8AM', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - } - - /** - * @dataProvider getAskConfirmationData - */ - public function testAskConfirmation($question, $expected, $default = true) - { - $dialog = new QuestionHelper(); - - $dialog->setInputStream($this->getInputStream($question."\n")); - $question = new ConfirmationQuestion('Do you like French fries?', $default); - $this->assertEquals($expected, $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question), 'confirmation question should '.($expected ? 'pass' : 'cancel')); - } - - public function getAskConfirmationData() - { - return array( - array('', true), - array('', false, false), - array('y', true), - array('yes', true), - array('n', false), - array('no', false), - ); - } - - public function testAskConfirmationWithCustomTrueAnswer() - { - $dialog = new QuestionHelper(); - - $dialog->setInputStream($this->getInputStream("j\ny\n")); - $question = new ConfirmationQuestion('Do you like French fries?', false, '/^(j|y)/i'); - $this->assertTrue($dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $question = new ConfirmationQuestion('Do you like French fries?', false, '/^(j|y)/i'); - $this->assertTrue($dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - } - - public function testAskAndValidate() - { - $dialog = new QuestionHelper(); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $error = 'This is not a color!'; - $validator = function ($color) use ($error) { - if (!in_array($color, array('white', 'black'))) { - throw new \InvalidArgumentException($error); - } - - return $color; - }; - - $question = new Question('What color was the white horse of Henry IV?', 'white'); - $question->setValidator($validator); - $question->setMaxAttempts(2); - - $dialog->setInputStream($this->getInputStream("\nblack\n")); - $this->assertEquals('white', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - $this->assertEquals('black', $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question)); - - $dialog->setInputStream($this->getInputStream("green\nyellow\norange\n")); - try { - $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertEquals($error, $e->getMessage()); - } - } - - /** - * @dataProvider simpleAnswerProvider - */ - public function testSelectChoiceFromSimpleChoices($providedAnswer, $expectedValue) - { - $possibleChoices = array( - 'My environment 1', - 'My environment 2', - 'My environment 3', - ); - - $dialog = new QuestionHelper(); - $dialog->setInputStream($this->getInputStream($providedAnswer."\n")); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = new ChoiceQuestion('Please select the environment to load', $possibleChoices); - $question->setMaxAttempts(1); - $answer = $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question); - - $this->assertSame($expectedValue, $answer); - } - - public function simpleAnswerProvider() - { - return array( - array(0, 'My environment 1'), - array(1, 'My environment 2'), - array(2, 'My environment 3'), - array('My environment 1', 'My environment 1'), - array('My environment 2', 'My environment 2'), - array('My environment 3', 'My environment 3'), - ); - } - - /** - * @dataProvider mixedKeysChoiceListAnswerProvider - */ - public function testChoiceFromChoicelistWithMixedKeys($providedAnswer, $expectedValue) - { - $possibleChoices = array( - '0' => 'No environment', - '1' => 'My environment 1', - 'env_2' => 'My environment 2', - 3 => 'My environment 3', - ); - - $dialog = new QuestionHelper(); - $dialog->setInputStream($this->getInputStream($providedAnswer."\n")); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = new ChoiceQuestion('Please select the environment to load', $possibleChoices); - $question->setMaxAttempts(1); - $answer = $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question); - - $this->assertSame($expectedValue, $answer); - } - - public function mixedKeysChoiceListAnswerProvider() - { - return array( - array('0', '0'), - array('No environment', '0'), - array('1', '1'), - array('env_2', 'env_2'), - array(3, '3'), - array('My environment 1', '1'), - ); - } - - /** - * @dataProvider answerProvider - */ - public function testSelectChoiceFromChoiceList($providedAnswer, $expectedValue) - { - $possibleChoices = array( - 'env_1' => 'My environment 1', - 'env_2' => 'My environment', - 'env_3' => 'My environment', - ); - - $dialog = new QuestionHelper(); - $dialog->setInputStream($this->getInputStream($providedAnswer."\n")); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = new ChoiceQuestion('Please select the environment to load', $possibleChoices); - $question->setMaxAttempts(1); - $answer = $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question); - - $this->assertSame($expectedValue, $answer); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The provided answer is ambiguous. Value should be one of env_2 or env_3. - */ - public function testAmbiguousChoiceFromChoicelist() - { - $possibleChoices = array( - 'env_1' => 'My first environment', - 'env_2' => 'My environment', - 'env_3' => 'My environment', - ); - - $dialog = new QuestionHelper(); - $dialog->setInputStream($this->getInputStream("My environment\n")); - $helperSet = new HelperSet(array(new FormatterHelper())); - $dialog->setHelperSet($helperSet); - - $question = new ChoiceQuestion('Please select the environment to load', $possibleChoices); - $question->setMaxAttempts(1); - - $dialog->ask($this->createInputInterfaceMock(), $this->createOutputInterface(), $question); - } - - public function answerProvider() - { - return array( - array('env_1', 'env_1'), - array('env_2', 'env_2'), - array('env_3', 'env_3'), - array('My environment 1', 'env_1'), - ); - } - - public function testNoInteraction() - { - $dialog = new QuestionHelper(); - $question = new Question('Do you have a job?', 'not yet'); - $this->assertEquals('not yet', $dialog->ask($this->createInputInterfaceMock(false), $this->createOutputInterface(), $question)); - } - - protected function getInputStream($input) - { - $stream = fopen('php://memory', 'r+', false); - fwrite($stream, $input); - rewind($stream); - - return $stream; - } - - protected function createOutputInterface() - { - return new StreamOutput(fopen('php://memory', 'r+', false)); - } - - protected function createInputInterfaceMock($interactive = true) - { - $mock = $this->getMock('Symfony\Component\Console\Input\InputInterface'); - $mock->expects($this->any()) - ->method('isInteractive') - ->will($this->returnValue($interactive)); - - return $mock; - } - - private function hasSttyAvailable() - { - exec('stty 2>&1', $output, $exitcode); - - return $exitcode === 0; - } -} diff --git a/vendor/symfony/console/Tests/Helper/TableStyleTest.php b/vendor/symfony/console/Tests/Helper/TableStyleTest.php deleted file mode 100644 index 587d8414e..000000000 --- a/vendor/symfony/console/Tests/Helper/TableStyleTest.php +++ /dev/null @@ -1,27 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\TableStyle; - -class TableStyleTest extends \PHPUnit_Framework_TestCase -{ - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Invalid padding type. Expected one of (STR_PAD_LEFT, STR_PAD_RIGHT, STR_PAD_BOTH). - */ - public function testSetPadTypeWithInvalidType() - { - $style = new TableStyle(); - $style->setPadType('TEST'); - } -} diff --git a/vendor/symfony/console/Tests/Helper/TableTest.php b/vendor/symfony/console/Tests/Helper/TableTest.php deleted file mode 100644 index ad0537940..000000000 --- a/vendor/symfony/console/Tests/Helper/TableTest.php +++ /dev/null @@ -1,568 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Helper; - -use Symfony\Component\Console\Helper\Table; -use Symfony\Component\Console\Helper\TableStyle; -use Symfony\Component\Console\Helper\TableSeparator; -use Symfony\Component\Console\Helper\TableCell; -use Symfony\Component\Console\Output\StreamOutput; - -class TableTest extends \PHPUnit_Framework_TestCase -{ - protected $stream; - - protected function setUp() - { - $this->stream = fopen('php://memory', 'r+'); - } - - protected function tearDown() - { - fclose($this->stream); - $this->stream = null; - } - - /** - * @dataProvider testRenderProvider - */ - public function testRender($headers, $rows, $style, $expected) - { - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders($headers) - ->setRows($rows) - ->setStyle($style) - ; - $table->render(); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - /** - * @dataProvider testRenderProvider - */ - public function testRenderAddRows($headers, $rows, $style, $expected) - { - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders($headers) - ->addRows($rows) - ->setStyle($style) - ; - $table->render(); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - /** - * @dataProvider testRenderProvider - */ - public function testRenderAddRowsOneByOne($headers, $rows, $style, $expected) - { - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders($headers) - ->setStyle($style) - ; - foreach ($rows as $row) { - $table->addRow($row); - } - $table->render(); - - $this->assertEquals($expected, $this->getOutputContent($output)); - } - - public function testRenderProvider() - { - $books = array( - array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - array('960-425-059-0', 'The Lord of the Rings', 'J. R. R. Tolkien'), - array('80-902734-1-6', 'And Then There Were None', 'Agatha Christie'), - ); - - return array( - array( - array('ISBN', 'Title', 'Author'), - $books, - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - ), - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array('99921-58-10-700', 'Divine Com', 'Dante Alighieri'), - array('9971-5-0210-0', 'A Tale of Two Cities', 'Charles Dickens'), - ), - 'default', -<<
    99921-58-10-700 | Divine Com | Dante Alighieri | -| 9971-5-0210-0 | A Tale of Two Cities | Charles Dickens | -+----------------------------------+----------------------+-----------------+ - -TABLE - ), - 'Cell with colspan' => array( - array('ISBN', 'Title', 'Author'), - array( - array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'), - new TableSeparator(), - array(new TableCell('Divine Comedy(Dante Alighieri)', array('colspan' => 3))), - new TableSeparator(), - array( - new TableCell('Arduino: A Quick-Start Guide', array('colspan' => 2)), - 'Mark Schmidt', - ), - new TableSeparator(), - array( - '9971-5-0210-0', - new TableCell("A Tale of \nTwo Cities", array('colspan' => 2)), - ), - ), - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array( - new TableCell('9971-5-0210-0', array('rowspan' => 3)), - 'Divine Comedy', - 'Dante Alighieri', - ), - array('A Tale of Two Cities', 'Charles Dickens'), - array("The Lord of \nthe Rings", "J. R. \nR. Tolkien"), - new TableSeparator(), - array('80-902734-1-6', new TableCell("And Then \nThere \nWere None", array('rowspan' => 3)), 'Agatha Christie'), - array('80-902734-1-7', 'Test'), - ), - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array( - new TableCell('9971-5-0210-0', array('rowspan' => 2, 'colspan' => 2)), - 'Dante Alighieri', - ), - array('Charles Dickens'), - new TableSeparator(), - array( - 'Dante Alighieri', - new TableCell('9971-5-0210-0', array('rowspan' => 3, 'colspan' => 2)), - ), - array('J. R. R. Tolkien'), - array('J. R. R'), - ), - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array( - new TableCell("9971\n-5-\n021\n0-0", array('rowspan' => 2, 'colspan' => 2)), - 'Dante Alighieri', - ), - array('Charles Dickens'), - new TableSeparator(), - array( - 'Dante Alighieri', - new TableCell("9971\n-5-\n021\n0-0", array('rowspan' => 2, 'colspan' => 2)), - ), - array('Charles Dickens'), - new TableSeparator(), - array( - new TableCell("9971\n-5-\n021\n0-0", array('rowspan' => 2, 'colspan' => 2)), - new TableCell("Dante \nAlighieri", array('rowspan' => 2, 'colspan' => 1)), - ), - ), - 'default', -<<
    array( - array('ISBN', 'Title', 'Author'), - array( - array( - new TableCell("9971\n-5-\n021\n0-0", array('rowspan' => 2, 'colspan' => 2)), - 'Dante Alighieri', - ), - array('Charles Dickens'), - array( - 'Dante Alighieri', - new TableCell("9971\n-5-\n021\n0-0", array('rowspan' => 2, 'colspan' => 2)), - ), - array('Charles Dickens'), - ), - 'default', -<<
    array( - array('ISBN', 'Author'), - array( - array( - new TableCell('9971-5-0210-0', array('rowspan' => 3, 'colspan' => 1)), - 'Dante Alighieri', - ), - array(new TableSeparator()), - array('Charles Dickens'), - ), - 'default', -<<
    array( - array( - array(new TableCell('Main title', array('colspan' => 3))), - array('ISBN', 'Title', 'Author'), - ), - array(), - 'default', -<<
    markTestSkipped('The "mbstring" extension is not available'); - } - - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders(array('■■')) - ->setRows(array(array(1234))) - ->setStyle('default') - ; - $table->render(); - - $expected = -<<
    assertEquals($expected, $this->getOutputContent($output)); - } - - public function testStyle() - { - $style = new TableStyle(); - $style - ->setHorizontalBorderChar('.') - ->setVerticalBorderChar('.') - ->setCrossingChar('.') - ; - - Table::setStyleDefinition('dotfull', $style); - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders(array('Foo')) - ->setRows(array(array('Bar'))) - ->setStyle('dotfull'); - $table->render(); - - $expected = -<<
    assertEquals($expected, $this->getOutputContent($output)); - } - - public function testRowSeparator() - { - $table = new Table($output = $this->getOutputStream()); - $table - ->setHeaders(array('Foo')) - ->setRows(array( - array('Bar1'), - new TableSeparator(), - array('Bar2'), - new TableSeparator(), - array('Bar3'), - )); - $table->render(); - - $expected = -<<
    assertEquals($expected, $this->getOutputContent($output)); - - $this->assertEquals($table, $table->addRow(new TableSeparator()), 'fluent interface on addRow() with a single TableSeparator() works'); - } - - protected function getOutputStream() - { - return new StreamOutput($this->stream, StreamOutput::VERBOSITY_NORMAL, false); - } - - protected function getOutputContent(StreamOutput $output) - { - rewind($output->getStream()); - - return str_replace(PHP_EOL, "\n", stream_get_contents($output->getStream())); - } -} diff --git a/vendor/symfony/console/Tests/Input/ArgvInputTest.php b/vendor/symfony/console/Tests/Input/ArgvInputTest.php deleted file mode 100644 index d2c540e6f..000000000 --- a/vendor/symfony/console/Tests/Input/ArgvInputTest.php +++ /dev/null @@ -1,317 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\ArgvInput; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; - -class ArgvInputTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $_SERVER['argv'] = array('cli.php', 'foo'); - $input = new ArgvInput(); - $r = new \ReflectionObject($input); - $p = $r->getProperty('tokens'); - $p->setAccessible(true); - - $this->assertEquals(array('foo'), $p->getValue($input), '__construct() automatically get its input from the argv server variable'); - } - - public function testParseArguments() - { - $input = new ArgvInput(array('cli.php', 'foo')); - $input->bind(new InputDefinition(array(new InputArgument('name')))); - $this->assertEquals(array('name' => 'foo'), $input->getArguments(), '->parse() parses required arguments'); - - $input->bind(new InputDefinition(array(new InputArgument('name')))); - $this->assertEquals(array('name' => 'foo'), $input->getArguments(), '->parse() is stateless'); - } - - /** - * @dataProvider provideOptions - */ - public function testParseOptions($input, $options, $expectedOptions, $message) - { - $input = new ArgvInput($input); - $input->bind(new InputDefinition($options)); - - $this->assertEquals($expectedOptions, $input->getOptions(), $message); - } - - public function provideOptions() - { - return array( - array( - array('cli.php', '--foo'), - array(new InputOption('foo')), - array('foo' => true), - '->parse() parses long options without a value', - ), - array( - array('cli.php', '--foo=bar'), - array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED)), - array('foo' => 'bar'), - '->parse() parses long options with a required value (with a = separator)', - ), - array( - array('cli.php', '--foo', 'bar'), - array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED)), - array('foo' => 'bar'), - '->parse() parses long options with a required value (with a space separator)', - ), - array( - array('cli.php', '-f'), - array(new InputOption('foo', 'f')), - array('foo' => true), - '->parse() parses short options without a value', - ), - array( - array('cli.php', '-fbar'), - array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED)), - array('foo' => 'bar'), - '->parse() parses short options with a required value (with no separator)', - ), - array( - array('cli.php', '-f', 'bar'), - array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED)), - array('foo' => 'bar'), - '->parse() parses short options with a required value (with a space separator)', - ), - array( - array('cli.php', '-f', ''), - array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL)), - array('foo' => ''), - '->parse() parses short options with an optional empty value', - ), - array( - array('cli.php', '-f', '', 'foo'), - array(new InputArgument('name'), new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL)), - array('foo' => ''), - '->parse() parses short options with an optional empty value followed by an argument', - ), - array( - array('cli.php', '-f', '', '-b'), - array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL), new InputOption('bar', 'b')), - array('foo' => '', 'bar' => true), - '->parse() parses short options with an optional empty value followed by an option', - ), - array( - array('cli.php', '-f', '-b', 'foo'), - array(new InputArgument('name'), new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL), new InputOption('bar', 'b')), - array('foo' => null, 'bar' => true), - '->parse() parses short options with an optional value which is not present', - ), - array( - array('cli.php', '-fb'), - array(new InputOption('foo', 'f'), new InputOption('bar', 'b')), - array('foo' => true, 'bar' => true), - '->parse() parses short options when they are aggregated as a single one', - ), - array( - array('cli.php', '-fb', 'bar'), - array(new InputOption('foo', 'f'), new InputOption('bar', 'b', InputOption::VALUE_REQUIRED)), - array('foo' => true, 'bar' => 'bar'), - '->parse() parses short options when they are aggregated as a single one and the last one has a required value', - ), - array( - array('cli.php', '-fb', 'bar'), - array(new InputOption('foo', 'f'), new InputOption('bar', 'b', InputOption::VALUE_OPTIONAL)), - array('foo' => true, 'bar' => 'bar'), - '->parse() parses short options when they are aggregated as a single one and the last one has an optional value', - ), - array( - array('cli.php', '-fbbar'), - array(new InputOption('foo', 'f'), new InputOption('bar', 'b', InputOption::VALUE_OPTIONAL)), - array('foo' => true, 'bar' => 'bar'), - '->parse() parses short options when they are aggregated as a single one and the last one has an optional value with no separator', - ), - array( - array('cli.php', '-fbbar'), - array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL), new InputOption('bar', 'b', InputOption::VALUE_OPTIONAL)), - array('foo' => 'bbar', 'bar' => null), - '->parse() parses short options when they are aggregated as a single one and one of them takes a value', - ), - ); - } - - /** - * @dataProvider provideInvalidInput - */ - public function testInvalidInput($argv, $definition, $expectedExceptionMessage) - { - $this->setExpectedException('RuntimeException', $expectedExceptionMessage); - - $input = new ArgvInput($argv); - $input->bind($definition); - } - - public function provideInvalidInput() - { - return array( - array( - array('cli.php', '--foo'), - new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED))), - 'The "--foo" option requires a value.', - ), - array( - array('cli.php', '-f'), - new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED))), - 'The "--foo" option requires a value.', - ), - array( - array('cli.php', '-ffoo'), - new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_NONE))), - 'The "-o" option does not exist.', - ), - array( - array('cli.php', '--foo=bar'), - new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_NONE))), - 'The "--foo" option does not accept a value.', - ), - array( - array('cli.php', 'foo', 'bar'), - new InputDefinition(), - 'Too many arguments.', - ), - array( - array('cli.php', '--foo'), - new InputDefinition(), - 'The "--foo" option does not exist.', - ), - array( - array('cli.php', '-f'), - new InputDefinition(), - 'The "-f" option does not exist.', - ), - array( - array('cli.php', '-1'), - new InputDefinition(array(new InputArgument('number'))), - 'The "-1" option does not exist.', - ), - ); - } - - public function testParseArrayArgument() - { - $input = new ArgvInput(array('cli.php', 'foo', 'bar', 'baz', 'bat')); - $input->bind(new InputDefinition(array(new InputArgument('name', InputArgument::IS_ARRAY)))); - - $this->assertEquals(array('name' => array('foo', 'bar', 'baz', 'bat')), $input->getArguments(), '->parse() parses array arguments'); - } - - public function testParseArrayOption() - { - $input = new ArgvInput(array('cli.php', '--name=foo', '--name=bar', '--name=baz')); - $input->bind(new InputDefinition(array(new InputOption('name', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY)))); - - $this->assertEquals(array('name' => array('foo', 'bar', 'baz')), $input->getOptions(), '->parse() parses array options ("--option=value" syntax)'); - - $input = new ArgvInput(array('cli.php', '--name', 'foo', '--name', 'bar', '--name', 'baz')); - $input->bind(new InputDefinition(array(new InputOption('name', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY)))); - $this->assertEquals(array('name' => array('foo', 'bar', 'baz')), $input->getOptions(), '->parse() parses array options ("--option value" syntax)'); - - $input = new ArgvInput(array('cli.php', '--name=foo', '--name=bar', '--name=')); - $input->bind(new InputDefinition(array(new InputOption('name', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY)))); - $this->assertSame(array('name' => array('foo', 'bar', null)), $input->getOptions(), '->parse() parses empty array options as null ("--option=value" syntax)'); - - $input = new ArgvInput(array('cli.php', '--name', 'foo', '--name', 'bar', '--name', '--anotherOption')); - $input->bind(new InputDefinition(array( - new InputOption('name', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY), - new InputOption('anotherOption', null, InputOption::VALUE_NONE), - ))); - $this->assertSame(array('name' => array('foo', 'bar', null), 'anotherOption' => true), $input->getOptions(), '->parse() parses empty array options as null ("--option value" syntax)'); - } - - public function testParseNegativeNumberAfterDoubleDash() - { - $input = new ArgvInput(array('cli.php', '--', '-1')); - $input->bind(new InputDefinition(array(new InputArgument('number')))); - $this->assertEquals(array('number' => '-1'), $input->getArguments(), '->parse() parses arguments with leading dashes as arguments after having encountered a double-dash sequence'); - - $input = new ArgvInput(array('cli.php', '-f', 'bar', '--', '-1')); - $input->bind(new InputDefinition(array(new InputArgument('number'), new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL)))); - $this->assertEquals(array('foo' => 'bar'), $input->getOptions(), '->parse() parses arguments with leading dashes as options before having encountered a double-dash sequence'); - $this->assertEquals(array('number' => '-1'), $input->getArguments(), '->parse() parses arguments with leading dashes as arguments after having encountered a double-dash sequence'); - } - - public function testParseEmptyStringArgument() - { - $input = new ArgvInput(array('cli.php', '-f', 'bar', '')); - $input->bind(new InputDefinition(array(new InputArgument('empty'), new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL)))); - - $this->assertEquals(array('empty' => ''), $input->getArguments(), '->parse() parses empty string arguments'); - } - - public function testGetFirstArgument() - { - $input = new ArgvInput(array('cli.php', '-fbbar')); - $this->assertNull($input->getFirstArgument(), '->getFirstArgument() returns null when there is no arguments'); - - $input = new ArgvInput(array('cli.php', '-fbbar', 'foo')); - $this->assertEquals('foo', $input->getFirstArgument(), '->getFirstArgument() returns the first argument from the raw input'); - } - - public function testHasParameterOption() - { - $input = new ArgvInput(array('cli.php', '-f', 'foo')); - $this->assertTrue($input->hasParameterOption('-f'), '->hasParameterOption() returns true if the given short option is in the raw input'); - - $input = new ArgvInput(array('cli.php', '--foo', 'foo')); - $this->assertTrue($input->hasParameterOption('--foo'), '->hasParameterOption() returns true if the given short option is in the raw input'); - - $input = new ArgvInput(array('cli.php', 'foo')); - $this->assertFalse($input->hasParameterOption('--foo'), '->hasParameterOption() returns false if the given short option is not in the raw input'); - - $input = new ArgvInput(array('cli.php', '--foo=bar')); - $this->assertTrue($input->hasParameterOption('--foo'), '->hasParameterOption() returns true if the given option with provided value is in the raw input'); - } - - public function testToString() - { - $input = new ArgvInput(array('cli.php', '-f', 'foo')); - $this->assertEquals('-f foo', (string) $input); - - $input = new ArgvInput(array('cli.php', '-f', '--bar=foo', 'a b c d', "A\nB'C")); - $this->assertEquals('-f --bar=foo '.escapeshellarg('a b c d').' '.escapeshellarg("A\nB'C"), (string) $input); - } - - /** - * @dataProvider provideGetParameterOptionValues - */ - public function testGetParameterOptionEqualSign($argv, $key, $expected) - { - $input = new ArgvInput($argv); - $this->assertEquals($expected, $input->getParameterOption($key), '->getParameterOption() returns the expected value'); - } - - public function provideGetParameterOptionValues() - { - return array( - array(array('app/console', 'foo:bar', '-e', 'dev'), '-e', 'dev'), - array(array('app/console', 'foo:bar', '--env=dev'), '--env', 'dev'), - array(array('app/console', 'foo:bar', '-e', 'dev'), array('-e', '--env'), 'dev'), - array(array('app/console', 'foo:bar', '--env=dev'), array('-e', '--env'), 'dev'), - array(array('app/console', 'foo:bar', '--env=dev', '--en=1'), array('--en'), '1'), - array(array('app/console', 'foo:bar', '--env=dev', '', '--en=1'), array('--en'), '1'), - ); - } - - public function testParseSingleDashAsArgument() - { - $input = new ArgvInput(array('cli.php', '-')); - $input->bind(new InputDefinition(array(new InputArgument('file')))); - $this->assertEquals(array('file' => '-'), $input->getArguments(), '->parse() parses single dash as an argument'); - } -} diff --git a/vendor/symfony/console/Tests/Input/ArrayInputTest.php b/vendor/symfony/console/Tests/Input/ArrayInputTest.php deleted file mode 100644 index cc89083c6..000000000 --- a/vendor/symfony/console/Tests/Input/ArrayInputTest.php +++ /dev/null @@ -1,138 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\ArrayInput; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; - -class ArrayInputTest extends \PHPUnit_Framework_TestCase -{ - public function testGetFirstArgument() - { - $input = new ArrayInput(array()); - $this->assertNull($input->getFirstArgument(), '->getFirstArgument() returns null if no argument were passed'); - $input = new ArrayInput(array('name' => 'Fabien')); - $this->assertEquals('Fabien', $input->getFirstArgument(), '->getFirstArgument() returns the first passed argument'); - $input = new ArrayInput(array('--foo' => 'bar', 'name' => 'Fabien')); - $this->assertEquals('Fabien', $input->getFirstArgument(), '->getFirstArgument() returns the first passed argument'); - } - - public function testHasParameterOption() - { - $input = new ArrayInput(array('name' => 'Fabien', '--foo' => 'bar')); - $this->assertTrue($input->hasParameterOption('--foo'), '->hasParameterOption() returns true if an option is present in the passed parameters'); - $this->assertFalse($input->hasParameterOption('--bar'), '->hasParameterOption() returns false if an option is not present in the passed parameters'); - - $input = new ArrayInput(array('--foo')); - $this->assertTrue($input->hasParameterOption('--foo'), '->hasParameterOption() returns true if an option is present in the passed parameters'); - } - - public function testGetParameterOption() - { - $input = new ArrayInput(array('name' => 'Fabien', '--foo' => 'bar')); - $this->assertEquals('bar', $input->getParameterOption('--foo'), '->getParameterOption() returns the option of specified name'); - - $input = new ArrayInput(array('Fabien', '--foo' => 'bar')); - $this->assertEquals('bar', $input->getParameterOption('--foo'), '->getParameterOption() returns the option of specified name'); - } - - public function testParseArguments() - { - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name')))); - - $this->assertEquals(array('name' => 'foo'), $input->getArguments(), '->parse() parses required arguments'); - } - - /** - * @dataProvider provideOptions - */ - public function testParseOptions($input, $options, $expectedOptions, $message) - { - $input = new ArrayInput($input, new InputDefinition($options)); - - $this->assertEquals($expectedOptions, $input->getOptions(), $message); - } - - public function provideOptions() - { - return array( - array( - array('--foo' => 'bar'), - array(new InputOption('foo')), - array('foo' => 'bar'), - '->parse() parses long options', - ), - array( - array('--foo' => 'bar'), - array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, '', 'default')), - array('foo' => 'bar'), - '->parse() parses long options with a default value', - ), - array( - array('--foo' => null), - array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, '', 'default')), - array('foo' => 'default'), - '->parse() parses long options with a default value', - ), - array( - array('-f' => 'bar'), - array(new InputOption('foo', 'f')), - array('foo' => 'bar'), - '->parse() parses short options', - ), - ); - } - - /** - * @dataProvider provideInvalidInput - */ - public function testParseInvalidInput($parameters, $definition, $expectedExceptionMessage) - { - $this->setExpectedException('InvalidArgumentException', $expectedExceptionMessage); - - new ArrayInput($parameters, $definition); - } - - public function provideInvalidInput() - { - return array( - array( - array('foo' => 'foo'), - new InputDefinition(array(new InputArgument('name'))), - 'The "foo" argument does not exist.', - ), - array( - array('--foo' => null), - new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED))), - 'The "--foo" option requires a value.', - ), - array( - array('--foo' => 'foo'), - new InputDefinition(), - 'The "--foo" option does not exist.', - ), - array( - array('-o' => 'foo'), - new InputDefinition(), - 'The "-o" option does not exist.', - ), - ); - } - - public function testToString() - { - $input = new ArrayInput(array('-f' => null, '-b' => 'bar', '--foo' => 'b a z', '--lala' => null, 'test' => 'Foo', 'test2' => "A\nB'C")); - $this->assertEquals('-f -b=bar --foo='.escapeshellarg('b a z').' --lala Foo '.escapeshellarg("A\nB'C"), (string) $input); - } -} diff --git a/vendor/symfony/console/Tests/Input/InputArgumentTest.php b/vendor/symfony/console/Tests/Input/InputArgumentTest.php deleted file mode 100644 index cfb37cd41..000000000 --- a/vendor/symfony/console/Tests/Input/InputArgumentTest.php +++ /dev/null @@ -1,111 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\InputArgument; - -class InputArgumentTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $argument = new InputArgument('foo'); - $this->assertEquals('foo', $argument->getName(), '__construct() takes a name as its first argument'); - } - - public function testModes() - { - $argument = new InputArgument('foo'); - $this->assertFalse($argument->isRequired(), '__construct() gives a "InputArgument::OPTIONAL" mode by default'); - - $argument = new InputArgument('foo', null); - $this->assertFalse($argument->isRequired(), '__construct() can take "InputArgument::OPTIONAL" as its mode'); - - $argument = new InputArgument('foo', InputArgument::OPTIONAL); - $this->assertFalse($argument->isRequired(), '__construct() can take "InputArgument::OPTIONAL" as its mode'); - - $argument = new InputArgument('foo', InputArgument::REQUIRED); - $this->assertTrue($argument->isRequired(), '__construct() can take "InputArgument::REQUIRED" as its mode'); - } - - /** - * @dataProvider provideInvalidModes - */ - public function testInvalidModes($mode) - { - $this->setExpectedException('InvalidArgumentException', sprintf('Argument mode "%s" is not valid.', $mode)); - - new InputArgument('foo', $mode); - } - - public function provideInvalidModes() - { - return array( - array('ANOTHER_ONE'), - array(-1), - ); - } - - public function testIsArray() - { - $argument = new InputArgument('foo', InputArgument::IS_ARRAY); - $this->assertTrue($argument->isArray(), '->isArray() returns true if the argument can be an array'); - $argument = new InputArgument('foo', InputArgument::OPTIONAL | InputArgument::IS_ARRAY); - $this->assertTrue($argument->isArray(), '->isArray() returns true if the argument can be an array'); - $argument = new InputArgument('foo', InputArgument::OPTIONAL); - $this->assertFalse($argument->isArray(), '->isArray() returns false if the argument can not be an array'); - } - - public function testGetDescription() - { - $argument = new InputArgument('foo', null, 'Some description'); - $this->assertEquals('Some description', $argument->getDescription(), '->getDescription() return the message description'); - } - - public function testGetDefault() - { - $argument = new InputArgument('foo', InputArgument::OPTIONAL, '', 'default'); - $this->assertEquals('default', $argument->getDefault(), '->getDefault() return the default value'); - } - - public function testSetDefault() - { - $argument = new InputArgument('foo', InputArgument::OPTIONAL, '', 'default'); - $argument->setDefault(null); - $this->assertNull($argument->getDefault(), '->setDefault() can reset the default value by passing null'); - $argument->setDefault('another'); - $this->assertEquals('another', $argument->getDefault(), '->setDefault() changes the default value'); - - $argument = new InputArgument('foo', InputArgument::OPTIONAL | InputArgument::IS_ARRAY); - $argument->setDefault(array(1, 2)); - $this->assertEquals(array(1, 2), $argument->getDefault(), '->setDefault() changes the default value'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot set a default value except for InputArgument::OPTIONAL mode. - */ - public function testSetDefaultWithRequiredArgument() - { - $argument = new InputArgument('foo', InputArgument::REQUIRED); - $argument->setDefault('default'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage A default value for an array argument must be an array. - */ - public function testSetDefaultWithArrayArgument() - { - $argument = new InputArgument('foo', InputArgument::IS_ARRAY); - $argument->setDefault('default'); - } -} diff --git a/vendor/symfony/console/Tests/Input/InputDefinitionTest.php b/vendor/symfony/console/Tests/Input/InputDefinitionTest.php deleted file mode 100644 index 7e0a24258..000000000 --- a/vendor/symfony/console/Tests/Input/InputDefinitionTest.php +++ /dev/null @@ -1,437 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; - -class InputDefinitionTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixtures; - - protected $foo, $bar, $foo1, $foo2; - - public static function setUpBeforeClass() - { - self::$fixtures = __DIR__.'/../Fixtures/'; - } - - public function testConstructorArguments() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $this->assertEquals(array(), $definition->getArguments(), '__construct() creates a new InputDefinition object'); - - $definition = new InputDefinition(array($this->foo, $this->bar)); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getArguments(), '__construct() takes an array of InputArgument objects as its first argument'); - } - - public function testConstructorOptions() - { - $this->initializeOptions(); - - $definition = new InputDefinition(); - $this->assertEquals(array(), $definition->getOptions(), '__construct() creates a new InputDefinition object'); - - $definition = new InputDefinition(array($this->foo, $this->bar)); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getOptions(), '__construct() takes an array of InputOption objects as its first argument'); - } - - public function testSetArguments() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->setArguments(array($this->foo)); - $this->assertEquals(array('foo' => $this->foo), $definition->getArguments(), '->setArguments() sets the array of InputArgument objects'); - $definition->setArguments(array($this->bar)); - - $this->assertEquals(array('bar' => $this->bar), $definition->getArguments(), '->setArguments() clears all InputArgument objects'); - } - - public function testAddArguments() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArguments(array($this->foo)); - $this->assertEquals(array('foo' => $this->foo), $definition->getArguments(), '->addArguments() adds an array of InputArgument objects'); - $definition->addArguments(array($this->bar)); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getArguments(), '->addArguments() does not clear existing InputArgument objects'); - } - - public function testAddArgument() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument($this->foo); - $this->assertEquals(array('foo' => $this->foo), $definition->getArguments(), '->addArgument() adds a InputArgument object'); - $definition->addArgument($this->bar); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getArguments(), '->addArgument() adds a InputArgument object'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage An argument with name "foo" already exists. - */ - public function testArgumentsMustHaveDifferentNames() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument($this->foo); - $definition->addArgument($this->foo1); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot add an argument after an array argument. - */ - public function testArrayArgumentHasToBeLast() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument(new InputArgument('fooarray', InputArgument::IS_ARRAY)); - $definition->addArgument(new InputArgument('anotherbar')); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot add a required argument after an optional one. - */ - public function testRequiredArgumentCannotFollowAnOptionalOne() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument($this->foo); - $definition->addArgument($this->foo2); - } - - public function testGetArgument() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArguments(array($this->foo)); - $this->assertEquals($this->foo, $definition->getArgument('foo'), '->getArgument() returns a InputArgument by its name'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "bar" argument does not exist. - */ - public function testGetInvalidArgument() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArguments(array($this->foo)); - $definition->getArgument('bar'); - } - - public function testHasArgument() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArguments(array($this->foo)); - - $this->assertTrue($definition->hasArgument('foo'), '->hasArgument() returns true if a InputArgument exists for the given name'); - $this->assertFalse($definition->hasArgument('bar'), '->hasArgument() returns false if a InputArgument exists for the given name'); - } - - public function testGetArgumentRequiredCount() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument($this->foo2); - $this->assertEquals(1, $definition->getArgumentRequiredCount(), '->getArgumentRequiredCount() returns the number of required arguments'); - $definition->addArgument($this->foo); - $this->assertEquals(1, $definition->getArgumentRequiredCount(), '->getArgumentRequiredCount() returns the number of required arguments'); - } - - public function testGetArgumentCount() - { - $this->initializeArguments(); - - $definition = new InputDefinition(); - $definition->addArgument($this->foo2); - $this->assertEquals(1, $definition->getArgumentCount(), '->getArgumentCount() returns the number of arguments'); - $definition->addArgument($this->foo); - $this->assertEquals(2, $definition->getArgumentCount(), '->getArgumentCount() returns the number of arguments'); - } - - public function testGetArgumentDefaults() - { - $definition = new InputDefinition(array( - new InputArgument('foo1', InputArgument::OPTIONAL), - new InputArgument('foo2', InputArgument::OPTIONAL, '', 'default'), - new InputArgument('foo3', InputArgument::OPTIONAL | InputArgument::IS_ARRAY), - // new InputArgument('foo4', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, '', array(1, 2)), - )); - $this->assertEquals(array('foo1' => null, 'foo2' => 'default', 'foo3' => array()), $definition->getArgumentDefaults(), '->getArgumentDefaults() return the default values for each argument'); - - $definition = new InputDefinition(array( - new InputArgument('foo4', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, '', array(1, 2)), - )); - $this->assertEquals(array('foo4' => array(1, 2)), $definition->getArgumentDefaults(), '->getArgumentDefaults() return the default values for each argument'); - } - - public function testSetOptions() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertEquals(array('foo' => $this->foo), $definition->getOptions(), '->setOptions() sets the array of InputOption objects'); - $definition->setOptions(array($this->bar)); - $this->assertEquals(array('bar' => $this->bar), $definition->getOptions(), '->setOptions() clears all InputOption objects'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "-f" option does not exist. - */ - public function testSetOptionsClearsOptions() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $definition->setOptions(array($this->bar)); - $definition->getOptionForShortcut('f'); - } - - public function testAddOptions() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertEquals(array('foo' => $this->foo), $definition->getOptions(), '->addOptions() adds an array of InputOption objects'); - $definition->addOptions(array($this->bar)); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getOptions(), '->addOptions() does not clear existing InputOption objects'); - } - - public function testAddOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(); - $definition->addOption($this->foo); - $this->assertEquals(array('foo' => $this->foo), $definition->getOptions(), '->addOption() adds a InputOption object'); - $definition->addOption($this->bar); - $this->assertEquals(array('foo' => $this->foo, 'bar' => $this->bar), $definition->getOptions(), '->addOption() adds a InputOption object'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage An option named "foo" already exists. - */ - public function testAddDuplicateOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(); - $definition->addOption($this->foo); - $definition->addOption($this->foo2); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage An option with shortcut "f" already exists. - */ - public function testAddDuplicateShortcutOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(); - $definition->addOption($this->foo); - $definition->addOption($this->foo1); - } - - public function testGetOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertEquals($this->foo, $definition->getOption('foo'), '->getOption() returns a InputOption by its name'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "--bar" option does not exist. - */ - public function testGetInvalidOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $definition->getOption('bar'); - } - - public function testHasOption() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertTrue($definition->hasOption('foo'), '->hasOption() returns true if a InputOption exists for the given name'); - $this->assertFalse($definition->hasOption('bar'), '->hasOption() returns false if a InputOption exists for the given name'); - } - - public function testHasShortcut() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertTrue($definition->hasShortcut('f'), '->hasShortcut() returns true if a InputOption exists for the given shortcut'); - $this->assertFalse($definition->hasShortcut('b'), '->hasShortcut() returns false if a InputOption exists for the given shortcut'); - } - - public function testGetOptionForShortcut() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $this->assertEquals($this->foo, $definition->getOptionForShortcut('f'), '->getOptionForShortcut() returns a InputOption by its shortcut'); - } - - public function testGetOptionForMultiShortcut() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->multi)); - $this->assertEquals($this->multi, $definition->getOptionForShortcut('m'), '->getOptionForShortcut() returns a InputOption by its shortcut'); - $this->assertEquals($this->multi, $definition->getOptionForShortcut('mmm'), '->getOptionForShortcut() returns a InputOption by its shortcut'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "-l" option does not exist. - */ - public function testGetOptionForInvalidShortcut() - { - $this->initializeOptions(); - - $definition = new InputDefinition(array($this->foo)); - $definition->getOptionForShortcut('l'); - } - - public function testGetOptionDefaults() - { - $definition = new InputDefinition(array( - new InputOption('foo1', null, InputOption::VALUE_NONE), - new InputOption('foo2', null, InputOption::VALUE_REQUIRED), - new InputOption('foo3', null, InputOption::VALUE_REQUIRED, '', 'default'), - new InputOption('foo4', null, InputOption::VALUE_OPTIONAL), - new InputOption('foo5', null, InputOption::VALUE_OPTIONAL, '', 'default'), - new InputOption('foo6', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY), - new InputOption('foo7', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, '', array(1, 2)), - )); - $defaults = array( - 'foo1' => false, - 'foo2' => null, - 'foo3' => 'default', - 'foo4' => null, - 'foo5' => 'default', - 'foo6' => array(), - 'foo7' => array(1, 2), - ); - $this->assertSame($defaults, $definition->getOptionDefaults(), '->getOptionDefaults() returns the default values for all options'); - } - - /** - * @dataProvider getGetSynopsisData - */ - public function testGetSynopsis(InputDefinition $definition, $expectedSynopsis, $message = null) - { - $this->assertEquals($expectedSynopsis, $definition->getSynopsis(), $message ? '->getSynopsis() '.$message : ''); - } - - public function getGetSynopsisData() - { - return array( - array(new InputDefinition(array(new InputOption('foo'))), '[--foo]', 'puts optional options in square brackets'), - array(new InputDefinition(array(new InputOption('foo', 'f'))), '[-f|--foo]', 'separates shortcut with a pipe'), - array(new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_REQUIRED))), '[-f|--foo FOO]', 'uses shortcut as value placeholder'), - array(new InputDefinition(array(new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL))), '[-f|--foo [FOO]]', 'puts optional values in square brackets'), - - array(new InputDefinition(array(new InputArgument('foo', InputArgument::REQUIRED))), '', 'puts arguments in angle brackets'), - array(new InputDefinition(array(new InputArgument('foo'))), '[]', 'puts optional arguments in square brackets'), - array(new InputDefinition(array(new InputArgument('foo', InputArgument::IS_ARRAY))), '[]...', 'uses an ellipsis for array arguments'), - array(new InputDefinition(array(new InputArgument('foo', InputArgument::REQUIRED | InputArgument::IS_ARRAY))), ' ()...', 'uses parenthesis and ellipsis for required array arguments'), - - array(new InputDefinition(array(new InputOption('foo'), new InputArgument('foo', InputArgument::REQUIRED))), '[--foo] [--] ', 'puts [--] between options and arguments'), - ); - } - - public function testGetShortSynopsis() - { - $definition = new InputDefinition(array(new InputOption('foo'), new InputOption('bar'), new InputArgument('cat'))); - $this->assertEquals('[options] [--] []', $definition->getSynopsis(true), '->getSynopsis(true) groups options in [options]'); - } - - /** - * @group legacy - */ - public function testLegacyAsText() - { - $definition = new InputDefinition(array( - new InputArgument('foo', InputArgument::OPTIONAL, 'The foo argument'), - new InputArgument('baz', InputArgument::OPTIONAL, 'The baz argument', true), - new InputArgument('bar', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, 'The bar argument', array('http://foo.com/')), - new InputOption('foo', 'f', InputOption::VALUE_REQUIRED, 'The foo option'), - new InputOption('baz', null, InputOption::VALUE_OPTIONAL, 'The baz option', false), - new InputOption('bar', 'b', InputOption::VALUE_OPTIONAL, 'The bar option', 'bar'), - new InputOption('qux', '', InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, 'The qux option', array('http://foo.com/', 'bar')), - new InputOption('qux2', '', InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, 'The qux2 option', array('foo' => 'bar')), - )); - - $this->assertStringEqualsFile(self::$fixtures.'/definition_astext.txt', $definition->asText(), '->asText() returns a textual representation of the InputDefinition'); - } - - /** - * @group legacy - */ - public function testLegacyAsXml() - { - $definition = new InputDefinition(array( - new InputArgument('foo', InputArgument::OPTIONAL, 'The foo argument'), - new InputArgument('baz', InputArgument::OPTIONAL, 'The baz argument', true), - new InputArgument('bar', InputArgument::OPTIONAL | InputArgument::IS_ARRAY, 'The bar argument', array('bar')), - new InputOption('foo', 'f', InputOption::VALUE_REQUIRED, 'The foo option'), - new InputOption('baz', null, InputOption::VALUE_OPTIONAL, 'The baz option', false), - new InputOption('bar', 'b', InputOption::VALUE_OPTIONAL, 'The bar option', 'bar'), - )); - $this->assertXmlStringEqualsXmlFile(self::$fixtures.'/definition_asxml.txt', $definition->asXml(), '->asXml() returns an XML representation of the InputDefinition'); - } - - protected function initializeArguments() - { - $this->foo = new InputArgument('foo'); - $this->bar = new InputArgument('bar'); - $this->foo1 = new InputArgument('foo'); - $this->foo2 = new InputArgument('foo2', InputArgument::REQUIRED); - } - - protected function initializeOptions() - { - $this->foo = new InputOption('foo', 'f'); - $this->bar = new InputOption('bar', 'b'); - $this->foo1 = new InputOption('fooBis', 'f'); - $this->foo2 = new InputOption('foo', 'p'); - $this->multi = new InputOption('multi', 'm|mm|mmm'); - } -} diff --git a/vendor/symfony/console/Tests/Input/InputOptionTest.php b/vendor/symfony/console/Tests/Input/InputOptionTest.php deleted file mode 100644 index 53ce1df8c..000000000 --- a/vendor/symfony/console/Tests/Input/InputOptionTest.php +++ /dev/null @@ -1,204 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\InputOption; - -class InputOptionTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $option = new InputOption('foo'); - $this->assertEquals('foo', $option->getName(), '__construct() takes a name as its first argument'); - $option = new InputOption('--foo'); - $this->assertEquals('foo', $option->getName(), '__construct() removes the leading -- of the option name'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Impossible to have an option mode VALUE_IS_ARRAY if the option does not accept a value. - */ - public function testArrayModeWithoutValue() - { - new InputOption('foo', 'f', InputOption::VALUE_IS_ARRAY); - } - - public function testShortcut() - { - $option = new InputOption('foo', 'f'); - $this->assertEquals('f', $option->getShortcut(), '__construct() can take a shortcut as its second argument'); - $option = new InputOption('foo', '-f|-ff|fff'); - $this->assertEquals('f|ff|fff', $option->getShortcut(), '__construct() removes the leading - of the shortcuts'); - $option = new InputOption('foo', array('f', 'ff', '-fff')); - $this->assertEquals('f|ff|fff', $option->getShortcut(), '__construct() removes the leading - of the shortcuts'); - $option = new InputOption('foo'); - $this->assertNull($option->getShortcut(), '__construct() makes the shortcut null by default'); - } - - public function testModes() - { - $option = new InputOption('foo', 'f'); - $this->assertFalse($option->acceptValue(), '__construct() gives a "InputOption::VALUE_NONE" mode by default'); - $this->assertFalse($option->isValueRequired(), '__construct() gives a "InputOption::VALUE_NONE" mode by default'); - $this->assertFalse($option->isValueOptional(), '__construct() gives a "InputOption::VALUE_NONE" mode by default'); - - $option = new InputOption('foo', 'f', null); - $this->assertFalse($option->acceptValue(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - $this->assertFalse($option->isValueRequired(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - $this->assertFalse($option->isValueOptional(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - - $option = new InputOption('foo', 'f', InputOption::VALUE_NONE); - $this->assertFalse($option->acceptValue(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - $this->assertFalse($option->isValueRequired(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - $this->assertFalse($option->isValueOptional(), '__construct() can take "InputOption::VALUE_NONE" as its mode'); - - $option = new InputOption('foo', 'f', InputOption::VALUE_REQUIRED); - $this->assertTrue($option->acceptValue(), '__construct() can take "InputOption::VALUE_REQUIRED" as its mode'); - $this->assertTrue($option->isValueRequired(), '__construct() can take "InputOption::VALUE_REQUIRED" as its mode'); - $this->assertFalse($option->isValueOptional(), '__construct() can take "InputOption::VALUE_REQUIRED" as its mode'); - - $option = new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL); - $this->assertTrue($option->acceptValue(), '__construct() can take "InputOption::VALUE_OPTIONAL" as its mode'); - $this->assertFalse($option->isValueRequired(), '__construct() can take "InputOption::VALUE_OPTIONAL" as its mode'); - $this->assertTrue($option->isValueOptional(), '__construct() can take "InputOption::VALUE_OPTIONAL" as its mode'); - } - - /** - * @dataProvider provideInvalidModes - */ - public function testInvalidModes($mode) - { - $this->setExpectedException('InvalidArgumentException', sprintf('Option mode "%s" is not valid.', $mode)); - - new InputOption('foo', 'f', $mode); - } - - public function provideInvalidModes() - { - return array( - array('ANOTHER_ONE'), - array(-1), - ); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEmptyNameIsInvalid() - { - new InputOption(''); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testDoubleDashNameIsInvalid() - { - new InputOption('--'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testSingleDashOptionIsInvalid() - { - new InputOption('foo', '-'); - } - - public function testIsArray() - { - $option = new InputOption('foo', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY); - $this->assertTrue($option->isArray(), '->isArray() returns true if the option can be an array'); - $option = new InputOption('foo', null, InputOption::VALUE_NONE); - $this->assertFalse($option->isArray(), '->isArray() returns false if the option can not be an array'); - } - - public function testGetDescription() - { - $option = new InputOption('foo', 'f', null, 'Some description'); - $this->assertEquals('Some description', $option->getDescription(), '->getDescription() returns the description message'); - } - - public function testGetDefault() - { - $option = new InputOption('foo', null, InputOption::VALUE_OPTIONAL, '', 'default'); - $this->assertEquals('default', $option->getDefault(), '->getDefault() returns the default value'); - - $option = new InputOption('foo', null, InputOption::VALUE_REQUIRED, '', 'default'); - $this->assertEquals('default', $option->getDefault(), '->getDefault() returns the default value'); - - $option = new InputOption('foo', null, InputOption::VALUE_REQUIRED); - $this->assertNull($option->getDefault(), '->getDefault() returns null if no default value is configured'); - - $option = new InputOption('foo', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY); - $this->assertEquals(array(), $option->getDefault(), '->getDefault() returns an empty array if option is an array'); - - $option = new InputOption('foo', null, InputOption::VALUE_NONE); - $this->assertFalse($option->getDefault(), '->getDefault() returns false if the option does not take a value'); - } - - public function testSetDefault() - { - $option = new InputOption('foo', null, InputOption::VALUE_REQUIRED, '', 'default'); - $option->setDefault(null); - $this->assertNull($option->getDefault(), '->setDefault() can reset the default value by passing null'); - $option->setDefault('another'); - $this->assertEquals('another', $option->getDefault(), '->setDefault() changes the default value'); - - $option = new InputOption('foo', null, InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY); - $option->setDefault(array(1, 2)); - $this->assertEquals(array(1, 2), $option->getDefault(), '->setDefault() changes the default value'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage Cannot set a default value when using InputOption::VALUE_NONE mode. - */ - public function testDefaultValueWithValueNoneMode() - { - $option = new InputOption('foo', 'f', InputOption::VALUE_NONE); - $option->setDefault('default'); - } - - /** - * @expectedException \LogicException - * @expectedExceptionMessage A default value for an array option must be an array. - */ - public function testDefaultValueWithIsArrayMode() - { - $option = new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY); - $option->setDefault('default'); - } - - public function testEquals() - { - $option = new InputOption('foo', 'f', null, 'Some description'); - $option2 = new InputOption('foo', 'f', null, 'Alternative description'); - $this->assertTrue($option->equals($option2)); - - $option = new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, 'Some description'); - $option2 = new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, 'Some description', true); - $this->assertFalse($option->equals($option2)); - - $option = new InputOption('foo', 'f', null, 'Some description'); - $option2 = new InputOption('bar', 'f', null, 'Some description'); - $this->assertFalse($option->equals($option2)); - - $option = new InputOption('foo', 'f', null, 'Some description'); - $option2 = new InputOption('foo', '', null, 'Some description'); - $this->assertFalse($option->equals($option2)); - - $option = new InputOption('foo', 'f', null, 'Some description'); - $option2 = new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, 'Some description'); - $this->assertFalse($option->equals($option2)); - } -} diff --git a/vendor/symfony/console/Tests/Input/InputTest.php b/vendor/symfony/console/Tests/Input/InputTest.php deleted file mode 100644 index 0b3e38fb6..000000000 --- a/vendor/symfony/console/Tests/Input/InputTest.php +++ /dev/null @@ -1,121 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\ArrayInput; -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputArgument; -use Symfony\Component\Console\Input\InputOption; - -class InputTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name')))); - $this->assertEquals('foo', $input->getArgument('name'), '->__construct() takes a InputDefinition as an argument'); - } - - public function testOptions() - { - $input = new ArrayInput(array('--name' => 'foo'), new InputDefinition(array(new InputOption('name')))); - $this->assertEquals('foo', $input->getOption('name'), '->getOption() returns the value for the given option'); - - $input->setOption('name', 'bar'); - $this->assertEquals('bar', $input->getOption('name'), '->setOption() sets the value for a given option'); - $this->assertEquals(array('name' => 'bar'), $input->getOptions(), '->getOptions() returns all option values'); - - $input = new ArrayInput(array('--name' => 'foo'), new InputDefinition(array(new InputOption('name'), new InputOption('bar', '', InputOption::VALUE_OPTIONAL, '', 'default')))); - $this->assertEquals('default', $input->getOption('bar'), '->getOption() returns the default value for optional options'); - $this->assertEquals(array('name' => 'foo', 'bar' => 'default'), $input->getOptions(), '->getOptions() returns all option values, even optional ones'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "foo" option does not exist. - */ - public function testSetInvalidOption() - { - $input = new ArrayInput(array('--name' => 'foo'), new InputDefinition(array(new InputOption('name'), new InputOption('bar', '', InputOption::VALUE_OPTIONAL, '', 'default')))); - $input->setOption('foo', 'bar'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "foo" option does not exist. - */ - public function testGetInvalidOption() - { - $input = new ArrayInput(array('--name' => 'foo'), new InputDefinition(array(new InputOption('name'), new InputOption('bar', '', InputOption::VALUE_OPTIONAL, '', 'default')))); - $input->getOption('foo'); - } - - public function testArguments() - { - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name')))); - $this->assertEquals('foo', $input->getArgument('name'), '->getArgument() returns the value for the given argument'); - - $input->setArgument('name', 'bar'); - $this->assertEquals('bar', $input->getArgument('name'), '->setArgument() sets the value for a given argument'); - $this->assertEquals(array('name' => 'bar'), $input->getArguments(), '->getArguments() returns all argument values'); - - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name'), new InputArgument('bar', InputArgument::OPTIONAL, '', 'default')))); - $this->assertEquals('default', $input->getArgument('bar'), '->getArgument() returns the default value for optional arguments'); - $this->assertEquals(array('name' => 'foo', 'bar' => 'default'), $input->getArguments(), '->getArguments() returns all argument values, even optional ones'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "foo" argument does not exist. - */ - public function testSetInvalidArgument() - { - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name'), new InputArgument('bar', InputArgument::OPTIONAL, '', 'default')))); - $input->setArgument('foo', 'bar'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "foo" argument does not exist. - */ - public function testGetInvalidArgument() - { - $input = new ArrayInput(array('name' => 'foo'), new InputDefinition(array(new InputArgument('name'), new InputArgument('bar', InputArgument::OPTIONAL, '', 'default')))); - $input->getArgument('foo'); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Not enough arguments. - */ - public function testValidateWithMissingArguments() - { - $input = new ArrayInput(array()); - $input->bind(new InputDefinition(array(new InputArgument('name', InputArgument::REQUIRED)))); - $input->validate(); - } - - public function testValidate() - { - $input = new ArrayInput(array('name' => 'foo')); - $input->bind(new InputDefinition(array(new InputArgument('name', InputArgument::REQUIRED)))); - - $this->assertNull($input->validate()); - } - - public function testSetGetInteractive() - { - $input = new ArrayInput(array()); - $this->assertTrue($input->isInteractive(), '->isInteractive() returns whether the input should be interactive or not'); - $input->setInteractive(false); - $this->assertFalse($input->isInteractive(), '->setInteractive() changes the interactive flag'); - } -} diff --git a/vendor/symfony/console/Tests/Input/StringInputTest.php b/vendor/symfony/console/Tests/Input/StringInputTest.php deleted file mode 100644 index ccf9289cf..000000000 --- a/vendor/symfony/console/Tests/Input/StringInputTest.php +++ /dev/null @@ -1,99 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Input; - -use Symfony\Component\Console\Input\InputDefinition; -use Symfony\Component\Console\Input\InputOption; -use Symfony\Component\Console\Input\StringInput; - -class StringInputTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider getTokenizeData - */ - public function testTokenize($input, $tokens, $message) - { - $input = new StringInput($input); - $r = new \ReflectionClass('Symfony\Component\Console\Input\ArgvInput'); - $p = $r->getProperty('tokens'); - $p->setAccessible(true); - $this->assertEquals($tokens, $p->getValue($input), $message); - } - - public function testInputOptionWithGivenString() - { - $definition = new InputDefinition( - array(new InputOption('foo', null, InputOption::VALUE_REQUIRED)) - ); - - // call to bind - $input = new StringInput('--foo=bar'); - $input->bind($definition); - $this->assertEquals('bar', $input->getOption('foo')); - } - - /** - * @group legacy - */ - public function testLegacyInputOptionDefinitionInConstructor() - { - $definition = new InputDefinition( - array(new InputOption('foo', null, InputOption::VALUE_REQUIRED)) - ); - - $input = new StringInput('--foo=bar', $definition); - $this->assertEquals('bar', $input->getOption('foo')); - } - - public function getTokenizeData() - { - return array( - array('', array(), '->tokenize() parses an empty string'), - array('foo', array('foo'), '->tokenize() parses arguments'), - array(' foo bar ', array('foo', 'bar'), '->tokenize() ignores whitespaces between arguments'), - array('"quoted"', array('quoted'), '->tokenize() parses quoted arguments'), - array("'quoted'", array('quoted'), '->tokenize() parses quoted arguments'), - array("'a\rb\nc\td'", array("a\rb\nc\td"), '->tokenize() parses whitespace chars in strings'), - array("'a'\r'b'\n'c'\t'd'", array('a','b','c','d'), '->tokenize() parses whitespace chars between args as spaces'), - array('\"quoted\"', array('"quoted"'), '->tokenize() parses escaped-quoted arguments'), - array("\'quoted\'", array('\'quoted\''), '->tokenize() parses escaped-quoted arguments'), - array('-a', array('-a'), '->tokenize() parses short options'), - array('-azc', array('-azc'), '->tokenize() parses aggregated short options'), - array('-awithavalue', array('-awithavalue'), '->tokenize() parses short options with a value'), - array('-a"foo bar"', array('-afoo bar'), '->tokenize() parses short options with a value'), - array('-a"foo bar""foo bar"', array('-afoo barfoo bar'), '->tokenize() parses short options with a value'), - array('-a\'foo bar\'', array('-afoo bar'), '->tokenize() parses short options with a value'), - array('-a\'foo bar\'\'foo bar\'', array('-afoo barfoo bar'), '->tokenize() parses short options with a value'), - array('-a\'foo bar\'"foo bar"', array('-afoo barfoo bar'), '->tokenize() parses short options with a value'), - array('--long-option', array('--long-option'), '->tokenize() parses long options'), - array('--long-option=foo', array('--long-option=foo'), '->tokenize() parses long options with a value'), - array('--long-option="foo bar"', array('--long-option=foo bar'), '->tokenize() parses long options with a value'), - array('--long-option="foo bar""another"', array('--long-option=foo baranother'), '->tokenize() parses long options with a value'), - array('--long-option=\'foo bar\'', array('--long-option=foo bar'), '->tokenize() parses long options with a value'), - array("--long-option='foo bar''another'", array('--long-option=foo baranother'), '->tokenize() parses long options with a value'), - array("--long-option='foo bar'\"another\"", array('--long-option=foo baranother'), '->tokenize() parses long options with a value'), - array('foo -a -ffoo --long bar', array('foo', '-a', '-ffoo', '--long', 'bar'), '->tokenize() parses when several arguments and options'), - ); - } - - public function testToString() - { - $input = new StringInput('-f foo'); - $this->assertEquals('-f foo', (string) $input); - - $input = new StringInput('-f --bar=foo "a b c d"'); - $this->assertEquals('-f --bar=foo '.escapeshellarg('a b c d'), (string) $input); - - $input = new StringInput('-f --bar=foo \'a b c d\' '."'A\nB\\'C'"); - $this->assertEquals('-f --bar=foo '.escapeshellarg('a b c d').' '.escapeshellarg("A\nB'C"), (string) $input); - } -} diff --git a/vendor/symfony/console/Tests/Logger/ConsoleLoggerTest.php b/vendor/symfony/console/Tests/Logger/ConsoleLoggerTest.php deleted file mode 100644 index c5eca2caf..000000000 --- a/vendor/symfony/console/Tests/Logger/ConsoleLoggerTest.php +++ /dev/null @@ -1,58 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Logger; - -use Psr\Log\Test\LoggerInterfaceTest; -use Psr\Log\LogLevel; -use Symfony\Component\Console\Logger\ConsoleLogger; -use Symfony\Component\Console\Tests\Fixtures\DummyOutput; -use Symfony\Component\Console\Output\OutputInterface; - -/** - * Console logger test. - * - * @author Kévin Dunglas - */ -class ConsoleLoggerTest extends LoggerInterfaceTest -{ - /** - * @var DummyOutput - */ - protected $output; - - /** - * {@inheritdoc} - */ - public function getLogger() - { - $this->output = new DummyOutput(OutputInterface::VERBOSITY_VERBOSE); - - return new ConsoleLogger($this->output, array( - LogLevel::EMERGENCY => OutputInterface::VERBOSITY_NORMAL, - LogLevel::ALERT => OutputInterface::VERBOSITY_NORMAL, - LogLevel::CRITICAL => OutputInterface::VERBOSITY_NORMAL, - LogLevel::ERROR => OutputInterface::VERBOSITY_NORMAL, - LogLevel::WARNING => OutputInterface::VERBOSITY_NORMAL, - LogLevel::NOTICE => OutputInterface::VERBOSITY_NORMAL, - LogLevel::INFO => OutputInterface::VERBOSITY_NORMAL, - LogLevel::DEBUG => OutputInterface::VERBOSITY_NORMAL, - )); - } - - /** - * {@inheritdoc} - */ - public function getLogs() - { - return $this->output->getLogs(); - } -} diff --git a/vendor/symfony/console/Tests/Output/ConsoleOutputTest.php b/vendor/symfony/console/Tests/Output/ConsoleOutputTest.php deleted file mode 100644 index 1afbbb6e6..000000000 --- a/vendor/symfony/console/Tests/Output/ConsoleOutputTest.php +++ /dev/null @@ -1,25 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Output; - -use Symfony\Component\Console\Output\ConsoleOutput; -use Symfony\Component\Console\Output\Output; - -class ConsoleOutputTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $output = new ConsoleOutput(Output::VERBOSITY_QUIET, true); - $this->assertEquals(Output::VERBOSITY_QUIET, $output->getVerbosity(), '__construct() takes the verbosity as its first argument'); - $this->assertSame($output->getFormatter(), $output->getErrorOutput()->getFormatter(), '__construct() takes a formatter or null as the third argument'); - } -} diff --git a/vendor/symfony/console/Tests/Output/NullOutputTest.php b/vendor/symfony/console/Tests/Output/NullOutputTest.php deleted file mode 100644 index b20ae4e8d..000000000 --- a/vendor/symfony/console/Tests/Output/NullOutputTest.php +++ /dev/null @@ -1,39 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Output; - -use Symfony\Component\Console\Output\NullOutput; -use Symfony\Component\Console\Output\OutputInterface; - -class NullOutputTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $output = new NullOutput(); - - ob_start(); - $output->write('foo'); - $buffer = ob_get_clean(); - - $this->assertSame('', $buffer, '->write() does nothing (at least nothing is printed)'); - $this->assertFalse($output->isDecorated(), '->isDecorated() returns false'); - } - - public function testVerbosity() - { - $output = new NullOutput(); - $this->assertSame(OutputInterface::VERBOSITY_QUIET, $output->getVerbosity(), '->getVerbosity() returns VERBOSITY_QUIET for NullOutput by default'); - - $output->setVerbosity(OutputInterface::VERBOSITY_VERBOSE); - $this->assertSame(OutputInterface::VERBOSITY_QUIET, $output->getVerbosity(), '->getVerbosity() always returns VERBOSITY_QUIET for NullOutput'); - } -} diff --git a/vendor/symfony/console/Tests/Output/OutputTest.php b/vendor/symfony/console/Tests/Output/OutputTest.php deleted file mode 100644 index cfb4afe15..000000000 --- a/vendor/symfony/console/Tests/Output/OutputTest.php +++ /dev/null @@ -1,156 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Output; - -use Symfony\Component\Console\Output\Output; -use Symfony\Component\Console\Formatter\OutputFormatterStyle; - -class OutputTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $output = new TestOutput(Output::VERBOSITY_QUIET, true); - $this->assertEquals(Output::VERBOSITY_QUIET, $output->getVerbosity(), '__construct() takes the verbosity as its first argument'); - $this->assertTrue($output->isDecorated(), '__construct() takes the decorated flag as its second argument'); - } - - public function testSetIsDecorated() - { - $output = new TestOutput(); - $output->setDecorated(true); - $this->assertTrue($output->isDecorated(), 'setDecorated() sets the decorated flag'); - } - - public function testSetGetVerbosity() - { - $output = new TestOutput(); - $output->setVerbosity(Output::VERBOSITY_QUIET); - $this->assertEquals(Output::VERBOSITY_QUIET, $output->getVerbosity(), '->setVerbosity() sets the verbosity'); - - $this->assertTrue($output->isQuiet()); - $this->assertFalse($output->isVerbose()); - $this->assertFalse($output->isVeryVerbose()); - $this->assertFalse($output->isDebug()); - - $output->setVerbosity(Output::VERBOSITY_NORMAL); - $this->assertFalse($output->isQuiet()); - $this->assertFalse($output->isVerbose()); - $this->assertFalse($output->isVeryVerbose()); - $this->assertFalse($output->isDebug()); - - $output->setVerbosity(Output::VERBOSITY_VERBOSE); - $this->assertFalse($output->isQuiet()); - $this->assertTrue($output->isVerbose()); - $this->assertFalse($output->isVeryVerbose()); - $this->assertFalse($output->isDebug()); - - $output->setVerbosity(Output::VERBOSITY_VERY_VERBOSE); - $this->assertFalse($output->isQuiet()); - $this->assertTrue($output->isVerbose()); - $this->assertTrue($output->isVeryVerbose()); - $this->assertFalse($output->isDebug()); - - $output->setVerbosity(Output::VERBOSITY_DEBUG); - $this->assertFalse($output->isQuiet()); - $this->assertTrue($output->isVerbose()); - $this->assertTrue($output->isVeryVerbose()); - $this->assertTrue($output->isDebug()); - } - - public function testWriteWithVerbosityQuiet() - { - $output = new TestOutput(Output::VERBOSITY_QUIET); - $output->writeln('foo'); - $this->assertEquals('', $output->output, '->writeln() outputs nothing if verbosity is set to VERBOSITY_QUIET'); - } - - public function testWriteAnArrayOfMessages() - { - $output = new TestOutput(); - $output->writeln(array('foo', 'bar')); - $this->assertEquals("foo\nbar\n", $output->output, '->writeln() can take an array of messages to output'); - } - - /** - * @dataProvider provideWriteArguments - */ - public function testWriteRawMessage($message, $type, $expectedOutput) - { - $output = new TestOutput(); - $output->writeln($message, $type); - $this->assertEquals($expectedOutput, $output->output); - } - - public function provideWriteArguments() - { - return array( - array('foo', Output::OUTPUT_RAW, "foo\n"), - array('foo', Output::OUTPUT_PLAIN, "foo\n"), - ); - } - - public function testWriteWithDecorationTurnedOff() - { - $output = new TestOutput(); - $output->setDecorated(false); - $output->writeln('foo'); - $this->assertEquals("foo\n", $output->output, '->writeln() strips decoration tags if decoration is set to false'); - } - - public function testWriteDecoratedMessage() - { - $fooStyle = new OutputFormatterStyle('yellow', 'red', array('blink')); - $output = new TestOutput(); - $output->getFormatter()->setStyle('FOO', $fooStyle); - $output->setDecorated(true); - $output->writeln('foo'); - $this->assertEquals("\033[33;41;5mfoo\033[39;49;25m\n", $output->output, '->writeln() decorates the output'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Unknown output type given (24) - */ - public function testWriteWithInvalidOutputType() - { - $output = new TestOutput(); - $output->writeln('foo', 24); - } - - public function testWriteWithInvalidStyle() - { - $output = new TestOutput(); - - $output->clear(); - $output->write('foo'); - $this->assertEquals('foo', $output->output, '->write() do nothing when a style does not exist'); - - $output->clear(); - $output->writeln('foo'); - $this->assertEquals("foo\n", $output->output, '->writeln() do nothing when a style does not exist'); - } -} - -class TestOutput extends Output -{ - public $output = ''; - - public function clear() - { - $this->output = ''; - } - - protected function doWrite($message, $newline) - { - $this->output .= $message.($newline ? "\n" : ''); - } -} diff --git a/vendor/symfony/console/Tests/Output/StreamOutputTest.php b/vendor/symfony/console/Tests/Output/StreamOutputTest.php deleted file mode 100644 index 2fd4f6121..000000000 --- a/vendor/symfony/console/Tests/Output/StreamOutputTest.php +++ /dev/null @@ -1,60 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Output; - -use Symfony\Component\Console\Output\Output; -use Symfony\Component\Console\Output\StreamOutput; - -class StreamOutputTest extends \PHPUnit_Framework_TestCase -{ - protected $stream; - - protected function setUp() - { - $this->stream = fopen('php://memory', 'a', false); - } - - protected function tearDown() - { - $this->stream = null; - } - - public function testConstructor() - { - $output = new StreamOutput($this->stream, Output::VERBOSITY_QUIET, true); - $this->assertEquals(Output::VERBOSITY_QUIET, $output->getVerbosity(), '__construct() takes the verbosity as its first argument'); - $this->assertTrue($output->isDecorated(), '__construct() takes the decorated flag as its second argument'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The StreamOutput class needs a stream as its first argument. - */ - public function testStreamIsRequired() - { - new StreamOutput('foo'); - } - - public function testGetStream() - { - $output = new StreamOutput($this->stream); - $this->assertEquals($this->stream, $output->getStream(), '->getStream() returns the current stream'); - } - - public function testDoWrite() - { - $output = new StreamOutput($this->stream); - $output->writeln('foo'); - rewind($output->getStream()); - $this->assertEquals('foo'.PHP_EOL, stream_get_contents($output->getStream()), '->doWrite() writes to the stream'); - } -} diff --git a/vendor/symfony/console/Tests/Style/SymfonyStyleTest.php b/vendor/symfony/console/Tests/Style/SymfonyStyleTest.php deleted file mode 100644 index 2df4f40e4..000000000 --- a/vendor/symfony/console/Tests/Style/SymfonyStyleTest.php +++ /dev/null @@ -1,64 +0,0 @@ -command = new Command('sfstyle'); - $this->tester = new CommandTester($this->command); - } - - protected function tearDown() - { - $this->command = null; - $this->tester = null; - } - - /** - * @dataProvider inputCommandToOutputFilesProvider - */ - public function testOutputs($inputCommandFilepath, $outputFilepath) - { - $code = require $inputCommandFilepath; - $this->command->setCode($code); - $this->tester->execute(array(), array('interactive' => false, 'decorated' => false)); - $this->assertStringEqualsFile($outputFilepath, $this->tester->getDisplay(true)); - } - - public function inputCommandToOutputFilesProvider() - { - $baseDir = __DIR__.'/../Fixtures/Style/SymfonyStyle'; - - return array_map(null, glob($baseDir.'/command/command_*.php'), glob($baseDir.'/output/output_*.txt')); - } - - public function testLongWordsBlockWrapping() - { - $word = 'Lopadotemachoselachogaleokranioleipsanodrimhypotrimmatosilphioparaomelitokatakechymenokichlepikossyphophattoperisteralektryonoptekephalliokigklopeleiolagoiosiraiobaphetraganopterygon'; - $wordLength = strlen($word); - $maxLineLength = SymfonyStyle::MAX_LINE_LENGTH - 3; - - $this->command->setCode(function (InputInterface $input, OutputInterface $output) use ($word) { - $sfStyle = new SymfonyStyle($input, $output); - $sfStyle->block($word, 'CUSTOM', 'fg=white;bg=blue', ' § ', false); - }); - - $this->tester->execute(array(), array('interactive' => false, 'decorated' => false)); - $expectedCount = (int) ceil($wordLength / ($maxLineLength)) + (int) ($wordLength > $maxLineLength - 5); - $this->assertSame($expectedCount, substr_count($this->tester->getDisplay(true), ' § ')); - } -} diff --git a/vendor/symfony/console/Tests/Tester/ApplicationTesterTest.php b/vendor/symfony/console/Tests/Tester/ApplicationTesterTest.php deleted file mode 100644 index a8389dd18..000000000 --- a/vendor/symfony/console/Tests/Tester/ApplicationTesterTest.php +++ /dev/null @@ -1,69 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Tester; - -use Symfony\Component\Console\Application; -use Symfony\Component\Console\Output\Output; -use Symfony\Component\Console\Tester\ApplicationTester; - -class ApplicationTesterTest extends \PHPUnit_Framework_TestCase -{ - protected $application; - protected $tester; - - protected function setUp() - { - $this->application = new Application(); - $this->application->setAutoExit(false); - $this->application->register('foo') - ->addArgument('foo') - ->setCode(function ($input, $output) { $output->writeln('foo'); }) - ; - - $this->tester = new ApplicationTester($this->application); - $this->tester->run(array('command' => 'foo', 'foo' => 'bar'), array('interactive' => false, 'decorated' => false, 'verbosity' => Output::VERBOSITY_VERBOSE)); - } - - protected function tearDown() - { - $this->application = null; - $this->tester = null; - } - - public function testRun() - { - $this->assertFalse($this->tester->getInput()->isInteractive(), '->execute() takes an interactive option'); - $this->assertFalse($this->tester->getOutput()->isDecorated(), '->execute() takes a decorated option'); - $this->assertEquals(Output::VERBOSITY_VERBOSE, $this->tester->getOutput()->getVerbosity(), '->execute() takes a verbosity option'); - } - - public function testGetInput() - { - $this->assertEquals('bar', $this->tester->getInput()->getArgument('foo'), '->getInput() returns the current input instance'); - } - - public function testGetOutput() - { - rewind($this->tester->getOutput()->getStream()); - $this->assertEquals('foo'.PHP_EOL, stream_get_contents($this->tester->getOutput()->getStream()), '->getOutput() returns the current output instance'); - } - - public function testGetDisplay() - { - $this->assertEquals('foo'.PHP_EOL, $this->tester->getDisplay(), '->getDisplay() returns the display of the last execution'); - } - - public function testGetStatusCode() - { - $this->assertSame(0, $this->tester->getStatusCode(), '->getStatusCode() returns the status code'); - } -} diff --git a/vendor/symfony/console/Tests/Tester/CommandTesterTest.php b/vendor/symfony/console/Tests/Tester/CommandTesterTest.php deleted file mode 100644 index b54c00e83..000000000 --- a/vendor/symfony/console/Tests/Tester/CommandTesterTest.php +++ /dev/null @@ -1,84 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Console\Tests\Tester; - -use Symfony\Component\Console\Application; -use Symfony\Component\Console\Command\Command; -use Symfony\Component\Console\Output\Output; -use Symfony\Component\Console\Tester\CommandTester; - -class CommandTesterTest extends \PHPUnit_Framework_TestCase -{ - protected $command; - protected $tester; - - protected function setUp() - { - $this->command = new Command('foo'); - $this->command->addArgument('command'); - $this->command->addArgument('foo'); - $this->command->setCode(function ($input, $output) { $output->writeln('foo'); }); - - $this->tester = new CommandTester($this->command); - $this->tester->execute(array('foo' => 'bar'), array('interactive' => false, 'decorated' => false, 'verbosity' => Output::VERBOSITY_VERBOSE)); - } - - protected function tearDown() - { - $this->command = null; - $this->tester = null; - } - - public function testExecute() - { - $this->assertFalse($this->tester->getInput()->isInteractive(), '->execute() takes an interactive option'); - $this->assertFalse($this->tester->getOutput()->isDecorated(), '->execute() takes a decorated option'); - $this->assertEquals(Output::VERBOSITY_VERBOSE, $this->tester->getOutput()->getVerbosity(), '->execute() takes a verbosity option'); - } - - public function testGetInput() - { - $this->assertEquals('bar', $this->tester->getInput()->getArgument('foo'), '->getInput() returns the current input instance'); - } - - public function testGetOutput() - { - rewind($this->tester->getOutput()->getStream()); - $this->assertEquals('foo'.PHP_EOL, stream_get_contents($this->tester->getOutput()->getStream()), '->getOutput() returns the current output instance'); - } - - public function testGetDisplay() - { - $this->assertEquals('foo'.PHP_EOL, $this->tester->getDisplay(), '->getDisplay() returns the display of the last execution'); - } - - public function testGetStatusCode() - { - $this->assertSame(0, $this->tester->getStatusCode(), '->getStatusCode() returns the status code'); - } - - public function testCommandFromApplication() - { - $application = new Application(); - $application->setAutoExit(false); - - $command = new Command('foo'); - $command->setCode(function ($input, $output) { $output->writeln('foo'); }); - - $application->add($command); - - $tester = new CommandTester($application->find('foo')); - - // check that there is no need to pass the command name here - $this->assertEquals(0, $tester->execute(array())); - } -} diff --git a/vendor/symfony/css-selector/Tests/CssSelectorTest.php b/vendor/symfony/css-selector/Tests/CssSelectorTest.php deleted file mode 100644 index 61ab80eec..000000000 --- a/vendor/symfony/css-selector/Tests/CssSelectorTest.php +++ /dev/null @@ -1,64 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests; - -use Symfony\Component\CssSelector\CssSelector; - -class CssSelectorTest extends \PHPUnit_Framework_TestCase -{ - public function testCssToXPath() - { - $this->assertEquals('descendant-or-self::*', CssSelector::toXPath('')); - $this->assertEquals('descendant-or-self::h1', CssSelector::toXPath('h1')); - $this->assertEquals("descendant-or-self::h1[@id = 'foo']", CssSelector::toXPath('h1#foo')); - $this->assertEquals("descendant-or-self::h1[@class and contains(concat(' ', normalize-space(@class), ' '), ' foo ')]", CssSelector::toXPath('h1.foo')); - $this->assertEquals('descendant-or-self::foo:h1', CssSelector::toXPath('foo|h1')); - } - - /** @dataProvider getCssToXPathWithoutPrefixTestData */ - public function testCssToXPathWithoutPrefix($css, $xpath) - { - $this->assertEquals($xpath, CssSelector::toXPath($css, ''), '->parse() parses an input string and returns a node'); - } - - public function testParseExceptions() - { - try { - CssSelector::toXPath('h1:'); - $this->fail('->parse() throws an Exception if the css selector is not valid'); - } catch (\Exception $e) { - $this->assertInstanceOf('\Symfony\Component\CssSelector\Exception\ParseException', $e, '->parse() throws an Exception if the css selector is not valid'); - $this->assertEquals('Expected identifier, but found.', $e->getMessage(), '->parse() throws an Exception if the css selector is not valid'); - } - } - - public function getCssToXPathWithoutPrefixTestData() - { - return array( - array('h1', 'h1'), - array('foo|h1', 'foo:h1'), - array('h1, h2, h3', 'h1 | h2 | h3'), - array('h1:nth-child(3n+1)', "*/*[name() = 'h1' and (position() - 1 >= 0 and (position() - 1) mod 3 = 0)]"), - array('h1 > p', 'h1/p'), - array('h1#foo', "h1[@id = 'foo']"), - array('h1.foo', "h1[@class and contains(concat(' ', normalize-space(@class), ' '), ' foo ')]"), - array('h1[class*="foo bar"]', "h1[@class and contains(@class, 'foo bar')]"), - array('h1[foo|class*="foo bar"]', "h1[@foo:class and contains(@foo:class, 'foo bar')]"), - array('h1[class]', 'h1[@class]'), - array('h1 .foo', "h1/descendant-or-self::*/*[@class and contains(concat(' ', normalize-space(@class), ' '), ' foo ')]"), - array('h1 #foo', "h1/descendant-or-self::*/*[@id = 'foo']"), - array('h1 [class*=foo]', "h1/descendant-or-self::*/*[@class and contains(@class, 'foo')]"), - array('div>.foo', "div/*[@class and contains(concat(' ', normalize-space(@class), ' '), ' foo ')]"), - array('div > .foo', "div/*[@class and contains(concat(' ', normalize-space(@class), ' '), ' foo ')]"), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/AbstractNodeTest.php b/vendor/symfony/css-selector/Tests/Node/AbstractNodeTest.php deleted file mode 100644 index 16a3a34d6..000000000 --- a/vendor/symfony/css-selector/Tests/Node/AbstractNodeTest.php +++ /dev/null @@ -1,32 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\NodeInterface; - -abstract class AbstractNodeTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getToStringConversionTestData */ - public function testToStringConversion(NodeInterface $node, $representation) - { - $this->assertEquals($representation, (string) $node); - } - - /** @dataProvider getSpecificityValueTestData */ - public function testSpecificityValue(NodeInterface $node, $value) - { - $this->assertEquals($value, $node->getSpecificity()->getValue()); - } - - abstract public function getToStringConversionTestData(); - abstract public function getSpecificityValueTestData(); -} diff --git a/vendor/symfony/css-selector/Tests/Node/AttributeNodeTest.php b/vendor/symfony/css-selector/Tests/Node/AttributeNodeTest.php deleted file mode 100644 index 1fd090f5a..000000000 --- a/vendor/symfony/css-selector/Tests/Node/AttributeNodeTest.php +++ /dev/null @@ -1,37 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\AttributeNode; -use Symfony\Component\CssSelector\Node\ElementNode; - -class AttributeNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new AttributeNode(new ElementNode(), null, 'attribute', 'exists', null), 'Attribute[Element[*][attribute]]'), - array(new AttributeNode(new ElementNode(), null, 'attribute', '$=', 'value'), "Attribute[Element[*][attribute $= 'value']]"), - array(new AttributeNode(new ElementNode(), 'namespace', 'attribute', '$=', 'value'), "Attribute[Element[*][namespace|attribute $= 'value']]"), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new AttributeNode(new ElementNode(), null, 'attribute', 'exists', null), 10), - array(new AttributeNode(new ElementNode(null, 'element'), null, 'attribute', 'exists', null), 11), - array(new AttributeNode(new ElementNode(), null, 'attribute', '$=', 'value'), 10), - array(new AttributeNode(new ElementNode(), 'namespace', 'attribute', '$=', 'value'), 10), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/ClassNodeTest.php b/vendor/symfony/css-selector/Tests/Node/ClassNodeTest.php deleted file mode 100644 index e0ab45acc..000000000 --- a/vendor/symfony/css-selector/Tests/Node/ClassNodeTest.php +++ /dev/null @@ -1,33 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ClassNode; -use Symfony\Component\CssSelector\Node\ElementNode; - -class ClassNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new ClassNode(new ElementNode(), 'class'), 'Class[Element[*].class]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new ClassNode(new ElementNode(), 'class'), 10), - array(new ClassNode(new ElementNode(null, 'element'), 'class'), 11), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/CombinedSelectorNodeTest.php b/vendor/symfony/css-selector/Tests/Node/CombinedSelectorNodeTest.php deleted file mode 100644 index 9547298a6..000000000 --- a/vendor/symfony/css-selector/Tests/Node/CombinedSelectorNodeTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\CombinedSelectorNode; -use Symfony\Component\CssSelector\Node\ElementNode; - -class CombinedSelectorNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new CombinedSelectorNode(new ElementNode(), '>', new ElementNode()), 'CombinedSelector[Element[*] > Element[*]]'), - array(new CombinedSelectorNode(new ElementNode(), ' ', new ElementNode()), 'CombinedSelector[Element[*] Element[*]]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new CombinedSelectorNode(new ElementNode(), '>', new ElementNode()), 0), - array(new CombinedSelectorNode(new ElementNode(null, 'element'), '>', new ElementNode()), 1), - array(new CombinedSelectorNode(new ElementNode(null, 'element'), '>', new ElementNode(null, 'element')), 2), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/ElementNodeTest.php b/vendor/symfony/css-selector/Tests/Node/ElementNodeTest.php deleted file mode 100644 index 1db6a591a..000000000 --- a/vendor/symfony/css-selector/Tests/Node/ElementNodeTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ElementNode; - -class ElementNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new ElementNode(), 'Element[*]'), - array(new ElementNode(null, 'element'), 'Element[element]'), - array(new ElementNode('namespace', 'element'), 'Element[namespace|element]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new ElementNode(), 0), - array(new ElementNode(null, 'element'), 1), - array(new ElementNode('namespace', 'element'),1), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/FunctionNodeTest.php b/vendor/symfony/css-selector/Tests/Node/FunctionNodeTest.php deleted file mode 100644 index ee3ce51ba..000000000 --- a/vendor/symfony/css-selector/Tests/Node/FunctionNodeTest.php +++ /dev/null @@ -1,47 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ElementNode; -use Symfony\Component\CssSelector\Node\FunctionNode; -use Symfony\Component\CssSelector\Parser\Token; - -class FunctionNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new FunctionNode(new ElementNode(), 'function'), 'Function[Element[*]:function()]'), - array(new FunctionNode(new ElementNode(), 'function', array( - new Token(Token::TYPE_IDENTIFIER, 'value', 0), - )), "Function[Element[*]:function(['value'])]"), - array(new FunctionNode(new ElementNode(), 'function', array( - new Token(Token::TYPE_STRING, 'value1', 0), - new Token(Token::TYPE_NUMBER, 'value2', 0), - )), "Function[Element[*]:function(['value1', 'value2'])]"), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new FunctionNode(new ElementNode(), 'function'), 10), - array(new FunctionNode(new ElementNode(), 'function', array( - new Token(Token::TYPE_IDENTIFIER, 'value', 0), - )), 10), - array(new FunctionNode(new ElementNode(), 'function', array( - new Token(Token::TYPE_STRING, 'value1', 0), - new Token(Token::TYPE_NUMBER, 'value2', 0), - )), 10), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/HashNodeTest.php b/vendor/symfony/css-selector/Tests/Node/HashNodeTest.php deleted file mode 100644 index 8554b226d..000000000 --- a/vendor/symfony/css-selector/Tests/Node/HashNodeTest.php +++ /dev/null @@ -1,33 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\HashNode; -use Symfony\Component\CssSelector\Node\ElementNode; - -class HashNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new HashNode(new ElementNode(), 'id'), 'Hash[Element[*]#id]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new HashNode(new ElementNode(), 'id'), 100), - array(new HashNode(new ElementNode(null, 'id'), 'class'), 101), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/NegationNodeTest.php b/vendor/symfony/css-selector/Tests/Node/NegationNodeTest.php deleted file mode 100644 index edf4552ba..000000000 --- a/vendor/symfony/css-selector/Tests/Node/NegationNodeTest.php +++ /dev/null @@ -1,33 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ClassNode; -use Symfony\Component\CssSelector\Node\NegationNode; -use Symfony\Component\CssSelector\Node\ElementNode; - -class NegationNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new NegationNode(new ElementNode(), new ClassNode(new ElementNode(), 'class')), 'Negation[Element[*]:not(Class[Element[*].class])]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new NegationNode(new ElementNode(), new ClassNode(new ElementNode(), 'class')), 10), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/PseudoNodeTest.php b/vendor/symfony/css-selector/Tests/Node/PseudoNodeTest.php deleted file mode 100644 index bc57813cc..000000000 --- a/vendor/symfony/css-selector/Tests/Node/PseudoNodeTest.php +++ /dev/null @@ -1,32 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ElementNode; -use Symfony\Component\CssSelector\Node\PseudoNode; - -class PseudoNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new PseudoNode(new ElementNode(), 'pseudo'), 'Pseudo[Element[*]:pseudo]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new PseudoNode(new ElementNode(), 'pseudo'), 10), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/SelectorNodeTest.php b/vendor/symfony/css-selector/Tests/Node/SelectorNodeTest.php deleted file mode 100644 index 5badf71d1..000000000 --- a/vendor/symfony/css-selector/Tests/Node/SelectorNodeTest.php +++ /dev/null @@ -1,34 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\ElementNode; -use Symfony\Component\CssSelector\Node\SelectorNode; - -class SelectorNodeTest extends AbstractNodeTest -{ - public function getToStringConversionTestData() - { - return array( - array(new SelectorNode(new ElementNode()), 'Selector[Element[*]]'), - array(new SelectorNode(new ElementNode(), 'pseudo'), 'Selector[Element[*]::pseudo]'), - ); - } - - public function getSpecificityValueTestData() - { - return array( - array(new SelectorNode(new ElementNode()), 0), - array(new SelectorNode(new ElementNode(), 'pseudo'), 1), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Node/SpecificityTest.php b/vendor/symfony/css-selector/Tests/Node/SpecificityTest.php deleted file mode 100644 index c34fe5fc7..000000000 --- a/vendor/symfony/css-selector/Tests/Node/SpecificityTest.php +++ /dev/null @@ -1,62 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Node; - -use Symfony\Component\CssSelector\Node\Specificity; - -class SpecificityTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getValueTestData */ - public function testValue(Specificity $specificity, $value) - { - $this->assertEquals($value, $specificity->getValue()); - } - - /** @dataProvider getValueTestData */ - public function testPlusValue(Specificity $specificity, $value) - { - $this->assertEquals($value + 123, $specificity->plus(new Specificity(1, 2, 3))->getValue()); - } - - public function getValueTestData() - { - return array( - array(new Specificity(0, 0, 0), 0), - array(new Specificity(0, 0, 2), 2), - array(new Specificity(0, 3, 0), 30), - array(new Specificity(4, 0, 0), 400), - array(new Specificity(4, 3, 2), 432), - ); - } - - /** @dataProvider getCompareTestData */ - public function testCompareTo(Specificity $a, Specificity $b, $result) - { - $this->assertEquals($result, $a->compareTo($b)); - } - - public function getCompareTestData() - { - return array( - array(new Specificity(0, 0, 0), new Specificity(0, 0, 0), 0), - array(new Specificity(0, 0, 1), new Specificity(0, 0, 1), 0), - array(new Specificity(0, 0, 2), new Specificity(0, 0, 1), 1), - array(new Specificity(0, 0, 2), new Specificity(0, 0, 3), -1), - array(new Specificity(0, 4, 0), new Specificity(0, 4, 0), 0), - array(new Specificity(0, 6, 0), new Specificity(0, 5, 11), 1), - array(new Specificity(0, 7, 0), new Specificity(0, 8, 0), -1), - array(new Specificity(9, 0, 0), new Specificity(9, 0, 0), 0), - array(new Specificity(11, 0, 0), new Specificity(10, 11, 0), 1), - array(new Specificity(12, 11, 0), new Specificity(13, 0, 0), -1), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/AbstractHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/AbstractHandlerTest.php deleted file mode 100644 index a06dca013..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/AbstractHandlerTest.php +++ /dev/null @@ -1,67 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Reader; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\TokenStream; - -/** - * @author Jean-François Simon - */ -abstract class AbstractHandlerTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getHandleValueTestData */ - public function testHandleValue($value, Token $expectedToken, $remainingContent) - { - $reader = new Reader($value); - $stream = new TokenStream(); - - $this->assertTrue($this->generateHandler()->handle($reader, $stream)); - $this->assertEquals($expectedToken, $stream->getNext()); - $this->assertRemainingContent($reader, $remainingContent); - } - - /** @dataProvider getDontHandleValueTestData */ - public function testDontHandleValue($value) - { - $reader = new Reader($value); - $stream = new TokenStream(); - - $this->assertFalse($this->generateHandler()->handle($reader, $stream)); - $this->assertStreamEmpty($stream); - $this->assertRemainingContent($reader, $value); - } - - abstract public function getHandleValueTestData(); - abstract public function getDontHandleValueTestData(); - abstract protected function generateHandler(); - - protected function assertStreamEmpty(TokenStream $stream) - { - $property = new \ReflectionProperty($stream, 'tokens'); - $property->setAccessible(true); - - $this->assertEquals(array(), $property->getValue($stream)); - } - - protected function assertRemainingContent(Reader $reader, $remainingContent) - { - if ('' === $remainingContent) { - $this->assertEquals(0, $reader->getRemainingLength()); - $this->assertTrue($reader->isEOF()); - } else { - $this->assertEquals(strlen($remainingContent), $reader->getRemainingLength()); - $this->assertEquals(0, $reader->getOffset($remainingContent)); - } - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/CommentHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/CommentHandlerTest.php deleted file mode 100644 index 3961bf7d5..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/CommentHandlerTest.php +++ /dev/null @@ -1,55 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\CommentHandler; -use Symfony\Component\CssSelector\Parser\Reader; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\TokenStream; - -class CommentHandlerTest extends AbstractHandlerTest -{ - /** @dataProvider getHandleValueTestData */ - public function testHandleValue($value, Token $unusedArgument, $remainingContent) - { - $reader = new Reader($value); - $stream = new TokenStream(); - - $this->assertTrue($this->generateHandler()->handle($reader, $stream)); - // comments are ignored (not pushed as token in stream) - $this->assertStreamEmpty($stream); - $this->assertRemainingContent($reader, $remainingContent); - } - - public function getHandleValueTestData() - { - return array( - // 2nd argument only exists for inherited method compatibility - array('/* comment */', new Token(null, null, null), ''), - array('/* comment */foo', new Token(null, null, null), 'foo'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('>'), - array('+'), - array(' '), - ); - } - - protected function generateHandler() - { - return new CommentHandler(); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/HashHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/HashHandlerTest.php deleted file mode 100644 index b7fa00a22..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/HashHandlerTest.php +++ /dev/null @@ -1,49 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\HashHandler; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerPatterns; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerEscaping; - -class HashHandlerTest extends AbstractHandlerTest -{ - public function getHandleValueTestData() - { - return array( - array('#id', new Token(Token::TYPE_HASH, 'id', 0), ''), - array('#123', new Token(Token::TYPE_HASH, '123', 0), ''), - - array('#id.class', new Token(Token::TYPE_HASH, 'id', 0), '.class'), - array('#id element', new Token(Token::TYPE_HASH, 'id', 0), ' element'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('id'), - array('123'), - array('<'), - array('<'), - array('#'), - ); - } - - protected function generateHandler() - { - $patterns = new TokenizerPatterns(); - - return new HashHandler($patterns, new TokenizerEscaping($patterns)); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/IdentifierHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/IdentifierHandlerTest.php deleted file mode 100644 index 44d357498..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/IdentifierHandlerTest.php +++ /dev/null @@ -1,49 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\IdentifierHandler; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerPatterns; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerEscaping; - -class IdentifierHandlerTest extends AbstractHandlerTest -{ - public function getHandleValueTestData() - { - return array( - array('foo', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), ''), - array('foo|bar', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), '|bar'), - array('foo.class', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), '.class'), - array('foo[attr]', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), '[attr]'), - array('foo bar', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), ' bar'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('>'), - array('+'), - array(' '), - array('*|foo'), - array('/* comment */'), - ); - } - - protected function generateHandler() - { - $patterns = new TokenizerPatterns(); - - return new IdentifierHandler($patterns, new TokenizerEscaping($patterns)); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/NumberHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/NumberHandlerTest.php deleted file mode 100644 index 675fd05b4..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/NumberHandlerTest.php +++ /dev/null @@ -1,50 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\NumberHandler; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerPatterns; - -class NumberHandlerTest extends AbstractHandlerTest -{ - public function getHandleValueTestData() - { - return array( - array('12', new Token(Token::TYPE_NUMBER, '12', 0), ''), - array('12.34', new Token(Token::TYPE_NUMBER, '12.34', 0), ''), - array('+12.34', new Token(Token::TYPE_NUMBER, '+12.34', 0), ''), - array('-12.34', new Token(Token::TYPE_NUMBER, '-12.34', 0), ''), - - array('12 arg', new Token(Token::TYPE_NUMBER, '12', 0), ' arg'), - array('12]', new Token(Token::TYPE_NUMBER, '12', 0), ']'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('hello'), - array('>'), - array('+'), - array(' '), - array('/* comment */'), - ); - } - - protected function generateHandler() - { - $patterns = new TokenizerPatterns(); - - return new NumberHandler($patterns); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/StringHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/StringHandlerTest.php deleted file mode 100644 index 89eff8bd2..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/StringHandlerTest.php +++ /dev/null @@ -1,50 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\StringHandler; -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerPatterns; -use Symfony\Component\CssSelector\Parser\Tokenizer\TokenizerEscaping; - -class StringHandlerTest extends AbstractHandlerTest -{ - public function getHandleValueTestData() - { - return array( - array('"hello"', new Token(Token::TYPE_STRING, 'hello', 1), ''), - array('"1"', new Token(Token::TYPE_STRING, '1', 1), ''), - array('" "', new Token(Token::TYPE_STRING, ' ', 1), ''), - array('""', new Token(Token::TYPE_STRING, '', 1), ''), - array("'hello'", new Token(Token::TYPE_STRING, 'hello', 1), ''), - - array("'foo'bar", new Token(Token::TYPE_STRING, 'foo', 1), 'bar'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('hello'), - array('>'), - array('1'), - array(' '), - ); - } - - protected function generateHandler() - { - $patterns = new TokenizerPatterns(); - - return new StringHandler($patterns, new TokenizerEscaping($patterns)); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Handler/WhitespaceHandlerTest.php b/vendor/symfony/css-selector/Tests/Parser/Handler/WhitespaceHandlerTest.php deleted file mode 100644 index f5f9e71dc..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Handler/WhitespaceHandlerTest.php +++ /dev/null @@ -1,44 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Handler; - -use Symfony\Component\CssSelector\Parser\Handler\WhitespaceHandler; -use Symfony\Component\CssSelector\Parser\Token; - -class WhitespaceHandlerTest extends AbstractHandlerTest -{ - public function getHandleValueTestData() - { - return array( - array(' ', new Token(Token::TYPE_WHITESPACE, ' ', 0), ''), - array("\n", new Token(Token::TYPE_WHITESPACE, "\n", 0), ''), - array("\t", new Token(Token::TYPE_WHITESPACE, "\t", 0), ''), - - array(' foo', new Token(Token::TYPE_WHITESPACE, ' ', 0), 'foo'), - array(' .foo', new Token(Token::TYPE_WHITESPACE, ' ', 0), '.foo'), - ); - } - - public function getDontHandleValueTestData() - { - return array( - array('>'), - array('1'), - array('a'), - ); - } - - protected function generateHandler() - { - return new WhitespaceHandler(); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/ParserTest.php b/vendor/symfony/css-selector/Tests/Parser/ParserTest.php deleted file mode 100644 index 0454d9faa..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/ParserTest.php +++ /dev/null @@ -1,248 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser; - -use Symfony\Component\CssSelector\Exception\SyntaxErrorException; -use Symfony\Component\CssSelector\Node\FunctionNode; -use Symfony\Component\CssSelector\Node\SelectorNode; -use Symfony\Component\CssSelector\Parser\Parser; -use Symfony\Component\CssSelector\Parser\Token; - -class ParserTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getParserTestData */ - public function testParser($source, $representation) - { - $parser = new Parser(); - - $this->assertEquals($representation, array_map(function (SelectorNode $node) { - return (string) $node->getTree(); - }, $parser->parse($source))); - } - - /** @dataProvider getParserExceptionTestData */ - public function testParserException($source, $message) - { - $parser = new Parser(); - - try { - $parser->parse($source); - $this->fail('Parser should throw a SyntaxErrorException.'); - } catch (SyntaxErrorException $e) { - $this->assertEquals($message, $e->getMessage()); - } - } - - /** @dataProvider getPseudoElementsTestData */ - public function testPseudoElements($source, $element, $pseudo) - { - $parser = new Parser(); - $selectors = $parser->parse($source); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals($element, (string) $selector->getTree()); - $this->assertEquals($pseudo, (string) $selector->getPseudoElement()); - } - - /** @dataProvider getSpecificityTestData */ - public function testSpecificity($source, $value) - { - $parser = new Parser(); - $selectors = $parser->parse($source); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals($value, $selector->getSpecificity()->getValue()); - } - - /** @dataProvider getParseSeriesTestData */ - public function testParseSeries($series, $a, $b) - { - $parser = new Parser(); - $selectors = $parser->parse(sprintf(':nth-child(%s)', $series)); - $this->assertCount(1, $selectors); - - /** @var FunctionNode $function */ - $function = $selectors[0]->getTree(); - $this->assertEquals(array($a, $b), Parser::parseSeries($function->getArguments())); - } - - /** @dataProvider getParseSeriesExceptionTestData */ - public function testParseSeriesException($series) - { - $parser = new Parser(); - $selectors = $parser->parse(sprintf(':nth-child(%s)', $series)); - $this->assertCount(1, $selectors); - - /** @var FunctionNode $function */ - $function = $selectors[0]->getTree(); - $this->setExpectedException('Symfony\Component\CssSelector\Exception\SyntaxErrorException'); - Parser::parseSeries($function->getArguments()); - } - - public function getParserTestData() - { - return array( - array('*', array('Element[*]')), - array('*|*', array('Element[*]')), - array('*|foo', array('Element[foo]')), - array('foo|*', array('Element[foo|*]')), - array('foo|bar', array('Element[foo|bar]')), - array('#foo#bar', array('Hash[Hash[Element[*]#foo]#bar]')), - array('div>.foo', array('CombinedSelector[Element[div] > Class[Element[*].foo]]')), - array('div> .foo', array('CombinedSelector[Element[div] > Class[Element[*].foo]]')), - array('div >.foo', array('CombinedSelector[Element[div] > Class[Element[*].foo]]')), - array('div > .foo', array('CombinedSelector[Element[div] > Class[Element[*].foo]]')), - array("div \n> \t \t .foo", array('CombinedSelector[Element[div] > Class[Element[*].foo]]')), - array('td.foo,.bar', array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array('td.foo, .bar', array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array("td.foo\t\r\n\f ,\t\r\n\f .bar", array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array('td.foo,.bar', array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array('td.foo, .bar', array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array("td.foo\t\r\n\f ,\t\r\n\f .bar", array('Class[Element[td].foo]', 'Class[Element[*].bar]')), - array('div, td.foo, div.bar span', array('Element[div]', 'Class[Element[td].foo]', 'CombinedSelector[Class[Element[div].bar] Element[span]]')), - array('div > p', array('CombinedSelector[Element[div] > Element[p]]')), - array('td:first', array('Pseudo[Element[td]:first]')), - array('td :first', array('CombinedSelector[Element[td] Pseudo[Element[*]:first]]')), - array('a[name]', array('Attribute[Element[a][name]]')), - array("a[ name\t]", array('Attribute[Element[a][name]]')), - array('a [name]', array('CombinedSelector[Element[a] Attribute[Element[*][name]]]')), - array('a[rel="include"]', array("Attribute[Element[a][rel = 'include']]")), - array('a[rel = include]', array("Attribute[Element[a][rel = 'include']]")), - array("a[hreflang |= 'en']", array("Attribute[Element[a][hreflang |= 'en']]")), - array('a[hreflang|=en]', array("Attribute[Element[a][hreflang |= 'en']]")), - array('div:nth-child(10)', array("Function[Element[div]:nth-child(['10'])]")), - array(':nth-child(2n+2)', array("Function[Element[*]:nth-child(['2', 'n', '+2'])]")), - array('div:nth-of-type(10)', array("Function[Element[div]:nth-of-type(['10'])]")), - array('div div:nth-of-type(10) .aclass', array("CombinedSelector[CombinedSelector[Element[div] Function[Element[div]:nth-of-type(['10'])]] Class[Element[*].aclass]]")), - array('label:only', array('Pseudo[Element[label]:only]')), - array('a:lang(fr)', array("Function[Element[a]:lang(['fr'])]")), - array('div:contains("foo")', array("Function[Element[div]:contains(['foo'])]")), - array('div#foobar', array('Hash[Element[div]#foobar]')), - array('div:not(div.foo)', array('Negation[Element[div]:not(Class[Element[div].foo])]')), - array('td ~ th', array('CombinedSelector[Element[td] ~ Element[th]]')), - array('.foo[data-bar][data-baz=0]', array("Attribute[Attribute[Class[Element[*].foo][data-bar]][data-baz = '0']]")), - ); - } - - public function getParserExceptionTestData() - { - return array( - array('attributes(href)/html/body/a', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '(', 10))->getMessage()), - array('attributes(href)', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '(', 10))->getMessage()), - array('html/body/a', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '/', 4))->getMessage()), - array(' ', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_FILE_END, '', 1))->getMessage()), - array('div, ', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_FILE_END, '', 5))->getMessage()), - array(' , div', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, ',', 1))->getMessage()), - array('p, , div', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, ',', 3))->getMessage()), - array('div > ', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_FILE_END, '', 6))->getMessage()), - array(' > div', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '>', 2))->getMessage()), - array('foo|#bar', SyntaxErrorException::unexpectedToken('identifier or "*"', new Token(Token::TYPE_HASH, 'bar', 4))->getMessage()), - array('#.foo', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '#', 0))->getMessage()), - array('.#foo', SyntaxErrorException::unexpectedToken('identifier', new Token(Token::TYPE_HASH, 'foo', 1))->getMessage()), - array(':#foo', SyntaxErrorException::unexpectedToken('identifier', new Token(Token::TYPE_HASH, 'foo', 1))->getMessage()), - array('[*]', SyntaxErrorException::unexpectedToken('"|"', new Token(Token::TYPE_DELIMITER, ']', 2))->getMessage()), - array('[foo|]', SyntaxErrorException::unexpectedToken('identifier', new Token(Token::TYPE_DELIMITER, ']', 5))->getMessage()), - array('[#]', SyntaxErrorException::unexpectedToken('identifier or "*"', new Token(Token::TYPE_DELIMITER, '#', 1))->getMessage()), - array('[foo=#]', SyntaxErrorException::unexpectedToken('string or identifier', new Token(Token::TYPE_DELIMITER, '#', 5))->getMessage()), - array(':nth-child()', SyntaxErrorException::unexpectedToken('at least one argument', new Token(Token::TYPE_DELIMITER, ')', 11))->getMessage()), - array('[href]a', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_IDENTIFIER, 'a', 6))->getMessage()), - array('[rel:stylesheet]', SyntaxErrorException::unexpectedToken('operator', new Token(Token::TYPE_DELIMITER, ':', 4))->getMessage()), - array('[rel=stylesheet', SyntaxErrorException::unexpectedToken('"]"', new Token(Token::TYPE_FILE_END, '', 15))->getMessage()), - array(':lang(fr', SyntaxErrorException::unexpectedToken('an argument', new Token(Token::TYPE_FILE_END, '', 8))->getMessage()), - array(':contains("foo', SyntaxErrorException::unclosedString(10)->getMessage()), - array('foo!', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '!', 3))->getMessage()), - ); - } - - public function getPseudoElementsTestData() - { - return array( - array('foo', 'Element[foo]', ''), - array('*', 'Element[*]', ''), - array(':empty', 'Pseudo[Element[*]:empty]', ''), - array(':BEfore', 'Element[*]', 'before'), - array(':aftER', 'Element[*]', 'after'), - array(':First-Line', 'Element[*]', 'first-line'), - array(':First-Letter', 'Element[*]', 'first-letter'), - array('::befoRE', 'Element[*]', 'before'), - array('::AFter', 'Element[*]', 'after'), - array('::firsT-linE', 'Element[*]', 'first-line'), - array('::firsT-letteR', 'Element[*]', 'first-letter'), - array('::Selection', 'Element[*]', 'selection'), - array('foo:after', 'Element[foo]', 'after'), - array('foo::selection', 'Element[foo]', 'selection'), - array('lorem#ipsum ~ a#b.c[href]:empty::selection', 'CombinedSelector[Hash[Element[lorem]#ipsum] ~ Pseudo[Attribute[Class[Hash[Element[a]#b].c][href]]:empty]]', 'selection'), - ); - } - - public function getSpecificityTestData() - { - return array( - array('*', 0), - array(' foo', 1), - array(':empty ', 10), - array(':before', 1), - array('*:before', 1), - array(':nth-child(2)', 10), - array('.bar', 10), - array('[baz]', 10), - array('[baz="4"]', 10), - array('[baz^="4"]', 10), - array('#lipsum', 100), - array(':not(*)', 0), - array(':not(foo)', 1), - array(':not(.foo)', 10), - array(':not([foo])', 10), - array(':not(:empty)', 10), - array(':not(#foo)', 100), - array('foo:empty', 11), - array('foo:before', 2), - array('foo::before', 2), - array('foo:empty::before', 12), - array('#lorem + foo#ipsum:first-child > bar:first-line', 213), - ); - } - - public function getParseSeriesTestData() - { - return array( - array('1n+3', 1, 3), - array('1n +3', 1, 3), - array('1n + 3', 1, 3), - array('1n+ 3', 1, 3), - array('1n-3', 1, -3), - array('1n -3', 1, -3), - array('1n - 3', 1, -3), - array('1n- 3', 1, -3), - array('n-5', 1, -5), - array('odd', 2, 1), - array('even', 2, 0), - array('3n', 3, 0), - array('n', 1, 0), - array('+n', 1, 0), - array('-n', -1, 0), - array('5', 0, 5), - ); - } - - public function getParseSeriesExceptionTestData() - { - return array( - array('foo'), - array('n+'), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/ReaderTest.php b/vendor/symfony/css-selector/Tests/Parser/ReaderTest.php deleted file mode 100644 index 03c054eaa..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/ReaderTest.php +++ /dev/null @@ -1,101 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser; - -use Symfony\Component\CssSelector\Parser\Reader; - -class ReaderTest extends \PHPUnit_Framework_TestCase -{ - public function testIsEOF() - { - $reader = new Reader(''); - $this->assertTrue($reader->isEOF()); - - $reader = new Reader('hello'); - $this->assertFalse($reader->isEOF()); - - $this->assignPosition($reader, 2); - $this->assertFalse($reader->isEOF()); - - $this->assignPosition($reader, 5); - $this->assertTrue($reader->isEOF()); - } - - public function testGetRemainingLength() - { - $reader = new Reader('hello'); - $this->assertEquals(5, $reader->getRemainingLength()); - - $this->assignPosition($reader, 2); - $this->assertEquals(3, $reader->getRemainingLength()); - - $this->assignPosition($reader, 5); - $this->assertEquals(0, $reader->getRemainingLength()); - } - - public function testGetSubstring() - { - $reader = new Reader('hello'); - $this->assertEquals('he', $reader->getSubstring(2)); - $this->assertEquals('el', $reader->getSubstring(2, 1)); - - $this->assignPosition($reader, 2); - $this->assertEquals('ll', $reader->getSubstring(2)); - $this->assertEquals('lo', $reader->getSubstring(2, 1)); - } - - public function testGetOffset() - { - $reader = new Reader('hello'); - $this->assertEquals(2, $reader->getOffset('ll')); - $this->assertFalse($reader->getOffset('w')); - - $this->assignPosition($reader, 2); - $this->assertEquals(0, $reader->getOffset('ll')); - $this->assertFalse($reader->getOffset('he')); - } - - public function testFindPattern() - { - $reader = new Reader('hello'); - - $this->assertFalse($reader->findPattern('/world/')); - $this->assertEquals(array('hello', 'h'), $reader->findPattern('/^([a-z]).*/')); - - $this->assignPosition($reader, 2); - $this->assertFalse($reader->findPattern('/^h.*/')); - $this->assertEquals(array('llo'), $reader->findPattern('/^llo$/')); - } - - public function testMoveForward() - { - $reader = new Reader('hello'); - $this->assertEquals(0, $reader->getPosition()); - - $reader->moveForward(2); - $this->assertEquals(2, $reader->getPosition()); - } - - public function testToEnd() - { - $reader = new Reader('hello'); - $reader->moveToEnd(); - $this->assertTrue($reader->isEOF()); - } - - private function assignPosition(Reader $reader, $value) - { - $position = new \ReflectionProperty($reader, 'position'); - $position->setAccessible(true); - $position->setValue($reader, $value); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Shortcut/ClassParserTest.php b/vendor/symfony/css-selector/Tests/Parser/Shortcut/ClassParserTest.php deleted file mode 100644 index 6efdd6765..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Shortcut/ClassParserTest.php +++ /dev/null @@ -1,44 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Shortcut; - -use Symfony\Component\CssSelector\Node\SelectorNode; -use Symfony\Component\CssSelector\Parser\Shortcut\ClassParser; - -/** - * @author Jean-François Simon - */ -class ClassParserTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getParseTestData */ - public function testParse($source, $representation) - { - $parser = new ClassParser(); - $selectors = $parser->parse($source); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals($representation, (string) $selector->getTree()); - } - - public function getParseTestData() - { - return array( - array('.testclass', 'Class[Element[*].testclass]'), - array('testel.testclass', 'Class[Element[testel].testclass]'), - array('testns|.testclass', 'Class[Element[testns|*].testclass]'), - array('testns|*.testclass', 'Class[Element[testns|*].testclass]'), - array('testns|testel.testclass', 'Class[Element[testns|testel].testclass]'), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Shortcut/ElementParserTest.php b/vendor/symfony/css-selector/Tests/Parser/Shortcut/ElementParserTest.php deleted file mode 100644 index b30b5ee7a..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Shortcut/ElementParserTest.php +++ /dev/null @@ -1,43 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Shortcut; - -use Symfony\Component\CssSelector\Node\SelectorNode; -use Symfony\Component\CssSelector\Parser\Shortcut\ElementParser; - -/** - * @author Jean-François Simon - */ -class ElementParserTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getParseTestData */ - public function testParse($source, $representation) - { - $parser = new ElementParser(); - $selectors = $parser->parse($source); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals($representation, (string) $selector->getTree()); - } - - public function getParseTestData() - { - return array( - array('*', 'Element[*]'), - array('testel', 'Element[testel]'), - array('testns|*', 'Element[testns|*]'), - array('testns|testel', 'Element[testns|testel]'), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Shortcut/EmptyStringParserTest.php b/vendor/symfony/css-selector/Tests/Parser/Shortcut/EmptyStringParserTest.php deleted file mode 100644 index b7c3539c6..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Shortcut/EmptyStringParserTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Shortcut; - -use Symfony\Component\CssSelector\Node\SelectorNode; -use Symfony\Component\CssSelector\Parser\Shortcut\EmptyStringParser; - -/** - * @author Jean-François Simon - */ -class EmptyStringParserTest extends \PHPUnit_Framework_TestCase -{ - public function testParse() - { - $parser = new EmptyStringParser(); - $selectors = $parser->parse(''); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals('Element[*]', (string) $selector->getTree()); - - $selectors = $parser->parse('this will produce an empty array'); - $this->assertCount(0, $selectors); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/Shortcut/HashParserTest.php b/vendor/symfony/css-selector/Tests/Parser/Shortcut/HashParserTest.php deleted file mode 100644 index d2ce891ec..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/Shortcut/HashParserTest.php +++ /dev/null @@ -1,44 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser\Shortcut; - -use Symfony\Component\CssSelector\Node\SelectorNode; -use Symfony\Component\CssSelector\Parser\Shortcut\HashParser; - -/** - * @author Jean-François Simon - */ -class HashParserTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getParseTestData */ - public function testParse($source, $representation) - { - $parser = new HashParser(); - $selectors = $parser->parse($source); - $this->assertCount(1, $selectors); - - /** @var SelectorNode $selector */ - $selector = $selectors[0]; - $this->assertEquals($representation, (string) $selector->getTree()); - } - - public function getParseTestData() - { - return array( - array('#testid', 'Hash[Element[*]#testid]'), - array('testel#testid', 'Hash[Element[testel]#testid]'), - array('testns|#testid', 'Hash[Element[testns|*]#testid]'), - array('testns|*#testid', 'Hash[Element[testns|*]#testid]'), - array('testns|testel#testid', 'Hash[Element[testns|testel]#testid]'), - ); - } -} diff --git a/vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php b/vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php deleted file mode 100644 index 8f3253a7d..000000000 --- a/vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php +++ /dev/null @@ -1,95 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\Parser; - -use Symfony\Component\CssSelector\Parser\Token; -use Symfony\Component\CssSelector\Parser\TokenStream; - -class TokenStreamTest extends \PHPUnit_Framework_TestCase -{ - public function testGetNext() - { - $stream = new TokenStream(); - $stream->push($t1 = new Token(Token::TYPE_IDENTIFIER, 'h1', 0)); - $stream->push($t2 = new Token(Token::TYPE_DELIMITER, '.', 2)); - $stream->push($t3 = new Token(Token::TYPE_IDENTIFIER, 'title', 3)); - - $this->assertSame($t1, $stream->getNext()); - $this->assertSame($t2, $stream->getNext()); - $this->assertSame($t3, $stream->getNext()); - } - - public function testGetPeek() - { - $stream = new TokenStream(); - $stream->push($t1 = new Token(Token::TYPE_IDENTIFIER, 'h1', 0)); - $stream->push($t2 = new Token(Token::TYPE_DELIMITER, '.', 2)); - $stream->push($t3 = new Token(Token::TYPE_IDENTIFIER, 'title', 3)); - - $this->assertSame($t1, $stream->getPeek()); - $this->assertSame($t1, $stream->getNext()); - $this->assertSame($t2, $stream->getPeek()); - $this->assertSame($t2, $stream->getPeek()); - $this->assertSame($t2, $stream->getNext()); - } - - public function testGetNextIdentifier() - { - $stream = new TokenStream(); - $stream->push(new Token(Token::TYPE_IDENTIFIER, 'h1', 0)); - - $this->assertEquals('h1', $stream->getNextIdentifier()); - } - - public function testFailToGetNextIdentifier() - { - $this->setExpectedException('Symfony\Component\CssSelector\Exception\SyntaxErrorException'); - - $stream = new TokenStream(); - $stream->push(new Token(Token::TYPE_DELIMITER, '.', 2)); - $stream->getNextIdentifier(); - } - - public function testGetNextIdentifierOrStar() - { - $stream = new TokenStream(); - - $stream->push(new Token(Token::TYPE_IDENTIFIER, 'h1', 0)); - $this->assertEquals('h1', $stream->getNextIdentifierOrStar()); - - $stream->push(new Token(Token::TYPE_DELIMITER, '*', 0)); - $this->assertNull($stream->getNextIdentifierOrStar()); - } - - public function testFailToGetNextIdentifierOrStar() - { - $this->setExpectedException('Symfony\Component\CssSelector\Exception\SyntaxErrorException'); - - $stream = new TokenStream(); - $stream->push(new Token(Token::TYPE_DELIMITER, '.', 2)); - $stream->getNextIdentifierOrStar(); - } - - public function testSkipWhitespace() - { - $stream = new TokenStream(); - $stream->push($t1 = new Token(Token::TYPE_IDENTIFIER, 'h1', 0)); - $stream->push($t2 = new Token(Token::TYPE_WHITESPACE, ' ', 2)); - $stream->push($t3 = new Token(Token::TYPE_IDENTIFIER, 'h1', 3)); - - $stream->skipWhitespace(); - $this->assertSame($t1, $stream->getNext()); - - $stream->skipWhitespace(); - $this->assertSame($t3, $stream->getNext()); - } -} diff --git a/vendor/symfony/css-selector/Tests/XPath/Fixtures/ids.html b/vendor/symfony/css-selector/Tests/XPath/Fixtures/ids.html deleted file mode 100644 index 5799fad25..000000000 --- a/vendor/symfony/css-selector/Tests/XPath/Fixtures/ids.html +++ /dev/null @@ -1,48 +0,0 @@ - - - - -
    - - - - link -
      -
    1. content
    2. -
    3. -
      -
      -
    4. -
    5. -
    6. -
    7. -
    8. -
    9. -
    -

    - hi there - guy - - - - - - - -

    - - -
    -

    -
      -
    - - - - -
    -
    - diff --git a/vendor/symfony/css-selector/Tests/XPath/Fixtures/lang.xml b/vendor/symfony/css-selector/Tests/XPath/Fixtures/lang.xml deleted file mode 100644 index 14f8dbed6..000000000 --- a/vendor/symfony/css-selector/Tests/XPath/Fixtures/lang.xml +++ /dev/null @@ -1,11 +0,0 @@ - - a - b - c - d - e - f - - - - diff --git a/vendor/symfony/css-selector/Tests/XPath/Fixtures/shakespear.html b/vendor/symfony/css-selector/Tests/XPath/Fixtures/shakespear.html deleted file mode 100644 index 15d1ad33a..000000000 --- a/vendor/symfony/css-selector/Tests/XPath/Fixtures/shakespear.html +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - -
    -
    -

    As You Like It

    -
    - by William Shakespeare -
    -
    -

    ACT I, SCENE III. A room in the palace.

    -
    -
    Enter CELIA and ROSALIND
    -
    -
    CELIA
    -
    -
    Why, cousin! why, Rosalind! Cupid have mercy! not a word?
    -
    -
    ROSALIND
    -
    -
    Not one to throw at a dog.
    -
    -
    CELIA
    -
    -
    No, thy words are too precious to be cast away upon
    -
    curs; throw some of them at me; come, lame me with reasons.
    -
    -
    ROSALIND
    -
    CELIA
    -
    -
    But is all this for your father?
    -
    -
    -
    Then there were two cousins laid up; when the one
    -
    should be lamed with reasons and the other mad
    -
    without any.
    -
    -
    ROSALIND
    -
    -
    No, some of it is for my child's father. O, how
    -
    full of briers is this working-day world!
    -
    -
    CELIA
    -
    -
    They are but burs, cousin, thrown upon thee in
    -
    holiday foolery: if we walk not in the trodden
    -
    paths our very petticoats will catch them.
    -
    -
    ROSALIND
    -
    -
    I could shake them off my coat: these burs are in my heart.
    -
    -
    CELIA
    -
    -
    Hem them away.
    -
    -
    ROSALIND
    -
    -
    I would try, if I could cry 'hem' and have him.
    -
    -
    CELIA
    -
    -
    Come, come, wrestle with thy affections.
    -
    -
    ROSALIND
    -
    -
    O, they take the part of a better wrestler than myself!
    -
    -
    CELIA
    -
    -
    O, a good wish upon you! you will try in time, in
    -
    despite of a fall. But, turning these jests out of
    -
    service, let us talk in good earnest: is it
    -
    possible, on such a sudden, you should fall into so
    -
    strong a liking with old Sir Rowland's youngest son?
    -
    -
    ROSALIND
    -
    -
    The duke my father loved his father dearly.
    -
    -
    CELIA
    -
    -
    Doth it therefore ensue that you should love his son
    -
    dearly? By this kind of chase, I should hate him,
    -
    for my father hated his father dearly; yet I hate
    -
    not Orlando.
    -
    -
    ROSALIND
    -
    -
    No, faith, hate him not, for my sake.
    -
    -
    CELIA
    -
    -
    Why should I not? doth he not deserve well?
    -
    -
    ROSALIND
    -
    -
    Let me love him for that, and do you love him
    -
    because I do. Look, here comes the duke.
    -
    -
    CELIA
    -
    -
    With his eyes full of anger.
    -
    Enter DUKE FREDERICK, with Lords
    -
    -
    DUKE FREDERICK
    -
    -
    Mistress, dispatch you with your safest haste
    -
    And get you from our court.
    -
    -
    ROSALIND
    -
    -
    Me, uncle?
    -
    -
    DUKE FREDERICK
    -
    -
    You, cousin
    -
    Within these ten days if that thou be'st found
    -
    So near our public court as twenty miles,
    -
    Thou diest for it.
    -
    -
    ROSALIND
    -
    -
    I do beseech your grace,
    -
    Let me the knowledge of my fault bear with me:
    -
    If with myself I hold intelligence
    -
    Or have acquaintance with mine own desires,
    -
    If that I do not dream or be not frantic,--
    -
    As I do trust I am not--then, dear uncle,
    -
    Never so much as in a thought unborn
    -
    Did I offend your highness.
    -
    -
    DUKE FREDERICK
    -
    -
    Thus do all traitors:
    -
    If their purgation did consist in words,
    -
    They are as innocent as grace itself:
    -
    Let it suffice thee that I trust thee not.
    -
    -
    ROSALIND
    -
    -
    Yet your mistrust cannot make me a traitor:
    -
    Tell me whereon the likelihood depends.
    -
    -
    DUKE FREDERICK
    -
    -
    Thou art thy father's daughter; there's enough.
    -
    -
    ROSALIND
    -
    -
    So was I when your highness took his dukedom;
    -
    So was I when your highness banish'd him:
    -
    Treason is not inherited, my lord;
    -
    Or, if we did derive it from our friends,
    -
    What's that to me? my father was no traitor:
    -
    Then, good my liege, mistake me not so much
    -
    To think my poverty is treacherous.
    -
    -
    CELIA
    -
    -
    Dear sovereign, hear me speak.
    -
    -
    DUKE FREDERICK
    -
    -
    Ay, Celia; we stay'd her for your sake,
    -
    Else had she with her father ranged along.
    -
    -
    CELIA
    -
    -
    I did not then entreat to have her stay;
    -
    It was your pleasure and your own remorse:
    -
    I was too young that time to value her;
    -
    But now I know her: if she be a traitor,
    -
    Why so am I; we still have slept together,
    -
    Rose at an instant, learn'd, play'd, eat together,
    -
    And wheresoever we went, like Juno's swans,
    -
    Still we went coupled and inseparable.
    -
    -
    DUKE FREDERICK
    -
    -
    She is too subtle for thee; and her smoothness,
    -
    Her very silence and her patience
    -
    Speak to the people, and they pity her.
    -
    Thou art a fool: she robs thee of thy name;
    -
    And thou wilt show more bright and seem more virtuous
    -
    When she is gone. Then open not thy lips:
    -
    Firm and irrevocable is my doom
    -
    Which I have pass'd upon her; she is banish'd.
    -
    -
    CELIA
    -
    -
    Pronounce that sentence then on me, my liege:
    -
    I cannot live out of her company.
    -
    -
    DUKE FREDERICK
    -
    -
    You are a fool. You, niece, provide yourself:
    -
    If you outstay the time, upon mine honour,
    -
    And in the greatness of my word, you die.
    -
    Exeunt DUKE FREDERICK and Lords
    -
    -
    CELIA
    -
    -
    O my poor Rosalind, whither wilt thou go?
    -
    Wilt thou change fathers? I will give thee mine.
    -
    I charge thee, be not thou more grieved than I am.
    -
    -
    ROSALIND
    -
    -
    I have more cause.
    -
    -
    CELIA
    -
    -
    Thou hast not, cousin;
    -
    Prithee be cheerful: know'st thou not, the duke
    -
    Hath banish'd me, his daughter?
    -
    -
    ROSALIND
    -
    -
    That he hath not.
    -
    -
    CELIA
    -
    -
    No, hath not? Rosalind lacks then the love
    -
    Which teacheth thee that thou and I am one:
    -
    Shall we be sunder'd? shall we part, sweet girl?
    -
    No: let my father seek another heir.
    -
    Therefore devise with me how we may fly,
    -
    Whither to go and what to bear with us;
    -
    And do not seek to take your change upon you,
    -
    To bear your griefs yourself and leave me out;
    -
    For, by this heaven, now at our sorrows pale,
    -
    Say what thou canst, I'll go along with thee.
    -
    -
    ROSALIND
    -
    -
    Why, whither shall we go?
    -
    -
    CELIA
    -
    -
    To seek my uncle in the forest of Arden.
    -
    -
    ROSALIND
    -
    -
    Alas, what danger will it be to us,
    -
    Maids as we are, to travel forth so far!
    -
    Beauty provoketh thieves sooner than gold.
    -
    -
    CELIA
    -
    -
    I'll put myself in poor and mean attire
    -
    And with a kind of umber smirch my face;
    -
    The like do you: so shall we pass along
    -
    And never stir assailants.
    -
    -
    ROSALIND
    -
    -
    Were it not better,
    -
    Because that I am more than common tall,
    -
    That I did suit me all points like a man?
    -
    A gallant curtle-axe upon my thigh,
    -
    A boar-spear in my hand; and--in my heart
    -
    Lie there what hidden woman's fear there will--
    -
    We'll have a swashing and a martial outside,
    -
    As many other mannish cowards have
    -
    That do outface it with their semblances.
    -
    -
    CELIA
    -
    -
    What shall I call thee when thou art a man?
    -
    -
    ROSALIND
    -
    -
    I'll have no worse a name than Jove's own page;
    -
    And therefore look you call me Ganymede.
    -
    But what will you be call'd?
    -
    -
    CELIA
    -
    -
    Something that hath a reference to my state
    -
    No longer Celia, but Aliena.
    -
    -
    ROSALIND
    -
    -
    But, cousin, what if we assay'd to steal
    -
    The clownish fool out of your father's court?
    -
    Would he not be a comfort to our travel?
    -
    -
    CELIA
    -
    -
    He'll go along o'er the wide world with me;
    -
    Leave me alone to woo him. Let's away,
    -
    And get our jewels and our wealth together,
    -
    Devise the fittest time and safest way
    -
    To hide us from pursuit that will be made
    -
    After my flight. Now go we in content
    -
    To liberty and not to banishment.
    -
    Exeunt
    -
    -
    -
    -
    - - diff --git a/vendor/symfony/css-selector/Tests/XPath/TranslatorTest.php b/vendor/symfony/css-selector/Tests/XPath/TranslatorTest.php deleted file mode 100644 index 143328f41..000000000 --- a/vendor/symfony/css-selector/Tests/XPath/TranslatorTest.php +++ /dev/null @@ -1,324 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\CssSelector\Tests\XPath; - -use Symfony\Component\CssSelector\XPath\Extension\HtmlExtension; -use Symfony\Component\CssSelector\XPath\Translator; - -class TranslatorTest extends \PHPUnit_Framework_TestCase -{ - /** @dataProvider getXpathLiteralTestData */ - public function testXpathLiteral($value, $literal) - { - $this->assertEquals($literal, Translator::getXpathLiteral($value)); - } - - /** @dataProvider getCssToXPathTestData */ - public function testCssToXPath($css, $xpath) - { - $translator = new Translator(); - $translator->registerExtension(new HtmlExtension($translator)); - $this->assertEquals($xpath, $translator->cssToXPath($css, '')); - } - - /** @dataProvider getXmlLangTestData */ - public function testXmlLang($css, array $elementsId) - { - $translator = new Translator(); - $document = new \SimpleXMLElement(file_get_contents(__DIR__.'/Fixtures/lang.xml')); - $elements = $document->xpath($translator->cssToXPath($css)); - $this->assertEquals(count($elementsId), count($elements)); - foreach ($elements as $element) { - $this->assertTrue(in_array($element->attributes()->id, $elementsId)); - } - } - - /** @dataProvider getHtmlIdsTestData */ - public function testHtmlIds($css, array $elementsId) - { - $translator = new Translator(); - $translator->registerExtension(new HtmlExtension($translator)); - $document = new \DOMDocument(); - $document->strictErrorChecking = false; - $internalErrors = libxml_use_internal_errors(true); - $document->loadHTMLFile(__DIR__.'/Fixtures/ids.html'); - $document = simplexml_import_dom($document); - $elements = $document->xpath($translator->cssToXPath($css)); - $this->assertCount(count($elementsId), $elementsId); - foreach ($elements as $element) { - if (null !== $element->attributes()->id) { - $this->assertTrue(in_array($element->attributes()->id, $elementsId)); - } - } - libxml_clear_errors(); - libxml_use_internal_errors($internalErrors); - } - - /** @dataProvider getHtmlShakespearTestData */ - public function testHtmlShakespear($css, $count) - { - $translator = new Translator(); - $translator->registerExtension(new HtmlExtension($translator)); - $document = new \DOMDocument(); - $document->strictErrorChecking = false; - $document->loadHTMLFile(__DIR__.'/Fixtures/shakespear.html'); - $document = simplexml_import_dom($document); - $bodies = $document->xpath('//body'); - $elements = $bodies[0]->xpath($translator->cssToXPath($css)); - $this->assertEquals($count, count($elements)); - } - - public function getXpathLiteralTestData() - { - return array( - array('foo', "'foo'"), - array("foo's bar", '"foo\'s bar"'), - array("foo's \"middle\" bar", 'concat(\'foo\', "\'", \'s "middle" bar\')'), - array("foo's 'middle' \"bar\"", 'concat(\'foo\', "\'", \'s \', "\'", \'middle\', "\'", \' "bar"\')'), - ); - } - - public function getCssToXPathTestData() - { - return array( - array('*', '*'), - array('e', 'e'), - array('*|e', 'e'), - array('e|f', 'e:f'), - array('e[foo]', 'e[@foo]'), - array('e[foo|bar]', 'e[@foo:bar]'), - array('e[foo="bar"]', "e[@foo = 'bar']"), - array('e[foo~="bar"]', "e[@foo and contains(concat(' ', normalize-space(@foo), ' '), ' bar ')]"), - array('e[foo^="bar"]', "e[@foo and starts-with(@foo, 'bar')]"), - array('e[foo$="bar"]', "e[@foo and substring(@foo, string-length(@foo)-2) = 'bar']"), - array('e[foo*="bar"]', "e[@foo and contains(@foo, 'bar')]"), - array('e[hreflang|="en"]', "e[@hreflang and (@hreflang = 'en' or starts-with(@hreflang, 'en-'))]"), - array('e:nth-child(1)', "*/*[name() = 'e' and (position() = 1)]"), - array('e:nth-last-child(1)', "*/*[name() = 'e' and (position() = last() - 0)]"), - array('e:nth-last-child(2n+2)', "*/*[name() = 'e' and (last() - position() - 1 >= 0 and (last() - position() - 1) mod 2 = 0)]"), - array('e:nth-of-type(1)', '*/e[position() = 1]'), - array('e:nth-last-of-type(1)', '*/e[position() = last() - 0]'), - array('div e:nth-last-of-type(1) .aclass', "div/descendant-or-self::*/e[position() = last() - 0]/descendant-or-self::*/*[@class and contains(concat(' ', normalize-space(@class), ' '), ' aclass ')]"), - array('e:first-child', "*/*[name() = 'e' and (position() = 1)]"), - array('e:last-child', "*/*[name() = 'e' and (position() = last())]"), - array('e:first-of-type', '*/e[position() = 1]'), - array('e:last-of-type', '*/e[position() = last()]'), - array('e:only-child', "*/*[name() = 'e' and (last() = 1)]"), - array('e:only-of-type', 'e[last() = 1]'), - array('e:empty', 'e[not(*) and not(string-length())]'), - array('e:EmPTY', 'e[not(*) and not(string-length())]'), - array('e:root', 'e[not(parent::*)]'), - array('e:hover', 'e[0]'), - array('e:contains("foo")', "e[contains(string(.), 'foo')]"), - array('e:ConTains(foo)', "e[contains(string(.), 'foo')]"), - array('e.warning', "e[@class and contains(concat(' ', normalize-space(@class), ' '), ' warning ')]"), - array('e#myid', "e[@id = 'myid']"), - array('e:not(:nth-child(odd))', 'e[not(position() - 1 >= 0 and (position() - 1) mod 2 = 0)]'), - array('e:nOT(*)', 'e[0]'), - array('e f', 'e/descendant-or-self::*/f'), - array('e > f', 'e/f'), - array('e + f', "e/following-sibling::*[name() = 'f' and (position() = 1)]"), - array('e ~ f', 'e/following-sibling::f'), - array('div#container p', "div[@id = 'container']/descendant-or-self::*/p"), - ); - } - - public function getXmlLangTestData() - { - return array( - array(':lang("EN")', array('first', 'second', 'third', 'fourth')), - array(':lang("en-us")', array('second', 'fourth')), - array(':lang(en-nz)', array('third')), - array(':lang(fr)', array('fifth')), - array(':lang(ru)', array('sixth')), - array(":lang('ZH')", array('eighth')), - array(':lang(de) :lang(zh)', array('eighth')), - array(':lang(en), :lang(zh)', array('first', 'second', 'third', 'fourth', 'eighth')), - array(':lang(es)', array()), - ); - } - - public function getHtmlIdsTestData() - { - return array( - array('div', array('outer-div', 'li-div', 'foobar-div')), - array('DIV', array('outer-div', 'li-div', 'foobar-div')), // case-insensitive in HTML - array('div div', array('li-div')), - array('div, div div', array('outer-div', 'li-div', 'foobar-div')), - array('a[name]', array('name-anchor')), - array('a[NAme]', array('name-anchor')), // case-insensitive in HTML: - array('a[rel]', array('tag-anchor', 'nofollow-anchor')), - array('a[rel="tag"]', array('tag-anchor')), - array('a[href*="localhost"]', array('tag-anchor')), - array('a[href*=""]', array()), - array('a[href^="http"]', array('tag-anchor', 'nofollow-anchor')), - array('a[href^="http:"]', array('tag-anchor')), - array('a[href^=""]', array()), - array('a[href$="org"]', array('nofollow-anchor')), - array('a[href$=""]', array()), - array('div[foobar~="bc"]', array('foobar-div')), - array('div[foobar~="cde"]', array('foobar-div')), - array('[foobar~="ab bc"]', array('foobar-div')), - array('[foobar~=""]', array()), - array('[foobar~=" \t"]', array()), - array('div[foobar~="cd"]', array()), - array('*[lang|="En"]', array('second-li')), - array('[lang|="En-us"]', array('second-li')), - // Attribute values are case sensitive - array('*[lang|="en"]', array()), - array('[lang|="en-US"]', array()), - array('*[lang|="e"]', array()), - // ... :lang() is not. - array(':lang("EN")', array('second-li', 'li-div')), - array('*:lang(en-US)', array('second-li', 'li-div')), - array(':lang("e")', array()), - array('li:nth-child(3)', array('third-li')), - array('li:nth-child(10)', array()), - array('li:nth-child(2n)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-child(even)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-child(2n+0)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-child(+2n+1)', array('first-li', 'third-li', 'fifth-li', 'seventh-li')), - array('li:nth-child(odd)', array('first-li', 'third-li', 'fifth-li', 'seventh-li')), - array('li:nth-child(2n+4)', array('fourth-li', 'sixth-li')), - array('li:nth-child(3n+1)', array('first-li', 'fourth-li', 'seventh-li')), - array('li:nth-child(n)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-child(n-1)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-child(n+1)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-child(n+3)', array('third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-child(-n)', array()), - array('li:nth-child(-n-1)', array()), - array('li:nth-child(-n+1)', array('first-li')), - array('li:nth-child(-n+3)', array('first-li', 'second-li', 'third-li')), - array('li:nth-last-child(0)', array()), - array('li:nth-last-child(2n)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-last-child(even)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-last-child(2n+2)', array('second-li', 'fourth-li', 'sixth-li')), - array('li:nth-last-child(n)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-last-child(n-1)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-last-child(n-3)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-last-child(n+1)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li', 'sixth-li', 'seventh-li')), - array('li:nth-last-child(n+3)', array('first-li', 'second-li', 'third-li', 'fourth-li', 'fifth-li')), - array('li:nth-last-child(-n)', array()), - array('li:nth-last-child(-n-1)', array()), - array('li:nth-last-child(-n+1)', array('seventh-li')), - array('li:nth-last-child(-n+3)', array('fifth-li', 'sixth-li', 'seventh-li')), - array('ol:first-of-type', array('first-ol')), - array('ol:nth-child(1)', array('first-ol')), - array('ol:nth-of-type(2)', array('second-ol')), - array('ol:nth-last-of-type(1)', array('second-ol')), - array('span:only-child', array('foobar-span')), - array('li div:only-child', array('li-div')), - array('div *:only-child', array('li-div', 'foobar-span')), - array('p:only-of-type', array('paragraph')), - array('a:empty', array('name-anchor')), - array('a:EMpty', array('name-anchor')), - array('li:empty', array('third-li', 'fourth-li', 'fifth-li', 'sixth-li')), - array(':root', array('html')), - array('html:root', array('html')), - array('li:root', array()), - array('* :root', array()), - array('*:contains("link")', array('html', 'outer-div', 'tag-anchor', 'nofollow-anchor')), - array(':CONtains("link")', array('html', 'outer-div', 'tag-anchor', 'nofollow-anchor')), - array('*:contains("LInk")', array()), // case sensitive - array('*:contains("e")', array('html', 'nil', 'outer-div', 'first-ol', 'first-li', 'paragraph', 'p-em')), - array('*:contains("E")', array()), // case-sensitive - array('.a', array('first-ol')), - array('.b', array('first-ol')), - array('*.a', array('first-ol')), - array('ol.a', array('first-ol')), - array('.c', array('first-ol', 'third-li', 'fourth-li')), - array('*.c', array('first-ol', 'third-li', 'fourth-li')), - array('ol *.c', array('third-li', 'fourth-li')), - array('ol li.c', array('third-li', 'fourth-li')), - array('li ~ li.c', array('third-li', 'fourth-li')), - array('ol > li.c', array('third-li', 'fourth-li')), - array('#first-li', array('first-li')), - array('li#first-li', array('first-li')), - array('*#first-li', array('first-li')), - array('li div', array('li-div')), - array('li > div', array('li-div')), - array('div div', array('li-div')), - array('div > div', array()), - array('div>.c', array('first-ol')), - array('div > .c', array('first-ol')), - array('div + div', array('foobar-div')), - array('a ~ a', array('tag-anchor', 'nofollow-anchor')), - array('a[rel="tag"] ~ a', array('nofollow-anchor')), - array('ol#first-ol li:last-child', array('seventh-li')), - array('ol#first-ol *:last-child', array('li-div', 'seventh-li')), - array('#outer-div:first-child', array('outer-div')), - array('#outer-div :first-child', array('name-anchor', 'first-li', 'li-div', 'p-b', 'checkbox-fieldset-disabled', 'area-href')), - array('a[href]', array('tag-anchor', 'nofollow-anchor')), - array(':not(*)', array()), - array('a:not([href])', array('name-anchor')), - array('ol :Not(li[class])', array('first-li', 'second-li', 'li-div', 'fifth-li', 'sixth-li', 'seventh-li')), - // HTML-specific - array(':link', array('link-href', 'tag-anchor', 'nofollow-anchor', 'area-href')), - array(':visited', array()), - array(':enabled', array('link-href', 'tag-anchor', 'nofollow-anchor', 'checkbox-unchecked', 'text-checked', 'checkbox-checked', 'area-href')), - array(':disabled', array('checkbox-disabled', 'checkbox-disabled-checked', 'fieldset', 'checkbox-fieldset-disabled')), - array(':checked', array('checkbox-checked', 'checkbox-disabled-checked')), - ); - } - - public function getHtmlShakespearTestData() - { - return array( - array('*', 246), - array('div:contains(CELIA)', 26), - array('div:only-child', 22), // ? - array('div:nth-child(even)', 106), - array('div:nth-child(2n)', 106), - array('div:nth-child(odd)', 137), - array('div:nth-child(2n+1)', 137), - array('div:nth-child(n)', 243), - array('div:last-child', 53), - array('div:first-child', 51), - array('div > div', 242), - array('div + div', 190), - array('div ~ div', 190), - array('body', 1), - array('body div', 243), - array('div', 243), - array('div div', 242), - array('div div div', 241), - array('div, div, div', 243), - array('div, a, span', 243), - array('.dialog', 51), - array('div.dialog', 51), - array('div .dialog', 51), - array('div.character, div.dialog', 99), - array('div.direction.dialog', 0), - array('div.dialog.direction', 0), - array('div.dialog.scene', 1), - array('div.scene.scene', 1), - array('div.scene .scene', 0), - array('div.direction .dialog ', 0), - array('div .dialog .direction', 4), - array('div.dialog .dialog .direction', 4), - array('#speech5', 1), - array('div#speech5', 1), - array('div #speech5', 1), - array('div.scene div.dialog', 49), - array('div#scene1 div.dialog div', 142), - array('#scene1 #speech1', 1), - array('div[class]', 103), - array('div[class=dialog]', 50), - array('div[class^=dia]', 51), - array('div[class$=log]', 50), - array('div[class*=sce]', 1), - array('div[class|=dialog]', 50), // ? Seems right - array('div[class!=madeup]', 243), // ? Seems right - array('div[class~=dialog]', 51), // ? Seems right - ); - } -} diff --git a/vendor/symfony/debug/Tests/DebugClassLoaderTest.php b/vendor/symfony/debug/Tests/DebugClassLoaderTest.php deleted file mode 100644 index 1516dbedf..000000000 --- a/vendor/symfony/debug/Tests/DebugClassLoaderTest.php +++ /dev/null @@ -1,296 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests; - -use Symfony\Component\Debug\DebugClassLoader; -use Symfony\Component\Debug\ErrorHandler; -use Symfony\Component\Debug\Exception\ContextErrorException; - -class DebugClassLoaderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @var int Error reporting level before running tests. - */ - private $errorReporting; - - private $loader; - - protected function setUp() - { - $this->errorReporting = error_reporting(E_ALL | E_STRICT); - $this->loader = new ClassLoader(); - spl_autoload_register(array($this->loader, 'loadClass'), true, true); - DebugClassLoader::enable(); - } - - protected function tearDown() - { - DebugClassLoader::disable(); - spl_autoload_unregister(array($this->loader, 'loadClass')); - error_reporting($this->errorReporting); - } - - public function testIdempotence() - { - DebugClassLoader::enable(); - - $functions = spl_autoload_functions(); - foreach ($functions as $function) { - if (is_array($function) && $function[0] instanceof DebugClassLoader) { - $reflClass = new \ReflectionClass($function[0]); - $reflProp = $reflClass->getProperty('classLoader'); - $reflProp->setAccessible(true); - - $this->assertNotInstanceOf('Symfony\Component\Debug\DebugClassLoader', $reflProp->getValue($function[0])); - - return; - } - } - - $this->fail('DebugClassLoader did not register'); - } - - public function testUnsilencing() - { - if (PHP_VERSION_ID >= 70000) { - $this->markTestSkipped('PHP7 throws exceptions, unsilencing is not required anymore.'); - } - if (defined('HHVM_VERSION')) { - $this->markTestSkipped('HHVM is not handled in this test case.'); - } - - ob_start(); - - $this->iniSet('log_errors', 0); - $this->iniSet('display_errors', 1); - - // See below: this will fail with parse error - // but this should not be @-silenced. - @class_exists(__NAMESPACE__.'\TestingUnsilencing', true); - - $output = ob_get_clean(); - - $this->assertStringMatchesFormat('%aParse error%a', $output); - } - - public function testStacking() - { - // the ContextErrorException must not be loaded to test the workaround - // for https://bugs.php.net/65322. - if (class_exists('Symfony\Component\Debug\Exception\ContextErrorException', false)) { - $this->markTestSkipped('The ContextErrorException class is already loaded.'); - } - if (defined('HHVM_VERSION')) { - $this->markTestSkipped('HHVM is not handled in this test case.'); - } - - ErrorHandler::register(); - - try { - // Trigger autoloading + E_STRICT at compile time - // which in turn triggers $errorHandler->handle() - // that again triggers autoloading for ContextErrorException. - // Error stacking works around the bug above and everything is fine. - - eval(' - namespace '.__NAMESPACE__.'; - class ChildTestingStacking extends TestingStacking { function foo($bar) {} } - '); - $this->fail('ContextErrorException expected'); - } catch (\ErrorException $exception) { - // if an exception is thrown, the test passed - restore_error_handler(); - restore_exception_handler(); - $this->assertStringStartsWith(__FILE__, $exception->getFile()); - if (PHP_VERSION_ID < 70000) { - $this->assertRegExp('/^Runtime Notice: Declaration/', $exception->getMessage()); - $this->assertEquals(E_STRICT, $exception->getSeverity()); - } else { - $this->assertRegExp('/^Warning: Declaration/', $exception->getMessage()); - $this->assertEquals(E_WARNING, $exception->getSeverity()); - } - } catch (\Exception $exception) { - restore_error_handler(); - restore_exception_handler(); - - throw $exception; - } - } - - /** - * @expectedException \RuntimeException - */ - public function testNameCaseMismatch() - { - class_exists(__NAMESPACE__.'\TestingCaseMismatch', true); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Case mismatch between class and real file names - */ - public function testFileCaseMismatch() - { - if (!file_exists(__DIR__.'/Fixtures/CaseMismatch.php')) { - $this->markTestSkipped('Can only be run on case insensitive filesystems'); - } - - class_exists(__NAMESPACE__.'\Fixtures\CaseMismatch', true); - } - - /** - * @expectedException \RuntimeException - */ - public function testPsr4CaseMismatch() - { - class_exists(__NAMESPACE__.'\Fixtures\Psr4CaseMismatch', true); - } - - public function testNotPsr0() - { - $this->assertTrue(class_exists(__NAMESPACE__.'\Fixtures\NotPSR0', true)); - } - - public function testNotPsr0Bis() - { - $this->assertTrue(class_exists(__NAMESPACE__.'\Fixtures\NotPSR0bis', true)); - } - - public function testClassAlias() - { - $this->assertTrue(class_exists(__NAMESPACE__.'\Fixtures\ClassAlias', true)); - } - - /** - * @dataProvider provideDeprecatedSuper - */ - public function testDeprecatedSuper($class, $super, $type) - { - set_error_handler('var_dump', 0); - $e = error_reporting(0); - trigger_error('', E_USER_DEPRECATED); - - class_exists('Test\\'.__NAMESPACE__.'\\'.$class, true); - - error_reporting($e); - restore_error_handler(); - - $lastError = error_get_last(); - unset($lastError['file'], $lastError['line']); - - $xError = array( - 'type' => E_USER_DEPRECATED, - 'message' => 'The Test\Symfony\Component\Debug\Tests\\'.$class.' class '.$type.' Symfony\Component\Debug\Tests\Fixtures\\'.$super.' that is deprecated but this is a test deprecation notice.', - ); - - $this->assertSame($xError, $lastError); - } - - public function provideDeprecatedSuper() - { - return array( - array('DeprecatedInterfaceClass', 'DeprecatedInterface', 'implements'), - array('DeprecatedParentClass', 'DeprecatedClass', 'extends'), - ); - } - - public function testDeprecatedSuperInSameNamespace() - { - set_error_handler('var_dump', 0); - $e = error_reporting(0); - trigger_error('', E_USER_NOTICE); - - class_exists('Symfony\Bridge\Debug\Tests\Fixtures\ExtendsDeprecatedParent', true); - - error_reporting($e); - restore_error_handler(); - - $lastError = error_get_last(); - unset($lastError['file'], $lastError['line']); - - $xError = array( - 'type' => E_USER_NOTICE, - 'message' => '', - ); - - $this->assertSame($xError, $lastError); - } - - public function testReservedForPhp7() - { - if (PHP_VERSION_ID >= 70000) { - $this->markTestSkipped('PHP7 already prevents using reserved names.'); - } - - set_error_handler('var_dump', 0); - $e = error_reporting(0); - trigger_error('', E_USER_NOTICE); - - class_exists('Test\\'.__NAMESPACE__.'\\Float', true); - - error_reporting($e); - restore_error_handler(); - - $lastError = error_get_last(); - unset($lastError['file'], $lastError['line']); - - $xError = array( - 'type' => E_USER_DEPRECATED, - 'message' => 'Test\Symfony\Component\Debug\Tests\Float uses a reserved class name (Float) that will break on PHP 7 and higher', - ); - - $this->assertSame($xError, $lastError); - } -} - -class ClassLoader -{ - public function loadClass($class) - { - } - - public function getClassMap() - { - return array(__NAMESPACE__.'\Fixtures\NotPSR0bis' => __DIR__.'/Fixtures/notPsr0Bis.php'); - } - - public function findFile($class) - { - $fixtureDir = __DIR__.DIRECTORY_SEPARATOR.'Fixtures'.DIRECTORY_SEPARATOR; - - if (__NAMESPACE__.'\TestingUnsilencing' === $class) { - eval('-- parse error --'); - } elseif (__NAMESPACE__.'\TestingStacking' === $class) { - eval('namespace '.__NAMESPACE__.'; class TestingStacking { function foo() {} }'); - } elseif (__NAMESPACE__.'\TestingCaseMismatch' === $class) { - eval('namespace '.__NAMESPACE__.'; class TestingCaseMisMatch {}'); - } elseif (__NAMESPACE__.'\Fixtures\CaseMismatch' === $class) { - return $fixtureDir.'CaseMismatch.php'; - } elseif (__NAMESPACE__.'\Fixtures\Psr4CaseMismatch' === $class) { - return $fixtureDir.'psr4'.DIRECTORY_SEPARATOR.'Psr4CaseMismatch.php'; - } elseif (__NAMESPACE__.'\Fixtures\NotPSR0' === $class) { - return $fixtureDir.'reallyNotPsr0.php'; - } elseif (__NAMESPACE__.'\Fixtures\NotPSR0bis' === $class) { - return $fixtureDir.'notPsr0Bis.php'; - } elseif (__NAMESPACE__.'\Fixtures\DeprecatedInterface' === $class) { - return $fixtureDir.'DeprecatedInterface.php'; - } elseif ('Symfony\Bridge\Debug\Tests\Fixtures\ExtendsDeprecatedParent' === $class) { - eval('namespace Symfony\Bridge\Debug\Tests\Fixtures; class ExtendsDeprecatedParent extends \\'.__NAMESPACE__.'\Fixtures\DeprecatedClass {}'); - } elseif ('Test\\'.__NAMESPACE__.'\DeprecatedParentClass' === $class) { - eval('namespace Test\\'.__NAMESPACE__.'; class DeprecatedParentClass extends \\'.__NAMESPACE__.'\Fixtures\DeprecatedClass {}'); - } elseif ('Test\\'.__NAMESPACE__.'\DeprecatedInterfaceClass' === $class) { - eval('namespace Test\\'.__NAMESPACE__.'; class DeprecatedInterfaceClass implements \\'.__NAMESPACE__.'\Fixtures\DeprecatedInterface {}'); - } elseif ('Test\\'.__NAMESPACE__.'\Float' === $class) { - eval('namespace Test\\'.__NAMESPACE__.'; class Float {}'); - } - } -} diff --git a/vendor/symfony/debug/Tests/ErrorHandlerTest.php b/vendor/symfony/debug/Tests/ErrorHandlerTest.php deleted file mode 100644 index c107c0c7c..000000000 --- a/vendor/symfony/debug/Tests/ErrorHandlerTest.php +++ /dev/null @@ -1,503 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests; - -use Psr\Log\LogLevel; -use Symfony\Component\Debug\ErrorHandler; -use Symfony\Component\Debug\Exception\ContextErrorException; - -/** - * ErrorHandlerTest. - * - * @author Robert Schönthal - * @author Nicolas Grekas - */ -class ErrorHandlerTest extends \PHPUnit_Framework_TestCase -{ - public function testRegister() - { - $handler = ErrorHandler::register(); - - try { - $this->assertInstanceOf('Symfony\Component\Debug\ErrorHandler', $handler); - $this->assertSame($handler, ErrorHandler::register()); - - $newHandler = new ErrorHandler(); - - $this->assertSame($newHandler, ErrorHandler::register($newHandler, false)); - $h = set_error_handler('var_dump'); - restore_error_handler(); - $this->assertSame(array($handler, 'handleError'), $h); - - try { - $this->assertSame($newHandler, ErrorHandler::register($newHandler, true)); - $h = set_error_handler('var_dump'); - restore_error_handler(); - $this->assertSame(array($newHandler, 'handleError'), $h); - } catch (\Exception $e) { - } - - restore_error_handler(); - restore_exception_handler(); - - if (isset($e)) { - throw $e; - } - } catch (\Exception $e) { - } - - restore_error_handler(); - restore_exception_handler(); - - if (isset($e)) { - throw $e; - } - } - - public function testNotice() - { - ErrorHandler::register(); - - try { - self::triggerNotice($this); - $this->fail('ContextErrorException expected'); - } catch (ContextErrorException $exception) { - // if an exception is thrown, the test passed - restore_error_handler(); - restore_exception_handler(); - - $this->assertEquals(E_NOTICE, $exception->getSeverity()); - $this->assertEquals(__FILE__, $exception->getFile()); - $this->assertRegExp('/^Notice: Undefined variable: (foo|bar)/', $exception->getMessage()); - $this->assertArrayHasKey('foobar', $exception->getContext()); - - $trace = $exception->getTrace(); - $this->assertEquals(__FILE__, $trace[0]['file']); - $this->assertEquals('Symfony\Component\Debug\ErrorHandler', $trace[0]['class']); - $this->assertEquals('handleError', $trace[0]['function']); - $this->assertEquals('->', $trace[0]['type']); - - $this->assertEquals(__FILE__, $trace[1]['file']); - $this->assertEquals(__CLASS__, $trace[1]['class']); - $this->assertEquals('triggerNotice', $trace[1]['function']); - $this->assertEquals('::', $trace[1]['type']); - - $this->assertEquals(__FILE__, $trace[1]['file']); - $this->assertEquals(__CLASS__, $trace[2]['class']); - $this->assertEquals(__FUNCTION__, $trace[2]['function']); - $this->assertEquals('->', $trace[2]['type']); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - // dummy function to test trace in error handler. - private static function triggerNotice($that) - { - // dummy variable to check for in error handler. - $foobar = 123; - $that->assertSame('', $foo.$foo.$bar); - } - - public function testConstruct() - { - try { - $handler = ErrorHandler::register(); - $handler->throwAt(3, true); - $this->assertEquals(3 | E_RECOVERABLE_ERROR | E_USER_ERROR, $handler->throwAt(0)); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testDefaultLogger() - { - try { - $handler = ErrorHandler::register(); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $handler->setDefaultLogger($logger, E_NOTICE); - $handler->setDefaultLogger($logger, array(E_USER_NOTICE => LogLevel::CRITICAL)); - - $loggers = array( - E_DEPRECATED => array(null, LogLevel::INFO), - E_USER_DEPRECATED => array(null, LogLevel::INFO), - E_NOTICE => array($logger, LogLevel::WARNING), - E_USER_NOTICE => array($logger, LogLevel::CRITICAL), - E_STRICT => array(null, LogLevel::WARNING), - E_WARNING => array(null, LogLevel::WARNING), - E_USER_WARNING => array(null, LogLevel::WARNING), - E_COMPILE_WARNING => array(null, LogLevel::WARNING), - E_CORE_WARNING => array(null, LogLevel::WARNING), - E_USER_ERROR => array(null, LogLevel::CRITICAL), - E_RECOVERABLE_ERROR => array(null, LogLevel::CRITICAL), - E_COMPILE_ERROR => array(null, LogLevel::CRITICAL), - E_PARSE => array(null, LogLevel::CRITICAL), - E_ERROR => array(null, LogLevel::CRITICAL), - E_CORE_ERROR => array(null, LogLevel::CRITICAL), - ); - $this->assertSame($loggers, $handler->setLoggers(array())); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testHandleError() - { - try { - $handler = ErrorHandler::register(); - $handler->throwAt(0, true); - $this->assertFalse($handler->handleError(0, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $handler = ErrorHandler::register(); - $handler->throwAt(3, true); - $this->assertFalse($handler->handleError(4, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $handler = ErrorHandler::register(); - $handler->throwAt(3, true); - try { - $handler->handleError(4, 'foo', 'foo.php', 12, array()); - } catch (\ErrorException $e) { - $this->assertSame('Parse Error: foo', $e->getMessage()); - $this->assertSame(4, $e->getSeverity()); - $this->assertSame('foo.php', $e->getFile()); - $this->assertSame(12, $e->getLine()); - } - - restore_error_handler(); - restore_exception_handler(); - - $handler = ErrorHandler::register(); - $handler->throwAt(E_USER_DEPRECATED, true); - $this->assertFalse($handler->handleError(E_USER_DEPRECATED, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $handler = ErrorHandler::register(); - $handler->throwAt(E_DEPRECATED, true); - $this->assertFalse($handler->handleError(E_DEPRECATED, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $that = $this; - $warnArgCheck = function ($logLevel, $message, $context) use ($that) { - $that->assertEquals('info', $logLevel); - $that->assertEquals('foo', $message); - $that->assertArrayHasKey('type', $context); - $that->assertEquals($context['type'], E_USER_DEPRECATED); - $that->assertArrayHasKey('stack', $context); - $that->assertInternalType('array', $context['stack']); - }; - - $logger - ->expects($this->once()) - ->method('log') - ->will($this->returnCallback($warnArgCheck)) - ; - - $handler = ErrorHandler::register(); - $handler->setDefaultLogger($logger, E_USER_DEPRECATED); - $this->assertTrue($handler->handleError(E_USER_DEPRECATED, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $that = $this; - $logArgCheck = function ($level, $message, $context) use ($that) { - $that->assertEquals('Undefined variable: undefVar', $message); - $that->assertArrayHasKey('type', $context); - $that->assertEquals($context['type'], E_NOTICE); - }; - - $logger - ->expects($this->once()) - ->method('log') - ->will($this->returnCallback($logArgCheck)) - ; - - $handler = ErrorHandler::register(); - $handler->setDefaultLogger($logger, E_NOTICE); - $handler->screamAt(E_NOTICE); - unset($undefVar); - @$undefVar++; - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testHandleDeprecation() - { - $that = $this; - $logArgCheck = function ($level, $message, $context) use ($that) { - $that->assertEquals(LogLevel::INFO, $level); - $that->assertArrayHasKey('level', $context); - $that->assertEquals(E_RECOVERABLE_ERROR | E_USER_ERROR | E_DEPRECATED | E_USER_DEPRECATED, $context['level']); - $that->assertArrayHasKey('stack', $context); - }; - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - $logger - ->expects($this->once()) - ->method('log') - ->will($this->returnCallback($logArgCheck)) - ; - - $handler = new ErrorHandler(); - $handler->setDefaultLogger($logger); - @$handler->handleError(E_USER_DEPRECATED, 'Foo deprecation', __FILE__, __LINE__, array()); - } - - public function testHandleException() - { - try { - $handler = ErrorHandler::register(); - - $exception = new \Exception('foo'); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $that = $this; - $logArgCheck = function ($level, $message, $context) use ($that) { - $that->assertEquals('Uncaught Exception: foo', $message); - $that->assertArrayHasKey('type', $context); - $that->assertEquals($context['type'], E_ERROR); - }; - - $logger - ->expects($this->exactly(2)) - ->method('log') - ->will($this->returnCallback($logArgCheck)) - ; - - $handler->setDefaultLogger($logger, E_ERROR); - - try { - $handler->handleException($exception); - $this->fail('Exception expected'); - } catch (\Exception $e) { - $this->assertSame($exception, $e); - } - - $that = $this; - $handler->setExceptionHandler(function ($e) use ($exception, $that) { - $that->assertSame($exception, $e); - }); - - $handler->handleException($exception); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testErrorStacking() - { - try { - $handler = ErrorHandler::register(); - $handler->screamAt(E_USER_WARNING); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $logger - ->expects($this->exactly(2)) - ->method('log') - ->withConsecutive( - array($this->equalTo(LogLevel::WARNING), $this->equalTo('Dummy log')), - array($this->equalTo(LogLevel::DEBUG), $this->equalTo('Silenced warning')) - ) - ; - - $handler->setDefaultLogger($logger, array(E_USER_WARNING => LogLevel::WARNING)); - - ErrorHandler::stackErrors(); - @trigger_error('Silenced warning', E_USER_WARNING); - $logger->log(LogLevel::WARNING, 'Dummy log'); - ErrorHandler::unstackErrors(); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testHandleFatalError() - { - try { - $handler = ErrorHandler::register(); - - $error = array( - 'type' => E_PARSE, - 'message' => 'foo', - 'file' => 'bar', - 'line' => 123, - ); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $that = $this; - $logArgCheck = function ($level, $message, $context) use ($that) { - $that->assertEquals('Fatal Parse Error: foo', $message); - $that->assertArrayHasKey('type', $context); - $that->assertEquals($context['type'], E_PARSE); - }; - - $logger - ->expects($this->once()) - ->method('log') - ->will($this->returnCallback($logArgCheck)) - ; - - $handler->setDefaultLogger($logger, E_PARSE); - - $handler->handleFatalError($error); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - public function testHandleFatalErrorOnHHVM() - { - try { - $handler = ErrorHandler::register(); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - $logger - ->expects($this->once()) - ->method('log') - ->with( - $this->equalTo(LogLevel::CRITICAL), - $this->equalTo('Fatal Error: foo'), - $this->equalTo(array( - 'type' => 1, - 'file' => 'bar', - 'line' => 123, - 'level' => -1, - 'stack' => array(456), - )) - ) - ; - - $handler->setDefaultLogger($logger, E_ERROR); - - $error = array( - 'type' => E_ERROR + 0x1000000, // This error level is used by HHVM for fatal errors - 'message' => 'foo', - 'file' => 'bar', - 'line' => 123, - 'context' => array(123), - 'backtrace' => array(456), - ); - - call_user_func_array(array($handler, 'handleError'), $error); - $handler->handleFatalError($error); - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } - - /** - * @group legacy - */ - public function testLegacyInterface() - { - try { - $handler = ErrorHandler::register(0); - $this->assertFalse($handler->handle(0, 'foo', 'foo.php', 12, array())); - - restore_error_handler(); - restore_exception_handler(); - - $logger = $this->getMock('Psr\Log\LoggerInterface'); - - $that = $this; - $logArgCheck = function ($level, $message, $context) use ($that) { - $that->assertEquals('Undefined variable: undefVar', $message); - $that->assertArrayHasKey('type', $context); - $that->assertEquals($context['type'], E_NOTICE); - }; - - $logger - ->expects($this->once()) - ->method('log') - ->will($this->returnCallback($logArgCheck)) - ; - - $handler = ErrorHandler::register(E_NOTICE); - @$handler->setLogger($logger, 'scream'); - unset($undefVar); - @$undefVar++; - - restore_error_handler(); - restore_exception_handler(); - } catch (\Exception $e) { - restore_error_handler(); - restore_exception_handler(); - - throw $e; - } - } -} diff --git a/vendor/symfony/debug/Tests/Exception/FlattenExceptionTest.php b/vendor/symfony/debug/Tests/Exception/FlattenExceptionTest.php deleted file mode 100644 index 99eaf497d..000000000 --- a/vendor/symfony/debug/Tests/Exception/FlattenExceptionTest.php +++ /dev/null @@ -1,256 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests\Exception; - -use Symfony\Component\Debug\Exception\FlattenException; -use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; -use Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException; -use Symfony\Component\HttpKernel\Exception\UnauthorizedHttpException; -use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; -use Symfony\Component\HttpKernel\Exception\NotAcceptableHttpException; -use Symfony\Component\HttpKernel\Exception\ConflictHttpException; -use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; -use Symfony\Component\HttpKernel\Exception\GoneHttpException; -use Symfony\Component\HttpKernel\Exception\LengthRequiredHttpException; -use Symfony\Component\HttpKernel\Exception\PreconditionFailedHttpException; -use Symfony\Component\HttpKernel\Exception\PreconditionRequiredHttpException; -use Symfony\Component\HttpKernel\Exception\ServiceUnavailableHttpException; -use Symfony\Component\HttpKernel\Exception\TooManyRequestsHttpException; -use Symfony\Component\HttpKernel\Exception\UnsupportedMediaTypeHttpException; - -class FlattenExceptionTest extends \PHPUnit_Framework_TestCase -{ - public function testStatusCode() - { - $flattened = FlattenException::create(new \RuntimeException(), 403); - $this->assertEquals('403', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new \RuntimeException()); - $this->assertEquals('500', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new NotFoundHttpException()); - $this->assertEquals('404', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new UnauthorizedHttpException('Basic realm="My Realm"')); - $this->assertEquals('401', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new BadRequestHttpException()); - $this->assertEquals('400', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new NotAcceptableHttpException()); - $this->assertEquals('406', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new ConflictHttpException()); - $this->assertEquals('409', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new MethodNotAllowedHttpException(array('POST'))); - $this->assertEquals('405', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new AccessDeniedHttpException()); - $this->assertEquals('403', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new GoneHttpException()); - $this->assertEquals('410', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new LengthRequiredHttpException()); - $this->assertEquals('411', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new PreconditionFailedHttpException()); - $this->assertEquals('412', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new PreconditionRequiredHttpException()); - $this->assertEquals('428', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new ServiceUnavailableHttpException()); - $this->assertEquals('503', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new TooManyRequestsHttpException()); - $this->assertEquals('429', $flattened->getStatusCode()); - - $flattened = FlattenException::create(new UnsupportedMediaTypeHttpException()); - $this->assertEquals('415', $flattened->getStatusCode()); - } - - public function testHeadersForHttpException() - { - $flattened = FlattenException::create(new MethodNotAllowedHttpException(array('POST'))); - $this->assertEquals(array('Allow' => 'POST'), $flattened->getHeaders()); - - $flattened = FlattenException::create(new UnauthorizedHttpException('Basic realm="My Realm"')); - $this->assertEquals(array('WWW-Authenticate' => 'Basic realm="My Realm"'), $flattened->getHeaders()); - - $flattened = FlattenException::create(new ServiceUnavailableHttpException('Fri, 31 Dec 1999 23:59:59 GMT')); - $this->assertEquals(array('Retry-After' => 'Fri, 31 Dec 1999 23:59:59 GMT'), $flattened->getHeaders()); - - $flattened = FlattenException::create(new ServiceUnavailableHttpException(120)); - $this->assertEquals(array('Retry-After' => 120), $flattened->getHeaders()); - - $flattened = FlattenException::create(new TooManyRequestsHttpException('Fri, 31 Dec 1999 23:59:59 GMT')); - $this->assertEquals(array('Retry-After' => 'Fri, 31 Dec 1999 23:59:59 GMT'), $flattened->getHeaders()); - - $flattened = FlattenException::create(new TooManyRequestsHttpException(120)); - $this->assertEquals(array('Retry-After' => 120), $flattened->getHeaders()); - } - - /** - * @dataProvider flattenDataProvider - */ - public function testFlattenHttpException(\Exception $exception, $statusCode) - { - $flattened = FlattenException::create($exception); - $flattened2 = FlattenException::create($exception); - - $flattened->setPrevious($flattened2); - - $this->assertEquals($exception->getMessage(), $flattened->getMessage(), 'The message is copied from the original exception.'); - $this->assertEquals($exception->getCode(), $flattened->getCode(), 'The code is copied from the original exception.'); - $this->assertInstanceOf($flattened->getClass(), $exception, 'The class is set to the class of the original exception'); - } - - /** - * @dataProvider flattenDataProvider - */ - public function testPrevious(\Exception $exception, $statusCode) - { - $flattened = FlattenException::create($exception); - $flattened2 = FlattenException::create($exception); - - $flattened->setPrevious($flattened2); - - $this->assertSame($flattened2, $flattened->getPrevious()); - - $this->assertSame(array($flattened2), $flattened->getAllPrevious()); - } - - /** - * @dataProvider flattenDataProvider - */ - public function testLine(\Exception $exception) - { - $flattened = FlattenException::create($exception); - $this->assertSame($exception->getLine(), $flattened->getLine()); - } - - /** - * @dataProvider flattenDataProvider - */ - public function testFile(\Exception $exception) - { - $flattened = FlattenException::create($exception); - $this->assertSame($exception->getFile(), $flattened->getFile()); - } - - /** - * @dataProvider flattenDataProvider - */ - public function testToArray(\Exception $exception, $statusCode) - { - $flattened = FlattenException::create($exception); - $flattened->setTrace(array(), 'foo.php', 123); - - $this->assertEquals(array( - array( - 'message' => 'test', - 'class' => 'Exception', - 'trace' => array(array( - 'namespace' => '', 'short_class' => '', 'class' => '', 'type' => '', 'function' => '', 'file' => 'foo.php', 'line' => 123, - 'args' => array(), - )), - ), - ), $flattened->toArray()); - } - - public function flattenDataProvider() - { - return array( - array(new \Exception('test', 123), 500), - ); - } - - public function testRecursionInArguments() - { - $a = array('foo', array(2, &$a)); - $exception = $this->createException($a); - - $flattened = FlattenException::create($exception); - $trace = $flattened->getTrace(); - $this->assertContains('*DEEP NESTED ARRAY*', serialize($trace)); - } - - public function testTooBigArray() - { - $a = array(); - for ($i = 0; $i < 20; ++$i) { - for ($j = 0; $j < 50; ++$j) { - for ($k = 0; $k < 10; ++$k) { - $a[$i][$j][$k] = 'value'; - } - } - } - $a[20] = 'value'; - $a[21] = 'value1'; - $exception = $this->createException($a); - - $flattened = FlattenException::create($exception); - $trace = $flattened->getTrace(); - $serializeTrace = serialize($trace); - - $this->assertContains('*SKIPPED over 10000 entries*', $serializeTrace); - $this->assertNotContains('*value1*', $serializeTrace); - } - - private function createException($foo) - { - return new \Exception(); - } - - public function testSetTraceIncompleteClass() - { - $flattened = FlattenException::create(new \Exception('test', 123)); - $flattened->setTrace( - array( - array( - 'file' => __FILE__, - 'line' => 123, - 'function' => 'test', - 'args' => array( - unserialize('O:14:"BogusTestClass":0:{}'), - ), - ), - ), - 'foo.php', 123 - ); - - $this->assertEquals(array( - array( - 'message' => 'test', - 'class' => 'Exception', - 'trace' => array( - array( - 'namespace' => '', 'short_class' => '', 'class' => '', 'type' => '', 'function' => '', - 'file' => 'foo.php', 'line' => 123, - 'args' => array(), - ), - array( - 'namespace' => '', 'short_class' => '', 'class' => '', 'type' => '', 'function' => 'test', - 'file' => __FILE__, 'line' => 123, - 'args' => array( - array( - 'incomplete-object', 'BogusTestClass', - ), - ), - ), - ), - ), - ), $flattened->toArray()); - } -} diff --git a/vendor/symfony/debug/Tests/ExceptionHandlerTest.php b/vendor/symfony/debug/Tests/ExceptionHandlerTest.php deleted file mode 100644 index d4b93c083..000000000 --- a/vendor/symfony/debug/Tests/ExceptionHandlerTest.php +++ /dev/null @@ -1,134 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests; - -use Symfony\Component\Debug\ExceptionHandler; -use Symfony\Component\Debug\Exception\OutOfMemoryException; -use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; -use Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException; - -require_once __DIR__.'/HeaderMock.php'; - -class ExceptionHandlerTest extends \PHPUnit_Framework_TestCase -{ - protected function setUp() - { - testHeader(); - } - - protected function tearDown() - { - testHeader(); - } - - public function testDebug() - { - $handler = new ExceptionHandler(false); - - ob_start(); - $handler->sendPhpResponse(new \RuntimeException('Foo')); - $response = ob_get_clean(); - - $this->assertContains('

    Whoops, looks like something went wrong.

    ', $response); - $this->assertNotContains('

    ', $response); - - $handler = new ExceptionHandler(true); - - ob_start(); - $handler->sendPhpResponse(new \RuntimeException('Foo')); - $response = ob_get_clean(); - - $this->assertContains('

    Whoops, looks like something went wrong.

    ', $response); - $this->assertContains('

    ', $response); - } - - public function testStatusCode() - { - $handler = new ExceptionHandler(false, 'iso8859-1'); - - ob_start(); - $handler->sendPhpResponse(new NotFoundHttpException('Foo')); - $response = ob_get_clean(); - - $this->assertContains('Sorry, the page you are looking for could not be found.', $response); - - $expectedHeaders = array( - array('HTTP/1.0 404', true, null), - array('Content-Type: text/html; charset=iso8859-1', true, null), - ); - - $this->assertSame($expectedHeaders, testHeader()); - } - - public function testHeaders() - { - $handler = new ExceptionHandler(false, 'iso8859-1'); - - ob_start(); - $handler->sendPhpResponse(new MethodNotAllowedHttpException(array('POST'))); - $response = ob_get_clean(); - - $expectedHeaders = array( - array('HTTP/1.0 405', true, null), - array('Allow: POST', false, null), - array('Content-Type: text/html; charset=iso8859-1', true, null), - ); - - $this->assertSame($expectedHeaders, testHeader()); - } - - public function testNestedExceptions() - { - $handler = new ExceptionHandler(true); - ob_start(); - $handler->sendPhpResponse(new \RuntimeException('Foo', 0, new \RuntimeException('Bar'))); - $response = ob_get_clean(); - - $this->assertStringMatchesFormat('%AFoo%ABar%A', $response); - } - - public function testHandle() - { - $exception = new \Exception('foo'); - - $handler = $this->getMock('Symfony\Component\Debug\ExceptionHandler', array('sendPhpResponse')); - $handler - ->expects($this->exactly(2)) - ->method('sendPhpResponse'); - - $handler->handle($exception); - - $that = $this; - $handler->setHandler(function ($e) use ($exception, $that) { - $that->assertSame($exception, $e); - }); - - $handler->handle($exception); - } - - public function testHandleOutOfMemoryException() - { - $exception = new OutOfMemoryException('foo', 0, E_ERROR, __FILE__, __LINE__); - - $handler = $this->getMock('Symfony\Component\Debug\ExceptionHandler', array('sendPhpResponse')); - $handler - ->expects($this->once()) - ->method('sendPhpResponse'); - - $that = $this; - $handler->setHandler(function ($e) use ($that) { - $that->fail('OutOfMemoryException should bypass the handler'); - }); - - $handler->handle($exception); - } -} diff --git a/vendor/symfony/debug/Tests/FatalErrorHandler/ClassNotFoundFatalErrorHandlerTest.php b/vendor/symfony/debug/Tests/FatalErrorHandler/ClassNotFoundFatalErrorHandlerTest.php deleted file mode 100644 index c93983721..000000000 --- a/vendor/symfony/debug/Tests/FatalErrorHandler/ClassNotFoundFatalErrorHandlerTest.php +++ /dev/null @@ -1,200 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests\FatalErrorHandler; - -use Symfony\Component\ClassLoader\ClassLoader as SymfonyClassLoader; -use Symfony\Component\ClassLoader\UniversalClassLoader as SymfonyUniversalClassLoader; -use Symfony\Component\Debug\Exception\FatalErrorException; -use Symfony\Component\Debug\FatalErrorHandler\ClassNotFoundFatalErrorHandler; -use Symfony\Component\Debug\DebugClassLoader; -use Composer\Autoload\ClassLoader as ComposerClassLoader; - -class ClassNotFoundFatalErrorHandlerTest extends \PHPUnit_Framework_TestCase -{ - public static function setUpBeforeClass() - { - foreach (spl_autoload_functions() as $function) { - if (!is_array($function)) { - continue; - } - - // get class loaders wrapped by DebugClassLoader - if ($function[0] instanceof DebugClassLoader) { - $function = $function[0]->getClassLoader(); - } - - if ($function[0] instanceof ComposerClassLoader) { - $function[0]->add('Symfony_Component_Debug_Tests_Fixtures', dirname(dirname(dirname(dirname(dirname(__DIR__)))))); - break; - } - } - } - - /** - * @dataProvider provideClassNotFoundData - */ - public function testHandleClassNotFound($error, $translatedMessage, $autoloader = null) - { - if ($autoloader) { - // Unregister all autoloaders to ensure the custom provided - // autoloader is the only one to be used during the test run. - $autoloaders = spl_autoload_functions(); - array_map('spl_autoload_unregister', $autoloaders); - spl_autoload_register($autoloader); - } - - $handler = new ClassNotFoundFatalErrorHandler(); - - $exception = $handler->handleError($error, new FatalErrorException('', 0, $error['type'], $error['file'], $error['line'])); - - if ($autoloader) { - spl_autoload_unregister($autoloader); - array_map('spl_autoload_register', $autoloaders); - } - - $this->assertInstanceOf('Symfony\Component\Debug\Exception\ClassNotFoundException', $exception); - $this->assertSame($translatedMessage, $exception->getMessage()); - $this->assertSame($error['type'], $exception->getSeverity()); - $this->assertSame($error['file'], $exception->getFile()); - $this->assertSame($error['line'], $exception->getLine()); - } - - /** - * @group legacy - */ - public function testLegacyHandleClassNotFound() - { - $prefixes = array('Symfony\Component\Debug\Exception\\' => realpath(__DIR__.'/../../Exception')); - $symfonyUniversalClassLoader = new SymfonyUniversalClassLoader(); - $symfonyUniversalClassLoader->registerPrefixes($prefixes); - - $this->testHandleClassNotFound( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from namespace \"Foo\Bar\".\nDid you forget a \"use\" statement for \"Symfony\Component\Debug\Exception\UndefinedFunctionException\"?", - array($symfonyUniversalClassLoader, 'loadClass') - ); - } - - public function provideClassNotFoundData() - { - $prefixes = array('Symfony\Component\Debug\Exception\\' => realpath(__DIR__.'/../../Exception')); - - $symfonyAutoloader = new SymfonyClassLoader(); - $symfonyAutoloader->addPrefixes($prefixes); - - $debugClassLoader = new DebugClassLoader(array($symfonyAutoloader, 'loadClass')); - - return array( - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'WhizBangFactory\' not found', - ), - "Attempted to load class \"WhizBangFactory\" from the global namespace.\nDid you forget a \"use\" statement?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\WhizBangFactory\' not found', - ), - "Attempted to load class \"WhizBangFactory\" from namespace \"Foo\\Bar\".\nDid you forget a \"use\" statement for another namespace?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from the global namespace.\nDid you forget a \"use\" statement for \"Symfony\Component\Debug\Exception\UndefinedFunctionException\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'PEARClass\' not found', - ), - "Attempted to load class \"PEARClass\" from the global namespace.\nDid you forget a \"use\" statement for \"Symfony_Component_Debug_Tests_Fixtures_PEARClass\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from namespace \"Foo\Bar\".\nDid you forget a \"use\" statement for \"Symfony\Component\Debug\Exception\UndefinedFunctionException\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from namespace \"Foo\Bar\".\nDid you forget a \"use\" statement for \"Symfony\Component\Debug\Exception\UndefinedFunctionException\"?", - array($symfonyAutoloader, 'loadClass'), - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from namespace \"Foo\Bar\".\nDid you forget a \"use\" statement for \"Symfony\Component\Debug\Exception\UndefinedFunctionException\"?", - array($debugClassLoader, 'loadClass'), - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\UndefinedFunctionException\' not found', - ), - "Attempted to load class \"UndefinedFunctionException\" from namespace \"Foo\\Bar\".\nDid you forget a \"use\" statement for another namespace?", - function ($className) { /* do nothing here */ }, - ), - ); - } - - public function testCannotRedeclareClass() - { - if (!file_exists(__DIR__.'/../FIXTURES2/REQUIREDTWICE.PHP')) { - $this->markTestSkipped('Can only be run on case insensitive filesystems'); - } - - require_once __DIR__.'/../FIXTURES2/REQUIREDTWICE.PHP'; - - $error = array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Class \'Foo\\Bar\\RequiredTwice\' not found', - ); - - $handler = new ClassNotFoundFatalErrorHandler(); - $exception = $handler->handleError($error, new FatalErrorException('', 0, $error['type'], $error['file'], $error['line'])); - - $this->assertInstanceOf('Symfony\Component\Debug\Exception\ClassNotFoundException', $exception); - } -} diff --git a/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedFunctionFatalErrorHandlerTest.php b/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedFunctionFatalErrorHandlerTest.php deleted file mode 100644 index 795b74781..000000000 --- a/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedFunctionFatalErrorHandlerTest.php +++ /dev/null @@ -1,80 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests\FatalErrorHandler; - -use Symfony\Component\Debug\Exception\FatalErrorException; -use Symfony\Component\Debug\FatalErrorHandler\UndefinedFunctionFatalErrorHandler; - -class UndefinedFunctionFatalErrorHandlerTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider provideUndefinedFunctionData - */ - public function testUndefinedFunction($error, $translatedMessage) - { - $handler = new UndefinedFunctionFatalErrorHandler(); - $exception = $handler->handleError($error, new FatalErrorException('', 0, $error['type'], $error['file'], $error['line'])); - - $this->assertInstanceOf('Symfony\Component\Debug\Exception\UndefinedFunctionException', $exception); - // class names are case insensitive and PHP/HHVM do not return the same - $this->assertSame(strtolower($translatedMessage), strtolower($exception->getMessage())); - $this->assertSame($error['type'], $exception->getSeverity()); - $this->assertSame($error['file'], $exception->getFile()); - $this->assertSame($error['line'], $exception->getLine()); - } - - public function provideUndefinedFunctionData() - { - return array( - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined function test_namespaced_function()', - ), - "Attempted to call function \"test_namespaced_function\" from the global namespace.\nDid you mean to call \"\\symfony\\component\\debug\\tests\\fatalerrorhandler\\test_namespaced_function\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined function Foo\\Bar\\Baz\\test_namespaced_function()', - ), - "Attempted to call function \"test_namespaced_function\" from namespace \"Foo\\Bar\\Baz\".\nDid you mean to call \"\\symfony\\component\\debug\\tests\\fatalerrorhandler\\test_namespaced_function\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined function foo()', - ), - 'Attempted to call function "foo" from the global namespace.', - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined function Foo\\Bar\\Baz\\foo()', - ), - 'Attempted to call function "foo" from namespace "Foo\Bar\Baz".', - ), - ); - } -} - -function test_namespaced_function() -{ -} diff --git a/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedMethodFatalErrorHandlerTest.php b/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedMethodFatalErrorHandlerTest.php deleted file mode 100644 index de7b21c69..000000000 --- a/vendor/symfony/debug/Tests/FatalErrorHandler/UndefinedMethodFatalErrorHandlerTest.php +++ /dev/null @@ -1,66 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests\FatalErrorHandler; - -use Symfony\Component\Debug\Exception\FatalErrorException; -use Symfony\Component\Debug\FatalErrorHandler\UndefinedMethodFatalErrorHandler; - -class UndefinedMethodFatalErrorHandlerTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider provideUndefinedMethodData - */ - public function testUndefinedMethod($error, $translatedMessage) - { - $handler = new UndefinedMethodFatalErrorHandler(); - $exception = $handler->handleError($error, new FatalErrorException('', 0, $error['type'], $error['file'], $error['line'])); - - $this->assertInstanceOf('Symfony\Component\Debug\Exception\UndefinedMethodException', $exception); - $this->assertSame($translatedMessage, $exception->getMessage()); - $this->assertSame($error['type'], $exception->getSeverity()); - $this->assertSame($error['file'], $exception->getFile()); - $this->assertSame($error['line'], $exception->getLine()); - } - - public function provideUndefinedMethodData() - { - return array( - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined method SplObjectStorage::what()', - ), - 'Attempted to call an undefined method named "what" of class "SplObjectStorage".', - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined method SplObjectStorage::walid()', - ), - "Attempted to call an undefined method named \"walid\" of class \"SplObjectStorage\".\nDid you mean to call \"valid\"?", - ), - array( - array( - 'type' => 1, - 'line' => 12, - 'file' => 'foo.php', - 'message' => 'Call to undefined method SplObjectStorage::offsetFet()', - ), - "Attempted to call an undefined method named \"offsetFet\" of class \"SplObjectStorage\".\nDid you mean to call e.g. \"offsetGet\", \"offsetSet\" or \"offsetUnset\"?", - ), - ); - } -} diff --git a/vendor/symfony/debug/Tests/Fixtures/ClassAlias.php b/vendor/symfony/debug/Tests/Fixtures/ClassAlias.php deleted file mode 100644 index 9d6dbaa71..000000000 --- a/vendor/symfony/debug/Tests/Fixtures/ClassAlias.php +++ /dev/null @@ -1,3 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug; - -function headers_sent() -{ - return false; -} - -function header($str, $replace = true, $status = null) -{ - Tests\testHeader($str, $replace, $status); -} - -namespace Symfony\Component\Debug\Tests; - -function testHeader() -{ - static $headers = array(); - - if (!$h = func_get_args()) { - $h = $headers; - $headers = array(); - - return $h; - } - - $headers[] = func_get_args(); -} diff --git a/vendor/symfony/debug/Tests/MockExceptionHandler.php b/vendor/symfony/debug/Tests/MockExceptionHandler.php deleted file mode 100644 index a85d2d15e..000000000 --- a/vendor/symfony/debug/Tests/MockExceptionHandler.php +++ /dev/null @@ -1,24 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Debug\Tests; - -use Symfony\Component\Debug\ExceptionHandler; - -class MockExceptionHandler extends Exceptionhandler -{ - public $e; - - public function handle(\Exception $e) - { - $this->e = $e; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php deleted file mode 100644 index 04fe7c2cf..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php +++ /dev/null @@ -1,146 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class AnalyzeServiceReferencesPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - - $a = $container - ->register('a') - ->addArgument($ref1 = new Reference('b')) - ; - - $b = $container - ->register('b') - ->addMethodCall('setA', array($ref2 = new Reference('a'))) - ; - - $c = $container - ->register('c') - ->addArgument($ref3 = new Reference('a')) - ->addArgument($ref4 = new Reference('b')) - ; - - $d = $container - ->register('d') - ->setProperty('foo', $ref5 = new Reference('b')) - ; - - $e = $container - ->register('e') - ->setConfigurator(array($ref6 = new Reference('b'), 'methodName')) - ; - - $graph = $this->process($container); - - $this->assertCount(4, $edges = $graph->getNode('b')->getInEdges()); - - $this->assertSame($ref1, $edges[0]->getValue()); - $this->assertSame($ref4, $edges[1]->getValue()); - $this->assertSame($ref5, $edges[2]->getValue()); - $this->assertSame($ref6, $edges[3]->getValue()); - } - - public function testProcessDetectsReferencesFromInlinedDefinitions() - { - $container = new ContainerBuilder(); - - $container - ->register('a') - ; - - $container - ->register('b') - ->addArgument(new Definition(null, array($ref = new Reference('a')))) - ; - - $graph = $this->process($container); - - $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); - $this->assertSame($ref, $refs[0]->getValue()); - } - - public function testProcessDetectsReferencesFromInlinedFactoryDefinitions() - { - $container = new ContainerBuilder(); - - $container - ->register('a') - ; - - $factory = new Definition(); - $factory->setFactory(array(new Reference('a'), 'a')); - - $container - ->register('b') - ->addArgument($factory) - ; - - $graph = $this->process($container); - - $this->assertTrue($graph->hasNode('a')); - $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); - } - - public function testProcessDoesNotSaveDuplicateReferences() - { - $container = new ContainerBuilder(); - - $container - ->register('a') - ; - $container - ->register('b') - ->addArgument(new Definition(null, array($ref1 = new Reference('a')))) - ->addArgument(new Definition(null, array($ref2 = new Reference('a')))) - ; - - $graph = $this->process($container); - - $this->assertCount(2, $graph->getNode('a')->getInEdges()); - } - - public function testProcessDetectsFactoryReferences() - { - $container = new ContainerBuilder(); - - $container - ->register('foo', 'stdClass') - ->setFactory(array('stdClass', 'getInstance')); - - $container - ->register('bar', 'stdClass') - ->setFactory(array(new Reference('foo'), 'getInstance')); - - $graph = $this->process($container); - - $this->assertTrue($graph->hasNode('foo')); - $this->assertCount(1, $graph->getNode('foo')->getInEdges()); - } - - protected function process(ContainerBuilder $container) - { - $pass = new RepeatedPass(array(new AnalyzeServiceReferencesPass())); - $pass->process($container); - - return $container->getCompiler()->getServiceReferenceGraph(); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php deleted file mode 100644 index e3aba6d70..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php +++ /dev/null @@ -1,112 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class AutoAliasServicePassTest extends \PHPUnit_Framework_TestCase -{ - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException - */ - public function testProcessWithMissingParameter() - { - $container = new ContainerBuilder(); - - $container->register('example') - ->addTag('auto_alias', array('format' => '%non_existing%.example')); - - $pass = new AutoAliasServicePass(); - $pass->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException - */ - public function testProcessWithMissingFormat() - { - $container = new ContainerBuilder(); - - $container->register('example') - ->addTag('auto_alias', array()); - $container->setParameter('existing', 'mysql'); - - $pass = new AutoAliasServicePass(); - $pass->process($container); - } - - public function testProcessWithNonExistingAlias() - { - $container = new ContainerBuilder(); - - $container->register('example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault') - ->addTag('auto_alias', array('format' => '%existing%.example')); - $container->setParameter('existing', 'mysql'); - - $pass = new AutoAliasServicePass(); - $pass->process($container); - - $this->assertEquals('Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault', $container->getDefinition('example')->getClass()); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault', $container->get('example')); - } - - public function testProcessWithExistingAlias() - { - $container = new ContainerBuilder(); - - $container->register('example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault') - ->addTag('auto_alias', array('format' => '%existing%.example')); - - $container->register('mysql.example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMysql'); - $container->setParameter('existing', 'mysql'); - - $pass = new AutoAliasServicePass(); - $pass->process($container); - - $this->assertTrue($container->hasAlias('example')); - $this->assertEquals('mysql.example', $container->getAlias('example')); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMysql', $container->get('example')); - } - - public function testProcessWithManualAlias() - { - $container = new ContainerBuilder(); - - $container->register('example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault') - ->addTag('auto_alias', array('format' => '%existing%.example')); - - $container->register('mysql.example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMysql'); - $container->register('mariadb.example', 'Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMariadb'); - $container->setAlias('example', 'mariadb.example'); - $container->setParameter('existing', 'mysql'); - - $pass = new AutoAliasServicePass(); - $pass->process($container); - - $this->assertTrue($container->hasAlias('example')); - $this->assertEquals('mariadb.example', $container->getAlias('example')); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMariaDb', $container->get('example')); - } -} - -class ServiceClassDefault -{ -} - -class ServiceClassMysql extends ServiceClassDefault -{ -} - -class ServiceClassMariaDb extends ServiceClassMysql -{ -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php deleted file mode 100644 index 55351e551..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php +++ /dev/null @@ -1,130 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass; -use Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use Symfony\Component\DependencyInjection\Compiler\Compiler; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class CheckCircularReferencesPassTest extends \PHPUnit_Framework_TestCase -{ - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testProcess() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b')->addArgument(new Reference('a')); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testProcessWithAliases() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->setAlias('b', 'c'); - $container->setAlias('c', 'a'); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testProcessWithFactory() - { - $container = new ContainerBuilder(); - - $container - ->register('a', 'stdClass') - ->setFactory(array(new Reference('b'), 'getInstance')); - - $container - ->register('b', 'stdClass') - ->setFactory(array(new Reference('a'), 'getInstance')); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testProcessDetectsIndirectCircularReference() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b')->addArgument(new Reference('c')); - $container->register('c')->addArgument(new Reference('a')); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testProcessDetectsIndirectCircularReferenceWithFactory() - { - $container = new ContainerBuilder(); - - $container->register('a')->addArgument(new Reference('b')); - - $container - ->register('b', 'stdClass') - ->setFactory(array(new Reference('c'), 'getInstance')); - - $container->register('c')->addArgument(new Reference('a')); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testDeepCircularReference() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b')->addArgument(new Reference('c')); - $container->register('c')->addArgument(new Reference('b')); - - $this->process($container); - } - - public function testProcessIgnoresMethodCalls() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b')->addMethodCall('setA', array(new Reference('a'))); - - $this->process($container); - } - - protected function process(ContainerBuilder $container) - { - $compiler = new Compiler(); - $passConfig = $compiler->getPassConfig(); - $passConfig->setOptimizationPasses(array( - new AnalyzeServiceReferencesPass(true), - new CheckCircularReferencesPass(), - )); - $passConfig->setRemovingPasses(array()); - - $compiler->compile($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php deleted file mode 100644 index 4e8efdc8b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php +++ /dev/null @@ -1,103 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class CheckDefinitionValidityPassTest extends \PHPUnit_Framework_TestCase -{ - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - */ - public function testProcessDetectsSyntheticNonPublicDefinitions() - { - $container = new ContainerBuilder(); - $container->register('a')->setSynthetic(true)->setPublic(false); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - */ - public function testProcessDetectsSyntheticPrototypeDefinitions() - { - $container = new ContainerBuilder(); - $container->register('a')->setSynthetic(true)->setScope(ContainerInterface::SCOPE_PROTOTYPE); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - */ - public function testProcessDetectsNonSyntheticNonAbstractDefinitionWithoutClass() - { - $container = new ContainerBuilder(); - $container->register('a')->setSynthetic(false)->setAbstract(false); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @group legacy - */ - public function testLegacyProcessDetectsBothFactorySyntaxesUsed() - { - $container = new ContainerBuilder(); - $container->register('a')->setFactory(array('a', 'b'))->setFactoryClass('a'); - - $this->process($container); - } - - public function testProcess() - { - $container = new ContainerBuilder(); - $container->register('a', 'class'); - $container->register('b', 'class')->setSynthetic(true)->setPublic(true); - $container->register('c', 'class')->setAbstract(true); - $container->register('d', 'class')->setSynthetic(true); - - $this->process($container); - } - - public function testValidTags() - { - $container = new ContainerBuilder(); - $container->register('a', 'class')->addTag('foo', array('bar' => 'baz')); - $container->register('b', 'class')->addTag('foo', array('bar' => null)); - $container->register('c', 'class')->addTag('foo', array('bar' => 1)); - $container->register('d', 'class')->addTag('foo', array('bar' => 1.1)); - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - */ - public function testInvalidTags() - { - $container = new ContainerBuilder(); - $container->register('a', 'class')->addTag('foo', array('bar' => array('baz' => 'baz'))); - - $this->process($container); - } - - protected function process(ContainerBuilder $container) - { - $pass = new CheckDefinitionValidityPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php deleted file mode 100644 index 18b605b46..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php +++ /dev/null @@ -1,70 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class CheckExceptionOnInvalidReferenceBehaviorPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - - $container - ->register('a', '\stdClass') - ->addArgument(new Reference('b')) - ; - $container->register('b', '\stdClass'); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException - */ - public function testProcessThrowsExceptionOnInvalidReference() - { - $container = new ContainerBuilder(); - - $container - ->register('a', '\stdClass') - ->addArgument(new Reference('b')) - ; - - $this->process($container); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException - */ - public function testProcessThrowsExceptionOnInvalidReferenceFromInlinedDefinition() - { - $container = new ContainerBuilder(); - - $def = new Definition(); - $def->addArgument(new Reference('b')); - - $container - ->register('a', '\stdClass') - ->addArgument($def) - ; - - $this->process($container); - } - - private function process(ContainerBuilder $container) - { - $pass = new CheckExceptionOnInvalidReferenceBehaviorPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php deleted file mode 100644 index cd4448a96..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php +++ /dev/null @@ -1,97 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Scope; -use Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class CheckReferenceValidityPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcessIgnoresScopeWideningIfNonStrictReference() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b', ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, false)); - $container->register('b')->setScope('prototype'); - - $this->process($container); - } - - /** - * @expectedException \RuntimeException - */ - public function testProcessDetectsScopeWidening() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b')->setScope('prototype'); - - $this->process($container); - } - - public function testProcessIgnoresCrossScopeHierarchyReferenceIfNotStrict() - { - $container = new ContainerBuilder(); - $container->addScope(new Scope('a')); - $container->addScope(new Scope('b')); - - $container->register('a')->setScope('a')->addArgument(new Reference('b', ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, false)); - $container->register('b')->setScope('b'); - - $this->process($container); - } - - /** - * @expectedException \RuntimeException - */ - public function testProcessDetectsCrossScopeHierarchyReference() - { - $container = new ContainerBuilder(); - $container->addScope(new Scope('a')); - $container->addScope(new Scope('b')); - - $container->register('a')->setScope('a')->addArgument(new Reference('b')); - $container->register('b')->setScope('b'); - - $this->process($container); - } - - /** - * @expectedException \RuntimeException - */ - public function testProcessDetectsReferenceToAbstractDefinition() - { - $container = new ContainerBuilder(); - - $container->register('a')->setAbstract(true); - $container->register('b')->addArgument(new Reference('a')); - - $this->process($container); - } - - public function testProcess() - { - $container = new ContainerBuilder(); - $container->register('a')->addArgument(new Reference('b')); - $container->register('b'); - - $this->process($container); - } - - protected function process(ContainerBuilder $container) - { - $pass = new CheckReferenceValidityPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php deleted file mode 100644 index e17961ac9..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php +++ /dev/null @@ -1,81 +0,0 @@ -register('foo') - ->setPublic(false) - ; - $fooExtendedDefinition = $container - ->register('foo.extended') - ->setPublic(true) - ->setDecoratedService('foo') - ; - $barDefinition = $container - ->register('bar') - ->setPublic(true) - ; - $barExtendedDefinition = $container - ->register('bar.extended') - ->setPublic(true) - ->setDecoratedService('bar', 'bar.yoo') - ; - - $this->process($container); - - $this->assertEquals('foo.extended', $container->getAlias('foo')); - $this->assertFalse($container->getAlias('foo')->isPublic()); - - $this->assertEquals('bar.extended', $container->getAlias('bar')); - $this->assertTrue($container->getAlias('bar')->isPublic()); - - $this->assertSame($fooDefinition, $container->getDefinition('foo.extended.inner')); - $this->assertFalse($container->getDefinition('foo.extended.inner')->isPublic()); - - $this->assertSame($barDefinition, $container->getDefinition('bar.yoo')); - $this->assertFalse($container->getDefinition('bar.yoo')->isPublic()); - - $this->assertNull($fooExtendedDefinition->getDecoratedService()); - $this->assertNull($barExtendedDefinition->getDecoratedService()); - } - - public function testProcessWithAlias() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(true) - ; - $container->setAlias('foo.alias', new Alias('foo', false)); - $fooExtendedDefinition = $container - ->register('foo.extended') - ->setPublic(true) - ->setDecoratedService('foo.alias') - ; - - $this->process($container); - - $this->assertEquals('foo.extended', $container->getAlias('foo.alias')); - $this->assertFalse($container->getAlias('foo.alias')->isPublic()); - - $this->assertEquals('foo', $container->getAlias('foo.extended.inner')); - $this->assertFalse($container->getAlias('foo.extended.inner')->isPublic()); - - $this->assertNull($fooExtendedDefinition->getDecoratedService()); - } - - protected function process(ContainerBuilder $container) - { - $repeatedPass = new DecoratorServicePass(); - $repeatedPass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php deleted file mode 100644 index ef690da16..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php +++ /dev/null @@ -1,46 +0,0 @@ - - */ -class ExtensionCompilerPassTest extends \PHPUnit_Framework_TestCase -{ - private $container; - private $pass; - - public function setUp() - { - $this->container = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder'); - $this->pass = new ExtensionCompilerPass(); - } - - public function testProcess() - { - $extension1 = $this->createExtensionMock(true); - $extension1->expects($this->once())->method('process'); - $extension2 = $this->createExtensionMock(false); - $extension3 = $this->createExtensionMock(false); - $extension4 = $this->createExtensionMock(true); - $extension4->expects($this->once())->method('process'); - - $this->container->expects($this->any()) - ->method('getExtensions') - ->will($this->returnValue(array($extension1, $extension2, $extension3, $extension4))) - ; - - $this->pass->process($this->container); - } - - private function createExtensionMock($hasInlineCompile) - { - return $this->getMock('Symfony\Component\DependencyInjection\\'.( - $hasInlineCompile - ? 'Compiler\CompilerPassInterface' - : 'Extension\ExtensionInterface' - )); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php deleted file mode 100644 index 590ca4cfa..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php +++ /dev/null @@ -1,245 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Scope; -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class InlineServiceDefinitionsPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - $container - ->register('inlinable.service') - ->setPublic(false) - ; - - $container - ->register('service') - ->setArguments(array(new Reference('inlinable.service'))) - ; - - $this->process($container); - - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $arguments[0]); - $this->assertSame($container->getDefinition('inlinable.service'), $arguments[0]); - } - - public function testProcessDoesNotInlineWhenAliasedServiceIsNotOfPrototypeScope() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ; - $container->setAlias('moo', 'foo'); - - $container - ->register('service') - ->setArguments(array($ref = new Reference('foo'))) - ; - - $this->process($container); - - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertSame($ref, $arguments[0]); - } - - public function testProcessDoesInlineServiceOfPrototypeScope() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setScope('prototype') - ; - $container - ->register('bar') - ->setPublic(false) - ->setScope('prototype') - ; - $container->setAlias('moo', 'bar'); - - $container - ->register('service') - ->setArguments(array(new Reference('foo'), $ref = new Reference('moo'), new Reference('bar'))) - ; - - $this->process($container); - - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertEquals($container->getDefinition('foo'), $arguments[0]); - $this->assertNotSame($container->getDefinition('foo'), $arguments[0]); - $this->assertSame($ref, $arguments[1]); - $this->assertEquals($container->getDefinition('bar'), $arguments[2]); - $this->assertNotSame($container->getDefinition('bar'), $arguments[2]); - } - - public function testProcessInlinesIfMultipleReferencesButAllFromTheSameDefinition() - { - $container = new ContainerBuilder(); - - $a = $container->register('a')->setPublic(false); - $b = $container - ->register('b') - ->addArgument(new Reference('a')) - ->addArgument(new Definition(null, array(new Reference('a')))) - ; - - $this->process($container); - - $arguments = $b->getArguments(); - $this->assertSame($a, $arguments[0]); - - $inlinedArguments = $arguments[1]->getArguments(); - $this->assertSame($a, $inlinedArguments[0]); - } - - public function testProcessInlinesPrivateFactoryReference() - { - $container = new ContainerBuilder(); - - $container->register('a')->setPublic(false); - $b = $container - ->register('b') - ->setPublic(false) - ->setFactory(array(new Reference('a'), 'a')) - ; - - $container - ->register('foo') - ->setArguments(array( - $ref = new Reference('b'), - )); - - $this->process($container); - - $inlinedArguments = $container->getDefinition('foo')->getArguments(); - $this->assertSame($b, $inlinedArguments[0]); - } - - public function testProcessDoesNotInlinePrivateFactoryIfReferencedMultipleTimesWithinTheSameDefinition() - { - $container = new ContainerBuilder(); - $container - ->register('a') - ; - $container - ->register('b') - ->setPublic(false) - ->setFactory(array(new Reference('a'), 'a')) - ; - - $container - ->register('foo') - ->setArguments(array( - $ref1 = new Reference('b'), - $ref2 = new Reference('b'), - )) - ; - $this->process($container); - - $args = $container->getDefinition('foo')->getArguments(); - $this->assertSame($ref1, $args[0]); - $this->assertSame($ref2, $args[1]); - } - - public function testProcessDoesNotInlineReferenceWhenUsedByInlineFactory() - { - $container = new ContainerBuilder(); - $container - ->register('a') - ; - $container - ->register('b') - ->setPublic(false) - ->setFactory(array(new Reference('a'), 'a')) - ; - - $inlineFactory = new Definition(); - $inlineFactory->setPublic(false); - $inlineFactory->setFactory(array(new Reference('b'), 'b')); - - $container - ->register('foo') - ->setArguments(array( - $ref = new Reference('b'), - $inlineFactory, - )) - ; - $this->process($container); - - $args = $container->getDefinition('foo')->getArguments(); - $this->assertSame($ref, $args[0]); - } - - public function testProcessInlinesOnlyIfSameScope() - { - $container = new ContainerBuilder(); - - $container->addScope(new Scope('foo')); - $a = $container->register('a')->setPublic(false)->setScope('foo'); - $b = $container->register('b')->addArgument(new Reference('a')); - - $this->process($container); - $arguments = $b->getArguments(); - $this->assertEquals(new Reference('a'), $arguments[0]); - $this->assertTrue($container->hasDefinition('a')); - } - - public function testProcessDoesNotInlineWhenServiceIsPrivateButLazy() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ->setLazy(true) - ; - - $container - ->register('service') - ->setArguments(array($ref = new Reference('foo'))) - ; - - $this->process($container); - - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertSame($ref, $arguments[0]); - } - - public function testProcessDoesNotInlineWhenServiceReferencesItself() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ->addMethodCall('foo', array($ref = new Reference('foo'))) - ; - - $this->process($container); - - $calls = $container->getDefinition('foo')->getMethodCalls(); - $this->assertSame($ref, $calls[0][1][0]); - } - - protected function process(ContainerBuilder $container) - { - $repeatedPass = new RepeatedPass(array(new AnalyzeServiceReferencesPass(), new InlineServiceDefinitionsPass())); - $repeatedPass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php deleted file mode 100644 index c4479403a..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php +++ /dev/null @@ -1,116 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Alias; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -/** - * This class tests the integration of the different compiler passes. - */ -class IntegrationTest extends \PHPUnit_Framework_TestCase -{ - /** - * This tests that dependencies are correctly processed. - * - * We're checking that: - * - * * A is public, B/C are private - * * A -> C - * * B -> C - */ - public function testProcessRemovesAndInlinesRecursively() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - - $a = $container - ->register('a', '\stdClass') - ->addArgument(new Reference('c')) - ; - - $b = $container - ->register('b', '\stdClass') - ->addArgument(new Reference('c')) - ->setPublic(false) - ; - - $c = $container - ->register('c', '\stdClass') - ->setPublic(false) - ; - - $container->compile(); - - $this->assertTrue($container->hasDefinition('a')); - $arguments = $a->getArguments(); - $this->assertSame($c, $arguments[0]); - $this->assertFalse($container->hasDefinition('b')); - $this->assertFalse($container->hasDefinition('c')); - } - - public function testProcessInlinesReferencesToAliases() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - - $a = $container - ->register('a', '\stdClass') - ->addArgument(new Reference('b')) - ; - - $container->setAlias('b', new Alias('c', false)); - - $c = $container - ->register('c', '\stdClass') - ->setPublic(false) - ; - - $container->compile(); - - $this->assertTrue($container->hasDefinition('a')); - $arguments = $a->getArguments(); - $this->assertSame($c, $arguments[0]); - $this->assertFalse($container->hasAlias('b')); - $this->assertFalse($container->hasDefinition('c')); - } - - public function testProcessInlinesWhenThereAreMultipleReferencesButFromTheSameDefinition() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - - $container - ->register('a', '\stdClass') - ->addArgument(new Reference('b')) - ->addMethodCall('setC', array(new Reference('c'))) - ; - - $container - ->register('b', '\stdClass') - ->addArgument(new Reference('c')) - ->setPublic(false) - ; - - $container - ->register('c', '\stdClass') - ->setPublic(false) - ; - - $container->compile(); - - $this->assertTrue($container->hasDefinition('a')); - $this->assertFalse($container->hasDefinition('b')); - $this->assertFalse($container->hasDefinition('c'), 'Service C was not inlined.'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/LegacyResolveParameterPlaceHoldersPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/LegacyResolveParameterPlaceHoldersPassTest.php deleted file mode 100644 index e730a1a28..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/LegacyResolveParameterPlaceHoldersPassTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -/** - * @group legacy - */ -class LegacyResolveParameterPlaceHoldersPassTest extends \PHPUnit_Framework_TestCase -{ - public function testFactoryClassParametersShouldBeResolved() - { - $compilerPass = new ResolveParameterPlaceHoldersPass(); - - $container = new ContainerBuilder(); - $container->setParameter('foo.factory.class', 'FooFactory'); - $fooDefinition = $container->register('foo', '%foo.factory.class%'); - $fooDefinition->setFactoryClass('%foo.factory.class%'); - $compilerPass->process($container); - $fooDefinition = $container->getDefinition('foo'); - - $this->assertSame('FooFactory', $fooDefinition->getFactoryClass()); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php deleted file mode 100644 index 6e112bb7f..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php +++ /dev/null @@ -1,55 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; - -class MergeExtensionConfigurationPassTest extends \PHPUnit_Framework_TestCase -{ - public function testExpressionLanguageProviderForwarding() - { - if (true !== class_exists('Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage')) { - $this->markTestSkipped('The ExpressionLanguage component isn\'t available!'); - } - - $tmpProviders = array(); - - $extension = $this->getMock('Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface'); - $extension->expects($this->any()) - ->method('getXsdValidationBasePath') - ->will($this->returnValue(false)); - $extension->expects($this->any()) - ->method('getNamespace') - ->will($this->returnValue('http://example.org/schema/dic/foo')); - $extension->expects($this->any()) - ->method('getAlias') - ->will($this->returnValue('foo')); - $extension->expects($this->once()) - ->method('load') - ->will($this->returnCallback(function (array $config, ContainerBuilder $container) use (&$tmpProviders) { - $tmpProviders = $container->getExpressionLanguageProviders(); - })); - - $provider = $this->getMock('Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface'); - $container = new ContainerBuilder(new ParameterBag()); - $container->registerExtension($extension); - $container->prependExtensionConfig('foo', array('bar' => true)); - $container->addExpressionLanguageProvider($provider); - - $pass = new MergeExtensionConfigurationPass(); - $pass->process($container); - - $this->assertEquals(array($provider), $tmpProviders); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php deleted file mode 100644 index 82149ebdb..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php +++ /dev/null @@ -1,113 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass; -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class RemoveUnusedDefinitionsPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ; - $container - ->register('bar') - ->setPublic(false) - ; - $container - ->register('moo') - ->setArguments(array(new Reference('bar'))) - ; - - $this->process($container); - - $this->assertFalse($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - $this->assertTrue($container->hasDefinition('moo')); - } - - public function testProcessRemovesUnusedDefinitionsRecursively() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ; - $container - ->register('bar') - ->setArguments(array(new Reference('foo'))) - ->setPublic(false) - ; - - $this->process($container); - - $this->assertFalse($container->hasDefinition('foo')); - $this->assertFalse($container->hasDefinition('bar')); - } - - public function testProcessWorksWithInlinedDefinitions() - { - $container = new ContainerBuilder(); - $container - ->register('foo') - ->setPublic(false) - ; - $container - ->register('bar') - ->setArguments(array(new Definition(null, array(new Reference('foo'))))) - ; - - $this->process($container); - - $this->assertTrue($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - } - - public function testProcessWontRemovePrivateFactory() - { - $container = new ContainerBuilder(); - - $container - ->register('foo', 'stdClass') - ->setFactory(array('stdClass', 'getInstance')) - ->setPublic(false); - - $container - ->register('bar', 'stdClass') - ->setFactory(array(new Reference('foo'), 'getInstance')) - ->setPublic(false); - - $container - ->register('foobar') - ->addArgument(new Reference('bar')); - - $this->process($container); - - $this->assertTrue($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - $this->assertTrue($container->hasDefinition('foobar')); - } - - protected function process(ContainerBuilder $container) - { - $repeatedPass = new RepeatedPass(array(new AnalyzeServiceReferencesPass(), new RemoveUnusedDefinitionsPass())); - $repeatedPass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php deleted file mode 100644 index e4d22401d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php +++ /dev/null @@ -1,59 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Definition; - -class ReplaceAliasByActualDefinitionPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - - $container->register('a', '\stdClass'); - - $bDefinition = new Definition('\stdClass'); - $bDefinition->setPublic(false); - $container->setDefinition('b', $bDefinition); - - $container->setAlias('a_alias', 'a'); - $container->setAlias('b_alias', 'b'); - - $this->process($container); - - $this->assertTrue($container->has('a'), '->process() does nothing to public definitions.'); - $this->assertTrue($container->hasAlias('a_alias')); - $this->assertFalse($container->has('b'), '->process() removes non-public definitions.'); - $this->assertTrue( - $container->has('b_alias') && !$container->hasAlias('b_alias'), - '->process() replaces alias to actual.' - ); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testProcessWithInvalidAlias() - { - $container = new ContainerBuilder(); - $container->setAlias('a_alias', 'a'); - $this->process($container); - } - - protected function process(ContainerBuilder $container) - { - $pass = new ReplaceAliasByActualDefinitionPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php deleted file mode 100644 index 845edd2c1..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php +++ /dev/null @@ -1,215 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\DefinitionDecorator; -use Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class ResolveDefinitionTemplatesPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - $container->register('parent', 'foo')->setArguments(array('moo', 'b'))->setProperty('foo', 'moo'); - $container->setDefinition('child', new DefinitionDecorator('parent')) - ->replaceArgument(0, 'a') - ->setProperty('foo', 'bar') - ->setClass('bar') - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertNotInstanceOf('Symfony\Component\DependencyInjection\DefinitionDecorator', $def); - $this->assertEquals('bar', $def->getClass()); - $this->assertEquals(array('a', 'b'), $def->getArguments()); - $this->assertEquals(array('foo' => 'bar'), $def->getProperties()); - } - - public function testProcessAppendsMethodCallsAlways() - { - $container = new ContainerBuilder(); - - $container - ->register('parent') - ->addMethodCall('foo', array('bar')) - ; - - $container - ->setDefinition('child', new DefinitionDecorator('parent')) - ->addMethodCall('bar', array('foo')) - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertEquals(array( - array('foo', array('bar')), - array('bar', array('foo')), - ), $def->getMethodCalls()); - } - - public function testProcessDoesNotCopyAbstract() - { - $container = new ContainerBuilder(); - - $container - ->register('parent') - ->setAbstract(true) - ; - - $container - ->setDefinition('child', new DefinitionDecorator('parent')) - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertFalse($def->isAbstract()); - } - - public function testProcessDoesNotCopyScope() - { - $container = new ContainerBuilder(); - - $container - ->register('parent') - ->setScope('foo') - ; - - $container - ->setDefinition('child', new DefinitionDecorator('parent')) - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertEquals(ContainerInterface::SCOPE_CONTAINER, $def->getScope()); - } - - public function testProcessDoesNotCopyTags() - { - $container = new ContainerBuilder(); - - $container - ->register('parent') - ->addTag('foo') - ; - - $container - ->setDefinition('child', new DefinitionDecorator('parent')) - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertEquals(array(), $def->getTags()); - } - - public function testProcessDoesNotCopyDecoratedService() - { - $container = new ContainerBuilder(); - - $container - ->register('parent') - ->setDecoratedService('foo') - ; - - $container - ->setDefinition('child', new DefinitionDecorator('parent')) - ; - - $this->process($container); - - $def = $container->getDefinition('child'); - $this->assertNull($def->getDecoratedService()); - } - - public function testProcessHandlesMultipleInheritance() - { - $container = new ContainerBuilder(); - - $container - ->register('parent', 'foo') - ->setArguments(array('foo', 'bar', 'c')) - ; - - $container - ->setDefinition('child2', new DefinitionDecorator('child1')) - ->replaceArgument(1, 'b') - ; - - $container - ->setDefinition('child1', new DefinitionDecorator('parent')) - ->replaceArgument(0, 'a') - ; - - $this->process($container); - - $def = $container->getDefinition('child2'); - $this->assertEquals(array('a', 'b', 'c'), $def->getArguments()); - $this->assertEquals('foo', $def->getClass()); - } - - public function testSetLazyOnServiceHasParent() - { - $container = new ContainerBuilder(); - - $container->register('parent', 'stdClass'); - - $container->setDefinition('child1', new DefinitionDecorator('parent')) - ->setLazy(true) - ; - - $this->process($container); - - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - - public function testSetLazyOnServiceIsParent() - { - $container = new ContainerBuilder(); - - $container->register('parent', 'stdClass') - ->setLazy(true) - ; - - $container->setDefinition('child1', new DefinitionDecorator('parent')); - - $this->process($container); - - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - - public function testSetDecoratedServiceOnServiceHasParent() - { - $container = new ContainerBuilder(); - - $container->register('parent', 'stdClass'); - - $container->setDefinition('child1', new DefinitionDecorator('parent')) - ->setDecoratedService('foo', 'foo_inner') - ; - - $this->process($container); - - $this->assertEquals(array('foo', 'foo_inner'), $container->getDefinition('child1')->getDecoratedService()); - } - - protected function process(ContainerBuilder $container) - { - $pass = new ResolveDefinitionTemplatesPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php deleted file mode 100644 index 72058868d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php +++ /dev/null @@ -1,83 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class ResolveInvalidReferencesPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - $def = $container - ->register('foo') - ->setArguments(array(new Reference('bar', ContainerInterface::NULL_ON_INVALID_REFERENCE))) - ->addMethodCall('foo', array(new Reference('moo', ContainerInterface::IGNORE_ON_INVALID_REFERENCE))) - ; - - $this->process($container); - - $arguments = $def->getArguments(); - $this->assertNull($arguments[0]); - $this->assertCount(0, $def->getMethodCalls()); - } - - public function testProcessIgnoreNonExistentServices() - { - $container = new ContainerBuilder(); - $def = $container - ->register('foo') - ->setArguments(array(new Reference('bar'))) - ; - - $this->process($container); - - $arguments = $def->getArguments(); - $this->assertEquals('bar', (string) $arguments[0]); - } - - public function testProcessRemovesPropertiesOnInvalid() - { - $container = new ContainerBuilder(); - $def = $container - ->register('foo') - ->setProperty('foo', new Reference('bar', ContainerInterface::IGNORE_ON_INVALID_REFERENCE)) - ; - - $this->process($container); - - $this->assertEquals(array(), $def->getProperties()); - } - - public function testStrictFlagIsPreserved() - { - $container = new ContainerBuilder(); - $container->register('bar'); - $def = $container - ->register('foo') - ->addArgument(new Reference('bar', ContainerInterface::NULL_ON_INVALID_REFERENCE, false)) - ; - - $this->process($container); - - $this->assertFalse($def->getArgument(0)->isStrict()); - } - - protected function process(ContainerBuilder $container) - { - $pass = new ResolveInvalidReferencesPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php deleted file mode 100644 index 1f604c228..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php +++ /dev/null @@ -1,91 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class ResolveParameterPlaceHoldersPassTest extends \PHPUnit_Framework_TestCase -{ - private $compilerPass; - private $container; - private $fooDefinition; - - protected function setUp() - { - $this->compilerPass = new ResolveParameterPlaceHoldersPass(); - $this->container = $this->createContainerBuilder(); - $this->compilerPass->process($this->container); - $this->fooDefinition = $this->container->getDefinition('foo'); - } - - public function testClassParametersShouldBeResolved() - { - $this->assertSame('Foo', $this->fooDefinition->getClass()); - } - - public function testFactoryParametersShouldBeResolved() - { - $this->assertSame(array('FooFactory', 'getFoo'), $this->fooDefinition->getFactory()); - } - - public function testArgumentParametersShouldBeResolved() - { - $this->assertSame(array('bar', 'baz'), $this->fooDefinition->getArguments()); - } - - public function testMethodCallParametersShouldBeResolved() - { - $this->assertSame(array(array('foobar', array('bar', 'baz'))), $this->fooDefinition->getMethodCalls()); - } - - public function testPropertyParametersShouldBeResolved() - { - $this->assertSame(array('bar' => 'baz'), $this->fooDefinition->getProperties()); - } - - public function testFileParametersShouldBeResolved() - { - $this->assertSame('foo.php', $this->fooDefinition->getFile()); - } - - public function testAliasParametersShouldBeResolved() - { - $this->assertSame('foo', $this->container->getAlias('bar')->__toString()); - } - - private function createContainerBuilder() - { - $containerBuilder = new ContainerBuilder(); - - $containerBuilder->setParameter('foo.class', 'Foo'); - $containerBuilder->setParameter('foo.factory.class', 'FooFactory'); - $containerBuilder->setParameter('foo.arg1', 'bar'); - $containerBuilder->setParameter('foo.arg2', 'baz'); - $containerBuilder->setParameter('foo.method', 'foobar'); - $containerBuilder->setParameter('foo.property.name', 'bar'); - $containerBuilder->setParameter('foo.property.value', 'baz'); - $containerBuilder->setParameter('foo.file', 'foo.php'); - $containerBuilder->setParameter('alias.id', 'bar'); - - $fooDefinition = $containerBuilder->register('foo', '%foo.class%'); - $fooDefinition->setFactory(array('%foo.factory.class%', 'getFoo')); - $fooDefinition->setArguments(array('%foo.arg1%', '%foo.arg2%')); - $fooDefinition->addMethodCall('%foo.method%', array('%foo.arg1%', '%foo.arg2%')); - $fooDefinition->setProperty('%foo.property.name%', '%foo.property.value%'); - $fooDefinition->setFile('%foo.file%'); - - $containerBuilder->setAlias('%alias.id%', 'foo'); - - return $containerBuilder; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php deleted file mode 100644 index 6fdc23394..000000000 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php +++ /dev/null @@ -1,67 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Compiler; - -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass; -use Symfony\Component\DependencyInjection\ContainerBuilder; - -class ResolveReferencesToAliasesPassTest extends \PHPUnit_Framework_TestCase -{ - public function testProcess() - { - $container = new ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $def = $container - ->register('moo') - ->setArguments(array(new Reference('bar'))) - ; - - $this->process($container); - - $arguments = $def->getArguments(); - $this->assertEquals('foo', (string) $arguments[0]); - } - - public function testProcessRecursively() - { - $container = new ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $container->setAlias('moo', 'bar'); - $def = $container - ->register('foobar') - ->setArguments(array(new Reference('moo'))) - ; - - $this->process($container); - - $arguments = $def->getArguments(); - $this->assertEquals('foo', (string) $arguments[0]); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testAliasCircularReference() - { - $container = new ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $container->setAlias('foo', 'bar'); - $this->process($container); - } - - protected function process(ContainerBuilder $container) - { - $pass = new ResolveReferencesToAliasesPass(); - $pass->process($container); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php b/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php deleted file mode 100644 index 8155e0b7c..000000000 --- a/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php +++ /dev/null @@ -1,858 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -require_once __DIR__.'/Fixtures/includes/classes.php'; -require_once __DIR__.'/Fixtures/includes/ProjectExtension.php'; - -use Symfony\Component\Config\Resource\ResourceInterface; -use Symfony\Component\DependencyInjection\Alias; -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\Exception\RuntimeException; -use Symfony\Component\DependencyInjection\Exception\InactiveScopeException; -use Symfony\Component\DependencyInjection\Loader\ClosureLoader; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use Symfony\Component\DependencyInjection\Scope; -use Symfony\Component\Config\Resource\FileResource; -use Symfony\Component\ExpressionLanguage\Expression; - -class ContainerBuilderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::setDefinitions - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getDefinitions - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::setDefinition - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getDefinition - */ - public function testDefinitions() - { - $builder = new ContainerBuilder(); - $definitions = array( - 'foo' => new Definition('Bar\FooClass'), - 'bar' => new Definition('BarClass'), - ); - $builder->setDefinitions($definitions); - $this->assertEquals($definitions, $builder->getDefinitions(), '->setDefinitions() sets the service definitions'); - $this->assertTrue($builder->hasDefinition('foo'), '->hasDefinition() returns true if a service definition exists'); - $this->assertFalse($builder->hasDefinition('foobar'), '->hasDefinition() returns false if a service definition does not exist'); - - $builder->setDefinition('foobar', $foo = new Definition('FooBarClass')); - $this->assertEquals($foo, $builder->getDefinition('foobar'), '->getDefinition() returns a service definition if defined'); - $this->assertTrue($builder->setDefinition('foobar', $foo = new Definition('FooBarClass')) === $foo, '->setDefinition() implements a fluid interface by returning the service reference'); - - $builder->addDefinitions($defs = array('foobar' => new Definition('FooBarClass'))); - $this->assertEquals(array_merge($definitions, $defs), $builder->getDefinitions(), '->addDefinitions() adds the service definitions'); - - try { - $builder->getDefinition('baz'); - $this->fail('->getDefinition() throws an InvalidArgumentException if the service definition does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The service definition "baz" does not exist.', $e->getMessage(), '->getDefinition() throws an InvalidArgumentException if the service definition does not exist'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::register - */ - public function testRegister() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'Bar\FooClass'); - $this->assertTrue($builder->hasDefinition('foo'), '->register() registers a new service definition'); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $builder->getDefinition('foo'), '->register() returns the newly created Definition instance'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::has - */ - public function testHas() - { - $builder = new ContainerBuilder(); - $this->assertFalse($builder->has('foo'), '->has() returns false if the service does not exist'); - $builder->register('foo', 'Bar\FooClass'); - $this->assertTrue($builder->has('foo'), '->has() returns true if a service definition exists'); - $builder->set('bar', new \stdClass()); - $this->assertTrue($builder->has('bar'), '->has() returns true if a service exists'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::get - */ - public function testGet() - { - $builder = new ContainerBuilder(); - try { - $builder->get('foo'); - $this->fail('->get() throws an InvalidArgumentException if the service does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The service definition "foo" does not exist.', $e->getMessage(), '->get() throws an InvalidArgumentException if the service does not exist'); - } - - $this->assertNull($builder->get('foo', ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service does not exist and NULL_ON_INVALID_REFERENCE is passed as a second argument'); - - $builder->register('foo', 'stdClass'); - $this->assertInternalType('object', $builder->get('foo'), '->get() returns the service definition associated with the id'); - $builder->set('bar', $bar = new \stdClass()); - $this->assertEquals($bar, $builder->get('bar'), '->get() returns the service associated with the id'); - $builder->register('bar', 'stdClass'); - $this->assertEquals($bar, $builder->get('bar'), '->get() returns the service associated with the id even if a definition has been defined'); - - $builder->register('baz', 'stdClass')->setArguments(array(new Reference('baz'))); - try { - @$builder->get('baz'); - $this->fail('->get() throws a ServiceCircularReferenceException if the service has a circular reference to itself'); - } catch (\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { - $this->assertEquals('Circular reference detected for service "baz", path: "baz".', $e->getMessage(), '->get() throws a LogicException if the service has a circular reference to itself'); - } - - $builder->register('foobar', 'stdClass')->setScope('container'); - $this->assertTrue($builder->get('bar') === $builder->get('bar'), '->get() always returns the same instance if the service is shared'); - } - - /** - * @covers \Symfony\Component\DependencyInjection\ContainerBuilder::get - * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessage You have requested a synthetic service ("foo"). The DIC does not know how to construct this service. - */ - public function testGetUnsetLoadingServiceWhenCreateServiceThrowsAnException() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'stdClass')->setSynthetic(true); - - // we expect a RuntimeException here as foo is synthetic - try { - $builder->get('foo'); - } catch (RuntimeException $e) { - } - - // we must also have the same RuntimeException here - $builder->get('foo'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::get - */ - public function testGetReturnsNullOnInactiveScope() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'stdClass')->setScope('request'); - - $this->assertNull($builder->get('foo', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::get - */ - public function testGetReturnsNullOnInactiveScopeWhenServiceIsCreatedByAMethod() - { - $builder = new ProjectContainer(); - - $this->assertNull($builder->get('foobaz', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getServiceIds - */ - public function testGetServiceIds() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'stdClass'); - $builder->bar = $bar = new \stdClass(); - $builder->register('bar', 'stdClass'); - $this->assertEquals(array('foo', 'bar', 'service_container'), $builder->getServiceIds(), '->getServiceIds() returns all defined service ids'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::setAlias - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::hasAlias - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getAlias - */ - public function testAliases() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'stdClass'); - $builder->setAlias('bar', 'foo'); - $this->assertTrue($builder->hasAlias('bar'), '->hasAlias() returns true if the alias exists'); - $this->assertFalse($builder->hasAlias('foobar'), '->hasAlias() returns false if the alias does not exist'); - $this->assertEquals('foo', (string) $builder->getAlias('bar'), '->getAlias() returns the aliased service'); - $this->assertTrue($builder->has('bar'), '->setAlias() defines a new service'); - $this->assertTrue($builder->get('bar') === $builder->get('foo'), '->setAlias() creates a service that is an alias to another one'); - - try { - $builder->setAlias('foobar', 'foobar'); - $this->fail('->setAlias() throws an InvalidArgumentException if the alias references itself'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('An alias can not reference itself, got a circular reference on "foobar".', $e->getMessage(), '->setAlias() throws an InvalidArgumentException if the alias references itself'); - } - - try { - $builder->getAlias('foobar'); - $this->fail('->getAlias() throws an InvalidArgumentException if the alias does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The service alias "foobar" does not exist.', $e->getMessage(), '->getAlias() throws an InvalidArgumentException if the alias does not exist'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getAliases - */ - public function testGetAliases() - { - $builder = new ContainerBuilder(); - $builder->setAlias('bar', 'foo'); - $builder->setAlias('foobar', 'foo'); - $builder->setAlias('moo', new Alias('foo', false)); - - $aliases = $builder->getAliases(); - $this->assertEquals('foo', (string) $aliases['bar']); - $this->assertTrue($aliases['bar']->isPublic()); - $this->assertEquals('foo', (string) $aliases['foobar']); - $this->assertEquals('foo', (string) $aliases['moo']); - $this->assertFalse($aliases['moo']->isPublic()); - - $builder->register('bar', 'stdClass'); - $this->assertFalse($builder->hasAlias('bar')); - - $builder->set('foobar', 'stdClass'); - $builder->set('moo', 'stdClass'); - $this->assertCount(0, $builder->getAliases(), '->getAliases() does not return aliased services that have been overridden'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::setAliases - */ - public function testSetAliases() - { - $builder = new ContainerBuilder(); - $builder->setAliases(array('bar' => 'foo', 'foobar' => 'foo')); - - $aliases = $builder->getAliases(); - $this->assertTrue(isset($aliases['bar'])); - $this->assertTrue(isset($aliases['foobar'])); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::addAliases - */ - public function testAddAliases() - { - $builder = new ContainerBuilder(); - $builder->setAliases(array('bar' => 'foo')); - $builder->addAliases(array('foobar' => 'foo')); - - $aliases = $builder->getAliases(); - $this->assertTrue(isset($aliases['bar'])); - $this->assertTrue(isset($aliases['foobar'])); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::addCompilerPass - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getCompilerPassConfig - */ - public function testAddGetCompilerPass() - { - $builder = new ContainerBuilder(); - $builder->setResourceTracking(false); - $builderCompilerPasses = $builder->getCompiler()->getPassConfig()->getPasses(); - $builder->addCompilerPass($this->getMock('Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface')); - - $this->assertCount(count($builder->getCompiler()->getPassConfig()->getPasses()) - 1, $builderCompilerPasses); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateService() - { - $builder = new ContainerBuilder(); - $builder->register('foo1', 'Bar\FooClass')->setFile(__DIR__.'/Fixtures/includes/foo.php'); - $this->assertInstanceOf('\Bar\FooClass', $builder->get('foo1'), '->createService() requires the file defined by the service definition'); - $builder->register('foo2', 'Bar\FooClass')->setFile(__DIR__.'/Fixtures/includes/%file%.php'); - $builder->setParameter('file', 'foo'); - $this->assertInstanceOf('\Bar\FooClass', $builder->get('foo2'), '->createService() replaces parameters in the file provided by the service definition'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateProxyWithRealServiceInstantiator() - { - $builder = new ContainerBuilder(); - - $builder->register('foo1', 'Bar\FooClass')->setFile(__DIR__.'/Fixtures/includes/foo.php'); - $builder->getDefinition('foo1')->setLazy(true); - - $foo1 = $builder->get('foo1'); - - $this->assertSame($foo1, $builder->get('foo1'), 'The same proxy is retrieved on multiple subsequent calls'); - $this->assertSame('Bar\FooClass', get_class($foo1)); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceClass() - { - $builder = new ContainerBuilder(); - $builder->register('foo1', '%class%'); - $builder->setParameter('class', 'stdClass'); - $this->assertInstanceOf('\stdClass', $builder->get('foo1'), '->createService() replaces parameters in the class provided by the service definition'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceArguments() - { - $builder = new ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', 'Bar\FooClass')->addArgument(array('foo' => '%value%', '%value%' => 'foo', new Reference('bar'), '%%unescape_it%%')); - $builder->setParameter('value', 'bar'); - $this->assertEquals(array('foo' => 'bar', 'bar' => 'foo', $builder->get('bar'), '%unescape_it%'), $builder->get('foo1')->arguments, '->createService() replaces parameters and service references in the arguments provided by the service definition'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceFactory() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'Bar\FooClass')->setFactory('Bar\FooClass::getInstance'); - $builder->register('qux', 'Bar\FooClass')->setFactory(array('Bar\FooClass', 'getInstance')); - $builder->register('bar', 'Bar\FooClass')->setFactory(array(new Definition('Bar\FooClass'), 'getInstance')); - $builder->register('baz', 'Bar\FooClass')->setFactory(array(new Reference('bar'), 'getInstance')); - - $this->assertTrue($builder->get('foo')->called, '->createService() calls the factory method to create the service instance'); - $this->assertTrue($builder->get('qux')->called, '->createService() calls the factory method to create the service instance'); - $this->assertTrue($builder->get('bar')->called, '->createService() uses anonymous service as factory'); - $this->assertTrue($builder->get('baz')->called, '->createService() uses another service as factory'); - } - - public function testLegacyCreateServiceFactory() - { - $builder = new ContainerBuilder(); - $builder->register('bar', 'Bar\FooClass'); - $builder - ->register('foo1', 'Bar\FooClass') - ->setFactoryClass('%foo_class%') - ->setFactoryMethod('getInstance') - ->addArgument(array('foo' => '%value%', '%value%' => 'foo', new Reference('bar'))) - ; - $builder->setParameter('value', 'bar'); - $builder->setParameter('foo_class', 'Bar\FooClass'); - $this->assertTrue($builder->get('foo1')->called, '->createService() calls the factory method to create the service instance'); - $this->assertEquals(array('foo' => 'bar', 'bar' => 'foo', $builder->get('bar')), $builder->get('foo1')->arguments, '->createService() passes the arguments to the factory method'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testLegacyCreateServiceFactoryService() - { - $builder = new ContainerBuilder(); - $builder->register('foo_service', 'Bar\FooClass'); - $builder - ->register('foo', 'Bar\FooClass') - ->setFactoryService('%foo_service%') - ->setFactoryMethod('getInstance') - ; - $builder->setParameter('foo_service', 'foo_service'); - $this->assertTrue($builder->get('foo')->called, '->createService() calls the factory method to create the service instance'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceMethodCalls() - { - $builder = new ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', 'Bar\FooClass')->addMethodCall('setBar', array(array('%value%', new Reference('bar')))); - $builder->setParameter('value', 'bar'); - $this->assertEquals(array('bar', $builder->get('bar')), $builder->get('foo1')->bar, '->createService() replaces the values in the method calls arguments'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceConfigurator() - { - $builder = new ContainerBuilder(); - $builder->register('foo1', 'Bar\FooClass')->setConfigurator('sc_configure'); - $this->assertTrue($builder->get('foo1')->configured, '->createService() calls the configurator'); - - $builder->register('foo2', 'Bar\FooClass')->setConfigurator(array('%class%', 'configureStatic')); - $builder->setParameter('class', 'BazClass'); - $this->assertTrue($builder->get('foo2')->configured, '->createService() calls the configurator'); - - $builder->register('baz', 'BazClass'); - $builder->register('foo3', 'Bar\FooClass')->setConfigurator(array(new Reference('baz'), 'configure')); - $this->assertTrue($builder->get('foo3')->configured, '->createService() calls the configurator'); - - $builder->register('foo4', 'Bar\FooClass')->setConfigurator(array($builder->getDefinition('baz'), 'configure')); - $this->assertTrue($builder->get('foo4')->configured, '->createService() calls the configurator'); - - $builder->register('foo5', 'Bar\FooClass')->setConfigurator('foo'); - try { - $builder->get('foo5'); - $this->fail('->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The configure callable for class "Bar\FooClass" is not a callable.', $e->getMessage(), '->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - * @expectedException \RuntimeException - */ - public function testCreateSyntheticService() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'Bar\FooClass')->setSynthetic(true); - $builder->get('foo'); - } - - public function testCreateServiceWithExpression() - { - $builder = new ContainerBuilder(); - $builder->setParameter('bar', 'bar'); - $builder->register('bar', 'BarClass'); - $builder->register('foo', 'Bar\FooClass')->addArgument(array('foo' => new Expression('service("bar").foo ~ parameter("bar")'))); - $this->assertEquals('foobar', $builder->get('foo')->arguments['foo']); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::resolveServices - */ - public function testResolveServices() - { - $builder = new ContainerBuilder(); - $builder->register('foo', 'Bar\FooClass'); - $this->assertEquals($builder->get('foo'), $builder->resolveServices(new Reference('foo')), '->resolveServices() resolves service references to service instances'); - $this->assertEquals(array('foo' => array('foo', $builder->get('foo'))), $builder->resolveServices(array('foo' => array('foo', new Reference('foo')))), '->resolveServices() resolves service references to service instances in nested arrays'); - $this->assertEquals($builder->get('foo'), $builder->resolveServices(new Expression('service("foo")')), '->resolveServices() resolves expressions'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::merge - */ - public function testMerge() - { - $container = new ContainerBuilder(new ParameterBag(array('bar' => 'foo'))); - $container->setResourceTracking(false); - $config = new ContainerBuilder(new ParameterBag(array('foo' => 'bar'))); - $container->merge($config); - $this->assertEquals(array('bar' => 'foo', 'foo' => 'bar'), $container->getParameterBag()->all(), '->merge() merges current parameters with the loaded ones'); - - $container = new ContainerBuilder(new ParameterBag(array('bar' => 'foo'))); - $container->setResourceTracking(false); - $config = new ContainerBuilder(new ParameterBag(array('foo' => '%bar%'))); - $container->merge($config); - $container->compile(); - $this->assertEquals(array('bar' => 'foo', 'foo' => 'foo'), $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); - - $container = new ContainerBuilder(new ParameterBag(array('bar' => 'foo'))); - $container->setResourceTracking(false); - $config = new ContainerBuilder(new ParameterBag(array('foo' => '%bar%', 'baz' => '%foo%'))); - $container->merge($config); - $container->compile(); - $this->assertEquals(array('bar' => 'foo', 'foo' => 'foo', 'baz' => 'foo'), $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); - - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->register('foo', 'Bar\FooClass'); - $container->register('bar', 'BarClass'); - $config = new ContainerBuilder(); - $config->setDefinition('baz', new Definition('BazClass')); - $config->setAlias('alias_for_foo', 'foo'); - $container->merge($config); - $this->assertEquals(array('foo', 'bar', 'baz'), array_keys($container->getDefinitions()), '->merge() merges definitions already defined ones'); - - $aliases = $container->getAliases(); - $this->assertTrue(isset($aliases['alias_for_foo'])); - $this->assertEquals('foo', (string) $aliases['alias_for_foo']); - - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->register('foo', 'Bar\FooClass'); - $config->setDefinition('foo', new Definition('BazClass')); - $container->merge($config); - $this->assertEquals('BazClass', $container->getDefinition('foo')->getClass(), '->merge() overrides already defined services'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::merge - * @expectedException \LogicException - */ - public function testMergeLogicException() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->compile(); - $container->merge(new ContainerBuilder()); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::findTaggedServiceIds - */ - public function testfindTaggedServiceIds() - { - $builder = new ContainerBuilder(); - $builder - ->register('foo', 'Bar\FooClass') - ->addTag('foo', array('foo' => 'foo')) - ->addTag('bar', array('bar' => 'bar')) - ->addTag('foo', array('foofoo' => 'foofoo')) - ; - $this->assertEquals($builder->findTaggedServiceIds('foo'), array( - 'foo' => array( - array('foo' => 'foo'), - array('foofoo' => 'foofoo'), - ), - ), '->findTaggedServiceIds() returns an array of service ids and its tag attributes'); - $this->assertEquals(array(), $builder->findTaggedServiceIds('foobar'), '->findTaggedServiceIds() returns an empty array if there is annotated services'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::findDefinition - */ - public function testFindDefinition() - { - $container = new ContainerBuilder(); - $container->setDefinition('foo', $definition = new Definition('Bar\FooClass')); - $container->setAlias('bar', 'foo'); - $container->setAlias('foobar', 'bar'); - $this->assertEquals($definition, $container->findDefinition('foobar'), '->findDefinition() returns a Definition'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::addObjectResource - */ - public function testAddObjectResource() - { - $container = new ContainerBuilder(); - - $container->setResourceTracking(false); - $container->addObjectResource(new \BarClass()); - - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - - $container->setResourceTracking(true); - $container->addObjectResource(new \BarClass()); - - $resources = $container->getResources(); - - $this->assertCount(1, $resources, '1 resource was registered'); - - /* @var $resource \Symfony\Component\Config\Resource\FileResource */ - $resource = end($resources); - - $this->assertInstanceOf('Symfony\Component\Config\Resource\FileResource', $resource); - $this->assertSame(realpath(__DIR__.'/Fixtures/includes/classes.php'), realpath($resource->getResource())); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::addClassResource - */ - public function testAddClassResource() - { - $container = new ContainerBuilder(); - - $container->setResourceTracking(false); - $container->addClassResource(new \ReflectionClass('BarClass')); - - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - - $container->setResourceTracking(true); - $container->addClassResource(new \ReflectionClass('BarClass')); - - $resources = $container->getResources(); - - $this->assertCount(1, $resources, '1 resource was registered'); - - /* @var $resource \Symfony\Component\Config\Resource\FileResource */ - $resource = end($resources); - - $this->assertInstanceOf('Symfony\Component\Config\Resource\FileResource', $resource); - $this->assertSame(realpath(__DIR__.'/Fixtures/includes/classes.php'), realpath($resource->getResource())); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::compile - */ - public function testCompilesClassDefinitionsOfLazyServices() - { - $container = new ContainerBuilder(); - - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - - $container->register('foo', 'BarClass'); - $container->getDefinition('foo')->setLazy(true); - - $container->compile(); - - $classesPath = realpath(__DIR__.'/Fixtures/includes/classes.php'); - $matchingResources = array_filter( - $container->getResources(), - function (ResourceInterface $resource) use ($classesPath) { - return $resource instanceof FileResource && $classesPath === realpath($resource->getResource()); - } - ); - - $this->assertNotEmpty($matchingResources); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getResources - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::addResource - */ - public function testResources() - { - $container = new ContainerBuilder(); - $container->addResource($a = new FileResource(__DIR__.'/Fixtures/xml/services1.xml')); - $container->addResource($b = new FileResource(__DIR__.'/Fixtures/xml/services2.xml')); - $resources = array(); - foreach ($container->getResources() as $resource) { - if (false === strpos($resource, '.php')) { - $resources[] = $resource; - } - } - $this->assertEquals(array($a, $b), $resources, '->getResources() returns an array of resources read for the current configuration'); - $this->assertSame($container, $container->setResources(array())); - $this->assertEquals(array(), $container->getResources()); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::registerExtension - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getExtension - */ - public function testExtension() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - - $container->registerExtension($extension = new \ProjectExtension()); - $this->assertTrue($container->getExtension('project') === $extension, '->registerExtension() registers an extension'); - - $this->setExpectedException('LogicException'); - $container->getExtension('no_registered'); - } - - public function testRegisteredButNotLoadedExtension() - { - $extension = $this->getMock('Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface'); - $extension->expects($this->once())->method('getAlias')->will($this->returnValue('project')); - $extension->expects($this->never())->method('load'); - - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->registerExtension($extension); - $container->compile(); - } - - public function testRegisteredAndLoadedExtension() - { - $extension = $this->getMock('Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface'); - $extension->expects($this->exactly(2))->method('getAlias')->will($this->returnValue('project')); - $extension->expects($this->once())->method('load')->with(array(array('foo' => 'bar'))); - - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->registerExtension($extension); - $container->loadFromExtension('project', array('foo' => 'bar')); - $container->compile(); - } - - public function testPrivateServiceUser() - { - $fooDefinition = new Definition('BarClass'); - $fooUserDefinition = new Definition('BarUserClass', array(new Reference('bar'))); - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - - $fooDefinition->setPublic(false); - - $container->addDefinitions(array( - 'bar' => $fooDefinition, - 'bar_user' => $fooUserDefinition, - )); - - $container->compile(); - $this->assertInstanceOf('BarClass', $container->get('bar_user')->bar); - } - - /** - * @expectedException \BadMethodCallException - */ - public function testThrowsExceptionWhenSetServiceOnAFrozenContainer() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->setDefinition('a', new Definition('stdClass')); - $container->compile(); - $container->set('a', new \stdClass()); - } - - /** - * @expectedException \BadMethodCallException - */ - public function testThrowsExceptionWhenAddServiceOnAFrozenContainer() - { - $container = new ContainerBuilder(); - $container->compile(); - $container->set('a', new \stdClass()); - } - - public function testNoExceptionWhenSetSyntheticServiceOnAFrozenContainer() - { - $container = new ContainerBuilder(); - $def = new Definition('stdClass'); - $def->setSynthetic(true); - $container->setDefinition('a', $def); - $container->compile(); - $container->set('a', $a = new \stdClass()); - $this->assertEquals($a, $container->get('a')); - } - - /** - * @group legacy - */ - public function testLegacySetOnSynchronizedService() - { - $container = new ContainerBuilder(); - $container->register('baz', 'BazClass') - ->setSynchronized(true) - ; - $container->register('bar', 'BarClass') - ->addMethodCall('setBaz', array(new Reference('baz'))) - ; - - $container->set('baz', $baz = new \BazClass()); - $this->assertSame($baz, $container->get('bar')->getBaz()); - - $container->set('baz', $baz = new \BazClass()); - $this->assertSame($baz, $container->get('bar')->getBaz()); - } - - /** - * @group legacy - */ - public function testLegacySynchronizedServiceWithScopes() - { - $container = new ContainerBuilder(); - $container->addScope(new Scope('foo')); - $container->register('baz', 'BazClass') - ->setSynthetic(true) - ->setSynchronized(true) - ->setScope('foo') - ; - $container->register('bar', 'BarClass') - ->addMethodCall('setBaz', array(new Reference('baz', ContainerInterface::NULL_ON_INVALID_REFERENCE, false))) - ; - $container->compile(); - - $container->enterScope('foo'); - $container->set('baz', $outerBaz = new \BazClass(), 'foo'); - $this->assertSame($outerBaz, $container->get('bar')->getBaz()); - - $container->enterScope('foo'); - $container->set('baz', $innerBaz = new \BazClass(), 'foo'); - $this->assertSame($innerBaz, $container->get('bar')->getBaz()); - $container->leaveScope('foo'); - - $this->assertNotSame($innerBaz, $container->get('bar')->getBaz()); - $this->assertSame($outerBaz, $container->get('bar')->getBaz()); - - $container->leaveScope('foo'); - } - - /** - * @expectedException \BadMethodCallException - */ - public function testThrowsExceptionWhenSetDefinitionOnAFrozenContainer() - { - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->compile(); - $container->setDefinition('a', new Definition()); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::getExtensionConfig - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::prependExtensionConfig - */ - public function testExtensionConfig() - { - $container = new ContainerBuilder(); - - $configs = $container->getExtensionConfig('foo'); - $this->assertEmpty($configs); - - $first = array('foo' => 'bar'); - $container->prependExtensionConfig('foo', $first); - $configs = $container->getExtensionConfig('foo'); - $this->assertEquals(array($first), $configs); - - $second = array('ding' => 'dong'); - $container->prependExtensionConfig('foo', $second); - $configs = $container->getExtensionConfig('foo'); - $this->assertEquals(array($second, $first), $configs); - } - - public function testLazyLoadedService() - { - $loader = new ClosureLoader($container = new ContainerBuilder()); - $loader->load(function (ContainerBuilder $container) { - $container->set('a', new \BazClass()); - $definition = new Definition('BazClass'); - $definition->setLazy(true); - $container->setDefinition('a', $definition); - } - ); - - $container->setResourceTracking(true); - - $container->compile(); - - $class = new \BazClass(); - $reflectionClass = new \ReflectionClass($class); - - $r = new \ReflectionProperty($container, 'resources'); - $r->setAccessible(true); - $resources = $r->getValue($container); - - $classInList = false; - foreach ($resources as $resource) { - if ($resource->getResource() === $reflectionClass->getFileName()) { - $classInList = true; - break; - } - } - - $this->assertTrue($classInList); - } -} - -class FooClass -{ -} - -class ProjectContainer extends ContainerBuilder -{ - public function getFoobazService() - { - throw new InactiveScopeException('foo', 'request'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ContainerTest.php b/vendor/symfony/dependency-injection/Tests/ContainerTest.php deleted file mode 100644 index 472bd1ff6..000000000 --- a/vendor/symfony/dependency-injection/Tests/ContainerTest.php +++ /dev/null @@ -1,713 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\Scope; -use Symfony\Component\DependencyInjection\Container; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use Symfony\Component\DependencyInjection\Exception\InactiveScopeException; - -class ContainerTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Container::__construct - */ - public function testConstructor() - { - $sc = new Container(); - $this->assertSame($sc, $sc->get('service_container'), '__construct() automatically registers itself as a service'); - - $sc = new Container(new ParameterBag(array('foo' => 'bar'))); - $this->assertEquals(array('foo' => 'bar'), $sc->getParameterBag()->all(), '__construct() takes an array of parameters as its first argument'); - } - - /** - * @dataProvider dataForTestCamelize - */ - public function testCamelize($id, $expected) - { - $this->assertEquals($expected, Container::camelize($id), sprintf('Container::camelize("%s")', $id)); - } - - public function dataForTestCamelize() - { - return array( - array('foo_bar', 'FooBar'), - array('foo.bar', 'Foo_Bar'), - array('foo.bar_baz', 'Foo_BarBaz'), - array('foo._bar', 'Foo_Bar'), - array('foo_.bar', 'Foo_Bar'), - array('_foo', 'Foo'), - array('.foo', '_Foo'), - array('foo_', 'Foo'), - array('foo.', 'Foo_'), - array('foo\bar', 'Foo_Bar'), - ); - } - - /** - * @dataProvider dataForTestUnderscore - */ - public function testUnderscore($id, $expected) - { - $this->assertEquals($expected, Container::underscore($id), sprintf('Container::underscore("%s")', $id)); - } - - public function dataForTestUnderscore() - { - return array( - array('FooBar', 'foo_bar'), - array('Foo_Bar', 'foo.bar'), - array('Foo_BarBaz', 'foo.bar_baz'), - array('FooBar_BazQux', 'foo_bar.baz_qux'), - array('_Foo', '.foo'), - array('Foo_', 'foo.'), - ); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::compile - */ - public function testCompile() - { - $sc = new Container(new ParameterBag(array('foo' => 'bar'))); - $this->assertFalse($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); - $sc->compile(); - $this->assertTrue($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag', $sc->getParameterBag(), '->compile() changes the parameter bag to a FrozenParameterBag instance'); - $this->assertEquals(array('foo' => 'bar'), $sc->getParameterBag()->all(), '->compile() copies the current parameters to the new parameter bag'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::isFrozen - */ - public function testIsFrozen() - { - $sc = new Container(new ParameterBag(array('foo' => 'bar'))); - $this->assertFalse($sc->isFrozen(), '->isFrozen() returns false if the parameters are not frozen'); - $sc->compile(); - $this->assertTrue($sc->isFrozen(), '->isFrozen() returns true if the parameters are frozen'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::getParameterBag - */ - public function testGetParameterBag() - { - $sc = new Container(); - $this->assertEquals(array(), $sc->getParameterBag()->all(), '->getParameterBag() returns an empty array if no parameter has been defined'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::setParameter - * @covers Symfony\Component\DependencyInjection\Container::getParameter - */ - public function testGetSetParameter() - { - $sc = new Container(new ParameterBag(array('foo' => 'bar'))); - $sc->setParameter('bar', 'foo'); - $this->assertEquals('foo', $sc->getParameter('bar'), '->setParameter() sets the value of a new parameter'); - - $sc->setParameter('foo', 'baz'); - $this->assertEquals('baz', $sc->getParameter('foo'), '->setParameter() overrides previously set parameter'); - - $sc->setParameter('Foo', 'baz1'); - $this->assertEquals('baz1', $sc->getParameter('foo'), '->setParameter() converts the key to lowercase'); - $this->assertEquals('baz1', $sc->getParameter('FOO'), '->getParameter() converts the key to lowercase'); - - try { - $sc->getParameter('baba'); - $this->fail('->getParameter() thrown an \InvalidArgumentException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->getParameter() thrown an \InvalidArgumentException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->getParameter() thrown an \InvalidArgumentException if the key does not exist'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::getServiceIds - */ - public function testGetServiceIds() - { - $sc = new Container(); - $sc->set('foo', $obj = new \stdClass()); - $sc->set('bar', $obj = new \stdClass()); - $this->assertEquals(array('service_container', 'foo', 'bar'), $sc->getServiceIds(), '->getServiceIds() returns all defined service ids'); - - $sc = new ProjectServiceContainer(); - $sc->set('foo', $obj = new \stdClass()); - $this->assertEquals(array('scoped', 'scoped_foo', 'scoped_synchronized_foo', 'inactive', 'bar', 'foo_bar', 'foo.baz', 'circular', 'throw_exception', 'throws_exception_on_service_configuration', 'service_container', 'foo'), $sc->getServiceIds(), '->getServiceIds() returns defined service ids by getXXXService() methods, followed by service ids defined by set()'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::set - */ - public function testSet() - { - $sc = new Container(); - $sc->set('foo', $foo = new \stdClass()); - $this->assertEquals($foo, $sc->get('foo'), '->set() sets a service'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::set - */ - public function testSetWithNullResetTheService() - { - $sc = new Container(); - $sc->set('foo', null); - $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testSetDoesNotAllowPrototypeScope() - { - $c = new Container(); - $c->set('foo', new \stdClass(), Container::SCOPE_PROTOTYPE); - } - - /** - * @expectedException \RuntimeException - */ - public function testSetDoesNotAllowInactiveScope() - { - $c = new Container(); - $c->addScope(new Scope('foo')); - $c->set('foo', new \stdClass(), 'foo'); - } - - public function testSetAlsoSetsScopedService() - { - $c = new Container(); - $c->addScope(new Scope('foo')); - $c->enterScope('foo'); - $c->set('foo', $foo = new \stdClass(), 'foo'); - - $scoped = $this->getField($c, 'scopedServices'); - $this->assertTrue(isset($scoped['foo']['foo']), '->set() sets a scoped service'); - $this->assertSame($foo, $scoped['foo']['foo'], '->set() sets a scoped service'); - } - - public function testSetAlsoCallsSynchronizeService() - { - $c = new ProjectServiceContainer(); - $c->addScope(new Scope('foo')); - $c->enterScope('foo'); - $c->set('scoped_synchronized_foo', $bar = new \stdClass(), 'foo'); - $this->assertTrue($c->synchronized, '->set() calls synchronize*Service() if it is defined for the service'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::get - */ - public function testGet() - { - $sc = new ProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $this->assertEquals($foo, $sc->get('foo'), '->get() returns the service for the given id'); - $this->assertEquals($foo, $sc->get('Foo'), '->get() returns the service for the given id, and converts id to lowercase'); - $this->assertEquals($sc->__bar, $sc->get('bar'), '->get() returns the service for the given id'); - $this->assertEquals($sc->__foo_bar, $sc->get('foo_bar'), '->get() returns the service if a get*Method() is defined'); - $this->assertEquals($sc->__foo_baz, $sc->get('foo.baz'), '->get() returns the service if a get*Method() is defined'); - $this->assertEquals($sc->__foo_baz, $sc->get('foo\\baz'), '->get() returns the service if a get*Method() is defined'); - - $sc->set('bar', $bar = new \stdClass()); - $this->assertEquals($bar, $sc->get('bar'), '->get() prefers to return a service defined with set() than one defined with a getXXXMethod()'); - - try { - $sc->get(''); - $this->fail('->get() throws a \InvalidArgumentException exception if the service is empty'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException', $e, '->get() throws a ServiceNotFoundException exception if the service is empty'); - } - $this->assertNull($sc->get('', ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service is empty'); - } - - public function testGetThrowServiceNotFoundException() - { - $sc = new ProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $sc->set('bar', $foo = new \stdClass()); - $sc->set('baz', $foo = new \stdClass()); - - try { - $sc->get('foo1'); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent service "foo1". Did you mean this: "foo"?', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException with some advices'); - } - - try { - $sc->get('bag'); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent service "bag". Did you mean one of these: "bar", "baz"?', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException with some advices'); - } - } - - public function testGetCircularReference() - { - $sc = new ProjectServiceContainer(); - try { - $sc->get('circular'); - $this->fail('->get() throws a ServiceCircularReferenceException if it contains circular reference'); - } catch (\Exception $e) { - $this->assertInstanceOf('\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException', $e, '->get() throws a ServiceCircularReferenceException if it contains circular reference'); - $this->assertStringStartsWith('Circular reference detected for service "circular"', $e->getMessage(), '->get() throws a \LogicException if it contains circular reference'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::get - */ - public function testGetReturnsNullOnInactiveScope() - { - $sc = new ProjectServiceContainer(); - $this->assertNull($sc->get('inactive', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::has - */ - public function testHas() - { - $sc = new ProjectServiceContainer(); - $sc->set('foo', new \stdClass()); - $this->assertFalse($sc->has('foo1'), '->has() returns false if the service does not exist'); - $this->assertTrue($sc->has('foo'), '->has() returns true if the service exists'); - $this->assertTrue($sc->has('bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo_bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo.baz'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo\\baz'), '->has() returns true if a get*Method() is defined'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Container::initialized - */ - public function testInitialized() - { - $sc = new ProjectServiceContainer(); - $sc->set('foo', new \stdClass()); - $this->assertTrue($sc->initialized('foo'), '->initialized() returns true if service is loaded'); - $this->assertFalse($sc->initialized('foo1'), '->initialized() returns false if service is not loaded'); - $this->assertFalse($sc->initialized('bar'), '->initialized() returns false if a service is defined, but not currently loaded'); - $this->assertFalse($sc->initialized('alias'), '->initialized() returns false if an aliased service is not initialized'); - - $sc->set('bar', new \stdClass()); - $this->assertTrue($sc->initialized('alias'), '->initialized() returns true for alias if aliased service is initialized'); - } - - public function testEnterLeaveCurrentScope() - { - $container = new ProjectServiceContainer(); - $container->addScope(new Scope('foo')); - - $container->enterScope('foo'); - $scoped1 = $container->get('scoped'); - $scopedFoo1 = $container->get('scoped_foo'); - - $container->enterScope('foo'); - $scoped2 = $container->get('scoped'); - $scoped3 = $container->get('SCOPED'); - $scopedFoo2 = $container->get('scoped_foo'); - - $container->leaveScope('foo'); - $scoped4 = $container->get('scoped'); - $scopedFoo3 = $container->get('scoped_foo'); - - $this->assertNotSame($scoped1, $scoped2); - $this->assertSame($scoped2, $scoped3); - $this->assertSame($scoped1, $scoped4); - $this->assertNotSame($scopedFoo1, $scopedFoo2); - $this->assertSame($scopedFoo1, $scopedFoo3); - } - - public function testEnterLeaveScopeWithChildScopes() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - $container->addScope(new Scope('bar', 'foo')); - - $this->assertFalse($container->isScopeActive('foo')); - - $container->enterScope('foo'); - $container->enterScope('bar'); - - $this->assertTrue($container->isScopeActive('foo')); - $this->assertFalse($container->has('a')); - - $a = new \stdClass(); - $container->set('a', $a, 'bar'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertTrue(isset($scoped['bar']['a'])); - $this->assertSame($a, $scoped['bar']['a']); - $this->assertTrue($container->has('a')); - - $container->leaveScope('foo'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertFalse(isset($scoped['bar'])); - $this->assertFalse($container->isScopeActive('foo')); - $this->assertFalse($container->has('a')); - } - - public function testEnterScopeRecursivelyWithInactiveChildScopes() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - $container->addScope(new Scope('bar', 'foo')); - - $this->assertFalse($container->isScopeActive('foo')); - - $container->enterScope('foo'); - - $this->assertTrue($container->isScopeActive('foo')); - $this->assertFalse($container->isScopeActive('bar')); - $this->assertFalse($container->has('a')); - - $a = new \stdClass(); - $container->set('a', $a, 'foo'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertTrue(isset($scoped['foo']['a'])); - $this->assertSame($a, $scoped['foo']['a']); - $this->assertTrue($container->has('a')); - - $container->enterScope('foo'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertFalse(isset($scoped['a'])); - $this->assertTrue($container->isScopeActive('foo')); - $this->assertFalse($container->isScopeActive('bar')); - $this->assertFalse($container->has('a')); - - $container->enterScope('bar'); - - $this->assertTrue($container->isScopeActive('bar')); - - $container->leaveScope('foo'); - - $this->assertTrue($container->isScopeActive('foo')); - $this->assertFalse($container->isScopeActive('bar')); - $this->assertTrue($container->has('a')); - } - - public function testEnterChildScopeRecursively() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - $container->addScope(new Scope('bar', 'foo')); - - $container->enterScope('foo'); - $container->enterScope('bar'); - - $this->assertTrue($container->isScopeActive('bar')); - $this->assertFalse($container->has('a')); - - $a = new \stdClass(); - $container->set('a', $a, 'bar'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertTrue(isset($scoped['bar']['a'])); - $this->assertSame($a, $scoped['bar']['a']); - $this->assertTrue($container->has('a')); - - $container->enterScope('bar'); - - $scoped = $this->getField($container, 'scopedServices'); - $this->assertFalse(isset($scoped['a'])); - $this->assertTrue($container->isScopeActive('foo')); - $this->assertTrue($container->isScopeActive('bar')); - $this->assertFalse($container->has('a')); - - $container->leaveScope('bar'); - - $this->assertTrue($container->isScopeActive('foo')); - $this->assertTrue($container->isScopeActive('bar')); - $this->assertTrue($container->has('a')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnterScopeNotAdded() - { - $container = new Container(); - $container->enterScope('foo'); - } - - /** - * @expectedException \RuntimeException - */ - public function testEnterScopeDoesNotAllowInactiveParentScope() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - $container->addScope(new Scope('bar', 'foo')); - $container->enterScope('bar'); - } - - public function testLeaveScopeNotActive() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - - try { - $container->leaveScope('foo'); - $this->fail('->leaveScope() throws a \LogicException if the scope is not active yet'); - } catch (\Exception $e) { - $this->assertInstanceOf('\LogicException', $e, '->leaveScope() throws a \LogicException if the scope is not active yet'); - $this->assertEquals('The scope "foo" is not active.', $e->getMessage(), '->leaveScope() throws a \LogicException if the scope is not active yet'); - } - - try { - $container->leaveScope('bar'); - $this->fail('->leaveScope() throws a \LogicException if the scope does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\LogicException', $e, '->leaveScope() throws a \LogicException if the scope does not exist'); - $this->assertEquals('The scope "bar" is not active.', $e->getMessage(), '->leaveScope() throws a \LogicException if the scope does not exist'); - } - } - - /** - * @expectedException \InvalidArgumentException - * @dataProvider getBuiltInScopes - */ - public function testAddScopeDoesNotAllowBuiltInScopes($scope) - { - $container = new Container(); - $container->addScope(new Scope($scope)); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testAddScopeDoesNotAllowExistingScope() - { - $container = new Container(); - $container->addScope(new Scope('foo')); - $container->addScope(new Scope('foo')); - } - - /** - * @expectedException \InvalidArgumentException - * @dataProvider getInvalidParentScopes - */ - public function testAddScopeDoesNotAllowInvalidParentScope($scope) - { - $c = new Container(); - $c->addScope(new Scope('foo', $scope)); - } - - public function testAddScope() - { - $c = new Container(); - $c->addScope(new Scope('foo')); - $c->addScope(new Scope('bar', 'foo')); - - $this->assertSame(array('foo' => 'container', 'bar' => 'foo'), $this->getField($c, 'scopes')); - $this->assertSame(array('foo' => array('bar'), 'bar' => array()), $this->getField($c, 'scopeChildren')); - - $c->addScope(new Scope('baz', 'bar')); - - $this->assertSame(array('foo' => 'container', 'bar' => 'foo', 'baz' => 'bar'), $this->getField($c, 'scopes')); - $this->assertSame(array('foo' => array('bar', 'baz'), 'bar' => array('baz'), 'baz' => array()), $this->getField($c, 'scopeChildren')); - } - - public function testHasScope() - { - $c = new Container(); - - $this->assertFalse($c->hasScope('foo')); - $c->addScope(new Scope('foo')); - $this->assertTrue($c->hasScope('foo')); - } - - /** - * @expectedException \Exception - * @expectedExceptionMessage Something went terribly wrong! - */ - public function testGetThrowsException() - { - $c = new ProjectServiceContainer(); - - try { - $c->get('throw_exception'); - } catch (\Exception $e) { - // Do nothing. - } - - // Retry, to make sure that get*Service() will be called. - $c->get('throw_exception'); - } - - public function testGetThrowsExceptionOnServiceConfiguration() - { - $c = new ProjectServiceContainer(); - - try { - $c->get('throws_exception_on_service_configuration'); - } catch (\Exception $e) { - // Do nothing. - } - - $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); - - // Retry, to make sure that get*Service() will be called. - try { - $c->get('throws_exception_on_service_configuration'); - } catch (\Exception $e) { - // Do nothing. - } - $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); - } - - public function testIsScopeActive() - { - $c = new Container(); - - $this->assertFalse($c->isScopeActive('foo')); - $c->addScope(new Scope('foo')); - - $this->assertFalse($c->isScopeActive('foo')); - $c->enterScope('foo'); - - $this->assertTrue($c->isScopeActive('foo')); - $c->leaveScope('foo'); - - $this->assertFalse($c->isScopeActive('foo')); - } - - public function getInvalidParentScopes() - { - return array( - array(ContainerInterface::SCOPE_PROTOTYPE), - array('bar'), - ); - } - - public function getBuiltInScopes() - { - return array( - array(ContainerInterface::SCOPE_CONTAINER), - array(ContainerInterface::SCOPE_PROTOTYPE), - ); - } - - protected function getField($obj, $field) - { - $reflection = new \ReflectionProperty($obj, $field); - $reflection->setAccessible(true); - - return $reflection->getValue($obj); - } - - public function testAlias() - { - $c = new ProjectServiceContainer(); - - $this->assertTrue($c->has('alias')); - $this->assertSame($c->get('alias'), $c->get('bar')); - } -} - -class ProjectServiceContainer extends Container -{ - public $__bar, $__foo_bar, $__foo_baz; - public $synchronized; - - public function __construct() - { - parent::__construct(); - - $this->__bar = new \stdClass(); - $this->__foo_bar = new \stdClass(); - $this->__foo_baz = new \stdClass(); - $this->synchronized = false; - $this->aliases = array('alias' => 'bar'); - } - - protected function getScopedService() - { - if (!$this->isScopeActive('foo')) { - throw new \RuntimeException('Invalid call'); - } - - return $this->services['scoped'] = $this->scopedServices['foo']['scoped'] = new \stdClass(); - } - - protected function getScopedFooService() - { - if (!$this->isScopeActive('foo')) { - throw new \RuntimeException('invalid call'); - } - - return $this->services['scoped_foo'] = $this->scopedServices['foo']['scoped_foo'] = new \stdClass(); - } - - protected function getScopedSynchronizedFooService() - { - if (!$this->isScopeActive('foo')) { - throw new \RuntimeException('invalid call'); - } - - return $this->services['scoped_bar'] = $this->scopedServices['foo']['scoped_bar'] = new \stdClass(); - } - - protected function synchronizeScopedSynchronizedFooService() - { - $this->synchronized = true; - } - - protected function getInactiveService() - { - throw new InactiveScopeException('request', 'request'); - } - - protected function getBarService() - { - return $this->__bar; - } - - protected function getFooBarService() - { - return $this->__foo_bar; - } - - protected function getFoo_BazService() - { - return $this->__foo_baz; - } - - protected function getCircularService() - { - return $this->get('circular'); - } - - protected function getThrowExceptionService() - { - throw new \Exception('Something went terribly wrong!'); - } - - protected function getThrowsExceptionOnServiceConfigurationService() - { - $this->services['throws_exception_on_service_configuration'] = $instance = new \stdClass(); - - throw new \Exception('Something was terribly wrong while trying to configure the service!'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php b/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php deleted file mode 100644 index 692d73dbc..000000000 --- a/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php +++ /dev/null @@ -1,96 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\Config\FileLocator; - -class CrossCheckTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = __DIR__.'/Fixtures/'; - - require_once self::$fixturesPath.'/includes/classes.php'; - require_once self::$fixturesPath.'/includes/foo.php'; - } - - /** - * @dataProvider crossCheckLoadersDumpers - */ - public function testCrossCheck($fixture, $type) - { - $loaderClass = 'Symfony\\Component\\DependencyInjection\\Loader\\'.ucfirst($type).'FileLoader'; - $dumperClass = 'Symfony\\Component\\DependencyInjection\\Dumper\\'.ucfirst($type).'Dumper'; - - $tmp = tempnam('sf_service_container', 'sf'); - - file_put_contents($tmp, file_get_contents(self::$fixturesPath.'/'.$type.'/'.$fixture)); - - $container1 = new ContainerBuilder(); - $loader1 = new $loaderClass($container1, new FileLocator()); - $loader1->load($tmp); - - $dumper = new $dumperClass($container1); - file_put_contents($tmp, $dumper->dump()); - - $container2 = new ContainerBuilder(); - $loader2 = new $loaderClass($container2, new FileLocator()); - $loader2->load($tmp); - - unlink($tmp); - - $this->assertEquals($container2->getAliases(), $container1->getAliases(), 'loading a dump from a previously loaded container returns the same container'); - $this->assertEquals($container2->getDefinitions(), $container1->getDefinitions(), 'loading a dump from a previously loaded container returns the same container'); - $this->assertEquals($container2->getParameterBag()->all(), $container1->getParameterBag()->all(), '->getParameterBag() returns the same value for both containers'); - - $this->assertEquals(serialize($container2), serialize($container1), 'loading a dump from a previously loaded container returns the same container'); - - $services1 = array(); - foreach ($container1 as $id => $service) { - $services1[$id] = serialize($service); - } - $services2 = array(); - foreach ($container2 as $id => $service) { - $services2[$id] = serialize($service); - } - - unset($services1['service_container'], $services2['service_container']); - - $this->assertEquals($services2, $services1, 'Iterator on the containers returns the same services'); - } - - public function crossCheckLoadersDumpers() - { - $tests = array( - array('services1.xml', 'xml'), - array('services2.xml', 'xml'), - array('services6.xml', 'xml'), - array('services8.xml', 'xml'), - array('services9.xml', 'xml'), - ); - - if (class_exists('Symfony\Component\Yaml\Yaml')) { - $tests = array_merge($tests, array( - array('services1.yml', 'yaml'), - array('services2.yml', 'yaml'), - array('services6.yml', 'yaml'), - array('services8.yml', 'yaml'), - array('services9.yml', 'yaml'), - )); - } - - return $tests; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php b/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php deleted file mode 100644 index 732eead14..000000000 --- a/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php +++ /dev/null @@ -1,144 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\DefinitionDecorator; - -class DefinitionDecoratorTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $def = new DefinitionDecorator('foo'); - - $this->assertEquals('foo', $def->getParent()); - $this->assertEquals(array(), $def->getChanges()); - } - - /** - * @dataProvider getPropertyTests - */ - public function testSetProperty($property, $changeKey) - { - $def = new DefinitionDecorator('foo'); - - $getter = 'get'.ucfirst($property); - $setter = 'set'.ucfirst($property); - - $this->assertNull($def->$getter()); - $this->assertSame($def, $def->$setter('foo')); - $this->assertEquals('foo', $def->$getter()); - $this->assertEquals(array($changeKey => true), $def->getChanges()); - } - - public function getPropertyTests() - { - return array( - array('class', 'class'), - array('factory', 'factory'), - array('configurator', 'configurator'), - array('file', 'file'), - ); - } - - /** - * @dataProvider provideLegacyPropertyTests - * @group legacy - */ - public function testLegacySetProperty($property, $changeKey) - { - $def = new DefinitionDecorator('foo'); - - $getter = 'get'.ucfirst($property); - $setter = 'set'.ucfirst($property); - - $this->assertNull($def->$getter()); - $this->assertSame($def, $def->$setter('foo')); - $this->assertEquals('foo', $def->$getter()); - $this->assertEquals(array($changeKey => true), $def->getChanges()); - } - - public function provideLegacyPropertyTests() - { - return array( - array('factoryClass', 'factory_class'), - array('factoryMethod', 'factory_method'), - array('factoryService', 'factory_service'), - ); - } - - public function testSetPublic() - { - $def = new DefinitionDecorator('foo'); - - $this->assertTrue($def->isPublic()); - $this->assertSame($def, $def->setPublic(false)); - $this->assertFalse($def->isPublic()); - $this->assertEquals(array('public' => true), $def->getChanges()); - } - - public function testSetLazy() - { - $def = new DefinitionDecorator('foo'); - - $this->assertFalse($def->isLazy()); - $this->assertSame($def, $def->setLazy(false)); - $this->assertFalse($def->isLazy()); - $this->assertEquals(array('lazy' => true), $def->getChanges()); - } - - public function testSetArgument() - { - $def = new DefinitionDecorator('foo'); - - $this->assertEquals(array(), $def->getArguments()); - $this->assertSame($def, $def->replaceArgument(0, 'foo')); - $this->assertEquals(array('index_0' => 'foo'), $def->getArguments()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testReplaceArgumentShouldRequireIntegerIndex() - { - $def = new DefinitionDecorator('foo'); - - $def->replaceArgument('0', 'foo'); - } - - public function testReplaceArgument() - { - $def = new DefinitionDecorator('foo'); - - $def->setArguments(array(0 => 'foo', 1 => 'bar')); - $this->assertEquals('foo', $def->getArgument(0)); - $this->assertEquals('bar', $def->getArgument(1)); - - $this->assertSame($def, $def->replaceArgument(1, 'baz')); - $this->assertEquals('foo', $def->getArgument(0)); - $this->assertEquals('baz', $def->getArgument(1)); - - $this->assertEquals(array(0 => 'foo', 1 => 'bar', 'index_1' => 'baz'), $def->getArguments()); - } - - /** - * @expectedException \OutOfBoundsException - */ - public function testGetArgumentShouldCheckBounds() - { - $def = new DefinitionDecorator('foo'); - - $def->setArguments(array(0 => 'foo')); - $def->replaceArgument(0, 'foo'); - - $def->getArgument(1); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/DefinitionTest.php b/vendor/symfony/dependency-injection/Tests/DefinitionTest.php deleted file mode 100644 index b501f1183..000000000 --- a/vendor/symfony/dependency-injection/Tests/DefinitionTest.php +++ /dev/null @@ -1,328 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\Definition; - -class DefinitionTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Definition::__construct - */ - public function testConstructor() - { - $def = new Definition('stdClass'); - $this->assertEquals('stdClass', $def->getClass(), '__construct() takes the class name as its first argument'); - - $def = new Definition('stdClass', array('foo')); - $this->assertEquals(array('foo'), $def->getArguments(), '__construct() takes an optional array of arguments as its second argument'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setFactory - * @covers Symfony\Component\DependencyInjection\Definition::getFactory - */ - public function testSetGetFactory() - { - $def = new Definition('stdClass'); - - $this->assertSame($def, $def->setFactory('foo'), '->setFactory() implements a fluent interface'); - $this->assertEquals('foo', $def->getFactory(), '->getFactory() returns the factory'); - - $def->setFactory('Foo::bar'); - $this->assertEquals(array('Foo', 'bar'), $def->getFactory(), '->setFactory() converts string static method call to the array'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setClass - * @covers Symfony\Component\DependencyInjection\Definition::getClass - */ - public function testSetGetClass() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->setClass('foo'), '->setClass() implements a fluent interface'); - $this->assertEquals('foo', $def->getClass(), '->getClass() returns the class name'); - } - - public function testSetGetDecoratedService() - { - $def = new Definition('stdClass'); - $this->assertNull($def->getDecoratedService()); - $def->setDecoratedService('foo', 'foo.renamed'); - $this->assertEquals(array('foo', 'foo.renamed'), $def->getDecoratedService()); - $def->setDecoratedService(null); - $this->assertNull($def->getDecoratedService()); - - $def = new Definition('stdClass'); - $def->setDecoratedService('foo'); - $this->assertEquals(array('foo', null), $def->getDecoratedService()); - $def->setDecoratedService(null); - $this->assertNull($def->getDecoratedService()); - - $def = new Definition('stdClass'); - $this->setExpectedException('InvalidArgumentException', 'The decorated service inner name for "foo" must be different than the service name itself.'); - $def->setDecoratedService('foo', 'foo'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setArguments - * @covers Symfony\Component\DependencyInjection\Definition::getArguments - * @covers Symfony\Component\DependencyInjection\Definition::addArgument - */ - public function testArguments() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->setArguments(array('foo')), '->setArguments() implements a fluent interface'); - $this->assertEquals(array('foo'), $def->getArguments(), '->getArguments() returns the arguments'); - $this->assertSame($def, $def->addArgument('bar'), '->addArgument() implements a fluent interface'); - $this->assertEquals(array('foo', 'bar'), $def->getArguments(), '->addArgument() adds an argument'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setMethodCalls - * @covers Symfony\Component\DependencyInjection\Definition::addMethodCall - * @covers Symfony\Component\DependencyInjection\Definition::hasMethodCall - * @covers Symfony\Component\DependencyInjection\Definition::removeMethodCall - */ - public function testMethodCalls() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->setMethodCalls(array(array('foo', array('foo')))), '->setMethodCalls() implements a fluent interface'); - $this->assertEquals(array(array('foo', array('foo'))), $def->getMethodCalls(), '->getMethodCalls() returns the methods to call'); - $this->assertSame($def, $def->addMethodCall('bar', array('bar')), '->addMethodCall() implements a fluent interface'); - $this->assertEquals(array(array('foo', array('foo')), array('bar', array('bar'))), $def->getMethodCalls(), '->addMethodCall() adds a method to call'); - $this->assertTrue($def->hasMethodCall('bar'), '->hasMethodCall() returns true if first argument is a method to call registered'); - $this->assertFalse($def->hasMethodCall('no_registered'), '->hasMethodCall() returns false if first argument is not a method to call registered'); - $this->assertSame($def, $def->removeMethodCall('bar'), '->removeMethodCall() implements a fluent interface'); - $this->assertEquals(array(array('foo', array('foo'))), $def->getMethodCalls(), '->removeMethodCall() removes a method to call'); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException - * @expectedExceptionMessage Method name cannot be empty. - */ - public function testExceptionOnEmptyMethodCall() - { - $def = new Definition('stdClass'); - $def->addMethodCall(''); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setFile - * @covers Symfony\Component\DependencyInjection\Definition::getFile - */ - public function testSetGetFile() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->setFile('foo'), '->setFile() implements a fluent interface'); - $this->assertEquals('foo', $def->getFile(), '->getFile() returns the file to include'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setScope - * @covers Symfony\Component\DependencyInjection\Definition::getScope - */ - public function testSetGetScope() - { - $def = new Definition('stdClass'); - $this->assertEquals('container', $def->getScope()); - $this->assertSame($def, $def->setScope('foo')); - $this->assertEquals('foo', $def->getScope()); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setPublic - * @covers Symfony\Component\DependencyInjection\Definition::isPublic - */ - public function testSetIsPublic() - { - $def = new Definition('stdClass'); - $this->assertTrue($def->isPublic(), '->isPublic() returns true by default'); - $this->assertSame($def, $def->setPublic(false), '->setPublic() implements a fluent interface'); - $this->assertFalse($def->isPublic(), '->isPublic() returns false if the instance must not be public.'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setSynthetic - * @covers Symfony\Component\DependencyInjection\Definition::isSynthetic - */ - public function testSetIsSynthetic() - { - $def = new Definition('stdClass'); - $this->assertFalse($def->isSynthetic(), '->isSynthetic() returns false by default'); - $this->assertSame($def, $def->setSynthetic(true), '->setSynthetic() implements a fluent interface'); - $this->assertTrue($def->isSynthetic(), '->isSynthetic() returns true if the service is synthetic.'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setSynchronized - * @covers Symfony\Component\DependencyInjection\Definition::isSynchronized - * @group legacy - */ - public function testLegacySetIsSynchronized() - { - $def = new Definition('stdClass'); - $this->assertFalse($def->isSynchronized(), '->isSynchronized() returns false by default'); - $this->assertSame($def, $def->setSynchronized(true), '->setSynchronized() implements a fluent interface'); - $this->assertTrue($def->isSynchronized(), '->isSynchronized() returns true if the service is synchronized.'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setLazy - * @covers Symfony\Component\DependencyInjection\Definition::isLazy - */ - public function testSetIsLazy() - { - $def = new Definition('stdClass'); - $this->assertFalse($def->isLazy(), '->isLazy() returns false by default'); - $this->assertSame($def, $def->setLazy(true), '->setLazy() implements a fluent interface'); - $this->assertTrue($def->isLazy(), '->isLazy() returns true if the service is lazy.'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setAbstract - * @covers Symfony\Component\DependencyInjection\Definition::isAbstract - */ - public function testSetIsAbstract() - { - $def = new Definition('stdClass'); - $this->assertFalse($def->isAbstract(), '->isAbstract() returns false by default'); - $this->assertSame($def, $def->setAbstract(true), '->setAbstract() implements a fluent interface'); - $this->assertTrue($def->isAbstract(), '->isAbstract() returns true if the instance must not be public.'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::setConfigurator - * @covers Symfony\Component\DependencyInjection\Definition::getConfigurator - */ - public function testSetGetConfigurator() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->setConfigurator('foo'), '->setConfigurator() implements a fluent interface'); - $this->assertEquals('foo', $def->getConfigurator(), '->getConfigurator() returns the configurator'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::clearTags - */ - public function testClearTags() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); - $def->addTag('foo', array('foo' => 'bar')); - $def->clearTags(); - $this->assertEquals(array(), $def->getTags(), '->clearTags() removes all current tags'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::clearTags - */ - public function testClearTag() - { - $def = new Definition('stdClass'); - $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); - $def->addTag('1foo1', array('foo1' => 'bar1')); - $def->addTag('2foo2', array('foo2' => 'bar2')); - $def->addTag('3foo3', array('foo3' => 'bar3')); - $def->clearTag('2foo2'); - $this->assertTrue($def->hasTag('1foo1')); - $this->assertFalse($def->hasTag('2foo2')); - $this->assertTrue($def->hasTag('3foo3')); - $def->clearTag('1foo1'); - $this->assertFalse($def->hasTag('1foo1')); - $this->assertTrue($def->hasTag('3foo3')); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::addTag - * @covers Symfony\Component\DependencyInjection\Definition::getTag - * @covers Symfony\Component\DependencyInjection\Definition::getTags - * @covers Symfony\Component\DependencyInjection\Definition::hasTag - */ - public function testTags() - { - $def = new Definition('stdClass'); - $this->assertEquals(array(), $def->getTag('foo'), '->getTag() returns an empty array if the tag is not defined'); - $this->assertFalse($def->hasTag('foo')); - $this->assertSame($def, $def->addTag('foo'), '->addTag() implements a fluent interface'); - $this->assertTrue($def->hasTag('foo')); - $this->assertEquals(array(array()), $def->getTag('foo'), '->getTag() returns attributes for a tag name'); - $def->addTag('foo', array('foo' => 'bar')); - $this->assertEquals(array(array(), array('foo' => 'bar')), $def->getTag('foo'), '->addTag() can adds the same tag several times'); - $def->addTag('bar', array('bar' => 'bar')); - $this->assertEquals($def->getTags(), array( - 'foo' => array(array(), array('foo' => 'bar')), - 'bar' => array(array('bar' => 'bar')), - ), '->getTags() returns all tags'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Definition::replaceArgument - */ - public function testSetArgument() - { - $def = new Definition('stdClass'); - - $def->addArgument('foo'); - $this->assertSame(array('foo'), $def->getArguments()); - - $this->assertSame($def, $def->replaceArgument(0, 'moo')); - $this->assertSame(array('moo'), $def->getArguments()); - - $def->addArgument('moo'); - $def - ->replaceArgument(0, 'foo') - ->replaceArgument(1, 'bar') - ; - $this->assertSame(array('foo', 'bar'), $def->getArguments()); - } - - /** - * @expectedException \OutOfBoundsException - */ - public function testGetArgumentShouldCheckBounds() - { - $def = new Definition('stdClass'); - - $def->addArgument('foo'); - $def->getArgument(1); - } - - /** - * @expectedException \OutOfBoundsException - */ - public function testReplaceArgumentShouldCheckBounds() - { - $def = new Definition('stdClass'); - - $def->addArgument('foo'); - $def->replaceArgument(1, 'bar'); - } - - public function testSetGetProperties() - { - $def = new Definition('stdClass'); - - $this->assertEquals(array(), $def->getProperties()); - $this->assertSame($def, $def->setProperties(array('foo' => 'bar'))); - $this->assertEquals(array('foo' => 'bar'), $def->getProperties()); - } - - public function testSetProperty() - { - $def = new Definition('stdClass'); - - $this->assertEquals(array(), $def->getProperties()); - $this->assertSame($def, $def->setProperty('foo', 'bar')); - $this->assertEquals(array('foo' => 'bar'), $def->getProperties()); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php deleted file mode 100644 index 5da11359f..000000000 --- a/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php +++ /dev/null @@ -1,90 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Dumper; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Dumper\GraphvizDumper; - -class GraphvizDumperTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = __DIR__.'/../Fixtures/'; - } - - /** - * @group legacy - */ - public function testLegacyDump() - { - $container = include self::$fixturesPath.'/containers/legacy-container9.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/legacy-services9.dot')), $dumper->dump(), '->dump() dumps services'); - } - - public function testDump() - { - $dumper = new GraphvizDumper($container = new ContainerBuilder()); - - $this->assertStringEqualsFile(self::$fixturesPath.'/graphviz/services1.dot', $dumper->dump(), '->dump() dumps an empty container as an empty dot file'); - - $container = include self::$fixturesPath.'/containers/container9.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services9.dot')), $dumper->dump(), '->dump() dumps services'); - - $container = include self::$fixturesPath.'/containers/container10.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services10.dot')), $dumper->dump(), '->dump() dumps services'); - - $container = include self::$fixturesPath.'/containers/container10.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals($dumper->dump(array( - 'graph' => array('ratio' => 'normal'), - 'node' => array('fontsize' => 13, 'fontname' => 'Verdana', 'shape' => 'square'), - 'edge' => array('fontsize' => 12, 'fontname' => 'Verdana', 'color' => 'white', 'arrowhead' => 'closed', 'arrowsize' => 1), - 'node.instance' => array('fillcolor' => 'green', 'style' => 'empty'), - 'node.definition' => array('fillcolor' => 'grey'), - 'node.missing' => array('fillcolor' => 'red', 'style' => 'empty'), - )), str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services10-1.dot')), '->dump() dumps services'); - } - - public function testDumpWithFrozenContainer() - { - $container = include self::$fixturesPath.'/containers/container13.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services13.dot')), $dumper->dump(), '->dump() dumps services'); - } - - public function testDumpWithFrozenCustomClassContainer() - { - $container = include self::$fixturesPath.'/containers/container14.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services14.dot')), $dumper->dump(), '->dump() dumps services'); - } - - public function testDumpWithUnresolvedParameter() - { - $container = include self::$fixturesPath.'/containers/container17.php'; - $dumper = new GraphvizDumper($container); - - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services17.dot')), $dumper->dump(), '->dump() dumps services'); - } - - public function testDumpWithScopes() - { - $container = include self::$fixturesPath.'/containers/container18.php'; - $dumper = new GraphvizDumper($container); - $this->assertEquals(str_replace('%path%', __DIR__, file_get_contents(self::$fixturesPath.'/graphviz/services18.dot')), $dumper->dump(), '->dump() dumps services'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php deleted file mode 100644 index 063007e5d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php +++ /dev/null @@ -1,221 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Dumper; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Dumper\PhpDumper; -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Definition; - -class PhpDumperTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - } - - public function testDump() - { - $dumper = new PhpDumper($container = new ContainerBuilder()); - - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services1.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services1-1.php', $dumper->dump(array('class' => 'Container', 'base_class' => 'AbstractContainer', 'namespace' => 'Symfony\Component\DependencyInjection\Dump')), '->dump() takes a class and a base_class options'); - - $container = new ContainerBuilder(); - new PhpDumper($container); - } - - public function testDumpOptimizationString() - { - $definition = new Definition(); - $definition->setClass('stdClass'); - $definition->addArgument(array( - 'only dot' => '.', - 'concatenation as value' => '.\'\'.', - 'concatenation from the start value' => '\'\'.', - '.' => 'dot as a key', - '.\'\'.' => 'concatenation as a key', - '\'\'.' => 'concatenation from the start key', - 'optimize concatenation' => 'string1%some_string%string2', - 'optimize concatenation with empty string' => 'string1%empty_value%string2', - 'optimize concatenation from the start' => '%empty_value%start', - 'optimize concatenation at the end' => 'end%empty_value%', - )); - - $container = new ContainerBuilder(); - $container->setResourceTracking(false); - $container->setDefinition('test', $definition); - $container->setParameter('empty_value', ''); - $container->setParameter('some_string', '-'); - $container->compile(); - - $dumper = new PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services10.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); - } - - public function testDumpRelativeDir() - { - $definition = new Definition(); - $definition->setClass('stdClass'); - $definition->addArgument('%foo%'); - $definition->addArgument(array('%foo%' => '%buz%/')); - - $container = new ContainerBuilder(); - $container->setDefinition('test', $definition); - $container->setParameter('foo', 'wiz'.dirname(__DIR__)); - $container->setParameter('bar', __DIR__); - $container->setParameter('baz', '%bar%/PhpDumperTest.php'); - $container->setParameter('buz', dirname(dirname(__DIR__))); - $container->compile(); - - $dumper = new PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services12.php', $dumper->dump(array('file' => __FILE__)), '->dump() dumps __DIR__ relative strings'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testExportParameters() - { - $dumper = new PhpDumper(new ContainerBuilder(new ParameterBag(array('foo' => new Reference('foo'))))); - $dumper->dump(); - } - - public function testAddParameters() - { - $container = include self::$fixturesPath.'/containers/container8.php'; - $dumper = new PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services8.php', $dumper->dump(), '->dump() dumps parameters'); - } - - public function testAddService() - { - // without compilation - $container = include self::$fixturesPath.'/containers/container9.php'; - $dumper = new PhpDumper($container); - $this->assertEquals(str_replace('%path%', str_replace('\\', '\\\\', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR), file_get_contents(self::$fixturesPath.'/php/services9.php')), $dumper->dump(), '->dump() dumps services'); - - // with compilation - $container = include self::$fixturesPath.'/containers/container9.php'; - $container->compile(); - $dumper = new PhpDumper($container); - $this->assertEquals(str_replace('%path%', str_replace('\\', '\\\\', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR), file_get_contents(self::$fixturesPath.'/php/services9_compiled.php')), $dumper->dump(), '->dump() dumps services'); - - $dumper = new PhpDumper($container = new ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass()); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\Symfony\Component\DependencyInjection\Exception\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - - /** - * @group legacy - */ - public function testLegacySynchronizedServices() - { - $container = include self::$fixturesPath.'/containers/container20.php'; - $dumper = new PhpDumper($container); - $this->assertEquals(str_replace('%path%', str_replace('\\', '\\\\', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR), file_get_contents(self::$fixturesPath.'/php/services20.php')), $dumper->dump(), '->dump() dumps services'); - } - - public function testServicesWithAnonymousFactories() - { - $container = include self::$fixturesPath.'/containers/container19.php'; - $dumper = new PhpDumper($container); - - $this->assertStringEqualsFile(self::$fixturesPath.'/php/services19.php', $dumper->dump(), '->dump() dumps services with anonymous factories'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Service id "bar$" cannot be converted to a valid PHP method name. - */ - public function testAddServiceInvalidServiceId() - { - $container = new ContainerBuilder(); - $container->register('bar$', 'FooClass'); - $dumper = new PhpDumper($container); - $dumper->dump(); - } - - public function testAliases() - { - $container = include self::$fixturesPath.'/containers/container9.php'; - $container->compile(); - $dumper = new PhpDumper($container); - eval('?>'.$dumper->dump(array('class' => 'Symfony_DI_PhpDumper_Test_Aliases'))); - - $container = new \Symfony_DI_PhpDumper_Test_Aliases(); - $container->set('foo', $foo = new \stdClass()); - $this->assertSame($foo, $container->get('foo')); - $this->assertSame($foo, $container->get('alias_for_foo')); - $this->assertSame($foo, $container->get('alias_for_alias')); - } - - public function testFrozenContainerWithoutAliases() - { - $container = new ContainerBuilder(); - $container->compile(); - - $dumper = new PhpDumper($container); - eval('?>'.$dumper->dump(array('class' => 'Symfony_DI_PhpDumper_Test_Frozen_No_Aliases'))); - - $container = new \Symfony_DI_PhpDumper_Test_Frozen_No_Aliases(); - $this->assertFalse($container->has('foo')); - } - - public function testOverrideServiceWhenUsingADumpedContainer() - { - require_once self::$fixturesPath.'/php/services9.php'; - require_once self::$fixturesPath.'/includes/foo.php'; - - $container = new \ProjectServiceContainer(); - $container->set('bar', $bar = new \stdClass()); - $container->setParameter('foo_bar', 'foo_bar'); - - $this->assertEquals($bar, $container->get('bar'), '->set() overrides an already defined service'); - } - - public function testOverrideServiceWhenUsingADumpedContainerAndServiceIsUsedFromAnotherOne() - { - require_once self::$fixturesPath.'/php/services9.php'; - require_once self::$fixturesPath.'/includes/foo.php'; - require_once self::$fixturesPath.'/includes/classes.php'; - - $container = new \ProjectServiceContainer(); - $container->set('bar', $bar = new \stdClass()); - - $this->assertSame($bar, $container->get('foo')->bar, '->set() overrides an already defined service'); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException - */ - public function testCircularReference() - { - $container = new ContainerBuilder(); - $container->register('foo', 'stdClass')->addArgument(new Reference('bar')); - $container->register('bar', 'stdClass')->setPublic(false)->addMethodCall('setA', array(new Reference('baz'))); - $container->register('baz', 'stdClass')->addMethodCall('setA', array(new Reference('foo'))); - $container->compile(); - - $dumper = new PhpDumper($container); - $dumper->dump(); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php deleted file mode 100644 index 8aa544c72..000000000 --- a/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php +++ /dev/null @@ -1,184 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Dumper; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Dumper\XmlDumper; - -class XmlDumperTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - } - - public function testDump() - { - $dumper = new XmlDumper(new ContainerBuilder()); - - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/xml/services1.xml', $dumper->dump(), '->dump() dumps an empty container as an empty XML file'); - } - - public function testExportParameters() - { - $container = include self::$fixturesPath.'//containers/container8.php'; - $dumper = new XmlDumper($container); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); - } - - public function testAddParameters() - { - $container = include self::$fixturesPath.'//containers/container8.php'; - $dumper = new XmlDumper($container); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath.'/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); - } - - /** - * @group legacy - */ - public function testLegacyAddService() - { - $container = include self::$fixturesPath.'/containers/legacy-container9.php'; - $dumper = new XmlDumper($container); - - $this->assertEquals(str_replace('%path%', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR, file_get_contents(self::$fixturesPath.'/xml/legacy-services9.xml')), $dumper->dump(), '->dump() dumps services'); - - $dumper = new XmlDumper($container = new ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass()); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - - public function testAddService() - { - $container = include self::$fixturesPath.'/containers/container9.php'; - $dumper = new XmlDumper($container); - - $this->assertEquals(str_replace('%path%', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR, file_get_contents(self::$fixturesPath.'/xml/services9.xml')), $dumper->dump(), '->dump() dumps services'); - - $dumper = new XmlDumper($container = new ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass()); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - - public function testDumpAnonymousServices() - { - $container = include self::$fixturesPath.'/containers/container11.php'; - $dumper = new XmlDumper($container); - $this->assertEquals(' - - - - - - - - - - - - - -', $dumper->dump()); - } - - public function testDumpEntities() - { - $container = include self::$fixturesPath.'/containers/container12.php'; - $dumper = new XmlDumper($container); - $this->assertEquals(" - - - - - foo<>&bar - - - -", $dumper->dump()); - } - - /** - * @dataProvider provideDecoratedServicesData - */ - public function testDumpDecoratedServices($expectedXmlDump, $container) - { - $dumper = new XmlDumper($container); - $this->assertEquals($expectedXmlDump, $dumper->dump()); - } - - public function provideDecoratedServicesData() - { - $fixturesPath = realpath(__DIR__.'/../Fixtures/'); - - return array( - array(" - - - - - -", include $fixturesPath.'/containers/container15.php'), - array(" - - - - - -", include $fixturesPath.'/containers/container16.php'), - ); - } - - /** - * @dataProvider provideCompiledContainerData - */ - public function testCompiledContainerCanBeDumped($containerFile) - { - $fixturesPath = __DIR__.'/../Fixtures'; - $container = require $fixturesPath.'/containers/'.$containerFile.'.php'; - $container->compile(); - $dumper = new XmlDumper($container); - $dumper->dump(); - } - - public function provideCompiledContainerData() - { - return array( - array('container8'), - array('container9'), - array('container11'), - array('container12'), - array('container14'), - ); - } - - public function testDumpInlinedServices() - { - $container = include self::$fixturesPath.'/containers/container21.php'; - $dumper = new XmlDumper($container); - - $this->assertEquals(file_get_contents(self::$fixturesPath.'/xml/services21.xml'), $dumper->dump()); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php deleted file mode 100644 index 8e9f1174c..000000000 --- a/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php +++ /dev/null @@ -1,80 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Dumper; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Dumper\YamlDumper; - -class YamlDumperTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - } - - public function testDump() - { - $dumper = new YamlDumper($container = new ContainerBuilder()); - - $this->assertStringEqualsFile(self::$fixturesPath.'/yaml/services1.yml', $dumper->dump(), '->dump() dumps an empty container as an empty YAML file'); - - $container = new ContainerBuilder(); - $dumper = new YamlDumper($container); - } - - public function testAddParameters() - { - $container = include self::$fixturesPath.'/containers/container8.php'; - $dumper = new YamlDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath.'/yaml/services8.yml', $dumper->dump(), '->dump() dumps parameters'); - } - - /** - * @group legacy - */ - public function testLegacyAddService() - { - $container = include self::$fixturesPath.'/containers/legacy-container9.php'; - $dumper = new YamlDumper($container); - - $this->assertEquals(str_replace('%path%', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR, file_get_contents(self::$fixturesPath.'/yaml/legacy-services9.yml')), $dumper->dump(), '->dump() dumps services'); - - $dumper = new YamlDumper($container = new ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass()); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - - public function testAddService() - { - $container = include self::$fixturesPath.'/containers/container9.php'; - $dumper = new YamlDumper($container); - $this->assertEquals(str_replace('%path%', self::$fixturesPath.DIRECTORY_SEPARATOR.'includes'.DIRECTORY_SEPARATOR, file_get_contents(self::$fixturesPath.'/yaml/services9.yml')), $dumper->dump(), '->dump() dumps services'); - - $dumper = new YamlDumper($container = new ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass()); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php b/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php deleted file mode 100644 index e7f19a6e9..000000000 --- a/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php +++ /dev/null @@ -1,81 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Extension; - -class ExtensionTest extends \PHPUnit_Framework_TestCase -{ - /** - * @dataProvider getResolvedEnabledFixtures - */ - public function testIsConfigEnabledReturnsTheResolvedValue($enabled) - { - $pb = $this->getMockBuilder('Symfony\Component\DependencyInjection\ParameterBag\ParameterBag') - ->setMethods(array('resolveValue')) - ->getMock() - ; - - $container = $this->getMockBuilder('Symfony\Component\DependencyInjection\ContainerBuilder') - ->setMethods(array('getParameterBag')) - ->getMock() - ; - - $pb->expects($this->once()) - ->method('resolveValue') - ->with($this->equalTo($enabled)) - ->will($this->returnValue($enabled)) - ; - - $container->expects($this->once()) - ->method('getParameterBag') - ->will($this->returnValue($pb)) - ; - - $extension = $this->getMockBuilder('Symfony\Component\DependencyInjection\Extension\Extension') - ->setMethods(array()) - ->getMockForAbstractClass() - ; - - $r = new \ReflectionMethod('Symfony\Component\DependencyInjection\Extension\Extension', 'isConfigEnabled'); - $r->setAccessible(true); - - $r->invoke($extension, $container, array('enabled' => $enabled)); - } - - public function getResolvedEnabledFixtures() - { - return array( - array(true), - array(false), - ); - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException - * @expectedExceptionMessage The config array has no 'enabled' key. - */ - public function testIsConfigEnabledOnNonEnableableConfig() - { - $container = $this->getMockBuilder('Symfony\Component\DependencyInjection\ContainerBuilder') - ->getMock() - ; - - $extension = $this->getMockBuilder('Symfony\Component\DependencyInjection\Extension\Extension') - ->setMethods(array()) - ->getMockForAbstractClass() - ; - - $r = new \ReflectionMethod('Symfony\Component\DependencyInjection\Extension\Extension', 'isConfigEnabled'); - $r->setAccessible(true); - - $r->invoke($extension, $container, array()); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container10.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container10.php deleted file mode 100644 index a16ca9fff..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container10.php +++ /dev/null @@ -1,14 +0,0 @@ - - register('foo', 'FooClass')-> - addArgument(new Reference('bar')) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php deleted file mode 100644 index 3e6cafca2..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php +++ /dev/null @@ -1,12 +0,0 @@ - - register('foo', 'FooClass')-> - addArgument(new Definition('BarClass', array(new Definition('BazClass')))) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php deleted file mode 100644 index 73c5b4ef1..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php +++ /dev/null @@ -1,12 +0,0 @@ - - register('foo', 'FooClass\\Foo')-> - addArgument('foo<>&bar')-> - addTag('foo"bar\\bar', array('foo' => 'foo"barřž€')) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php deleted file mode 100644 index cc716c78f..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php +++ /dev/null @@ -1,16 +0,0 @@ - - register('foo', 'FooClass')-> - addArgument(new Reference('bar')) -; -$container-> - register('bar', 'BarClass') -; -$container->compile(); - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php deleted file mode 100644 index 56ea6c1ed..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php +++ /dev/null @@ -1,17 +0,0 @@ -register('foo', 'FooClass\\Foo') - ->setDecoratedService('bar', 'bar.woozy') -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php deleted file mode 100644 index 67b4d353d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php +++ /dev/null @@ -1,11 +0,0 @@ -register('foo', 'FooClass\\Foo') - ->setDecoratedService('bar') -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php deleted file mode 100644 index d902ec2a3..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php +++ /dev/null @@ -1,10 +0,0 @@ -register('foo', '%foo.class%') -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container18.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container18.php deleted file mode 100644 index 0248ed462..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container18.php +++ /dev/null @@ -1,14 +0,0 @@ -addScope(new Scope('request')); -$container-> - register('foo', 'FooClass')-> - setScope('request') -; -$container->compile(); - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php deleted file mode 100644 index 64b8f066d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php +++ /dev/null @@ -1,22 +0,0 @@ -register('service_from_anonymous_factory', 'Bar\FooClass') - ->setFactory(array(new Definition('Bar\FooClass'), 'getInstance')) -; - -$anonymousServiceWithFactory = new Definition('Bar\FooClass'); -$anonymousServiceWithFactory->setFactory('Bar\FooClass::getInstance'); -$container - ->register('service_with_method_call_and_factory', 'Bar\FooClass') - ->addMethodCall('setBar', array($anonymousServiceWithFactory)) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container20.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container20.php deleted file mode 100644 index a40a0e8a6..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container20.php +++ /dev/null @@ -1,19 +0,0 @@ -register('request', 'Request') - ->setSynchronized(true) -; -$container - ->register('depends_on_request', 'stdClass') - ->addMethodCall('setRequest', array(new Reference('request', ContainerInterface::NULL_ON_INVALID_REFERENCE, false))) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php deleted file mode 100644 index d04673861..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php +++ /dev/null @@ -1,20 +0,0 @@ -setConfigurator(array(new Definition('Baz'), 'configureBar')); - -$fooFactory = new Definition('FooFactory'); -$fooFactory->setFactory(array(new Definition('Foobar'), 'createFooFactory')); - -$container - ->register('foo', 'Foo') - ->setFactory(array($fooFactory, 'createFoo')) - ->setConfigurator(array($bar, 'configureFoo')) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php deleted file mode 100644 index f0b4ca933..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php +++ /dev/null @@ -1,14 +0,0 @@ - '%baz%', - 'baz' => 'bar', - 'bar' => 'foo is %%foo bar', - 'escape' => '@escapeme', - 'values' => array(true, false, null, 0, 1000.3, 'true', 'false', 'null'), -))); - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php deleted file mode 100644 index 47064c302..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php +++ /dev/null @@ -1,113 +0,0 @@ -register('foo', '\Bar\FooClass') - ->addTag('foo', array('foo' => 'foo')) - ->addTag('foo', array('bar' => 'bar', 'baz' => 'baz')) - ->setFactory(array('Bar\\FooClass', 'getInstance')) - ->setArguments(array('foo', new Reference('foo.baz'), array('%foo%' => 'foo is %foo%', 'foobar' => '%foo%'), true, new Reference('service_container'))) - ->setProperties(array('foo' => 'bar', 'moo' => new Reference('foo.baz'), 'qux' => array('%foo%' => 'foo is %foo%', 'foobar' => '%foo%'))) - ->addMethodCall('setBar', array(new Reference('bar'))) - ->addMethodCall('initialize') - ->setConfigurator('sc_configure') -; -$container - ->register('foo.baz', '%baz_class%') - ->setFactory(array('%baz_class%', 'getInstance')) - ->setConfigurator(array('%baz_class%', 'configureStatic1')) -; -$container - ->register('bar', 'Bar\FooClass') - ->setArguments(array('foo', new Reference('foo.baz'), new Parameter('foo_bar'))) - ->setScope('container') - ->setConfigurator(array(new Reference('foo.baz'), 'configure')) -; -$container - ->register('foo_bar', '%foo_class%') - ->setScope('prototype') -; -$container->getParameterBag()->clear(); -$container->getParameterBag()->add(array( - 'baz_class' => 'BazClass', - 'foo_class' => 'Bar\FooClass', - 'foo' => 'bar', -)); -$container->setAlias('alias_for_foo', 'foo'); -$container->setAlias('alias_for_alias', 'alias_for_foo'); -$container - ->register('method_call1', 'Bar\FooClass') - ->setFile(realpath(__DIR__.'/../includes/foo.php')) - ->addMethodCall('setBar', array(new Reference('foo'))) - ->addMethodCall('setBar', array(new Reference('foo2', ContainerInterface::NULL_ON_INVALID_REFERENCE))) - ->addMethodCall('setBar', array(new Reference('foo3', ContainerInterface::IGNORE_ON_INVALID_REFERENCE))) - ->addMethodCall('setBar', array(new Reference('foobaz', ContainerInterface::IGNORE_ON_INVALID_REFERENCE))) - ->addMethodCall('setBar', array(new Expression('service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")'))) -; -$container - ->register('foo_with_inline', 'Foo') - ->addMethodCall('setBar', array(new Reference('inlined'))) -; -$container - ->register('inlined', 'Bar') - ->setProperty('pub', 'pub') - ->addMethodCall('setBaz', array(new Reference('baz'))) - ->setPublic(false) -; -$container - ->register('baz', 'Baz') - ->addMethodCall('setFoo', array(new Reference('foo_with_inline'))) -; -$container - ->register('request', 'Request') - ->setSynthetic(true) -; -$container - ->register('configurator_service', 'ConfClass') - ->setPublic(false) - ->addMethodCall('setFoo', array(new Reference('baz'))) -; -$container - ->register('configured_service', 'stdClass') - ->setConfigurator(array(new Reference('configurator_service'), 'configureStdClass')) -; -$container - ->register('decorated', 'stdClass') -; -$container - ->register('decorator_service', 'stdClass') - ->setDecoratedService('decorated') -; -$container - ->register('decorator_service_with_name', 'stdClass') - ->setDecoratedService('decorated', 'decorated.pif-pouf') -; -$container - ->register('new_factory', 'FactoryClass') - ->setProperty('foo', 'bar') - ->setScope('container') - ->setPublic(false) -; -$container - ->register('factory_service', 'Bar') - ->setFactory(array(new Reference('foo.baz'), 'getInstance')) -; -$container - ->register('new_factory_service', 'FooBarBaz') - ->setProperty('foo', 'bar') - ->setFactory(array(new Reference('new_factory'), 'getInstance')) -; -$container - ->register('service_from_static_method', 'Bar\FooClass') - ->setFactory(array('Bar\FooClass', 'getInstance')) -; - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/legacy-container9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/legacy-container9.php deleted file mode 100644 index 9f4210c9d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/legacy-container9.php +++ /dev/null @@ -1,39 +0,0 @@ - - register('foo', 'Bar\FooClass')-> - addTag('foo', array('foo' => 'foo'))-> - addTag('foo', array('bar' => 'bar'))-> - setFactoryClass('Bar\\FooClass')-> - setFactoryMethod('getInstance')-> - setArguments(array('foo', new Reference('foo.baz'), array('%foo%' => 'foo is %foo%', 'foobar' => '%foo%'), true, new Reference('service_container')))-> - setProperties(array('foo' => 'bar', 'moo' => new Reference('foo.baz'), 'qux' => array('%foo%' => 'foo is %foo%', 'foobar' => '%foo%')))-> - addMethodCall('setBar', array(new Reference('bar')))-> - addMethodCall('initialize')-> - setConfigurator('sc_configure') -; -$container-> - register('foo.baz', '%baz_class%')-> - setFactoryClass('%baz_class%')-> - setFactoryMethod('getInstance')-> - setConfigurator(array('%baz_class%', 'configureStatic1')) -; -$container-> - register('factory_service', 'Bar')-> - setFactoryService('foo.baz')-> - setFactoryMethod('getInstance') -; -$container->getParameterBag()->clear(); -$container->getParameterBag()->add(array( - 'baz_class' => 'BazClass', - 'foo' => 'bar', -)); - -return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/legacy-services9.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/legacy-services9.dot deleted file mode 100644 index 4e8dfb977..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/legacy-services9.dot +++ /dev/null @@ -1,15 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_baz [label="foo.baz\nBazClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_factory_service [label="factory_service\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; - node_bar [label="bar\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo -> node_foo_baz [label="" style="filled"]; - node_foo -> node_service_container [label="" style="filled"]; - node_foo -> node_foo_baz [label="" style="dashed"]; - node_foo -> node_bar [label="setBar()" style="dashed"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot deleted file mode 100644 index 1bb7c30b8..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot +++ /dev/null @@ -1,7 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot deleted file mode 100644 index 0e578b161..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot +++ /dev/null @@ -1,10 +0,0 @@ -digraph sc { - ratio="normal" - node [fontsize="13" fontname="Verdana" shape="square"]; - edge [fontsize="12" fontname="Verdana" color="white" arrowhead="closed" arrowsize="1"]; - - node_foo [label="foo\nFooClass\n", shape=square, fillcolor="grey", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=square, fillcolor="green", style="empty"]; - node_bar [label="bar\n\n", shape=square, fillcolor="red", style="empty"]; - node_foo -> node_bar [label="" style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot deleted file mode 100644 index f17857fe4..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot +++ /dev/null @@ -1,10 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; - node_bar [label="bar\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo -> node_bar [label="" style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot deleted file mode 100644 index bc7f81317..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot +++ /dev/null @@ -1,10 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\nBarClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; - node_foo -> node_bar [label="" style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot deleted file mode 100644 index d07dc389e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot +++ /dev/null @@ -1,7 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container\nContainer14\\ProjectServiceContainer\n", shape=record, fillcolor="#9999ff", style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot deleted file mode 100644 index a6d04bf5a..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot +++ /dev/null @@ -1,8 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\n%foo.class%\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot deleted file mode 100644 index 4fbcceef3..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot +++ /dev/null @@ -1,8 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot deleted file mode 100644 index b3b424e2e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot +++ /dev/null @@ -1,41 +0,0 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo (alias_for_foo)\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_baz [label="foo.baz\nBazClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_bar [label="foo_bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="dotted"]; - node_method_call1 [label="method_call1\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_with_inline [label="foo_with_inline\nFoo\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_inlined [label="inlined\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_baz [label="baz\nBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_request [label="request\nRequest\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configurator_service [label="configurator_service\nConfClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configured_service [label="configured_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorated [label="decorated\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorator_service [label="decorator_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorator_service_with_name [label="decorator_service_with_name\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_new_factory [label="new_factory\nFactoryClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_factory_service [label="factory_service\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_new_factory_service [label="new_factory_service\nFooBarBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_from_static_method [label="service_from_static_method\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; - node_foo2 [label="foo2\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo3 [label="foo3\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foobaz [label="foobaz\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo -> node_foo_baz [label="" style="filled"]; - node_foo -> node_service_container [label="" style="filled"]; - node_foo -> node_foo_baz [label="" style="dashed"]; - node_foo -> node_bar [label="setBar()" style="dashed"]; - node_bar -> node_foo_baz [label="" style="filled"]; - node_method_call1 -> node_foo [label="setBar()" style="dashed"]; - node_method_call1 -> node_foo2 [label="setBar()" style="dashed"]; - node_method_call1 -> node_foo3 [label="setBar()" style="dashed"]; - node_method_call1 -> node_foobaz [label="setBar()" style="dashed"]; - node_foo_with_inline -> node_inlined [label="setBar()" style="dashed"]; - node_inlined -> node_baz [label="setBaz()" style="dashed"]; - node_baz -> node_foo_with_inline [label="setFoo()" style="dashed"]; - node_configurator_service -> node_baz [label="setFoo()" style="dashed"]; -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php deleted file mode 100644 index c9f801026..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php +++ /dev/null @@ -1,40 +0,0 @@ -setDefinition('project.service.bar', new Definition('FooClass')); - $configuration->setParameter('project.parameter.bar', isset($config['foo']) ? $config['foo'] : 'foobar'); - - $configuration->setDefinition('project.service.foo', new Definition('FooClass')); - $configuration->setParameter('project.parameter.foo', isset($config['foo']) ? $config['foo'] : 'foobar'); - - return $configuration; - } - - public function getXsdValidationBasePath() - { - return false; - } - - public function getNamespace() - { - return 'http://www.example.com/schema/project'; - } - - public function getAlias() - { - return 'project'; - } - - public function getConfiguration(array $config, ContainerBuilder $container) - { - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php deleted file mode 100644 index 2ee2f12dc..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php +++ /dev/null @@ -1,19 +0,0 @@ -9ZF829)cP2qlv4X_J zzrf1OpTLe_VeL-5W{LMstcEZy0@`@Zkp``){HON4^-Lnf=$gbDLerhScQua<{zIcIFuhk!dy`p zv$5$^oT&;v%oye^<(nUKM%|cd+kVWHBL6%g0b_2kKrOtsU)Tg6kqzU>C!>t}8Y@7? zps^y4SsVq-EVP+|KGR`&J%<-0LzJL1$PcECD5$56cuw zq1FNmJ()}#n6gB~;P`1W)1Nyu!PY^8B5vAZWzelSVrpr?ndyI*JgK*)Nlc!BG#%QY zSQ$!y`zgjAH|YLgcjFGl-m&dEo~K&4K#;;!gZ_UiH1{p1S5fbb#N@V<%CUQ^QrUD5 zd)-HQ%M=97Bvx+W?HSrRO)P{Uh6K3YO=YqTBbLRwL60+RhfxFp#ViTQ^PJ%b$8t94 z5HBpz&&B-H{R70(VFjlH+&l$t=4s|iOluhpGdxRt^D12{q)9@x8^$EYxml}0Tm>CJpcdz diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php deleted file mode 100644 index 70c3d275b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php +++ /dev/null @@ -1,61 +0,0 @@ -configure(); -} - -class BarClass -{ - protected $baz; - public $foo = 'foo'; - - public function setBaz(BazClass $baz) - { - $this->baz = $baz; - } - - public function getBaz() - { - return $this->baz; - } -} - -class BazClass -{ - protected $foo; - - public function setFoo(Foo $foo) - { - $this->foo = $foo; - } - - public function configure($instance) - { - $instance->configure(); - } - - public static function getInstance() - { - return new self(); - } - - public static function configureStatic($instance) - { - $instance->configure(); - } - - public static function configureStatic1() - { - } -} - -class BarUserClass -{ - public $bar; - - public function __construct(BarClass $bar) - { - $this->bar = $bar; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php deleted file mode 100644 index 5fa06a0eb..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php +++ /dev/null @@ -1,47 +0,0 @@ -addFromString('ProjectWithXsdExtensionInPhar.php', <<addFromString('schema/project-1.0.xsd', << - - - - - - - - - -EOT -); -$phar->setStub(''); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php deleted file mode 100644 index 55968aff9..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php +++ /dev/null @@ -1,38 +0,0 @@ -arguments = $arguments; - } - - public static function getInstance($arguments = array()) - { - $obj = new self($arguments); - $obj->called = true; - - return $obj; - } - - public function initialize() - { - $this->initialized = true; - } - - public function configure() - { - $this->configured = true; - } - - public function setBar($value = null) - { - $this->bar = $value; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd deleted file mode 100644 index 282884e4e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini deleted file mode 100644 index 9f84a6087..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini +++ /dev/null @@ -1,2 +0,0 @@ -{NOT AN INI FILE} -{JUST A PLAIN TEXT FILE} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini deleted file mode 100644 index df92f7527..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini +++ /dev/null @@ -1,3 +0,0 @@ -[parameters] - foo = bar - bar = %foo% diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini deleted file mode 100644 index e50f7222b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini +++ /dev/null @@ -1,3 +0,0 @@ -[parameters] - FOO = foo - baz = baz diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini deleted file mode 100644 index 75fbac628..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini +++ /dev/null @@ -1,2 +0,0 @@ -[parameters] - imported_from_ini = true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php deleted file mode 100644 index f15771172..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php +++ /dev/null @@ -1,30 +0,0 @@ -parameters = $this->getDefaultParameters(); - - $this->services = - $this->scopedServices = - $this->scopeStacks = array(); - $this->scopes = array(); - $this->scopeChildren = array(); - $this->methodMap = array( - 'test' => 'getTestService', - ); - - $this->aliases = array(); - } - - /** - * {@inheritdoc} - */ - public function compile() - { - throw new LogicException('You cannot compile a dumped frozen container.'); - } - - /** - * Gets the 'test' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getTestService() - { - return $this->services['test'] = new \stdClass(array('only dot' => '.', 'concatenation as value' => '.\'\'.', 'concatenation from the start value' => '\'\'.', '.' => 'dot as a key', '.\'\'.' => 'concatenation as a key', '\'\'.' => 'concatenation from the start key', 'optimize concatenation' => 'string1-string2', 'optimize concatenation with empty string' => 'string1string2', 'optimize concatenation from the start' => 'start', 'optimize concatenation at the end' => 'end')); - } - - /** - * {@inheritdoc} - */ - public function getParameter($name) - { - $name = strtolower($name); - - if (!(isset($this->parameters[$name]) || array_key_exists($name, $this->parameters))) { - throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); - } - - return $this->parameters[$name]; - } - - /** - * {@inheritdoc} - */ - public function hasParameter($name) - { - $name = strtolower($name); - - return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters); - } - - /** - * {@inheritdoc} - */ - public function setParameter($name, $value) - { - throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - - /** - * {@inheritdoc} - */ - public function getParameterBag() - { - if (null === $this->parameterBag) { - $this->parameterBag = new FrozenParameterBag($this->parameters); - } - - return $this->parameterBag; - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return array( - 'empty_value' => '', - 'some_string' => '-', - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php deleted file mode 100644 index a53f3a3e8..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php +++ /dev/null @@ -1,124 +0,0 @@ -targetDirs[$i] = $dir = dirname($dir); - } - $this->parameters = $this->getDefaultParameters(); - - $this->services = - $this->scopedServices = - $this->scopeStacks = array(); - $this->scopes = array(); - $this->scopeChildren = array(); - $this->methodMap = array( - 'test' => 'getTestService', - ); - - $this->aliases = array(); - } - - /** - * {@inheritdoc} - */ - public function compile() - { - throw new LogicException('You cannot compile a dumped frozen container.'); - } - - /** - * Gets the 'test' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getTestService() - { - return $this->services['test'] = new \stdClass(('wiz'.$this->targetDirs[1]), array(('wiz'.$this->targetDirs[1]) => ($this->targetDirs[2].'/'))); - } - - /** - * {@inheritdoc} - */ - public function getParameter($name) - { - $name = strtolower($name); - - if (!(isset($this->parameters[$name]) || array_key_exists($name, $this->parameters))) { - throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); - } - - return $this->parameters[$name]; - } - - /** - * {@inheritdoc} - */ - public function hasParameter($name) - { - $name = strtolower($name); - - return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters); - } - - /** - * {@inheritdoc} - */ - public function setParameter($name, $value) - { - throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - - /** - * {@inheritdoc} - */ - public function getParameterBag() - { - if (null === $this->parameterBag) { - $this->parameterBag = new FrozenParameterBag($this->parameters); - } - - return $this->parameterBag; - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return array( - 'foo' => ('wiz'.$this->targetDirs[1]), - 'bar' => __DIR__, - 'baz' => (__DIR__.'/PhpDumperTest.php'), - 'buz' => $this->targetDirs[2], - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php deleted file mode 100644 index 455600da7..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php +++ /dev/null @@ -1,63 +0,0 @@ -methodMap = array( - 'service_from_anonymous_factory' => 'getServiceFromAnonymousFactoryService', - 'service_with_method_call_and_factory' => 'getServiceWithMethodCallAndFactoryService', - ); - } - - /** - * Gets the 'service_from_anonymous_factory' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getServiceFromAnonymousFactoryService() - { - return $this->services['service_from_anonymous_factory'] = call_user_func(array(new \Bar\FooClass(), 'getInstance')); - } - - /** - * Gets the 'service_with_method_call_and_factory' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getServiceWithMethodCallAndFactoryService() - { - $this->services['service_with_method_call_and_factory'] = $instance = new \Bar\FooClass(); - - $instance->setBar(\Bar\FooClass::getInstance()); - - return $instance; - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services20.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services20.php deleted file mode 100644 index 83f6dc7ed..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services20.php +++ /dev/null @@ -1,73 +0,0 @@ -methodMap = array( - 'depends_on_request' => 'getDependsOnRequestService', - 'request' => 'getRequestService', - ); - } - - /** - * Gets the 'depends_on_request' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDependsOnRequestService() - { - $this->services['depends_on_request'] = $instance = new \stdClass(); - - $instance->setRequest($this->get('request', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - - return $instance; - } - - /** - * Gets the 'request' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Request A Request instance. - */ - protected function getRequestService() - { - return $this->services['request'] = new \Request(); - } - - /** - * Updates the 'request' service. - */ - protected function synchronizeRequestService() - { - if ($this->initialized('depends_on_request')) { - $this->get('depends_on_request')->setRequest($this->get('request', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php deleted file mode 100644 index c2c52fe33..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php +++ /dev/null @@ -1,54 +0,0 @@ -getDefaultParameters())); - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return array( - 'foo' => '%baz%', - 'baz' => 'bar', - 'bar' => 'foo is %%foo bar', - 'escape' => '@escapeme', - 'values' => array( - 0 => true, - 1 => false, - 2 => NULL, - 3 => 0, - 4 => 1000.3, - 5 => 'true', - 6 => 'false', - 7 => 'null', - ), - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php deleted file mode 100644 index 5977c1c6e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php +++ /dev/null @@ -1,376 +0,0 @@ -getDefaultParameters())); - $this->methodMap = array( - 'bar' => 'getBarService', - 'baz' => 'getBazService', - 'configurator_service' => 'getConfiguratorServiceService', - 'configured_service' => 'getConfiguredServiceService', - 'decorated' => 'getDecoratedService', - 'decorator_service' => 'getDecoratorServiceService', - 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', - 'factory_service' => 'getFactoryServiceService', - 'foo' => 'getFooService', - 'foo.baz' => 'getFoo_BazService', - 'foo_bar' => 'getFooBarService', - 'foo_with_inline' => 'getFooWithInlineService', - 'inlined' => 'getInlinedService', - 'method_call1' => 'getMethodCall1Service', - 'new_factory' => 'getNewFactoryService', - 'new_factory_service' => 'getNewFactoryServiceService', - 'request' => 'getRequestService', - 'service_from_static_method' => 'getServiceFromStaticMethodService', - ); - $this->aliases = array( - 'alias_for_alias' => 'foo', - 'alias_for_foo' => 'foo', - ); - } - - /** - * Gets the 'bar' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getBarService() - { - $a = $this->get('foo.baz'); - - $this->services['bar'] = $instance = new \Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); - - $a->configure($instance); - - return $instance; - } - - /** - * Gets the 'baz' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Baz A Baz instance. - */ - protected function getBazService() - { - $this->services['baz'] = $instance = new \Baz(); - - $instance->setFoo($this->get('foo_with_inline')); - - return $instance; - } - - /** - * Gets the 'configured_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getConfiguredServiceService() - { - $this->services['configured_service'] = $instance = new \stdClass(); - - $this->get('configurator_service')->configureStdClass($instance); - - return $instance; - } - - /** - * Gets the 'decorated' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDecoratedService() - { - return $this->services['decorated'] = new \stdClass(); - } - - /** - * Gets the 'decorator_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDecoratorServiceService() - { - return $this->services['decorator_service'] = new \stdClass(); - } - - /** - * Gets the 'decorator_service_with_name' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDecoratorServiceWithNameService() - { - return $this->services['decorator_service_with_name'] = new \stdClass(); - } - - /** - * Gets the 'factory_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar A Bar instance. - */ - protected function getFactoryServiceService() - { - return $this->services['factory_service'] = $this->get('foo.baz')->getInstance(); - } - - /** - * Gets the 'foo' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getFooService() - { - $a = $this->get('foo.baz'); - - $this->services['foo'] = $instance = \Bar\FooClass::getInstance('foo', $a, array($this->getParameter('foo') => 'foo is '.$this->getParameter('foo').'', 'foobar' => $this->getParameter('foo')), true, $this); - - $instance->setBar($this->get('bar')); - $instance->initialize(); - $instance->foo = 'bar'; - $instance->moo = $a; - $instance->qux = array($this->getParameter('foo') => 'foo is '.$this->getParameter('foo').'', 'foobar' => $this->getParameter('foo')); - sc_configure($instance); - - return $instance; - } - - /** - * Gets the 'foo.baz' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return object A %baz_class% instance. - */ - protected function getFoo_BazService() - { - $this->services['foo.baz'] = $instance = call_user_func(array($this->getParameter('baz_class'), 'getInstance')); - - call_user_func(array($this->getParameter('baz_class'), 'configureStatic1'), $instance); - - return $instance; - } - - /** - * Gets the 'foo_bar' service. - * - * @return object A %foo_class% instance. - */ - protected function getFooBarService() - { - $class = $this->getParameter('foo_class'); - - return new $class(); - } - - /** - * Gets the 'foo_with_inline' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Foo A Foo instance. - */ - protected function getFooWithInlineService() - { - $this->services['foo_with_inline'] = $instance = new \Foo(); - - $instance->setBar($this->get('inlined')); - - return $instance; - } - - /** - * Gets the 'method_call1' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getMethodCall1Service() - { - require_once '%path%foo.php'; - - $this->services['method_call1'] = $instance = new \Bar\FooClass(); - - $instance->setBar($this->get('foo')); - $instance->setBar($this->get('foo2', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - if ($this->has('foo3')) { - $instance->setBar($this->get('foo3', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - if ($this->has('foobaz')) { - $instance->setBar($this->get('foobaz', ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - $instance->setBar(($this->get("foo")->foo() . (($this->hasparameter("foo")) ? ($this->getParameter("foo")) : ("default")))); - - return $instance; - } - - /** - * Gets the 'new_factory_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \FooBarBaz A FooBarBaz instance. - */ - protected function getNewFactoryServiceService() - { - $this->services['new_factory_service'] = $instance = $this->get('new_factory')->getInstance(); - - $instance->foo = 'bar'; - - return $instance; - } - - /** - * Gets the 'request' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @throws RuntimeException always since this service is expected to be injected dynamically - */ - protected function getRequestService() - { - throw new RuntimeException('You have requested a synthetic service ("request"). The DIC does not know how to construct this service.'); - } - - /** - * Gets the 'service_from_static_method' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getServiceFromStaticMethodService() - { - return $this->services['service_from_static_method'] = \Bar\FooClass::getInstance(); - } - - /** - * Gets the 'configurator_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * This service is private. - * If you want to be able to request this service from the container directly, - * make it public, otherwise you might end up with broken code. - * - * @return \ConfClass A ConfClass instance. - */ - protected function getConfiguratorServiceService() - { - $this->services['configurator_service'] = $instance = new \ConfClass(); - - $instance->setFoo($this->get('baz')); - - return $instance; - } - - /** - * Gets the 'inlined' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * This service is private. - * If you want to be able to request this service from the container directly, - * make it public, otherwise you might end up with broken code. - * - * @return \Bar A Bar instance. - */ - protected function getInlinedService() - { - $this->services['inlined'] = $instance = new \Bar(); - - $instance->setBaz($this->get('baz')); - $instance->pub = 'pub'; - - return $instance; - } - - /** - * Gets the 'new_factory' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * This service is private. - * If you want to be able to request this service from the container directly, - * make it public, otherwise you might end up with broken code. - * - * @return \FactoryClass A FactoryClass instance. - */ - protected function getNewFactoryService() - { - $this->services['new_factory'] = $instance = new \FactoryClass(); - - $instance->foo = 'bar'; - - return $instance; - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return array( - 'baz_class' => 'BazClass', - 'foo_class' => 'Bar\\FooClass', - 'foo' => 'bar', - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php deleted file mode 100644 index 8c1e71f43..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php +++ /dev/null @@ -1,357 +0,0 @@ -parameters = $this->getDefaultParameters(); - - $this->services = - $this->scopedServices = - $this->scopeStacks = array(); - $this->scopes = array(); - $this->scopeChildren = array(); - $this->methodMap = array( - 'bar' => 'getBarService', - 'baz' => 'getBazService', - 'configured_service' => 'getConfiguredServiceService', - 'decorator_service' => 'getDecoratorServiceService', - 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', - 'factory_service' => 'getFactoryServiceService', - 'foo' => 'getFooService', - 'foo.baz' => 'getFoo_BazService', - 'foo_bar' => 'getFooBarService', - 'foo_with_inline' => 'getFooWithInlineService', - 'method_call1' => 'getMethodCall1Service', - 'new_factory_service' => 'getNewFactoryServiceService', - 'request' => 'getRequestService', - 'service_from_static_method' => 'getServiceFromStaticMethodService', - ); - $this->aliases = array( - 'alias_for_alias' => 'foo', - 'alias_for_foo' => 'foo', - 'decorated' => 'decorator_service_with_name', - ); - } - - /** - * {@inheritdoc} - */ - public function compile() - { - throw new LogicException('You cannot compile a dumped frozen container.'); - } - - /** - * Gets the 'bar' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getBarService() - { - $a = $this->get('foo.baz'); - - $this->services['bar'] = $instance = new \Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); - - $a->configure($instance); - - return $instance; - } - - /** - * Gets the 'baz' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Baz A Baz instance. - */ - protected function getBazService() - { - $this->services['baz'] = $instance = new \Baz(); - - $instance->setFoo($this->get('foo_with_inline')); - - return $instance; - } - - /** - * Gets the 'configured_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getConfiguredServiceService() - { - $a = new \ConfClass(); - $a->setFoo($this->get('baz')); - - $this->services['configured_service'] = $instance = new \stdClass(); - - $a->configureStdClass($instance); - - return $instance; - } - - /** - * Gets the 'decorator_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDecoratorServiceService() - { - return $this->services['decorator_service'] = new \stdClass(); - } - - /** - * Gets the 'decorator_service_with_name' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \stdClass A stdClass instance. - */ - protected function getDecoratorServiceWithNameService() - { - return $this->services['decorator_service_with_name'] = new \stdClass(); - } - - /** - * Gets the 'factory_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar A Bar instance. - */ - protected function getFactoryServiceService() - { - return $this->services['factory_service'] = $this->get('foo.baz')->getInstance(); - } - - /** - * Gets the 'foo' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getFooService() - { - $a = $this->get('foo.baz'); - - $this->services['foo'] = $instance = \Bar\FooClass::getInstance('foo', $a, array('bar' => 'foo is bar', 'foobar' => 'bar'), true, $this); - - $instance->setBar($this->get('bar')); - $instance->initialize(); - $instance->foo = 'bar'; - $instance->moo = $a; - $instance->qux = array('bar' => 'foo is bar', 'foobar' => 'bar'); - sc_configure($instance); - - return $instance; - } - - /** - * Gets the 'foo.baz' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \BazClass A BazClass instance. - */ - protected function getFoo_BazService() - { - $this->services['foo.baz'] = $instance = \BazClass::getInstance(); - - \BazClass::configureStatic1($instance); - - return $instance; - } - - /** - * Gets the 'foo_bar' service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getFooBarService() - { - return new \Bar\FooClass(); - } - - /** - * Gets the 'foo_with_inline' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Foo A Foo instance. - */ - protected function getFooWithInlineService() - { - $a = new \Bar(); - - $this->services['foo_with_inline'] = $instance = new \Foo(); - - $a->setBaz($this->get('baz')); - $a->pub = 'pub'; - - $instance->setBar($a); - - return $instance; - } - - /** - * Gets the 'method_call1' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getMethodCall1Service() - { - require_once '%path%foo.php'; - - $this->services['method_call1'] = $instance = new \Bar\FooClass(); - - $instance->setBar($this->get('foo')); - $instance->setBar(NULL); - $instance->setBar(($this->get("foo")->foo() . (($this->hasparameter("foo")) ? ($this->getParameter("foo")) : ("default")))); - - return $instance; - } - - /** - * Gets the 'new_factory_service' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \FooBarBaz A FooBarBaz instance. - */ - protected function getNewFactoryServiceService() - { - $a = new \FactoryClass(); - $a->foo = 'bar'; - - $this->services['new_factory_service'] = $instance = $a->getInstance(); - - $instance->foo = 'bar'; - - return $instance; - } - - /** - * Gets the 'request' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @throws RuntimeException always since this service is expected to be injected dynamically - */ - protected function getRequestService() - { - throw new RuntimeException('You have requested a synthetic service ("request"). The DIC does not know how to construct this service.'); - } - - /** - * Gets the 'service_from_static_method' service. - * - * This service is shared. - * This method always returns the same instance of the service. - * - * @return \Bar\FooClass A Bar\FooClass instance. - */ - protected function getServiceFromStaticMethodService() - { - return $this->services['service_from_static_method'] = \Bar\FooClass::getInstance(); - } - - /** - * {@inheritdoc} - */ - public function getParameter($name) - { - $name = strtolower($name); - - if (!(isset($this->parameters[$name]) || array_key_exists($name, $this->parameters))) { - throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); - } - - return $this->parameters[$name]; - } - - /** - * {@inheritdoc} - */ - public function hasParameter($name) - { - $name = strtolower($name); - - return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters); - } - - /** - * {@inheritdoc} - */ - public function setParameter($name, $value) - { - throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - - /** - * {@inheritdoc} - */ - public function getParameterBag() - { - if (null === $this->parameterBag) { - $this->parameterBag = new FrozenParameterBag($this->parameters); - } - - return $this->parameterBag; - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return array( - 'baz_class' => 'BazClass', - 'foo_class' => 'Bar\\FooClass', - 'foo' => 'bar', - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php deleted file mode 100644 index aa4df998c..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php +++ /dev/null @@ -1,3 +0,0 @@ -setParameter('foo', 'foo'); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml deleted file mode 100644 index 52df38d0c..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml deleted file mode 100644 index 21a7ef58c..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml deleted file mode 100644 index 792fa0705..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - BAR - - - - - - - - - %project.parameter.foo% - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml deleted file mode 100644 index 67d462be9..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - BAR - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml deleted file mode 100644 index c23f02a08..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - BAR - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml deleted file mode 100644 index 2c33c3a7d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml deleted file mode 100644 index 0eaaff2d2..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml deleted file mode 100644 index a9c01030d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml deleted file mode 100644 index e77780db6..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services6.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services6.xml deleted file mode 100644 index 708e10fd5..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services6.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services9.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services9.xml deleted file mode 100644 index 5692ba13e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy-services9.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - BazClass - bar - - - - - - foo - - - foo is %foo% - %foo% - - true - - bar - - - foo is %foo% - %foo% - - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml deleted file mode 100644 index 5a05cedd7..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - foo - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml deleted file mode 100644 index e7b5bc973..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml deleted file mode 100644 index 6aa5732f9..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml +++ /dev/null @@ -1,2 +0,0 @@ - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml deleted file mode 100644 index a4da1bf74..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml deleted file mode 100644 index 1ac493884..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - true - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml deleted file mode 100644 index 73446214e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - app - - - - - - app - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml deleted file mode 100644 index f1ac14dd5..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - a string - bar - - 0 - 4 - null - true - true - false - on - off - 1.3 - 1000.3 - a string - - foo - bar - - - - value - - PHP_EOL - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services20.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services20.xml deleted file mode 100644 index 5d799fc94..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services20.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml deleted file mode 100644 index 329bc3d72..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml deleted file mode 100644 index 87bf183db..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - foo - - true - false - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml deleted file mode 100644 index 03ad9f808..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml deleted file mode 100644 index 0b7f10a30..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml deleted file mode 100644 index acb93e748..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml deleted file mode 100644 index 9eb7b8915..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - - - %path%/foo.php - - - foo - - - true - false - - - - - - - - - - - - - - - service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default") - - - - - foo - - - true - false - - - - - - - - - - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml deleted file mode 100644 index 824d8b5d7..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml deleted file mode 100644 index b17e50043..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - %baz% - bar - foo is %%foo bar - @escapeme - - true - false - null - 0 - 1000.3 - true - false - null - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml deleted file mode 100644 index c4ddc416b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml +++ /dev/null @@ -1,106 +0,0 @@ - - - - BazClass - Bar\FooClass - bar - - - - - - foo - - - foo is %foo% - %foo% - - true - - bar - - - foo is %foo% - %foo% - - - - - - - - - - - - - - foo - - %foo_bar% - - - - - %path%foo.php - - - - - - - - - - - - - - service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default") - - - - - - - - - pub - - - - - - - - - - - - - - - - - - - - - - - bar - - - - - - bar - - - - - - - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml deleted file mode 100644 index f217d5bca..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml deleted file mode 100644 index 3f34b07eb..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml +++ /dev/null @@ -1,4 +0,0 @@ -services: - method_call1: - class: FooClass - calls: foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml deleted file mode 100644 index 1f58cac6a..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml +++ /dev/null @@ -1,2 +0,0 @@ -parameters: - FOO: bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml deleted file mode 100644 index 0765dc8dd..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - - foo.yml diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml deleted file mode 100644 index 1ce9d57c6..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - foo:bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml deleted file mode 100644 index bbd13ac0b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml +++ /dev/null @@ -1,2 +0,0 @@ -parameters: - foo:bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml deleted file mode 100644 index 811af3c0e..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml +++ /dev/null @@ -1,2 +0,0 @@ -services: - foo: bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml deleted file mode 100644 index cfbf17ce5..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml +++ /dev/null @@ -1 +0,0 @@ -services: foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml deleted file mode 100644 index 14536fdb3..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml +++ /dev/null @@ -1,5 +0,0 @@ -services: - foo_service: - class: FooClass - # tags is not an array - tags: string diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml deleted file mode 100644 index 90288144c..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml +++ /dev/null @@ -1,6 +0,0 @@ -services: - foo_service: - class: FooClass - tags: - # tag is missing the name key - foo_tag: { foo: bar } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml deleted file mode 100644 index 72ec4e8f0..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml +++ /dev/null @@ -1,6 +0,0 @@ -services: - foo_service: - class: FooClass - tags: - # tag-attribute is not a scalar - - { name: foo, bar: { foo: foo, bar: bar } } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag4.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag4.yml deleted file mode 100644 index e8e99395b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag4.yml +++ /dev/null @@ -1,6 +0,0 @@ -services: - foo_service: - class: FooClass - tags: - # tag is not an array - - foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services6.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services6.yml deleted file mode 100644 index 46ac67994..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services6.yml +++ /dev/null @@ -1,8 +0,0 @@ -services: - constructor: { class: FooClass, factory_method: getInstance } - factory_service: { class: BazClass, factory_method: getInstance, factory_service: baz_factory } - request: - class: Request - synthetic: true - synchronized: true - lazy: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services9.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services9.yml deleted file mode 100644 index 64d17262a..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy-services9.yml +++ /dev/null @@ -1,28 +0,0 @@ -parameters: - baz_class: BazClass - foo: bar - -services: - foo: - class: Bar\FooClass - tags: - - { name: foo, foo: foo } - - { name: foo, bar: bar } - factory_class: Bar\FooClass - factory_method: getInstance - arguments: [foo, '@foo.baz', { '%foo%': 'foo is %foo%', foobar: '%foo%' }, true, '@service_container'] - properties: { foo: bar, moo: '@foo.baz', qux: { '%foo%': 'foo is %foo%', foobar: '%foo%' } } - calls: - - [setBar, ['@bar']] - - [initialize, { }] - - configurator: sc_configure - foo.baz: - class: %baz_class% - factory_class: %baz_class% - factory_method: getInstance - configurator: ['%baz_class%', configureStatic1] - factory_service: - class: Bar - factory_method: getInstance - factory_service: foo.baz diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml deleted file mode 100644 index 4eddb872b..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml +++ /dev/null @@ -1,2 +0,0 @@ -foo: - bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml deleted file mode 100644 index c508d5366..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml +++ /dev/null @@ -1 +0,0 @@ -false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml deleted file mode 100644 index 8b1378917..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml deleted file mode 100644 index f2f8d953d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml +++ /dev/null @@ -1,9 +0,0 @@ -parameters: - project.parameter.foo: BAR - -services: - project.service.foo: - class: BAR - -project: - test: %project.parameter.foo% diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml deleted file mode 100644 index 40126f005..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml +++ /dev/null @@ -1 +0,0 @@ -foobarfoobar: {} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml deleted file mode 100644 index d52d355c2..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml +++ /dev/null @@ -1,3 +0,0 @@ -# used to test imports in XML -parameters: - imported_from_yaml: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml deleted file mode 100644 index 4c188c5fb..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml +++ /dev/null @@ -1,3 +0,0 @@ -services: - factory: { class: FooBarClass, factory: baz:getClass} - factory_with_static_call: { class: FooBarClass, factory: FooBacFactory::createFooBar} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml deleted file mode 100644 index 3c127466a..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml +++ /dev/null @@ -1,12 +0,0 @@ -parameters: - FOO: bar - values: - - true - - false - - 0 - - 1000.3 - bar: foo - escape: @@escapeme - foo_bar: @foo_bar - MixedCase: - MixedCaseKey: value diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services20.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services20.yml deleted file mode 100644 index 847f65688..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services20.yml +++ /dev/null @@ -1,9 +0,0 @@ -services: - request: - class: Request - synthetic: true - synchronized: true - depends_on_request: - class: stdClass - calls: - - [setRequest, ['@?request']] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml deleted file mode 100644 index da717a8bb..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml +++ /dev/null @@ -1,15 +0,0 @@ -services: - manager: - class: UserManager - arguments: - - true - calls: - - method: setLogger - arguments: - - @logger - - method: setClass - arguments: - - User - tags: - - name: manager - alias: user diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml deleted file mode 100644 index 0e92cdf50..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml +++ /dev/null @@ -1,5 +0,0 @@ -parameters: - foo: foo - values: - - true - - false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml deleted file mode 100644 index 8e0987fd0..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml +++ /dev/null @@ -1,7 +0,0 @@ -imports: - - { resource: services2.yml } - - { resource: services3.yml } - - { resource: "../php/simple.php" } - - { resource: "../ini/parameters.ini", class: Symfony\Component\DependencyInjection\Loader\IniFileLoader } - - { resource: "../ini/parameters2.ini" } - - { resource: "../xml/services13.xml" } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml deleted file mode 100644 index f7089fc4d..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - - { resource: foo_fake.yml, ignore_errors: true } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml deleted file mode 100644 index 78abf4d15..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml +++ /dev/null @@ -1,33 +0,0 @@ -services: - foo: { class: FooClass } - baz: { class: BazClass } - scope.container: { class: FooClass, scope: container } - scope.custom: { class: FooClass, scope: custom } - scope.prototype: { class: FooClass, scope: prototype } - file: { class: FooClass, file: %path%/foo.php } - arguments: { class: FooClass, arguments: [foo, @foo, [true, false]] } - configurator1: { class: FooClass, configurator: sc_configure } - configurator2: { class: FooClass, configurator: [@baz, configure] } - configurator3: { class: FooClass, configurator: [BazClass, configureStatic] } - method_call1: - class: FooClass - calls: - - [ setBar, [] ] - - [ setBar ] - - [ setBar, ['@=service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")'] ] - method_call2: - class: FooClass - calls: - - [ setBar, [ foo, @foo, [true, false] ] ] - alias_for_foo: @foo - another_alias_for_foo: - alias: foo - public: false - decorator_service: - decorates: decorated - decorator_service_with_name: - decorates: decorated - decoration_inner_name: decorated.pif-pouf - new_factory1: { class: FooBarClass, factory: factory} - new_factory2: { class: FooBarClass, factory: [@baz, getClass]} - new_factory3: { class: FooBarClass, factory: [BazClass, getInstance]} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml deleted file mode 100644 index 09064f200..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml +++ /dev/null @@ -1,2 +0,0 @@ -services: - foo: { class: BarClass } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml deleted file mode 100644 index a1fb59035..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml +++ /dev/null @@ -1,7 +0,0 @@ -parameters: - foo: '%baz%' - baz: bar - bar: 'foo is %%foo bar' - escape: '@@escapeme' - values: [true, false, null, 0, 1000.3, 'true', 'false', 'null'] - diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml deleted file mode 100644 index fdab85fc7..000000000 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml +++ /dev/null @@ -1,94 +0,0 @@ -parameters: - baz_class: BazClass - foo_class: Bar\FooClass - foo: bar - -services: - foo: - class: Bar\FooClass - tags: - - { name: foo, foo: foo } - - { name: foo, bar: bar, baz: baz } - arguments: [foo, '@foo.baz', { '%foo%': 'foo is %foo%', foobar: '%foo%' }, true, '@service_container'] - properties: { foo: bar, moo: '@foo.baz', qux: { '%foo%': 'foo is %foo%', foobar: '%foo%' } } - calls: - - [setBar, ['@bar']] - - [initialize, { }] - - factory: [Bar\FooClass, getInstance] - configurator: sc_configure - foo.baz: - class: %baz_class% - factory: ['%baz_class%', getInstance] - configurator: ['%baz_class%', configureStatic1] - bar: - class: Bar\FooClass - arguments: [foo, '@foo.baz', '%foo_bar%'] - configurator: ['@foo.baz', configure] - foo_bar: - class: %foo_class% - scope: prototype - method_call1: - class: Bar\FooClass - file: %path%foo.php - calls: - - [setBar, ['@foo']] - - [setBar, ['@?foo2']] - - [setBar, ['@?foo3']] - - [setBar, ['@?foobaz']] - - [setBar, ['@=service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")']] - - foo_with_inline: - class: Foo - calls: - - [setBar, ['@inlined']] - - inlined: - class: Bar - public: false - properties: { pub: pub } - calls: - - [setBaz, ['@baz']] - - baz: - class: Baz - calls: - - [setFoo, ['@foo_with_inline']] - - request: - class: Request - synthetic: true - configurator_service: - class: ConfClass - public: false - calls: - - [setFoo, ['@baz']] - - configured_service: - class: stdClass - configurator: ['@configurator_service', configureStdClass] - decorated: - class: stdClass - decorator_service: - class: stdClass - decorates: decorated - decorator_service_with_name: - class: stdClass - decorates: decorated - decoration_inner_name: decorated.pif-pouf - new_factory: - class: FactoryClass - public: false - properties: { foo: bar } - factory_service: - class: Bar - factory: ['@foo.baz', getInstance] - new_factory_service: - class: FooBarBaz - properties: { foo: bar } - factory: ['@new_factory', getInstance] - service_from_static_method: - class: Bar\FooClass - factory: [Bar\FooClass, getInstance] - alias_for_foo: @foo - alias_for_alias: @foo diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php deleted file mode 100644 index cb4402499..000000000 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php +++ /dev/null @@ -1,37 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\LazyProxy\Instantiator; - -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator; - -/** - * Tests for {@see \Symfony\Component\DependencyInjection\Instantiator\RealServiceInstantiator}. - * - * @author Marco Pivetta - * - * @covers \Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator - */ -class RealServiceInstantiatorTest extends \PHPUnit_Framework_TestCase -{ - public function testInstantiateProxy() - { - $instantiator = new RealServiceInstantiator(); - $instance = new \stdClass(); - $container = $this->getMock('Symfony\Component\DependencyInjection\ContainerInterface'); - $callback = function () use ($instance) { - return $instance; - }; - - $this->assertSame($instance, $instantiator->instantiateProxy($container, new Definition(), 'foo', $callback)); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php deleted file mode 100644 index 2081ebcf4..000000000 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\LazyProxy\PhpDumper; - -use Symfony\Component\DependencyInjection\Definition; -use Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; - -/** - * Tests for {@see \Symfony\Component\DependencyInjection\PhpDumper\NullDumper}. - * - * @author Marco Pivetta - * - * @covers \Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper - */ -class NullDumperTest extends \PHPUnit_Framework_TestCase -{ - public function testNullDumper() - { - $dumper = new NullDumper(); - $definition = new Definition('stdClass'); - - $this->assertFalse($dumper->isProxyCandidate($definition)); - $this->assertSame('', $dumper->getProxyFactoryCode($definition, 'foo')); - $this->assertSame('', $dumper->getProxyCode($definition)); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/LegacyContainerBuilderTest.php b/vendor/symfony/dependency-injection/Tests/LegacyContainerBuilderTest.php deleted file mode 100644 index 40aec2006..000000000 --- a/vendor/symfony/dependency-injection/Tests/LegacyContainerBuilderTest.php +++ /dev/null @@ -1,46 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Reference; - -/** - * @group legacy - */ -class LegacyContainerBuilderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceFactoryMethod() - { - $builder = new ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', 'Bar\FooClass')->setFactoryClass('Bar\FooClass')->setFactoryMethod('getInstance')->addArgument(array('foo' => '%value%', '%value%' => 'foo', new Reference('bar'))); - $builder->setParameter('value', 'bar'); - $this->assertTrue($builder->get('foo1')->called, '->createService() calls the factory method to create the service instance'); - $this->assertEquals(array('foo' => 'bar', 'bar' => 'foo', $builder->get('bar')), $builder->get('foo1')->arguments, '->createService() passes the arguments to the factory method'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ContainerBuilder::createService - */ - public function testCreateServiceFactoryService() - { - $builder = new ContainerBuilder(); - $builder->register('baz_service')->setFactoryService('baz_factory')->setFactoryMethod('getInstance'); - $builder->register('baz_factory', 'BazClass'); - - $this->assertInstanceOf('BazClass', $builder->get('baz_service')); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/LegacyDefinitionTest.php b/vendor/symfony/dependency-injection/Tests/LegacyDefinitionTest.php deleted file mode 100644 index 07891fff6..000000000 --- a/vendor/symfony/dependency-injection/Tests/LegacyDefinitionTest.php +++ /dev/null @@ -1,44 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\Definition; - -/** - * @group legacy - */ -class LegacyDefinitionTest extends \PHPUnit_Framework_TestCase -{ - public function testSetGetFactoryClass() - { - $def = new Definition('stdClass'); - $this->assertNull($def->getFactoryClass()); - $this->assertSame($def, $def->setFactoryClass('stdClass2'), '->setFactoryClass() implements a fluent interface.'); - $this->assertEquals('stdClass2', $def->getFactoryClass(), '->getFactoryClass() returns current class to construct this service.'); - } - - public function testSetGetFactoryMethod() - { - $def = new Definition('stdClass'); - $this->assertNull($def->getFactoryMethod()); - $this->assertSame($def, $def->setFactoryMethod('foo'), '->setFactoryMethod() implements a fluent interface'); - $this->assertEquals('foo', $def->getFactoryMethod(), '->getFactoryMethod() returns the factory method name'); - } - - public function testSetGetFactoryService() - { - $def = new Definition('stdClass'); - $this->assertNull($def->getFactoryService()); - $this->assertSame($def, $def->setFactoryService('foo.bar'), '->setFactoryService() implements a fluent interface.'); - $this->assertEquals('foo.bar', $def->getFactoryService(), '->getFactoryService() returns current service to construct this service.'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php deleted file mode 100644 index 483e30b78..000000000 --- a/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php +++ /dev/null @@ -1,43 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Loader; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Loader\ClosureLoader; - -class ClosureLoaderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Loader\ClosureLoader::supports - */ - public function testSupports() - { - $loader = new ClosureLoader(new ContainerBuilder()); - - $this->assertTrue($loader->supports(function ($container) {}), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\ClosureLoader::load - */ - public function testLoad() - { - $loader = new ClosureLoader($container = new ContainerBuilder()); - - $loader->load(function ($container) { - $container->setParameter('foo', 'foo'); - }); - - $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a \Closure resource'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php deleted file mode 100644 index 9188018b2..000000000 --- a/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php +++ /dev/null @@ -1,80 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Loader; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use Symfony\Component\Config\FileLocator; - -class IniFileLoaderTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - protected $container; - protected $loader; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - } - - protected function setUp() - { - $this->container = new ContainerBuilder(); - $this->loader = new IniFileLoader($this->container, new FileLocator(self::$fixturesPath.'/ini')); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::__construct - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::load - */ - public function testIniFileCanBeLoaded() - { - $this->loader->load('parameters.ini'); - $this->assertEquals(array('foo' => 'bar', 'bar' => '%foo%'), $this->container->getParameterBag()->all(), '->load() takes a single file name as its first argument'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::__construct - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::load - * - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The file "foo.ini" does not exist (in: - */ - public function testExceptionIsRaisedWhenIniFileDoesNotExist() - { - $this->loader->load('foo.ini'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::__construct - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::load - * - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage The "nonvalid.ini" file is not valid. - */ - public function testExceptionIsRaisedWhenIniFileCannotBeParsed() - { - @$this->loader->load('nonvalid.ini'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\IniFileLoader::supports - */ - public function testSupports() - { - $loader = new IniFileLoader(new ContainerBuilder(), new FileLocator()); - - $this->assertTrue($loader->supports('foo.ini'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php deleted file mode 100644 index 5ae097ca7..000000000 --- a/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php +++ /dev/null @@ -1,42 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Loader; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use Symfony\Component\Config\FileLocator; - -class PhpFileLoaderTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Loader\PhpFileLoader::supports - */ - public function testSupports() - { - $loader = new PhpFileLoader(new ContainerBuilder(), new FileLocator()); - - $this->assertTrue($loader->supports('foo.php'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\PhpFileLoader::load - */ - public function testLoad() - { - $loader = new PhpFileLoader($container = new ContainerBuilder(), new FileLocator()); - - $loader->load(__DIR__.'/../Fixtures/php/simple.php'); - - $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a PHP file resource'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php deleted file mode 100644 index 8bf524ae4..000000000 --- a/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php +++ /dev/null @@ -1,495 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Loader; - -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use Symfony\Component\Config\Loader\LoaderResolver; -use Symfony\Component\Config\FileLocator; -use Symfony\Component\ExpressionLanguage\Expression; - -class XmlFileLoaderTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - require_once self::$fixturesPath.'/includes/foo.php'; - require_once self::$fixturesPath.'/includes/ProjectExtension.php'; - require_once self::$fixturesPath.'/includes/ProjectWithXsdExtension.php'; - } - - public function testLoad() - { - $loader = new XmlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/ini')); - - try { - $loader->load('foo.xml'); - $this->fail('->load() throws an InvalidArgumentException if the loaded file does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file does not exist'); - $this->assertStringStartsWith('The file "foo.xml" does not exist (in:', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file does not exist'); - } - } - - public function testParseFile() - { - $loader = new XmlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/ini')); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('parseFileToDOM'); - $m->setAccessible(true); - - try { - $m->invoke($loader, self::$fixturesPath.'/ini/parameters.ini'); - $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $this->assertRegExp(sprintf('#^Unable to parse file ".+%s".$#', 'parameters.ini'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $this->assertStringStartsWith('[ERROR 4] Start tag expected, \'<\' not found (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - } - - $loader = new XmlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/xml')); - - try { - $m->invoke($loader, self::$fixturesPath.'/xml/nonvalid.xml'); - $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - $this->assertRegExp(sprintf('#^Unable to parse file ".+%s".$#', 'nonvalid.xml'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - $this->assertStringStartsWith('[ERROR 1845] Element \'nonvalid\': No matching global declaration available for the validation root. (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - } - - $xml = $m->invoke($loader, self::$fixturesPath.'/xml/services1.xml'); - $this->assertInstanceOf('DOMDocument', $xml, '->parseFileToDOM() returns an SimpleXMLElement object'); - } - - public function testLoadParameters() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services2.xml'); - - $actual = $container->getParameterBag()->all(); - $expected = array( - 'a string', - 'foo' => 'bar', - 'values' => array( - 0, - 'integer' => 4, - 100 => null, - 'true', - true, - false, - 'on', - 'off', - 'float' => 1.3, - 1000.3, - 'a string', - array('foo', 'bar'), - ), - 'mixedcase' => array('MixedCaseKey' => 'value'), - 'constant' => PHP_EOL, - ); - - $this->assertEquals($expected, $actual, '->load() converts XML values to PHP ones'); - } - - public function testLoadImports() - { - $container = new ContainerBuilder(); - $resolver = new LoaderResolver(array( - new IniFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')), - new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')), - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')), - )); - $loader->setResolver($resolver); - $loader->load('services4.xml'); - - $actual = $container->getParameterBag()->all(); - $expected = array( - 'a string', - 'foo' => 'bar', - 'values' => array( - 0, - 'integer' => 4, - 100 => null, - 'true', - true, - false, - 'on', - 'off', - 'float' => 1.3, - 1000.3, - 'a string', - array('foo', 'bar'), - ), - 'mixedcase' => array('MixedCaseKey' => 'value'), - 'constant' => PHP_EOL, - 'bar' => '%foo%', - 'imported_from_ini' => true, - 'imported_from_yaml' => true, - ); - - $this->assertEquals(array_keys($expected), array_keys($actual), '->load() imports and merges imported files'); - - // Bad import throws no exception due to ignore_errors value. - $loader->load('services4_bad_import.xml'); - } - - public function testLoadAnonymousServices() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services5.xml'); - $services = $container->getDefinitions(); - $this->assertCount(4, $services, '->load() attributes unique ids to anonymous services'); - - // anonymous service as an argument - $args = $services['foo']->getArguments(); - $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); - $this->assertTrue(isset($services[(string) $args[0]]), '->load() makes a reference to the created ones'); - $inner = $services[(string) $args[0]]; - $this->assertEquals('BarClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - - // inner anonymous services - $args = $inner->getArguments(); - $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); - $this->assertTrue(isset($services[(string) $args[0]]), '->load() makes a reference to the created ones'); - $inner = $services[(string) $args[0]]; - $this->assertEquals('BazClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertFalse($inner->isPublic()); - - // anonymous service as a property - $properties = $services['foo']->getProperties(); - $property = $properties['p']; - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Reference', $property, '->load() converts anonymous services to references to "normal" services'); - $this->assertTrue(isset($services[(string) $property]), '->load() makes a reference to the created ones'); - $inner = $services[(string) $property]; - $this->assertEquals('BazClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - } - - /** - * @group legacy - */ - public function testLegacyLoadServices() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('legacy-services6.xml'); - $services = $container->getDefinitions(); - $this->assertEquals('FooClass', $services['constructor']->getClass()); - $this->assertEquals('getInstance', $services['constructor']->getFactoryMethod()); - $this->assertNull($services['factory_service']->getClass()); - $this->assertEquals('baz_factory', $services['factory_service']->getFactoryService()); - $this->assertEquals('getInstance', $services['factory_service']->getFactoryMethod()); - $this->assertTrue($services['request']->isSynthetic(), '->load() parses the synthetic flag'); - $this->assertTrue($services['request']->isSynchronized(), '->load() parses the synchronized flag'); - $this->assertTrue($services['request']->isLazy(), '->load() parses the lazy flag'); - $this->assertNull($services['request']->getDecoratedService()); - } - - public function testLoadServices() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services6.xml'); - $services = $container->getDefinitions(); - $this->assertTrue(isset($services['foo']), '->load() parses elements'); - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts element to Definition instances'); - $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); - $this->assertEquals('container', $services['scope.container']->getScope()); - $this->assertEquals('custom', $services['scope.custom']->getScope()); - $this->assertEquals('prototype', $services['scope.prototype']->getScope()); - $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); - $this->assertEquals(array('foo', new Reference('foo'), array(true, false)), $services['arguments']->getArguments(), '->load() parses the argument tags'); - $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array(new Reference('baz', ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, false), 'configure'), $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array('BazClass', 'configureStatic'), $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array(array('setBar', array()), array('setBar', array(new Expression('service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")')))), $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals(array(array('setBar', array('foo', new Reference('foo'), array(true, false)))), $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(array(new Reference('baz', ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, false), 'getClass'), $services['new_factory2']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(array('BazClass', 'getInstance'), $services['new_factory3']->getFactory(), '->load() parses the factory tag'); - - $aliases = $container->getAliases(); - $this->assertTrue(isset($aliases['alias_for_foo']), '->load() parses elements'); - $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); - $this->assertTrue($aliases['alias_for_foo']->isPublic()); - $this->assertTrue(isset($aliases['another_alias_for_foo'])); - $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); - $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); - - $this->assertEquals(array('decorated', null), $services['decorator_service']->getDecoratedService()); - $this->assertEquals(array('decorated', 'decorated.pif-pouf'), $services['decorator_service_with_name']->getDecoratedService()); - } - - public function testParsesTags() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services10.xml'); - - $services = $container->findTaggedServiceIds('foo_tag'); - $this->assertCount(1, $services); - - foreach ($services as $id => $tagAttributes) { - foreach ($tagAttributes as $attributes) { - $this->assertArrayHasKey('other_option', $attributes); - $this->assertEquals('lorem', $attributes['other_option']); - $this->assertArrayHasKey('other-option', $attributes, 'unnormalized tag attributes should not be removed'); - - $this->assertEquals('ciz', $attributes['some_option'], 'no overriding should be done when normalizing'); - $this->assertEquals('cat', $attributes['some-option']); - - $this->assertArrayNotHasKey('an_other_option', $attributes, 'normalization should not be done when an underscore is already found'); - } - } - } - - public function testConvertDomElementToArray() - { - $doc = new \DOMDocument('1.0'); - $doc->loadXML('bar'); - $this->assertEquals('bar', XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(array('foo' => 'bar'), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML('bar'); - $this->assertEquals(array('foo' => 'bar'), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML('barbar'); - $this->assertEquals(array('foo' => array('value' => 'bar', 'foo' => 'bar')), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(array('foo' => null), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(array('foo' => null), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(array('foo' => array(array('foo' => 'bar'), array('foo' => 'bar'))), XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \DomElement to an array'); - } - - public function testExtensions() - { - $container = new ContainerBuilder(); - $container->registerExtension(new \ProjectExtension()); - $container->registerExtension(new \ProjectWithXsdExtension()); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - - // extension without an XSD - $loader->load('extensions/services1.xml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - - $this->assertTrue(isset($services['project.service.bar']), '->load() parses extension elements'); - $this->assertTrue(isset($parameters['project.parameter.bar']), '->load() parses extension elements'); - - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - - // extension with an XSD - $container = new ContainerBuilder(); - $container->registerExtension(new \ProjectExtension()); - $container->registerExtension(new \ProjectWithXsdExtension()); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('extensions/services2.xml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - - $this->assertTrue(isset($services['project.service.bar']), '->load() parses extension elements'); - $this->assertTrue(isset($parameters['project.parameter.bar']), '->load() parses extension elements'); - - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - - $container = new ContainerBuilder(); - $container->registerExtension(new \ProjectExtension()); - $container->registerExtension(new \ProjectWithXsdExtension()); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - - // extension with an XSD (does not validate) - try { - $loader->load('extensions/services3.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertRegExp(sprintf('#^Unable to parse file ".+%s".$#', 'services3.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertContains('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } - - // non-registered extension - try { - $loader->load('extensions/services4.xml'); - $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); - $this->assertStringStartsWith('There is no extension able to load the configuration for "project:bar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); - } - } - - public function testExtensionInPhar() - { - if (extension_loaded('suhosin') && false === strpos(ini_get('suhosin.executor.include.whitelist'), 'phar')) { - $this->markTestSkipped('To run this test, add "phar" to the "suhosin.executor.include.whitelist" settings in your php.ini file.'); - } - - require_once self::$fixturesPath.'/includes/ProjectWithXsdExtensionInPhar.phar'; - - // extension with an XSD in PHAR archive - $container = new ContainerBuilder(); - $container->registerExtension(new \ProjectWithXsdExtensionInPhar()); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('extensions/services6.xml'); - - // extension with an XSD in PHAR archive (does not validate) - try { - $loader->load('extensions/services7.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertRegExp(sprintf('#^Unable to parse file ".+%s".$#', 'services7.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertContains('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\XmlFileLoader::supports - */ - public function testSupports() - { - $loader = new XmlFileLoader(new ContainerBuilder(), new FileLocator()); - - $this->assertTrue($loader->supports('foo.xml'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } - - public function testNoNamingConflictsForAnonymousServices() - { - $container = new ContainerBuilder(); - - $loader1 = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml/extension1')); - $loader1->load('services.xml'); - $services = $container->getDefinitions(); - $this->assertCount(2, $services, '->load() attributes unique ids to anonymous services'); - $loader2 = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml/extension2')); - $loader2->load('services.xml'); - $services = $container->getDefinitions(); - $this->assertCount(4, $services, '->load() attributes unique ids to anonymous services'); - - $services = $container->getDefinitions(); - $args1 = $services['extension1.foo']->getArguments(); - $inner1 = $services[(string) $args1[0]]; - $this->assertEquals('BarClass1', $inner1->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $args2 = $services['extension2.foo']->getArguments(); - $inner2 = $services[(string) $args2[0]]; - $this->assertEquals('BarClass2', $inner2->getClass(), '->load() uses the same configuration as for the anonymous ones'); - } - - public function testDocTypeIsNotAllowed() - { - $container = new ContainerBuilder(); - - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - - // document types are not allowed. - try { - $loader->load('withdoctype.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration contains a document type'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); - $this->assertRegExp(sprintf('#^Unable to parse file ".+%s".$#', 'withdoctype.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); - - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); - $this->assertSame('Document types are not allowed.', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); - } - } - - public function testXmlNamespaces() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('namespaces.xml'); - $services = $container->getDefinitions(); - - $this->assertTrue(isset($services['foo']), '->load() parses elements'); - $this->assertEquals(1, count($services['foo']->getTag('foo.tag')), '->load parses elements'); - $this->assertEquals(array(array('setBar', array('foo'))), $services['foo']->getMethodCalls(), '->load() parses the tag'); - } - - public function testLoadIndexedArguments() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services14.xml'); - - $this->assertEquals(array('index_0' => 'app'), $container->findDefinition('logger')->getArguments()); - } - - public function testLoadInlinedServices() - { - $container = new ContainerBuilder(); - $loader = new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/xml')); - $loader->load('services21.xml'); - - $foo = $container->getDefinition('foo'); - - $fooFactory = $foo->getFactory(); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $fooFactory[0]); - $this->assertSame('FooFactory', $fooFactory[0]->getClass()); - $this->assertSame('createFoo', $fooFactory[1]); - - $fooFactoryFactory = $fooFactory[0]->getFactory(); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $fooFactoryFactory[0]); - $this->assertSame('Foobar', $fooFactoryFactory[0]->getClass()); - $this->assertSame('createFooFactory', $fooFactoryFactory[1]); - - $fooConfigurator = $foo->getConfigurator(); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $fooConfigurator[0]); - $this->assertSame('Bar', $fooConfigurator[0]->getClass()); - $this->assertSame('configureFoo', $fooConfigurator[1]); - - $barConfigurator = $fooConfigurator[0]->getConfigurator(); - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Definition', $barConfigurator[0]); - $this->assertSame('Baz', $barConfigurator[0]->getClass()); - $this->assertSame('configureBar', $barConfigurator[1]); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php deleted file mode 100644 index c94f40bf5..000000000 --- a/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php +++ /dev/null @@ -1,283 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\Loader; - -use Symfony\Component\DependencyInjection\ContainerBuilder; -use Symfony\Component\DependencyInjection\Reference; -use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use Symfony\Component\Config\Loader\LoaderResolver; -use Symfony\Component\Config\FileLocator; -use Symfony\Component\ExpressionLanguage\Expression; - -class YamlFileLoaderTest extends \PHPUnit_Framework_TestCase -{ - protected static $fixturesPath; - - public static function setUpBeforeClass() - { - self::$fixturesPath = realpath(__DIR__.'/../Fixtures/'); - require_once self::$fixturesPath.'/includes/foo.php'; - require_once self::$fixturesPath.'/includes/ProjectExtension.php'; - } - - public function testLoadFile() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/ini')); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('loadFile'); - $m->setAccessible(true); - - try { - $m->invoke($loader, 'foo.yml'); - $this->fail('->load() throws an InvalidArgumentException if the loaded file does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file does not exist'); - $this->assertEquals('The service file "foo.yml" is not valid.', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file does not exist'); - } - - try { - $m->invoke($loader, 'parameters.ini'); - $this->fail('->load() throws an InvalidArgumentException if the loaded file is not a valid YAML file'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file is not a valid YAML file'); - $this->assertEquals('The service file "parameters.ini" is not valid.', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file is not a valid YAML file'); - } - - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - - foreach (array('nonvalid1', 'nonvalid2') as $fixture) { - try { - $m->invoke($loader, $fixture.'.yml'); - $this->fail('->load() throws an InvalidArgumentException if the loaded file does not validate'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file does not validate'); - $this->assertStringMatchesFormat('The service file "nonvalid%d.yml" is not valid.', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file does not validate'); - } - } - } - - /** - * @dataProvider provideInvalidFiles - * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException - */ - public function testLoadInvalidFile($file) - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - - $loader->load($file.'.yml'); - } - - public function provideInvalidFiles() - { - return array( - array('bad_parameters'), - array('bad_imports'), - array('bad_import'), - array('bad_services'), - array('bad_service'), - array('bad_calls'), - array('bad_format'), - ); - } - - public function testLoadParameters() - { - $container = new ContainerBuilder(); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('services2.yml'); - $this->assertEquals(array('foo' => 'bar', 'mixedcase' => array('MixedCaseKey' => 'value'), 'values' => array(true, false, 0, 1000.3), 'bar' => 'foo', 'escape' => '@escapeme', 'foo_bar' => new Reference('foo_bar')), $container->getParameterBag()->all(), '->load() converts YAML keys to lowercase'); - } - - public function testLoadImports() - { - $container = new ContainerBuilder(); - $resolver = new LoaderResolver(array( - new IniFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')), - new XmlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')), - new PhpFileLoader($container, new FileLocator(self::$fixturesPath.'/php')), - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')), - )); - $loader->setResolver($resolver); - $loader->load('services4.yml'); - - $actual = $container->getParameterBag()->all(); - $expected = array('foo' => 'bar', 'values' => array(true, false), 'bar' => '%foo%', 'escape' => '@escapeme', 'foo_bar' => new Reference('foo_bar'), 'mixedcase' => array('MixedCaseKey' => 'value'), 'imported_from_ini' => true, 'imported_from_xml' => true); - $this->assertEquals(array_keys($expected), array_keys($actual), '->load() imports and merges imported files'); - - // Bad import throws no exception due to ignore_errors value. - $loader->load('services4_bad_import.yml'); - } - - /** - * @group legacy - */ - public function testLegacyLoadServices() - { - $container = new ContainerBuilder(); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('legacy-services6.yml'); - $services = $container->getDefinitions(); - $this->assertEquals('FooClass', $services['constructor']->getClass()); - $this->assertEquals('getInstance', $services['constructor']->getFactoryMethod()); - $this->assertEquals('BazClass', $services['factory_service']->getClass()); - $this->assertEquals('baz_factory', $services['factory_service']->getFactoryService()); - $this->assertEquals('getInstance', $services['factory_service']->getFactoryMethod()); - $this->assertTrue($services['request']->isSynthetic(), '->load() parses the synthetic flag'); - $this->assertTrue($services['request']->isSynchronized(), '->load() parses the synchronized flag'); - $this->assertTrue($services['request']->isLazy(), '->load() parses the lazy flag'); - $this->assertNull($services['request']->getDecoratedService()); - } - - public function testLoadServices() - { - $container = new ContainerBuilder(); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('services6.yml'); - $services = $container->getDefinitions(); - $this->assertTrue(isset($services['foo']), '->load() parses service elements'); - $this->assertInstanceOf('Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts service element to Definition instances'); - $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); - $this->assertEquals('container', $services['scope.container']->getScope()); - $this->assertEquals('custom', $services['scope.custom']->getScope()); - $this->assertEquals('prototype', $services['scope.prototype']->getScope()); - $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); - $this->assertEquals(array('foo', new Reference('foo'), array(true, false)), $services['arguments']->getArguments(), '->load() parses the argument tags'); - $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array(new Reference('baz'), 'configure'), $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array('BazClass', 'configureStatic'), $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(array(array('setBar', array()), array('setBar', array()), array('setBar', array(new Expression('service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")')))), $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals(array(array('setBar', array('foo', new Reference('foo'), array(true, false)))), $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(array(new Reference('baz'), 'getClass'), $services['new_factory2']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(array('BazClass', 'getInstance'), $services['new_factory3']->getFactory(), '->load() parses the factory tag'); - - $aliases = $container->getAliases(); - $this->assertTrue(isset($aliases['alias_for_foo']), '->load() parses aliases'); - $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); - $this->assertTrue($aliases['alias_for_foo']->isPublic()); - $this->assertTrue(isset($aliases['another_alias_for_foo'])); - $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); - $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); - - $this->assertEquals(array('decorated', null), $services['decorator_service']->getDecoratedService()); - $this->assertEquals(array('decorated', 'decorated.pif-pouf'), $services['decorator_service_with_name']->getDecoratedService()); - } - - public function testLoadFactoryShortSyntax() - { - $container = new ContainerBuilder(); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('services14.yml'); - $services = $container->getDefinitions(); - - $this->assertEquals(array(new Reference('baz'), 'getClass'), $services['factory']->getFactory(), '->load() parses the factory tag with service:method'); - $this->assertEquals(array('FooBacFactory', 'createFooBar'), $services['factory_with_static_call']->getFactory(), '->load() parses the factory tag with Class::method'); - } - - public function testExtensions() - { - $container = new ContainerBuilder(); - $container->registerExtension(new \ProjectExtension()); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('services10.yml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - - $this->assertTrue(isset($services['project.service.bar']), '->load() parses extension elements'); - $this->assertTrue(isset($parameters['project.parameter.bar']), '->load() parses extension elements'); - - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - - try { - $loader->load('services11.yml'); - $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); - } catch (\Exception $e) { - $this->assertInstanceOf('\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); - $this->assertStringStartsWith('There is no extension able to load the configuration for "foobarfoobar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\Loader\YamlFileLoader::supports - */ - public function testSupports() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator()); - - $this->assertTrue($loader->supports('foo.yml'), '->supports() returns true if the resource is loadable'); - $this->assertTrue($loader->supports('foo.yaml'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } - - public function testNonArrayTagsThrowsException() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - try { - $loader->load('badtag1.yml'); - $this->fail('->load() should throw an exception when the tags key of a service is not an array'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tags key is not an array'); - $this->assertStringStartsWith('Parameter "tags" must be an array for service', $e->getMessage(), '->load() throws an InvalidArgumentException if the tags key is not an array'); - } - } - - /** - * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException - * @expectedExceptionMessage A "tags" entry must be an array for service - */ - public function testNonArrayTagThrowsException() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('badtag4.yml'); - } - - public function testTagWithoutNameThrowsException() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - try { - $loader->load('badtag2.yml'); - $this->fail('->load() should throw an exception when a tag is missing the name key'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag is missing the name key'); - $this->assertStringStartsWith('A "tags" entry is missing a "name" key for service ', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag is missing the name key'); - } - } - - public function testTagWithAttributeArrayThrowsException() - { - $loader = new YamlFileLoader(new ContainerBuilder(), new FileLocator(self::$fixturesPath.'/yaml')); - try { - $loader->load('badtag3.yml'); - $this->fail('->load() should throw an exception when a tag-attribute is not a scalar'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); - $this->assertStringStartsWith('A "tags" attribute must be of a scalar-type for service "foo_service", tag "foo", attribute "bar"', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); - } - } - - public function testLoadYamlOnlyWithKeys() - { - $container = new ContainerBuilder(); - $loader = new YamlFileLoader($container, new FileLocator(self::$fixturesPath.'/yaml')); - $loader->load('services21.yml'); - - $definition = $container->getDefinition('manager'); - $this->assertEquals(array(array('setLogger', array(new Reference('logger'))), array('setClass', array('User'))), $definition->getMethodCalls()); - $this->assertEquals(array(true), $definition->getArguments()); - $this->assertEquals(array('manager' => array(array('alias' => 'user'))), $definition->getTags()); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php deleted file mode 100644 index 6d963dc05..000000000 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php +++ /dev/null @@ -1,69 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\ParameterBag; - -use Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; - -class FrozenParameterBagTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag::__construct - */ - public function testConstructor() - { - $parameters = array( - 'foo' => 'foo', - 'bar' => 'bar', - ); - $bag = new FrozenParameterBag($parameters); - $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag::clear - * @expectedException \LogicException - */ - public function testClear() - { - $bag = new FrozenParameterBag(array()); - $bag->clear(); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag::set - * @expectedException \LogicException - */ - public function testSet() - { - $bag = new FrozenParameterBag(array()); - $bag->set('foo', 'bar'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag::add - * @expectedException \LogicException - */ - public function testAdd() - { - $bag = new FrozenParameterBag(array()); - $bag->add(array()); - } - - /** - * @expectedException \LogicException - */ - public function testRemove() - { - $bag = new FrozenParameterBag(array('foo' => 'bar')); - $bag->remove('foo'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php deleted file mode 100644 index e1f8169f8..000000000 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php +++ /dev/null @@ -1,279 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests\ParameterBag; - -use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -use Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; -use Symfony\Component\DependencyInjection\Exception\RuntimeException; - -class ParameterBagTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::__construct - */ - public function testConstructor() - { - $bag = new ParameterBag($parameters = array( - 'foo' => 'foo', - 'bar' => 'bar', - )); - $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::clear - */ - public function testClear() - { - $bag = new ParameterBag($parameters = array( - 'foo' => 'foo', - 'bar' => 'bar', - )); - $bag->clear(); - $this->assertEquals(array(), $bag->all(), '->clear() removes all parameters'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::remove - */ - public function testRemove() - { - $bag = new ParameterBag(array( - 'foo' => 'foo', - 'bar' => 'bar', - )); - $bag->remove('foo'); - $this->assertEquals(array('bar' => 'bar'), $bag->all(), '->remove() removes a parameter'); - $bag->remove('BAR'); - $this->assertEquals(array(), $bag->all(), '->remove() converts key to lowercase before removing'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::get - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::set - */ - public function testGetSet() - { - $bag = new ParameterBag(array('foo' => 'bar')); - $bag->set('bar', 'foo'); - $this->assertEquals('foo', $bag->get('bar'), '->set() sets the value of a new parameter'); - - $bag->set('foo', 'baz'); - $this->assertEquals('baz', $bag->get('foo'), '->set() overrides previously set parameter'); - - $bag->set('Foo', 'baz1'); - $this->assertEquals('baz1', $bag->get('foo'), '->set() converts the key to lowercase'); - $this->assertEquals('baz1', $bag->get('FOO'), '->get() converts the key to lowercase'); - - try { - $bag->get('baba'); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - } - } - - public function testGetThrowParameterNotFoundException() - { - $bag = new ParameterBag(array( - 'foo' => 'foo', - 'bar' => 'bar', - 'baz' => 'baz', - )); - - try { - $bag->get('foo1'); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "foo1". Did you mean this: "foo"?', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException with some advices'); - } - - try { - $bag->get('bag'); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "bag". Did you mean one of these: "bar", "baz"?', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException with some advices'); - } - - try { - $bag->get(''); - $this->fail('->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException', $e, '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "".', $e->getMessage(), '->get() throws an Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException with some advices'); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::has - */ - public function testHas() - { - $bag = new ParameterBag(array('foo' => 'bar')); - $this->assertTrue($bag->has('foo'), '->has() returns true if a parameter is defined'); - $this->assertTrue($bag->has('Foo'), '->has() converts the key to lowercase'); - $this->assertFalse($bag->has('bar'), '->has() returns false if a parameter is not defined'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolveValue - */ - public function testResolveValue() - { - $bag = new ParameterBag(array()); - $this->assertEquals('foo', $bag->resolveValue('foo'), '->resolveValue() returns its argument unmodified if no placeholders are found'); - - $bag = new ParameterBag(array('foo' => 'bar')); - $this->assertEquals('I\'m a bar', $bag->resolveValue('I\'m a %foo%'), '->resolveValue() replaces placeholders by their values'); - $this->assertEquals(array('bar' => 'bar'), $bag->resolveValue(array('%foo%' => '%foo%')), '->resolveValue() replaces placeholders in keys and values of arrays'); - $this->assertEquals(array('bar' => array('bar' => array('bar' => 'bar'))), $bag->resolveValue(array('%foo%' => array('%foo%' => array('%foo%' => '%foo%')))), '->resolveValue() replaces placeholders in nested arrays'); - $this->assertEquals('I\'m a %%foo%%', $bag->resolveValue('I\'m a %%foo%%'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals('I\'m a bar %%foo bar', $bag->resolveValue('I\'m a %foo% %%foo %foo%'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals(array('foo' => array('bar' => array('ding' => 'I\'m a bar %%foo %%bar'))), $bag->resolveValue(array('foo' => array('bar' => array('ding' => 'I\'m a bar %%foo %%bar')))), '->resolveValue() supports % escaping by doubling it'); - - $bag = new ParameterBag(array('foo' => true)); - $this->assertTrue($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); - $bag = new ParameterBag(array('foo' => null)); - $this->assertNull($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); - - $bag = new ParameterBag(array('foo' => 'bar', 'baz' => '%%%foo% %foo%%% %%foo%% %%%foo%%%')); - $this->assertEquals('%%bar bar%% %%foo%% %%bar%%', $bag->resolveValue('%baz%'), '->resolveValue() replaces params placed besides escaped %'); - - $bag = new ParameterBag(array('baz' => '%%s?%%s')); - $this->assertEquals('%%s?%%s', $bag->resolveValue('%baz%'), '->resolveValue() is not replacing greedily'); - - $bag = new ParameterBag(array()); - try { - $bag->resolveValue('%foobar%'); - $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter'); - } catch (ParameterNotFoundException $e) { - $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } - - try { - $bag->resolveValue('foo %foobar% bar'); - $this->fail('->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } catch (ParameterNotFoundException $e) { - $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } - - $bag = new ParameterBag(array('foo' => 'a %bar%', 'bar' => array())); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); - } catch (RuntimeException $e) { - $this->assertEquals('A string value must be composed of strings and/or numbers, but found parameter "bar" of type array inside string value "a %bar%".', $e->getMessage(), '->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); - } - - $bag = new ParameterBag(array('foo' => '%bar%', 'bar' => '%foobar%', 'foobar' => '%foo%')); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } catch (ParameterCircularReferenceException $e) { - $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } - - $bag = new ParameterBag(array('foo' => 'a %bar%', 'bar' => 'a %foobar%', 'foobar' => 'a %foo%')); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } catch (ParameterCircularReferenceException $e) { - $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } - - $bag = new ParameterBag(array('host' => 'foo.bar', 'port' => 1337)); - $this->assertEquals('foo.bar:1337', $bag->resolveValue('%host%:%port%')); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolve - */ - public function testResolveIndicatesWhyAParameterIsNeeded() - { - $bag = new ParameterBag(array('foo' => '%bar%')); - - try { - $bag->resolve(); - } catch (ParameterNotFoundException $e) { - $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); - } - - $bag = new ParameterBag(array('foo' => '%bar%')); - - try { - $bag->resolve(); - } catch (ParameterNotFoundException $e) { - $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); - } - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolve - */ - public function testResolveUnescapesValue() - { - $bag = new ParameterBag(array( - 'foo' => array('bar' => array('ding' => 'I\'m a bar %%foo %%bar')), - 'bar' => 'I\'m a %%foo%%', - )); - - $bag->resolve(); - - $this->assertEquals('I\'m a %foo%', $bag->get('bar'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals(array('bar' => array('ding' => 'I\'m a bar %foo %bar')), $bag->get('foo'), '->resolveValue() supports % escaping by doubling it'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::escapeValue - */ - public function testEscapeValue() - { - $bag = new ParameterBag(); - - $bag->add(array( - 'foo' => $bag->escapeValue(array('bar' => array('ding' => 'I\'m a bar %foo %bar', 'zero' => null))), - 'bar' => $bag->escapeValue('I\'m a %foo%'), - )); - - $this->assertEquals('I\'m a %%foo%%', $bag->get('bar'), '->escapeValue() escapes % by doubling it'); - $this->assertEquals(array('bar' => array('ding' => 'I\'m a bar %%foo %%bar', 'zero' => null)), $bag->get('foo'), '->escapeValue() escapes % by doubling it'); - } - - /** - * @covers Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolve - * @dataProvider stringsWithSpacesProvider - */ - public function testResolveStringWithSpacesReturnsString($expected, $test, $description) - { - $bag = new ParameterBag(array('foo' => 'bar')); - - try { - $this->assertEquals($expected, $bag->resolveString($test), $description); - } catch (ParameterNotFoundException $e) { - $this->fail(sprintf('%s - "%s"', $description, $expected)); - } - } - - public function stringsWithSpacesProvider() - { - return array( - array('bar', '%foo%', 'Parameters must be wrapped by %.'), - array('% foo %', '% foo %', 'Parameters should not have spaces.'), - array('{% set my_template = "foo" %}', '{% set my_template = "foo" %}', 'Twig-like strings are not parameters.'), - array('50% is less than 100%', '50% is less than 100%', 'Text between % signs is allowed, if there are spaces.'), - ); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterTest.php b/vendor/symfony/dependency-injection/Tests/ParameterTest.php deleted file mode 100644 index bed188e95..000000000 --- a/vendor/symfony/dependency-injection/Tests/ParameterTest.php +++ /dev/null @@ -1,26 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\Parameter; - -class ParameterTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Parameter::__construct - */ - public function testConstructor() - { - $ref = new Parameter('foo'); - $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the parameter, which is used for the __toString() method'); - } -} diff --git a/vendor/symfony/dependency-injection/Tests/ReferenceTest.php b/vendor/symfony/dependency-injection/Tests/ReferenceTest.php deleted file mode 100644 index f14e99f92..000000000 --- a/vendor/symfony/dependency-injection/Tests/ReferenceTest.php +++ /dev/null @@ -1,32 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DependencyInjection\Tests; - -use Symfony\Component\DependencyInjection\Reference; - -class ReferenceTest extends \PHPUnit_Framework_TestCase -{ - /** - * @covers Symfony\Component\DependencyInjection\Reference::__construct - */ - public function testConstructor() - { - $ref = new Reference('foo'); - $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the reference, which is used for the __toString() method'); - } - - public function testCaseInsensitive() - { - $ref = new Reference('FooBar'); - $this->assertEquals('foobar', (string) $ref, 'the id is lowercased as the container is case insensitive'); - } -} diff --git a/vendor/symfony/dom-crawler/Tests/CrawlerTest.php b/vendor/symfony/dom-crawler/Tests/CrawlerTest.php deleted file mode 100755 index 4cfd06f5c..000000000 --- a/vendor/symfony/dom-crawler/Tests/CrawlerTest.php +++ /dev/null @@ -1,1084 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\DomCrawler\Tests; - -use Symfony\Component\CssSelector\CssSelector; -use Symfony\Component\DomCrawler\Crawler; - -class CrawlerTest extends \PHPUnit_Framework_TestCase -{ - public function testConstructor() - { - $crawler = new Crawler(); - $this->assertCount(0, $crawler, '__construct() returns an empty crawler'); - - $crawler = new Crawler(new \DOMNode()); - $this->assertCount(1, $crawler, '__construct() takes a node as a first argument'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::add - */ - public function testAdd() - { - $crawler = new Crawler(); - $crawler->add($this->createDomDocument()); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->add() adds nodes from a \DOMDocument'); - - $crawler = new Crawler(); - $crawler->add($this->createNodeList()); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->add() adds nodes from a \DOMNodeList'); - - foreach ($this->createNodeList() as $node) { - $list[] = $node; - } - $crawler = new Crawler(); - $crawler->add($list); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->add() adds nodes from an array of nodes'); - - $crawler = new Crawler(); - $crawler->add($this->createNodeList()->item(0)); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->add() adds nodes from a \DOMElement'); - - $crawler = new Crawler(); - $crawler->add('Foo'); - $this->assertEquals('Foo', $crawler->filterXPath('//body')->text(), '->add() adds nodes from a string'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testAddInvalidNode() - { - $crawler = new Crawler(); - $crawler->add(1); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - */ - public function testAddHtmlContent() - { - $crawler = new Crawler(); - $crawler->addHtmlContent('
    ', 'UTF-8'); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addHtmlContent() adds nodes from an HTML string'); - - $crawler->addHtmlContent('', 'UTF-8'); - - $this->assertEquals('http://symfony.com', $crawler->filterXPath('//base')->attr('href'), '->addHtmlContent() adds nodes from an HTML string'); - $this->assertEquals('http://symfony.com/contact', $crawler->filterXPath('//a')->link()->getUri(), '->addHtmlContent() adds nodes from an HTML string'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - * @requires extension mbstring - */ - public function testAddHtmlContentCharset() - { - $crawler = new Crawler(); - $crawler->addHtmlContent('
    Tiếng Việt', 'UTF-8'); - - $this->assertEquals('Tiếng Việt', $crawler->filterXPath('//div')->text()); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - */ - public function testAddHtmlContentInvalidBaseTag() - { - $crawler = new Crawler(null, 'http://symfony.com'); - - $crawler->addHtmlContent('', 'UTF-8'); - - $this->assertEquals('http://symfony.com/contact', current($crawler->filterXPath('//a')->links())->getUri(), '->addHtmlContent() correctly handles a non-existent base tag href attribute'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - */ - public function testAddHtmlContentUnsupportedCharset() - { - $crawler = new Crawler(); - $crawler->addHtmlContent(file_get_contents(__DIR__.'/Fixtures/windows-1250.html'), 'Windows-1250'); - - $this->assertEquals('Žťčýů', $crawler->filterXPath('//p')->text()); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - * @requires extension mbstring - */ - public function testAddHtmlContentCharsetGbk() - { - $crawler = new Crawler(); - //gbk encode of

    中文

    - $crawler->addHtmlContent(base64_decode('PGh0bWw+PHA+1tDOxDwvcD48L2h0bWw+'), 'gbk'); - - $this->assertEquals('中文', $crawler->filterXPath('//p')->text()); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addHtmlContent - */ - public function testAddHtmlContentWithErrors() - { - $internalErrors = libxml_use_internal_errors(true); - - $crawler = new Crawler(); - $crawler->addHtmlContent(<< - - - - - - - -EOF - , 'UTF-8'); - - $errors = libxml_get_errors(); - $this->assertCount(1, $errors); - $this->assertEquals("Tag nav invalid\n", $errors[0]->message); - - libxml_clear_errors(); - libxml_use_internal_errors($internalErrors); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addXmlContent - */ - public function testAddXmlContent() - { - $crawler = new Crawler(); - $crawler->addXmlContent('
    ', 'UTF-8'); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addXmlContent() adds nodes from an XML string'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addXmlContent - */ - public function testAddXmlContentCharset() - { - $crawler = new Crawler(); - $crawler->addXmlContent('
    Tiếng Việt
    ', 'UTF-8'); - - $this->assertEquals('Tiếng Việt', $crawler->filterXPath('//div')->text()); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addXmlContent - */ - public function testAddXmlContentWithErrors() - { - $internalErrors = libxml_use_internal_errors(true); - - $crawler = new Crawler(); - $crawler->addXmlContent(<< - - - - -
    - - -EOF - , 'UTF-8'); - - $this->assertTrue(count(libxml_get_errors()) > 1); - - libxml_clear_errors(); - libxml_use_internal_errors($internalErrors); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addContent - */ - public function testAddContent() - { - $crawler = new Crawler(); - $crawler->addContent('
    ', 'text/html; charset=UTF-8'); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addContent() adds nodes from an HTML string'); - - $crawler = new Crawler(); - $crawler->addContent('
    ', 'text/html; charset=UTF-8; dir=RTL'); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addContent() adds nodes from an HTML string with extended content type'); - - $crawler = new Crawler(); - $crawler->addContent('
    '); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addContent() uses text/html as the default type'); - - $crawler = new Crawler(); - $crawler->addContent('
    ', 'text/xml; charset=UTF-8'); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addContent() adds nodes from an XML string'); - - $crawler = new Crawler(); - $crawler->addContent('
    ', 'text/xml'); - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addContent() adds nodes from an XML string'); - - $crawler = new Crawler(); - $crawler->addContent('foo bar', 'text/plain'); - $this->assertCount(0, $crawler, '->addContent() does nothing if the type is not (x|ht)ml'); - - $crawler = new Crawler(); - $crawler->addContent('中文'); - $this->assertEquals('中文', $crawler->filterXPath('//span')->text(), '->addContent() guess wrong charset'); - - $crawler = new Crawler(); - $crawler->addContent(iconv('UTF-8', 'SJIS', '日本語')); - $this->assertEquals('日本語', $crawler->filterXPath('//body')->text(), '->addContent() can recognize "Shift_JIS" in html5 meta charset tag'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addDocument - */ - public function testAddDocument() - { - $crawler = new Crawler(); - $crawler->addDocument($this->createDomDocument()); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addDocument() adds nodes from a \DOMDocument'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addNodeList - */ - public function testAddNodeList() - { - $crawler = new Crawler(); - $crawler->addNodeList($this->createNodeList()); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addNodeList() adds nodes from a \DOMNodeList'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addNodes - */ - public function testAddNodes() - { - foreach ($this->createNodeList() as $node) { - $list[] = $node; - } - - $crawler = new Crawler(); - $crawler->addNodes($list); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addNodes() adds nodes from an array of nodes'); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::addNode - */ - public function testAddNode() - { - $crawler = new Crawler(); - $crawler->addNode($this->createNodeList()->item(0)); - - $this->assertEquals('foo', $crawler->filterXPath('//div')->attr('class'), '->addNode() adds nodes from a \DOMElement'); - } - - public function testClear() - { - $crawler = new Crawler(new \DOMNode()); - $crawler->clear(); - $this->assertCount(0, $crawler, '->clear() removes all the nodes from the crawler'); - } - - public function testEq() - { - $crawler = $this->createTestCrawler()->filterXPath('//li'); - $this->assertNotSame($crawler, $crawler->eq(0), '->eq() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->eq() returns a new instance of a crawler'); - - $this->assertEquals('Two', $crawler->eq(1)->text(), '->eq() returns the nth node of the list'); - $this->assertCount(0, $crawler->eq(100), '->eq() returns an empty crawler if the nth node does not exist'); - } - - public function testEach() - { - $data = $this->createTestCrawler()->filterXPath('//ul[1]/li')->each(function ($node, $i) { - return $i.'-'.$node->text(); - }); - - $this->assertEquals(array('0-One', '1-Two', '2-Three'), $data, '->each() executes an anonymous function on each node of the list'); - } - - public function testSlice() - { - $crawler = $this->createTestCrawler()->filterXPath('//ul[1]/li'); - $this->assertNotSame($crawler->slice(), $crawler, '->slice() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->slice(), '->slice() returns a new instance of a crawler'); - - $this->assertCount(3, $crawler->slice(), '->slice() does not slice the nodes in the list if any param is entered'); - $this->assertCount(1, $crawler->slice(1, 1), '->slice() slices the nodes in the list'); - } - - public function testReduce() - { - $crawler = $this->createTestCrawler()->filterXPath('//ul[1]/li'); - $nodes = $crawler->reduce(function ($node, $i) { - return $i !== 1; - }); - $this->assertNotSame($nodes, $crawler, '->reduce() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $nodes, '->reduce() returns a new instance of a crawler'); - - $this->assertCount(2, $nodes, '->reduce() filters the nodes in the list'); - } - - public function testAttr() - { - $this->assertEquals('first', $this->createTestCrawler()->filterXPath('//li')->attr('class'), '->attr() returns the attribute of the first element of the node list'); - - try { - $this->createTestCrawler()->filterXPath('//ol')->attr('class'); - $this->fail('->attr() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->attr() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testMissingAttrValueIsNull() - { - $crawler = new Crawler(); - $crawler->addContent('
    ', 'text/html; charset=UTF-8'); - $div = $crawler->filterXPath('//div'); - - $this->assertEquals('sample value', $div->attr('non-empty-attr'), '->attr() reads non-empty attributes correctly'); - $this->assertEquals('', $div->attr('empty-attr'), '->attr() reads empty attributes correctly'); - $this->assertNull($div->attr('missing-attr'), '->attr() reads missing attributes correctly'); - } - - public function testNodeName() - { - $this->assertEquals('li', $this->createTestCrawler()->filterXPath('//li')->nodeName(), '->nodeName() returns the node name of the first element of the node list'); - - try { - $this->createTestCrawler()->filterXPath('//ol')->nodeName(); - $this->fail('->nodeName() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->nodeName() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testText() - { - $this->assertEquals('One', $this->createTestCrawler()->filterXPath('//li')->text(), '->text() returns the node value of the first element of the node list'); - - try { - $this->createTestCrawler()->filterXPath('//ol')->text(); - $this->fail('->text() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->text() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testHtml() - { - $this->assertEquals('Bar', $this->createTestCrawler()->filterXPath('//a[5]')->html()); - $this->assertEquals('', trim($this->createTestCrawler()->filterXPath('//form[@id="FooFormId"]')->html())); - - try { - $this->createTestCrawler()->filterXPath('//ol')->html(); - $this->fail('->html() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->html() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testExtract() - { - $crawler = $this->createTestCrawler()->filterXPath('//ul[1]/li'); - - $this->assertEquals(array('One', 'Two', 'Three'), $crawler->extract('_text'), '->extract() returns an array of extracted data from the node list'); - $this->assertEquals(array(array('One', 'first'), array('Two', ''), array('Three', '')), $crawler->extract(array('_text', 'class')), '->extract() returns an array of extracted data from the node list'); - - $this->assertEquals(array(), $this->createTestCrawler()->filterXPath('//ol')->extract('_text'), '->extract() returns an empty array if the node list is empty'); - } - - public function testFilterXpathComplexQueries() - { - $crawler = $this->createTestCrawler()->filterXPath('//body'); - - $this->assertCount(0, $crawler->filterXPath('/input')); - $this->assertCount(0, $crawler->filterXPath('/body')); - $this->assertCount(1, $crawler->filterXPath('/_root/body')); - $this->assertCount(1, $crawler->filterXPath('./body')); - $this->assertCount(1, $crawler->filterXPath('.//body')); - $this->assertCount(5, $crawler->filterXPath('.//input')); - $this->assertCount(4, $crawler->filterXPath('//form')->filterXPath('//button | //input')); - $this->assertCount(1, $crawler->filterXPath('body')); - $this->assertCount(6, $crawler->filterXPath('//button | //input')); - $this->assertCount(1, $crawler->filterXPath('//body')); - $this->assertCount(1, $crawler->filterXPath('descendant-or-self::body')); - $this->assertCount(1, $crawler->filterXPath('//div[@id="parent"]')->filterXPath('./div'), 'A child selection finds only the current div'); - $this->assertCount(3, $crawler->filterXPath('//div[@id="parent"]')->filterXPath('descendant::div'), 'A descendant selector matches the current div and its child'); - $this->assertCount(3, $crawler->filterXPath('//div[@id="parent"]')->filterXPath('//div'), 'A descendant selector matches the current div and its child'); - $this->assertCount(5, $crawler->filterXPath('(//a | //div)//img')); - $this->assertCount(7, $crawler->filterXPath('((//a | //div)//img | //ul)')); - $this->assertCount(7, $crawler->filterXPath('( ( //a | //div )//img | //ul )')); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::filterXPath - */ - public function testFilterXPath() - { - $crawler = $this->createTestCrawler(); - $this->assertNotSame($crawler, $crawler->filterXPath('//li'), '->filterXPath() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->filterXPath() returns a new instance of a crawler'); - - $crawler = $this->createTestCrawler()->filterXPath('//ul'); - $this->assertCount(6, $crawler->filterXPath('//li'), '->filterXPath() filters the node list with the XPath expression'); - - $crawler = $this->createTestCrawler(); - $this->assertCount(3, $crawler->filterXPath('//body')->filterXPath('//button')->parents(), '->filterXpath() preserves parents when chained'); - } - - public function testFilterXPathWithDefaultNamespace() - { - $crawler = $this->createTestXmlCrawler()->filterXPath('//default:entry/default:id'); - $this->assertCount(1, $crawler, '->filterXPath() automatically registers a namespace'); - $this->assertSame('tag:youtube.com,2008:video:kgZRZmEc9j4', $crawler->text()); - } - - public function testFilterXPathWithCustomDefaultNamespace() - { - $crawler = $this->createTestXmlCrawler(); - $crawler->setDefaultNamespacePrefix('x'); - $crawler = $crawler->filterXPath('//x:entry/x:id'); - - $this->assertCount(1, $crawler, '->filterXPath() lets to override the default namespace prefix'); - $this->assertSame('tag:youtube.com,2008:video:kgZRZmEc9j4', $crawler->text()); - } - - public function testFilterXPathWithNamespace() - { - $crawler = $this->createTestXmlCrawler()->filterXPath('//yt:accessControl'); - $this->assertCount(2, $crawler, '->filterXPath() automatically registers a namespace'); - } - - public function testFilterXPathWithMultipleNamespaces() - { - $crawler = $this->createTestXmlCrawler()->filterXPath('//media:group/yt:aspectRatio'); - $this->assertCount(1, $crawler, '->filterXPath() automatically registers multiple namespaces'); - $this->assertSame('widescreen', $crawler->text()); - } - - public function testFilterXPathWithManuallyRegisteredNamespace() - { - $crawler = $this->createTestXmlCrawler(); - $crawler->registerNamespace('m', 'http://search.yahoo.com/mrss/'); - - $crawler = $crawler->filterXPath('//m:group/yt:aspectRatio'); - $this->assertCount(1, $crawler, '->filterXPath() uses manually registered namespace'); - $this->assertSame('widescreen', $crawler->text()); - } - - public function testFilterXPathWithAnUrl() - { - $crawler = $this->createTestXmlCrawler(); - - $crawler = $crawler->filterXPath('//media:category[@scheme="http://gdata.youtube.com/schemas/2007/categories.cat"]'); - $this->assertCount(1, $crawler); - $this->assertSame('Music', $crawler->text()); - } - - public function testFilterXPathWithFakeRoot() - { - $crawler = $this->createTestCrawler(); - $this->assertCount(0, $crawler->filterXPath('.'), '->filterXPath() returns an empty result if the XPath references the fake root node'); - $this->assertCount(0, $crawler->filterXPath('/_root'), '->filterXPath() returns an empty result if the XPath references the fake root node'); - $this->assertCount(0, $crawler->filterXPath('self::*'), '->filterXPath() returns an empty result if the XPath references the fake root node'); - $this->assertCount(0, $crawler->filterXPath('self::_root'), '->filterXPath() returns an empty result if the XPath references the fake root node'); - } - - public function testFilterXPathWithAncestorAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//form'); - - $this->assertCount(0, $crawler->filterXPath('ancestor::*'), 'The fake root node has no ancestor nodes'); - } - - public function testFilterXPathWithAncestorOrSelfAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//form'); - - $this->assertCount(0, $crawler->filterXPath('ancestor-or-self::*'), 'The fake root node has no ancestor nodes'); - } - - public function testFilterXPathWithAttributeAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//form'); - - $this->assertCount(0, $crawler->filterXPath('attribute::*'), 'The fake root node has no attribute nodes'); - } - - public function testFilterXPathWithAttributeAxisAfterElementAxis() - { - $this->assertCount(3, $this->createTestCrawler()->filterXPath('//form/button/attribute::*'), '->filterXPath() handles attribute axes properly when they are preceded by an element filtering axis'); - } - - public function testFilterXPathWithChildAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//div[@id="parent"]'); - - $this->assertCount(1, $crawler->filterXPath('child::div'), 'A child selection finds only the current div'); - } - - public function testFilterXPathWithFollowingAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//a'); - - $this->assertCount(0, $crawler->filterXPath('following::div'), 'The fake root node has no following nodes'); - } - - public function testFilterXPathWithFollowingSiblingAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//a'); - - $this->assertCount(0, $crawler->filterXPath('following-sibling::div'), 'The fake root node has no following nodes'); - } - - public function testFilterXPathWithNamespaceAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//button'); - - $this->assertCount(0, $crawler->filterXPath('namespace::*'), 'The fake root node has no namespace nodes'); - } - - public function testFilterXPathWithNamespaceAxisAfterElementAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//div[@id="parent"]/namespace::*'); - - $this->assertCount(0, $crawler->filterXPath('namespace::*'), 'Namespace axes cannot be requested'); - } - - public function testFilterXPathWithParentAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//button'); - - $this->assertCount(0, $crawler->filterXPath('parent::*'), 'The fake root node has no parent nodes'); - } - - public function testFilterXPathWithPrecedingAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//form'); - - $this->assertCount(0, $crawler->filterXPath('preceding::*'), 'The fake root node has no preceding nodes'); - } - - public function testFilterXPathWithPrecedingSiblingAxis() - { - $crawler = $this->createTestCrawler()->filterXPath('//form'); - - $this->assertCount(0, $crawler->filterXPath('preceding-sibling::*'), 'The fake root node has no preceding nodes'); - } - - public function testFilterXPathWithSelfAxes() - { - $crawler = $this->createTestCrawler()->filterXPath('//a'); - - $this->assertCount(0, $crawler->filterXPath('self::a'), 'The fake root node has no "real" element name'); - $this->assertCount(0, $crawler->filterXPath('self::a/img'), 'The fake root node has no "real" element name'); - $this->assertCount(9, $crawler->filterXPath('self::*/a')); - } - - /** - * @covers Symfony\Component\DomCrawler\Crawler::filter - */ - public function testFilter() - { - $crawler = $this->createTestCrawler(); - $this->assertNotSame($crawler, $crawler->filter('li'), '->filter() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->filter() returns a new instance of a crawler'); - - $crawler = $this->createTestCrawler()->filter('ul'); - - $this->assertCount(6, $crawler->filter('li'), '->filter() filters the node list with the CSS selector'); - } - - public function testFilterWithDefaultNamespace() - { - $crawler = $this->createTestXmlCrawler()->filter('default|entry default|id'); - $this->assertCount(1, $crawler, '->filter() automatically registers namespaces'); - $this->assertSame('tag:youtube.com,2008:video:kgZRZmEc9j4', $crawler->text()); - } - - public function testFilterWithNamespace() - { - CssSelector::disableHtmlExtension(); - - $crawler = $this->createTestXmlCrawler()->filter('yt|accessControl'); - $this->assertCount(2, $crawler, '->filter() automatically registers namespaces'); - } - - public function testFilterWithMultipleNamespaces() - { - CssSelector::disableHtmlExtension(); - - $crawler = $this->createTestXmlCrawler()->filter('media|group yt|aspectRatio'); - $this->assertCount(1, $crawler, '->filter() automatically registers namespaces'); - $this->assertSame('widescreen', $crawler->text()); - } - - public function testFilterWithDefaultNamespaceOnly() - { - $crawler = new Crawler(' - - - http://localhost/foo - weekly - 0.5 - 2012-11-16 - - - http://localhost/bar - weekly - 0.5 - 2012-11-16 - - - '); - - $this->assertEquals(2, $crawler->filter('url')->count()); - } - - public function testSelectLink() - { - $crawler = $this->createTestCrawler(); - $this->assertNotSame($crawler, $crawler->selectLink('Foo'), '->selectLink() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->selectLink() returns a new instance of a crawler'); - - $this->assertCount(1, $crawler->selectLink('Fabien\'s Foo'), '->selectLink() selects links by the node values'); - $this->assertCount(1, $crawler->selectLink('Fabien\'s Bar'), '->selectLink() selects links by the alt attribute of a clickable image'); - - $this->assertCount(2, $crawler->selectLink('Fabien"s Foo'), '->selectLink() selects links by the node values'); - $this->assertCount(2, $crawler->selectLink('Fabien"s Bar'), '->selectLink() selects links by the alt attribute of a clickable image'); - - $this->assertCount(1, $crawler->selectLink('\' Fabien"s Foo'), '->selectLink() selects links by the node values'); - $this->assertCount(1, $crawler->selectLink('\' Fabien"s Bar'), '->selectLink() selects links by the alt attribute of a clickable image'); - - $this->assertCount(4, $crawler->selectLink('Foo'), '->selectLink() selects links by the node values'); - $this->assertCount(4, $crawler->selectLink('Bar'), '->selectLink() selects links by the node values'); - } - - public function testSelectButton() - { - $crawler = $this->createTestCrawler(); - $this->assertNotSame($crawler, $crawler->selectButton('FooValue'), '->selectButton() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->selectButton() returns a new instance of a crawler'); - - $this->assertEquals(1, $crawler->selectButton('FooValue')->count(), '->selectButton() selects buttons'); - $this->assertEquals(1, $crawler->selectButton('FooName')->count(), '->selectButton() selects buttons'); - $this->assertEquals(1, $crawler->selectButton('FooId')->count(), '->selectButton() selects buttons'); - - $this->assertEquals(1, $crawler->selectButton('BarValue')->count(), '->selectButton() selects buttons'); - $this->assertEquals(1, $crawler->selectButton('BarName')->count(), '->selectButton() selects buttons'); - $this->assertEquals(1, $crawler->selectButton('BarId')->count(), '->selectButton() selects buttons'); - - $this->assertEquals(1, $crawler->selectButton('FooBarValue')->count(), '->selectButton() selects buttons with form attribute too'); - $this->assertEquals(1, $crawler->selectButton('FooBarName')->count(), '->selectButton() selects buttons with form attribute too'); - } - - public function testSelectButtonWithSingleQuotesInNameAttribute() - { - $html = << - - -
    -
    - - - - -HTML; - - $crawler = new Crawler($html); - - $this->assertCount(1, $crawler->selectButton('Click \'Here\'')); - } - - public function testSelectButtonWithDoubleQuotesInNameAttribute() - { - $html = << - - -
    - Login -
    -
    - - - - -HTML; - - $crawler = new Crawler($html); - - $this->assertCount(1, $crawler->selectButton('Click "Here"')); - } - - public function testLink() - { - $crawler = $this->createTestCrawler('http://example.com/bar/')->selectLink('Foo'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Link', $crawler->link(), '->link() returns a Link instance'); - - $this->assertEquals('POST', $crawler->link('post')->getMethod(), '->link() takes a method as its argument'); - - $crawler = $this->createTestCrawler('http://example.com/bar')->selectLink('GetLink'); - $this->assertEquals('http://example.com/bar?get=param', $crawler->link()->getUri(), '->link() returns a Link instance'); - - try { - $this->createTestCrawler()->filterXPath('//ol')->link(); - $this->fail('->link() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->link() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testSelectLinkAndLinkFiltered() - { - $html = << - - -
    - Login -
    -
    - - - - -HTML; - - $crawler = new Crawler($html); - $filtered = $crawler->filterXPath("descendant-or-self::*[@id = 'login-form']"); - - $this->assertCount(0, $filtered->selectLink('Login')); - $this->assertCount(1, $filtered->selectButton('Submit')); - - $filtered = $crawler->filterXPath("descendant-or-self::*[@id = 'action']"); - - $this->assertCount(1, $filtered->selectLink('Login')); - $this->assertCount(0, $filtered->selectButton('Submit')); - - $this->assertCount(1, $crawler->selectLink('Login')->selectLink('Login')); - $this->assertCount(1, $crawler->selectButton('Submit')->selectButton('Submit')); - } - - public function testChaining() - { - $crawler = new Crawler('
    '); - - $this->assertEquals('a', $crawler->filterXPath('//div')->filterXPath('div')->filterXPath('div')->attr('name')); - } - - public function testLinks() - { - $crawler = $this->createTestCrawler('http://example.com/bar/')->selectLink('Foo'); - $this->assertInternalType('array', $crawler->links(), '->links() returns an array'); - - $this->assertCount(4, $crawler->links(), '->links() returns an array'); - $links = $crawler->links(); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Link', $links[0], '->links() returns an array of Link instances'); - - $this->assertEquals(array(), $this->createTestCrawler()->filterXPath('//ol')->links(), '->links() returns an empty array if the node selection is empty'); - } - - public function testForm() - { - $testCrawler = $this->createTestCrawler('http://example.com/bar/'); - $crawler = $testCrawler->selectButton('FooValue'); - $crawler2 = $testCrawler->selectButton('FooBarValue'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Form', $crawler->form(), '->form() returns a Form instance'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Form', $crawler2->form(), '->form() returns a Form instance'); - - $this->assertEquals($crawler->form()->getFormNode()->getAttribute('id'), $crawler2->form()->getFormNode()->getAttribute('id'), '->form() works on elements with form attribute'); - - $this->assertEquals(array('FooName' => 'FooBar', 'TextName' => 'TextValue', 'FooTextName' => 'FooTextValue'), $crawler->form(array('FooName' => 'FooBar'))->getValues(), '->form() takes an array of values to submit as its first argument'); - $this->assertEquals(array('FooName' => 'FooValue', 'TextName' => 'TextValue', 'FooTextName' => 'FooTextValue'), $crawler->form()->getValues(), '->getValues() returns correct form values'); - $this->assertEquals(array('FooBarName' => 'FooBarValue', 'TextName' => 'TextValue', 'FooTextName' => 'FooTextValue'), $crawler2->form()->getValues(), '->getValues() returns correct form values'); - - try { - $this->createTestCrawler()->filterXPath('//ol')->form(); - $this->fail('->form() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->form() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testLast() - { - $crawler = $this->createTestCrawler()->filterXPath('//ul[1]/li'); - $this->assertNotSame($crawler, $crawler->last(), '->last() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->last() returns a new instance of a crawler'); - - $this->assertEquals('Three', $crawler->last()->text()); - } - - public function testFirst() - { - $crawler = $this->createTestCrawler()->filterXPath('//li'); - $this->assertNotSame($crawler, $crawler->first(), '->first() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->first() returns a new instance of a crawler'); - - $this->assertEquals('One', $crawler->first()->text()); - } - - public function testSiblings() - { - $crawler = $this->createTestCrawler()->filterXPath('//li')->eq(1); - $this->assertNotSame($crawler, $crawler->siblings(), '->siblings() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->siblings() returns a new instance of a crawler'); - - $nodes = $crawler->siblings(); - $this->assertEquals(2, $nodes->count()); - $this->assertEquals('One', $nodes->eq(0)->text()); - $this->assertEquals('Three', $nodes->eq(1)->text()); - - $nodes = $this->createTestCrawler()->filterXPath('//li')->eq(0)->siblings(); - $this->assertEquals(2, $nodes->count()); - $this->assertEquals('Two', $nodes->eq(0)->text()); - $this->assertEquals('Three', $nodes->eq(1)->text()); - - try { - $this->createTestCrawler()->filterXPath('//ol')->siblings(); - $this->fail('->siblings() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->siblings() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testNextAll() - { - $crawler = $this->createTestCrawler()->filterXPath('//li')->eq(1); - $this->assertNotSame($crawler, $crawler->nextAll(), '->nextAll() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->nextAll() returns a new instance of a crawler'); - - $nodes = $crawler->nextAll(); - $this->assertEquals(1, $nodes->count()); - $this->assertEquals('Three', $nodes->eq(0)->text()); - - try { - $this->createTestCrawler()->filterXPath('//ol')->nextAll(); - $this->fail('->nextAll() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->nextAll() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testPreviousAll() - { - $crawler = $this->createTestCrawler()->filterXPath('//li')->eq(2); - $this->assertNotSame($crawler, $crawler->previousAll(), '->previousAll() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->previousAll() returns a new instance of a crawler'); - - $nodes = $crawler->previousAll(); - $this->assertEquals(2, $nodes->count()); - $this->assertEquals('Two', $nodes->eq(0)->text()); - - try { - $this->createTestCrawler()->filterXPath('//ol')->previousAll(); - $this->fail('->previousAll() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->previousAll() throws an \InvalidArgumentException if the node list is empty'); - } - } - - public function testChildren() - { - $crawler = $this->createTestCrawler()->filterXPath('//ul'); - $this->assertNotSame($crawler, $crawler->children(), '->children() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->children() returns a new instance of a crawler'); - - $nodes = $crawler->children(); - $this->assertEquals(3, $nodes->count()); - $this->assertEquals('One', $nodes->eq(0)->text()); - $this->assertEquals('Two', $nodes->eq(1)->text()); - $this->assertEquals('Three', $nodes->eq(2)->text()); - - try { - $this->createTestCrawler()->filterXPath('//ol')->children(); - $this->fail('->children() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->children() throws an \InvalidArgumentException if the node list is empty'); - } - - try { - $crawler = new Crawler('

    '); - $crawler->filter('p')->children(); - $this->assertTrue(true, '->children() does not trigger a notice if the node has no children'); - } catch (\PHPUnit_Framework_Error_Notice $e) { - $this->fail('->children() does not trigger a notice if the node has no children'); - } - } - - public function testParents() - { - $crawler = $this->createTestCrawler()->filterXPath('//li[1]'); - $this->assertNotSame($crawler, $crawler->parents(), '->parents() returns a new instance of a crawler'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->parents() returns a new instance of a crawler'); - - $nodes = $crawler->parents(); - $this->assertEquals(3, $nodes->count()); - - $nodes = $this->createTestCrawler()->filterXPath('//html')->parents(); - $this->assertEquals(0, $nodes->count()); - - try { - $this->createTestCrawler()->filterXPath('//ol')->parents(); - $this->fail('->parents() throws an \InvalidArgumentException if the node list is empty'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->parents() throws an \InvalidArgumentException if the node list is empty'); - } - } - - /** - * @dataProvider getBaseTagData - */ - public function testBaseTag($baseValue, $linkValue, $expectedUri, $currentUri = null, $description = null) - { - $crawler = new Crawler('', $currentUri); - $this->assertEquals($expectedUri, $crawler->filterXPath('//a')->link()->getUri(), $description); - } - - public function getBaseTagData() - { - return array( - array('http://base.com', 'link', 'http://base.com/link'), - array('//base.com', 'link', 'https://base.com/link', 'https://domain.com', ' tag can use a schema-less URL'), - array('path/', 'link', 'https://domain.com/path/link', 'https://domain.com', ' tag can set a path'), - array('http://base.com', '#', 'http://base.com#', 'http://domain.com/path/link', ' tag does work with links to an anchor'), - array('http://base.com', '', 'http://base.com', 'http://domain.com/path/link', ' tag does work with empty links'), - ); - } - - /** - * @dataProvider getBaseTagWithFormData - */ - public function testBaseTagWithForm($baseValue, $actionValue, $expectedUri, $currentUri = null, $description = null) - { - $crawler = new Crawler('
    ', - array('bar' => array('InputFormField', 'bar')), - ), - array( - 'appends the submitted button value but not other submit buttons', - ' - ', - array('foobar' => array('InputFormField', 'foobar')), - ), - array( - 'turns an image input into x and y fields', - '', - array('bar.x' => array('InputFormField', '0'), 'bar.y' => array('InputFormField', '0')), - ), - array( - 'returns textareas', - ' - ', - array('foo' => array('TextareaFormField', 'foo')), - ), - array( - 'returns inputs', - ' - ', - array('foo' => array('InputFormField', 'foo')), - ), - array( - 'returns checkboxes', - ' - ', - array('foo' => array('ChoiceFormField', 'foo')), - ), - array( - 'returns not-checked checkboxes', - ' - ', - array('foo' => array('ChoiceFormField', false)), - ), - array( - 'returns radio buttons', - ' - - ', - array('foo' => array('ChoiceFormField', 'bar')), - ), - array( - 'returns file inputs', - ' - ', - array('foo' => array('FileFormField', array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0))), - ), - ); - } - - public function testGetFormNode() - { - $dom = new \DOMDocument(); - $dom->loadHTML('
    '); - - $form = new Form($dom->getElementsByTagName('input')->item(0), 'http://example.com'); - - $this->assertSame($dom->getElementsByTagName('form')->item(0), $form->getFormNode(), '->getFormNode() returns the form node associated with this form'); - } - - public function testGetFormNodeFromNamedForm() - { - $dom = new \DOMDocument(); - $dom->loadHTML('
    '); - - $form = new Form($dom->getElementsByTagName('form')->item(0), 'http://example.com'); - - $this->assertSame($dom->getElementsByTagName('form')->item(0), $form->getFormNode(), '->getFormNode() returns the form node associated with this form'); - } - - public function testGetMethod() - { - $form = $this->createForm('
    '); - $this->assertEquals('GET', $form->getMethod(), '->getMethod() returns get if no method is defined'); - - $form = $this->createForm('
    '); - $this->assertEquals('POST', $form->getMethod(), '->getMethod() returns the method attribute value of the form'); - - $form = $this->createForm('
    ', 'put'); - $this->assertEquals('PUT', $form->getMethod(), '->getMethod() returns the method defined in the constructor if provided'); - - $form = $this->createForm('
    ', 'delete'); - $this->assertEquals('DELETE', $form->getMethod(), '->getMethod() returns the method defined in the constructor if provided'); - - $form = $this->createForm('
    ', 'patch'); - $this->assertEquals('PATCH', $form->getMethod(), '->getMethod() returns the method defined in the constructor if provided'); - } - - public function testGetSetValue() - { - $form = $this->createForm('
    '); - - $this->assertEquals('foo', $form['foo']->getValue(), '->offsetGet() returns the value of a form field'); - - $form['foo'] = 'bar'; - - $this->assertEquals('bar', $form['foo']->getValue(), '->offsetSet() changes the value of a form field'); - - try { - $form['foobar'] = 'bar'; - $this->fail('->offsetSet() throws an \InvalidArgumentException exception if the field does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->offsetSet() throws an \InvalidArgumentException exception if the field does not exist'); - } - - try { - $form['foobar']; - $this->fail('->offsetSet() throws an \InvalidArgumentException exception if the field does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->offsetSet() throws an \InvalidArgumentException exception if the field does not exist'); - } - } - - public function testSetValueOnMultiValuedFieldsWithMalformedName() - { - $form = $this->createForm('
    '); - - try { - $form['foo[bar'] = 'bar'; - $this->fail('->offsetSet() throws an \InvalidArgumentException exception if the name is malformed.'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->offsetSet() throws an \InvalidArgumentException exception if the name is malformed.'); - } - } - - public function testDisableValidation() - { - $form = $this->createForm('
    - - - - '); - - $form->disableValidation(); - - $form['foo[bar]']->select('foo'); - $form['foo[baz]']->select('bar'); - $this->assertEquals('foo', $form['foo[bar]']->getValue(), '->disableValidation() disables validation of all ChoiceFormField.'); - $this->assertEquals('bar', $form['foo[baz]']->getValue(), '->disableValidation() disables validation of all ChoiceFormField.'); - } - - public function testOffsetUnset() - { - $form = $this->createForm('
    '); - unset($form['foo']); - $this->assertFalse(isset($form['foo']), '->offsetUnset() removes a field'); - } - - public function testOffsetExists() - { - $form = $this->createForm('
    '); - - $this->assertTrue(isset($form['foo']), '->offsetExists() return true if the field exists'); - $this->assertFalse(isset($form['bar']), '->offsetExists() return false if the field does not exist'); - } - - public function testGetValues() - { - $form = $this->createForm('
    '); - $this->assertEquals(array('foo[bar]' => 'foo', 'bar' => 'bar', 'baz' => array()), $form->getValues(), '->getValues() returns all form field values'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('bar' => 'bar'), $form->getValues(), '->getValues() does not include not-checked checkboxes'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('bar' => 'bar'), $form->getValues(), '->getValues() does not include file input fields'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('bar' => 'bar'), $form->getValues(), '->getValues() does not include disabled fields'); - } - - public function testSetValues() - { - $form = $this->createForm('
    '); - $form->setValues(array('foo' => false, 'bar' => 'foo')); - $this->assertEquals(array('bar' => 'foo'), $form->getValues(), '->setValues() sets the values of fields'); - } - - public function testMultiselectSetValues() - { - $form = $this->createForm('
    '); - $form->setValues(array('multi' => array('foo', 'bar'))); - $this->assertEquals(array('multi' => array('foo', 'bar')), $form->getValues(), '->setValue() sets the values of select'); - } - - public function testGetPhpValues() - { - $form = $this->createForm('
    '); - $this->assertEquals(array('foo' => array('bar' => 'foo'), 'bar' => 'bar'), $form->getPhpValues(), '->getPhpValues() converts keys with [] to arrays'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('fo.o' => array('ba.r' => 'foo'), 'ba r' => 'bar'), $form->getPhpValues(), '->getPhpValues() preserves periods and spaces in names'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('fo.o' => array('ba.r' => array('foo', 'ba.z' => 'bar'))), $form->getPhpValues(), '->getPhpValues() preserves periods and spaces in names recursively'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('foo' => array('bar' => 'foo'), 'bar' => 'bar'), $form->getPhpValues(), "->getPhpValues() doesn't return empty values"); - } - - public function testGetFiles() - { - $form = $this->createForm('
    '); - $this->assertEquals(array(), $form->getFiles(), '->getFiles() returns an empty array if method is get'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('foo[bar]' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0)), $form->getFiles(), '->getFiles() only returns file fields for POST'); - - $form = $this->createForm('
    ', 'put'); - $this->assertEquals(array('foo[bar]' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0)), $form->getFiles(), '->getFiles() only returns file fields for PUT'); - - $form = $this->createForm('
    ', 'delete'); - $this->assertEquals(array('foo[bar]' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0)), $form->getFiles(), '->getFiles() only returns file fields for DELETE'); - - $form = $this->createForm('
    ', 'patch'); - $this->assertEquals(array('foo[bar]' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0)), $form->getFiles(), '->getFiles() only returns file fields for PATCH'); - - $form = $this->createForm('
    '); - $this->assertEquals(array(), $form->getFiles(), '->getFiles() does not include disabled file fields'); - } - - public function testGetPhpFiles() - { - $form = $this->createForm('
    '); - $this->assertEquals(array('foo' => array('bar' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0))), $form->getPhpFiles(), '->getPhpFiles() converts keys with [] to arrays'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('f.o o' => array('bar' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0))), $form->getPhpFiles(), '->getPhpFiles() preserves periods and spaces in names'); - - $form = $this->createForm('
    '); - $this->assertEquals(array('f.o o' => array('bar' => array('ba.z' => array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0), array('name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0)))), $form->getPhpFiles(), '->getPhpFiles() preserves periods and spaces in names recursively'); - } - - /** - * @dataProvider provideGetUriValues - */ - public function testGetUri($message, $form, $values, $uri, $method = null) - { - $form = $this->createForm($form, $method); - $form->setValues($values); - - $this->assertEquals('http://example.com'.$uri, $form->getUri(), '->getUri() '.$message); - } - - public function testGetBaseUri() - { - $dom = new \DOMDocument(); - $dom->loadHTML('
    '); - - $nodes = $dom->getElementsByTagName('input'); - $form = new Form($nodes->item($nodes->length - 1), 'http://www.foo.com/'); - $this->assertEquals('http://www.foo.com/foo.php', $form->getUri()); - } - - public function testGetUriWithAnchor() - { - $form = $this->createForm('
    ', null, 'http://example.com/id/123'); - - $this->assertEquals('http://example.com/id/123#foo', $form->getUri()); - } - - public function testGetUriActionAbsolute() - { - $formHtml = '
    '; - - $form = $this->createForm($formHtml); - $this->assertEquals('https://login.foo.com/login.php?login_attempt=1', $form->getUri(), '->getUri() returns absolute URIs set in the action form'); - - $form = $this->createForm($formHtml, null, 'https://login.foo.com'); - $this->assertEquals('https://login.foo.com/login.php?login_attempt=1', $form->getUri(), '->getUri() returns absolute URIs set in the action form'); - - $form = $this->createForm($formHtml, null, 'https://login.foo.com/bar/'); - $this->assertEquals('https://login.foo.com/login.php?login_attempt=1', $form->getUri(), '->getUri() returns absolute URIs set in the action form'); - - // The action URI haven't the same domain Host have an another domain as Host - $form = $this->createForm($formHtml, null, 'https://www.foo.com'); - $this->assertEquals('https://login.foo.com/login.php?login_attempt=1', $form->getUri(), '->getUri() returns absolute URIs set in the action form'); - - $form = $this->createForm($formHtml, null, 'https://www.foo.com/bar/'); - $this->assertEquals('https://login.foo.com/login.php?login_attempt=1', $form->getUri(), '->getUri() returns absolute URIs set in the action form'); - } - - public function testGetUriAbsolute() - { - $form = $this->createForm('
    ', null, 'http://localhost/foo/'); - $this->assertEquals('http://localhost/foo/foo', $form->getUri(), '->getUri() returns absolute URIs'); - - $form = $this->createForm('
    ', null, 'http://localhost/foo/'); - $this->assertEquals('http://localhost/foo', $form->getUri(), '->getUri() returns absolute URIs'); - } - - public function testGetUriWithOnlyQueryString() - { - $form = $this->createForm('
    ', null, 'http://localhost/foo/bar'); - $this->assertEquals('http://localhost/foo/bar?get=param', $form->getUri(), '->getUri() returns absolute URIs only if the host has been defined in the constructor'); - } - - public function testGetUriWithoutAction() - { - $form = $this->createForm('
    ', null, 'http://localhost/foo/bar'); - $this->assertEquals('http://localhost/foo/bar', $form->getUri(), '->getUri() returns path if no action defined'); - } - - public function provideGetUriValues() - { - return array( - array( - 'returns the URI of the form', - '
    ', - array(), - '/foo', - ), - array( - 'appends the form values if the method is get', - '
    ', - array(), - '/foo?foo=foo', - ), - array( - 'appends the form values and merges the submitted values', - '
    ', - array('foo' => 'bar'), - '/foo?foo=bar', - ), - array( - 'does not append values if the method is post', - '
    ', - array(), - '/foo', - ), - array( - 'does not append values if the method is patch', - '
    ', - array(), - '/foo', - 'PUT', - ), - array( - 'does not append values if the method is delete', - '
    ', - array(), - '/foo', - 'DELETE', - ), - array( - 'does not append values if the method is put', - '
    ', - array(), - '/foo', - 'PATCH', - ), - array( - 'appends the form values to an existing query string', - '
    ', - array(), - '/foo?bar=bar&foo=foo', - ), - array( - 'replaces query values with the form values', - '
    ', - array(), - '/foo?bar=foo', - ), - array( - 'returns an empty URI if the action is empty', - '
    ', - array(), - '/', - ), - array( - 'appends the form values even if the action is empty', - '
    ', - array(), - '/?foo=foo', - ), - array( - 'chooses the path if the action attribute value is a sharp (#)', - '
    ', - array(), - '/#', - ), - ); - } - - public function testHas() - { - $form = $this->createForm('
    '); - - $this->assertFalse($form->has('foo'), '->has() returns false if a field is not in the form'); - $this->assertTrue($form->has('bar'), '->has() returns true if a field is in the form'); - } - - public function testRemove() - { - $form = $this->createForm('
    '); - $form->remove('bar'); - $this->assertFalse($form->has('bar'), '->remove() removes a field'); - } - - public function testGet() - { - $form = $this->createForm('
    '); - - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Field\\InputFormField', $form->get('bar'), '->get() returns the field object associated with the given name'); - - try { - $form->get('foo'); - $this->fail('->get() throws an \InvalidArgumentException if the field does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertTrue(true, '->get() throws an \InvalidArgumentException if the field does not exist'); - } - } - - public function testAll() - { - $form = $this->createForm('
    '); - - $fields = $form->all(); - $this->assertCount(1, $fields, '->all() return an array of form field objects'); - $this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Field\\InputFormField', $fields['bar'], '->all() return an array of form field objects'); - } - - public function testSubmitWithoutAFormButton() - { - $dom = new \DOMDocument(); - $dom->loadHTML(' - -
    - - - - '); - - $nodes = $dom->getElementsByTagName('form'); - $form = new Form($nodes->item(0), 'http://example.com'); - $this->assertSame($nodes->item(0), $form->getFormNode(), '->getFormNode() returns the form node associated with this form'); - } - - public function testTypeAttributeIsCaseInsensitive() - { - $form = $this->createForm('
    '); - $this->assertTrue($form->has('example.x'), '->has() returns true if the image input was correctly turned into an x and a y fields'); - $this->assertTrue($form->has('example.y'), '->has() returns true if the image input was correctly turned into an x and a y fields'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistryAddThrowAnExceptionWhenTheNameIsMalformed() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('[foo]')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistryRemoveThrowAnExceptionWhenTheNameIsMalformed() - { - $registry = new FormFieldRegistry(); - $registry->remove('[foo]'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistryGetThrowAnExceptionWhenTheNameIsMalformed() - { - $registry = new FormFieldRegistry(); - $registry->get('[foo]'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistryGetThrowAnExceptionWhenTheFieldDoesNotExist() - { - $registry = new FormFieldRegistry(); - $registry->get('foo'); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistrySetThrowAnExceptionWhenTheNameIsMalformed() - { - $registry = new FormFieldRegistry(); - $registry->set('[foo]', null); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testFormFieldRegistrySetThrowAnExceptionWhenTheFieldDoesNotExist() - { - $registry = new FormFieldRegistry(); - $registry->set('foo', null); - } - - public function testFormFieldRegistryHasReturnsTrueWhenTheFQNExists() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('foo[bar]')); - - $this->assertTrue($registry->has('foo')); - $this->assertTrue($registry->has('foo[bar]')); - $this->assertFalse($registry->has('bar')); - $this->assertFalse($registry->has('foo[foo]')); - } - - public function testFormRegistryFieldsCanBeRemoved() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('foo')); - $registry->remove('foo'); - $this->assertFalse($registry->has('foo')); - } - - public function testFormRegistrySupportsMultivaluedFields() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('foo[]')); - $registry->add($this->getFormFieldMock('foo[]')); - $registry->add($this->getFormFieldMock('bar[5]')); - $registry->add($this->getFormFieldMock('bar[]')); - $registry->add($this->getFormFieldMock('bar[baz]')); - - $this->assertEquals( - array('foo[0]', 'foo[1]', 'bar[5]', 'bar[6]', 'bar[baz]'), - array_keys($registry->all()) - ); - } - - public function testFormRegistrySetValues() - { - $registry = new FormFieldRegistry(); - $registry->add($f2 = $this->getFormFieldMock('foo[2]')); - $registry->add($f3 = $this->getFormFieldMock('foo[3]')); - $registry->add($fbb = $this->getFormFieldMock('foo[bar][baz]')); - - $f2 - ->expects($this->exactly(2)) - ->method('setValue') - ->with(2) - ; - - $f3 - ->expects($this->exactly(2)) - ->method('setValue') - ->with(3) - ; - - $fbb - ->expects($this->exactly(2)) - ->method('setValue') - ->with('fbb') - ; - - $registry->set('foo[2]', 2); - $registry->set('foo[3]', 3); - $registry->set('foo[bar][baz]', 'fbb'); - - $registry->set('foo', array( - 2 => 2, - 3 => 3, - 'bar' => array( - 'baz' => 'fbb', - ), - )); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Cannot set value on a compound field "foo[bar]". - */ - public function testFormRegistrySetValueOnCompoundField() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('foo[bar][baz]')); - - $registry->set('foo[bar]', 'fbb'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Unreachable field "0" - */ - public function testFormRegistrySetArrayOnNotCompoundField() - { - $registry = new FormFieldRegistry(); - $registry->add($this->getFormFieldMock('bar')); - - $registry->set('bar', array('baz')); - } - - public function testDifferentFieldTypesWithSameName() - { - $dom = new \DOMDocument(); - $dom->loadHTML(' - - -
    - - - - - - - - - - '); - $form = new Form($dom->getElementsByTagName('form')->item(0), 'http://example.com'); - - $this->assertInstanceOf('Symfony\Component\DomCrawler\Field\ChoiceFormField', $form->get('option')); - } - - protected function getFormFieldMock($name, $value = null) - { - $field = $this - ->getMockBuilder('Symfony\\Component\\DomCrawler\\Field\\FormField') - ->setMethods(array('getName', 'getValue', 'setValue', 'initialize')) - ->disableOriginalConstructor() - ->getMock() - ; - - $field - ->expects($this->any()) - ->method('getName') - ->will($this->returnValue($name)) - ; - - $field - ->expects($this->any()) - ->method('getValue') - ->will($this->returnValue($value)) - ; - - return $field; - } - - protected function createForm($form, $method = null, $currentUri = null) - { - $dom = new \DOMDocument(); - $dom->loadHTML(''.$form.''); - - $xPath = new \DOMXPath($dom); - $nodes = $xPath->query('//input | //button'); - - if (null === $currentUri) { - $currentUri = 'http://example.com/'; - } - - return new Form($nodes->item($nodes->length - 1), $currentUri, $method); - } - - protected function createTestHtml5Form() - { - $dom = new \DOMDocument(); - $dom->loadHTML(' - -

    Hello form

    -
    -
    - -
    - - - - -
    -
    -
    - - - -
    - -
    - -
    -
    -
    - - -
    - - - -
    -
    -
    - - - - -

    - {% for row in items|batch(3, 'No item') %} - - {% for column in row %} - - {% endfor %} - - {% endfor %} -
    {{ column }}
    - -The above example will be rendered as: - -.. code-block:: jinja - - - - - - - - - - - - - - - - - -
    abc
    def
    gNo itemNo item
    - -Arguments ---------- - -* ``size``: The size of the batch; fractional numbers will be rounded up -* ``fill``: Used to fill in missing items diff --git a/vendor/twig/twig/doc/filters/capitalize.rst b/vendor/twig/twig/doc/filters/capitalize.rst deleted file mode 100644 index 10546a1f3..000000000 --- a/vendor/twig/twig/doc/filters/capitalize.rst +++ /dev/null @@ -1,11 +0,0 @@ -``capitalize`` -============== - -The ``capitalize`` filter capitalizes a value. The first character will be -uppercase, all others lowercase: - -.. code-block:: jinja - - {{ 'my first car'|capitalize }} - - {# outputs 'My first car' #} diff --git a/vendor/twig/twig/doc/filters/convert_encoding.rst b/vendor/twig/twig/doc/filters/convert_encoding.rst deleted file mode 100644 index f4ebe5807..000000000 --- a/vendor/twig/twig/doc/filters/convert_encoding.rst +++ /dev/null @@ -1,28 +0,0 @@ -``convert_encoding`` -==================== - -.. versionadded:: 1.4 - The ``convert_encoding`` filter was added in Twig 1.4. - -The ``convert_encoding`` filter converts a string from one encoding to -another. The first argument is the expected output charset and the second one -is the input charset: - -.. code-block:: jinja - - {{ data|convert_encoding('UTF-8', 'iso-2022-jp') }} - -.. note:: - - This filter relies on the `iconv`_ or `mbstring`_ extension, so one of - them must be installed. In case both are installed, `mbstring`_ is used by - default (Twig before 1.8.1 uses `iconv`_ by default). - -Arguments ---------- - -* ``to``: The output charset -* ``from``: The input charset - -.. _`iconv`: http://php.net/iconv -.. _`mbstring`: http://php.net/mbstring diff --git a/vendor/twig/twig/doc/filters/date.rst b/vendor/twig/twig/doc/filters/date.rst deleted file mode 100644 index c86d42baf..000000000 --- a/vendor/twig/twig/doc/filters/date.rst +++ /dev/null @@ -1,94 +0,0 @@ -``date`` -======== - -.. versionadded:: 1.1 - The timezone support has been added in Twig 1.1. - -.. versionadded:: 1.5 - The default date format support has been added in Twig 1.5. - -.. versionadded:: 1.6.1 - The default timezone support has been added in Twig 1.6.1. - -.. versionadded:: 1.11.0 - The introduction of the false value for the timezone was introduced in Twig 1.11.0 - -The ``date`` filter formats a date to a given format: - -.. code-block:: jinja - - {{ post.published_at|date("m/d/Y") }} - -The format specifier is the same as supported by `date`_, -except when the filtered data is of type `DateInterval`_, when the format must conform to -`DateInterval::format`_ instead. - -The ``date`` filter accepts strings (it must be in a format supported by the -`strtotime`_ function), `DateTime`_ instances, or `DateInterval`_ instances. For -instance, to display the current date, filter the word "now": - -.. code-block:: jinja - - {{ "now"|date("m/d/Y") }} - -To escape words and characters in the date format use ``\\`` in front of each -character: - -.. code-block:: jinja - - {{ post.published_at|date("F jS \\a\\t g:ia") }} - -If the value passed to the ``date`` filter is ``null``, it will return the -current date by default. If an empty string is desired instead of the current -date, use a ternary operator: - -.. code-block:: jinja - - {{ post.published_at is empty ? "" : post.published_at|date("m/d/Y") }} - -If no format is provided, Twig will use the default one: ``F j, Y H:i``. This -default can be easily changed by calling the ``setDateFormat()`` method on the -``core`` extension instance. The first argument is the default format for -dates and the second one is the default format for date intervals: - -.. code-block:: php - - $twig = new Twig_Environment($loader); - $twig->getExtension('core')->setDateFormat('d/m/Y', '%d days'); - -Timezone --------- - -By default, the date is displayed by applying the default timezone (the one -specified in php.ini or declared in Twig -- see below), but you can override -it by explicitly specifying a timezone: - -.. code-block:: jinja - - {{ post.published_at|date("m/d/Y", "Europe/Paris") }} - -If the date is already a DateTime object, and if you want to keep its current -timezone, pass ``false`` as the timezone value: - -.. code-block:: jinja - - {{ post.published_at|date("m/d/Y", false) }} - -The default timezone can also be set globally by calling ``setTimezone()``: - -.. code-block:: php - - $twig = new Twig_Environment($loader); - $twig->getExtension('core')->setTimezone('Europe/Paris'); - -Arguments ---------- - -* ``format``: The date format -* ``timezone``: The date timezone - -.. _`strtotime`: http://www.php.net/strtotime -.. _`DateTime`: http://www.php.net/DateTime -.. _`DateInterval`: http://www.php.net/DateInterval -.. _`date`: http://www.php.net/date -.. _`DateInterval::format`: http://www.php.net/DateInterval.format diff --git a/vendor/twig/twig/doc/filters/date_modify.rst b/vendor/twig/twig/doc/filters/date_modify.rst deleted file mode 100644 index add40b56b..000000000 --- a/vendor/twig/twig/doc/filters/date_modify.rst +++ /dev/null @@ -1,23 +0,0 @@ -``date_modify`` -=============== - -.. versionadded:: 1.9.0 - The date_modify filter has been added in Twig 1.9.0. - -The ``date_modify`` filter modifies a date with a given modifier string: - -.. code-block:: jinja - - {{ post.published_at|date_modify("+1 day")|date("m/d/Y") }} - -The ``date_modify`` filter accepts strings (it must be in a format supported -by the `strtotime`_ function) or `DateTime`_ instances. You can easily combine -it with the :doc:`date` filter for formatting. - -Arguments ---------- - -* ``modifier``: The modifier - -.. _`strtotime`: http://www.php.net/strtotime -.. _`DateTime`: http://www.php.net/DateTime diff --git a/vendor/twig/twig/doc/filters/default.rst b/vendor/twig/twig/doc/filters/default.rst deleted file mode 100644 index 641ac6e75..000000000 --- a/vendor/twig/twig/doc/filters/default.rst +++ /dev/null @@ -1,33 +0,0 @@ -``default`` -=========== - -The ``default`` filter returns the passed default value if the value is -undefined or empty, otherwise the value of the variable: - -.. code-block:: jinja - - {{ var|default('var is not defined') }} - - {{ var.foo|default('foo item on var is not defined') }} - - {{ var['foo']|default('foo item on var is not defined') }} - - {{ ''|default('passed var is empty') }} - -When using the ``default`` filter on an expression that uses variables in some -method calls, be sure to use the ``default`` filter whenever a variable can be -undefined: - -.. code-block:: jinja - - {{ var.method(foo|default('foo'))|default('foo') }} - -.. note:: - - Read the documentation for the :doc:`defined<../tests/defined>` and - :doc:`empty<../tests/empty>` tests to learn more about their semantics. - -Arguments ---------- - -* ``default``: The default value diff --git a/vendor/twig/twig/doc/filters/escape.rst b/vendor/twig/twig/doc/filters/escape.rst deleted file mode 100644 index fc9771acd..000000000 --- a/vendor/twig/twig/doc/filters/escape.rst +++ /dev/null @@ -1,116 +0,0 @@ -``escape`` -========== - -.. versionadded:: 1.9.0 - The ``css``, ``url``, and ``html_attr`` strategies were added in Twig - 1.9.0. - -.. versionadded:: 1.14.0 - The ability to define custom escapers was added in Twig 1.14.0. - -The ``escape`` filter escapes a string for safe insertion into the final -output. It supports different escaping strategies depending on the template -context. - -By default, it uses the HTML escaping strategy: - -.. code-block:: jinja - - {{ user.username|escape }} - -For convenience, the ``e`` filter is defined as an alias: - -.. code-block:: jinja - - {{ user.username|e }} - -The ``escape`` filter can also be used in other contexts than HTML thanks to -an optional argument which defines the escaping strategy to use: - -.. code-block:: jinja - - {{ user.username|e }} - {# is equivalent to #} - {{ user.username|e('html') }} - -And here is how to escape variables included in JavaScript code: - -.. code-block:: jinja - - {{ user.username|escape('js') }} - {{ user.username|e('js') }} - -The ``escape`` filter supports the following escaping strategies: - -* ``html``: escapes a string for the **HTML body** context. - -* ``js``: escapes a string for the **JavaScript context**. - -* ``css``: escapes a string for the **CSS context**. CSS escaping can be - applied to any string being inserted into CSS and escapes everything except - alphanumerics. - -* ``url``: escapes a string for the **URI or parameter contexts**. This should - not be used to escape an entire URI; only a subcomponent being inserted. - -* ``html_attr``: escapes a string for the **HTML attribute** context. - -.. note:: - - Internally, ``escape`` uses the PHP native `htmlspecialchars`_ function - for the HTML escaping strategy. - -.. caution:: - - When using automatic escaping, Twig tries to not double-escape a variable - when the automatic escaping strategy is the same as the one applied by the - escape filter; but that does not work when using a variable as the - escaping strategy: - - .. code-block:: jinja - - {% set strategy = 'html' %} - - {% autoescape 'html' %} - {{ var|escape('html') }} {# won't be double-escaped #} - {{ var|escape(strategy) }} {# will be double-escaped #} - {% endautoescape %} - - When using a variable as the escaping strategy, you should disable - automatic escaping: - - .. code-block:: jinja - - {% set strategy = 'html' %} - - {% autoescape 'html' %} - {{ var|escape(strategy)|raw }} {# won't be double-escaped #} - {% endautoescape %} - -Custom Escapers ---------------- - -You can define custom escapers by calling the ``setEscaper()`` method on the -``core`` extension instance. The first argument is the escaper name (to be -used in the ``escape`` call) and the second one must be a valid PHP callable: - -.. code-block:: php - - $twig = new Twig_Environment($loader); - $twig->getExtension('core')->setEscaper('csv', 'csv_escaper')); - -When called by Twig, the callable receives the Twig environment instance, the -string to escape, and the charset. - -.. note:: - - Built-in escapers cannot be overridden mainly they should be considered as - the final implementation and also for better performance. - -Arguments ---------- - -* ``strategy``: The escaping strategy -* ``charset``: The string charset - -.. _`htmlspecialchars`: http://php.net/htmlspecialchars diff --git a/vendor/twig/twig/doc/filters/first.rst b/vendor/twig/twig/doc/filters/first.rst deleted file mode 100644 index 674c1f9ed..000000000 --- a/vendor/twig/twig/doc/filters/first.rst +++ /dev/null @@ -1,25 +0,0 @@ -``first`` -========= - -.. versionadded:: 1.12.2 - The ``first`` filter was added in Twig 1.12.2. - -The ``first`` filter returns the first "element" of a sequence, a mapping, or -a string: - -.. code-block:: jinja - - {{ [1, 2, 3, 4]|first }} - {# outputs 1 #} - - {{ { a: 1, b: 2, c: 3, d: 4 }|first }} - {# outputs 1 #} - - {{ '1234'|first }} - {# outputs 1 #} - -.. note:: - - It also works with objects implementing the `Traversable`_ interface. - -.. _`Traversable`: http://php.net/manual/en/class.traversable.php diff --git a/vendor/twig/twig/doc/filters/format.rst b/vendor/twig/twig/doc/filters/format.rst deleted file mode 100644 index f8effd9a9..000000000 --- a/vendor/twig/twig/doc/filters/format.rst +++ /dev/null @@ -1,16 +0,0 @@ -``format`` -========== - -The ``format`` filter formats a given string by replacing the placeholders -(placeholders follows the `sprintf`_ notation): - -.. code-block:: jinja - - {{ "I like %s and %s."|format(foo, "bar") }} - - {# outputs I like foo and bar - if the foo parameter equals to the foo string. #} - -.. _`sprintf`: http://www.php.net/sprintf - -.. seealso:: :doc:`replace` diff --git a/vendor/twig/twig/doc/filters/index.rst b/vendor/twig/twig/doc/filters/index.rst deleted file mode 100644 index 8daa96118..000000000 --- a/vendor/twig/twig/doc/filters/index.rst +++ /dev/null @@ -1,37 +0,0 @@ -Filters -======= - -.. toctree:: - :maxdepth: 1 - - abs - batch - capitalize - convert_encoding - date - date_modify - default - escape - first - format - join - json_encode - keys - last - length - lower - merge - nl2br - number_format - raw - replace - reverse - round - slice - sort - split - striptags - title - trim - upper - url_encode diff --git a/vendor/twig/twig/doc/filters/join.rst b/vendor/twig/twig/doc/filters/join.rst deleted file mode 100644 index 2fab94528..000000000 --- a/vendor/twig/twig/doc/filters/join.rst +++ /dev/null @@ -1,23 +0,0 @@ -``join`` -======== - -The ``join`` filter returns a string which is the concatenation of the items -of a sequence: - -.. code-block:: jinja - - {{ [1, 2, 3]|join }} - {# returns 123 #} - -The separator between elements is an empty string per default, but you can -define it with the optional first parameter: - -.. code-block:: jinja - - {{ [1, 2, 3]|join('|') }} - {# outputs 1|2|3 #} - -Arguments ---------- - -* ``glue``: The separator diff --git a/vendor/twig/twig/doc/filters/json_encode.rst b/vendor/twig/twig/doc/filters/json_encode.rst deleted file mode 100644 index a39bb476e..000000000 --- a/vendor/twig/twig/doc/filters/json_encode.rst +++ /dev/null @@ -1,21 +0,0 @@ -``json_encode`` -=============== - -The ``json_encode`` filter returns the JSON representation of a value: - -.. code-block:: jinja - - {{ data|json_encode() }} - -.. note:: - - Internally, Twig uses the PHP `json_encode`_ function. - -Arguments ---------- - -* ``options``: A bitmask of `json_encode options`_ (``{{ - data|json_encode(constant('JSON_PRETTY_PRINT')) }}``) - -.. _`json_encode`: http://php.net/json_encode -.. _`json_encode options`: http://www.php.net/manual/en/json.constants.php diff --git a/vendor/twig/twig/doc/filters/keys.rst b/vendor/twig/twig/doc/filters/keys.rst deleted file mode 100644 index e4f090c6b..000000000 --- a/vendor/twig/twig/doc/filters/keys.rst +++ /dev/null @@ -1,11 +0,0 @@ -``keys`` -======== - -The ``keys`` filter returns the keys of an array. It is useful when you want to -iterate over the keys of an array: - -.. code-block:: jinja - - {% for key in array|keys %} - ... - {% endfor %} diff --git a/vendor/twig/twig/doc/filters/last.rst b/vendor/twig/twig/doc/filters/last.rst deleted file mode 100644 index 345b6573d..000000000 --- a/vendor/twig/twig/doc/filters/last.rst +++ /dev/null @@ -1,25 +0,0 @@ -``last`` -======== - -.. versionadded:: 1.12.2 - The ``last`` filter was added in Twig 1.12.2. - -The ``last`` filter returns the last "element" of a sequence, a mapping, or -a string: - -.. code-block:: jinja - - {{ [1, 2, 3, 4]|last }} - {# outputs 4 #} - - {{ { a: 1, b: 2, c: 3, d: 4 }|last }} - {# outputs 4 #} - - {{ '1234'|last }} - {# outputs 4 #} - -.. note:: - - It also works with objects implementing the `Traversable`_ interface. - -.. _`Traversable`: http://php.net/manual/en/class.traversable.php diff --git a/vendor/twig/twig/doc/filters/length.rst b/vendor/twig/twig/doc/filters/length.rst deleted file mode 100644 index 1f783b3dd..000000000 --- a/vendor/twig/twig/doc/filters/length.rst +++ /dev/null @@ -1,11 +0,0 @@ -``length`` -========== - -The ``length`` filter returns the number of items of a sequence or mapping, or -the length of a string: - -.. code-block:: jinja - - {% if users|length > 10 %} - ... - {% endif %} diff --git a/vendor/twig/twig/doc/filters/lower.rst b/vendor/twig/twig/doc/filters/lower.rst deleted file mode 100644 index ef9faa90a..000000000 --- a/vendor/twig/twig/doc/filters/lower.rst +++ /dev/null @@ -1,10 +0,0 @@ -``lower`` -========= - -The ``lower`` filter converts a value to lowercase: - -.. code-block:: jinja - - {{ 'WELCOME'|lower }} - - {# outputs 'welcome' #} diff --git a/vendor/twig/twig/doc/filters/merge.rst b/vendor/twig/twig/doc/filters/merge.rst deleted file mode 100644 index 88780dd6f..000000000 --- a/vendor/twig/twig/doc/filters/merge.rst +++ /dev/null @@ -1,48 +0,0 @@ -``merge`` -========= - -The ``merge`` filter merges an array with another array: - -.. code-block:: jinja - - {% set values = [1, 2] %} - - {% set values = values|merge(['apple', 'orange']) %} - - {# values now contains [1, 2, 'apple', 'orange'] #} - -New values are added at the end of the existing ones. - -The ``merge`` filter also works on hashes: - -.. code-block:: jinja - - {% set items = { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'unknown' } %} - - {% set items = items|merge({ 'peugeot': 'car', 'renault': 'car' }) %} - - {# items now contains { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'car', 'renault': 'car' } #} - -For hashes, the merging process occurs on the keys: if the key does not -already exist, it is added but if the key already exists, its value is -overridden. - -.. tip:: - - If you want to ensure that some values are defined in an array (by given - default values), reverse the two elements in the call: - - .. code-block:: jinja - - {% set items = { 'apple': 'fruit', 'orange': 'fruit' } %} - - {% set items = { 'apple': 'unknown' }|merge(items) %} - - {# items now contains { 'apple': 'fruit', 'orange': 'fruit' } #} - -.. note:: - - Internally, Twig uses the PHP `array_merge`_ function. It supports - Traversable objects by transforming those to arrays. - -.. _`array_merge`: http://php.net/array_merge diff --git a/vendor/twig/twig/doc/filters/nl2br.rst b/vendor/twig/twig/doc/filters/nl2br.rst deleted file mode 100644 index 5c923e143..000000000 --- a/vendor/twig/twig/doc/filters/nl2br.rst +++ /dev/null @@ -1,22 +0,0 @@ -``nl2br`` -========= - -.. versionadded:: 1.5 - The ``nl2br`` filter was added in Twig 1.5. - -The ``nl2br`` filter inserts HTML line breaks before all newlines in a string: - -.. code-block:: jinja - - {{ "I like Twig.\nYou will like it too."|nl2br }} - {# outputs - - I like Twig.
    - You will like it too. - - #} - -.. note:: - - The ``nl2br`` filter pre-escapes the input before applying the - transformation. diff --git a/vendor/twig/twig/doc/filters/number_format.rst b/vendor/twig/twig/doc/filters/number_format.rst deleted file mode 100644 index 3114e8451..000000000 --- a/vendor/twig/twig/doc/filters/number_format.rst +++ /dev/null @@ -1,45 +0,0 @@ -``number_format`` -================= - -.. versionadded:: 1.5 - The ``number_format`` filter was added in Twig 1.5 - -The ``number_format`` filter formats numbers. It is a wrapper around PHP's -`number_format`_ function: - -.. code-block:: jinja - - {{ 200.35|number_format }} - -You can control the number of decimal places, decimal point, and thousands -separator using the additional arguments: - -.. code-block:: jinja - - {{ 9800.333|number_format(2, '.', ',') }} - -If no formatting options are provided then Twig will use the default formatting -options of: - -* 0 decimal places. -* ``.`` as the decimal point. -* ``,`` as the thousands separator. - -These defaults can be easily changed through the core extension: - -.. code-block:: php - - $twig = new Twig_Environment($loader); - $twig->getExtension('core')->setNumberFormat(3, '.', ','); - -The defaults set for ``number_format`` can be over-ridden upon each call using the -additional parameters. - -Arguments ---------- - -* ``decimal``: The number of decimal points to display -* ``decimal_point``: The character(s) to use for the decimal point -* ``thousand_sep``: The character(s) to use for the thousands separator - -.. _`number_format`: http://php.net/number_format diff --git a/vendor/twig/twig/doc/filters/raw.rst b/vendor/twig/twig/doc/filters/raw.rst deleted file mode 100644 index e5e5b12ec..000000000 --- a/vendor/twig/twig/doc/filters/raw.rst +++ /dev/null @@ -1,36 +0,0 @@ -``raw`` -======= - -The ``raw`` filter marks the value as being "safe", which means that in an -environment with automatic escaping enabled this variable will not be escaped -if ``raw`` is the last filter applied to it: - -.. code-block:: jinja - - {% autoescape %} - {{ var|raw }} {# var won't be escaped #} - {% endautoescape %} - -.. note:: - - Be careful when using the ``raw`` filter inside expressions: - - .. code-block:: jinja - - {% autoescape %} - {% set hello = 'Hello' %} - {% set hola = 'Hola' %} - - {{ false ? 'Hola' : hello|raw }} - does not render the same as - {{ false ? hola : hello|raw }} - but renders the same as - {{ (false ? hola : hello)|raw }} - {% endautoescape %} - - The first ternary statement is not escaped: ``hello`` is marked as being - safe and Twig does not escape static values (see - :doc:`escape<../tags/autoescape>`). In the second ternary statement, even - if ``hello`` is marked as safe, ``hola`` remains unsafe and so is the whole - expression. The third ternary statement is marked as safe and the result is - not escaped. diff --git a/vendor/twig/twig/doc/filters/replace.rst b/vendor/twig/twig/doc/filters/replace.rst deleted file mode 100644 index 1227957b9..000000000 --- a/vendor/twig/twig/doc/filters/replace.rst +++ /dev/null @@ -1,19 +0,0 @@ -``replace`` -=========== - -The ``replace`` filter formats a given string by replacing the placeholders -(placeholders are free-form): - -.. code-block:: jinja - - {{ "I like %this% and %that%."|replace({'%this%': foo, '%that%': "bar"}) }} - - {# outputs I like foo and bar - if the foo parameter equals to the foo string. #} - -Arguments ---------- - -* ``replace_pairs``: The placeholder values - -.. seealso:: :doc:`format` diff --git a/vendor/twig/twig/doc/filters/reverse.rst b/vendor/twig/twig/doc/filters/reverse.rst deleted file mode 100644 index 76fd2c1ab..000000000 --- a/vendor/twig/twig/doc/filters/reverse.rst +++ /dev/null @@ -1,47 +0,0 @@ -``reverse`` -=========== - -.. versionadded:: 1.6 - Support for strings has been added in Twig 1.6. - -The ``reverse`` filter reverses a sequence, a mapping, or a string: - -.. code-block:: jinja - - {% for user in users|reverse %} - ... - {% endfor %} - - {{ '1234'|reverse }} - - {# outputs 4321 #} - -.. tip:: - - For sequences and mappings, numeric keys are not preserved. To reverse - them as well, pass ``true`` as an argument to the ``reverse`` filter: - - .. code-block:: jinja - - {% for key, value in {1: "a", 2: "b", 3: "c"}|reverse %} - {{ key }}: {{ value }} - {%- endfor %} - - {# output: 0: c 1: b 2: a #} - - {% for key, value in {1: "a", 2: "b", 3: "c"}|reverse(true) %} - {{ key }}: {{ value }} - {%- endfor %} - - {# output: 3: c 2: b 1: a #} - -.. note:: - - It also works with objects implementing the `Traversable`_ interface. - -Arguments ---------- - -* ``preserve_keys``: Preserve keys when reversing a mapping or a sequence. - -.. _`Traversable`: http://php.net/Traversable diff --git a/vendor/twig/twig/doc/filters/round.rst b/vendor/twig/twig/doc/filters/round.rst deleted file mode 100644 index 2521cf16a..000000000 --- a/vendor/twig/twig/doc/filters/round.rst +++ /dev/null @@ -1,37 +0,0 @@ -``round`` -========= - -.. versionadded:: 1.15.0 - The ``round`` filter was added in Twig 1.15.0. - -The ``round`` filter rounds a number to a given precision: - -.. code-block:: jinja - - {{ 42.55|round }} - {# outputs 43 #} - - {{ 42.55|round(1, 'floor') }} - {# outputs 42.5 #} - -The ``round`` filter takes two optional arguments; the first one specifies the -precision (default is ``0``) and the second the rounding method (default is -``common``): - -* ``common`` rounds either up or down (rounds the value up to precision decimal - places away from zero, when it is half way there -- making 1.5 into 2 and - -1.5 into -2); - -* ``ceil`` always rounds up; - -* ``floor`` always rounds down. - -.. note:: - - The ``//`` operator is equivalent to ``|round(0, 'floor')``. - -Arguments ---------- - -* ``precision``: The rounding precision -* ``method``: The rounding method diff --git a/vendor/twig/twig/doc/filters/slice.rst b/vendor/twig/twig/doc/filters/slice.rst deleted file mode 100644 index 70bf139e6..000000000 --- a/vendor/twig/twig/doc/filters/slice.rst +++ /dev/null @@ -1,71 +0,0 @@ -``slice`` -=========== - -.. versionadded:: 1.6 - The ``slice`` filter was added in Twig 1.6. - -The ``slice`` filter extracts a slice of a sequence, a mapping, or a string: - -.. code-block:: jinja - - {% for i in [1, 2, 3, 4, 5]|slice(1, 2) %} - {# will iterate over 2 and 3 #} - {% endfor %} - - {{ '12345'|slice(1, 2) }} - - {# outputs 23 #} - -You can use any valid expression for both the start and the length: - -.. code-block:: jinja - - {% for i in [1, 2, 3, 4, 5]|slice(start, length) %} - {# ... #} - {% endfor %} - -As syntactic sugar, you can also use the ``[]`` notation: - -.. code-block:: jinja - - {% for i in [1, 2, 3, 4, 5][start:length] %} - {# ... #} - {% endfor %} - - {{ '12345'[1:2] }} {# will display "23" #} - - {# you can omit the first argument -- which is the same as 0 #} - {{ '12345'[:2] }} {# will display "12" #} - - {# you can omit the last argument -- which will select everything till the end #} - {{ '12345'[2:] }} {# will display "345" #} - -The ``slice`` filter works as the `array_slice`_ PHP function for arrays and -`mb_substr`_ for strings with a fallback to `substr`_. - -If the start is non-negative, the sequence will start at that start in the -variable. If start is negative, the sequence will start that far from the end -of the variable. - -If length is given and is positive, then the sequence will have up to that -many elements in it. If the variable is shorter than the length, then only the -available variable elements will be present. If length is given and is -negative then the sequence will stop that many elements from the end of the -variable. If it is omitted, then the sequence will have everything from offset -up until the end of the variable. - -.. note:: - - It also works with objects implementing the `Traversable`_ interface. - -Arguments ---------- - -* ``start``: The start of the slice -* ``length``: The size of the slice -* ``preserve_keys``: Whether to preserve key or not (when the input is an array) - -.. _`Traversable`: http://php.net/manual/en/class.traversable.php -.. _`array_slice`: http://php.net/array_slice -.. _`mb_substr` : http://php.net/mb-substr -.. _`substr`: http://php.net/substr diff --git a/vendor/twig/twig/doc/filters/sort.rst b/vendor/twig/twig/doc/filters/sort.rst deleted file mode 100644 index 350207f8e..000000000 --- a/vendor/twig/twig/doc/filters/sort.rst +++ /dev/null @@ -1,18 +0,0 @@ -``sort`` -======== - -The ``sort`` filter sorts an array: - -.. code-block:: jinja - - {% for user in users|sort %} - ... - {% endfor %} - -.. note:: - - Internally, Twig uses the PHP `asort`_ function to maintain index - association. It supports Traversable objects by transforming - those to arrays. - -.. _`asort`: http://php.net/asort diff --git a/vendor/twig/twig/doc/filters/split.rst b/vendor/twig/twig/doc/filters/split.rst deleted file mode 100644 index bbc6d798f..000000000 --- a/vendor/twig/twig/doc/filters/split.rst +++ /dev/null @@ -1,53 +0,0 @@ -``split`` -========= - -.. versionadded:: 1.10.3 - The ``split`` filter was added in Twig 1.10.3. - -The ``split`` filter splits a string by the given delimiter and returns a list -of strings: - -.. code-block:: jinja - - {% set foo = "one,two,three"|split(',') %} - {# foo contains ['one', 'two', 'three'] #} - -You can also pass a ``limit`` argument: - - * If ``limit`` is positive, the returned array will contain a maximum of - limit elements with the last element containing the rest of string; - - * If ``limit`` is negative, all components except the last -limit are - returned; - - * If ``limit`` is zero, then this is treated as 1. - -.. code-block:: jinja - - {% set foo = "one,two,three,four,five"|split(',', 3) %} - {# foo contains ['one', 'two', 'three,four,five'] #} - -If the ``delimiter`` is an empty string, then value will be split by equal -chunks. Length is set by the ``limit`` argument (one character by default). - -.. code-block:: jinja - - {% set foo = "123"|split('') %} - {# foo contains ['1', '2', '3'] #} - - {% set bar = "aabbcc"|split('', 2) %} - {# bar contains ['aa', 'bb', 'cc'] #} - -.. note:: - - Internally, Twig uses the PHP `explode`_ or `str_split`_ (if delimiter is - empty) functions for string splitting. - -Arguments ---------- - -* ``delimiter``: The delimiter -* ``limit``: The limit argument - -.. _`explode`: http://php.net/explode -.. _`str_split`: http://php.net/str_split diff --git a/vendor/twig/twig/doc/filters/striptags.rst b/vendor/twig/twig/doc/filters/striptags.rst deleted file mode 100644 index 72c6f252f..000000000 --- a/vendor/twig/twig/doc/filters/striptags.rst +++ /dev/null @@ -1,15 +0,0 @@ -``striptags`` -============= - -The ``striptags`` filter strips SGML/XML tags and replace adjacent whitespace -by one space: - -.. code-block:: jinja - - {{ some_html|striptags }} - -.. note:: - - Internally, Twig uses the PHP `strip_tags`_ function. - -.. _`strip_tags`: http://php.net/strip_tags diff --git a/vendor/twig/twig/doc/filters/title.rst b/vendor/twig/twig/doc/filters/title.rst deleted file mode 100644 index c5a318e85..000000000 --- a/vendor/twig/twig/doc/filters/title.rst +++ /dev/null @@ -1,11 +0,0 @@ -``title`` -========= - -The ``title`` filter returns a titlecased version of the value. Words will -start with uppercase letters, all remaining characters are lowercase: - -.. code-block:: jinja - - {{ 'my first car'|title }} - - {# outputs 'My First Car' #} diff --git a/vendor/twig/twig/doc/filters/trim.rst b/vendor/twig/twig/doc/filters/trim.rst deleted file mode 100644 index 4ddb2083b..000000000 --- a/vendor/twig/twig/doc/filters/trim.rst +++ /dev/null @@ -1,29 +0,0 @@ -``trim`` -======== - -.. versionadded:: 1.6.2 - The ``trim`` filter was added in Twig 1.6.2. - -The ``trim`` filter strips whitespace (or other characters) from the beginning -and end of a string: - -.. code-block:: jinja - - {{ ' I like Twig. '|trim }} - - {# outputs 'I like Twig.' #} - - {{ ' I like Twig.'|trim('.') }} - - {# outputs ' I like Twig' #} - -.. note:: - - Internally, Twig uses the PHP `trim`_ function. - -Arguments ---------- - -* ``character_mask``: The characters to strip - -.. _`trim`: http://php.net/trim diff --git a/vendor/twig/twig/doc/filters/upper.rst b/vendor/twig/twig/doc/filters/upper.rst deleted file mode 100644 index 561cebe33..000000000 --- a/vendor/twig/twig/doc/filters/upper.rst +++ /dev/null @@ -1,10 +0,0 @@ -``upper`` -========= - -The ``upper`` filter converts a value to uppercase: - -.. code-block:: jinja - - {{ 'welcome'|upper }} - - {# outputs 'WELCOME' #} diff --git a/vendor/twig/twig/doc/filters/url_encode.rst b/vendor/twig/twig/doc/filters/url_encode.rst deleted file mode 100644 index 5944e59cd..000000000 --- a/vendor/twig/twig/doc/filters/url_encode.rst +++ /dev/null @@ -1,34 +0,0 @@ -``url_encode`` -============== - -.. versionadded:: 1.12.3 - Support for encoding an array as query string was added in Twig 1.12.3. - -.. versionadded:: 1.16.0 - The ``raw`` argument was removed in Twig 1.16.0. Twig now always encodes - according to RFC 3986. - -The ``url_encode`` filter percent encodes a given string as URL segment -or an array as query string: - -.. code-block:: jinja - - {{ "path-seg*ment"|url_encode }} - {# outputs "path-seg%2Ament" #} - - {{ "string with spaces"|url_encode }} - {# outputs "string%20with%20spaces" #} - - {{ {'param': 'value', 'foo': 'bar'}|url_encode }} - {# outputs "param=value&foo=bar" #} - -.. note:: - - Internally, Twig uses the PHP `urlencode`_ (or `rawurlencode`_ if you pass - ``true`` as the first parameter) or the `http_build_query`_ function. Note - that as of Twig 1.16.0, ``urlencode`` **always** uses ``rawurlencode`` (the - ``raw`` argument was removed.) - -.. _`urlencode`: http://php.net/urlencode -.. _`rawurlencode`: http://php.net/rawurlencode -.. _`http_build_query`: http://php.net/http_build_query diff --git a/vendor/twig/twig/doc/functions/attribute.rst b/vendor/twig/twig/doc/functions/attribute.rst deleted file mode 100644 index ceba96b05..000000000 --- a/vendor/twig/twig/doc/functions/attribute.rst +++ /dev/null @@ -1,26 +0,0 @@ -``attribute`` -============= - -.. versionadded:: 1.2 - The ``attribute`` function was added in Twig 1.2. - -The ``attribute`` function can be used to access a "dynamic" attribute of a -variable: - -.. code-block:: jinja - - {{ attribute(object, method) }} - {{ attribute(object, method, arguments) }} - {{ attribute(array, item) }} - -In addition, the ``defined`` test can check for the existence of a dynamic -attribute: - -.. code-block:: jinja - - {{ attribute(object, method) is defined ? 'Method exists' : 'Method does not exist' }} - -.. note:: - - The resolution algorithm is the same as the one used for the ``.`` - notation, except that the item can be any valid expression. diff --git a/vendor/twig/twig/doc/functions/block.rst b/vendor/twig/twig/doc/functions/block.rst deleted file mode 100644 index fd571efbc..000000000 --- a/vendor/twig/twig/doc/functions/block.rst +++ /dev/null @@ -1,15 +0,0 @@ -``block`` -========= - -When a template uses inheritance and if you want to print a block multiple -times, use the ``block`` function: - -.. code-block:: jinja - - {% block title %}{% endblock %} - -

    {{ block('title') }}

    - - {% block body %}{% endblock %} - -.. seealso:: :doc:`extends<../tags/extends>`, :doc:`parent<../functions/parent>` diff --git a/vendor/twig/twig/doc/functions/constant.rst b/vendor/twig/twig/doc/functions/constant.rst deleted file mode 100644 index bea0e9fc0..000000000 --- a/vendor/twig/twig/doc/functions/constant.rst +++ /dev/null @@ -1,18 +0,0 @@ -``constant`` -============ - -.. versionadded: 1.12.1 - constant now accepts object instances as the second argument. - -``constant`` returns the constant value for a given string: - -.. code-block:: jinja - - {{ some_date|date(constant('DATE_W3C')) }} - {{ constant('Namespace\\Classname::CONSTANT_NAME') }} - -As of 1.12.1 you can read constants from object instances as well: - -.. code-block:: jinja - - {{ constant('RSS', date) }} diff --git a/vendor/twig/twig/doc/functions/cycle.rst b/vendor/twig/twig/doc/functions/cycle.rst deleted file mode 100644 index e34349323..000000000 --- a/vendor/twig/twig/doc/functions/cycle.rst +++ /dev/null @@ -1,28 +0,0 @@ -``cycle`` -========= - -The ``cycle`` function cycles on an array of values: - -.. code-block:: jinja - - {% set start_year = date() | date('Y') %} - {% set end_year = start_year + 5 %} - - {% for year in start_year..end_year %} - {{ cycle(['odd', 'even'], loop.index0) }} - {% endfor %} - -The array can contain any number of values: - -.. code-block:: jinja - - {% set fruits = ['apple', 'orange', 'citrus'] %} - - {% for i in 0..10 %} - {{ cycle(fruits, i) }} - {% endfor %} - -Arguments ---------- - -* ``position``: The cycle position diff --git a/vendor/twig/twig/doc/functions/date.rst b/vendor/twig/twig/doc/functions/date.rst deleted file mode 100644 index 714e08c47..000000000 --- a/vendor/twig/twig/doc/functions/date.rst +++ /dev/null @@ -1,52 +0,0 @@ -``date`` -======== - -.. versionadded:: 1.6 - The date function has been added in Twig 1.6. - -.. versionadded:: 1.6.1 - The default timezone support has been added in Twig 1.6.1. - -Converts an argument to a date to allow date comparison: - -.. code-block:: jinja - - {% if date(user.created_at) < date('-2days') %} - {# do something #} - {% endif %} - -The argument must be in one of PHP’s supported `date and time formats`_. - -You can pass a timezone as the second argument: - -.. code-block:: jinja - - {% if date(user.created_at) < date('-2days', 'Europe/Paris') %} - {# do something #} - {% endif %} - -If no argument is passed, the function returns the current date: - -.. code-block:: jinja - - {% if date(user.created_at) < date() %} - {# always! #} - {% endif %} - -.. note:: - - You can set the default timezone globally by calling ``setTimezone()`` on - the ``core`` extension instance: - - .. code-block:: php - - $twig = new Twig_Environment($loader); - $twig->getExtension('core')->setTimezone('Europe/Paris'); - -Arguments ---------- - -* ``date``: The date -* ``timezone``: The timezone - -.. _`date and time formats`: http://php.net/manual/en/datetime.formats.php diff --git a/vendor/twig/twig/doc/functions/dump.rst b/vendor/twig/twig/doc/functions/dump.rst deleted file mode 100644 index a231f089e..000000000 --- a/vendor/twig/twig/doc/functions/dump.rst +++ /dev/null @@ -1,69 +0,0 @@ -``dump`` -======== - -.. versionadded:: 1.5 - The ``dump`` function was added in Twig 1.5. - -The ``dump`` function dumps information about a template variable. This is -mostly useful to debug a template that does not behave as expected by -introspecting its variables: - -.. code-block:: jinja - - {{ dump(user) }} - -.. note:: - - The ``dump`` function is not available by default. You must add the - ``Twig_Extension_Debug`` extension explicitly when creating your Twig - environment:: - - $twig = new Twig_Environment($loader, array( - 'debug' => true, - // ... - )); - $twig->addExtension(new Twig_Extension_Debug()); - - Even when enabled, the ``dump`` function won't display anything if the - ``debug`` option on the environment is not enabled (to avoid leaking debug - information on a production server). - -In an HTML context, wrap the output with a ``pre`` tag to make it easier to -read: - -.. code-block:: jinja - -
    -        {{ dump(user) }}
    -    
    - -.. tip:: - - Using a ``pre`` tag is not needed when `XDebug`_ is enabled and - ``html_errors`` is ``on``; as a bonus, the output is also nicer with - XDebug enabled. - -You can debug several variables by passing them as additional arguments: - -.. code-block:: jinja - - {{ dump(user, categories) }} - -If you don't pass any value, all variables from the current context are -dumped: - -.. code-block:: jinja - - {{ dump() }} - -.. note:: - - Internally, Twig uses the PHP `var_dump`_ function. - -Arguments ---------- - -* ``context``: The context to dump - -.. _`XDebug`: http://xdebug.org/docs/display -.. _`var_dump`: http://php.net/var_dump diff --git a/vendor/twig/twig/doc/functions/include.rst b/vendor/twig/twig/doc/functions/include.rst deleted file mode 100644 index 33bd56d11..000000000 --- a/vendor/twig/twig/doc/functions/include.rst +++ /dev/null @@ -1,80 +0,0 @@ -``include`` -=========== - -.. versionadded:: 1.12 - The ``include`` function was added in Twig 1.12. - -The ``include`` function returns the rendered content of a template: - -.. code-block:: jinja - - {{ include('template.html') }} - {{ include(some_var) }} - -Included templates have access to the variables of the active context. - -If you are using the filesystem loader, the templates are looked for in the -paths defined by it. - -The context is passed by default to the template but you can also pass -additional variables: - -.. code-block:: jinja - - {# template.html will have access to the variables from the current context and the additional ones provided #} - {{ include('template.html', {foo: 'bar'}) }} - -You can disable access to the context by setting ``with_context`` to -``false``: - -.. code-block:: jinja - - {# only the foo variable will be accessible #} - {{ include('template.html', {foo: 'bar'}, with_context = false) }} - -.. code-block:: jinja - - {# no variables will be accessible #} - {{ include('template.html', with_context = false) }} - -And if the expression evaluates to a ``Twig_Template`` object, Twig will use it -directly:: - - // {{ include(template) }} - - $template = $twig->loadTemplate('some_template.twig'); - - $twig->loadTemplate('template.twig')->display(array('template' => $template)); - -When you set the ``ignore_missing`` flag, Twig will return an empty string if -the template does not exist: - -.. code-block:: jinja - - {{ include('sidebar.html', ignore_missing = true) }} - -You can also provide a list of templates that are checked for existence before -inclusion. The first template that exists will be rendered: - -.. code-block:: jinja - - {{ include(['page_detailed.html', 'page.html']) }} - -If ``ignore_missing`` is set, it will fall back to rendering nothing if none -of the templates exist, otherwise it will throw an exception. - -When including a template created by an end user, you should consider -sandboxing it: - -.. code-block:: jinja - - {{ include('page.html', sandboxed = true) }} - -Arguments ---------- - -* ``template``: The template to render -* ``variables``: The variables to pass to the template -* ``with_context``: Whether to pass the current context variables or not -* ``ignore_missing``: Whether to ignore missing templates or not -* ``sandboxed``: Whether to sandbox the template or not diff --git a/vendor/twig/twig/doc/functions/index.rst b/vendor/twig/twig/doc/functions/index.rst deleted file mode 100644 index 07214a76c..000000000 --- a/vendor/twig/twig/doc/functions/index.rst +++ /dev/null @@ -1,20 +0,0 @@ -Functions -========= - -.. toctree:: - :maxdepth: 1 - - attribute - block - constant - cycle - date - dump - include - max - min - parent - random - range - source - template_from_string diff --git a/vendor/twig/twig/doc/functions/max.rst b/vendor/twig/twig/doc/functions/max.rst deleted file mode 100644 index 6f3cfc535..000000000 --- a/vendor/twig/twig/doc/functions/max.rst +++ /dev/null @@ -1,20 +0,0 @@ -``max`` -======= - -.. versionadded:: 1.15 - The ``max`` function was added in Twig 1.15. - -``max`` returns the biggest value of a sequence or a set of values: - -.. code-block:: jinja - - {{ max(1, 3, 2) }} - {{ max([1, 3, 2]) }} - -When called with a mapping, max ignores keys and only compares values: - -.. code-block:: jinja - - {{ max({2: "e", 1: "a", 3: "b", 5: "d", 4: "c"}) }} - {# returns "e" #} - diff --git a/vendor/twig/twig/doc/functions/min.rst b/vendor/twig/twig/doc/functions/min.rst deleted file mode 100644 index 7b6a65e10..000000000 --- a/vendor/twig/twig/doc/functions/min.rst +++ /dev/null @@ -1,20 +0,0 @@ -``min`` -======= - -.. versionadded:: 1.15 - The ``min`` function was added in Twig 1.15. - -``min`` returns the lowest value of a sequence or a set of values: - -.. code-block:: jinja - - {{ min(1, 3, 2) }} - {{ min([1, 3, 2]) }} - -When called with a mapping, min ignores keys and only compares values: - -.. code-block:: jinja - - {{ min({2: "e", 3: "a", 1: "b", 5: "d", 4: "c"}) }} - {# returns "a" #} - diff --git a/vendor/twig/twig/doc/functions/parent.rst b/vendor/twig/twig/doc/functions/parent.rst deleted file mode 100644 index f5bd20010..000000000 --- a/vendor/twig/twig/doc/functions/parent.rst +++ /dev/null @@ -1,20 +0,0 @@ -``parent`` -========== - -When a template uses inheritance, it's possible to render the contents of the -parent block when overriding a block by using the ``parent`` function: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% block sidebar %} -

    Table Of Contents

    - ... - {{ parent() }} - {% endblock %} - -The ``parent()`` call will return the content of the ``sidebar`` block as -defined in the ``base.html`` template. - -.. seealso:: :doc:`extends<../tags/extends>`, :doc:`block<../functions/block>`, :doc:`block<../tags/block>` diff --git a/vendor/twig/twig/doc/functions/random.rst b/vendor/twig/twig/doc/functions/random.rst deleted file mode 100644 index 168e74f8f..000000000 --- a/vendor/twig/twig/doc/functions/random.rst +++ /dev/null @@ -1,29 +0,0 @@ -``random`` -========== - -.. versionadded:: 1.5 - The ``random`` function was added in Twig 1.5. - -.. versionadded:: 1.6 - String and integer handling was added in Twig 1.6. - -The ``random`` function returns a random value depending on the supplied -parameter type: - -* a random item from a sequence; -* a random character from a string; -* a random integer between 0 and the integer parameter (inclusive). - -.. code-block:: jinja - - {{ random(['apple', 'orange', 'citrus']) }} {# example output: orange #} - {{ random('ABC') }} {# example output: C #} - {{ random() }} {# example output: 15386094 (works as the native PHP mt_rand function) #} - {{ random(5) }} {# example output: 3 #} - -Arguments ---------- - -* ``values``: The values - -.. _`mt_rand`: http://php.net/mt_rand diff --git a/vendor/twig/twig/doc/functions/range.rst b/vendor/twig/twig/doc/functions/range.rst deleted file mode 100644 index b7cd01116..000000000 --- a/vendor/twig/twig/doc/functions/range.rst +++ /dev/null @@ -1,45 +0,0 @@ -``range`` -========= - -Returns a list containing an arithmetic progression of integers: - -.. code-block:: jinja - - {% for i in range(0, 3) %} - {{ i }}, - {% endfor %} - - {# outputs 0, 1, 2, 3, #} - -When step is given (as the third parameter), it specifies the increment (or -decrement): - -.. code-block:: jinja - - {% for i in range(0, 6, 2) %} - {{ i }}, - {% endfor %} - - {# outputs 0, 2, 4, 6, #} - -The Twig built-in ``..`` operator is just syntactic sugar for the ``range`` -function (with a step of 1): - -.. code-block:: jinja - - {% for i in 0..3 %} - {{ i }}, - {% endfor %} - -.. tip:: - - The ``range`` function works as the native PHP `range`_ function. - -Arguments ---------- - -* ``low``: The first value of the sequence. -* ``high``: The highest possible value of the sequence. -* ``step``: The increment between elements of the sequence. - -.. _`range`: http://php.net/range diff --git a/vendor/twig/twig/doc/functions/source.rst b/vendor/twig/twig/doc/functions/source.rst deleted file mode 100644 index 3c921b1cf..000000000 --- a/vendor/twig/twig/doc/functions/source.rst +++ /dev/null @@ -1,32 +0,0 @@ -``source`` -========== - -.. versionadded:: 1.15 - The ``source`` function was added in Twig 1.15. - -.. versionadded:: 1.18.3 - The ``ignore_missing`` flag was added in Twig 1.18.3. - -The ``source`` function returns the content of a template without rendering it: - -.. code-block:: jinja - - {{ source('template.html') }} - {{ source(some_var) }} - -When you set the ``ignore_missing`` flag, Twig will return an empty string if -the template does not exist: - -.. code-block:: jinja - - {{ source('template.html', ignore_missing = true) }} - -The function uses the same template loaders as the ones used to include -templates. So, if you are using the filesystem loader, the templates are looked -for in the paths defined by it. - -Arguments ---------- - -* ``name``: The name of the template to read -* ``ignore_missing``: Whether to ignore missing templates or not diff --git a/vendor/twig/twig/doc/functions/template_from_string.rst b/vendor/twig/twig/doc/functions/template_from_string.rst deleted file mode 100644 index ce6a60dc0..000000000 --- a/vendor/twig/twig/doc/functions/template_from_string.rst +++ /dev/null @@ -1,32 +0,0 @@ -``template_from_string`` -======================== - -.. versionadded:: 1.11 - The ``template_from_string`` function was added in Twig 1.11. - -The ``template_from_string`` function loads a template from a string: - -.. code-block:: jinja - - {{ include(template_from_string("Hello {{ name }}")) }} - {{ include(template_from_string(page.template)) }} - -.. note:: - - The ``template_from_string`` function is not available by default. You - must add the ``Twig_Extension_StringLoader`` extension explicitly when - creating your Twig environment:: - - $twig = new Twig_Environment(...); - $twig->addExtension(new Twig_Extension_StringLoader()); - -.. note:: - - Even if you will probably always use the ``template_from_string`` function - with the ``include`` function, you can use it with any tag or function that - takes a template as an argument (like the ``embed`` or ``extends`` tags). - -Arguments ---------- - -* ``template``: The template diff --git a/vendor/twig/twig/doc/index.rst b/vendor/twig/twig/doc/index.rst deleted file mode 100644 index 358bd738e..000000000 --- a/vendor/twig/twig/doc/index.rst +++ /dev/null @@ -1,19 +0,0 @@ -Twig -==== - -.. toctree:: - :maxdepth: 2 - - intro - installation - templates - api - advanced - internals - deprecated - recipes - coding_standards - tags/index - filters/index - functions/index - tests/index diff --git a/vendor/twig/twig/doc/installation.rst b/vendor/twig/twig/doc/installation.rst deleted file mode 100644 index afdcf1659..000000000 --- a/vendor/twig/twig/doc/installation.rst +++ /dev/null @@ -1,116 +0,0 @@ -Installation -============ - -You have multiple ways to install Twig. - -Installing the Twig PHP package -------------------------------- - -Installing via Composer (recommended) -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -Install `Composer`_ and run the following command to get the latest version: - -.. code-block:: bash - - composer require twig/twig:~1.0 - -Installing from the tarball release -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -1. Download the most recent tarball from the `download page`_ -2. Verify the integrity of the tarball http://fabien.potencier.org/article/73/signing-project-releases -3. Unpack the tarball -4. Move the files somewhere in your project - -Installing the development version -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. code-block:: bash - - git clone git://github.com/twigphp/Twig.git - -Installing the PEAR package -~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -.. note:: - - Using PEAR for installing Twig is deprecated and Twig 1.15.1 was the last - version published on the PEAR channel; use Composer instead. - -.. code-block:: bash - - pear channel-discover pear.twig-project.org - pear install twig/Twig - -Installing the C extension --------------------------- - -.. versionadded:: 1.4 - The C extension was added in Twig 1.4. - -.. note:: - - The C extension is **optional** but it brings some nice performance - improvements. Note that the extension is not a replacement for the PHP - code; it only implements a small part of the PHP code to improve the - performance at runtime; you must still install the regular PHP code. - -Twig comes with a C extension that enhances the performance of the Twig -runtime engine; install it like any other PHP extensions: - -.. code-block:: bash - - cd ext/twig - phpize - ./configure - make - make install - -.. note:: - - You can also install the C extension via PEAR (note that this method is - deprecated and newer versions of Twig are not available on the PEAR - channel): - - .. code-block:: bash - - pear channel-discover pear.twig-project.org - pear install twig/CTwig - -For Windows: - -1. Setup the build environment following the `PHP documentation`_ -2. Put Twig's C extension source code into ``C:\php-sdk\phpdev\vcXX\x86\php-source-directory\ext\twig`` -3. Use the ``configure --disable-all --enable-cli --enable-twig=shared`` command instead of step 14 -4. ``nmake`` -5. Copy the ``C:\php-sdk\phpdev\vcXX\x86\php-source-directory\Release_TS\php_twig.dll`` file to your PHP setup. - -.. tip:: - - For Windows ZendServer, ZTS is not enabled as mentioned in `Zend Server - FAQ`_. - - You have to use ``configure --disable-all --disable-zts --enable-cli - --enable-twig=shared`` to be able to build the twig C extension for - ZendServer. - - The built DLL will be available in - ``C:\\php-sdk\\phpdev\\vcXX\\x86\\php-source-directory\\Release`` - -Finally, enable the extension in your ``php.ini`` configuration file: - -.. code-block:: ini - - extension=twig.so #For Unix systems - extension=php_twig.dll #For Windows systems - -And from now on, Twig will automatically compile your templates to take -advantage of the C extension. Note that this extension does not replace the -PHP code but only provides an optimized version of the -``Twig_Template::getAttribute()`` method. - -.. _`download page`: https://github.com/twigphp/Twig/tags -.. _`Composer`: https://getcomposer.org/download/ -.. _`PHP documentation`: https://wiki.php.net/internals/windows/stepbystepbuild -.. _`Zend Server FAQ`: http://www.zend.com/en/products/server/faq#faqD6 diff --git a/vendor/twig/twig/doc/internals.rst b/vendor/twig/twig/doc/internals.rst deleted file mode 100644 index ef1174dd9..000000000 --- a/vendor/twig/twig/doc/internals.rst +++ /dev/null @@ -1,138 +0,0 @@ -Twig Internals -============== - -Twig is very extensible and you can easily hack it. Keep in mind that you -should probably try to create an extension before hacking the core, as most -features and enhancements can be handled with extensions. This chapter is also -useful for people who want to understand how Twig works under the hood. - -How does Twig work? -------------------- - -The rendering of a Twig template can be summarized into four key steps: - -* **Load** the template: If the template is already compiled, load it and go - to the *evaluation* step, otherwise: - - * First, the **lexer** tokenizes the template source code into small pieces - for easier processing; - * Then, the **parser** converts the token stream into a meaningful tree - of nodes (the Abstract Syntax Tree); - * Eventually, the *compiler* transforms the AST into PHP code. - -* **Evaluate** the template: It basically means calling the ``display()`` - method of the compiled template and passing it the context. - -The Lexer ---------- - -The lexer tokenizes a template source code into a token stream (each token is -an instance of ``Twig_Token``, and the stream is an instance of -``Twig_TokenStream``). The default lexer recognizes 13 different token types: - -* ``Twig_Token::BLOCK_START_TYPE``, ``Twig_Token::BLOCK_END_TYPE``: Delimiters for blocks (``{% %}``) -* ``Twig_Token::VAR_START_TYPE``, ``Twig_Token::VAR_END_TYPE``: Delimiters for variables (``{{ }}``) -* ``Twig_Token::TEXT_TYPE``: A text outside an expression; -* ``Twig_Token::NAME_TYPE``: A name in an expression; -* ``Twig_Token::NUMBER_TYPE``: A number in an expression; -* ``Twig_Token::STRING_TYPE``: A string in an expression; -* ``Twig_Token::OPERATOR_TYPE``: An operator; -* ``Twig_Token::PUNCTUATION_TYPE``: A punctuation sign; -* ``Twig_Token::INTERPOLATION_START_TYPE``, ``Twig_Token::INTERPOLATION_END_TYPE`` (as of Twig 1.5): Delimiters for string interpolation; -* ``Twig_Token::EOF_TYPE``: Ends of template. - -You can manually convert a source code into a token stream by calling the -``tokenize()`` method of an environment:: - - $stream = $twig->tokenize($source, $identifier); - -As the stream has a ``__toString()`` method, you can have a textual -representation of it by echoing the object:: - - echo $stream."\n"; - -Here is the output for the ``Hello {{ name }}`` template: - -.. code-block:: text - - TEXT_TYPE(Hello ) - VAR_START_TYPE() - NAME_TYPE(name) - VAR_END_TYPE() - EOF_TYPE() - -.. note:: - - The default lexer (``Twig_Lexer``) can be changed by calling - the ``setLexer()`` method:: - - $twig->setLexer($lexer); - -The Parser ----------- - -The parser converts the token stream into an AST (Abstract Syntax Tree), or a -node tree (an instance of ``Twig_Node_Module``). The core extension defines -the basic nodes like: ``for``, ``if``, ... and the expression nodes. - -You can manually convert a token stream into a node tree by calling the -``parse()`` method of an environment:: - - $nodes = $twig->parse($stream); - -Echoing the node object gives you a nice representation of the tree:: - - echo $nodes."\n"; - -Here is the output for the ``Hello {{ name }}`` template: - -.. code-block:: text - - Twig_Node_Module( - Twig_Node_Text(Hello ) - Twig_Node_Print( - Twig_Node_Expression_Name(name) - ) - ) - -.. note:: - - The default parser (``Twig_TokenParser``) can be changed by calling the - ``setParser()`` method:: - - $twig->setParser($parser); - -The Compiler ------------- - -The last step is done by the compiler. It takes a node tree as an input and -generates PHP code usable for runtime execution of the template. - -You can manually compile a node tree to PHP code with the ``compile()`` method -of an environment:: - - $php = $twig->compile($nodes); - -The generated template for a ``Hello {{ name }}`` template reads as follows -(the actual output can differ depending on the version of Twig you are -using):: - - /* Hello {{ name }} */ - class __TwigTemplate_1121b6f109fe93ebe8c6e22e3712bceb extends Twig_Template - { - protected function doDisplay(array $context, array $blocks = array()) - { - // line 1 - echo "Hello "; - echo twig_escape_filter($this->env, isset($context["name"]) ? $context["name"] : null), "html", null, true); - } - - // some more code - } - -.. note:: - - The default compiler (``Twig_Compiler``) can be changed by calling the - ``setCompiler()`` method:: - - $twig->setCompiler($compiler); diff --git a/vendor/twig/twig/doc/intro.rst b/vendor/twig/twig/doc/intro.rst deleted file mode 100644 index 9b38c97d4..000000000 --- a/vendor/twig/twig/doc/intro.rst +++ /dev/null @@ -1,85 +0,0 @@ -Introduction -============ - -This is the documentation for Twig, the flexible, fast, and secure template -engine for PHP. - -If you have any exposure to other text-based template languages, such as -Smarty, Django, or Jinja, you should feel right at home with Twig. It's both -designer and developer friendly by sticking to PHP's principles and adding -functionality useful for templating environments. - -The key-features are... - -* *Fast*: Twig compiles templates down to plain optimized PHP code. The - overhead compared to regular PHP code was reduced to the very minimum. - -* *Secure*: Twig has a sandbox mode to evaluate untrusted template code. This - allows Twig to be used as a template language for applications where users - may modify the template design. - -* *Flexible*: Twig is powered by a flexible lexer and parser. This allows the - developer to define its own custom tags and filters, and create its own DSL. - -Twig is used by many Open-Source projects like Symfony, Drupal8, eZPublish, -phpBB, Piwik, OroCRM, and many frameworks have support for it as well like -Slim, Yii, Laravel, Codeigniter, and Kohana, just to name a few. - -Prerequisites -------------- - -Twig needs at least **PHP 5.2.7** to run. - -Installation ------------- - -The recommended way to install Twig is via Composer: - -.. code-block:: bash - - composer require "twig/twig:~1.0" - -.. note:: - - To learn more about the other installation methods, read the - :doc:`installation` chapter; it also explains how to install - the Twig C extension. - -Basic API Usage ---------------- - -This section gives you a brief introduction to the PHP API for Twig. - -.. code-block:: php - - require_once '/path/to/vendor/autoload.php'; - - $loader = new Twig_Loader_Array(array( - 'index' => 'Hello {{ name }}!', - )); - $twig = new Twig_Environment($loader); - - echo $twig->render('index', array('name' => 'Fabien')); - -Twig uses a loader (``Twig_Loader_Array``) to locate templates, and an -environment (``Twig_Environment``) to store the configuration. - -The ``render()`` method loads the template passed as a first argument and -renders it with the variables passed as a second argument. - -As templates are generally stored on the filesystem, Twig also comes with a -filesystem loader:: - - $loader = new Twig_Loader_Filesystem('/path/to/templates'); - $twig = new Twig_Environment($loader, array( - 'cache' => '/path/to/compilation_cache', - )); - - echo $twig->render('index.html', array('name' => 'Fabien')); - -.. tip:: - - If you are not using Composer, use the Twig built-in autoloader:: - - require_once '/path/to/lib/Twig/Autoloader.php'; - Twig_Autoloader::register(); diff --git a/vendor/twig/twig/doc/recipes.rst b/vendor/twig/twig/doc/recipes.rst deleted file mode 100644 index 6ad53276c..000000000 --- a/vendor/twig/twig/doc/recipes.rst +++ /dev/null @@ -1,518 +0,0 @@ -Recipes -======= - -.. _deprecation-notices: - -Displaying Deprecation Notices ------------------------------- - -.. versionadded:: 1.21 - This works as of Twig 1.21. - -Deprecated features generate deprecation notices (via a call to the -``trigger_error()`` PHP function). By default, they are silenced and never -displayed nor logged. - -To easily remove all deprecated feature usages from your templates, write and -run a script along the lines of the following:: - - require_once __DIR__.'/vendor/autoload.php'; - - $twig = create_your_twig_env(); - - $deprecations = new Twig_Util_DeprecationCollector($twig); - - print_r($deprecations->collectDir(__DIR__.'/templates')); - -The ``collectDir()`` method compiles all templates found in a directory, -catches deprecation notices, and return them. - -.. tip:: - - If your templates are not stored on the filesystem, use the ``collect()`` - method instead which takes an ``Iterator``; the iterator must return - template names as keys and template contents as values (as done by - ``Twig_Util_TemplateDirIterator``). - -However, this code won't find all deprecations (like using deprecated some Twig -classes). To catch all notices, register a custom error handler like the one -below:: - - $deprecations = array(); - set_error_handler(function ($type, $msg) use (&$deprecations) { - if (E_USER_DEPRECATED === $type) { - $deprecations[] = $msg; - } - }); - - // run your application - - print_r($deprecations); - -Note that most deprecation notices are triggered during **compilation**, so -they won't be generated when templates are already cached. - -.. tip:: - - If you want to manage the deprecation notices from your PHPUnit tests, have - a look at the `symfony/phpunit-bridge - `_ package, which eases the - process a lot. - -Making a Layout conditional ---------------------------- - -Working with Ajax means that the same content is sometimes displayed as is, -and sometimes decorated with a layout. As Twig layout template names can be -any valid expression, you can pass a variable that evaluates to ``true`` when -the request is made via Ajax and choose the layout accordingly: - -.. code-block:: jinja - - {% extends request.ajax ? "base_ajax.html" : "base.html" %} - - {% block content %} - This is the content to be displayed. - {% endblock %} - -Making an Include dynamic -------------------------- - -When including a template, its name does not need to be a string. For -instance, the name can depend on the value of a variable: - -.. code-block:: jinja - - {% include var ~ '_foo.html' %} - -If ``var`` evaluates to ``index``, the ``index_foo.html`` template will be -rendered. - -As a matter of fact, the template name can be any valid expression, such as -the following: - -.. code-block:: jinja - - {% include var|default('index') ~ '_foo.html' %} - -Overriding a Template that also extends itself ----------------------------------------------- - -A template can be customized in two different ways: - -* *Inheritance*: A template *extends* a parent template and overrides some - blocks; - -* *Replacement*: If you use the filesystem loader, Twig loads the first - template it finds in a list of configured directories; a template found in a - directory *replaces* another one from a directory further in the list. - -But how do you combine both: *replace* a template that also extends itself -(aka a template in a directory further in the list)? - -Let's say that your templates are loaded from both ``.../templates/mysite`` -and ``.../templates/default`` in this order. The ``page.twig`` template, -stored in ``.../templates/default`` reads as follows: - -.. code-block:: jinja - - {# page.twig #} - {% extends "layout.twig" %} - - {% block content %} - {% endblock %} - -You can replace this template by putting a file with the same name in -``.../templates/mysite``. And if you want to extend the original template, you -might be tempted to write the following: - -.. code-block:: jinja - - {# page.twig in .../templates/mysite #} - {% extends "page.twig" %} {# from .../templates/default #} - -Of course, this will not work as Twig will always load the template from -``.../templates/mysite``. - -It turns out it is possible to get this to work, by adding a directory right -at the end of your template directories, which is the parent of all of the -other directories: ``.../templates`` in our case. This has the effect of -making every template file within our system uniquely addressable. Most of the -time you will use the "normal" paths, but in the special case of wanting to -extend a template with an overriding version of itself we can reference its -parent's full, unambiguous template path in the extends tag: - -.. code-block:: jinja - - {# page.twig in .../templates/mysite #} - {% extends "default/page.twig" %} {# from .../templates #} - -.. note:: - - This recipe was inspired by the following Django wiki page: - http://code.djangoproject.com/wiki/ExtendingTemplates - -Customizing the Syntax ----------------------- - -Twig allows some syntax customization for the block delimiters. It's not -recommended to use this feature as templates will be tied with your custom -syntax. But for specific projects, it can make sense to change the defaults. - -To change the block delimiters, you need to create your own lexer object:: - - $twig = new Twig_Environment(); - - $lexer = new Twig_Lexer($twig, array( - 'tag_comment' => array('{#', '#}'), - 'tag_block' => array('{%', '%}'), - 'tag_variable' => array('{{', '}}'), - 'interpolation' => array('#{', '}'), - )); - $twig->setLexer($lexer); - -Here are some configuration example that simulates some other template engines -syntax:: - - // Ruby erb syntax - $lexer = new Twig_Lexer($twig, array( - 'tag_comment' => array('<%#', '%>'), - 'tag_block' => array('<%', '%>'), - 'tag_variable' => array('<%=', '%>'), - )); - - // SGML Comment Syntax - $lexer = new Twig_Lexer($twig, array( - 'tag_comment' => array(''), - 'tag_block' => array(''), - 'tag_variable' => array('${', '}'), - )); - - // Smarty like - $lexer = new Twig_Lexer($twig, array( - 'tag_comment' => array('{*', '*}'), - 'tag_block' => array('{', '}'), - 'tag_variable' => array('{$', '}'), - )); - -Using dynamic Object Properties -------------------------------- - -When Twig encounters a variable like ``article.title``, it tries to find a -``title`` public property in the ``article`` object. - -It also works if the property does not exist but is rather defined dynamically -thanks to the magic ``__get()`` method; you just need to also implement the -``__isset()`` magic method like shown in the following snippet of code:: - - class Article - { - public function __get($name) - { - if ('title' == $name) { - return 'The title'; - } - - // throw some kind of error - } - - public function __isset($name) - { - if ('title' == $name) { - return true; - } - - return false; - } - } - -Accessing the parent Context in Nested Loops --------------------------------------------- - -Sometimes, when using nested loops, you need to access the parent context. The -parent context is always accessible via the ``loop.parent`` variable. For -instance, if you have the following template data:: - - $data = array( - 'topics' => array( - 'topic1' => array('Message 1 of topic 1', 'Message 2 of topic 1'), - 'topic2' => array('Message 1 of topic 2', 'Message 2 of topic 2'), - ), - ); - -And the following template to display all messages in all topics: - -.. code-block:: jinja - - {% for topic, messages in topics %} - * {{ loop.index }}: {{ topic }} - {% for message in messages %} - - {{ loop.parent.loop.index }}.{{ loop.index }}: {{ message }} - {% endfor %} - {% endfor %} - -The output will be similar to: - -.. code-block:: text - - * 1: topic1 - - 1.1: The message 1 of topic 1 - - 1.2: The message 2 of topic 1 - * 2: topic2 - - 2.1: The message 1 of topic 2 - - 2.2: The message 2 of topic 2 - -In the inner loop, the ``loop.parent`` variable is used to access the outer -context. So, the index of the current ``topic`` defined in the outer for loop -is accessible via the ``loop.parent.loop.index`` variable. - -Defining undefined Functions and Filters on the Fly ---------------------------------------------------- - -When a function (or a filter) is not defined, Twig defaults to throw a -``Twig_Error_Syntax`` exception. However, it can also call a `callback`_ (any -valid PHP callable) which should return a function (or a filter). - -For filters, register callbacks with ``registerUndefinedFilterCallback()``. -For functions, use ``registerUndefinedFunctionCallback()``:: - - // auto-register all native PHP functions as Twig functions - // don't try this at home as it's not secure at all! - $twig->registerUndefinedFunctionCallback(function ($name) { - if (function_exists($name)) { - return new Twig_Function_Function($name); - } - - return false; - }); - -If the callable is not able to return a valid function (or filter), it must -return ``false``. - -If you register more than one callback, Twig will call them in turn until one -does not return ``false``. - -.. tip:: - - As the resolution of functions and filters is done during compilation, - there is no overhead when registering these callbacks. - -Validating the Template Syntax ------------------------------- - -When template code is provided by a third-party (through a web interface for -instance), it might be interesting to validate the template syntax before -saving it. If the template code is stored in a `$template` variable, here is -how you can do it:: - - try { - $twig->parse($twig->tokenize($template)); - - // the $template is valid - } catch (Twig_Error_Syntax $e) { - // $template contains one or more syntax errors - } - -If you iterate over a set of files, you can pass the filename to the -``tokenize()`` method to get the filename in the exception message:: - - foreach ($files as $file) { - try { - $twig->parse($twig->tokenize($template, $file)); - - // the $template is valid - } catch (Twig_Error_Syntax $e) { - // $template contains one or more syntax errors - } - } - -.. note:: - - This method won't catch any sandbox policy violations because the policy - is enforced during template rendering (as Twig needs the context for some - checks like allowed methods on objects). - -Refreshing modified Templates when OPcache or APC is enabled ------------------------------------------------------------- - -When using OPcache with ``opcache.validate_timestamps`` set to ``0`` or APC -with ``apc.stat`` set to ``0`` and Twig cache enabled, clearing the template -cache won't update the cache. - -To get around this, force Twig to invalidate the bytecode cache:: - - $twig = new Twig_Environment($loader, array( - 'cache' => new Twig_Cache_Filesystem('/some/cache/path', Twig_Cache_Filesystem::FORCE_BYTECODE_INVALIDATION), - // ... - )); - -.. note:: - - Before Twig 1.22, you should extend ``Twig_Environment`` instead:: - - class OpCacheAwareTwigEnvironment extends Twig_Environment - { - protected function writeCacheFile($file, $content) - { - parent::writeCacheFile($file, $content); - - // Compile cached file into bytecode cache - if (function_exists('opcache_invalidate')) { - opcache_invalidate($file, true); - } elseif (function_exists('apc_compile_file')) { - apc_compile_file($file); - } - } - } - -Reusing a stateful Node Visitor -------------------------------- - -When attaching a visitor to a ``Twig_Environment`` instance, Twig uses it to -visit *all* templates it compiles. If you need to keep some state information -around, you probably want to reset it when visiting a new template. - -This can be easily achieved with the following code:: - - protected $someTemplateState = array(); - - public function enterNode(Twig_NodeInterface $node, Twig_Environment $env) - { - if ($node instanceof Twig_Node_Module) { - // reset the state as we are entering a new template - $this->someTemplateState = array(); - } - - // ... - - return $node; - } - -Using a Database to store Templates ------------------------------------ - -If you are developing a CMS, templates are usually stored in a database. This -recipe gives you a simple PDO template loader you can use as a starting point -for your own. - -First, let's create a temporary in-memory SQLite3 database to work with:: - - $dbh = new PDO('sqlite::memory:'); - $dbh->exec('CREATE TABLE templates (name STRING, source STRING, last_modified INTEGER)'); - $base = '{% block content %}{% endblock %}'; - $index = ' - {% extends "base.twig" %} - {% block content %}Hello {{ name }}{% endblock %} - '; - $now = time(); - $dbh->exec("INSERT INTO templates (name, source, last_modified) VALUES ('base.twig', '$base', $now)"); - $dbh->exec("INSERT INTO templates (name, source, last_modified) VALUES ('index.twig', '$index', $now)"); - -We have created a simple ``templates`` table that hosts two templates: -``base.twig`` and ``index.twig``. - -Now, let's define a loader able to use this database:: - - class DatabaseTwigLoader implements Twig_LoaderInterface, Twig_ExistsLoaderInterface - { - protected $dbh; - - public function __construct(PDO $dbh) - { - $this->dbh = $dbh; - } - - public function getSource($name) - { - if (false === $source = $this->getValue('source', $name)) { - throw new Twig_Error_Loader(sprintf('Template "%s" does not exist.', $name)); - } - - return $source; - } - - // Twig_ExistsLoaderInterface as of Twig 1.11 - public function exists($name) - { - return $name === $this->getValue('name', $name); - } - - public function getCacheKey($name) - { - return $name; - } - - public function isFresh($name, $time) - { - if (false === $lastModified = $this->getValue('last_modified', $name)) { - return false; - } - - return $lastModified <= $time; - } - - protected function getValue($column, $name) - { - $sth = $this->dbh->prepare('SELECT '.$column.' FROM templates WHERE name = :name'); - $sth->execute(array(':name' => (string) $name)); - - return $sth->fetchColumn(); - } - } - -Finally, here is an example on how you can use it:: - - $loader = new DatabaseTwigLoader($dbh); - $twig = new Twig_Environment($loader); - - echo $twig->render('index.twig', array('name' => 'Fabien')); - -Using different Template Sources --------------------------------- - -This recipe is the continuation of the previous one. Even if you store the -contributed templates in a database, you might want to keep the original/base -templates on the filesystem. When templates can be loaded from different -sources, you need to use the ``Twig_Loader_Chain`` loader. - -As you can see in the previous recipe, we reference the template in the exact -same way as we would have done it with a regular filesystem loader. This is -the key to be able to mix and match templates coming from the database, the -filesystem, or any other loader for that matter: the template name should be a -logical name, and not the path from the filesystem:: - - $loader1 = new DatabaseTwigLoader($dbh); - $loader2 = new Twig_Loader_Array(array( - 'base.twig' => '{% block content %}{% endblock %}', - )); - $loader = new Twig_Loader_Chain(array($loader1, $loader2)); - - $twig = new Twig_Environment($loader); - - echo $twig->render('index.twig', array('name' => 'Fabien')); - -Now that the ``base.twig`` templates is defined in an array loader, you can -remove it from the database, and everything else will still work as before. - -Loading a Template from a String --------------------------------- - -From a template, you can easily load a template stored in a string via the -``template_from_string`` function (available as of Twig 1.11 via the -``Twig_Extension_StringLoader`` extension):: - -.. code-block:: jinja - - {{ include(template_from_string("Hello {{ name }}")) }} - -From PHP, it's also possible to load a template stored in a string via -``Twig_Environment::createTemplate()`` (available as of Twig 1.18):: - - $template = $twig->createTemplate('hello {{ name }}'); - echo $template->render(array('name' => 'Fabien')); - -.. note:: - - Never use the ``Twig_Loader_String`` loader, which has severe limitations. - -.. _callback: http://www.php.net/manual/en/function.is-callable.php diff --git a/vendor/twig/twig/doc/tags/autoescape.rst b/vendor/twig/twig/doc/tags/autoescape.rst deleted file mode 100644 index 4208d1a31..000000000 --- a/vendor/twig/twig/doc/tags/autoescape.rst +++ /dev/null @@ -1,83 +0,0 @@ -``autoescape`` -============== - -Whether automatic escaping is enabled or not, you can mark a section of a -template to be escaped or not by using the ``autoescape`` tag: - -.. code-block:: jinja - - {# The following syntax works as of Twig 1.8 -- see the note below for previous versions #} - - {% autoescape %} - Everything will be automatically escaped in this block - using the HTML strategy - {% endautoescape %} - - {% autoescape 'html' %} - Everything will be automatically escaped in this block - using the HTML strategy - {% endautoescape %} - - {% autoescape 'js' %} - Everything will be automatically escaped in this block - using the js escaping strategy - {% endautoescape %} - - {% autoescape false %} - Everything will be outputted as is in this block - {% endautoescape %} - -.. note:: - - Before Twig 1.8, the syntax was different: - - .. code-block:: jinja - - {% autoescape true %} - Everything will be automatically escaped in this block - using the HTML strategy - {% endautoescape %} - - {% autoescape false %} - Everything will be outputted as is in this block - {% endautoescape %} - - {% autoescape true js %} - Everything will be automatically escaped in this block - using the js escaping strategy - {% endautoescape %} - -When automatic escaping is enabled everything is escaped by default except for -values explicitly marked as safe. Those can be marked in the template by using -the :doc:`raw<../filters/raw>` filter: - -.. code-block:: jinja - - {% autoescape %} - {{ safe_value|raw }} - {% endautoescape %} - -Functions returning template data (like :doc:`macros` and -:doc:`parent<../functions/parent>`) always return safe markup. - -.. note:: - - Twig is smart enough to not escape an already escaped value by the - :doc:`escape<../filters/escape>` filter. - -.. note:: - - Twig does not escape static expressions: - - .. code-block:: jinja - - {% set hello = "Hello" %} - {{ hello }} - {{ "world" }} - - Will be rendered "Hello **world**". - -.. note:: - - The chapter :doc:`Twig for Developers<../api>` gives more information - about when and how automatic escaping is applied. diff --git a/vendor/twig/twig/doc/tags/block.rst b/vendor/twig/twig/doc/tags/block.rst deleted file mode 100644 index e38048232..000000000 --- a/vendor/twig/twig/doc/tags/block.rst +++ /dev/null @@ -1,11 +0,0 @@ -``block`` -========= - -Blocks are used for inheritance and act as placeholders and replacements at -the same time. They are documented in detail in the documentation for the -:doc:`extends<../tags/extends>` tag. - -Block names should consist of alphanumeric characters, and underscores. Dashes -are not permitted. - -.. seealso:: :doc:`block<../functions/block>`, :doc:`parent<../functions/parent>`, :doc:`use<../tags/use>`, :doc:`extends<../tags/extends>` diff --git a/vendor/twig/twig/doc/tags/do.rst b/vendor/twig/twig/doc/tags/do.rst deleted file mode 100644 index 1c344e302..000000000 --- a/vendor/twig/twig/doc/tags/do.rst +++ /dev/null @@ -1,12 +0,0 @@ -``do`` -====== - -.. versionadded:: 1.5 - The ``do`` tag was added in Twig 1.5. - -The ``do`` tag works exactly like the regular variable expression (``{{ ... -}}``) just that it doesn't print anything: - -.. code-block:: jinja - - {% do 1 + 2 %} diff --git a/vendor/twig/twig/doc/tags/embed.rst b/vendor/twig/twig/doc/tags/embed.rst deleted file mode 100644 index 5a6a0299a..000000000 --- a/vendor/twig/twig/doc/tags/embed.rst +++ /dev/null @@ -1,178 +0,0 @@ -``embed`` -========= - -.. versionadded:: 1.8 - The ``embed`` tag was added in Twig 1.8. - -The ``embed`` tag combines the behaviour of :doc:`include` and -:doc:`extends`. -It allows you to include another template's contents, just like ``include`` -does. But it also allows you to override any block defined inside the -included template, like when extending a template. - -Think of an embedded template as a "micro layout skeleton". - -.. code-block:: jinja - - {% embed "teasers_skeleton.twig" %} - {# These blocks are defined in "teasers_skeleton.twig" #} - {# and we override them right here: #} - {% block left_teaser %} - Some content for the left teaser box - {% endblock %} - {% block right_teaser %} - Some content for the right teaser box - {% endblock %} - {% endembed %} - -The ``embed`` tag takes the idea of template inheritance to the level of -content fragments. While template inheritance allows for "document skeletons", -which are filled with life by child templates, the ``embed`` tag allows you to -create "skeletons" for smaller units of content and re-use and fill them -anywhere you like. - -Since the use case may not be obvious, let's look at a simplified example. -Imagine a base template shared by multiple HTML pages, defining a single block -named "content": - -.. code-block:: text - - ┌─── page layout ─────────────────────┐ - │ │ - │ ┌── block "content" ──┐ │ - │ │ │ │ - │ │ │ │ - │ │ (child template to │ │ - │ │ put content here) │ │ - │ │ │ │ - │ │ │ │ - │ └─────────────────────┘ │ - │ │ - └─────────────────────────────────────┘ - -Some pages ("foo" and "bar") share the same content structure - -two vertically stacked boxes: - -.. code-block:: text - - ┌─── page layout ─────────────────────┐ - │ │ - │ ┌── block "content" ──┐ │ - │ │ ┌─ block "top" ───┐ │ │ - │ │ │ │ │ │ - │ │ └─────────────────┘ │ │ - │ │ ┌─ block "bottom" ┐ │ │ - │ │ │ │ │ │ - │ │ └─────────────────┘ │ │ - │ └─────────────────────┘ │ - │ │ - └─────────────────────────────────────┘ - -While other pages ("boom" and "baz") share a different content structure - -two boxes side by side: - -.. code-block:: text - - ┌─── page layout ─────────────────────┐ - │ │ - │ ┌── block "content" ──┐ │ - │ │ │ │ - │ │ ┌ block ┐ ┌ block ┐ │ │ - │ │ │"left" │ │"right"│ │ │ - │ │ │ │ │ │ │ │ - │ │ │ │ │ │ │ │ - │ │ └───────┘ └───────┘ │ │ - │ └─────────────────────┘ │ - │ │ - └─────────────────────────────────────┘ - -Without the ``embed`` tag, you have two ways to design your templates: - - * Create two "intermediate" base templates that extend the master layout - template: one with vertically stacked boxes to be used by the "foo" and - "bar" pages and another one with side-by-side boxes for the "boom" and - "baz" pages. - - * Embed the markup for the top/bottom and left/right boxes into each page - template directly. - -These two solutions do not scale well because they each have a major drawback: - - * The first solution may indeed work for this simplified example. But imagine - we add a sidebar, which may again contain different, recurring structures - of content. Now we would need to create intermediate base templates for - all occurring combinations of content structure and sidebar structure... - and so on. - - * The second solution involves duplication of common code with all its negative - consequences: any change involves finding and editing all affected copies - of the structure, correctness has to be verified for each copy, copies may - go out of sync by careless modifications etc. - -In such a situation, the ``embed`` tag comes in handy. The common layout -code can live in a single base template, and the two different content structures, -let's call them "micro layouts" go into separate templates which are embedded -as necessary: - -Page template ``foo.twig``: - -.. code-block:: jinja - - {% extends "layout_skeleton.twig" %} - - {% block content %} - {% embed "vertical_boxes_skeleton.twig" %} - {% block top %} - Some content for the top box - {% endblock %} - - {% block bottom %} - Some content for the bottom box - {% endblock %} - {% endembed %} - {% endblock %} - -And here is the code for ``vertical_boxes_skeleton.twig``: - -.. code-block:: html+jinja - -
    - {% block top %} - Top box default content - {% endblock %} -
    - -
    - {% block bottom %} - Bottom box default content - {% endblock %} -
    - -The goal of the ``vertical_boxes_skeleton.twig`` template being to factor -out the HTML markup for the boxes. - -The ``embed`` tag takes the exact same arguments as the ``include`` tag: - -.. code-block:: jinja - - {% embed "base" with {'foo': 'bar'} %} - ... - {% endembed %} - - {% embed "base" with {'foo': 'bar'} only %} - ... - {% endembed %} - - {% embed "base" ignore missing %} - ... - {% endembed %} - -.. warning:: - - As embedded templates do not have "names", auto-escaping strategies based - on the template "filename" won't work as expected if you change the - context (for instance, if you embed a CSS/JavaScript template into an HTML - one). In that case, explicitly set the default auto-escaping strategy with - the ``autoescape`` tag. - -.. seealso:: :doc:`include<../tags/include>` diff --git a/vendor/twig/twig/doc/tags/extends.rst b/vendor/twig/twig/doc/tags/extends.rst deleted file mode 100644 index 1ad2b12b1..000000000 --- a/vendor/twig/twig/doc/tags/extends.rst +++ /dev/null @@ -1,268 +0,0 @@ -``extends`` -=========== - -The ``extends`` tag can be used to extend a template from another one. - -.. note:: - - Like PHP, Twig does not support multiple inheritance. So you can only have - one extends tag called per rendering. However, Twig supports horizontal - :doc:`reuse`. - -Let's define a base template, ``base.html``, which defines a simple HTML -skeleton document: - -.. code-block:: html+jinja - - - - - {% block head %} - - {% block title %}{% endblock %} - My Webpage - {% endblock %} - - -
    {% block content %}{% endblock %}
    - - - - -In this example, the :doc:`block` tags define four blocks that child -templates can fill in. - -All the ``block`` tag does is to tell the template engine that a child -template may override those portions of the template. - -Child Template --------------- - -A child template might look like this: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% block title %}Index{% endblock %} - {% block head %} - {{ parent() }} - - {% endblock %} - {% block content %} -

    Index

    -

    - Welcome on my awesome homepage. -

    - {% endblock %} - -The ``extends`` tag is the key here. It tells the template engine that this -template "extends" another template. When the template system evaluates this -template, first it locates the parent. The extends tag should be the first tag -in the template. - -Note that since the child template doesn't define the ``footer`` block, the -value from the parent template is used instead. - -You can't define multiple ``block`` tags with the same name in the same -template. This limitation exists because a block tag works in "both" -directions. That is, a block tag doesn't just provide a hole to fill - it also -defines the content that fills the hole in the *parent*. If there were two -similarly-named ``block`` tags in a template, that template's parent wouldn't -know which one of the blocks' content to use. - -If you want to print a block multiple times you can however use the -``block`` function: - -.. code-block:: jinja - - {% block title %}{% endblock %} -

    {{ block('title') }}

    - {% block body %}{% endblock %} - -Parent Blocks -------------- - -It's possible to render the contents of the parent block by using the -:doc:`parent<../functions/parent>` function. This gives back the results of -the parent block: - -.. code-block:: jinja - - {% block sidebar %} -

    Table Of Contents

    - ... - {{ parent() }} - {% endblock %} - -Named Block End-Tags --------------------- - -Twig allows you to put the name of the block after the end tag for better -readability: - -.. code-block:: jinja - - {% block sidebar %} - {% block inner_sidebar %} - ... - {% endblock inner_sidebar %} - {% endblock sidebar %} - -Of course, the name after the ``endblock`` word must match the block name. - -Block Nesting and Scope ------------------------ - -Blocks can be nested for more complex layouts. Per default, blocks have access -to variables from outer scopes: - -.. code-block:: jinja - - {% for item in seq %} -
  • {% block loop_item %}{{ item }}{% endblock %}
  • - {% endfor %} - -Block Shortcuts ---------------- - -For blocks with few content, it's possible to use a shortcut syntax. The -following constructs do the same: - -.. code-block:: jinja - - {% block title %} - {{ page_title|title }} - {% endblock %} - -.. code-block:: jinja - - {% block title page_title|title %} - -Dynamic Inheritance -------------------- - -Twig supports dynamic inheritance by using a variable as the base template: - -.. code-block:: jinja - - {% extends some_var %} - -If the variable evaluates to a ``Twig_Template`` object, Twig will use it as -the parent template:: - - // {% extends layout %} - - $layout = $twig->loadTemplate('some_layout_template.twig'); - - $twig->display('template.twig', array('layout' => $layout)); - -.. versionadded:: 1.2 - The possibility to pass an array of templates has been added in Twig 1.2. - -You can also provide a list of templates that are checked for existence. The -first template that exists will be used as a parent: - -.. code-block:: jinja - - {% extends ['layout.html', 'base_layout.html'] %} - -Conditional Inheritance ------------------------ - -As the template name for the parent can be any valid Twig expression, it's -possible to make the inheritance mechanism conditional: - -.. code-block:: jinja - - {% extends standalone ? "minimum.html" : "base.html" %} - -In this example, the template will extend the "minimum.html" layout template -if the ``standalone`` variable evaluates to ``true``, and "base.html" -otherwise. - -How do blocks work? -------------------- - -A block provides a way to change how a certain part of a template is rendered -but it does not interfere in any way with the logic around it. - -Let's take the following example to illustrate how a block works and more -importantly, how it does not work: - -.. code-block:: jinja - - {# base.twig #} - - {% for post in posts %} - {% block post %} -

    {{ post.title }}

    -

    {{ post.body }}

    - {% endblock %} - {% endfor %} - -If you render this template, the result would be exactly the same with or -without the ``block`` tag. The ``block`` inside the ``for`` loop is just a way -to make it overridable by a child template: - -.. code-block:: jinja - - {# child.twig #} - - {% extends "base.twig" %} - - {% block post %} -
    -
    {{ post.title }}
    -
    {{ post.text }}
    -
    - {% endblock %} - -Now, when rendering the child template, the loop is going to use the block -defined in the child template instead of the one defined in the base one; the -executed template is then equivalent to the following one: - -.. code-block:: jinja - - {% for post in posts %} -
    -
    {{ post.title }}
    -
    {{ post.text }}
    -
    - {% endfor %} - -Let's take another example: a block included within an ``if`` statement: - -.. code-block:: jinja - - {% if posts is empty %} - {% block head %} - {{ parent() }} - - - {% endblock head %} - {% endif %} - -Contrary to what you might think, this template does not define a block -conditionally; it just makes overridable by a child template the output of -what will be rendered when the condition is ``true``. - -If you want the output to be displayed conditionally, use the following -instead: - -.. code-block:: jinja - - {% block head %} - {{ parent() }} - - {% if posts is empty %} - - {% endif %} - {% endblock head %} - -.. seealso:: :doc:`block<../functions/block>`, :doc:`block<../tags/block>`, :doc:`parent<../functions/parent>`, :doc:`use<../tags/use>` diff --git a/vendor/twig/twig/doc/tags/filter.rst b/vendor/twig/twig/doc/tags/filter.rst deleted file mode 100644 index 82ca5c62f..000000000 --- a/vendor/twig/twig/doc/tags/filter.rst +++ /dev/null @@ -1,21 +0,0 @@ -``filter`` -========== - -Filter sections allow you to apply regular Twig filters on a block of template -data. Just wrap the code in the special ``filter`` section: - -.. code-block:: jinja - - {% filter upper %} - This text becomes uppercase - {% endfilter %} - -You can also chain filters: - -.. code-block:: jinja - - {% filter lower|escape %} - SOME TEXT - {% endfilter %} - - {# outputs "<strong>some text</strong>" #} diff --git a/vendor/twig/twig/doc/tags/flush.rst b/vendor/twig/twig/doc/tags/flush.rst deleted file mode 100644 index 55ef593a9..000000000 --- a/vendor/twig/twig/doc/tags/flush.rst +++ /dev/null @@ -1,17 +0,0 @@ -``flush`` -========= - -.. versionadded:: 1.5 - The flush tag was added in Twig 1.5. - -The ``flush`` tag tells Twig to flush the output buffer: - -.. code-block:: jinja - - {% flush %} - -.. note:: - - Internally, Twig uses the PHP `flush`_ function. - -.. _`flush`: http://php.net/flush diff --git a/vendor/twig/twig/doc/tags/for.rst b/vendor/twig/twig/doc/tags/for.rst deleted file mode 100644 index 0673b5511..000000000 --- a/vendor/twig/twig/doc/tags/for.rst +++ /dev/null @@ -1,172 +0,0 @@ -``for`` -======= - -Loop over each item in a sequence. For example, to display a list of users -provided in a variable called ``users``: - -.. code-block:: jinja - -

    Members

    -
      - {% for user in users %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    - -.. note:: - - A sequence can be either an array or an object implementing the - ``Traversable`` interface. - -If you do need to iterate over a sequence of numbers, you can use the ``..`` -operator: - -.. code-block:: jinja - - {% for i in 0..10 %} - * {{ i }} - {% endfor %} - -The above snippet of code would print all numbers from 0 to 10. - -It can be also useful with letters: - -.. code-block:: jinja - - {% for letter in 'a'..'z' %} - * {{ letter }} - {% endfor %} - -The ``..`` operator can take any expression at both sides: - -.. code-block:: jinja - - {% for letter in 'a'|upper..'z'|upper %} - * {{ letter }} - {% endfor %} - -.. tip: - - If you need a step different from 1, you can use the ``range`` function - instead. - -The `loop` variable -------------------- - -Inside of a ``for`` loop block you can access some special variables: - -===================== ============================================================= -Variable Description -===================== ============================================================= -``loop.index`` The current iteration of the loop. (1 indexed) -``loop.index0`` The current iteration of the loop. (0 indexed) -``loop.revindex`` The number of iterations from the end of the loop (1 indexed) -``loop.revindex0`` The number of iterations from the end of the loop (0 indexed) -``loop.first`` True if first iteration -``loop.last`` True if last iteration -``loop.length`` The number of items in the sequence -``loop.parent`` The parent context -===================== ============================================================= - -.. code-block:: jinja - - {% for user in users %} - {{ loop.index }} - {{ user.username }} - {% endfor %} - -.. note:: - - The ``loop.length``, ``loop.revindex``, ``loop.revindex0``, and - ``loop.last`` variables are only available for PHP arrays, or objects that - implement the ``Countable`` interface. They are also not available when - looping with a condition. - -.. versionadded:: 1.2 - The ``if`` modifier support has been added in Twig 1.2. - -Adding a condition ------------------- - -Unlike in PHP, it's not possible to ``break`` or ``continue`` in a loop. You -can however filter the sequence during iteration which allows you to skip -items. The following example skips all the users which are not active: - -.. code-block:: jinja - -
      - {% for user in users if user.active %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    - -The advantage is that the special loop variable will count correctly thus not -counting the users not iterated over. Keep in mind that properties like -``loop.last`` will not be defined when using loop conditions. - -.. note:: - - Using the ``loop`` variable within the condition is not recommended as it - will probably not be doing what you expect it to. For instance, adding a - condition like ``loop.index > 4`` won't work as the index is only - incremented when the condition is true (so the condition will never - match). - -The `else` Clause ------------------ - -If no iteration took place because the sequence was empty, you can render a -replacement block by using ``else``: - -.. code-block:: jinja - -
      - {% for user in users %} -
    • {{ user.username|e }}
    • - {% else %} -
    • no user found
    • - {% endfor %} -
    - -Iterating over Keys -------------------- - -By default, a loop iterates over the values of the sequence. You can iterate -on keys by using the ``keys`` filter: - -.. code-block:: jinja - -

    Members

    -
      - {% for key in users|keys %} -
    • {{ key }}
    • - {% endfor %} -
    - -Iterating over Keys and Values ------------------------------- - -You can also access both keys and values: - -.. code-block:: jinja - -

    Members

    -
      - {% for key, user in users %} -
    • {{ key }}: {{ user.username|e }}
    • - {% endfor %} -
    - -Iterating over a Subset ------------------------ - -You might want to iterate over a subset of values. This can be achieved using -the :doc:`slice <../filters/slice>` filter: - -.. code-block:: jinja - -

    Top Ten Members

    -
      - {% for user in users|slice(0, 10) %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    diff --git a/vendor/twig/twig/doc/tags/from.rst b/vendor/twig/twig/doc/tags/from.rst deleted file mode 100644 index 39334fdde..000000000 --- a/vendor/twig/twig/doc/tags/from.rst +++ /dev/null @@ -1,8 +0,0 @@ -``from`` -======== - -The ``from`` tag imports :doc:`macro<../tags/macro>` names into the current -namespace. The tag is documented in detail in the documentation for the -:doc:`import<../tags/import>` tag. - -.. seealso:: :doc:`macro<../tags/macro>`, :doc:`import<../tags/import>` diff --git a/vendor/twig/twig/doc/tags/if.rst b/vendor/twig/twig/doc/tags/if.rst deleted file mode 100644 index 12edf980d..000000000 --- a/vendor/twig/twig/doc/tags/if.rst +++ /dev/null @@ -1,76 +0,0 @@ -``if`` -====== - -The ``if`` statement in Twig is comparable with the if statements of PHP. - -In the simplest form you can use it to test if an expression evaluates to -``true``: - -.. code-block:: jinja - - {% if online == false %} -

    Our website is in maintenance mode. Please, come back later.

    - {% endif %} - -You can also test if an array is not empty: - -.. code-block:: jinja - - {% if users %} -
      - {% for user in users %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    - {% endif %} - -.. note:: - - If you want to test if the variable is defined, use ``if users is - defined`` instead. - -You can also use ``not`` to check for values that evaluate to ``false``: - -.. code-block:: jinja - - {% if not user.subscribed %} -

    You are not subscribed to our mailing list.

    - {% endif %} - -For multiple conditions, ``and`` and ``or`` can be used: - -.. code-block:: jinja - - {% if temperature > 18 and temperature < 27 %} -

    It's a nice day for a walk in the park.

    - {% endif %} - -For multiple branches ``elseif`` and ``else`` can be used like in PHP. You can -use more complex ``expressions`` there too: - -.. code-block:: jinja - - {% if kenny.sick %} - Kenny is sick. - {% elseif kenny.dead %} - You killed Kenny! You bastard!!! - {% else %} - Kenny looks okay --- so far - {% endif %} - -.. note:: - - The rules to determine if an expression is ``true`` or ``false`` are the - same as in PHP; here are the edge cases rules: - - ====================== ==================== - Value Boolean evaluation - ====================== ==================== - empty string false - numeric zero false - whitespace-only string true - empty array false - null false - non-empty array true - object true - ====================== ==================== diff --git a/vendor/twig/twig/doc/tags/import.rst b/vendor/twig/twig/doc/tags/import.rst deleted file mode 100644 index 21a1e1980..000000000 --- a/vendor/twig/twig/doc/tags/import.rst +++ /dev/null @@ -1,57 +0,0 @@ -``import`` -========== - -Twig supports putting often used code into :doc:`macros<../tags/macro>`. These -macros can go into different templates and get imported from there. - -There are two ways to import templates. You can import the complete template -into a variable or request specific macros from it. - -Imagine we have a helper module that renders forms (called ``forms.html``): - -.. code-block:: jinja - - {% macro input(name, value, type, size) %} - - {% endmacro %} - - {% macro textarea(name, value, rows, cols) %} - - {% endmacro %} - -The easiest and most flexible is importing the whole module into a variable. -That way you can access the attributes: - -.. code-block:: jinja - - {% import 'forms.html' as forms %} - -
    -
    Username
    -
    {{ forms.input('username') }}
    -
    Password
    -
    {{ forms.input('password', null, 'password') }}
    -
    -

    {{ forms.textarea('comment') }}

    - -Alternatively you can import names from the template into the current -namespace: - -.. code-block:: jinja - - {% from 'forms.html' import input as input_field, textarea %} - -
    -
    Username
    -
    {{ input_field('username') }}
    -
    Password
    -
    {{ input_field('password', '', 'password') }}
    -
    -

    {{ textarea('comment') }}

    - -.. tip:: - - To import macros from the current file, use the special ``_self`` variable - for the source. - -.. seealso:: :doc:`macro<../tags/macro>`, :doc:`from<../tags/from>` diff --git a/vendor/twig/twig/doc/tags/include.rst b/vendor/twig/twig/doc/tags/include.rst deleted file mode 100644 index da18dc65e..000000000 --- a/vendor/twig/twig/doc/tags/include.rst +++ /dev/null @@ -1,86 +0,0 @@ -``include`` -=========== - -The ``include`` statement includes a template and returns the rendered content -of that file into the current namespace: - -.. code-block:: jinja - - {% include 'header.html' %} - Body - {% include 'footer.html' %} - -Included templates have access to the variables of the active context. - -If you are using the filesystem loader, the templates are looked for in the -paths defined by it. - -You can add additional variables by passing them after the ``with`` keyword: - -.. code-block:: jinja - - {# template.html will have access to the variables from the current context and the additional ones provided #} - {% include 'template.html' with {'foo': 'bar'} %} - - {% set vars = {'foo': 'bar'} %} - {% include 'template.html' with vars %} - -You can disable access to the context by appending the ``only`` keyword: - -.. code-block:: jinja - - {# only the foo variable will be accessible #} - {% include 'template.html' with {'foo': 'bar'} only %} - -.. code-block:: jinja - - {# no variables will be accessible #} - {% include 'template.html' only %} - -.. tip:: - - When including a template created by an end user, you should consider - sandboxing it. More information in the :doc:`Twig for Developers<../api>` - chapter and in the :doc:`sandbox<../tags/sandbox>` tag documentation. - -The template name can be any valid Twig expression: - -.. code-block:: jinja - - {% include some_var %} - {% include ajax ? 'ajax.html' : 'not_ajax.html' %} - -And if the expression evaluates to a ``Twig_Template`` object, Twig will use it -directly:: - - // {% include template %} - - $template = $twig->loadTemplate('some_template.twig'); - - $twig->loadTemplate('template.twig')->display(array('template' => $template)); - -.. versionadded:: 1.2 - The ``ignore missing`` feature has been added in Twig 1.2. - -You can mark an include with ``ignore missing`` in which case Twig will ignore -the statement if the template to be included does not exist. It has to be -placed just after the template name. Here some valid examples: - -.. code-block:: jinja - - {% include 'sidebar.html' ignore missing %} - {% include 'sidebar.html' ignore missing with {'foo': 'bar'} %} - {% include 'sidebar.html' ignore missing only %} - -.. versionadded:: 1.2 - The possibility to pass an array of templates has been added in Twig 1.2. - -You can also provide a list of templates that are checked for existence before -inclusion. The first template that exists will be included: - -.. code-block:: jinja - - {% include ['page_detailed.html', 'page.html'] %} - -If ``ignore missing`` is given, it will fall back to rendering nothing if none -of the templates exist, otherwise it will throw an exception. diff --git a/vendor/twig/twig/doc/tags/index.rst b/vendor/twig/twig/doc/tags/index.rst deleted file mode 100644 index e6a632b7d..000000000 --- a/vendor/twig/twig/doc/tags/index.rst +++ /dev/null @@ -1,24 +0,0 @@ -Tags -==== - -.. toctree:: - :maxdepth: 1 - - autoescape - block - do - embed - extends - filter - flush - for - from - if - import - include - macro - sandbox - set - spaceless - use - verbatim diff --git a/vendor/twig/twig/doc/tags/macro.rst b/vendor/twig/twig/doc/tags/macro.rst deleted file mode 100644 index 60a1567d1..000000000 --- a/vendor/twig/twig/doc/tags/macro.rst +++ /dev/null @@ -1,86 +0,0 @@ -``macro`` -========= - -Macros are comparable with functions in regular programming languages. They -are useful to put often used HTML idioms into reusable elements to not repeat -yourself. - -Here is a small example of a macro that renders a form element: - -.. code-block:: jinja - - {% macro input(name, value, type, size) %} - - {% endmacro %} - -Macros differs from native PHP functions in a few ways: - -* Default argument values are defined by using the ``default`` filter in the - macro body; - -* Arguments of a macro are always optional. - -* If extra positional arguments are passed to a macro, they end up in the - special ``varargs`` variable as a list of values. - -But as with PHP functions, macros don't have access to the current template -variables. - -.. tip:: - - You can pass the whole context as an argument by using the special - ``_context`` variable. - -Macros can be defined in any template, and need to be "imported" before being -used (see the documentation for the :doc:`import<../tags/import>` tag for more -information): - -.. code-block:: jinja - - {% import "forms.html" as forms %} - -The above ``import`` call imports the "forms.html" file (which can contain only -macros, or a template and some macros), and import the functions as items of -the ``forms`` variable. - -The macro can then be called at will: - -.. code-block:: jinja - -

    {{ forms.input('username') }}

    -

    {{ forms.input('password', null, 'password') }}

    - -If macros are defined and used in the same template, you can use the -special ``_self`` variable to import them: - -.. code-block:: jinja - - {% import _self as forms %} - -

    {{ forms.input('username') }}

    - -.. warning:: - - When you define a macro in the template where you are going to use it, you - might be tempted to call the macro directly via ``_self.input()`` instead - of importing it; even if seems to work, this is just a side-effect of the - current implementation and it won't work anymore in Twig 2.x. - -When you want to use a macro in another macro from the same file, you need to -import it locally: - -.. code-block:: jinja - - {% macro input(name, value, type, size) %} - - {% endmacro %} - - {% macro wrapped_input(name, value, type, size) %} - {% import _self as forms %} - -
    - {{ forms.input(name, value, type, size) }} -
    - {% endmacro %} - -.. seealso:: :doc:`from<../tags/from>`, :doc:`import<../tags/import>` diff --git a/vendor/twig/twig/doc/tags/sandbox.rst b/vendor/twig/twig/doc/tags/sandbox.rst deleted file mode 100644 index e186726c2..000000000 --- a/vendor/twig/twig/doc/tags/sandbox.rst +++ /dev/null @@ -1,30 +0,0 @@ -``sandbox`` -=========== - -The ``sandbox`` tag can be used to enable the sandboxing mode for an included -template, when sandboxing is not enabled globally for the Twig environment: - -.. code-block:: jinja - - {% sandbox %} - {% include 'user.html' %} - {% endsandbox %} - -.. warning:: - - The ``sandbox`` tag is only available when the sandbox extension is - enabled (see the :doc:`Twig for Developers<../api>` chapter). - -.. note:: - - The ``sandbox`` tag can only be used to sandbox an include tag and it - cannot be used to sandbox a section of a template. The following example - won't work: - - .. code-block:: jinja - - {% sandbox %} - {% for i in 1..2 %} - {{ i }} - {% endfor %} - {% endsandbox %} diff --git a/vendor/twig/twig/doc/tags/set.rst b/vendor/twig/twig/doc/tags/set.rst deleted file mode 100644 index 3eba239a9..000000000 --- a/vendor/twig/twig/doc/tags/set.rst +++ /dev/null @@ -1,78 +0,0 @@ -``set`` -======= - -Inside code blocks you can also assign values to variables. Assignments use -the ``set`` tag and can have multiple targets. - -Here is how you can assign the ``bar`` value to the ``foo`` variable: - -.. code-block:: jinja - - {% set foo = 'bar' %} - -After the ``set`` call, the ``foo`` variable is available in the template like -any other ones: - -.. code-block:: jinja - - {# displays bar #} - {{ foo }} - -The assigned value can be any valid :ref:`Twig expressions -`: - -.. code-block:: jinja - - {% set foo = [1, 2] %} - {% set foo = {'foo': 'bar'} %} - {% set foo = 'foo' ~ 'bar' %} - -Several variables can be assigned in one block: - -.. code-block:: jinja - - {% set foo, bar = 'foo', 'bar' %} - - {# is equivalent to #} - - {% set foo = 'foo' %} - {% set bar = 'bar' %} - -The ``set`` tag can also be used to 'capture' chunks of text: - -.. code-block:: jinja - - {% set foo %} - - {% endset %} - -.. caution:: - - If you enable automatic output escaping, Twig will only consider the - content to be safe when capturing chunks of text. - -.. note:: - - Note that loops are scoped in Twig; therefore a variable declared inside a - ``for`` loop is not accessible outside the loop itself: - - .. code-block:: jinja - - {% for item in list %} - {% set foo = item %} - {% endfor %} - - {# foo is NOT available #} - - If you want to access the variable, just declare it before the loop: - - .. code-block:: jinja - - {% set foo = "" %} - {% for item in list %} - {% set foo = item %} - {% endfor %} - - {# foo is available #} diff --git a/vendor/twig/twig/doc/tags/spaceless.rst b/vendor/twig/twig/doc/tags/spaceless.rst deleted file mode 100644 index b39cb27ef..000000000 --- a/vendor/twig/twig/doc/tags/spaceless.rst +++ /dev/null @@ -1,37 +0,0 @@ -``spaceless`` -============= - -Use the ``spaceless`` tag to remove whitespace *between HTML tags*, not -whitespace within HTML tags or whitespace in plain text: - -.. code-block:: jinja - - {% spaceless %} -
    - foo -
    - {% endspaceless %} - - {# output will be
    foo
    #} - -This tag is not meant to "optimize" the size of the generated HTML content but -merely to avoid extra whitespace between HTML tags to avoid browser rendering -quirks under some circumstances. - -.. tip:: - - If you want to optimize the size of the generated HTML content, gzip - compress the output instead. - -.. tip:: - - If you want to create a tag that actually removes all extra whitespace in - an HTML string, be warned that this is not as easy as it seems to be - (think of ``textarea`` or ``pre`` tags for instance). Using a third-party - library like Tidy is probably a better idea. - -.. tip:: - - For more information on whitespace control, read the - :ref:`dedicated section ` of the documentation and learn how - you can also use the whitespace control modifier on your tags. diff --git a/vendor/twig/twig/doc/tags/use.rst b/vendor/twig/twig/doc/tags/use.rst deleted file mode 100644 index 071b1975e..000000000 --- a/vendor/twig/twig/doc/tags/use.rst +++ /dev/null @@ -1,124 +0,0 @@ -``use`` -======= - -.. versionadded:: 1.1 - Horizontal reuse was added in Twig 1.1. - -.. note:: - - Horizontal reuse is an advanced Twig feature that is hardly ever needed in - regular templates. It is mainly used by projects that need to make - template blocks reusable without using inheritance. - -Template inheritance is one of the most powerful Twig's feature but it is -limited to single inheritance; a template can only extend one other template. -This limitation makes template inheritance simple to understand and easy to -debug: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% block title %}{% endblock %} - {% block content %}{% endblock %} - -Horizontal reuse is a way to achieve the same goal as multiple inheritance, -but without the associated complexity: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% use "blocks.html" %} - - {% block title %}{% endblock %} - {% block content %}{% endblock %} - -The ``use`` statement tells Twig to import the blocks defined in -``blocks.html`` into the current template (it's like macros, but for blocks): - -.. code-block:: jinja - - {# blocks.html #} - - {% block sidebar %}{% endblock %} - -In this example, the ``use`` statement imports the ``sidebar`` block into the -main template. The code is mostly equivalent to the following one (the -imported blocks are not outputted automatically): - -.. code-block:: jinja - - {% extends "base.html" %} - - {% block sidebar %}{% endblock %} - {% block title %}{% endblock %} - {% block content %}{% endblock %} - -.. note:: - - The ``use`` tag only imports a template if it does not extend another - template, if it does not define macros, and if the body is empty. But it - can *use* other templates. - -.. note:: - - Because ``use`` statements are resolved independently of the context - passed to the template, the template reference cannot be an expression. - -The main template can also override any imported block. If the template -already defines the ``sidebar`` block, then the one defined in ``blocks.html`` -is ignored. To avoid name conflicts, you can rename imported blocks: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% use "blocks.html" with sidebar as base_sidebar, title as base_title %} - - {% block sidebar %}{% endblock %} - {% block title %}{% endblock %} - {% block content %}{% endblock %} - -.. versionadded:: 1.3 - The ``parent()`` support was added in Twig 1.3. - -The ``parent()`` function automatically determines the correct inheritance -tree, so it can be used when overriding a block defined in an imported -template: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% use "blocks.html" %} - - {% block sidebar %} - {{ parent() }} - {% endblock %} - - {% block title %}{% endblock %} - {% block content %}{% endblock %} - -In this example, ``parent()`` will correctly call the ``sidebar`` block from -the ``blocks.html`` template. - -.. tip:: - - In Twig 1.2, renaming allows you to simulate inheritance by calling the - "parent" block: - - .. code-block:: jinja - - {% extends "base.html" %} - - {% use "blocks.html" with sidebar as parent_sidebar %} - - {% block sidebar %} - {{ block('parent_sidebar') }} - {% endblock %} - -.. note:: - - You can use as many ``use`` statements as you want in any given template. - If two imported templates define the same block, the latest one wins. diff --git a/vendor/twig/twig/doc/tags/verbatim.rst b/vendor/twig/twig/doc/tags/verbatim.rst deleted file mode 100644 index fe61ca1b0..000000000 --- a/vendor/twig/twig/doc/tags/verbatim.rst +++ /dev/null @@ -1,24 +0,0 @@ -``verbatim`` -============ - -.. versionadded:: 1.12 - The ``verbatim`` tag was added in Twig 1.12 (it was named ``raw`` before). - -The ``verbatim`` tag marks sections as being raw text that should not be -parsed. For example to put Twig syntax as example into a template you can use -this snippet: - -.. code-block:: jinja - - {% verbatim %} -
      - {% for item in seq %} -
    • {{ item }}
    • - {% endfor %} -
    - {% endverbatim %} - -.. note:: - - The ``verbatim`` tag works in the exact same way as the old ``raw`` tag, - but was renamed to avoid confusion with the ``raw`` filter. \ No newline at end of file diff --git a/vendor/twig/twig/doc/templates.rst b/vendor/twig/twig/doc/templates.rst deleted file mode 100644 index 2d59b1a12..000000000 --- a/vendor/twig/twig/doc/templates.rst +++ /dev/null @@ -1,888 +0,0 @@ -Twig for Template Designers -=========================== - -This document describes the syntax and semantics of the template engine and -will be most useful as reference to those creating Twig templates. - -Synopsis --------- - -A template is simply a text file. It can generate any text-based format (HTML, -XML, CSV, LaTeX, etc.). It doesn't have a specific extension, ``.html`` or -``.xml`` are just fine. - -A template contains **variables** or **expressions**, which get replaced with -values when the template is evaluated, and **tags**, which control the logic -of the template. - -Below is a minimal template that illustrates a few basics. We will cover further -details later on: - -.. code-block:: html+jinja - - - - - My Webpage - - - - -

    My Webpage

    - {{ a_variable }} - - - -There are two kinds of delimiters: ``{% ... %}`` and ``{{ ... }}``. The first -one is used to execute statements such as for-loops, the latter prints the -result of an expression to the template. - -IDEs Integration ----------------- - -Many IDEs support syntax highlighting and auto-completion for Twig: - -* *Textmate* via the `Twig bundle`_ -* *Vim* via the `Jinja syntax plugin`_ or the `vim-twig plugin`_ -* *Netbeans* via the `Twig syntax plugin`_ (until 7.1, native as of 7.2) -* *PhpStorm* (native as of 2.1) -* *Eclipse* via the `Twig plugin`_ -* *Sublime Text* via the `Twig bundle`_ -* *GtkSourceView* via the `Twig language definition`_ (used by gedit and other projects) -* *Coda* and *SubEthaEdit* via the `Twig syntax mode`_ -* *Coda 2* via the `other Twig syntax mode`_ -* *Komodo* and *Komodo Edit* via the Twig highlight/syntax check mode -* *Notepad++* via the `Notepad++ Twig Highlighter`_ -* *Emacs* via `web-mode.el`_ -* *Atom* via the `PHP-twig for atom`_ - -Also, `TwigFiddle`_ is an online service that allows you to execute Twig templates -from a browser; it supports all versions of Twig. - -Variables ---------- - -The application passes variables to the templates for manipulation in the -template. Variables may have attributes or elements you can access, -too. The visual representation of a variable depends heavily on the application providing -it. - -You can use a dot (``.``) to access attributes of a variable (methods or -properties of a PHP object, or items of a PHP array), or the so-called -"subscript" syntax (``[]``): - -.. code-block:: jinja - - {{ foo.bar }} - {{ foo['bar'] }} - -When the attribute contains special characters (like ``-`` that would be -interpreted as the minus operator), use the ``attribute`` function instead to -access the variable attribute: - -.. code-block:: jinja - - {# equivalent to the non-working foo.data-foo #} - {{ attribute(foo, 'data-foo') }} - -.. note:: - - It's important to know that the curly braces are *not* part of the - variable but the print statement. When accessing variables inside tags, - don't put the braces around them. - -If a variable or attribute does not exist, you will receive a ``null`` value -when the ``strict_variables`` option is set to ``false``; alternatively, if ``strict_variables`` -is set, Twig will throw an error (see :ref:`environment options`). - -.. sidebar:: Implementation - - For convenience's sake ``foo.bar`` does the following things on the PHP - layer: - - * check if ``foo`` is an array and ``bar`` a valid element; - * if not, and if ``foo`` is an object, check that ``bar`` is a valid property; - * if not, and if ``foo`` is an object, check that ``bar`` is a valid method - (even if ``bar`` is the constructor - use ``__construct()`` instead); - * if not, and if ``foo`` is an object, check that ``getBar`` is a valid method; - * if not, and if ``foo`` is an object, check that ``isBar`` is a valid method; - * if not, return a ``null`` value. - - ``foo['bar']`` on the other hand only works with PHP arrays: - - * check if ``foo`` is an array and ``bar`` a valid element; - * if not, return a ``null`` value. - -.. note:: - - If you want to access a dynamic attribute of a variable, use the - :doc:`attribute` function instead. - -Global Variables -~~~~~~~~~~~~~~~~ - -The following variables are always available in templates: - -* ``_self``: references the current template (deprecated since Twig 1.20); -* ``_context``: references the current context; -* ``_charset``: references the current charset. - -Setting Variables -~~~~~~~~~~~~~~~~~ - -You can assign values to variables inside code blocks. Assignments use the -:doc:`set` tag: - -.. code-block:: jinja - - {% set foo = 'foo' %} - {% set foo = [1, 2] %} - {% set foo = {'foo': 'bar'} %} - -Filters -------- - -Variables can be modified by **filters**. Filters are separated from the -variable by a pipe symbol (``|``) and may have optional arguments in -parentheses. Multiple filters can be chained. The output of one filter is -applied to the next. - -The following example removes all HTML tags from the ``name`` and title-cases -it: - -.. code-block:: jinja - - {{ name|striptags|title }} - -Filters that accept arguments have parentheses around the arguments. This -example will join a list by commas: - -.. code-block:: jinja - - {{ list|join(', ') }} - -To apply a filter on a section of code, wrap it in the -:doc:`filter` tag: - -.. code-block:: jinja - - {% filter upper %} - This text becomes uppercase - {% endfilter %} - -Go to the :doc:`filters` page to learn more about built-in -filters. - -Functions ---------- - -Functions can be called to generate content. Functions are called by their -name followed by parentheses (``()``) and may have arguments. - -For instance, the ``range`` function returns a list containing an arithmetic -progression of integers: - -.. code-block:: jinja - - {% for i in range(0, 3) %} - {{ i }}, - {% endfor %} - -Go to the :doc:`functions` page to learn more about the -built-in functions. - -Named Arguments ---------------- - -.. versionadded:: 1.12 - Support for named arguments was added in Twig 1.12. - -.. code-block:: jinja - - {% for i in range(low=1, high=10, step=2) %} - {{ i }}, - {% endfor %} - -Using named arguments makes your templates more explicit about the meaning of -the values you pass as arguments: - -.. code-block:: jinja - - {{ data|convert_encoding('UTF-8', 'iso-2022-jp') }} - - {# versus #} - - {{ data|convert_encoding(from='iso-2022-jp', to='UTF-8') }} - -Named arguments also allow you to skip some arguments for which you don't want -to change the default value: - -.. code-block:: jinja - - {# the first argument is the date format, which defaults to the global date format if null is passed #} - {{ "now"|date(null, "Europe/Paris") }} - - {# or skip the format value by using a named argument for the time zone #} - {{ "now"|date(timezone="Europe/Paris") }} - -You can also use both positional and named arguments in one call, in which -case positional arguments must always come before named arguments: - -.. code-block:: jinja - - {{ "now"|date('d/m/Y H:i', timezone="Europe/Paris") }} - -.. tip:: - - Each function and filter documentation page has a section where the names - of all arguments are listed when supported. - -Control Structure ------------------ - -A control structure refers to all those things that control the flow of a -program - conditionals (i.e. ``if``/``elseif``/``else``), ``for``-loops, as -well as things like blocks. Control structures appear inside ``{% ... %}`` -blocks. - -For example, to display a list of users provided in a variable called -``users``, use the :doc:`for` tag: - -.. code-block:: jinja - -

    Members

    -
      - {% for user in users %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    - -The :doc:`if` tag can be used to test an expression: - -.. code-block:: jinja - - {% if users|length > 0 %} -
      - {% for user in users %} -
    • {{ user.username|e }}
    • - {% endfor %} -
    - {% endif %} - -Go to the :doc:`tags` page to learn more about the built-in tags. - -Comments --------- - -To comment-out part of a line in a template, use the comment syntax ``{# ... -#}``. This is useful for debugging or to add information for other template -designers or yourself: - -.. code-block:: jinja - - {# note: disabled template because we no longer use this - {% for user in users %} - ... - {% endfor %} - #} - -Including other Templates -------------------------- - -The :doc:`include` tag is useful to include a template and -return the rendered content of that template into the current one: - -.. code-block:: jinja - - {% include 'sidebar.html' %} - -Per default included templates are passed the current context. - -The context that is passed to the included template includes variables defined -in the template: - -.. code-block:: jinja - - {% for box in boxes %} - {% include "render_box.html" %} - {% endfor %} - -The included template ``render_box.html`` is able to access ``box``. - -The filename of the template depends on the template loader. For instance, the -``Twig_Loader_Filesystem`` allows you to access other templates by giving the -filename. You can access templates in subdirectories with a slash: - -.. code-block:: jinja - - {% include "sections/articles/sidebar.html" %} - -This behavior depends on the application embedding Twig. - -Template Inheritance --------------------- - -The most powerful part of Twig is template inheritance. Template inheritance -allows you to build a base "skeleton" template that contains all the common -elements of your site and defines **blocks** that child templates can -override. - -Sounds complicated but it is very basic. It's easier to understand it by -starting with an example. - -Let's define a base template, ``base.html``, which defines a simple HTML -skeleton document that you might use for a simple two-column page: - -.. code-block:: html+jinja - - - - - {% block head %} - - {% block title %}{% endblock %} - My Webpage - {% endblock %} - - -
    {% block content %}{% endblock %}
    - - - - -In this example, the :doc:`block` tags define four blocks that -child templates can fill in. All the ``block`` tag does is to tell the -template engine that a child template may override those portions of the -template. - -A child template might look like this: - -.. code-block:: jinja - - {% extends "base.html" %} - - {% block title %}Index{% endblock %} - {% block head %} - {{ parent() }} - - {% endblock %} - {% block content %} -

    Index

    -

    - Welcome to my awesome homepage. -

    - {% endblock %} - -The :doc:`extends` tag is the key here. It tells the template -engine that this template "extends" another template. When the template system -evaluates this template, first it locates the parent. The extends tag should -be the first tag in the template. - -Note that since the child template doesn't define the ``footer`` block, the -value from the parent template is used instead. - -It's possible to render the contents of the parent block by using the -:doc:`parent` function. This gives back the results of the -parent block: - -.. code-block:: jinja - - {% block sidebar %} -

    Table Of Contents

    - ... - {{ parent() }} - {% endblock %} - -.. tip:: - - The documentation page for the :doc:`extends` tag describes - more advanced features like block nesting, scope, dynamic inheritance, and - conditional inheritance. - -.. note:: - - Twig also supports multiple inheritance with the so called horizontal reuse - with the help of the :doc:`use` tag. This is an advanced feature - hardly ever needed in regular templates. - -HTML Escaping -------------- - -When generating HTML from templates, there's always a risk that a variable -will include characters that affect the resulting HTML. There are two -approaches: manually escaping each variable or automatically escaping -everything by default. - -Twig supports both, automatic escaping is enabled by default. - -.. note:: - - Automatic escaping is only supported if the *escaper* extension has been - enabled (which is the default). - -Working with Manual Escaping -~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -If manual escaping is enabled, it is **your** responsibility to escape -variables if needed. What to escape? Any variable you don't trust. - -Escaping works by piping the variable through the -:doc:`escape` or ``e`` filter: - -.. code-block:: jinja - - {{ user.username|e }} - -By default, the ``escape`` filter uses the ``html`` strategy, but depending on -the escaping context, you might want to explicitly use any other available -strategies: - -.. code-block:: jinja - - {{ user.username|e('js') }} - {{ user.username|e('css') }} - {{ user.username|e('url') }} - {{ user.username|e('html_attr') }} - -Working with Automatic Escaping -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -Whether automatic escaping is enabled or not, you can mark a section of a -template to be escaped or not by using the :doc:`autoescape` -tag: - -.. code-block:: jinja - - {% autoescape %} - Everything will be automatically escaped in this block (using the HTML strategy) - {% endautoescape %} - -By default, auto-escaping uses the ``html`` escaping strategy. If you output -variables in other contexts, you need to explicitly escape them with the -appropriate escaping strategy: - -.. code-block:: jinja - - {% autoescape 'js' %} - Everything will be automatically escaped in this block (using the JS strategy) - {% endautoescape %} - -Escaping --------- - -It is sometimes desirable or even necessary to have Twig ignore parts it would -otherwise handle as variables or blocks. For example if the default syntax is -used and you want to use ``{{`` as raw string in the template and not start a -variable you have to use a trick. - -The easiest way is to output the variable delimiter (``{{``) by using a variable -expression: - -.. code-block:: jinja - - {{ '{{' }} - -For bigger sections it makes sense to mark a block -:doc:`verbatim`. - -Macros ------- - -.. versionadded:: 1.12 - Support for default argument values was added in Twig 1.12. - -Macros are comparable with functions in regular programming languages. They -are useful to reuse often used HTML fragments to not repeat yourself. - -A macro is defined via the :doc:`macro` tag. Here is a small example -(subsequently called ``forms.html``) of a macro that renders a form element: - -.. code-block:: jinja - - {% macro input(name, value, type, size) %} - - {% endmacro %} - -Macros can be defined in any template, and need to be "imported" via the -:doc:`import` tag before being used: - -.. code-block:: jinja - - {% import "forms.html" as forms %} - -

    {{ forms.input('username') }}

    - -Alternatively, you can import individual macro names from a template into the -current namespace via the :doc:`from` tag and optionally alias them: - -.. code-block:: jinja - - {% from 'forms.html' import input as input_field %} - -
    -
    Username
    -
    {{ input_field('username') }}
    -
    Password
    -
    {{ input_field('password', '', 'password') }}
    -
    - -A default value can also be defined for macro arguments when not provided in a -macro call: - -.. code-block:: jinja - - {% macro input(name, value = "", type = "text", size = 20) %} - - {% endmacro %} - -If extra positional arguments are passed to a macro call, they end up in the -special ``varargs`` variable as a list of values. - -.. _twig-expressions: - -Expressions ------------ - -Twig allows expressions everywhere. These work very similar to regular PHP and -even if you're not working with PHP you should feel comfortable with it. - -.. note:: - - The operator precedence is as follows, with the lowest-precedence - operators listed first: ``b-and``, ``b-xor``, ``b-or``, ``or``, ``and``, - ``==``, ``!=``, ``<``, ``>``, ``>=``, ``<=``, ``in``, ``matches``, - ``starts with``, ``ends with``, ``..``, ``+``, ``-``, ``~``, ``*``, ``/``, - ``//``, ``%``, ``is``, ``**``, ``|``, ``[]``, and ``.``: - - .. code-block:: jinja - - {% set greeting = 'Hello ' %} - {% set name = 'Fabien' %} - - {{ greeting ~ name|lower }} {# Hello fabien #} - - {# use parenthesis to change precedence #} - {{ (greeting ~ name)|lower }} {# hello fabien #} - -Literals -~~~~~~~~ - -.. versionadded:: 1.5 - Support for hash keys as names and expressions was added in Twig 1.5. - -The simplest form of expressions are literals. Literals are representations -for PHP types such as strings, numbers, and arrays. The following literals -exist: - -* ``"Hello World"``: Everything between two double or single quotes is a - string. They are useful whenever you need a string in the template (for - example as arguments to function calls, filters or just to extend or include - a template). A string can contain a delimiter if it is preceded by a - backslash (``\``) -- like in ``'It\'s good'``. - -* ``42`` / ``42.23``: Integers and floating point numbers are created by just - writing the number down. If a dot is present the number is a float, - otherwise an integer. - -* ``["foo", "bar"]``: Arrays are defined by a sequence of expressions - separated by a comma (``,``) and wrapped with squared brackets (``[]``). - -* ``{"foo": "bar"}``: Hashes are defined by a list of keys and values - separated by a comma (``,``) and wrapped with curly braces (``{}``): - - .. code-block:: jinja - - {# keys as string #} - { 'foo': 'foo', 'bar': 'bar' } - - {# keys as names (equivalent to the previous hash) -- as of Twig 1.5 #} - { foo: 'foo', bar: 'bar' } - - {# keys as integer #} - { 2: 'foo', 4: 'bar' } - - {# keys as expressions (the expression must be enclosed into parentheses) -- as of Twig 1.5 #} - { (1 + 1): 'foo', (a ~ 'b'): 'bar' } - -* ``true`` / ``false``: ``true`` represents the true value, ``false`` - represents the false value. - -* ``null``: ``null`` represents no specific value. This is the value returned - when a variable does not exist. ``none`` is an alias for ``null``. - -Arrays and hashes can be nested: - -.. code-block:: jinja - - {% set foo = [1, {"foo": "bar"}] %} - -.. tip:: - - Using double-quoted or single-quoted strings has no impact on performance - but string interpolation is only supported in double-quoted strings. - -Math -~~~~ - -Twig allows you to calculate with values. This is rarely useful in templates -but exists for completeness' sake. The following operators are supported: - -* ``+``: Adds two objects together (the operands are casted to numbers). ``{{ - 1 + 1 }}`` is ``2``. - -* ``-``: Subtracts the second number from the first one. ``{{ 3 - 2 }}`` is - ``1``. - -* ``/``: Divides two numbers. The returned value will be a floating point - number. ``{{ 1 / 2 }}`` is ``{{ 0.5 }}``. - -* ``%``: Calculates the remainder of an integer division. ``{{ 11 % 7 }}`` is - ``4``. - -* ``//``: Divides two numbers and returns the floored integer result. ``{{ 20 - // 7 }}`` is ``2``, ``{{ -20 // 7 }}`` is ``-3`` (this is just syntactic - sugar for the :doc:`round` filter). - -* ``*``: Multiplies the left operand with the right one. ``{{ 2 * 2 }}`` would - return ``4``. - -* ``**``: Raises the left operand to the power of the right operand. ``{{ 2 ** - 3 }}`` would return ``8``. - -Logic -~~~~~ - -You can combine multiple expressions with the following operators: - -* ``and``: Returns true if the left and the right operands are both true. - -* ``or``: Returns true if the left or the right operand is true. - -* ``not``: Negates a statement. - -* ``(expr)``: Groups an expression. - -.. note:: - - Twig also support bitwise operators (``b-and``, ``b-xor``, and ``b-or``). - -.. note:: - - Operators are case sensitive. - -Comparisons -~~~~~~~~~~~ - -The following comparison operators are supported in any expression: ``==``, -``!=``, ``<``, ``>``, ``>=``, and ``<=``. - -You can also check if a string ``starts with`` or ``ends with`` another -string: - -.. code-block:: jinja - - {% if 'Fabien' starts with 'F' %} - {% endif %} - - {% if 'Fabien' ends with 'n' %} - {% endif %} - -.. note:: - - For complex string comparisons, the ``matches`` operator allows you to use - `regular expressions`_: - - .. code-block:: jinja - - {% if phone matches '/^[\\d\\.]+$/' %} - {% endif %} - -Containment Operator -~~~~~~~~~~~~~~~~~~~~ - -The ``in`` operator performs containment test. - -It returns ``true`` if the left operand is contained in the right: - -.. code-block:: jinja - - {# returns true #} - - {{ 1 in [1, 2, 3] }} - - {{ 'cd' in 'abcde' }} - -.. tip:: - - You can use this filter to perform a containment test on strings, arrays, - or objects implementing the ``Traversable`` interface. - -To perform a negative test, use the ``not in`` operator: - -.. code-block:: jinja - - {% if 1 not in [1, 2, 3] %} - - {# is equivalent to #} - {% if not (1 in [1, 2, 3]) %} - -Test Operator -~~~~~~~~~~~~~ - -The ``is`` operator performs tests. Tests can be used to test a variable against -a common expression. The right operand is name of the test: - -.. code-block:: jinja - - {# find out if a variable is odd #} - - {{ name is odd }} - -Tests can accept arguments too: - -.. code-block:: jinja - - {% if post.status is constant('Post::PUBLISHED') %} - -Tests can be negated by using the ``is not`` operator: - -.. code-block:: jinja - - {% if post.status is not constant('Post::PUBLISHED') %} - - {# is equivalent to #} - {% if not (post.status is constant('Post::PUBLISHED')) %} - -Go to the :doc:`tests` page to learn more about the built-in -tests. - -Other Operators -~~~~~~~~~~~~~~~ - -.. versionadded:: 1.12.0 - Support for the extended ternary operator was added in Twig 1.12.0. - -The following operators are very useful but don't fit into any of the other -categories: - -* ``..``: Creates a sequence based on the operand before and after the - operator (this is just syntactic sugar for the :doc:`range` - function). - -* ``|``: Applies a filter. - -* ``~``: Converts all operands into strings and concatenates them. ``{{ "Hello - " ~ name ~ "!" }}`` would return (assuming ``name`` is ``'John'``) ``Hello - John!``. - -* ``.``, ``[]``: Gets an attribute of an object. - -* ``?:``: The ternary operator: - - .. code-block:: jinja - - {{ foo ? 'yes' : 'no' }} - - {# as of Twig 1.12.0 #} - {{ foo ?: 'no' }} is the same as {{ foo ? foo : 'no' }} - {{ foo ? 'yes' }} is the same as {{ foo ? 'yes' : '' }} - -String Interpolation -~~~~~~~~~~~~~~~~~~~~ - -.. versionadded:: 1.5 - String interpolation was added in Twig 1.5. - -String interpolation (`#{expression}`) allows any valid expression to appear -within a *double-quoted string*. The result of evaluating that expression is -inserted into the string: - -.. code-block:: jinja - - {{ "foo #{bar} baz" }} - {{ "foo #{1 + 2} baz" }} - -.. _templates-whitespace-control: - -Whitespace Control ------------------- - -.. versionadded:: 1.1 - Tag level whitespace control was added in Twig 1.1. - -The first newline after a template tag is removed automatically (like in PHP.) -Whitespace is not further modified by the template engine, so each whitespace -(spaces, tabs, newlines etc.) is returned unchanged. - -Use the ``spaceless`` tag to remove whitespace *between HTML tags*: - -.. code-block:: jinja - - {% spaceless %} -
    - foo bar -
    - {% endspaceless %} - - {# output will be
    foo bar
    #} - -In addition to the spaceless tag you can also control whitespace on a per tag -level. By using the whitespace control modifier on your tags, you can trim -leading and or trailing whitespace: - -.. code-block:: jinja - - {% set value = 'no spaces' %} - {#- No leading/trailing whitespace -#} - {%- if true -%} - {{- value -}} - {%- endif -%} - - {# output 'no spaces' #} - -The above sample shows the default whitespace control modifier, and how you can -use it to remove whitespace around tags. Trimming space will consume all whitespace -for that side of the tag. It is possible to use whitespace trimming on one side -of a tag: - -.. code-block:: jinja - - {% set value = 'no spaces' %} -
  • {{- value }}
  • - - {# outputs '
  • no spaces
  • ' #} - -Extensions ----------- - -Twig can be easily extended. - -If you are looking for new tags, filters, or functions, have a look at the Twig official -`extension repository`_. - -If you want to create your own, read the :ref:`Creating an -Extension` chapter. - -.. _`Twig bundle`: https://github.com/Anomareh/PHP-Twig.tmbundle -.. _`Jinja syntax plugin`: http://jinja.pocoo.org/docs/integration/#vim -.. _`vim-twig plugin`: https://github.com/evidens/vim-twig -.. _`Twig syntax plugin`: http://plugins.netbeans.org/plugin/37069/php-twig -.. _`Twig plugin`: https://github.com/pulse00/Twig-Eclipse-Plugin -.. _`Twig language definition`: https://github.com/gabrielcorpse/gedit-twig-template-language -.. _`extension repository`: http://github.com/twigphp/Twig-extensions -.. _`Twig syntax mode`: https://github.com/bobthecow/Twig-HTML.mode -.. _`other Twig syntax mode`: https://github.com/muxx/Twig-HTML.mode -.. _`Notepad++ Twig Highlighter`: https://github.com/Banane9/notepadplusplus-twig -.. _`web-mode.el`: http://web-mode.org/ -.. _`regular expressions`: http://php.net/manual/en/pcre.pattern.php -.. _`PHP-twig for atom`: https://github.com/reesef/php-twig -.. _`TwigFiddle`: http://twigfiddle.com/ diff --git a/vendor/twig/twig/doc/tests/constant.rst b/vendor/twig/twig/doc/tests/constant.rst deleted file mode 100644 index 8d0724a80..000000000 --- a/vendor/twig/twig/doc/tests/constant.rst +++ /dev/null @@ -1,22 +0,0 @@ -``constant`` -============ - -.. versionadded: 1.13.1 - constant now accepts object instances as the second argument. - -``constant`` checks if a variable has the exact same value as a constant. You -can use either global constants or class constants: - -.. code-block:: jinja - - {% if post.status is constant('Post::PUBLISHED') %} - the status attribute is exactly the same as Post::PUBLISHED - {% endif %} - -You can test constants from object instances as well: - -.. code-block:: jinja - - {% if post.status is constant('PUBLISHED', post) %} - the status attribute is exactly the same as Post::PUBLISHED - {% endif %} diff --git a/vendor/twig/twig/doc/tests/defined.rst b/vendor/twig/twig/doc/tests/defined.rst deleted file mode 100644 index 702ce7256..000000000 --- a/vendor/twig/twig/doc/tests/defined.rst +++ /dev/null @@ -1,30 +0,0 @@ -``defined`` -=========== - -``defined`` checks if a variable is defined in the current context. This is very -useful if you use the ``strict_variables`` option: - -.. code-block:: jinja - - {# defined works with variable names #} - {% if foo is defined %} - ... - {% endif %} - - {# and attributes on variables names #} - {% if foo.bar is defined %} - ... - {% endif %} - - {% if foo['bar'] is defined %} - ... - {% endif %} - -When using the ``defined`` test on an expression that uses variables in some -method calls, be sure that they are all defined first: - -.. code-block:: jinja - - {% if var is defined and foo.method(var) is defined %} - ... - {% endif %} diff --git a/vendor/twig/twig/doc/tests/divisibleby.rst b/vendor/twig/twig/doc/tests/divisibleby.rst deleted file mode 100644 index 6c693b2b4..000000000 --- a/vendor/twig/twig/doc/tests/divisibleby.rst +++ /dev/null @@ -1,14 +0,0 @@ -``divisible by`` -================ - -.. versionadded:: 1.14.2 - The ``divisible by`` test was added in Twig 1.14.2 as an alias for - ``divisibleby``. - -``divisible by`` checks if a variable is divisible by a number: - -.. code-block:: jinja - - {% if loop.index is divisible by(3) %} - ... - {% endif %} diff --git a/vendor/twig/twig/doc/tests/empty.rst b/vendor/twig/twig/doc/tests/empty.rst deleted file mode 100644 index e5b55999d..000000000 --- a/vendor/twig/twig/doc/tests/empty.rst +++ /dev/null @@ -1,11 +0,0 @@ -``empty`` -========= - -``empty`` checks if a variable is empty: - -.. code-block:: jinja - - {# evaluates to true if the foo variable is null, false, an empty array, or the empty string #} - {% if foo is empty %} - ... - {% endif %} diff --git a/vendor/twig/twig/doc/tests/even.rst b/vendor/twig/twig/doc/tests/even.rst deleted file mode 100644 index 6ab5cc39a..000000000 --- a/vendor/twig/twig/doc/tests/even.rst +++ /dev/null @@ -1,10 +0,0 @@ -``even`` -======== - -``even`` returns ``true`` if the given number is even: - -.. code-block:: jinja - - {{ var is even }} - -.. seealso:: :doc:`odd<../tests/odd>` diff --git a/vendor/twig/twig/doc/tests/index.rst b/vendor/twig/twig/doc/tests/index.rst deleted file mode 100644 index c63208ee7..000000000 --- a/vendor/twig/twig/doc/tests/index.rst +++ /dev/null @@ -1,15 +0,0 @@ -Tests -===== - -.. toctree:: - :maxdepth: 1 - - constant - defined - divisibleby - empty - even - iterable - null - odd - sameas diff --git a/vendor/twig/twig/doc/tests/iterable.rst b/vendor/twig/twig/doc/tests/iterable.rst deleted file mode 100644 index 89a172f74..000000000 --- a/vendor/twig/twig/doc/tests/iterable.rst +++ /dev/null @@ -1,19 +0,0 @@ -``iterable`` -============ - -.. versionadded:: 1.7 - The iterable test was added in Twig 1.7. - -``iterable`` checks if a variable is an array or a traversable object: - -.. code-block:: jinja - - {# evaluates to true if the foo variable is iterable #} - {% if users is iterable %} - {% for user in users %} - Hello {{ user }}! - {% endfor %} - {% else %} - {# users is probably a string #} - Hello {{ users }}! - {% endif %} diff --git a/vendor/twig/twig/doc/tests/null.rst b/vendor/twig/twig/doc/tests/null.rst deleted file mode 100644 index 44eec62e5..000000000 --- a/vendor/twig/twig/doc/tests/null.rst +++ /dev/null @@ -1,12 +0,0 @@ -``null`` -======== - -``null`` returns ``true`` if the variable is ``null``: - -.. code-block:: jinja - - {{ var is null }} - -.. note:: - - ``none`` is an alias for ``null``. diff --git a/vendor/twig/twig/doc/tests/odd.rst b/vendor/twig/twig/doc/tests/odd.rst deleted file mode 100644 index 9eece7776..000000000 --- a/vendor/twig/twig/doc/tests/odd.rst +++ /dev/null @@ -1,10 +0,0 @@ -``odd`` -======= - -``odd`` returns ``true`` if the given number is odd: - -.. code-block:: jinja - - {{ var is odd }} - -.. seealso:: :doc:`even<../tests/even>` diff --git a/vendor/twig/twig/doc/tests/sameas.rst b/vendor/twig/twig/doc/tests/sameas.rst deleted file mode 100644 index 16f904d5c..000000000 --- a/vendor/twig/twig/doc/tests/sameas.rst +++ /dev/null @@ -1,14 +0,0 @@ -``same as`` -=========== - -.. versionadded:: 1.14.2 - The ``same as`` test was added in Twig 1.14.2 as an alias for ``sameas``. - -``same as`` checks if a variable is the same as another variable. -This is the equivalent to ``===`` in PHP: - -.. code-block:: jinja - - {% if foo.attribute is same as(false) %} - the foo attribute really is the 'false' PHP value - {% endif %} diff --git a/vendor/twig/twig/ext/twig/.gitignore b/vendor/twig/twig/ext/twig/.gitignore deleted file mode 100644 index 56ea76cc2..000000000 --- a/vendor/twig/twig/ext/twig/.gitignore +++ /dev/null @@ -1,30 +0,0 @@ -*.sw* -.deps -Makefile -Makefile.fragments -Makefile.global -Makefile.objects -acinclude.m4 -aclocal.m4 -build/ -config.cache -config.guess -config.h -config.h.in -config.log -config.nice -config.status -config.sub -configure -configure.in -install-sh -libtool -ltmain.sh -missing -mkinstalldirs -run-tests.php -twig.loT -.libs/ -modules/ -twig.la -twig.lo diff --git a/vendor/twig/twig/ext/twig/config.m4 b/vendor/twig/twig/ext/twig/config.m4 deleted file mode 100644 index 83486be4c..000000000 --- a/vendor/twig/twig/ext/twig/config.m4 +++ /dev/null @@ -1,8 +0,0 @@ -dnl config.m4 for extension twig - -PHP_ARG_ENABLE(twig, whether to enable twig support, -[ --enable-twig Enable twig support]) - -if test "$PHP_TWIG" != "no"; then - PHP_NEW_EXTENSION(twig, twig.c, $ext_shared) -fi diff --git a/vendor/twig/twig/ext/twig/config.w32 b/vendor/twig/twig/ext/twig/config.w32 deleted file mode 100644 index cb287b99b..000000000 --- a/vendor/twig/twig/ext/twig/config.w32 +++ /dev/null @@ -1,8 +0,0 @@ -// vim:ft=javascript - -ARG_ENABLE("twig", "Twig support", "no"); - -if (PHP_TWIG != "no") { - AC_DEFINE('HAVE_TWIG', 1); - EXTENSION('twig', 'twig.c'); -} diff --git a/vendor/twig/twig/ext/twig/php_twig.h b/vendor/twig/twig/ext/twig/php_twig.h deleted file mode 100644 index 359cd43b2..000000000 --- a/vendor/twig/twig/ext/twig/php_twig.h +++ /dev/null @@ -1,35 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | Twig Extension | - +----------------------------------------------------------------------+ - | Copyright (c) 2011 Derick Rethans | - +----------------------------------------------------------------------+ - | Redistribution and use in source and binary forms, with or without | - | modification, are permitted provided that the conditions mentioned | - | in the accompanying LICENSE file are met (BSD-3-Clause). | - +----------------------------------------------------------------------+ - | Author: Derick Rethans | - +----------------------------------------------------------------------+ - */ - -#ifndef PHP_TWIG_H -#define PHP_TWIG_H - -#define PHP_TWIG_VERSION "1.22.2" - -#include "php.h" - -extern zend_module_entry twig_module_entry; -#define phpext_twig_ptr &twig_module_entry -#ifndef PHP_WIN32 -zend_module_entry *get_module(void); -#endif - -#ifdef ZTS -#include "TSRM.h" -#endif - -PHP_FUNCTION(twig_template_get_attributes); -PHP_RSHUTDOWN_FUNCTION(twig); - -#endif diff --git a/vendor/twig/twig/ext/twig/twig.c b/vendor/twig/twig/ext/twig/twig.c deleted file mode 100644 index 92d1addc7..000000000 --- a/vendor/twig/twig/ext/twig/twig.c +++ /dev/null @@ -1,1127 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | Twig Extension | - +----------------------------------------------------------------------+ - | Copyright (c) 2011 Derick Rethans | - +----------------------------------------------------------------------+ - | Redistribution and use in source and binary forms, with or without | - | modification, are permitted provided that the conditions mentioned | - | in the accompanying LICENSE file are met (BSD-3-Clause). | - +----------------------------------------------------------------------+ - | Author: Derick Rethans | - +----------------------------------------------------------------------+ - */ - -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#include "php.h" -#include "php_twig.h" -#include "ext/standard/php_var.h" -#include "ext/standard/php_string.h" -#include "ext/standard/php_smart_str.h" -#include "ext/spl/spl_exceptions.h" - -#include "Zend/zend_object_handlers.h" -#include "Zend/zend_interfaces.h" -#include "Zend/zend_exceptions.h" - -#ifndef Z_ADDREF_P -#define Z_ADDREF_P(pz) (pz)->refcount++ -#endif - -#define FREE_DTOR(z) \ - zval_dtor(z); \ - efree(z); - -#if PHP_VERSION_ID >= 50300 - #define APPLY_TSRMLS_DC TSRMLS_DC - #define APPLY_TSRMLS_CC TSRMLS_CC - #define APPLY_TSRMLS_FETCH() -#else - #define APPLY_TSRMLS_DC - #define APPLY_TSRMLS_CC - #define APPLY_TSRMLS_FETCH() TSRMLS_FETCH() -#endif - -ZEND_BEGIN_ARG_INFO_EX(twig_template_get_attribute_args, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 6) - ZEND_ARG_INFO(0, template) - ZEND_ARG_INFO(0, object) - ZEND_ARG_INFO(0, item) - ZEND_ARG_INFO(0, arguments) - ZEND_ARG_INFO(0, type) - ZEND_ARG_INFO(0, isDefinedTest) -ZEND_END_ARG_INFO() - -#ifndef PHP_FE_END -#define PHP_FE_END { NULL, NULL, NULL} -#endif - -static const zend_function_entry twig_functions[] = { - PHP_FE(twig_template_get_attributes, twig_template_get_attribute_args) - PHP_FE_END -}; - -PHP_RSHUTDOWN_FUNCTION(twig) -{ -#if ZEND_DEBUG - CG(unclean_shutdown) = 0; /* get rid of PHPUnit's exit() and report memleaks */ -#endif - return SUCCESS; -} - -zend_module_entry twig_module_entry = { - STANDARD_MODULE_HEADER, - "twig", - twig_functions, - NULL, - NULL, - NULL, - PHP_RSHUTDOWN(twig), - NULL, - PHP_TWIG_VERSION, - STANDARD_MODULE_PROPERTIES -}; - - -#ifdef COMPILE_DL_TWIG -ZEND_GET_MODULE(twig) -#endif - -static int TWIG_ARRAY_KEY_EXISTS(zval *array, zval *key) -{ - if (Z_TYPE_P(array) != IS_ARRAY) { - return 0; - } - - switch (Z_TYPE_P(key)) { - case IS_NULL: - return zend_hash_exists(Z_ARRVAL_P(array), "", 1); - - case IS_BOOL: - case IS_DOUBLE: - convert_to_long(key); - case IS_LONG: - return zend_hash_index_exists(Z_ARRVAL_P(array), Z_LVAL_P(key)); - - default: - convert_to_string(key); - return zend_symtable_exists(Z_ARRVAL_P(array), Z_STRVAL_P(key), Z_STRLEN_P(key) + 1); - } -} - -static int TWIG_INSTANCE_OF(zval *object, zend_class_entry *interface TSRMLS_DC) -{ - if (Z_TYPE_P(object) != IS_OBJECT) { - return 0; - } - return instanceof_function(Z_OBJCE_P(object), interface TSRMLS_CC); -} - -static int TWIG_INSTANCE_OF_USERLAND(zval *object, char *interface TSRMLS_DC) -{ - zend_class_entry **pce; - if (Z_TYPE_P(object) != IS_OBJECT) { - return 0; - } - if (zend_lookup_class(interface, strlen(interface), &pce TSRMLS_CC) == FAILURE) { - return 0; - } - return instanceof_function(Z_OBJCE_P(object), *pce TSRMLS_CC); -} - -static zval *TWIG_GET_ARRAYOBJECT_ELEMENT(zval *object, zval *offset TSRMLS_DC) -{ - zend_class_entry *ce = Z_OBJCE_P(object); - zval *retval; - - if (Z_TYPE_P(object) == IS_OBJECT) { - SEPARATE_ARG_IF_REF(offset); - zend_call_method_with_1_params(&object, ce, NULL, "offsetget", &retval, offset); - - zval_ptr_dtor(&offset); - - if (!retval) { - if (!EG(exception)) { - zend_error(E_ERROR, "Undefined offset for object of type %s used as array", ce->name); - } - return NULL; - } - - return retval; - } - return NULL; -} - -static int TWIG_ISSET_ARRAYOBJECT_ELEMENT(zval *object, zval *offset TSRMLS_DC) -{ - zend_class_entry *ce = Z_OBJCE_P(object); - zval *retval; - - if (Z_TYPE_P(object) == IS_OBJECT) { - SEPARATE_ARG_IF_REF(offset); - zend_call_method_with_1_params(&object, ce, NULL, "offsetexists", &retval, offset); - - zval_ptr_dtor(&offset); - - if (!retval) { - if (!EG(exception)) { - zend_error(E_ERROR, "Undefined offset for object of type %s used as array", ce->name); - } - return 0; - } - - return (retval && Z_TYPE_P(retval) == IS_BOOL && Z_LVAL_P(retval)); - } - return 0; -} - -static char *TWIG_STRTOLOWER(const char *str, int str_len) -{ - char *item_dup; - - item_dup = estrndup(str, str_len); - php_strtolower(item_dup, str_len); - return item_dup; -} - -static zval *TWIG_CALL_USER_FUNC_ARRAY(zval *object, char *function, zval *arguments TSRMLS_DC) -{ - zend_fcall_info fci; - zval ***args = NULL; - int arg_count = 0; - HashTable *table; - HashPosition pos; - int i = 0; - zval *retval_ptr; - zval *zfunction; - - if (arguments) { - table = HASH_OF(arguments); - args = safe_emalloc(sizeof(zval **), table->nNumOfElements, 0); - - zend_hash_internal_pointer_reset_ex(table, &pos); - - while (zend_hash_get_current_data_ex(table, (void **)&args[i], &pos) == SUCCESS) { - i++; - zend_hash_move_forward_ex(table, &pos); - } - arg_count = table->nNumOfElements; - } - - MAKE_STD_ZVAL(zfunction); - ZVAL_STRING(zfunction, function, 1); - fci.size = sizeof(fci); - fci.function_table = EG(function_table); - fci.function_name = zfunction; - fci.symbol_table = NULL; -#if PHP_VERSION_ID >= 50300 - fci.object_ptr = object; -#else - fci.object_pp = &object; -#endif - fci.retval_ptr_ptr = &retval_ptr; - fci.param_count = arg_count; - fci.params = args; - fci.no_separation = 0; - - if (zend_call_function(&fci, NULL TSRMLS_CC) == FAILURE) { - ALLOC_INIT_ZVAL(retval_ptr); - ZVAL_BOOL(retval_ptr, 0); - } - - if (args) { - efree(fci.params); - } - FREE_DTOR(zfunction); - return retval_ptr; -} - -static int TWIG_CALL_BOOLEAN(zval *object, char *functionName TSRMLS_DC) -{ - zval *ret; - int res; - - ret = TWIG_CALL_USER_FUNC_ARRAY(object, functionName, NULL TSRMLS_CC); - res = Z_LVAL_P(ret); - zval_ptr_dtor(&ret); - return res; -} - -static zval *TWIG_GET_STATIC_PROPERTY(zval *class, char *prop_name TSRMLS_DC) -{ - zval **tmp_zval; - zend_class_entry *ce; - - if (class == NULL || Z_TYPE_P(class) != IS_OBJECT) { - return NULL; - } - - ce = zend_get_class_entry(class TSRMLS_CC); -#if PHP_VERSION_ID >= 50400 - tmp_zval = zend_std_get_static_property(ce, prop_name, strlen(prop_name), 0, NULL TSRMLS_CC); -#else - tmp_zval = zend_std_get_static_property(ce, prop_name, strlen(prop_name), 0 TSRMLS_CC); -#endif - return *tmp_zval; -} - -static zval *TWIG_GET_ARRAY_ELEMENT_ZVAL(zval *class, zval *prop_name TSRMLS_DC) -{ - zval **tmp_zval; - - if (class == NULL || Z_TYPE_P(class) != IS_ARRAY) { - if (class != NULL && Z_TYPE_P(class) == IS_OBJECT && TWIG_INSTANCE_OF(class, zend_ce_arrayaccess TSRMLS_CC)) { - // array access object - return TWIG_GET_ARRAYOBJECT_ELEMENT(class, prop_name TSRMLS_CC); - } - return NULL; - } - - switch(Z_TYPE_P(prop_name)) { - case IS_NULL: - zend_hash_find(HASH_OF(class), "", 1, (void**) &tmp_zval); - return *tmp_zval; - - case IS_BOOL: - case IS_DOUBLE: - convert_to_long(prop_name); - case IS_LONG: - zend_hash_index_find(HASH_OF(class), Z_LVAL_P(prop_name), (void **) &tmp_zval); - return *tmp_zval; - - case IS_STRING: - zend_symtable_find(HASH_OF(class), Z_STRVAL_P(prop_name), Z_STRLEN_P(prop_name) + 1, (void**) &tmp_zval); - return *tmp_zval; - } - - return NULL; -} - -static zval *TWIG_GET_ARRAY_ELEMENT(zval *class, char *prop_name, int prop_name_length TSRMLS_DC) -{ - zval **tmp_zval; - - if (class == NULL/* || Z_TYPE_P(class) != IS_ARRAY*/) { - return NULL; - } - - if (class != NULL && Z_TYPE_P(class) == IS_OBJECT && TWIG_INSTANCE_OF(class, zend_ce_arrayaccess TSRMLS_CC)) { - // array access object - zval *tmp_name_zval; - zval *tmp_ret_zval; - - ALLOC_INIT_ZVAL(tmp_name_zval); - ZVAL_STRING(tmp_name_zval, prop_name, 1); - tmp_ret_zval = TWIG_GET_ARRAYOBJECT_ELEMENT(class, tmp_name_zval TSRMLS_CC); - FREE_DTOR(tmp_name_zval); - return tmp_ret_zval; - } - - if (zend_symtable_find(HASH_OF(class), prop_name, prop_name_length+1, (void**)&tmp_zval) == SUCCESS) { - return *tmp_zval; - } - return NULL; -} - -static zval *TWIG_PROPERTY(zval *object, zval *propname TSRMLS_DC) -{ - zval *tmp = NULL; - - if (Z_OBJ_HT_P(object)->read_property) { -#if PHP_VERSION_ID >= 50400 - tmp = Z_OBJ_HT_P(object)->read_property(object, propname, BP_VAR_IS, NULL TSRMLS_CC); -#else - tmp = Z_OBJ_HT_P(object)->read_property(object, propname, BP_VAR_IS TSRMLS_CC); -#endif - if (tmp == EG(uninitialized_zval_ptr)) { - ZVAL_NULL(tmp); - } - } - return tmp; -} - -static int TWIG_HAS_PROPERTY(zval *object, zval *propname TSRMLS_DC) -{ - if (Z_OBJ_HT_P(object)->has_property) { -#if PHP_VERSION_ID >= 50400 - return Z_OBJ_HT_P(object)->has_property(object, propname, 0, NULL TSRMLS_CC); -#else - return Z_OBJ_HT_P(object)->has_property(object, propname, 0 TSRMLS_CC); -#endif - } - return 0; -} - -static int TWIG_HAS_DYNAMIC_PROPERTY(zval *object, char *prop, int prop_len TSRMLS_DC) -{ - if (Z_OBJ_HT_P(object)->get_properties) { - return zend_hash_quick_exists( - Z_OBJ_HT_P(object)->get_properties(object TSRMLS_CC), // the properties hash - prop, // property name - prop_len + 1, // property length - zend_get_hash_value(prop, prop_len + 1) // hash value - ); - } - return 0; -} - -static zval *TWIG_PROPERTY_CHAR(zval *object, char *propname TSRMLS_DC) -{ - zval *tmp_name_zval, *tmp; - - ALLOC_INIT_ZVAL(tmp_name_zval); - ZVAL_STRING(tmp_name_zval, propname, 1); - tmp = TWIG_PROPERTY(object, tmp_name_zval TSRMLS_CC); - FREE_DTOR(tmp_name_zval); - return tmp; -} - -static zval *TWIG_CALL_S(zval *object, char *method, char *arg0 TSRMLS_DC) -{ - zend_fcall_info fci; - zval **args[1]; - zval *argument; - zval *zfunction; - zval *retval_ptr; - - MAKE_STD_ZVAL(argument); - ZVAL_STRING(argument, arg0, 1); - args[0] = &argument; - - MAKE_STD_ZVAL(zfunction); - ZVAL_STRING(zfunction, method, 1); - fci.size = sizeof(fci); - fci.function_table = EG(function_table); - fci.function_name = zfunction; - fci.symbol_table = NULL; -#if PHP_VERSION_ID >= 50300 - fci.object_ptr = object; -#else - fci.object_pp = &object; -#endif - fci.retval_ptr_ptr = &retval_ptr; - fci.param_count = 1; - fci.params = args; - fci.no_separation = 0; - - if (zend_call_function(&fci, NULL TSRMLS_CC) == FAILURE) { - FREE_DTOR(zfunction); - zval_ptr_dtor(&argument); - return 0; - } - FREE_DTOR(zfunction); - zval_ptr_dtor(&argument); - return retval_ptr; -} - -static int TWIG_CALL_SB(zval *object, char *method, char *arg0 TSRMLS_DC) -{ - zval *retval_ptr; - int success; - - retval_ptr = TWIG_CALL_S(object, method, arg0 TSRMLS_CC); - success = (retval_ptr && (Z_TYPE_P(retval_ptr) == IS_BOOL) && Z_LVAL_P(retval_ptr)); - - if (retval_ptr) { - zval_ptr_dtor(&retval_ptr); - } - - return success; -} - -static int TWIG_CALL_ZZ(zval *object, char *method, zval *arg1, zval *arg2 TSRMLS_DC) -{ - zend_fcall_info fci; - zval **args[2]; - zval *zfunction; - zval *retval_ptr; - int success; - - args[0] = &arg1; - args[1] = &arg2; - - MAKE_STD_ZVAL(zfunction); - ZVAL_STRING(zfunction, method, 1); - fci.size = sizeof(fci); - fci.function_table = EG(function_table); - fci.function_name = zfunction; - fci.symbol_table = NULL; -#if PHP_VERSION_ID >= 50300 - fci.object_ptr = object; -#else - fci.object_pp = &object; -#endif - fci.retval_ptr_ptr = &retval_ptr; - fci.param_count = 2; - fci.params = args; - fci.no_separation = 0; - - if (zend_call_function(&fci, NULL TSRMLS_CC) == FAILURE) { - FREE_DTOR(zfunction); - return 0; - } - - FREE_DTOR(zfunction); - - success = (retval_ptr && (Z_TYPE_P(retval_ptr) == IS_BOOL) && Z_LVAL_P(retval_ptr)); - if (retval_ptr) { - zval_ptr_dtor(&retval_ptr); - } - - return success; -} - -#ifndef Z_SET_REFCOUNT_P -# define Z_SET_REFCOUNT_P(pz, rc) pz->refcount = rc -# define Z_UNSET_ISREF_P(pz) pz->is_ref = 0 -#endif - -static void TWIG_NEW(zval *object, char *class, zval *arg0, zval *arg1 TSRMLS_DC) -{ - zend_class_entry **pce; - - if (zend_lookup_class(class, strlen(class), &pce TSRMLS_CC) == FAILURE) { - return; - } - - Z_TYPE_P(object) = IS_OBJECT; - object_init_ex(object, *pce); - Z_SET_REFCOUNT_P(object, 1); - Z_UNSET_ISREF_P(object); - - TWIG_CALL_ZZ(object, "__construct", arg0, arg1 TSRMLS_CC); -} - -static int twig_add_array_key_to_string(void *pDest APPLY_TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) -{ - smart_str *buf; - char *joiner; - APPLY_TSRMLS_FETCH(); - - buf = va_arg(args, smart_str*); - joiner = va_arg(args, char*); - - if (buf->len != 0) { - smart_str_appends(buf, joiner); - } - - if (hash_key->nKeyLength == 0) { - smart_str_append_long(buf, (long) hash_key->h); - } else { - char *key, *tmp_str; - int key_len, tmp_len; - key = php_addcslashes(hash_key->arKey, hash_key->nKeyLength - 1, &key_len, 0, "'\\", 2 TSRMLS_CC); - tmp_str = php_str_to_str_ex(key, key_len, "\0", 1, "' . \"\\0\" . '", 12, &tmp_len, 0, NULL); - - smart_str_appendl(buf, tmp_str, tmp_len); - efree(key); - efree(tmp_str); - } - - return 0; -} - -static char *TWIG_IMPLODE_ARRAY_KEYS(char *joiner, zval *array TSRMLS_DC) -{ - smart_str collector = { 0, 0, 0 }; - - smart_str_appendl(&collector, "", 0); - zend_hash_apply_with_arguments(HASH_OF(array) APPLY_TSRMLS_CC, twig_add_array_key_to_string, 2, &collector, joiner); - smart_str_0(&collector); - - return collector.c; -} - -static void TWIG_RUNTIME_ERROR(zval *template TSRMLS_DC, char *message, ...) -{ - char *buffer; - va_list args; - zend_class_entry **pce; - zval *ex; - zval *constructor; - zval *zmessage; - zval *lineno; - zval *filename_func; - zval *filename; - zval *constructor_args[3]; - zval *constructor_retval; - - if (zend_lookup_class("Twig_Error_Runtime", strlen("Twig_Error_Runtime"), &pce TSRMLS_CC) == FAILURE) { - return; - } - - va_start(args, message); - vspprintf(&buffer, 0, message, args); - va_end(args); - - MAKE_STD_ZVAL(ex); - object_init_ex(ex, *pce); - - // Call Twig_Error constructor - MAKE_STD_ZVAL(constructor); - MAKE_STD_ZVAL(zmessage); - MAKE_STD_ZVAL(lineno); - MAKE_STD_ZVAL(filename); - MAKE_STD_ZVAL(filename_func); - MAKE_STD_ZVAL(constructor_retval); - - ZVAL_STRINGL(constructor, "__construct", sizeof("__construct")-1, 1); - ZVAL_STRING(zmessage, buffer, 1); - ZVAL_LONG(lineno, -1); - - // Get template filename - ZVAL_STRINGL(filename_func, "getTemplateName", sizeof("getTemplateName")-1, 1); - call_user_function(EG(function_table), &template, filename_func, filename, 0, 0 TSRMLS_CC); - - constructor_args[0] = zmessage; - constructor_args[1] = lineno; - constructor_args[2] = filename; - call_user_function(EG(function_table), &ex, constructor, constructor_retval, 3, constructor_args TSRMLS_CC); - - zval_ptr_dtor(&constructor_retval); - zval_ptr_dtor(&zmessage); - zval_ptr_dtor(&lineno); - zval_ptr_dtor(&filename); - FREE_DTOR(constructor); - FREE_DTOR(filename_func); - efree(buffer); - - zend_throw_exception_object(ex TSRMLS_CC); -} - -static char *TWIG_GET_CLASS_NAME(zval *object TSRMLS_DC) -{ - char *class_name; - zend_uint class_name_len; - - if (Z_TYPE_P(object) != IS_OBJECT) { - return ""; - } -#if PHP_API_VERSION >= 20100412 - zend_get_object_classname(object, (const char **) &class_name, &class_name_len TSRMLS_CC); -#else - zend_get_object_classname(object, &class_name, &class_name_len TSRMLS_CC); -#endif - return class_name; -} - -static int twig_add_method_to_class(void *pDest APPLY_TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) -{ - zend_class_entry *ce; - zval *retval; - char *item; - size_t item_len; - zend_function *mptr = (zend_function *) pDest; - APPLY_TSRMLS_FETCH(); - - if (!(mptr->common.fn_flags & ZEND_ACC_PUBLIC)) { - return 0; - } - - ce = *va_arg(args, zend_class_entry**); - retval = va_arg(args, zval*); - - item_len = strlen(mptr->common.function_name); - item = estrndup(mptr->common.function_name, item_len); - php_strtolower(item, item_len); - - if (strcmp("getenvironment", item) == 0) { - zend_class_entry **twig_template_ce; - if (zend_lookup_class("Twig_Template", strlen("Twig_Template"), &twig_template_ce TSRMLS_CC) == FAILURE) { - return 0; - } - if (instanceof_function(ce, *twig_template_ce TSRMLS_CC)) { - return 0; - } - } - - add_assoc_stringl_ex(retval, item, item_len+1, item, item_len, 0); - - return 0; -} - -static int twig_add_property_to_class(void *pDest APPLY_TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) -{ - zend_class_entry *ce; - zval *retval; - char *class_name, *prop_name; - zend_property_info *pptr = (zend_property_info *) pDest; - APPLY_TSRMLS_FETCH(); - - if (!(pptr->flags & ZEND_ACC_PUBLIC) || (pptr->flags & ZEND_ACC_STATIC)) { - return 0; - } - - ce = *va_arg(args, zend_class_entry**); - retval = va_arg(args, zval*); - -#if PHP_API_VERSION >= 20100412 - zend_unmangle_property_name(pptr->name, pptr->name_length, (const char **) &class_name, (const char **) &prop_name); -#else - zend_unmangle_property_name(pptr->name, pptr->name_length, &class_name, &prop_name); -#endif - - add_assoc_string(retval, prop_name, prop_name, 1); - - return 0; -} - -static void twig_add_class_to_cache(zval *cache, zval *object, char *class_name TSRMLS_DC) -{ - zval *class_info, *class_methods, *class_properties; - zend_class_entry *class_ce; - - class_ce = zend_get_class_entry(object TSRMLS_CC); - - ALLOC_INIT_ZVAL(class_info); - ALLOC_INIT_ZVAL(class_methods); - ALLOC_INIT_ZVAL(class_properties); - array_init(class_info); - array_init(class_methods); - array_init(class_properties); - // add all methods to self::cache[$class]['methods'] - zend_hash_apply_with_arguments(&class_ce->function_table APPLY_TSRMLS_CC, twig_add_method_to_class, 2, &class_ce, class_methods); - zend_hash_apply_with_arguments(&class_ce->properties_info APPLY_TSRMLS_CC, twig_add_property_to_class, 2, &class_ce, class_properties); - - add_assoc_zval(class_info, "methods", class_methods); - add_assoc_zval(class_info, "properties", class_properties); - add_assoc_zval(cache, class_name, class_info); -} - -/* {{{ proto mixed twig_template_get_attributes(TwigTemplate template, mixed object, mixed item, array arguments, string type, boolean isDefinedTest, boolean ignoreStrictCheck) - A C implementation of TwigTemplate::getAttribute() */ -PHP_FUNCTION(twig_template_get_attributes) -{ - zval *template; - zval *object; - char *item; - int item_len; - zval *zitem, ztmpitem; - zval *arguments = NULL; - zval *ret = NULL; - char *type = NULL; - int type_len = 0; - zend_bool isDefinedTest = 0; - zend_bool ignoreStrictCheck = 0; - int free_ret = 0; - zval *tmp_self_cache; - char *class_name = NULL; - zval *tmp_class; - char *type_name; - - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ozz|asbb", &template, &object, &zitem, &arguments, &type, &type_len, &isDefinedTest, &ignoreStrictCheck) == FAILURE) { - return; - } - - // convert the item to a string - ztmpitem = *zitem; - zval_copy_ctor(&ztmpitem); - convert_to_string(&ztmpitem); - item_len = Z_STRLEN(ztmpitem); - item = estrndup(Z_STRVAL(ztmpitem), item_len); - zval_dtor(&ztmpitem); - - if (!type) { - type = "any"; - } - -/* - // array - if (Twig_Template::METHOD_CALL !== $type) { - $arrayItem = is_bool($item) || is_float($item) ? (int) $item : $item; - - if ((is_array($object) && array_key_exists($arrayItem, $object)) - || ($object instanceof ArrayAccess && isset($object[$arrayItem])) - ) { - if ($isDefinedTest) { - return true; - } - - return $object[$arrayItem]; - } -*/ - - - if (strcmp("method", type) != 0) { - if ((TWIG_ARRAY_KEY_EXISTS(object, zitem)) - || (TWIG_INSTANCE_OF(object, zend_ce_arrayaccess TSRMLS_CC) && TWIG_ISSET_ARRAYOBJECT_ELEMENT(object, zitem TSRMLS_CC)) - ) { - - if (isDefinedTest) { - efree(item); - RETURN_TRUE; - } - - ret = TWIG_GET_ARRAY_ELEMENT_ZVAL(object, zitem TSRMLS_CC); - - if (!ret) { - ret = &EG(uninitialized_zval); - } - RETVAL_ZVAL(ret, 1, 0); - if (free_ret) { - zval_ptr_dtor(&ret); - } - efree(item); - return; - } -/* - if (Twig_Template::ARRAY_CALL === $type) { - if ($isDefinedTest) { - return false; - } - if ($ignoreStrictCheck || !$this->env->isStrictVariables()) { - return null; - } -*/ - if (strcmp("array", type) == 0 || Z_TYPE_P(object) != IS_OBJECT) { - if (isDefinedTest) { - efree(item); - RETURN_FALSE; - } - if (ignoreStrictCheck || !TWIG_CALL_BOOLEAN(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "isStrictVariables" TSRMLS_CC)) { - efree(item); - return; - } -/* - if ($object instanceof ArrayAccess) { - $message = sprintf('Key "%s" in object with ArrayAccess of class "%s" does not exist', $arrayItem, get_class($object)); - } elseif (is_object($object)) { - $message = sprintf('Impossible to access a key "%s" on an object of class "%s" that does not implement ArrayAccess interface', $item, get_class($object)); - } elseif (is_array($object)) { - if (empty($object)) { - $message = sprintf('Key "%s" does not exist as the array is empty', $arrayItem); - } else { - $message = sprintf('Key "%s" for array with keys "%s" does not exist', $arrayItem, implode(', ', array_keys($object))); - } - } elseif (Twig_Template::ARRAY_CALL === $type) { - if (null === $object) { - $message = sprintf('Impossible to access a key ("%s") on a null variable', $item); - } else { - $message = sprintf('Impossible to access a key ("%s") on a %s variable ("%s")', $item, gettype($object), $object); - } - } elseif (null === $object) { - $message = sprintf('Impossible to access an attribute ("%s") on a null variable', $item); - } else { - $message = sprintf('Impossible to access an attribute ("%s") on a %s variable ("%s")', $item, gettype($object), $object); - } - throw new Twig_Error_Runtime($message, -1, $this->getTemplateName()); - } - } -*/ - if (TWIG_INSTANCE_OF(object, zend_ce_arrayaccess TSRMLS_CC)) { - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Key \"%s\" in object with ArrayAccess of class \"%s\" does not exist", item, TWIG_GET_CLASS_NAME(object TSRMLS_CC)); - } else if (Z_TYPE_P(object) == IS_OBJECT) { - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Impossible to access a key \"%s\" on an object of class \"%s\" that does not implement ArrayAccess interface", item, TWIG_GET_CLASS_NAME(object TSRMLS_CC)); - } else if (Z_TYPE_P(object) == IS_ARRAY) { - if (0 == zend_hash_num_elements(Z_ARRVAL_P(object))) { - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Key \"%s\" does not exist as the array is empty", item); - } else { - char *array_keys = TWIG_IMPLODE_ARRAY_KEYS(", ", object TSRMLS_CC); - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Key \"%s\" for array with keys \"%s\" does not exist", item, array_keys); - efree(array_keys); - } - } else { - char *type_name = zend_zval_type_name(object); - Z_ADDREF_P(object); - if (Z_TYPE_P(object) == IS_NULL) { - convert_to_string(object); - TWIG_RUNTIME_ERROR(template TSRMLS_CC, - (strcmp("array", type) == 0) - ? "Impossible to access a key (\"%s\") on a %s variable" - : "Impossible to access an attribute (\"%s\") on a %s variable", - item, type_name); - } else { - convert_to_string(object); - TWIG_RUNTIME_ERROR(template TSRMLS_CC, - (strcmp("array", type) == 0) - ? "Impossible to access a key (\"%s\") on a %s variable (\"%s\")" - : "Impossible to access an attribute (\"%s\") on a %s variable (\"%s\")", - item, type_name, Z_STRVAL_P(object)); - } - zval_ptr_dtor(&object); - } - efree(item); - return; - } - } - -/* - if (!is_object($object)) { - if ($isDefinedTest) { - return false; - } -*/ - - if (Z_TYPE_P(object) != IS_OBJECT) { - if (isDefinedTest) { - efree(item); - RETURN_FALSE; - } -/* - if ($ignoreStrictCheck || !$this->env->isStrictVariables()) { - return null; - } - - if (null === $object) { - $message = sprintf('Impossible to invoke a method ("%s") on a null variable', $item); - } else { - $message = sprintf('Impossible to invoke a method ("%s") on a %s variable ("%s")', $item, gettype($object), $object); - } - - throw new Twig_Error_Runtime($message, -1, $this->getTemplateName()); - } -*/ - if (ignoreStrictCheck || !TWIG_CALL_BOOLEAN(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "isStrictVariables" TSRMLS_CC)) { - efree(item); - return; - } - - type_name = zend_zval_type_name(object); - Z_ADDREF_P(object); - if (Z_TYPE_P(object) == IS_NULL) { - convert_to_string_ex(&object); - - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Impossible to invoke a method (\"%s\") on a %s variable", item, type_name); - } else { - convert_to_string_ex(&object); - - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Impossible to invoke a method (\"%s\") on a %s variable (\"%s\")", item, type_name, Z_STRVAL_P(object)); - } - - zval_ptr_dtor(&object); - efree(item); - return; - } -/* - $class = get_class($object); -*/ - - class_name = TWIG_GET_CLASS_NAME(object TSRMLS_CC); - tmp_self_cache = TWIG_GET_STATIC_PROPERTY(template, "cache" TSRMLS_CC); - tmp_class = TWIG_GET_ARRAY_ELEMENT(tmp_self_cache, class_name, strlen(class_name) TSRMLS_CC); - - if (!tmp_class) { - twig_add_class_to_cache(tmp_self_cache, object, class_name TSRMLS_CC); - tmp_class = TWIG_GET_ARRAY_ELEMENT(tmp_self_cache, class_name, strlen(class_name) TSRMLS_CC); - } - efree(class_name); - -/* - // object property - if (Twig_Template::METHOD_CALL !== $type && !$object instanceof Twig_Template) { - if (isset($object->$item) || array_key_exists((string) $item, $object)) { - if ($isDefinedTest) { - return true; - } - - if ($this->env->hasExtension('sandbox')) { - $this->env->getExtension('sandbox')->checkPropertyAllowed($object, $item); - } - - return $object->$item; - } - } -*/ - if (strcmp("method", type) != 0 && !TWIG_INSTANCE_OF_USERLAND(object, "Twig_Template" TSRMLS_CC)) { - zval *tmp_properties, *tmp_item; - - tmp_properties = TWIG_GET_ARRAY_ELEMENT(tmp_class, "properties", strlen("properties") TSRMLS_CC); - tmp_item = TWIG_GET_ARRAY_ELEMENT(tmp_properties, item, item_len TSRMLS_CC); - - if (tmp_item || TWIG_HAS_PROPERTY(object, zitem TSRMLS_CC) || TWIG_HAS_DYNAMIC_PROPERTY(object, item, item_len TSRMLS_CC)) { - if (isDefinedTest) { - efree(item); - RETURN_TRUE; - } - if (TWIG_CALL_SB(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "hasExtension", "sandbox" TSRMLS_CC)) { - TWIG_CALL_ZZ(TWIG_CALL_S(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "getExtension", "sandbox" TSRMLS_CC), "checkPropertyAllowed", object, zitem TSRMLS_CC); - } - if (EG(exception)) { - efree(item); - return; - } - - ret = TWIG_PROPERTY(object, zitem TSRMLS_CC); - efree(item); - RETURN_ZVAL(ret, 1, 0); - } - } -/* - // object method - if (!isset(self::$cache[$class]['methods'])) { - if ($object instanceof self) { - $ref = new ReflectionClass($class); - $methods = array(); - - foreach ($ref->getMethods(ReflectionMethod::IS_PUBLIC) as $refMethod) { - $methodName = strtolower($refMethod->name); - - // Accessing the environment from templates is forbidden to prevent untrusted changes to the environment - if ('getenvironment' !== $methodName) { - $methods[$methodName] = true; - } - } - - self::$cache[$class]['methods'] = $methods; - } else { - self::$cache[$class]['methods'] = array_change_key_case(array_flip(get_class_methods($object))); - } - } - - $call = false; - $lcItem = strtolower($item); - if (isset(self::$cache[$class]['methods'][$lcItem])) { - $method = (string) $item; - } elseif (isset(self::$cache[$class]['methods']['get'.$lcItem])) { - $method = 'get'.$item; - } elseif (isset(self::$cache[$class]['methods']['is'.$lcItem])) { - $method = 'is'.$item; - } elseif (isset(self::$cache[$class]['methods']['__call'])) { - $method = (string) $item; - $call = true; -*/ - { - int call = 0; - char *lcItem = TWIG_STRTOLOWER(item, item_len); - int lcItem_length; - char *method = NULL; - char *tmp_method_name_get; - char *tmp_method_name_is; - zval *zmethod; - zval *tmp_methods; - - lcItem_length = strlen(lcItem); - tmp_method_name_get = emalloc(4 + lcItem_length); - tmp_method_name_is = emalloc(3 + lcItem_length); - - sprintf(tmp_method_name_get, "get%s", lcItem); - sprintf(tmp_method_name_is, "is%s", lcItem); - - tmp_methods = TWIG_GET_ARRAY_ELEMENT(tmp_class, "methods", strlen("methods") TSRMLS_CC); - - if (TWIG_GET_ARRAY_ELEMENT(tmp_methods, lcItem, lcItem_length TSRMLS_CC)) { - method = item; - } else if (TWIG_GET_ARRAY_ELEMENT(tmp_methods, tmp_method_name_get, lcItem_length + 3 TSRMLS_CC)) { - method = tmp_method_name_get; - } else if (TWIG_GET_ARRAY_ELEMENT(tmp_methods, tmp_method_name_is, lcItem_length + 2 TSRMLS_CC)) { - method = tmp_method_name_is; - } else if (TWIG_GET_ARRAY_ELEMENT(tmp_methods, "__call", 6 TSRMLS_CC)) { - method = item; - call = 1; -/* - } else { - if ($isDefinedTest) { - return false; - } - - if ($ignoreStrictCheck || !$this->env->isStrictVariables()) { - return null; - } - - throw new Twig_Error_Runtime(sprintf('Method "%s" for object "%s" does not exist', $item, get_class($object)), -1, $this->getTemplateName()); - } - - if ($isDefinedTest) { - return true; - } -*/ - } else { - efree(tmp_method_name_get); - efree(tmp_method_name_is); - efree(lcItem); - - if (isDefinedTest) { - efree(item); - RETURN_FALSE; - } - if (ignoreStrictCheck || !TWIG_CALL_BOOLEAN(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "isStrictVariables" TSRMLS_CC)) { - efree(item); - return; - } - TWIG_RUNTIME_ERROR(template TSRMLS_CC, "Method \"%s\" for object \"%s\" does not exist", item, TWIG_GET_CLASS_NAME(object TSRMLS_CC)); - efree(item); - return; - } - - if (isDefinedTest) { - efree(tmp_method_name_get); - efree(tmp_method_name_is); - efree(lcItem);efree(item); - RETURN_TRUE; - } -/* - if ($this->env->hasExtension('sandbox')) { - $this->env->getExtension('sandbox')->checkMethodAllowed($object, $method); - } -*/ - MAKE_STD_ZVAL(zmethod); - ZVAL_STRING(zmethod, method, 1); - if (TWIG_CALL_SB(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "hasExtension", "sandbox" TSRMLS_CC)) { - TWIG_CALL_ZZ(TWIG_CALL_S(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "getExtension", "sandbox" TSRMLS_CC), "checkMethodAllowed", object, zmethod TSRMLS_CC); - } - zval_ptr_dtor(&zmethod); - if (EG(exception)) { - efree(tmp_method_name_get); - efree(tmp_method_name_is); - efree(lcItem);efree(item); - return; - } -/* - // Some objects throw exceptions when they have __call, and the method we try - // to call is not supported. If ignoreStrictCheck is true, we should return null. - try { - $ret = call_user_func_array(array($object, $method), $arguments); - } catch (BadMethodCallException $e) { - if ($call && ($ignoreStrictCheck || !$this->env->isStrictVariables())) { - return null; - } - throw $e; - } -*/ - ret = TWIG_CALL_USER_FUNC_ARRAY(object, method, arguments TSRMLS_CC); - if (EG(exception) && TWIG_INSTANCE_OF(EG(exception), spl_ce_BadMethodCallException TSRMLS_CC)) { - if (ignoreStrictCheck || !TWIG_CALL_BOOLEAN(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "isStrictVariables" TSRMLS_CC)) { - efree(tmp_method_name_get); - efree(tmp_method_name_is); - efree(lcItem);efree(item); - zend_clear_exception(TSRMLS_C); - return; - } - } - free_ret = 1; - efree(tmp_method_name_get); - efree(tmp_method_name_is); - efree(lcItem); - } -/* - // useful when calling a template method from a template - // this is not supported but unfortunately heavily used in the Symfony profiler - if ($object instanceof Twig_TemplateInterface) { - return $ret === '' ? '' : new Twig_Markup($ret, $this->env->getCharset()); - } - - return $ret; -*/ - efree(item); - // ret can be null, if e.g. the called method throws an exception - if (ret) { - if (TWIG_INSTANCE_OF_USERLAND(object, "Twig_TemplateInterface" TSRMLS_CC)) { - if (Z_STRLEN_P(ret) != 0) { - zval *charset = TWIG_CALL_USER_FUNC_ARRAY(TWIG_PROPERTY_CHAR(template, "env" TSRMLS_CC), "getCharset", NULL TSRMLS_CC); - TWIG_NEW(return_value, "Twig_Markup", ret, charset TSRMLS_CC); - zval_ptr_dtor(&charset); - if (ret) { - zval_ptr_dtor(&ret); - } - return; - } - } - - RETVAL_ZVAL(ret, 1, 0); - if (free_ret) { - zval_ptr_dtor(&ret); - } - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/AutoloaderTest.php b/vendor/twig/twig/test/Twig/Tests/AutoloaderTest.php deleted file mode 100644 index 52107c0c1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/AutoloaderTest.php +++ /dev/null @@ -1,24 +0,0 @@ -assertFalse(class_exists('FooBarFoo'), '->autoload() does not try to load classes that does not begin with Twig'); - - $autoloader = new Twig_Autoloader(); - $this->assertNull($autoloader->autoload('Foo'), '->autoload() returns false if it is not able to load a class'); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/CompilerTest.php b/vendor/twig/twig/test/Twig/Tests/CompilerTest.php deleted file mode 100644 index bc25f117b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/CompilerTest.php +++ /dev/null @@ -1,33 +0,0 @@ -getMock('Twig_LoaderInterface'))); - - $locale = setlocale(LC_NUMERIC, 0); - if (false === $locale) { - $this->markTestSkipped('Your platform does not support locales.'); - } - - $required_locales = array('fr_FR.UTF-8', 'fr_FR.UTF8', 'fr_FR.utf-8', 'fr_FR.utf8', 'French_France.1252'); - if (false === setlocale(LC_NUMERIC, $required_locales)) { - $this->markTestSkipped('Could not set any of required locales: '.implode(', ', $required_locales)); - } - - $this->assertEquals('1.2', $compiler->repr(1.2)->getSource()); - $this->assertContains('fr', strtolower(setlocale(LC_NUMERIC, 0))); - - setlocale(LC_NUMERIC, $locale); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/EnvironmentTest.php b/vendor/twig/twig/test/Twig/Tests/EnvironmentTest.php deleted file mode 100644 index 83a98ef52..000000000 --- a/vendor/twig/twig/test/Twig/Tests/EnvironmentTest.php +++ /dev/null @@ -1,303 +0,0 @@ -render('test'); - } - - public function testAutoescapeOption() - { - $loader = new Twig_Loader_Array(array( - 'html' => '{{ foo }} {{ foo }}', - 'js' => '{{ bar }} {{ bar }}', - )); - - $twig = new Twig_Environment($loader, array( - 'debug' => true, - 'cache' => false, - 'autoescape' => array($this, 'escapingStrategyCallback'), - )); - - $this->assertEquals('foo<br/ > foo<br/ >', $twig->render('html', array('foo' => 'foo
    '))); - $this->assertEquals('foo\x3Cbr\x2F\x20\x3E foo\x3Cbr\x2F\x20\x3E', $twig->render('js', array('bar' => 'foo
    '))); - } - - public function escapingStrategyCallback($filename) - { - return $filename; - } - - public function testGlobals() - { - // globals can be added after calling getGlobals - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->addGlobal('foo', 'bar'); - $globals = $twig->getGlobals(); - $this->assertEquals('bar', $globals['foo']); - - // globals can be modified after runtime init - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->initRuntime(); - $twig->addGlobal('foo', 'bar'); - $globals = $twig->getGlobals(); - $this->assertEquals('bar', $globals['foo']); - - // globals can be modified after extensions init - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->getFunctions(); - $twig->addGlobal('foo', 'bar'); - $globals = $twig->getGlobals(); - $this->assertEquals('bar', $globals['foo']); - - // globals can be modified after extensions and runtime init - $twig = new Twig_Environment($loader = new Twig_Loader_Array(array('index' => '{{foo}}'))); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->getFunctions(); - $twig->initRuntime(); - $twig->addGlobal('foo', 'bar'); - $globals = $twig->getGlobals(); - $this->assertEquals('bar', $globals['foo']); - - $twig = new Twig_Environment($loader); - $twig->getGlobals(); - $twig->addGlobal('foo', 'bar'); - $template = $twig->loadTemplate('index'); - $this->assertEquals('bar', $template->render(array())); - - /* to be uncomment in Twig 2.0 - // globals cannot be added after runtime init - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->initRuntime(); - try { - $twig->addGlobal('bar', 'bar'); - $this->fail(); - } catch (LogicException $e) { - $this->assertFalse(array_key_exists('bar', $twig->getGlobals())); - } - - // globals cannot be added after extensions init - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->getFunctions(); - try { - $twig->addGlobal('bar', 'bar'); - $this->fail(); - } catch (LogicException $e) { - $this->assertFalse(array_key_exists('bar', $twig->getGlobals())); - } - - // globals cannot be added after extensions and runtime init - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addGlobal('foo', 'foo'); - $twig->getGlobals(); - $twig->getFunctions(); - $twig->initRuntime(); - try { - $twig->addGlobal('bar', 'bar'); - $this->fail(); - } catch (LogicException $e) { - $this->assertFalse(array_key_exists('bar', $twig->getGlobals())); - } - - // test adding globals after initRuntime without call to getGlobals - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->initRuntime(); - try { - $twig->addGlobal('bar', 'bar'); - $this->fail(); - } catch (LogicException $e) { - $this->assertFalse(array_key_exists('bar', $twig->getGlobals())); - } - */ - } - - public function testCompileSourceInlinesSource() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - - $source = "\r\nbar\n"; - $expected = "/* */\n/* bar*/\n/* */\n"; - $compiled = $twig->compileSource($source, 'index'); - - $this->assertContains($expected, $compiled); - $this->assertNotContains('/**', $compiled); - } - - public function testExtensionsAreNotInitializedWhenRenderingACompiledTemplate() - { - $cache = new Twig_Cache_Filesystem($dir = sys_get_temp_dir().'/twig'); - $options = array('cache' => $cache, 'auto_reload' => false, 'debug' => false); - - // force compilation - $twig = new Twig_Environment($loader = new Twig_Loader_Array(array('index' => '{{ foo }}')), $options); - - $key = $cache->generateKey('index', $twig->getTemplateClass('index')); - $cache->write($key, $twig->compileSource('{{ foo }}', 'index')); - - // check that extensions won't be initialized when rendering a template that is already in the cache - $twig = $this - ->getMockBuilder('Twig_Environment') - ->setConstructorArgs(array($loader, $options)) - ->setMethods(array('initExtensions')) - ->getMock() - ; - - $twig->expects($this->never())->method('initExtensions'); - - // render template - $output = $twig->render('index', array('foo' => 'bar')); - $this->assertEquals('bar', $output); - - unlink($key); - } - - public function testAddExtension() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addExtension(new Twig_Tests_EnvironmentTest_Extension()); - - $this->assertArrayHasKey('test', $twig->getTags()); - $this->assertArrayHasKey('foo_filter', $twig->getFilters()); - $this->assertArrayHasKey('foo_function', $twig->getFunctions()); - $this->assertArrayHasKey('foo_test', $twig->getTests()); - $this->assertArrayHasKey('foo_unary', $twig->getUnaryOperators()); - $this->assertArrayHasKey('foo_binary', $twig->getBinaryOperators()); - $this->assertArrayHasKey('foo_global', $twig->getGlobals()); - $visitors = $twig->getNodeVisitors(); - $this->assertEquals('Twig_Tests_EnvironmentTest_NodeVisitor', get_class($visitors[2])); - } - - /** - * @group legacy - */ - public function testRemoveExtension() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->addExtension(new Twig_Tests_EnvironmentTest_Extension()); - $twig->removeExtension('environment_test'); - - $this->assertFalse(array_key_exists('test', $twig->getTags())); - $this->assertFalse(array_key_exists('foo_filter', $twig->getFilters())); - $this->assertFalse(array_key_exists('foo_function', $twig->getFunctions())); - $this->assertFalse(array_key_exists('foo_test', $twig->getTests())); - $this->assertFalse(array_key_exists('foo_unary', $twig->getUnaryOperators())); - $this->assertFalse(array_key_exists('foo_binary', $twig->getBinaryOperators())); - $this->assertFalse(array_key_exists('foo_global', $twig->getGlobals())); - $this->assertCount(2, $twig->getNodeVisitors()); - } -} - -class Twig_Tests_EnvironmentTest_Extension extends Twig_Extension -{ - public function getTokenParsers() - { - return array( - new Twig_Tests_EnvironmentTest_TokenParser(), - ); - } - - public function getNodeVisitors() - { - return array( - new Twig_Tests_EnvironmentTest_NodeVisitor(), - ); - } - - public function getFilters() - { - return array( - new Twig_SimpleFilter('foo_filter', 'foo_filter'), - ); - } - - public function getTests() - { - return array( - new Twig_SimpleTest('foo_test', 'foo_test'), - ); - } - - public function getFunctions() - { - return array( - new Twig_SimpleFunction('foo_function', 'foo_function'), - ); - } - - public function getOperators() - { - return array( - array('foo_unary' => array()), - array('foo_binary' => array()), - ); - } - - public function getGlobals() - { - return array( - 'foo_global' => 'foo_global', - ); - } - - public function getName() - { - return 'environment_test'; - } -} - -class Twig_Tests_EnvironmentTest_TokenParser extends Twig_TokenParser -{ - public function parse(Twig_Token $token) - { - } - - public function getTag() - { - return 'test'; - } -} - -class Twig_Tests_EnvironmentTest_NodeVisitor implements Twig_NodeVisitorInterface -{ - public function enterNode(Twig_NodeInterface $node, Twig_Environment $env) - { - return $node; - } - - public function leaveNode(Twig_NodeInterface $node, Twig_Environment $env) - { - return $node; - } - - public function getPriority() - { - return 0; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/ErrorTest.php b/vendor/twig/twig/test/Twig/Tests/ErrorTest.php deleted file mode 100644 index d58c40b8d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/ErrorTest.php +++ /dev/null @@ -1,144 +0,0 @@ -setTemplateFile(new SplFileInfo(__FILE__)); - - $this->assertContains('test'.DIRECTORY_SEPARATOR.'Twig'.DIRECTORY_SEPARATOR.'Tests'.DIRECTORY_SEPARATOR.'ErrorTest.php', $error->getMessage()); - } - - public function testErrorWithArrayFilename() - { - $error = new Twig_Error('foo'); - $error->setTemplateFile(array('foo' => 'bar')); - - $this->assertEquals('foo in {"foo":"bar"}', $error->getMessage()); - } - - public function testTwigExceptionAddsFileAndLineWhenMissingWithInheritanceOnDisk() - { - $loader = new Twig_Loader_Filesystem(dirname(__FILE__).'/Fixtures/errors'); - $twig = new Twig_Environment($loader, array('strict_variables' => true, 'debug' => true, 'cache' => false)); - - $template = $twig->loadTemplate('index.html'); - try { - $template->render(array()); - - $this->fail(); - } catch (Twig_Error_Runtime $e) { - $this->assertEquals('Variable "foo" does not exist in "index.html" at line 3', $e->getMessage()); - $this->assertEquals(3, $e->getTemplateLine()); - $this->assertEquals('index.html', $e->getTemplateFile()); - } - - try { - $template->render(array('foo' => new Twig_Tests_ErrorTest_Foo())); - - $this->fail(); - } catch (Twig_Error_Runtime $e) { - $this->assertEquals('An exception has been thrown during the rendering of a template ("Runtime error...") in "index.html" at line 3.', $e->getMessage()); - $this->assertEquals(3, $e->getTemplateLine()); - $this->assertEquals('index.html', $e->getTemplateFile()); - } - } - - /** - * @dataProvider getErroredTemplates - */ - public function testTwigExceptionAddsFileAndLine($templates, $name, $line) - { - $loader = new Twig_Loader_Array($templates); - $twig = new Twig_Environment($loader, array('strict_variables' => true, 'debug' => true, 'cache' => false)); - - $template = $twig->loadTemplate('index'); - - try { - $template->render(array()); - - $this->fail(); - } catch (Twig_Error_Runtime $e) { - $this->assertEquals(sprintf('Variable "foo" does not exist in "%s" at line %d', $name, $line), $e->getMessage()); - $this->assertEquals($line, $e->getTemplateLine()); - $this->assertEquals($name, $e->getTemplateFile()); - } - - try { - $template->render(array('foo' => new Twig_Tests_ErrorTest_Foo())); - - $this->fail(); - } catch (Twig_Error_Runtime $e) { - $this->assertEquals(sprintf('An exception has been thrown during the rendering of a template ("Runtime error...") in "%s" at line %d.', $name, $line), $e->getMessage()); - $this->assertEquals($line, $e->getTemplateLine()); - $this->assertEquals($name, $e->getTemplateFile()); - } - } - - public function getErroredTemplates() - { - return array( - // error occurs in a template - array( - array( - 'index' => "\n\n{{ foo.bar }}\n\n\n{{ 'foo' }}", - ), - 'index', 3, - ), - - // error occurs in an included template - array( - array( - 'index' => "{% include 'partial' %}", - 'partial' => '{{ foo.bar }}', - ), - 'partial', 1, - ), - - // error occurs in a parent block when called via parent() - array( - array( - 'index' => "{% extends 'base' %} - {% block content %} - {{ parent() }} - {% endblock %}", - 'base' => '{% block content %}{{ foo.bar }}{% endblock %}', - ), - 'base', 1, - ), - - // error occurs in a block from the child - array( - array( - 'index' => "{% extends 'base' %} - {% block content %} - {{ foo.bar }} - {% endblock %} - {% block foo %} - {{ foo.bar }} - {% endblock %}", - 'base' => '{% block content %}{% endblock %}', - ), - 'index', 3, - ), - ); - } -} - -class Twig_Tests_ErrorTest_Foo -{ - public function bar() - { - throw new Exception('Runtime error...'); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/ExpressionParserTest.php b/vendor/twig/twig/test/Twig/Tests/ExpressionParserTest.php deleted file mode 100644 index ff263cf28..000000000 --- a/vendor/twig/twig/test/Twig/Tests/ExpressionParserTest.php +++ /dev/null @@ -1,332 +0,0 @@ -getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize($template, 'index')); - } - - public function getFailingTestsForAssignment() - { - return array( - array('{% set false = "foo" %}'), - array('{% set true = "foo" %}'), - array('{% set none = "foo" %}'), - array('{% set 3 = "foo" %}'), - array('{% set 1 + 2 = "foo" %}'), - array('{% set "bar" = "foo" %}'), - array('{% set %}{% endset %}'), - ); - } - - /** - * @dataProvider getTestsForArray - */ - public function testArrayExpression($template, $expected) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $stream = $env->tokenize($template, 'index'); - $parser = new Twig_Parser($env); - - $this->assertEquals($expected, $parser->parse($stream)->getNode('body')->getNode(0)->getNode('expr')); - } - - /** - * @expectedException Twig_Error_Syntax - * @dataProvider getFailingTestsForArray - */ - public function testArraySyntaxError($template) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize($template, 'index')); - } - - public function getFailingTestsForArray() - { - return array( - array('{{ [1, "a": "b"] }}'), - array('{{ {"a": "b", 2} }}'), - ); - } - - public function getTestsForArray() - { - return array( - // simple array - array('{{ [1, 2] }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant(0, 1), - new Twig_Node_Expression_Constant(1, 1), - - new Twig_Node_Expression_Constant(1, 1), - new Twig_Node_Expression_Constant(2, 1), - ), 1), - ), - - // array with trailing , - array('{{ [1, 2, ] }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant(0, 1), - new Twig_Node_Expression_Constant(1, 1), - - new Twig_Node_Expression_Constant(1, 1), - new Twig_Node_Expression_Constant(2, 1), - ), 1), - ), - - // simple hash - array('{{ {"a": "b", "b": "c"} }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant('a', 1), - new Twig_Node_Expression_Constant('b', 1), - - new Twig_Node_Expression_Constant('b', 1), - new Twig_Node_Expression_Constant('c', 1), - ), 1), - ), - - // hash with trailing , - array('{{ {"a": "b", "b": "c", } }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant('a', 1), - new Twig_Node_Expression_Constant('b', 1), - - new Twig_Node_Expression_Constant('b', 1), - new Twig_Node_Expression_Constant('c', 1), - ), 1), - ), - - // hash in an array - array('{{ [1, {"a": "b", "b": "c"}] }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant(0, 1), - new Twig_Node_Expression_Constant(1, 1), - - new Twig_Node_Expression_Constant(1, 1), - new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant('a', 1), - new Twig_Node_Expression_Constant('b', 1), - - new Twig_Node_Expression_Constant('b', 1), - new Twig_Node_Expression_Constant('c', 1), - ), 1), - ), 1), - ), - - // array in a hash - array('{{ {"a": [1, 2], "b": "c"} }}', new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant('a', 1), - new Twig_Node_Expression_Array(array( - new Twig_Node_Expression_Constant(0, 1), - new Twig_Node_Expression_Constant(1, 1), - - new Twig_Node_Expression_Constant(1, 1), - new Twig_Node_Expression_Constant(2, 1), - ), 1), - new Twig_Node_Expression_Constant('b', 1), - new Twig_Node_Expression_Constant('c', 1), - ), 1), - ), - ); - } - - /** - * @expectedException Twig_Error_Syntax - */ - public function testStringExpressionDoesNotConcatenateTwoConsecutiveStrings() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false, 'optimizations' => 0)); - $stream = $env->tokenize('{{ "a" "b" }}', 'index'); - $parser = new Twig_Parser($env); - - $parser->parse($stream); - } - - /** - * @dataProvider getTestsForString - */ - public function testStringExpression($template, $expected) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false, 'optimizations' => 0)); - $stream = $env->tokenize($template, 'index'); - $parser = new Twig_Parser($env); - - $this->assertEquals($expected, $parser->parse($stream)->getNode('body')->getNode(0)->getNode('expr')); - } - - public function getTestsForString() - { - return array( - array( - '{{ "foo" }}', new Twig_Node_Expression_Constant('foo', 1), - ), - array( - '{{ "foo #{bar}" }}', new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Constant('foo ', 1), - new Twig_Node_Expression_Name('bar', 1), - 1 - ), - ), - array( - '{{ "foo #{bar} baz" }}', new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Constant('foo ', 1), - new Twig_Node_Expression_Name('bar', 1), - 1 - ), - new Twig_Node_Expression_Constant(' baz', 1), - 1 - ), - ), - - array( - '{{ "foo #{"foo #{bar} baz"} baz" }}', new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Constant('foo ', 1), - new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Binary_Concat( - new Twig_Node_Expression_Constant('foo ', 1), - new Twig_Node_Expression_Name('bar', 1), - 1 - ), - new Twig_Node_Expression_Constant(' baz', 1), - 1 - ), - 1 - ), - new Twig_Node_Expression_Constant(' baz', 1), - 1 - ), - ), - ); - } - - /** - * @expectedException Twig_Error_Syntax - */ - public function testAttributeCallDoesNotSupportNamedArguments() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{{ foo.bar(name="Foo") }}', 'index')); - } - - /** - * @expectedException Twig_Error_Syntax - */ - public function testMacroCallDoesNotSupportNamedArguments() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{% from _self import foo %}{% macro foo() %}{% endmacro %}{{ foo(name="Foo") }}', 'index')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage An argument must be a name. Unexpected token "string" of value "a" ("name" expected) in "index" at line 1 - */ - public function testMacroDefinitionDoesNotSupportNonNameVariableName() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{% macro foo("a") %}{% endmacro %}', 'index')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage A default value for an argument must be a constant (a boolean, a string, a number, or an array) in "index" at line 1 - * @dataProvider getMacroDefinitionDoesNotSupportNonConstantDefaultValues - */ - public function testMacroDefinitionDoesNotSupportNonConstantDefaultValues($template) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize($template, 'index')); - } - - public function getMacroDefinitionDoesNotSupportNonConstantDefaultValues() - { - return array( - array('{% macro foo(name = "a #{foo} a") %}{% endmacro %}'), - array('{% macro foo(name = [["b", "a #{foo} a"]]) %}{% endmacro %}'), - ); - } - - /** - * @dataProvider getMacroDefinitionSupportsConstantDefaultValues - */ - public function testMacroDefinitionSupportsConstantDefaultValues($template) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize($template, 'index')); - } - - public function getMacroDefinitionSupportsConstantDefaultValues() - { - return array( - array('{% macro foo(name = "aa") %}{% endmacro %}'), - array('{% macro foo(name = 12) %}{% endmacro %}'), - array('{% macro foo(name = true) %}{% endmacro %}'), - array('{% macro foo(name = ["a"]) %}{% endmacro %}'), - array('{% macro foo(name = [["a"]]) %}{% endmacro %}'), - array('{% macro foo(name = {a: "a"}) %}{% endmacro %}'), - array('{% macro foo(name = {a: {b: "a"}}) %}{% endmacro %}'), - ); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage The function "cycl" does not exist. Did you mean "cycle" in "index" at line 1 - */ - public function testUnknownFunction() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{{ cycl() }}', 'index')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage The filter "lowe" does not exist. Did you mean "lower" in "index" at line 1 - */ - public function testUnknownFilter() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{{ 1|lowe }}', 'index')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage The test "nul" does not exist. Did you mean "null" in "index" at line 1 - */ - public function testUnknownTest() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $parser = new Twig_Parser($env); - - $parser->parse($env->tokenize('{{ 1 is nul }}', 'index')); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Extension/CoreTest.php b/vendor/twig/twig/test/Twig/Tests/Extension/CoreTest.php deleted file mode 100644 index a4692c267..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Extension/CoreTest.php +++ /dev/null @@ -1,156 +0,0 @@ -getMock('Twig_LoaderInterface')); - - for ($i = 0; $i < 100; ++$i) { - $this->assertTrue(in_array(twig_random($env, $value), $expectedInArray, true)); // assertContains() would not consider the type - } - } - - public function getRandomFunctionTestData() - { - return array( - array(// array - array('apple', 'orange', 'citrus'), - array('apple', 'orange', 'citrus'), - ), - array(// Traversable - new ArrayObject(array('apple', 'orange', 'citrus')), - array('apple', 'orange', 'citrus'), - ), - array(// unicode string - 'Ä€é', - array('Ä', '€', 'é'), - ), - array(// numeric but string - '123', - array('1', '2', '3'), - ), - array(// integer - 5, - range(0, 5, 1), - ), - array(// float - 5.9, - range(0, 5, 1), - ), - array(// negative - -2, - array(0, -1, -2), - ), - ); - } - - public function testRandomFunctionWithoutParameter() - { - $max = mt_getrandmax(); - - for ($i = 0; $i < 100; ++$i) { - $val = twig_random(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $this->assertTrue(is_int($val) && $val >= 0 && $val <= $max); - } - } - - public function testRandomFunctionReturnsAsIs() - { - $this->assertSame('', twig_random(new Twig_Environment($this->getMock('Twig_LoaderInterface')), '')); - $this->assertSame('', twig_random(new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('charset' => null)), '')); - - $instance = new stdClass(); - $this->assertSame($instance, twig_random(new Twig_Environment($this->getMock('Twig_LoaderInterface')), $instance)); - } - - /** - * @expectedException Twig_Error_Runtime - */ - public function testRandomFunctionOfEmptyArrayThrowsException() - { - twig_random(new Twig_Environment($this->getMock('Twig_LoaderInterface')), array()); - } - - public function testRandomFunctionOnNonUTF8String() - { - if (!function_exists('iconv') && !function_exists('mb_convert_encoding')) { - $this->markTestSkipped('needs iconv or mbstring'); - } - - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->setCharset('ISO-8859-1'); - - $text = twig_convert_encoding('Äé', 'ISO-8859-1', 'UTF-8'); - for ($i = 0; $i < 30; ++$i) { - $rand = twig_random($twig, $text); - $this->assertTrue(in_array(twig_convert_encoding($rand, 'UTF-8', 'ISO-8859-1'), array('Ä', 'é'), true)); - } - } - - public function testReverseFilterOnNonUTF8String() - { - if (!function_exists('iconv') && !function_exists('mb_convert_encoding')) { - $this->markTestSkipped('needs iconv or mbstring'); - } - - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->setCharset('ISO-8859-1'); - - $input = twig_convert_encoding('Äé', 'ISO-8859-1', 'UTF-8'); - $output = twig_convert_encoding(twig_reverse_filter($twig, $input), 'UTF-8', 'ISO-8859-1'); - - $this->assertEquals($output, 'éÄ'); - } - - public function testCustomEscaper() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $twig->getExtension('core')->setEscaper('foo', 'foo_escaper_for_test'); - - $this->assertEquals('fooUTF-8', twig_escape_filter($twig, 'foo', 'foo')); - } - - /** - * @expectedException Twig_Error_Runtime - */ - public function testUnknownCustomEscaper() - { - twig_escape_filter(new Twig_Environment($this->getMock('Twig_LoaderInterface')), 'foo', 'bar'); - } - - public function testTwigFirst() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $this->assertEquals('a', twig_first($twig, 'abc')); - $this->assertEquals(1, twig_first($twig, array(1, 2, 3))); - $this->assertSame('', twig_first($twig, null)); - $this->assertSame('', twig_first($twig, '')); - } - - public function testTwigLast() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $this->assertEquals('c', twig_last($twig, 'abc')); - $this->assertEquals(3, twig_last($twig, array(1, 2, 3))); - $this->assertSame('', twig_last($twig, null)); - $this->assertSame('', twig_last($twig, '')); - } -} - -function foo_escaper_for_test(Twig_Environment $env, $string, $charset) -{ - return $string.$charset; -} diff --git a/vendor/twig/twig/test/Twig/Tests/Extension/SandboxTest.php b/vendor/twig/twig/test/Twig/Tests/Extension/SandboxTest.php deleted file mode 100644 index d21fb231b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Extension/SandboxTest.php +++ /dev/null @@ -1,220 +0,0 @@ - 'Fabien', - 'obj' => new FooObject(), - 'arr' => array('obj' => new FooObject()), - ); - - self::$templates = array( - '1_basic1' => '{{ obj.foo }}', - '1_basic2' => '{{ name|upper }}', - '1_basic3' => '{% if name %}foo{% endif %}', - '1_basic4' => '{{ obj.bar }}', - '1_basic5' => '{{ obj }}', - '1_basic6' => '{{ arr.obj }}', - '1_basic7' => '{{ cycle(["foo","bar"], 1) }}', - '1_basic8' => '{{ obj.getfoobar }}{{ obj.getFooBar }}', - '1_basic9' => '{{ obj.foobar }}{{ obj.fooBar }}', - '1_basic' => '{% if obj.foo %}{{ obj.foo|upper }}{% endif %}', - '1_layout' => '{% block content %}{% endblock %}', - '1_child' => "{% extends \"1_layout\" %}\n{% block content %}\n{{ \"a\"|json_encode }}\n{% endblock %}", - ); - } - - /** - * @expectedException Twig_Sandbox_SecurityError - * @expectedExceptionMessage Filter "json_encode" is not allowed in "1_child" at line 3. - */ - public function testSandboxWithInheritance() - { - $twig = $this->getEnvironment(true, array(), self::$templates, array('block')); - $twig->loadTemplate('1_child')->render(array()); - } - - public function testSandboxGloballySet() - { - $twig = $this->getEnvironment(false, array(), self::$templates); - $this->assertEquals('FOO', $twig->loadTemplate('1_basic')->render(self::$params), 'Sandbox does nothing if it is disabled globally'); - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic1')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed method is called'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic2')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed filter is called'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic3')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed tag is used in the template'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic4')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed property is called in the template'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic5')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed method (__toString()) is called in the template'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic6')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed method (__toString()) is called in the template'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('1_basic7')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception if an unallowed function is called in the template'); - } catch (Twig_Sandbox_SecurityError $e) { - } - - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array(), array('FooObject' => 'foo')); - FooObject::reset(); - $this->assertEquals('foo', $twig->loadTemplate('1_basic1')->render(self::$params), 'Sandbox allow some methods'); - $this->assertEquals(1, FooObject::$called['foo'], 'Sandbox only calls method once'); - - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array(), array('FooObject' => '__toString')); - FooObject::reset(); - $this->assertEquals('foo', $twig->loadTemplate('1_basic5')->render(self::$params), 'Sandbox allow some methods'); - $this->assertEquals(1, FooObject::$called['__toString'], 'Sandbox only calls method once'); - - $twig = $this->getEnvironment(false, array(), self::$templates); - FooObject::reset(); - $this->assertEquals('foo', $twig->loadTemplate('1_basic5')->render(self::$params), 'Sandbox allows __toString when sandbox disabled'); - $this->assertEquals(1, FooObject::$called['__toString'], 'Sandbox only calls method once'); - - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array('upper')); - $this->assertEquals('FABIEN', $twig->loadTemplate('1_basic2')->render(self::$params), 'Sandbox allow some filters'); - - $twig = $this->getEnvironment(true, array(), self::$templates, array('if')); - $this->assertEquals('foo', $twig->loadTemplate('1_basic3')->render(self::$params), 'Sandbox allow some tags'); - - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array(), array(), array('FooObject' => 'bar')); - $this->assertEquals('bar', $twig->loadTemplate('1_basic4')->render(self::$params), 'Sandbox allow some properties'); - - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array(), array(), array(), array('cycle')); - $this->assertEquals('bar', $twig->loadTemplate('1_basic7')->render(self::$params), 'Sandbox allow some functions'); - - foreach (array('getfoobar', 'getFoobar', 'getFooBar') as $name) { - $twig = $this->getEnvironment(true, array(), self::$templates, array(), array(), array('FooObject' => $name)); - FooObject::reset(); - $this->assertEquals('foobarfoobar', $twig->loadTemplate('1_basic8')->render(self::$params), 'Sandbox allow methods in a case-insensitive way'); - $this->assertEquals(2, FooObject::$called['getFooBar'], 'Sandbox only calls method once'); - - $this->assertEquals('foobarfoobar', $twig->loadTemplate('1_basic9')->render(self::$params), 'Sandbox allow methods via shortcut names (ie. without get/set)'); - } - } - - public function testSandboxLocallySetForAnInclude() - { - self::$templates = array( - '2_basic' => '{{ obj.foo }}{% include "2_included" %}{{ obj.foo }}', - '2_included' => '{% if obj.foo %}{{ obj.foo|upper }}{% endif %}', - ); - - $twig = $this->getEnvironment(false, array(), self::$templates); - $this->assertEquals('fooFOOfoo', $twig->loadTemplate('2_basic')->render(self::$params), 'Sandbox does nothing if disabled globally and sandboxed not used for the include'); - - self::$templates = array( - '3_basic' => '{{ obj.foo }}{% sandbox %}{% include "3_included" %}{% endsandbox %}{{ obj.foo }}', - '3_included' => '{% if obj.foo %}{{ obj.foo|upper }}{% endif %}', - ); - - $twig = $this->getEnvironment(true, array(), self::$templates); - try { - $twig->loadTemplate('3_basic')->render(self::$params); - $this->fail('Sandbox throws a SecurityError exception when the included file is sandboxed'); - } catch (Twig_Sandbox_SecurityError $e) { - } - } - - public function testMacrosInASandbox() - { - $twig = $this->getEnvironment(true, array('autoescape' => 'html'), array('index' => <<{{ text }}

    {% endmacro %} - -{{- macros.test('username') }} -EOF - ), array('macro', 'import'), array('escape')); - - $this->assertEquals('

    username

    ', $twig->loadTemplate('index')->render(array())); - } - - protected function getEnvironment($sandboxed, $options, $templates, $tags = array(), $filters = array(), $methods = array(), $properties = array(), $functions = array()) - { - $loader = new Twig_Loader_Array($templates); - $twig = new Twig_Environment($loader, array_merge(array('debug' => true, 'cache' => false, 'autoescape' => false), $options)); - $policy = new Twig_Sandbox_SecurityPolicy($tags, $filters, $methods, $properties, $functions); - $twig->addExtension(new Twig_Extension_Sandbox($policy, $sandboxed)); - - return $twig; - } -} - -class FooObject -{ - public static $called = array('__toString' => 0, 'foo' => 0, 'getFooBar' => 0); - - public $bar = 'bar'; - - public static function reset() - { - self::$called = array('__toString' => 0, 'foo' => 0, 'getFooBar' => 0); - } - - public function __toString() - { - ++self::$called['__toString']; - - return 'foo'; - } - - public function foo() - { - ++self::$called['foo']; - - return 'foo'; - } - - public function getFooBar() - { - ++self::$called['getFooBar']; - - return 'foobar'; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/FileCachingTest.php b/vendor/twig/twig/test/Twig/Tests/FileCachingTest.php deleted file mode 100644 index 14e0144c6..000000000 --- a/vendor/twig/twig/test/Twig/Tests/FileCachingTest.php +++ /dev/null @@ -1,85 +0,0 @@ -tmpDir = sys_get_temp_dir().'/TwigTests'; - if (!file_exists($this->tmpDir)) { - @mkdir($this->tmpDir, 0777, true); - } - - if (!is_writable($this->tmpDir)) { - $this->markTestSkipped(sprintf('Unable to run the tests as "%s" is not writable.', $this->tmpDir)); - } - - $this->env = new Twig_Environment(new Twig_Loader_Array(array('index' => 'index', 'index2' => 'index2')), array('cache' => $this->tmpDir)); - } - - public function tearDown() - { - if ($this->fileName) { - unlink($this->fileName); - } - - $this->removeDir($this->tmpDir); - } - - /** - * @group legacy - */ - public function testWritingCacheFiles() - { - $name = 'index'; - $this->env->loadTemplate($name); - $cacheFileName = $this->env->getCacheFilename($name); - - $this->assertTrue(file_exists($cacheFileName), 'Cache file does not exist.'); - $this->fileName = $cacheFileName; - } - - /** - * @group legacy - */ - public function testClearingCacheFiles() - { - $name = 'index2'; - $this->env->loadTemplate($name); - $cacheFileName = $this->env->getCacheFilename($name); - - $this->assertTrue(file_exists($cacheFileName), 'Cache file does not exist.'); - $this->env->clearCacheFiles(); - $this->assertFalse(file_exists($cacheFileName), 'Cache file was not cleared.'); - } - - private function removeDir($target) - { - $fp = opendir($target); - while (false !== $file = readdir($fp)) { - if (in_array($file, array('.', '..'))) { - continue; - } - - if (is_dir($target.'/'.$file)) { - self::removeDir($target.'/'.$file); - } else { - unlink($target.'/'.$file); - } - } - closedir($fp); - rmdir($target); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/FileExtensionEscapingStrategyTest.php b/vendor/twig/twig/test/Twig/Tests/FileExtensionEscapingStrategyTest.php deleted file mode 100644 index b310a5be3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/FileExtensionEscapingStrategyTest.php +++ /dev/null @@ -1,51 +0,0 @@ -assertSame($strategy, Twig_FileExtensionEscapingStrategy::guess($filename)); - } - - public function getGuessData() - { - return array( - // default - array('html', 'foo.html'), - array('html', 'foo.html.twig'), - array('html', 'foo'), - array('html', 'foo.bar.twig'), - array('html', 'foo.txt/foo'), - array('html', 'foo.txt/foo.js/'), - - // css - array('css', 'foo.css'), - array('css', 'foo.css.twig'), - array('css', 'foo.twig.css'), - array('css', 'foo.js.css'), - array('css', 'foo.js.css.twig'), - - // js - array('js', 'foo.js'), - array('js', 'foo.js.twig'), - array('js', 'foo.txt/foo.js'), - array('js', 'foo.txt.twig/foo.js'), - - // txt - array(false, 'foo.txt'), - array(false, 'foo.txt.twig'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/autoescape/filename.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/autoescape/filename.test deleted file mode 100644 index b091ad34d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/autoescape/filename.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"filename" autoescape strategy ---TEMPLATE-- -{{ br -}} -{{ include('index.html.twig') -}} -{{ include('index.txt.twig') -}} ---TEMPLATE(index.html.twig)-- -{{ br -}} ---TEMPLATE(index.txt.twig)-- -{{ br -}} ---DATA-- -return array('br' => '
    ') ---CONFIG-- -return array('autoescape' => 'filename') ---EXPECT-- -<br /> -<br /> -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/base.html b/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/base.html deleted file mode 100644 index cb0dbe444..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/base.html +++ /dev/null @@ -1 +0,0 @@ -{% block content %}{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/index.html b/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/index.html deleted file mode 100644 index df57c822f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/errors/index.html +++ /dev/null @@ -1,7 +0,0 @@ -{% extends 'base.html' %} -{% block content %} - {{ foo.bar }} -{% endblock %} -{% block foo %} - {{ foo.bar }} -{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable.test deleted file mode 100644 index ce49165dc..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -Exception for multiline array with undefined variable ---TEMPLATE-- -{% set foo = { - foo: 'foo', - bar: 'bar', - - - foobar: foobar, - - - - foo2: foo2, -} %} ---DATA-- -return array('foobar' => 'foobar') ---EXCEPTION-- -Twig_Error_Runtime: Variable "foo2" does not exist in "index.twig" at line 11 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable_again.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable_again.test deleted file mode 100644 index e3c040f9c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_array_with_undefined_variable_again.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -Exception for multiline array with undefined variable ---TEMPLATE-- -{% set foo = { - foo: 'foo', - bar: 'bar', - - - foobar: foobar, - - - - foo2: foo2, -} %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Runtime: Variable "foobar" does not exist in "index.twig" at line 7 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_undefined_variable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_undefined_variable.test deleted file mode 100644 index d799a3906..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_undefined_variable.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Exception for multile function with undefined variable ---TEMPLATE-- -{{ include('foo', - with_context=with_context -) }} ---TEMPLATE(foo)-- -Foo ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Runtime: Variable "with_context" does not exist in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_unknown_argument.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_unknown_argument.test deleted file mode 100644 index 64761fcf1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_function_with_unknown_argument.test +++ /dev/null @@ -1,9 +0,0 @@ ---TEST-- -Exception for multiline function with unknown argument ---TEMPLATE-- -{{ include('foo', - with_context=True, - invalid=False -) }} ---EXCEPTION-- -Twig_Error_Syntax: Unknown argument "invalid" for function "include(template, variables, with_context, ignore_missing, sandboxed)" in "index.twig" at line 4. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_tag_with_undefined_variable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_tag_with_undefined_variable.test deleted file mode 100644 index 096a5dbf5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/multiline_tag_with_undefined_variable.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Exception for multiline tag with undefined variable ---TEMPLATE-- -{% include 'foo' - with vars -%} ---TEMPLATE(foo)-- -Foo ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Runtime: Variable "vars" does not exist in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/syntax_error_in_reused_template.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/syntax_error_in_reused_template.test deleted file mode 100644 index 5dd9f3838..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/syntax_error_in_reused_template.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Exception for syntax error in reused template ---TEMPLATE-- -{% use 'foo.twig' %} ---TEMPLATE(foo.twig)-- -{% block bar %} - {% do node.data = 5 %} -{% endblock %} ---EXCEPTION-- -Twig_Error_Syntax: Unexpected token "operator" of value "=" ("end of statement block" expected) in "foo.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/unclosed_tag.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/unclosed_tag.test deleted file mode 100644 index 02245e931..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/unclosed_tag.test +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -Exception for an unclosed tag ---TEMPLATE-- -{% block foo %} - {% if foo %} - - - - - {% for i in fo %} - - - - {% endfor %} - - - -{% endblock %} ---EXCEPTION-- -Twig_Error_Syntax: Unexpected tag name "endblock" (expecting closing tag for the "if" tag defined near line 4) in "index.twig" at line 16 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_parent.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_parent.test deleted file mode 100644 index c8e7a0973..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_parent.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Exception for an undefined parent ---TEMPLATE-- -{% extends 'foo.html' %} - -{% set foo = "foo" %} ---EXCEPTION-- -Twig_Error_Loader: Template "foo.html" is not defined in "index.twig" at line 2. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_template_in_child_template.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_template_in_child_template.test deleted file mode 100644 index 1992510b2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_template_in_child_template.test +++ /dev/null @@ -1,15 +0,0 @@ ---TEST-- -Exception for an undefined template in a child template ---TEMPLATE-- -{% extends 'base.twig' %} - -{% block sidebar %} - {{ include('include.twig') }} -{% endblock %} ---TEMPLATE(base.twig)-- -{% block sidebar %} -{% endblock %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Loader: Template "include.twig" is not defined in "index.twig" at line 5. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_trait.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_trait.test deleted file mode 100644 index 6679fbe13..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/exceptions/undefined_trait.test +++ /dev/null @@ -1,9 +0,0 @@ ---TEST-- -Exception for an undefined trait ---TEMPLATE-- -{% use 'foo' with foobar as bar %} ---TEMPLATE(foo)-- -{% block bar %} -{% endblock %} ---EXCEPTION-- -Twig_Error_Runtime: Block "foobar" is not defined in trait "foo" in "index.twig" at line 2. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array.test deleted file mode 100644 index c69b1192f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array.test +++ /dev/null @@ -1,61 +0,0 @@ ---TEST-- -Twig supports array notation ---TEMPLATE-- -{# empty array #} -{{ []|join(',') }} - -{{ [1, 2]|join(',') }} -{{ ['foo', "bar"]|join(',') }} -{{ {0: 1, 'foo': 'bar'}|join(',') }} -{{ {0: 1, 'foo': 'bar'}|keys|join(',') }} - -{{ {0: 1, foo: 'bar'}|join(',') }} -{{ {0: 1, foo: 'bar'}|keys|join(',') }} - -{# nested arrays #} -{% set a = [1, 2, [1, 2], {'foo': {'foo': 'bar'}}] %} -{{ a[2]|join(',') }} -{{ a[3]["foo"]|join(',') }} - -{# works even if [] is used inside the array #} -{{ [foo[bar]]|join(',') }} - -{# elements can be any expression #} -{{ ['foo'|upper, bar|upper, bar == foo]|join(',') }} - -{# arrays can have a trailing , like in PHP #} -{{ - [ - 1, - 2, - ]|join(',') -}} - -{# keys can be any expression #} -{% set a = 1 %} -{% set b = "foo" %} -{% set ary = { (a): 'a', (b): 'b', 'c': 'c', (a ~ b): 'd' } %} -{{ ary|keys|join(',') }} -{{ ary|join(',') }} ---DATA-- -return array('bar' => 'bar', 'foo' => array('bar' => 'bar')) ---EXPECT-- -1,2 -foo,bar -1,bar -0,foo - -1,bar -0,foo - -1,2 -bar - -bar - -FOO,BAR, - -1,2 - -1,foo,c,1foo -a,b,c,d diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array_call.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array_call.test deleted file mode 100644 index f3df328fe..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/array_call.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -Twig supports method calls ---TEMPLATE-- -{{ items.foo }} -{{ items['foo'] }} -{{ items[foo] }} -{{ items[items[foo]] }} ---DATA-- -return array('foo' => 'bar', 'items' => array('foo' => 'bar', 'bar' => 'foo')) ---EXPECT-- -bar -bar -foo -bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/binary.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/binary.test deleted file mode 100644 index f5e68456d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/binary.test +++ /dev/null @@ -1,46 +0,0 @@ ---TEST-- -Twig supports binary operations (+, -, *, /, ~, %, and, or) ---TEMPLATE-- -{{ 1 + 1 }} -{{ 2 - 1 }} -{{ 2 * 2 }} -{{ 2 / 2 }} -{{ 3 % 2 }} -{{ 1 and 1 }} -{{ 1 and 0 }} -{{ 0 and 1 }} -{{ 0 and 0 }} -{{ 1 or 1 }} -{{ 1 or 0 }} -{{ 0 or 1 }} -{{ 0 or 0 }} -{{ 0 or 1 and 0 }} -{{ 1 or 0 and 1 }} -{{ "foo" ~ "bar" }} -{{ foo ~ "bar" }} -{{ "foo" ~ bar }} -{{ foo ~ bar }} -{{ 20 // 7 }} ---DATA-- -return array('foo' => 'bar', 'bar' => 'foo') ---EXPECT-- -2 -1 -4 -1 -1 -1 - - - -1 -1 -1 - - -1 -foobar -barbar -foofoo -barfoo -2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/bitwise.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/bitwise.test deleted file mode 100644 index 74fe6cabb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/bitwise.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -Twig supports bitwise operations ---TEMPLATE-- -{{ 1 b-and 5 }} -{{ 1 b-or 5 }} -{{ 1 b-xor 5 }} -{{ (1 and 0 b-or 0) is same as(1 and (0 b-or 0)) ? 'ok' : 'ko' }} ---DATA-- -return array() ---EXPECT-- -1 -5 -4 -ok diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/comparison.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/comparison.test deleted file mode 100644 index 726b85075..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/comparison.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -Twig supports comparison operators (==, !=, <, >, >=, <=) ---TEMPLATE-- -{{ 1 > 2 }}/{{ 1 > 1 }}/{{ 1 >= 2 }}/{{ 1 >= 1 }} -{{ 1 < 2 }}/{{ 1 < 1 }}/{{ 1 <= 2 }}/{{ 1 <= 1 }} -{{ 1 == 1 }}/{{ 1 == 2 }} -{{ 1 != 1 }}/{{ 1 != 2 }} ---DATA-- -return array() ---EXPECT-- -///1 -1//1/1 -1/ -/1 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/divisibleby.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/divisibleby.test deleted file mode 100644 index 238dd2790..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/divisibleby.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -Twig supports the "divisible by" operator ---TEMPLATE-- -{{ 8 is divisible by(2) ? 'OK' }} -{{ 8 is not divisible by(3) ? 'OK' }} -{{ 8 is divisible by (2) ? 'OK' }} -{{ 8 is not - divisible - by - (3) ? 'OK' }} ---DATA-- -return array() ---EXPECT-- -OK -OK -OK -OK diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/dotdot.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/dotdot.test deleted file mode 100644 index 9cd0676ce..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/dotdot.test +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -Twig supports the .. operator ---TEMPLATE-- -{% for i in 0..10 %}{{ i }} {% endfor %} - -{% for letter in 'a'..'z' %}{{ letter }} {% endfor %} - -{% for letter in 'a'|upper..'z'|upper %}{{ letter }} {% endfor %} - -{% for i in foo[0]..foo[1] %}{{ i }} {% endfor %} - -{% for i in 0 + 1 .. 10 - 1 %}{{ i }} {% endfor %} ---DATA-- -return array('foo' => array(1, 10)) ---EXPECT-- -0 1 2 3 4 5 6 7 8 9 10 -a b c d e f g h i j k l m n o p q r s t u v w x y z -A B C D E F G H I J K L M N O P Q R S T U V W X Y Z -1 2 3 4 5 6 7 8 9 10 -1 2 3 4 5 6 7 8 9 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ends_with.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ends_with.test deleted file mode 100644 index 9ad5e5e8e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ends_with.test +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -Twig supports the "ends with" operator ---TEMPLATE-- -{{ 'foo' ends with 'o' ? 'OK' : 'KO' }} -{{ not ('foo' ends with 'f') ? 'OK' : 'KO' }} -{{ not ('foo' ends with 'foowaytoolong') ? 'OK' : 'KO' }} -{{ 'foo' ends with '' ? 'OK' : 'KO' }} -{{ '1' ends with true ? 'OK' : 'KO' }} -{{ 1 ends with true ? 'OK' : 'KO' }} -{{ 0 ends with false ? 'OK' : 'KO' }} -{{ '' ends with false ? 'OK' : 'KO' }} -{{ false ends with false ? 'OK' : 'KO' }} -{{ false ends with '' ? 'OK' : 'KO' }} ---DATA-- -return array() ---EXPECT-- -OK -OK -OK -OK -KO -KO -KO -KO -KO -KO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/grouping.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/grouping.test deleted file mode 100644 index 79f8e0b0d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/grouping.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Twig supports grouping of expressions ---TEMPLATE-- -{{ (2 + 2) / 2 }} ---DATA-- -return array() ---EXPECT-- -2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/literals.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/literals.test deleted file mode 100644 index 7ae3bae95..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/literals.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Twig supports literals ---TEMPLATE-- -1 {{ true }} -2 {{ TRUE }} -3 {{ false }} -4 {{ FALSE }} -5 {{ none }} -6 {{ NONE }} -7 {{ null }} -8 {{ NULL }} ---DATA-- -return array() ---EXPECT-- -1 1 -2 1 -3 -4 -5 -6 -7 -8 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/magic_call.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/magic_call.test deleted file mode 100644 index 159db96f5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/magic_call.test +++ /dev/null @@ -1,27 +0,0 @@ ---TEST-- -Twig supports __call() for attributes ---TEMPLATE-- -{{ foo.foo }} -{{ foo.bar }} ---DATA-- -class TestClassForMagicCallAttributes -{ - public function getBar() - { - return 'bar_from_getbar'; - } - - public function __call($method, $arguments) - { - if ('foo' === $method) - { - return 'foo_from_call'; - } - - return false; - } -} -return array('foo' => new TestClassForMagicCallAttributes()) ---EXPECT-- -foo_from_call -bar_from_getbar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/matches.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/matches.test deleted file mode 100644 index b6c771657..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/matches.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Twig supports the "matches" operator ---TEMPLATE-- -{{ 'foo' matches '/o/' ? 'OK' : 'KO' }} -{{ 'foo' matches '/^fo/' ? 'OK' : 'KO' }} -{{ 'foo' matches '/O/i' ? 'OK' : 'KO' }} ---DATA-- -return array() ---EXPECT-- -OK -OK -OK diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/method_call.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/method_call.test deleted file mode 100644 index 5f801e635..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/method_call.test +++ /dev/null @@ -1,28 +0,0 @@ ---TEST-- -Twig supports method calls ---TEMPLATE-- -{{ items.foo.foo }} -{{ items.foo.getFoo() }} -{{ items.foo.bar }} -{{ items.foo['bar'] }} -{{ items.foo.bar('a', 43) }} -{{ items.foo.bar(foo) }} -{{ items.foo.self.foo() }} -{{ items.foo.is }} -{{ items.foo.in }} -{{ items.foo.not }} ---DATA-- -return array('foo' => 'bar', 'items' => array('foo' => new TwigTestFoo(), 'bar' => 'foo')) ---CONFIG-- -return array('strict_variables' => false) ---EXPECT-- -foo -foo -bar - -bar_a-43 -bar_bar -foo -is -in -not diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/negative_numbers.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/negative_numbers.test deleted file mode 100644 index 1853b1b06..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/negative_numbers.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -Twig manages negative numbers correctly ---TEMPLATE-- -{{ -1 }} -{{ - 1 }} -{{ 5 - 1 }} -{{ 5-1 }} -{{ 5 + -1 }} -{{ 5 + - 1 }} ---DATA-- -return array() ---EXPECT-- --1 --1 -4 -4 -4 -4 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/operators_as_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/operators_as_variables.test deleted file mode 100644 index fe29d08bb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/operators_as_variables.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -Twig allows to use named operators as variable names ---TEMPLATE-- -{% for match in matches %} - {{- match }} -{% endfor %} -{{ in }} -{{ is }} ---DATA-- -return array('matches' => array(1, 2, 3), 'in' => 'in', 'is' => 'is') ---EXPECT-- -1 -2 -3 -in -is diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/postfix.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/postfix.test deleted file mode 100644 index 542c35046..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/postfix.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Twig parses postfix expressions ---TEMPLATE-- -{% import _self as macros %} - -{% macro foo() %}foo{% endmacro %} - -{{ 'a' }} -{{ 'a'|upper }} -{{ ('a')|upper }} -{{ -1|upper }} -{{ macros.foo() }} -{{ (macros).foo() }} ---DATA-- -return array(); ---EXPECT-- -a -A -A --1 -foo -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/sameas.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/sameas.test deleted file mode 100644 index 601201deb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/sameas.test +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -Twig supports the "same as" operator ---TEMPLATE-- -{{ 1 is same as(1) ? 'OK' }} -{{ 1 is not same as(true) ? 'OK' }} -{{ 1 is same as(1) ? 'OK' }} -{{ 1 is not same as(true) ? 'OK' }} -{{ 1 is same as (1) ? 'OK' }} -{{ 1 is not - same - as - (true) ? 'OK' }} ---DATA-- -return array() ---EXPECT-- -OK -OK -OK -OK -OK -OK diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/starts_with.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/starts_with.test deleted file mode 100644 index 75d331e90..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/starts_with.test +++ /dev/null @@ -1,27 +0,0 @@ ---TEST-- -Twig supports the "starts with" operator ---TEMPLATE-- -{{ 'foo' starts with 'f' ? 'OK' : 'KO' }} -{{ not ('foo' starts with 'oo') ? 'OK' : 'KO' }} -{{ not ('foo' starts with 'foowaytoolong') ? 'OK' : 'KO' }} -{{ 'foo' starts with 'f' ? 'OK' : 'KO' }} -{{ 'foo' starts -with 'f' ? 'OK' : 'KO' }} -{{ 'foo' starts with '' ? 'OK' : 'KO' }} -{{ '1' starts with true ? 'OK' : 'KO' }} -{{ '' starts with false ? 'OK' : 'KO' }} -{{ 'a' starts with false ? 'OK' : 'KO' }} -{{ false starts with '' ? 'OK' : 'KO' }} ---DATA-- -return array() ---EXPECT-- -OK -OK -OK -OK -OK -OK -KO -KO -KO -KO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/strings.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/strings.test deleted file mode 100644 index a9116613e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/strings.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Twig supports string interpolation ---TEMPLATE-- -{{ "foo #{"foo #{bar} baz"} baz" }} -{{ "foo #{bar}#{bar} baz" }} ---DATA-- -return array('bar' => 'BAR'); ---EXPECT-- -foo foo BAR baz baz -foo BARBAR baz diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator.test deleted file mode 100644 index 0e6fa96e2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -Twig supports the ternary operator ---TEMPLATE-- -{{ 1 ? 'YES' : 'NO' }} -{{ 0 ? 'YES' : 'NO' }} -{{ 0 ? 'YES' : (1 ? 'YES1' : 'NO1') }} -{{ 0 ? 'YES' : (0 ? 'YES1' : 'NO1') }} -{{ 1 == 1 ? 'foo
    ':'' }} -{{ foo ~ (bar ? ('-' ~ bar) : '') }} ---DATA-- -return array('foo' => 'foo', 'bar' => 'bar') ---EXPECT-- -YES -NO -YES1 -NO1 -foo
    -foo-bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_noelse.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_noelse.test deleted file mode 100644 index fdc660fc5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_noelse.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Twig supports the ternary operator ---TEMPLATE-- -{{ 1 ? 'YES' }} -{{ 0 ? 'YES' }} ---DATA-- -return array() ---EXPECT-- -YES - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_nothen.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_nothen.test deleted file mode 100644 index 9057e8370..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/ternary_operator_nothen.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Twig supports the ternary operator ---TEMPLATE-- -{{ 'YES' ?: 'NO' }} -{{ 0 ?: 'NO' }} ---DATA-- -return array() ---EXPECT-- -YES -NO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/two_word_operators_as_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/two_word_operators_as_variables.test deleted file mode 100644 index 47f37e450..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/two_word_operators_as_variables.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Twig does not allow to use two-word named operators as variable names ---TEMPLATE-- -{{ starts with }} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: Unexpected token "operator" of value "starts with" in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary.test deleted file mode 100644 index b79219a2a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Twig supports unary operators (not, -, +) ---TEMPLATE-- -{{ not 1 }}/{{ not 0 }} -{{ +1 + 1 }}/{{ -1 - 1 }} -{{ not (false or true) }} ---DATA-- -return array() ---EXPECT-- -/1 -2/-2 - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_macro_arguments.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_macro_arguments.test deleted file mode 100644 index ad84a9c26..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_macro_arguments.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Twig manages negative numbers as default parameters ---TEMPLATE-- -{% import _self as macros %} -{{ macros.negative_number1() }} -{{ macros.negative_number2() }} -{{ macros.negative_number3() }} -{{ macros.positive_number1() }} -{{ macros.positive_number2() }} -{% macro negative_number1(nb=-1) %}{{ nb }}{% endmacro %} -{% macro negative_number2(nb = --1) %}{{ nb }}{% endmacro %} -{% macro negative_number3(nb = - 1) %}{{ nb }}{% endmacro %} -{% macro positive_number1(nb = +1) %}{{ nb }}{% endmacro %} -{% macro positive_number2(nb = ++1) %}{{ nb }}{% endmacro %} ---DATA-- -return array() ---EXPECT-- --1 -1 --1 -1 -1 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_precedence.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_precedence.test deleted file mode 100644 index cc6eef8d2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/expressions/unary_precedence.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -Twig unary operators precedence ---TEMPLATE-- -{{ -1 - 1 }} -{{ -1 - -1 }} -{{ -1 * -1 }} -{{ 4 / -1 * 5 }} ---DATA-- -return array() ---EXPECT-- --2 -0 -1 --20 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/abs.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/abs.test deleted file mode 100644 index 27e93fd63..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/abs.test +++ /dev/null @@ -1,30 +0,0 @@ ---TEST-- -"abs" filter ---TEMPLATE-- -{{ (-5.5)|abs }} -{{ (-5)|abs }} -{{ (-0)|abs }} -{{ 0|abs }} -{{ 5|abs }} -{{ 5.5|abs }} -{{ number1|abs }} -{{ number2|abs }} -{{ number3|abs }} -{{ number4|abs }} -{{ number5|abs }} -{{ number6|abs }} ---DATA-- -return array('number1' => -5.5, 'number2' => -5, 'number3' => -0, 'number4' => 0, 'number5' => 5, 'number6' => 5.5) ---EXPECT-- -5.5 -5 -0 -0 -5 -5.5 -5.5 -5 -0 -0 -5 -5.5 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch.test deleted file mode 100644 index cb6de7f97..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch.test +++ /dev/null @@ -1,31 +0,0 @@ ---TEST-- -"batch" filter ---TEMPLATE-- -{% for row in items|batch(3) %} -
    - {% for column in row %} -
    {{ column }}
    - {% endfor %} -
    -{% endfor %} ---DATA-- -return array('items' => array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j')) ---EXPECT-- -
    -
    a
    -
    b
    -
    c
    -
    -
    -
    d
    -
    e
    -
    f
    -
    -
    -
    g
    -
    h
    -
    i
    -
    -
    -
    j
    -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_float.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_float.test deleted file mode 100644 index e2ec4beb2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_float.test +++ /dev/null @@ -1,29 +0,0 @@ ---TEST-- -"batch" filter ---TEMPLATE-- -{% for row in items|batch(3.1) %} -
    - {% for column in row %} -
    {{ column }}
    - {% endfor %} -
    -{% endfor %} ---DATA-- -return array('items' => array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j')) ---EXPECT-- -
    -
    a
    -
    b
    -
    c
    -
    d
    -
    -
    -
    e
    -
    f
    -
    g
    -
    h
    -
    -
    -
    i
    -
    j
    -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_empty_fill.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_empty_fill.test deleted file mode 100644 index af996f246..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_empty_fill.test +++ /dev/null @@ -1,37 +0,0 @@ ---TEST-- -"batch" filter ---TEMPLATE-- - -{% for row in items|batch(3, '') %} - - {% for column in row %} - - {% endfor %} - -{% endfor %} -
    {{ column }}
    ---DATA-- -return array('items' => array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j')) ---EXPECT-- - - - - - - - - - - - - - - - - - - - - - -
    abc
    def
    ghi
    j
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_exact_elements.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_exact_elements.test deleted file mode 100644 index 72483f4b5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_exact_elements.test +++ /dev/null @@ -1,33 +0,0 @@ ---TEST-- -"batch" filter ---TEMPLATE-- -{% for row in items|batch(3, 'fill') %} -
    - {% for column in row %} -
    {{ column }}
    - {% endfor %} -
    -{% endfor %} ---DATA-- -return array('items' => array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l')) ---EXPECT-- -
    -
    a
    -
    b
    -
    c
    -
    -
    -
    d
    -
    e
    -
    f
    -
    -
    -
    g
    -
    h
    -
    i
    -
    -
    -
    j
    -
    k
    -
    l
    -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_fill.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_fill.test deleted file mode 100644 index 746295f1b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_fill.test +++ /dev/null @@ -1,37 +0,0 @@ ---TEST-- -"batch" filter ---TEMPLATE-- - -{% for row in items|batch(3, 'fill') %} - - {% for column in row %} - - {% endfor %} - -{% endfor %} -
    {{ column }}
    ---DATA-- -return array('items' => array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j')) ---EXPECT-- - - - - - - - - - - - - - - - - - - - - - -
    abc
    def
    ghi
    jfillfill
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_keys.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_keys.test deleted file mode 100644 index 6015380e2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_keys.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"batch" filter preserves array keys ---TEMPLATE-- -{{ {'foo': 'bar', 'key': 'value'}|batch(4)|first|keys|join(',') }} -{{ {'foo': 'bar', 'key': 'value'}|batch(4, 'fill')|first|keys|join(',') }} ---DATA-- -return array() ---EXPECT-- -foo,key -foo,key,0,1 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_zero_elements.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_zero_elements.test deleted file mode 100644 index b9c058d6b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/batch_with_zero_elements.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"batch" filter with zero elements ---TEMPLATE-- -{{ []|batch(3)|length }} -{{ []|batch(3, 'fill')|length }} ---DATA-- -return array() ---EXPECT-- -0 -0 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/convert_encoding.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/convert_encoding.test deleted file mode 100644 index 380b04bb8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/convert_encoding.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"convert_encoding" filter ---CONDITION-- -function_exists('iconv') || function_exists('mb_convert_encoding') ---TEMPLATE-- -{{ "愛していますか?"|convert_encoding('ISO-2022-JP', 'UTF-8')|convert_encoding('UTF-8', 'ISO-2022-JP') }} ---DATA-- -return array() ---EXPECT-- -愛していますか? diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date.test deleted file mode 100644 index d17e5e2f0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date.test +++ /dev/null @@ -1,90 +0,0 @@ ---TEST-- -"date" filter ---TEMPLATE-- -{{ date1|date }} -{{ date1|date('d/m/Y') }} -{{ date1|date('d/m/Y H:i:s', 'Asia/Hong_Kong') }} -{{ date1|date('d/m/Y H:i:s P', 'Asia/Hong_Kong') }} -{{ date1|date('d/m/Y H:i:s P', 'America/Chicago') }} -{{ date1|date('e') }} -{{ date1|date('d/m/Y H:i:s') }} - -{{ date2|date }} -{{ date2|date('d/m/Y') }} -{{ date2|date('d/m/Y H:i:s', 'Asia/Hong_Kong') }} -{{ date2|date('d/m/Y H:i:s', timezone1) }} -{{ date2|date('d/m/Y H:i:s') }} - -{{ date3|date }} -{{ date3|date('d/m/Y') }} - -{{ date4|date }} -{{ date4|date('d/m/Y') }} - -{{ date5|date }} -{{ date5|date('d/m/Y') }} - -{{ date6|date('d/m/Y H:i:s P', 'Europe/Paris') }} -{{ date6|date('d/m/Y H:i:s P', 'Asia/Hong_Kong') }} -{{ date6|date('d/m/Y H:i:s P', false) }} -{{ date6|date('e', 'Europe/Paris') }} -{{ date6|date('e', false) }} - -{{ date7|date }} -{{ date7|date(timezone='Europe/Paris') }} -{{ date7|date(timezone='Asia/Hong_Kong') }} -{{ date7|date(timezone=false) }} -{{ date7|date(timezone='Indian/Mauritius') }} - -{{ '2010-01-28 15:00:00'|date(timezone="Europe/Paris") }} -{{ '2010-01-28 15:00:00'|date(timezone="Asia/Hong_Kong") }} ---DATA-- -date_default_timezone_set('Europe/Paris'); -return array( - 'date1' => mktime(13, 45, 0, 10, 4, 2010), - 'date2' => new DateTime('2010-10-04 13:45'), - 'date3' => '2010-10-04 13:45', - 'date4' => 1286199900, // DateTime::createFromFormat('Y-m-d H:i', '2010-10-04 13:45', new DateTimeZone('UTC'))->getTimestamp() -- A unixtimestamp is always GMT - 'date5' => -189291360, // DateTime::createFromFormat('Y-m-d H:i', '1964-01-02 03:04', new DateTimeZone('UTC'))->getTimestamp(), - 'date6' => new DateTime('2010-10-04 13:45', new DateTimeZone('America/New_York')), - 'date7' => '2010-01-28T15:00:00+04:00', - 'timezone1' => new DateTimeZone('America/New_York'), -) ---EXPECT-- -October 4, 2010 13:45 -04/10/2010 -04/10/2010 19:45:00 -04/10/2010 19:45:00 +08:00 -04/10/2010 06:45:00 -05:00 -Europe/Paris -04/10/2010 13:45:00 - -October 4, 2010 13:45 -04/10/2010 -04/10/2010 19:45:00 -04/10/2010 07:45:00 -04/10/2010 13:45:00 - -October 4, 2010 13:45 -04/10/2010 - -October 4, 2010 15:45 -04/10/2010 - -January 2, 1964 04:04 -02/01/1964 - -04/10/2010 19:45:00 +02:00 -05/10/2010 01:45:00 +08:00 -04/10/2010 13:45:00 -04:00 -Europe/Paris -America/New_York - -January 28, 2010 12:00 -January 28, 2010 12:00 -January 28, 2010 19:00 -January 28, 2010 15:00 -January 28, 2010 15:00 - -January 28, 2010 15:00 -January 28, 2010 22:00 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format.test deleted file mode 100644 index 11a1ef4bd..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"date" filter ---TEMPLATE-- -{{ date1|date }} -{{ date1|date('d/m/Y') }} ---DATA-- -date_default_timezone_set('UTC'); -$twig->getExtension('core')->setDateFormat('Y-m-d', '%d days %h hours'); -return array( - 'date1' => mktime(13, 45, 0, 10, 4, 2010), -) ---EXPECT-- -2010-10-04 -04/10/2010 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format_interval.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format_interval.test deleted file mode 100644 index e6d3707d9..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_default_format_interval.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"date" filter (interval support as of PHP 5.3) ---CONDITION-- -version_compare(phpversion(), '5.3.0', '>=') ---TEMPLATE-- -{{ date2|date }} -{{ date2|date('%d days') }} ---DATA-- -date_default_timezone_set('UTC'); -$twig->getExtension('core')->setDateFormat('Y-m-d', '%d days %h hours'); -return array( - 'date2' => new DateInterval('P2D'), -) ---EXPECT-- -2 days 0 hours -2 days diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_immutable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_immutable.test deleted file mode 100644 index 4e1832562..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_immutable.test +++ /dev/null @@ -1,37 +0,0 @@ ---TEST-- -"date" filter ---CONDITION-- -version_compare(phpversion(), '5.5.0', '>=') ---TEMPLATE-- -{{ date1|date }} -{{ date1|date('d/m/Y') }} -{{ date1|date('d/m/Y H:i:s', 'Asia/Hong_Kong') }} -{{ date1|date('d/m/Y H:i:s', timezone1) }} -{{ date1|date('d/m/Y H:i:s') }} -{{ date1|date_modify('+1 hour')|date('d/m/Y H:i:s') }} - -{{ date2|date('d/m/Y H:i:s P', 'Europe/Paris') }} -{{ date2|date('d/m/Y H:i:s P', 'Asia/Hong_Kong') }} -{{ date2|date('d/m/Y H:i:s P', false) }} -{{ date2|date('e', 'Europe/Paris') }} -{{ date2|date('e', false) }} ---DATA-- -date_default_timezone_set('Europe/Paris'); -return array( - 'date1' => new DateTimeImmutable('2010-10-04 13:45'), - 'date2' => new DateTimeImmutable('2010-10-04 13:45', new DateTimeZone('America/New_York')), - 'timezone1' => new DateTimeZone('America/New_York'), -) ---EXPECT-- -October 4, 2010 13:45 -04/10/2010 -04/10/2010 19:45:00 -04/10/2010 07:45:00 -04/10/2010 13:45:00 -04/10/2010 14:45:00 - -04/10/2010 19:45:00 +02:00 -05/10/2010 01:45:00 +08:00 -04/10/2010 13:45:00 -04:00 -Europe/Paris -America/New_York diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_interval.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_interval.test deleted file mode 100644 index 0c8c6f1a2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_interval.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -"date" filter (interval support as of PHP 5.3) ---CONDITION-- -version_compare(phpversion(), '5.3.0', '>=') ---TEMPLATE-- -{{ date1|date }} -{{ date1|date('%d days %h hours') }} -{{ date1|date('%d days %h hours', timezone1) }} ---DATA-- -date_default_timezone_set('UTC'); -return array( - 'date1' => new DateInterval('P2D'), - // This should have no effect on DateInterval formatting - 'timezone1' => new DateTimeZone('America/New_York'), -) ---EXPECT-- -2 days -2 days 0 hours -2 days 0 hours diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_modify.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_modify.test deleted file mode 100644 index 53d3a69cd..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_modify.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"date_modify" filter ---TEMPLATE-- -{{ date1|date_modify('-1day')|date('Y-m-d H:i:s') }} -{{ date2|date_modify('-1day')|date('Y-m-d H:i:s') }} ---DATA-- -date_default_timezone_set('UTC'); -return array( - 'date1' => '2010-10-04 13:45', - 'date2' => new DateTime('2010-10-04 13:45'), -) ---EXPECT-- -2010-10-03 13:45:00 -2010-10-03 13:45:00 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_namedargs.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_namedargs.test deleted file mode 100644 index 4ecde8a18..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/date_namedargs.test +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -"date" filter ---TEMPLATE-- -{{ date|date(format='d/m/Y H:i:s P', timezone='America/Chicago') }} -{{ date|date(timezone='America/Chicago', format='d/m/Y H:i:s P') }} -{{ date|date('d/m/Y H:i:s P', timezone='America/Chicago') }} ---DATA-- -date_default_timezone_set('UTC'); -return array('date' => mktime(13, 45, 0, 10, 4, 2010)) ---EXPECT-- -04/10/2010 08:45:00 -05:00 -04/10/2010 08:45:00 -05:00 -04/10/2010 08:45:00 -05:00 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/default.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/default.test deleted file mode 100644 index b8d1d66f5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/default.test +++ /dev/null @@ -1,150 +0,0 @@ ---TEST-- -"default" filter ---TEMPLATE-- -Variable: -{{ definedVar |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ zeroVar |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ emptyVar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ nullVar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ undefinedVar |default('default') is same as('default') ? 'ok' : 'ko' }} -Array access: -{{ nested.definedVar |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ nested['definedVar'] |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ nested.zeroVar |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ nested.emptyVar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ nested.nullVar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ nested.undefinedVar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ nested['undefinedVar'] |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ undefinedVar.foo |default('default') is same as('default') ? 'ok' : 'ko' }} -Plain values: -{{ 'defined' |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ 0 |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ '' |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ null |default('default') is same as('default') ? 'ok' : 'ko' }} -Precedence: -{{ 'o' ~ nullVar |default('k') }} -{{ 'o' ~ nested.nullVar |default('k') }} -Object methods: -{{ object.foo |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ object.undefinedMethod |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ object.getFoo() |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ object.getFoo('a') |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ object.undefinedMethod() |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ object.undefinedMethod('a') |default('default') is same as('default') ? 'ok' : 'ko' }} -Deep nested: -{{ nested.undefinedVar.foo.bar |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ nested.definedArray.0 |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ nested['definedArray'][0] |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ object.self.foo |default('default') is same as('default') ? 'ko' : 'ok' }} -{{ object.self.undefinedMethod |default('default') is same as('default') ? 'ok' : 'ko' }} -{{ object.undefinedMethod.self |default('default') is same as('default') ? 'ok' : 'ko' }} ---DATA-- -return array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'emptyVar' => '', - 'nullVar' => null, - 'nested' => array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'emptyVar' => '', - 'nullVar' => null, - 'definedArray' => array(0), - ), - 'object' => new TwigTestFoo(), -) ---CONFIG-- -return array('strict_variables' => false) ---EXPECT-- -Variable: -ok -ok -ok -ok -ok -Array access: -ok -ok -ok -ok -ok -ok -ok -ok -Plain values: -ok -ok -ok -ok -Precedence: -ok -ok -Object methods: -ok -ok -ok -ok -ok -ok -Deep nested: -ok -ok -ok -ok -ok -ok ---DATA-- -return array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'emptyVar' => '', - 'nullVar' => null, - 'nested' => array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'emptyVar' => '', - 'nullVar' => null, - 'definedArray' => array(0), - ), - 'object' => new TwigTestFoo(), -) ---CONFIG-- -return array('strict_variables' => true) ---EXPECT-- -Variable: -ok -ok -ok -ok -ok -Array access: -ok -ok -ok -ok -ok -ok -ok -ok -Plain values: -ok -ok -ok -ok -Precedence: -ok -ok -Object methods: -ok -ok -ok -ok -ok -ok -Deep nested: -ok -ok -ok -ok -ok -ok diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/dynamic_filter.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/dynamic_filter.test deleted file mode 100644 index 93c5913f2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/dynamic_filter.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -dynamic filter ---TEMPLATE-- -{{ 'bar'|foo_path }} -{{ 'bar'|a_foo_b_bar }} ---DATA-- -return array() ---EXPECT-- -foo/bar -a/b/bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape.test deleted file mode 100644 index a606c1065..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"escape" filter ---TEMPLATE-- -{{ "foo
    "|e }} ---DATA-- -return array() ---EXPECT-- -foo <br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_html_attr.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_html_attr.test deleted file mode 100644 index 009a24532..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_html_attr.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"escape" filter does not escape with the html strategy when using the html_attr strategy ---TEMPLATE-- -{{ '
    '|escape('html_attr') }} ---DATA-- -return array() ---EXPECT-- -<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_non_supported_charset.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_non_supported_charset.test deleted file mode 100644 index bba26a0df..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/escape_non_supported_charset.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"escape" filter ---TEMPLATE-- -{{ "愛していますか?
    "|e }} ---DATA-- -return array() ---EXPECT-- -愛していますか? <br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/first.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/first.test deleted file mode 100644 index aa54645c3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/first.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"first" filter ---TEMPLATE-- -{{ [1, 2, 3, 4]|first }} -{{ {a: 1, b: 2, c: 3, d: 4}|first }} -{{ '1234'|first }} -{{ arr|first }} -{{ 'Ä€é'|first }} -{{ ''|first }} ---DATA-- -return array('arr' => new ArrayObject(array(1, 2, 3, 4))) ---EXPECT-- -1 -1 -1 -1 -Ä diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/force_escape.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/force_escape.test deleted file mode 100644 index 85a9b7172..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/force_escape.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"escape" filter ---TEMPLATE-- -{% set foo %} - foo
    -{% endset %} - -{{ foo|e('html') -}} -{{ foo|e('js') }} -{% autoescape true %} - {{ foo }} -{% endautoescape %} ---DATA-- -return array() ---EXPECT-- - foo<br /> -\x20\x20\x20\x20foo\x3Cbr\x20\x2F\x3E\x0A - foo
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/format.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/format.test deleted file mode 100644 index 97221ff80..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/format.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"format" filter ---TEMPLATE-- -{{ string|format(foo, 3) }} ---DATA-- -return array('string' => '%s/%d', 'foo' => 'bar') ---EXPECT-- -bar/3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/join.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/join.test deleted file mode 100644 index b342c174c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/join.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"join" filter ---TEMPLATE-- -{{ ["foo", "bar"]|join(', ') }} -{{ foo|join(', ') }} -{{ bar|join(', ') }} ---DATA-- -return array('foo' => new TwigTestFoo(), 'bar' => new ArrayObject(array(3, 4))) ---EXPECT-- -foo, bar -1, 2 -3, 4 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/json_encode.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/json_encode.test deleted file mode 100644 index 1738d40cd..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/json_encode.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"json_encode" filter ---TEMPLATE-- -{{ "foo"|json_encode|raw }} -{{ foo|json_encode|raw }} -{{ [foo, "foo"]|json_encode|raw }} ---DATA-- -return array('foo' => new Twig_Markup('foo', 'UTF-8')) ---EXPECT-- -"foo" -"foo" -["foo","foo"] diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/last.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/last.test deleted file mode 100644 index 1b8031ee8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/last.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"last" filter ---TEMPLATE-- -{{ [1, 2, 3, 4]|last }} -{{ {a: 1, b: 2, c: 3, d: 4}|last }} -{{ '1234'|last }} -{{ arr|last }} -{{ 'Ä€é'|last }} -{{ ''|last }} ---DATA-- -return array('arr' => new ArrayObject(array(1, 2, 3, 4))) ---EXPECT-- -4 -4 -4 -4 -é diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length.test deleted file mode 100644 index 3347474d5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"length" filter ---TEMPLATE-- -{{ array|length }} -{{ string|length }} -{{ number|length }} -{{ markup|length }} ---DATA-- -return array('array' => array(1, 4), 'string' => 'foo', 'number' => 1000, 'markup' => new Twig_Markup('foo', 'UTF-8')) ---EXPECT-- -2 -3 -4 -3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length_utf8.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length_utf8.test deleted file mode 100644 index 5d5e24361..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/length_utf8.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"length" filter ---CONDITION-- -function_exists('mb_get_info') ---TEMPLATE-- -{{ string|length }} -{{ markup|length }} ---DATA-- -return array('string' => 'été', 'markup' => new Twig_Markup('foo', 'UTF-8')) ---EXPECT-- -3 -3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/merge.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/merge.test deleted file mode 100644 index 81371a41b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/merge.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"merge" filter ---TEMPLATE-- -{{ items|merge({'bar': 'foo'})|join }} -{{ items|merge({'bar': 'foo'})|keys|join }} -{{ {'bar': 'foo'}|merge(items)|join }} -{{ {'bar': 'foo'}|merge(items)|keys|join }} -{{ numerics|merge([4, 5, 6])|join }} -{{ traversable.a|merge(traversable.b)|join }} ---DATA-- -return array('items' => array('foo' => 'bar'), 'numerics' => array(1, 2, 3), 'traversable' => array('a' => new ArrayObject(array(0 => 1, 1 => 2, 2 => 3)), 'b' => new ArrayObject(array('a' => 'b')))) ---EXPECT-- -barfoo -foobar -foobar -barfoo -123456 -123b diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/nl2br.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/nl2br.test deleted file mode 100644 index 6545a9bb0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/nl2br.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"nl2br" filter ---TEMPLATE-- -{{ "I like Twig.\nYou will like it too.\n\nEverybody like it!"|nl2br }} -{{ text|nl2br }} ---DATA-- -return array('text' => "If you have some HTML\nit will be escaped.") ---EXPECT-- -I like Twig.
    -You will like it too.
    -
    -Everybody like it! -If you have some <strong>HTML</strong>
    -it will be escaped. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format.test deleted file mode 100644 index 639a8659f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"number_format" filter ---TEMPLATE-- -{{ 20|number_format }} -{{ 20.25|number_format }} -{{ 20.25|number_format(2) }} -{{ 20.25|number_format(2, ',') }} -{{ 1020.25|number_format(2, ',') }} -{{ 1020.25|number_format(2, ',', '.') }} ---DATA-- -return array(); ---EXPECT-- -20 -20 -20.25 -20,25 -1,020,25 -1.020,25 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format_default.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format_default.test deleted file mode 100644 index c6903cc73..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/number_format_default.test +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -"number_format" filter with defaults. ---TEMPLATE-- -{{ 20|number_format }} -{{ 20.25|number_format }} -{{ 20.25|number_format(1) }} -{{ 20.25|number_format(2, ',') }} -{{ 1020.25|number_format }} -{{ 1020.25|number_format(2, ',') }} -{{ 1020.25|number_format(2, ',', '.') }} ---DATA-- -$twig->getExtension('core')->setNumberFormat(2, '!', '='); -return array(); ---EXPECT-- -20!00 -20!25 -20!3 -20,25 -1=020!25 -1=020,25 -1.020,25 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace.test deleted file mode 100644 index 06be7e270..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"replace" filter ---TEMPLATE-- -{{ "I liké %this% and %that%."|replace({'%this%': "foo", '%that%': "bar"}) }} -{{ 'I like single replace operation only %that%'|replace({'%that%' : '%that%1'}) }} -{{ 'I like %this% and %that%.'|replace(traversable) }} ---DATA-- -return array('traversable' => new ArrayObject(array('%this%' => 'foo', '%that%' => 'bar'))) ---EXPECT-- -I liké foo and bar. -I like single replace operation only %that%1 -I like foo and bar. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace_invalid_arg.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace_invalid_arg.test deleted file mode 100644 index 2143a8690..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/replace_invalid_arg.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Exception for invalid argument type in replace call ---TEMPLATE-- -{{ 'test %foo%'|replace(stdClass) }} ---DATA-- -return array('stdClass' => new stdClass()) ---EXCEPTION-- -Twig_Error_Runtime: The "replace" filter expects an array or "Traversable" as replace values, got "stdClass" in "index.twig" at line 2. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/reverse.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/reverse.test deleted file mode 100644 index 7948ac45f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/reverse.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"reverse" filter ---TEMPLATE-- -{{ [1, 2, 3, 4]|reverse|join('') }} -{{ '1234évènement'|reverse }} -{{ arr|reverse|join('') }} -{{ {'a': 'c', 'b': 'a'}|reverse()|join(',') }} -{{ {'a': 'c', 'b': 'a'}|reverse(preserveKeys=true)|join(glue=',') }} -{{ {'a': 'c', 'b': 'a'}|reverse(preserve_keys=true)|join(glue=',') }} ---DATA-- -return array('arr' => new ArrayObject(array(1, 2, 3, 4))) ---EXPECT-- -4321 -tnemenèvé4321 -4321 -a,c -a,c -a,c diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/round.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/round.test deleted file mode 100644 index 57806b619..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/round.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"round" filter ---TEMPLATE-- -{{ 2.7|round }} -{{ 2.1|round }} -{{ 2.1234|round(3, 'floor') }} -{{ 2.1|round(0, 'ceil') }} - -{{ 21.3|round(-1)}} -{{ 21.3|round(-1, 'ceil')}} -{{ 21.3|round(-1, 'floor')}} ---DATA-- -return array() ---EXPECT-- -3 -2 -2.123 -3 - -20 -30 -20 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/slice.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/slice.test deleted file mode 100644 index b49b89fe5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/slice.test +++ /dev/null @@ -1,54 +0,0 @@ ---TEST-- -"slice" filter ---TEMPLATE-- -{{ [1, 2, 3, 4][1:2]|join('') }} -{{ {a: 1, b: 2, c: 3, d: 4}[1:2]|join('') }} -{{ [1, 2, 3, 4][start:length]|join('') }} -{{ [1, 2, 3, 4]|slice(1, 2)|join('') }} -{{ [1, 2, 3, 4]|slice(1, 2)|keys|join('') }} -{{ [1, 2, 3, 4]|slice(1, 2, true)|keys|join('') }} -{{ {a: 1, b: 2, c: 3, d: 4}|slice(1, 2)|join('') }} -{{ {a: 1, b: 2, c: 3, d: 4}|slice(1, 2)|keys|join('') }} -{{ '1234'|slice(1, 2) }} -{{ '1234'[1:2] }} -{{ arr|slice(1, 2)|join('') }} -{{ arr[1:2]|join('') }} -{{ arr[4:1]|join('') }} -{{ arr[3:2]|join('') }} - -{{ [1, 2, 3, 4]|slice(1)|join('') }} -{{ [1, 2, 3, 4][1:]|join('') }} -{{ '1234'|slice(1) }} -{{ '1234'[1:] }} -{{ '1234'[:1] }} - -{{ arr|slice(3)|join('') }} -{{ arr[2:]|join('') }} -{{ xml|slice(1)|join('')}} ---DATA-- -return array('start' => 1, 'length' => 2, 'arr' => new ArrayObject(array(1, 2, 3, 4)), 'xml' => new SimpleXMLElement('12')) ---EXPECT-- -23 -23 -23 -23 -01 -12 -23 -bc -23 -23 -23 -23 - -4 - -234 -234 -234 -234 -1 - -4 -34 -2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/sort.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/sort.test deleted file mode 100644 index c67c18ea9..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/sort.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"sort" filter ---TEMPLATE-- -{{ array1|sort|join }} -{{ array2|sort|join }} -{{ traversable|sort|join }} ---DATA-- -return array('array1' => array(4, 1), 'array2' => array('foo', 'bar'), 'traversable' => new ArrayObject(array(0 => 3, 1 => 2, 2 => 1))) ---EXPECT-- -14 -barfoo -123 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/special_chars.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/special_chars.test deleted file mode 100644 index dbaf7dc97..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/special_chars.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"§" custom filter ---TEMPLATE-- -{{ 'foo'|§ }} ---DATA-- -return array() ---EXPECT-- -§foo§ diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split.test deleted file mode 100644 index a093ed79b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split.test +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -"split" filter ---TEMPLATE-- -{{ "one,two,three,four,five"|split(',')|join('-') }} -{{ foo|split(',')|join('-') }} -{{ foo|split(',', 3)|join('-') }} -{{ baz|split('')|join('-') }} -{{ baz|split('', 1)|join('-') }} -{{ baz|split('', 2)|join('-') }} -{{ foo|split(',', -2)|join('-') }} ---DATA-- -return array('foo' => "one,two,three,four,five", 'baz' => '12345',) ---EXPECT-- -one-two-three-four-five -one-two-three-four-five -one-two-three,four,five -1-2-3-4-5 -1-2-3-4-5 -12-34-5 -one-two-three \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split_utf8.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split_utf8.test deleted file mode 100644 index 305e162fe..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/split_utf8.test +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -"split" filter ---CONDITION-- -function_exists('mb_get_info') ---TEMPLATE-- -{{ "é"|split('', 10)|join('-') }} -{{ foo|split(',')|join('-') }} -{{ foo|split(',', 1)|join('-') }} -{{ foo|split(',', 2)|join('-') }} -{{ foo|split(',', 3)|join('-') }} -{{ baz|split('')|join('-') }} -{{ baz|split('', 1)|join('-') }} -{{ baz|split('', 2)|join('-') }} ---DATA-- -return array('foo' => 'Ä,é,Äほ', 'baz' => 'éÄßごa',) ---EXPECT-- -é -Ä-é-Äほ -Ä,é,Äほ -Ä-é,Äほ -Ä-é-Äほ -é-Ä-ß-ご-a -é-Ä-ß-ご-a -éÄ-ßご-a \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/trim.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/trim.test deleted file mode 100644 index 319206258..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/trim.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"trim" filter ---TEMPLATE-- -{{ " I like Twig. "|trim }} -{{ text|trim }} -{{ " foo/"|trim("/") }} ---DATA-- -return array('text' => " If you have some HTML it will be escaped. ") ---EXPECT-- -I like Twig. -If you have some <strong>HTML</strong> it will be escaped. - foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode.test deleted file mode 100644 index 8726159db..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"url_encode" filter ---CONDITION-- -defined('PHP_QUERY_RFC3986') ---TEMPLATE-- -{{ {foo: "bar", number: 3, "spéßi%l": "e%c0d@d", "spa ce": ""}|url_encode }} -{{ {foo: "bar", number: 3, "spéßi%l": "e%c0d@d", "spa ce": ""}|url_encode|raw }} -{{ {}|url_encode|default("default") }} -{{ 'spéßi%le%c0d@dspa ce'|url_encode }} ---DATA-- -return array() ---EXPECT-- -foo=bar&number=3&sp%C3%A9%C3%9Fi%25l=e%25c0d%40d&spa%20ce= -foo=bar&number=3&sp%C3%A9%C3%9Fi%25l=e%25c0d%40d&spa%20ce= -default -sp%C3%A9%C3%9Fi%25le%25c0d%40dspa%20ce diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode_deprecated.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode_deprecated.test deleted file mode 100644 index 11800e9c0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/filters/urlencode_deprecated.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"url_encode" filter for PHP < 5.4 and HHVM ---CONDITION-- -defined('PHP_QUERY_RFC3986') ---TEMPLATE-- -{{ {foo: "bar", number: 3, "spéßi%l": "e%c0d@d", "spa ce": ""}|url_encode }} -{{ {foo: "bar", number: 3, "spéßi%l": "e%c0d@d", "spa ce": ""}|url_encode|raw }} -{{ {}|url_encode|default("default") }} -{{ 'spéßi%le%c0d@dspa ce'|url_encode }} ---DATA-- -return array() ---EXPECT-- -foo=bar&number=3&sp%C3%A9%C3%9Fi%25l=e%25c0d%40d&spa%20ce= -foo=bar&number=3&sp%C3%A9%C3%9Fi%25l=e%25c0d%40d&spa%20ce= -default -sp%C3%A9%C3%9Fi%25le%25c0d%40dspa%20ce diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/attribute.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/attribute.test deleted file mode 100644 index 71b2038aa..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/attribute.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"attribute" function ---TEMPLATE-- -{{ attribute(obj, method) }} -{{ attribute(array, item) }} -{{ attribute(obj, "bar", ["a", "b"]) }} -{{ attribute(obj, "bar", arguments) }} -{{ attribute(obj, method) is defined ? 'ok' : 'ko' }} -{{ attribute(obj, nonmethod) is defined ? 'ok' : 'ko' }} ---DATA-- -return array('obj' => new TwigTestFoo(), 'method' => 'foo', 'array' => array('foo' => 'bar'), 'item' => 'foo', 'nonmethod' => 'xxx', 'arguments' => array('a', 'b')) ---EXPECT-- -foo -bar -bar_a-b -bar_a-b -ok -ko diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/block.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/block.test deleted file mode 100644 index 8e54059ae..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/block.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"block" function ---TEMPLATE-- -{% extends 'base.twig' %} -{% block bar %}BAR{% endblock %} ---TEMPLATE(base.twig)-- -{% block foo %}{{ block('bar') }}{% endblock %} -{% block bar %}BAR_BASE{% endblock %} ---DATA-- -return array() ---EXPECT-- -BARBAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/constant.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/constant.test deleted file mode 100644 index 63128791f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/constant.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"constant" function ---TEMPLATE-- -{{ constant('DATE_W3C') == expect ? 'true' : 'false' }} -{{ constant('ARRAY_AS_PROPS', object) }} ---DATA-- -return array('expect' => DATE_W3C, 'object' => new ArrayObject(array('hi'))); ---EXPECT-- -true -2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/cycle.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/cycle.test deleted file mode 100644 index 522a63b85..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/cycle.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"cycle" function ---TEMPLATE-- -{% for i in 0..6 %} -{{ cycle(array1, i) }}-{{ cycle(array2, i) }} -{% endfor %} ---DATA-- -return array('array1' => array('odd', 'even'), 'array2' => array('apple', 'orange', 'citrus')) ---EXPECT-- -odd-apple -even-orange -odd-citrus -even-apple -odd-orange -even-citrus -odd-apple diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date.test deleted file mode 100644 index 8be9c0c40..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date.test +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -"date" function ---TEMPLATE-- -{{ date() == date('now') ? 'OK' : 'KO' }} -{{ date(date1) == date('2010-10-04 13:45') ? 'OK' : 'KO' }} -{{ date(date2) == date('2010-10-04 13:45') ? 'OK' : 'KO' }} -{{ date(date3) == date('2010-10-04 13:45') ? 'OK' : 'KO' }} -{{ date(date4) == date('2010-10-04 13:45') ? 'OK' : 'KO' }} -{{ date(date5) == date('1964-01-02 03:04') ? 'OK' : 'KO' }} ---DATA-- -date_default_timezone_set('UTC'); -return array( - 'date1' => mktime(13, 45, 0, 10, 4, 2010), - 'date2' => new DateTime('2010-10-04 13:45'), - 'date3' => '2010-10-04 13:45', - 'date4' => 1286199900, // DateTime::createFromFormat('Y-m-d H:i', '2010-10-04 13:45', new DateTimeZone('UTC'))->getTimestamp() -- A unixtimestamp is always GMT - 'date5' => -189291360, // DateTime::createFromFormat('Y-m-d H:i', '1964-01-02 03:04', new DateTimeZone('UTC'))->getTimestamp(), -) ---EXPECT-- -OK -OK -OK -OK -OK -OK diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date_namedargs.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date_namedargs.test deleted file mode 100644 index b9dd9e383..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/date_namedargs.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"date" function ---TEMPLATE-- -{{ date(date, "America/New_York")|date('d/m/Y H:i:s P', false) }} -{{ date(timezone="America/New_York", date=date)|date('d/m/Y H:i:s P', false) }} ---DATA-- -date_default_timezone_set('UTC'); -return array('date' => mktime(13, 45, 0, 10, 4, 2010)) ---EXPECT-- -04/10/2010 09:45:00 -04:00 -04/10/2010 09:45:00 -04:00 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump.test deleted file mode 100644 index f4072375a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"dump" function ---CONDITION-- -!extension_loaded('xdebug') ---TEMPLATE-- -{{ dump('foo') }} -{{ dump('foo', 'bar') }} ---DATA-- -return array('foo' => 'foo', 'bar' => 'bar') ---CONFIG-- -return array('debug' => true, 'autoescape' => false); ---EXPECT-- -string(3) "foo" - -string(3) "foo" -string(3) "bar" diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump_array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump_array.test deleted file mode 100644 index 889b7a922..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dump_array.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -"dump" function, xdebug is not loaded or xdebug <2.2-dev is loaded ---CONDITION-- -!extension_loaded('xdebug') || (($r = new ReflectionExtension('xdebug')) && version_compare($r->getVersion(), '2.2-dev', '<')) ---TEMPLATE-- -{{ dump() }} ---DATA-- -return array('foo' => 'foo', 'bar' => 'bar') ---CONFIG-- -return array('debug' => true, 'autoescape' => false); ---EXPECT-- -array(3) { - ["foo"]=> - string(3) "foo" - ["bar"]=> - string(3) "bar" - ["global"]=> - string(6) "global" -} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dynamic_function.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dynamic_function.test deleted file mode 100644 index 913fbc995..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/dynamic_function.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -dynamic function ---TEMPLATE-- -{{ foo_path('bar') }} -{{ a_foo_b_bar('bar') }} ---DATA-- -return array() ---EXPECT-- -foo/bar -a/b/bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/assignment.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/assignment.test deleted file mode 100644 index b7653b4ef..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/assignment.test +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -{% set tmp = include("foo.twig") %} - -FOO{{ tmp }}BAR ---TEMPLATE(foo.twig)-- -FOOBAR ---DATA-- -return array() ---EXPECT-- -FOO -FOOBARBAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/autoescaping.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/autoescaping.test deleted file mode 100644 index 56f8f3b5a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/autoescaping.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"include" function is safe for auto-escaping ---TEMPLATE-- -{{ include("foo.twig") }} ---TEMPLATE(foo.twig)-- -

    Test

    ---DATA-- -return array() ---EXPECT-- -

    Test

    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/basic.test deleted file mode 100644 index a434182a2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/basic.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -FOO -{{ include("foo.twig") }} - -BAR ---TEMPLATE(foo.twig)-- -FOOBAR ---DATA-- -return array() ---EXPECT-- -FOO - -FOOBAR - -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/expression.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/expression.test deleted file mode 100644 index aba30ce3f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/expression.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"include" function allows expressions for the template to include ---TEMPLATE-- -FOO -{{ include(foo) }} - -BAR ---TEMPLATE(foo.twig)-- -FOOBAR ---DATA-- -return array('foo' => 'foo.twig') ---EXPECT-- -FOO - -FOOBAR - -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/ignore_missing.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/ignore_missing.test deleted file mode 100644 index 43a2ccc2c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/ignore_missing.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -{{ include(["foo.twig", "bar.twig"], ignore_missing = true) }} -{{ include("foo.twig", ignore_missing = true) }} -{{ include("foo.twig", ignore_missing = true, variables = {}) }} -{{ include("foo.twig", ignore_missing = true, variables = {}, with_context = true) }} ---DATA-- -return array() ---EXPECT-- diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing.test deleted file mode 100644 index 4d2f6cf13..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -{{ include("foo.twig") }} ---DATA-- -return array(); ---EXCEPTION-- -Twig_Error_Loader: Template "foo.twig" is not defined in "index.twig" at line 2. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing_nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing_nested.test deleted file mode 100644 index 78fddc7a6..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/missing_nested.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -{% extends "base.twig" %} - -{% block content %} - {{ parent() }} -{% endblock %} ---TEMPLATE(base.twig)-- -{% block content %} - {{ include("foo.twig") }} -{% endblock %} ---DATA-- -return array(); ---EXCEPTION-- -Twig_Error_Loader: Template "foo.twig" is not defined in "base.twig" at line 3. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox.test deleted file mode 100644 index 7b9ccaca8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox.test +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -"include" tag sandboxed ---TEMPLATE-- -{{ include("foo.twig", sandboxed = true) }} ---TEMPLATE(foo.twig)-- - - -{{ foo|e }} -{{ foo|e }} ---DATA-- -return array() ---EXCEPTION-- -Twig_Sandbox_SecurityNotAllowedFilterError: Filter "e" is not allowed in "foo.twig" at line 4. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling.test deleted file mode 100644 index 8ffc49225..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" tag sandboxed ---TEMPLATE-- -{{ include("foo.twig", sandboxed = true) }} -{{ include("bar.twig") }} ---TEMPLATE(foo.twig)-- -foo ---TEMPLATE(bar.twig)-- -{{ foo|e }} ---DATA-- -return array('foo' => 'bar
    ') ---EXPECT-- -foo - - -bar<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling_ignore_missing.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling_ignore_missing.test deleted file mode 100644 index 8bf6e102d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/sandbox_disabling_ignore_missing.test +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -"include" tag sandboxed ---TEMPLATE-- -{{ include("unknown.twig", sandboxed = true, ignore_missing = true) }} -{{ include("bar.twig") }} ---TEMPLATE(bar.twig)-- -{{ foo|e }} ---DATA-- -return array('foo' => 'bar
    ') ---EXPECT-- - - -bar<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/template_instance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/template_instance.test deleted file mode 100644 index 18d405a02..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/template_instance.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"include" function accepts Twig_Template instance ---TEMPLATE-- -{{ include(foo) }} FOO ---TEMPLATE(foo.twig)-- -BAR ---DATA-- -return array('foo' => $twig->loadTemplate('foo.twig')) ---EXPECT-- -BAR FOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/templates_as_array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/templates_as_array.test deleted file mode 100644 index 1a8100687..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/templates_as_array.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"include" function ---TEMPLATE-- -{{ include(["foo.twig", "bar.twig"]) }} -{{- include(["bar.twig", "foo.twig"]) }} ---TEMPLATE(foo.twig)-- -foo ---DATA-- -return array() ---EXPECT-- -foo -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_context.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_context.test deleted file mode 100644 index 35611fbb9..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_context.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" function accept variables and with_context ---TEMPLATE-- -{{ include("foo.twig") }} -{{- include("foo.twig", with_context = false) }} -{{- include("foo.twig", {'foo1': 'bar'}) }} -{{- include("foo.twig", {'foo1': 'bar'}, with_context = false) }} ---TEMPLATE(foo.twig)-- -{% for k, v in _context %}{{ k }},{% endfor %} ---DATA-- -return array('foo' => 'bar') ---EXPECT-- -foo,global,_parent, -global,_parent, -foo,global,foo1,_parent, -foo1,global,_parent, diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_variables.test deleted file mode 100644 index b2ace940e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/include/with_variables.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"include" function accept variables ---TEMPLATE-- -{{ include("foo.twig", {'foo': 'bar'}) }} -{{- include("foo.twig", vars) }} ---TEMPLATE(foo.twig)-- -{{ foo }} ---DATA-- -return array('vars' => array('foo' => 'bar')) ---EXPECT-- -bar -bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/max.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/max.test deleted file mode 100644 index e6c94af63..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/max.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"max" function ---TEMPLATE-- -{{ max([2, 1, 3, 5, 4]) }} -{{ max(2, 1, 3, 5, 4) }} -{{ max({2:"two", 1:"one", 3:"three", 5:"five", 4:"for"}) }} ---DATA-- -return array() ---EXPECT-- -5 -5 -two diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/min.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/min.test deleted file mode 100644 index 660471c00..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/min.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"min" function ---TEMPLATE-- -{{ min(2, 1, 3, 5, 4) }} -{{ min([2, 1, 3, 5, 4]) }} -{{ min({2:"two", 1:"one", 3:"three", 5:"five", 4:"for"}) }} ---DATA-- -return array() ---EXPECT-- -1 -1 -five diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/range.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/range.test deleted file mode 100644 index e0377c8d4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/range.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"range" function ---TEMPLATE-- -{{ range(low=0+1, high=10+0, step=2)|join(',') }} ---DATA-- -return array() ---EXPECT-- -1,3,5,7,9 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/recursive_block_with_inheritance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/recursive_block_with_inheritance.test deleted file mode 100644 index f39712da8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/recursive_block_with_inheritance.test +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -"block" function recursively called in a parent template ---TEMPLATE-- -{% extends "ordered_menu.twig" %} -{% block label %}"{{ parent() }}"{% endblock %} -{% block list %}{% set class = 'b' %}{{ parent() }}{% endblock %} ---TEMPLATE(ordered_menu.twig)-- -{% extends "menu.twig" %} -{% block list %}{% set class = class|default('a') %}
      {{ block('children') }}
    {% endblock %} ---TEMPLATE(menu.twig)-- -{% extends "base.twig" %} -{% block list %}
      {{ block('children') }}
    {% endblock %} -{% block children %}{% set currentItem = item %}{% for item in currentItem %}{{ block('item') }}{% endfor %}{% set item = currentItem %}{% endblock %} -{% block item %}
  • {% if item is not iterable %}{{ block('label') }}{% else %}{{ block('list') }}{% endif %}
  • {% endblock %} -{% block label %}{{ item }}{{ block('unknown') }}{% endblock %} ---TEMPLATE(base.twig)-- -{{ block('list') }} ---DATA-- -return array('item' => array('1', '2', array('3.1', array('3.2.1', '3.2.2'), '3.4'))) ---EXPECT-- -
    1. "1"
    2. "2"
      1. "3.1"
        1. "3.2.1"
        2. "3.2.2"
      2. "3.4"
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/source.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/source.test deleted file mode 100644 index 0e094c3b2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/source.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"source" function ---TEMPLATE-- -FOO -{{ source("foo.twig") }} - -BAR ---TEMPLATE(foo.twig)-- -{{ foo }}
    ---DATA-- -return array() ---EXPECT-- -FOO - -{{ foo }}
    - -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/special_chars.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/special_chars.test deleted file mode 100644 index 30c3df516..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/special_chars.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"§" custom function ---TEMPLATE-- -{{ §('foo') }} ---DATA-- -return array() ---EXPECT-- -§foo§ diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/template_from_string.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/template_from_string.test deleted file mode 100644 index 3d3b95874..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/functions/template_from_string.test +++ /dev/null @@ -1,15 +0,0 @@ ---TEST-- -"template_from_string" function ---TEMPLATE-- -{% include template_from_string(template) %} - -{% include template_from_string("Hello {{ name }}") %} -{% include template_from_string('{% extends "parent.twig" %}{% block content %}Hello {{ name }}{% endblock %}') %} ---TEMPLATE(parent.twig)-- -{% block content %}{% endblock %} ---DATA-- -return array('name' => 'Fabien', 'template' => "Hello {{ name }}") ---EXPECT-- -Hello Fabien -Hello Fabien -Hello Fabien diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/default_values.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/default_values.test deleted file mode 100644 index 4ccff7b67..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/default_values.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -macro ---TEMPLATE-- -{% from _self import test %} - -{% macro test(a, b = 'bar') -%} -{{ a }}{{ b }} -{%- endmacro %} - -{{ test('foo') }} -{{ test('bar', 'foo') }} ---DATA-- -return array(); ---EXPECT-- -foobar -barfoo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/nested_calls.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/nested_calls.test deleted file mode 100644 index cd2542810..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/nested_calls.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -macro ---TEMPLATE-- -{% import _self as macros %} - -{% macro foo(data) %} - {{ data }} -{% endmacro %} - -{% macro bar() %} -
    -{% endmacro %} - -{{ macros.foo(macros.bar()) }} ---DATA-- -return array(); ---EXPECT-- -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/reserved_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/reserved_variables.test deleted file mode 100644 index cbfb921b2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/reserved_variables.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -macro ---TEMPLATE-- -{% from _self import test %} - -{% macro test(this) -%} - {{ this }} -{%- endmacro %} - -{{ test(this) }} ---DATA-- -return array('this' => 'foo'); ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/simple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/simple.test deleted file mode 100644 index 6a366cdf1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/simple.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -macro ---TEMPLATE-- -{% import _self as test %} -{% from _self import test %} - -{% macro test(a, b) -%} - {{ a|default('a') }}
    - {{- b|default('b') }}
    -{%- endmacro %} - -{{ test.test() }} -{{ test() }} -{{ test.test(1, "c") }} -{{ test(1, "c") }} ---DATA-- -return array(); ---EXPECT-- -a
    b
    -a
    b
    -1
    c
    -1
    c
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs.test deleted file mode 100644 index 412c90fae..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs.test +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -macro with arbitrary arguments ---TEMPLATE-- -{% from _self import test1, test2 %} - -{% macro test1(var) %} - {{- var }}: {{ varargs|join(", ") }} -{% endmacro %} - -{% macro test2() %} - {{- varargs|join(", ") }} -{% endmacro %} - -{{ test1("foo", "bar", "foobar") }} -{{ test2("foo", "bar", "foobar") }} ---DATA-- -return array(); ---EXPECT-- -foo: bar, foobar - -foo, bar, foobar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs_argument.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs_argument.test deleted file mode 100644 index b08c8ec91..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/varargs_argument.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -macro with varargs argument ---TEMPLATE-- -{% macro test(varargs) %} -{% endmacro %} ---EXCEPTION-- -Twig_Error_Syntax: The argument "varargs" in macro "test" cannot be defined because the variable "varargs" is reserved for arbitrary arguments in "index.twig" at line 2 - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/with_filters.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/with_filters.test deleted file mode 100644 index 685626f2a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/macros/with_filters.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -macro with a filter ---TEMPLATE-- -{% import _self as test %} - -{% macro test() %} - {% filter escape %}foo
    {% endfilter %} -{% endmacro %} - -{{ test.test() }} ---DATA-- -return array(); ---EXPECT-- -foo<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/combined_debug_info.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/combined_debug_info.test deleted file mode 100644 index df485783a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/combined_debug_info.test +++ /dev/null @@ -1,15 +0,0 @@ ---TEST-- -Exception with bad line number ---TEMPLATE-- -{% block content %} - {{ foo }} - {{ include("foo") }} -{% endblock %} -index ---TEMPLATE(foo)-- -foo -{{ foo.bar }} ---DATA-- -return array('foo' => 'foo'); ---EXCEPTION-- -Twig_Error_Runtime: Impossible to access an attribute ("bar") on a string variable ("foo") in "foo" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/empty_token.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/empty_token.test deleted file mode 100644 index 65f6cd2b8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/empty_token.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Twig outputs 0 nodes correctly ---TEMPLATE-- -{{ foo }}0{{ foo }} ---DATA-- -return array('foo' => 'foo') ---EXPECT-- -foo0foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/issue_1143.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/issue_1143.test deleted file mode 100644 index ff7c8bb70..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/issue_1143.test +++ /dev/null @@ -1,23 +0,0 @@ ---TEST-- -error in twig extension ---TEMPLATE-- -{{ object.region is not null ? object.regionChoices[object.region] }} ---DATA-- -class House -{ - const REGION_S = 1; - const REGION_P = 2; - - public static $regionChoices = array(self::REGION_S => 'house.region.s', self::REGION_P => 'house.region.p'); - - public function getRegionChoices() - { - return self::$regionChoices; - } -} - -$object = new House(); -$object->region = 1; -return array('object' => $object) ---EXPECT-- -house.region.s diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/multi_word_tests.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/multi_word_tests.test deleted file mode 100644 index 269a30571..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/multi_word_tests.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Twig allows multi-word tests without a custom node class ---TEMPLATE-- -{{ 'foo' is multi word ? 'yes' : 'no' }} -{{ 'foo bar' is multi word ? 'yes' : 'no' }} ---DATA-- -return array() ---EXPECT-- -no -yes diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/simple_xml_element.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/simple_xml_element.test deleted file mode 100644 index 60c3c51d7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/simple_xml_element.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -Twig is able to deal with SimpleXMLElement instances as variables ---CONDITION-- -version_compare(phpversion(), '5.3.0', '>=') ---TEMPLATE-- -Hello '{{ images.image.0.group }}'! -{{ images.image.0.group.attributes.myattr }} -{{ images.children().image.count() }} -{% for image in images %} - - {{ image.group }} -{% endfor %} ---DATA-- -return array('images' => new SimpleXMLElement('foobar')) ---EXPECT-- -Hello 'foo'! -example -2 - - foo - - bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/strings_like_numbers.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/strings_like_numbers.test deleted file mode 100644 index e18e11079..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/regression/strings_like_numbers.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Twig does not confuse strings with integers in getAttribute() ---TEMPLATE-- -{{ hash['2e2'] }} ---DATA-- -return array('hash' => array('2e2' => 'works')) ---EXPECT-- -works diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/basic.test deleted file mode 100644 index 2f6a3e1a0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/basic.test +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping on its children ---TEMPLATE-- -{% autoescape %} -{{ var }}
    -{% endautoescape %} -{% autoescape 'html' %} -{{ var }}
    -{% endautoescape %} -{% autoescape false %} -{{ var }}
    -{% endautoescape %} -{% autoescape true %} -{{ var }}
    -{% endautoescape %} -{% autoescape false %} -{{ var }}
    -{% endautoescape %} ---DATA-- -return array('var' => '
    ') ---EXPECT-- -<br />
    -<br />
    -

    -<br />
    -

    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/blocks.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/blocks.test deleted file mode 100644 index 05ab83ce3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/blocks.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping on embedded blocks ---TEMPLATE-- -{% autoescape 'html' %} - {% block foo %} - {{ var }} - {% endblock %} -{% endautoescape %} ---DATA-- -return array('var' => '
    ') ---EXPECT-- -<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/double_escaping.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/double_escaping.test deleted file mode 100644 index 9c0972462..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/double_escaping.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"autoescape" tag does not double-escape ---TEMPLATE-- -{% autoescape 'html' %} -{{ var|escape }} -{% endautoescape %} ---DATA-- -return array('var' => '
    ') ---EXPECT-- -<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/functions.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/functions.test deleted file mode 100644 index ce7ea789e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/functions.test +++ /dev/null @@ -1,83 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping after calling functions ---TEMPLATE-- - -autoescape false -{% autoescape false %} - -safe_br -{{ safe_br() }} - -unsafe_br -{{ unsafe_br() }} - -{% endautoescape %} - -autoescape 'html' -{% autoescape 'html' %} - -safe_br -{{ safe_br() }} - -unsafe_br -{{ unsafe_br() }} - -unsafe_br()|raw -{{ (unsafe_br())|raw }} - -safe_br()|escape -{{ (safe_br())|escape }} - -safe_br()|raw -{{ (safe_br())|raw }} - -unsafe_br()|escape -{{ (unsafe_br())|escape }} - -{% endautoescape %} - -autoescape js -{% autoescape 'js' %} - -safe_br -{{ safe_br() }} - -{% endautoescape %} ---DATA-- -return array() ---EXPECT-- - -autoescape false - -safe_br -
    - -unsafe_br -
    - - -autoescape 'html' - -safe_br -
    - -unsafe_br -<br /> - -unsafe_br()|raw -
    - -safe_br()|escape -<br /> - -safe_br()|raw -
    - -unsafe_br()|escape -<br /> - - -autoescape js - -safe_br -\x3Cbr\x20\x2F\x3E diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/literal.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/literal.test deleted file mode 100644 index e389d4dd5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/literal.test +++ /dev/null @@ -1,45 +0,0 @@ ---TEST-- -"autoescape" tag does not apply escaping on literals ---TEMPLATE-- -{% autoescape 'html' %} - -1. Simple literal -{{ "
    " }} - -2. Conditional expression with only literals -{{ true ? "
    " : "
    " }} - -3. Conditional expression with a variable -{{ true ? "
    " : someVar }} - -4. Nested conditionals with only literals -{{ true ? (true ? "
    " : "
    ") : "\n" }} - -5. Nested conditionals with a variable -{{ true ? (true ? "
    " : someVar) : "\n" }} - -6. Nested conditionals with a variable marked safe -{{ true ? (true ? "
    " : someVar|raw) : "\n" }} - -{% endautoescape %} ---DATA-- -return array() ---EXPECT-- - -1. Simple literal -
    - -2. Conditional expression with only literals -
    - -3. Conditional expression with a variable -<br /> - -4. Nested conditionals with only literals -
    - -5. Nested conditionals with a variable -<br /> - -6. Nested conditionals with a variable marked safe -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/nested.test deleted file mode 100644 index 798e6feaf..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/nested.test +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -"autoescape" tags can be nested at will ---TEMPLATE-- -{{ var }} -{% autoescape 'html' %} - {{ var }} - {% autoescape false %} - {{ var }} - {% autoescape 'html' %} - {{ var }} - {% endautoescape %} - {{ var }} - {% endautoescape %} - {{ var }} -{% endautoescape %} -{{ var }} ---DATA-- -return array('var' => '
    ') ---EXPECT-- -<br /> - <br /> -
    - <br /> -
    - <br /> -<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/objects.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/objects.test deleted file mode 100644 index e896aa41c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/objects.test +++ /dev/null @@ -1,26 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping to object method calls ---TEMPLATE-- -{% autoescape 'html' %} -{{ user.name }} -{{ user.name|lower }} -{{ user }} -{% endautoescape %} ---DATA-- -class UserForAutoEscapeTest -{ - public function getName() - { - return 'Fabien
    '; - } - - public function __toString() - { - return 'Fabien
    '; - } -} -return array('user' => new UserForAutoEscapeTest()) ---EXPECT-- -Fabien<br /> -fabien<br /> -Fabien<br /> diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/raw.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/raw.test deleted file mode 100644 index 9f1cedd3a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/raw.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"autoescape" tag does not escape when raw is used as a filter ---TEMPLATE-- -{% autoescape 'html' %} -{{ var|raw }} -{% endautoescape %} ---DATA-- -return array('var' => '
    ') ---EXPECT-- -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.legacy.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.legacy.test deleted file mode 100644 index bbf1356e7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.legacy.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"autoescape" tag accepts an escaping strategy ---TEMPLATE-- -{% autoescape true js %}{{ var }}{% endautoescape %} - -{% autoescape true html %}{{ var }}{% endautoescape %} ---DATA-- -return array('var' => '
    "') ---EXPECT-- -\x3Cbr\x20\x2F\x3E\x22 -<br />" diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.test deleted file mode 100644 index e496f6081..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/strategy.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"autoescape" tag accepts an escaping strategy ---TEMPLATE-- -{% autoescape 'js' %}{{ var }}{% endautoescape %} - -{% autoescape 'html' %}{{ var }}{% endautoescape %} ---DATA-- -return array('var' => '
    "') ---EXPECT-- -\x3Cbr\x20\x2F\x3E\x22 -<br />" diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/type.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/type.test deleted file mode 100644 index 4f415201d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/type.test +++ /dev/null @@ -1,69 +0,0 @@ ---TEST-- -escape types ---TEMPLATE-- - -1. autoescape 'html' |escape('js') - -{% autoescape 'html' %} - -{% endautoescape %} - -2. autoescape 'html' |escape('js') - -{% autoescape 'html' %} - -{% endautoescape %} - -3. autoescape 'js' |escape('js') - -{% autoescape 'js' %} - -{% endautoescape %} - -4. no escape - -{% autoescape false %} - -{% endautoescape %} - -5. |escape('js')|escape('html') - -{% autoescape false %} - -{% endautoescape %} - -6. autoescape 'html' |escape('js')|escape('html') - -{% autoescape 'html' %} - -{% endautoescape %} - ---DATA-- -return array('msg' => "<>\n'\"") ---EXPECT-- - -1. autoescape 'html' |escape('js') - - - -2. autoescape 'html' |escape('js') - - - -3. autoescape 'js' |escape('js') - - - -4. no escape - - - -5. |escape('js')|escape('html') - - - -6. autoescape 'html' |escape('js')|escape('html') - - - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters.test deleted file mode 100644 index 7821a9aaf..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters.test +++ /dev/null @@ -1,131 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping after calling filters ---TEMPLATE-- -{% autoescape 'html' %} - -(escape_and_nl2br is an escaper filter) - -1. Don't escape escaper filter output -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped ) -{{ var|escape_and_nl2br }} - -2. Don't escape escaper filter output -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped, |raw is redundant ) -{{ var|escape_and_nl2br|raw }} - -3. Explicit escape -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is explicitly escaped by |escape ) -{{ var|escape_and_nl2br|escape }} - -4. Escape non-escaper filter output -( var is upper-cased by |upper, - the output is auto-escaped ) -{{ var|upper }} - -5. Escape if last filter is not an escaper -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is upper-cased by |upper, - the output is auto-escaped as |upper is not an escaper ) -{{ var|escape_and_nl2br|upper }} - -6. Don't escape escaper filter output -( var is upper cased by upper, - the output is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped as |escape_and_nl2br is an escaper ) -{{ var|upper|escape_and_nl2br }} - -7. Escape if last filter is not an escaper -( the output of |format is "" ~ var ~ "", - the output is auto-escaped ) -{{ "%s"|format(var) }} - -8. Escape if last filter is not an escaper -( the output of |format is "" ~ var ~ "", - |raw is redundant, - the output is auto-escaped ) -{{ "%s"|raw|format(var) }} - -9. Don't escape escaper filter output -( the output of |format is "" ~ var ~ "", - the output is not escaped due to |raw filter at the end ) -{{ "%s"|format(var)|raw }} - -10. Don't escape escaper filter output -( the output of |format is "" ~ var ~ "", - the output is not escaped due to |raw filter at the end, - the |raw filter on var is redundant ) -{{ "%s"|format(var|raw)|raw }} - -{% endautoescape %} ---DATA-- -return array('var' => "\nTwig") ---EXPECT-- - -(escape_and_nl2br is an escaper filter) - -1. Don't escape escaper filter output -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped ) -<Fabien>
    -Twig - -2. Don't escape escaper filter output -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped, |raw is redundant ) -<Fabien>
    -Twig - -3. Explicit escape -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is explicitly escaped by |escape ) -&lt;Fabien&gt;<br /> -Twig - -4. Escape non-escaper filter output -( var is upper-cased by |upper, - the output is auto-escaped ) -<FABIEN> -TWIG - -5. Escape if last filter is not an escaper -( var is escaped by |escape_and_nl2br, line-breaks are added, - the output is upper-cased by |upper, - the output is auto-escaped as |upper is not an escaper ) -&LT;FABIEN&GT;<BR /> -TWIG - -6. Don't escape escaper filter output -( var is upper cased by upper, - the output is escaped by |escape_and_nl2br, line-breaks are added, - the output is not escaped as |escape_and_nl2br is an escaper ) -<FABIEN>
    -TWIG - -7. Escape if last filter is not an escaper -( the output of |format is "" ~ var ~ "", - the output is auto-escaped ) -<b><Fabien> -Twig</b> - -8. Escape if last filter is not an escaper -( the output of |format is "" ~ var ~ "", - |raw is redundant, - the output is auto-escaped ) -<b><Fabien> -Twig</b> - -9. Don't escape escaper filter output -( the output of |format is "" ~ var ~ "", - the output is not escaped due to |raw filter at the end ) - -Twig - -10. Don't escape escaper filter output -( the output of |format is "" ~ var ~ "", - the output is not escaped due to |raw filter at the end, - the |raw filter on var is redundant ) - -Twig diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters_arguments.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters_arguments.test deleted file mode 100644 index f58a1e09c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_filters_arguments.test +++ /dev/null @@ -1,23 +0,0 @@ ---TEST-- -"autoescape" tag do not applies escaping on filter arguments ---TEMPLATE-- -{% autoescape 'html' %} -{{ var|nl2br("
    ") }} -{{ var|nl2br("
    "|escape) }} -{{ var|nl2br(sep) }} -{{ var|nl2br(sep|raw) }} -{{ var|nl2br(sep|escape) }} -{% endautoescape %} ---DATA-- -return array('var' => "\nTwig", 'sep' => '
    ') ---EXPECT-- -<Fabien>
    -Twig -<Fabien><br /> -Twig -<Fabien>
    -Twig -<Fabien>
    -Twig -<Fabien><br /> -Twig diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_pre_escape_filters.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_pre_escape_filters.test deleted file mode 100644 index 134c77ea8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_pre_escape_filters.test +++ /dev/null @@ -1,68 +0,0 @@ ---TEST-- -"autoescape" tag applies escaping after calling filters, and before calling pre_escape filters ---TEMPLATE-- -{% autoescape 'html' %} - -(nl2br is pre_escaped for "html" and declared safe for "html") - -1. Pre-escape and don't post-escape -( var|escape|nl2br ) -{{ var|nl2br }} - -2. Don't double-pre-escape -( var|escape|nl2br ) -{{ var|escape|nl2br }} - -3. Don't escape safe values -( var|raw|nl2br ) -{{ var|raw|nl2br }} - -4. Don't escape safe values -( var|escape|nl2br|nl2br ) -{{ var|nl2br|nl2br }} - -5. Re-escape values that are escaped for an other contexts -( var|escape_something|escape|nl2br ) -{{ var|escape_something|nl2br }} - -6. Still escape when using filters not declared safe -( var|escape|nl2br|upper|escape ) -{{ var|nl2br|upper }} - -{% endautoescape %} ---DATA-- -return array('var' => "\nTwig") ---EXPECT-- - -(nl2br is pre_escaped for "html" and declared safe for "html") - -1. Pre-escape and don't post-escape -( var|escape|nl2br ) -<Fabien>
    -Twig - -2. Don't double-pre-escape -( var|escape|nl2br ) -<Fabien>
    -Twig - -3. Don't escape safe values -( var|raw|nl2br ) -
    -Twig - -4. Don't escape safe values -( var|escape|nl2br|nl2br ) -<Fabien>

    -Twig - -5. Re-escape values that are escaped for an other contexts -( var|escape_something|escape|nl2br ) -<FABIEN>
    -TWIG - -6. Still escape when using filters not declared safe -( var|escape|nl2br|upper|escape ) -&LT;FABIEN&GT;<BR /> -TWIG - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_preserves_safety_filters.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_preserves_safety_filters.test deleted file mode 100644 index 32d3943b5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/autoescape/with_preserves_safety_filters.test +++ /dev/null @@ -1,50 +0,0 @@ ---TEST-- -"autoescape" tag handles filters preserving the safety ---TEMPLATE-- -{% autoescape 'html' %} - -(preserves_safety is preserving safety for "html") - -1. Unsafe values are still unsafe -( var|preserves_safety|escape ) -{{ var|preserves_safety }} - -2. Safe values are still safe -( var|escape|preserves_safety ) -{{ var|escape|preserves_safety }} - -3. Re-escape values that are escaped for an other contexts -( var|escape_something|preserves_safety|escape ) -{{ var|escape_something|preserves_safety }} - -4. Still escape when using filters not declared safe -( var|escape|preserves_safety|replace({'FABIEN': 'FABPOT'})|escape ) -{{ var|escape|preserves_safety|replace({'FABIEN': 'FABPOT'}) }} - -{% endautoescape %} ---DATA-- -return array('var' => "\nTwig") ---EXPECT-- - -(preserves_safety is preserving safety for "html") - -1. Unsafe values are still unsafe -( var|preserves_safety|escape ) -<FABIEN> -TWIG - -2. Safe values are still safe -( var|escape|preserves_safety ) -<FABIEN> -TWIG - -3. Re-escape values that are escaped for an other contexts -( var|escape_something|preserves_safety|escape ) -<FABIEN> -TWIG - -4. Still escape when using filters not declared safe -( var|escape|preserves_safety|replace({'FABIEN': 'FABPOT'})|escape ) -&LT;FABPOT&GT; -TWIG - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/basic.test deleted file mode 100644 index 360dcf030..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/basic.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"block" tag ---TEMPLATE-- -{% block title1 %}FOO{% endblock %} -{% block title2 foo|lower %} ---TEMPLATE(foo.twig)-- -{% block content %}{% endblock %} ---DATA-- -return array('foo' => 'bar') ---EXPECT-- -FOObar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/block_unique_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/block_unique_name.test deleted file mode 100644 index 5c205c0aa..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/block_unique_name.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"block" tag ---TEMPLATE-- -{% block content %} - {% block content %} - {% endblock %} -{% endblock %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: The block 'content' has already been defined line 2 in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/special_chars.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/special_chars.test deleted file mode 100644 index be17fedf3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/block/special_chars.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"§" special chars in a block name ---TEMPLATE-- -{% block § %} -§ -{% endblock § %} ---DATA-- -return array() ---EXPECT-- -§ diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/basic.test deleted file mode 100644 index f44296ea0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/basic.test +++ /dev/null @@ -1,35 +0,0 @@ ---TEST-- -"embed" tag ---TEMPLATE-- -FOO -{% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - block1extended - {% endblock %} -{% endembed %} - -BAR ---TEMPLATE(foo.twig)-- -A -{% block c1 %} - block1 -{% endblock %} -B -{% block c2 %} - block2 -{% endblock %} -C ---DATA-- -return array() ---EXPECT-- -FOO - -A - block1 - - block1extended - B - block2 -C -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/error_line.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/error_line.test deleted file mode 100644 index 71ab2e018..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/error_line.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"embed" tag ---TEMPLATE(index.twig)-- -FOO -{% embed "foo.twig" %} - {% block c1 %} - {{ nothing }} - {% endblock %} -{% endembed %} -BAR ---TEMPLATE(foo.twig)-- -{% block c1 %}{% endblock %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Runtime: Variable "nothing" does not exist in "index.twig" at line 5 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/multiple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/multiple.test deleted file mode 100644 index da161e6d4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/multiple.test +++ /dev/null @@ -1,50 +0,0 @@ ---TEST-- -"embed" tag ---TEMPLATE-- -FOO -{% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - block1extended - {% endblock %} -{% endembed %} - -{% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - block1extended - {% endblock %} -{% endembed %} - -BAR ---TEMPLATE(foo.twig)-- -A -{% block c1 %} - block1 -{% endblock %} -B -{% block c2 %} - block2 -{% endblock %} -C ---DATA-- -return array() ---EXPECT-- -FOO - -A - block1 - - block1extended - B - block2 -C - -A - block1 - - block1extended - B - block2 -C -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/nested.test deleted file mode 100644 index 81563dcef..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/nested.test +++ /dev/null @@ -1,42 +0,0 @@ ---TEST-- -"embed" tag ---TEMPLATE-- -{% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - {% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - block1extended - {% endblock %} - {% endembed %} - - {% endblock %} -{% endembed %} ---TEMPLATE(foo.twig)-- -A -{% block c1 %} - block1 -{% endblock %} -B -{% block c2 %} - block2 -{% endblock %} -C ---DATA-- -return array() ---EXPECT-- -A - block1 - - -A - block1 - - block1extended - B - block2 -C - B - block2 -C diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/with_extends.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/with_extends.test deleted file mode 100644 index cf7953d3e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/embed/with_extends.test +++ /dev/null @@ -1,57 +0,0 @@ ---TEST-- -"embed" tag ---TEMPLATE-- -{% extends "base.twig" %} - -{% block c1 %} - {{ parent() }} - blockc1baseextended -{% endblock %} - -{% block c2 %} - {{ parent() }} - - {% embed "foo.twig" %} - {% block c1 %} - {{ parent() }} - block1extended - {% endblock %} - {% endembed %} -{% endblock %} ---TEMPLATE(base.twig)-- -A -{% block c1 %} - blockc1base -{% endblock %} -{% block c2 %} - blockc2base -{% endblock %} -B ---TEMPLATE(foo.twig)-- -A -{% block c1 %} - block1 -{% endblock %} -B -{% block c2 %} - block2 -{% endblock %} -C ---DATA-- -return array() ---EXPECT-- -A - blockc1base - - blockc1baseextended - blockc2base - - - -A - block1 - - block1extended - B - block2 -CB \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/basic.test deleted file mode 100644 index 82094f2f0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/basic.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"filter" tag applies a filter on its children ---TEMPLATE-- -{% filter upper %} -Some text with a {{ var }} -{% endfilter %} ---DATA-- -return array('var' => 'var') ---EXPECT-- -SOME TEXT WITH A VAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/json_encode.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/json_encode.test deleted file mode 100644 index 3e7148bf4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/json_encode.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"filter" tag applies a filter on its children ---TEMPLATE-- -{% filter json_encode|raw %}test{% endfilter %} ---DATA-- -return array() ---EXPECT-- -"test" diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/multiple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/multiple.test deleted file mode 100644 index 75512ef96..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/multiple.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"filter" tags accept multiple chained filters ---TEMPLATE-- -{% filter lower|title %} - {{ var }} -{% endfilter %} ---DATA-- -return array('var' => 'VAR') ---EXPECT-- - Var diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/nested.test deleted file mode 100644 index 7e4e4eb33..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/nested.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"filter" tags can be nested at will ---TEMPLATE-- -{% filter lower|title %} - {{ var }} - {% filter upper %} - {{ var }} - {% endfilter %} - {{ var }} -{% endfilter %} ---DATA-- -return array('var' => 'var') ---EXPECT-- - Var - Var - Var diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_for_tag.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_for_tag.test deleted file mode 100644 index 22745eadf..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_for_tag.test +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -"filter" tag applies the filter on "for" tags ---TEMPLATE-- -{% filter upper %} -{% for item in items %} -{{ item }} -{% endfor %} -{% endfilter %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- -A -B diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_if_tag.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_if_tag.test deleted file mode 100644 index afd95b296..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/filter/with_if_tag.test +++ /dev/null @@ -1,29 +0,0 @@ ---TEST-- -"filter" tag applies the filter on "if" tags ---TEMPLATE-- -{% filter upper %} -{% if items %} -{{ items|join(', ') }} -{% endif %} - -{% if items.3 is defined %} -FOO -{% else %} -{{ items.1 }} -{% endif %} - -{% if items.3 is defined %} -FOO -{% elseif items.1 %} -{{ items.0 }} -{% endif %} - -{% endfilter %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- -A, B - -B - -A diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/condition.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/condition.test deleted file mode 100644 index 380531f78..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/condition.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"for" tag takes a condition ---TEMPLATE-- -{% for i in 1..5 if i is odd -%} - {{ loop.index }}.{{ i }}{{ foo.bar }} -{% endfor %} ---DATA-- -return array('foo' => array('bar' => 'X')) ---CONFIG-- -return array('strict_variables' => false) ---EXPECT-- -1.1X -2.3X -3.5X diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/context.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/context.test deleted file mode 100644 index ddc69307b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/context.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"for" tag keeps the context safe ---TEMPLATE-- -{% for item in items %} - {% for item in items %} - * {{ item }} - {% endfor %} - * {{ item }} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * a - * b - * a - * a - * b - * b diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/else.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/else.test deleted file mode 100644 index 20ccc880c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/else.test +++ /dev/null @@ -1,23 +0,0 @@ ---TEST-- -"for" tag can use an "else" clause ---TEMPLATE-- -{% for item in items %} - * {{ item }} -{% else %} - no item -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * a - * b ---DATA-- -return array('items' => array()) ---EXPECT-- - no item ---DATA-- -return array() ---CONFIG-- -return array('strict_variables' => false) ---EXPECT-- - no item diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/inner_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/inner_variables.test deleted file mode 100644 index 49fb9ca6f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/inner_variables.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"for" tag does not reset inner variables ---TEMPLATE-- -{% for i in 1..2 %} - {% for j in 0..2 %} - {{k}}{% set k = k+1 %} {{ loop.parent.loop.index }} - {% endfor %} -{% endfor %} ---DATA-- -return array('k' => 0) ---EXPECT-- - 0 1 - 1 1 - 2 1 - 3 2 - 4 2 - 5 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys.test deleted file mode 100644 index 4e22cb473..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"for" tag can iterate over keys ---TEMPLATE-- -{% for key in items|keys %} - * {{ key }} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * 0 - * 1 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys_and_values.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys_and_values.test deleted file mode 100644 index 4c211689d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/keys_and_values.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"for" tag can iterate over keys and values ---TEMPLATE-- -{% for key, item in items %} - * {{ key }}/{{ item }} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * 0/a - * 1/b diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context.test deleted file mode 100644 index 93bc76a1f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -"for" tag adds a loop variable to the context ---TEMPLATE-- -{% for item in items %} - * {{ loop.index }}/{{ loop.index0 }} - * {{ loop.revindex }}/{{ loop.revindex0 }} - * {{ loop.first }}/{{ loop.last }}/{{ loop.length }} - -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * 1/0 - * 2/1 - * 1//2 - - * 2/1 - * 1/0 - * /1/2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context_local.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context_local.test deleted file mode 100644 index 58af2c326..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_context_local.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"for" tag adds a loop variable to the context locally ---TEMPLATE-- -{% for item in items %} -{% endfor %} -{% if loop is not defined %}WORKS{% endif %} ---DATA-- -return array('items' => array()) ---EXPECT-- -WORKS diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined.test deleted file mode 100644 index 4301ef2ff..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"for" tag ---TEMPLATE-- -{% for i, item in items if i > 0 %} - {{ loop.last }} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXCEPTION-- -Twig_Error_Syntax: The "loop.last" variable is not defined when looping with a condition in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined_cond.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined_cond.test deleted file mode 100644 index c7e723a51..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/loop_not_defined_cond.test +++ /dev/null @@ -1,9 +0,0 @@ ---TEST-- -"for" tag ---TEMPLATE-- -{% for i, item in items if loop.last > 0 %} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXCEPTION-- -Twig_Error_Syntax: The "loop" variable cannot be used in a looping condition in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/nested_else.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/nested_else.test deleted file mode 100644 index f8b9f6bc1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/nested_else.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"for" tag can use an "else" clause ---TEMPLATE-- -{% for item in items %} - {% for item in items1 %} - * {{ item }} - {% else %} - no {{ item }} - {% endfor %} -{% else %} - no item1 -{% endfor %} ---DATA-- -return array('items' => array('a', 'b'), 'items1' => array()) ---EXPECT-- -no a - no b diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects.test deleted file mode 100644 index 503443792..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects.test +++ /dev/null @@ -1,43 +0,0 @@ ---TEST-- -"for" tag iterates over iterable objects ---TEMPLATE-- -{% for item in items %} - * {{ item }} - * {{ loop.index }}/{{ loop.index0 }} - * {{ loop.first }} - -{% endfor %} - -{% for key, value in items %} - * {{ key }}/{{ value }} -{% endfor %} - -{% for key in items|keys %} - * {{ key }} -{% endfor %} ---DATA-- -class ItemsIterator implements Iterator -{ - protected $values = array('foo' => 'bar', 'bar' => 'foo'); - public function current() { return current($this->values); } - public function key() { return key($this->values); } - public function next() { return next($this->values); } - public function rewind() { return reset($this->values); } - public function valid() { return false !== current($this->values); } -} -return array('items' => new ItemsIterator()) ---EXPECT-- - * bar - * 1/0 - * 1 - - * foo - * 2/1 - * - - - * foo/bar - * bar/foo - - * foo - * bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects_countable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects_countable.test deleted file mode 100644 index 4a1ff6119..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/objects_countable.test +++ /dev/null @@ -1,47 +0,0 @@ ---TEST-- -"for" tag iterates over iterable and countable objects ---TEMPLATE-- -{% for item in items %} - * {{ item }} - * {{ loop.index }}/{{ loop.index0 }} - * {{ loop.revindex }}/{{ loop.revindex0 }} - * {{ loop.first }}/{{ loop.last }}/{{ loop.length }} - -{% endfor %} - -{% for key, value in items %} - * {{ key }}/{{ value }} -{% endfor %} - -{% for key in items|keys %} - * {{ key }} -{% endfor %} ---DATA-- -class ItemsIteratorCountable implements Iterator, Countable -{ - protected $values = array('foo' => 'bar', 'bar' => 'foo'); - public function current() { return current($this->values); } - public function key() { return key($this->values); } - public function next() { return next($this->values); } - public function rewind() { return reset($this->values); } - public function valid() { return false !== current($this->values); } - public function count() { return count($this->values); } -} -return array('items' => new ItemsIteratorCountable()) ---EXPECT-- - * bar - * 1/0 - * 2/1 - * 1//2 - - * foo - * 2/1 - * 1/0 - * /1/2 - - - * foo/bar - * bar/foo - - * foo - * bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/recursive.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/recursive.test deleted file mode 100644 index 17b2e2223..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/recursive.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"for" tags can be nested ---TEMPLATE-- -{% for key, item in items %} -* {{ key }} ({{ loop.length }}): -{% for value in item %} - * {{ value }} ({{ loop.length }}) -{% endfor %} -{% endfor %} ---DATA-- -return array('items' => array('a' => array('a1', 'a2', 'a3'), 'b' => array('b1'))) ---EXPECT-- -* a (2): - * a1 (3) - * a2 (3) - * a3 (3) -* b (2): - * b1 (1) diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/values.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/values.test deleted file mode 100644 index 82f2ae8a4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/for/values.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"for" tag iterates over item values ---TEMPLATE-- -{% for item in items %} - * {{ item }} -{% endfor %} ---DATA-- -return array('items' => array('a', 'b')) ---EXPECT-- - * a - * b diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/from.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/from.test deleted file mode 100644 index 5f5da0ec1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/from.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -global variables ---TEMPLATE-- -{% include "included.twig" %} -{% from "included.twig" import foobar %} -{{ foobar() }} ---TEMPLATE(included.twig)-- -{% macro foobar() %} -called foobar -{% endmacro %} ---DATA-- -return array(); ---EXPECT-- -called foobar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/basic.test deleted file mode 100644 index c1c3d2768..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/basic.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"if" creates a condition ---TEMPLATE-- -{% if a is defined %} - {{ a }} -{% elseif b is defined %} - {{ b }} -{% else %} - NOTHING -{% endif %} ---DATA-- -return array('a' => 'a') ---EXPECT-- - a ---DATA-- -return array('b' => 'b') ---EXPECT-- - b ---DATA-- -return array() ---EXPECT-- - NOTHING diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/expression.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/expression.test deleted file mode 100644 index edfb73df4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/if/expression.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"if" takes an expression as a test ---TEMPLATE-- -{% if a < 2 %} - A1 -{% elseif a > 10 %} - A2 -{% else %} - A3 -{% endif %} ---DATA-- -return array('a' => 1) ---EXPECT-- - A1 ---DATA-- -return array('a' => 12) ---EXPECT-- - A2 ---DATA-- -return array('a' => 7) ---EXPECT-- - A3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/basic.test deleted file mode 100644 index 8fe1a6c13..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/basic.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" tag ---TEMPLATE-- -FOO -{% include "foo.twig" %} - -BAR ---TEMPLATE(foo.twig)-- -FOOBAR ---DATA-- -return array() ---EXPECT-- -FOO - -FOOBAR -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/expression.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/expression.test deleted file mode 100644 index eaeeb112e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/expression.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" tag allows expressions for the template to include ---TEMPLATE-- -FOO -{% include foo %} - -BAR ---TEMPLATE(foo.twig)-- -FOOBAR ---DATA-- -return array('foo' => 'foo.twig') ---EXPECT-- -FOO - -FOOBAR -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/ignore_missing.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/ignore_missing.test deleted file mode 100644 index 24aed06de..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/ignore_missing.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"include" tag ---TEMPLATE-- -{% include ["foo.twig", "bar.twig"] ignore missing %} -{% include "foo.twig" ignore missing %} -{% include "foo.twig" ignore missing with {} %} -{% include "foo.twig" ignore missing with {} only %} ---DATA-- -return array() ---EXPECT-- diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing.test deleted file mode 100644 index f25e87155..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"include" tag ---TEMPLATE-- -{% include "foo.twig" %} ---DATA-- -return array(); ---EXCEPTION-- -Twig_Error_Loader: Template "foo.twig" is not defined in "index.twig" at line 2. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing_nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing_nested.test deleted file mode 100644 index 86c186444..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/missing_nested.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" tag ---TEMPLATE-- -{% extends "base.twig" %} - -{% block content %} - {{ parent() }} -{% endblock %} ---TEMPLATE(base.twig)-- -{% block content %} - {% include "foo.twig" %} -{% endblock %} ---DATA-- -return array(); ---EXCEPTION-- -Twig_Error_Loader: Template "foo.twig" is not defined in "base.twig" at line 3. diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/only.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/only.test deleted file mode 100644 index 77760a09e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/only.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"include" tag accept variables and only ---TEMPLATE-- -{% include "foo.twig" %} -{% include "foo.twig" only %} -{% include "foo.twig" with {'foo1': 'bar'} %} -{% include "foo.twig" with {'foo1': 'bar'} only %} ---TEMPLATE(foo.twig)-- -{% for k, v in _context %}{{ k }},{% endfor %} ---DATA-- -return array('foo' => 'bar') ---EXPECT-- -foo,global,_parent, -global,_parent, -foo,global,foo1,_parent, -foo1,global,_parent, diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/template_instance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/template_instance.test deleted file mode 100644 index 6ba064a38..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/template_instance.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"include" tag accepts Twig_Template instance ---TEMPLATE-- -{% include foo %} FOO ---TEMPLATE(foo.twig)-- -BAR ---DATA-- -return array('foo' => $twig->loadTemplate('foo.twig')) ---EXPECT-- -BAR FOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/templates_as_array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/templates_as_array.test deleted file mode 100644 index ab670ee06..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/templates_as_array.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"include" tag ---TEMPLATE-- -{% include ["foo.twig", "bar.twig"] %} -{% include ["bar.twig", "foo.twig"] %} ---TEMPLATE(foo.twig)-- -foo ---DATA-- -return array() ---EXPECT-- -foo -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/with_variables.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/with_variables.test deleted file mode 100644 index 41384ac7c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/include/with_variables.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"include" tag accept variables ---TEMPLATE-- -{% include "foo.twig" with {'foo': 'bar'} %} -{% include "foo.twig" with vars %} ---TEMPLATE(foo.twig)-- -{{ foo }} ---DATA-- -return array('vars' => array('foo' => 'bar')) ---EXPECT-- -bar -bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/basic.test deleted file mode 100644 index 0778a4b49..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/basic.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "foo.twig" %} - -{% block content %} -FOO -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}{% endblock %} ---DATA-- -return array() ---EXPECT-- -FOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr.test deleted file mode 100644 index 9a81499ab..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr.test +++ /dev/null @@ -1,32 +0,0 @@ ---TEST-- -block_expr ---TEMPLATE-- -{% extends "base.twig" %} - -{% block element -%} - Element: - {{- parent() -}} -{% endblock %} ---TEMPLATE(base.twig)-- -{% spaceless %} -{% block element -%} -
    - {%- if item.children is defined %} - {%- for item in item.children %} - {{- block('element') -}} - {% endfor %} - {%- endif -%} -
    -{%- endblock %} -{% endspaceless %} ---DATA-- -return array( - 'item' => array( - 'children' => array( - null, - null, - ) - ) -) ---EXPECT-- -Element:
    Element:
    Element:
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr2.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr2.test deleted file mode 100644 index 3e868c0da..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/block_expr2.test +++ /dev/null @@ -1,34 +0,0 @@ ---TEST-- -block_expr2 ---TEMPLATE-- -{% extends "base2.twig" %} - -{% block element -%} - Element: - {{- parent() -}} -{% endblock %} ---TEMPLATE(base2.twig)-- -{% extends "base.twig" %} ---TEMPLATE(base.twig)-- -{% spaceless %} -{% block element -%} -
    - {%- if item.children is defined %} - {%- for item in item.children %} - {{- block('element') -}} - {% endfor %} - {%- endif -%} -
    -{%- endblock %} -{% endspaceless %} ---DATA-- -return array( - 'item' => array( - 'children' => array( - null, - null, - ) - ) -) ---EXPECT-- -Element:
    Element:
    Element:
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/conditional.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/conditional.test deleted file mode 100644 index 8576e773a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/conditional.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends standalone ? foo : 'bar.twig' %} - -{% block content %}{{ parent() }}FOO{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}FOO{% endblock %} ---TEMPLATE(bar.twig)-- -{% block content %}BAR{% endblock %} ---DATA-- -return array('foo' => 'foo.twig', 'standalone' => true) ---EXPECT-- -FOOFOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/dynamic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/dynamic.test deleted file mode 100644 index ee06ddce3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/dynamic.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends foo %} - -{% block content %} -FOO -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}{% endblock %} ---DATA-- -return array('foo' => 'foo.twig') ---EXPECT-- -FOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/empty.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/empty.test deleted file mode 100644 index 784f35718..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/empty.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "foo.twig" %} ---TEMPLATE(foo.twig)-- -{% block content %}FOO{% endblock %} ---DATA-- -return array() ---EXPECT-- -FOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array.test deleted file mode 100644 index a1cb1ce8a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends ["foo.twig", "bar.twig"] %} ---TEMPLATE(bar.twig)-- -{% block content %} -foo -{% endblock %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_empty_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_empty_name.test deleted file mode 100644 index acc74f6a1..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_empty_name.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends ["", "bar.twig"] %} ---TEMPLATE(bar.twig)-- -{% block content %} -foo -{% endblock %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_null_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_null_name.test deleted file mode 100644 index cfa648d41..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/extends_as_array_with_null_name.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends [null, "bar.twig"] %} ---TEMPLATE(bar.twig)-- -{% block content %} -foo -{% endblock %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple.test deleted file mode 100644 index dfc2b6c49..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "layout.twig" %}{% block content %}{{ parent() }}index {% endblock %} ---TEMPLATE(layout.twig)-- -{% extends "base.twig" %}{% block content %}{{ parent() }}layout {% endblock %} ---TEMPLATE(base.twig)-- -{% block content %}base {% endblock %} ---DATA-- -return array() ---EXPECT-- -base layout index diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple_dynamic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple_dynamic.test deleted file mode 100644 index 1d3e639ca..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/multiple_dynamic.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% set foo = 1 %} -{{ include('parent.twig') }} -{{ include('parent.twig') }} -{% set foo = 2 %} -{{ include('parent.twig') }} ---TEMPLATE(parent.twig)-- -{% extends foo~'_parent.twig' %}{% block content %}{{ parent() }} parent{% endblock %} ---TEMPLATE(1_parent.twig)-- -{% block content %}1{% endblock %} ---TEMPLATE(2_parent.twig)-- -{% block content %}2{% endblock %} ---DATA-- -return array() ---EXPECT-- -1 parent - -1 parent - -2 parent diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks.test deleted file mode 100644 index faca92591..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"block" tag ---TEMPLATE-- -{% extends "foo.twig" %} - -{% block content %} - {% block subcontent %} - {% block subsubcontent %} - SUBSUBCONTENT - {% endblock %} - {% endblock %} -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %} - {% block subcontent %} - SUBCONTENT - {% endblock %} -{% endblock %} ---DATA-- -return array() ---EXPECT-- -SUBSUBCONTENT diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks_parent_only.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks_parent_only.test deleted file mode 100644 index 0ad11d0c0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_blocks_parent_only.test +++ /dev/null @@ -1,15 +0,0 @@ ---TEST-- -"block" tag ---TEMPLATE-- -{% block content %} - CONTENT - {%- block subcontent -%} - SUBCONTENT - {%- endblock -%} - ENDCONTENT -{% endblock %} ---TEMPLATE(foo.twig)-- ---DATA-- -return array() ---EXPECT-- -CONTENTSUBCONTENTENDCONTENT diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_inheritance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_inheritance.test deleted file mode 100644 index 71e3cdfd4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/nested_inheritance.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "layout.twig" %} -{% block inside %}INSIDE{% endblock inside %} ---TEMPLATE(layout.twig)-- -{% extends "base.twig" %} -{% block body %} - {% block inside '' %} -{% endblock body %} ---TEMPLATE(base.twig)-- -{% block body '' %} ---DATA-- -return array() ---EXPECT-- -INSIDE diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent.test deleted file mode 100644 index 4f975db80..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "foo.twig" %} - -{% block content %}{{ parent() }}FOO{{ parent() }}{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}BAR{% endblock %} ---DATA-- -return array() ---EXPECT-- -BARFOOBAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_change.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_change.test deleted file mode 100644 index a8bc90cef..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_change.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends foo ? 'foo.twig' : 'bar.twig' %} ---TEMPLATE(foo.twig)-- -FOO ---TEMPLATE(bar.twig)-- -BAR ---DATA-- -return array('foo' => true) ---EXPECT-- -FOO ---DATA-- -return array('foo' => false) ---EXPECT-- -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_in_a_block.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_in_a_block.test deleted file mode 100644 index c9e86b1ae..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_in_a_block.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% block content %} - {% extends "foo.twig" %} -{% endblock %} ---EXCEPTION-- -Twig_Error_Syntax: Cannot extend from a block in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_isolation.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_isolation.test deleted file mode 100644 index 628167135..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_isolation.test +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "base.twig" %} -{% block content %}{% include "included.twig" %}{% endblock %} - -{% block footer %}Footer{% endblock %} ---TEMPLATE(included.twig)-- -{% extends "base.twig" %} -{% block content %}Included Content{% endblock %} ---TEMPLATE(base.twig)-- -{% block content %}Default Content{% endblock %} - -{% block footer %}Default Footer{% endblock %} ---DATA-- -return array() ---EXPECT-- -Included Content -Default Footer -Footer diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_nested.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_nested.test deleted file mode 100644 index 71e7c2080..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_nested.test +++ /dev/null @@ -1,28 +0,0 @@ ---TEST-- -"extends" tag ---TEMPLATE-- -{% extends "foo.twig" %} - -{% block content %} - {% block inside %} - INSIDE OVERRIDDEN - {% endblock %} - - BEFORE - {{ parent() }} - AFTER -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %} - BAR -{% endblock %} ---DATA-- -return array() ---EXPECT-- - -INSIDE OVERRIDDEN - - BEFORE - BAR - - AFTER diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends.test deleted file mode 100644 index a9eaa4c13..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"parent" tag ---TEMPLATE-- -{% block content %} - {{ parent() }} -{% endblock %} ---EXCEPTION-- -Twig_Error_Syntax: Calling "parent" on a template that does not extend nor "use" another template is forbidden in "index.twig" at line 3 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends_but_traits.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends_but_traits.test deleted file mode 100644 index 63c730550..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/parent_without_extends_but_traits.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"parent" tag ---TEMPLATE-- -{% use 'foo.twig' %} - -{% block content %} - {{ parent() }} -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}BAR{% endblock %} ---DATA-- -return array() ---EXPECT-- -BAR diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/template_instance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/template_instance.test deleted file mode 100644 index d1876a52d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/template_instance.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"extends" tag accepts Twig_Template instance ---TEMPLATE-- -{% extends foo %} - -{% block content %} -{{ parent() }}FOO -{% endblock %} ---TEMPLATE(foo.twig)-- -{% block content %}BAR{% endblock %} ---DATA-- -return array('foo' => $twig->loadTemplate('foo.twig')) ---EXPECT-- -BARFOO diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/use.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/use.test deleted file mode 100644 index 8f9ece7ce..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/inheritance/use.test +++ /dev/null @@ -1,44 +0,0 @@ ---TEST-- -"parent" function ---TEMPLATE-- -{% extends "parent.twig" %} - -{% use "use1.twig" %} -{% use "use2.twig" %} - -{% block content_parent %} - {{ parent() }} -{% endblock %} - -{% block content_use1 %} - {{ parent() }} -{% endblock %} - -{% block content_use2 %} - {{ parent() }} -{% endblock %} - -{% block content %} - {{ block('content_use1_only') }} - {{ block('content_use2_only') }} -{% endblock %} ---TEMPLATE(parent.twig)-- -{% block content_parent 'content_parent' %} -{% block content_use1 'content_parent' %} -{% block content_use2 'content_parent' %} -{% block content '' %} ---TEMPLATE(use1.twig)-- -{% block content_use1 'content_use1' %} -{% block content_use2 'content_use1' %} -{% block content_use1_only 'content_use1_only' %} ---TEMPLATE(use2.twig)-- -{% block content_use2 'content_use2' %} -{% block content_use2_only 'content_use2_only' %} ---DATA-- -return array() ---EXPECT-- - content_parent - content_use1 - content_use2 - content_use1_only - content_use2_only diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/basic.test deleted file mode 100644 index eef0c10d5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/basic.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"macro" tag ---TEMPLATE-- -{% import _self as macros %} - -{{ macros.input('username') }} -{{ macros.input('password', null, 'password', 1) }} - -{% macro input(name, value, type, size) %} - -{% endmacro %} ---DATA-- -return array() ---EXPECT-- - - - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/endmacro_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/endmacro_name.test deleted file mode 100644 index ae6203bb6..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/endmacro_name.test +++ /dev/null @@ -1,16 +0,0 @@ ---TEST-- -"macro" tag supports name for endmacro ---TEMPLATE-- -{% import _self as macros %} - -{{ macros.foo() }} -{{ macros.bar() }} - -{% macro foo() %}foo{% endmacro %} -{% macro bar() %}bar{% endmacro bar %} ---DATA-- -return array() ---EXPECT-- -foo -bar - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/external.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/external.test deleted file mode 100644 index 5cd3dae66..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/external.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"macro" tag ---TEMPLATE-- -{% import 'forms.twig' as forms %} - -{{ forms.input('username') }} -{{ forms.input('password', null, 'password', 1) }} ---TEMPLATE(forms.twig)-- -{% macro input(name, value, type, size) %} - -{% endmacro %} ---DATA-- -return array() ---EXPECT-- - - - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test deleted file mode 100644 index 205f59182..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test +++ /dev/null @@ -1,18 +0,0 @@ ---TEST-- -"macro" tag ---TEMPLATE-- -{% from 'forms.twig' import foo %} -{% from 'forms.twig' import foo as foobar, bar %} - -{{ foo('foo') }} -{{ foobar('foo') }} -{{ bar('foo') }} ---TEMPLATE(forms.twig)-- -{% macro foo(name) %}foo{{ name }}{% endmacro %} -{% macro bar(name) %}bar{{ name }}{% endmacro %} ---DATA-- -return array() ---EXPECT-- -foofoo -foofoo -barfoo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from_with_reserved_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from_with_reserved_name.test deleted file mode 100644 index 6df4f5d6c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from_with_reserved_name.test +++ /dev/null @@ -1,9 +0,0 @@ ---TEST-- -"from" tag with reserved name ---TEMPLATE-- -{% from 'forms.twig' import templateName %} ---TEMPLATE(forms.twig)-- ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: "templateName" cannot be an imported macro as it is a reserved keyword in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/global.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/global.test deleted file mode 100644 index 6b371768e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/global.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"macro" tag ---TEMPLATE-- -{% from 'forms.twig' import foo %} - -{{ foo('foo') }} -{{ foo() }} ---TEMPLATE(forms.twig)-- -{% macro foo(name) %}{{ name|default('foo') }}{{ global }}{% endmacro %} ---DATA-- -return array() ---EXPECT-- -fooglobal -fooglobal diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/import_with_reserved_nam.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/import_with_reserved_nam.test deleted file mode 100644 index e5aa7498c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/import_with_reserved_nam.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -"from" tag with reserved name ---TEMPLATE-- -{% import 'forms.twig' as macros %} - -{{ macros.parent() }} ---TEMPLATE(forms.twig)-- ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: "parent" cannot be called as macro as it is a reserved keyword in "index.twig" at line 4 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/reserved_name.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/reserved_name.test deleted file mode 100644 index a2dde5a50..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/reserved_name.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"macro" tag with reserved name ---TEMPLATE-- -{% macro parent(arg1, arg2) %} - parent -{% endmacro %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: "parent" cannot be used as a macro name as it is a reserved keyword in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/self_import.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/self_import.test deleted file mode 100644 index 17756cb6c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/self_import.test +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -"macro" tag ---TEMPLATE-- -{% import _self as forms %} - -{{ forms.input('username') }} -{{ forms.input('password', null, 'password', 1) }} - -{% macro input(name, value, type, size) %} - -{% endmacro %} ---DATA-- -return array() ---EXPECT-- - - - diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/special_chars.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/special_chars.test deleted file mode 100644 index 372177073..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/special_chars.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"§" as a macro name ---TEMPLATE-- -{% import _self as macros %} - -{{ macros.§('foo') }} - -{% macro §(foo) %} - §{{ foo }}§ -{% endmacro %} ---DATA-- -return array() ---EXPECT-- -§foo§ diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/super_globals.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/super_globals.test deleted file mode 100644 index 567946281..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/super_globals.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -Super globals as macro arguments ---TEMPLATE-- -{% import _self as macros %} - -{{ macros.foo('foo') }} - -{% macro foo(GET) %} - {{ GET }} -{% endmacro %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/basic.legacy.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/basic.legacy.test deleted file mode 100644 index 0445e8530..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/basic.legacy.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"raw" tag ---TEMPLATE-- -{% raw %} -{{ foo }} -{% endraw %} ---DATA-- -return array() ---EXPECT-- -{{ foo }} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/mixed_usage_with_raw.legacy.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/mixed_usage_with_raw.legacy.test deleted file mode 100644 index 2fd9fb26d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/mixed_usage_with_raw.legacy.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"raw" tag ---TEMPLATE-- -{% raw %} -{{ foo }} -{% endverbatim %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: Unexpected end of file: Unclosed "raw" block in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/whitespace_control.legacy.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/whitespace_control.legacy.test deleted file mode 100644 index 352bb1876..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/raw/whitespace_control.legacy.test +++ /dev/null @@ -1,56 +0,0 @@ ---TEST-- -"raw" tag ---TEMPLATE-- -1*** - -{%- raw %} - {{ 'bla' }} -{% endraw %} - -1*** -2*** - -{%- raw -%} - {{ 'bla' }} -{% endraw %} - -2*** -3*** - -{%- raw -%} - {{ 'bla' }} -{% endraw -%} - -3*** -4*** - -{%- raw -%} - {{ 'bla' }} -{%- endraw %} - -4*** -5*** - -{%- raw -%} - {{ 'bla' }} -{%- endraw -%} - -5*** ---DATA-- -return array() ---EXPECT-- -1*** - {{ 'bla' }} - - -1*** -2***{{ 'bla' }} - - -2*** -3***{{ 'bla' }} -3*** -4***{{ 'bla' }} - -4*** -5***{{ 'bla' }}5*** diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid1.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid1.test deleted file mode 100644 index 683c59a0e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid1.test +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -sandbox tag ---TEMPLATE-- -{%- sandbox %} - {%- include "foo.twig" %} - a -{%- endsandbox %} ---TEMPLATE(foo.twig)-- -foo ---EXCEPTION-- -Twig_Error_Syntax: Only "include" tags are allowed within a "sandbox" section in "index.twig" at line 4 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid2.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid2.test deleted file mode 100644 index 3dcfa88c7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/not_valid2.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -sandbox tag ---TEMPLATE-- -{%- sandbox %} - {%- include "foo.twig" %} - - {% if 1 %} - {%- include "foo.twig" %} - {% endif %} -{%- endsandbox %} ---TEMPLATE(foo.twig)-- -foo ---EXCEPTION-- -Twig_Error_Syntax: Only "include" tags are allowed within a "sandbox" section in "index.twig" at line 5 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/simple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/simple.test deleted file mode 100644 index de20f3dba..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/sandbox/simple.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -sandbox tag ---TEMPLATE-- -{%- sandbox %} - {%- include "foo.twig" %} -{%- endsandbox %} - -{%- sandbox %} - {%- include "foo.twig" %} - {%- include "foo.twig" %} -{%- endsandbox %} - -{%- sandbox %}{% include "foo.twig" %}{% endsandbox %} ---TEMPLATE(foo.twig)-- -foo ---DATA-- -return array() ---EXPECT-- -foo -foo -foo -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/basic.test deleted file mode 100644 index a5a9f830e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/basic.test +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -"set" tag ---TEMPLATE-- -{% set foo = 'foo' %} -{% set bar = 'foo
    ' %} - -{{ foo }} -{{ bar }} - -{% set foo, bar = 'foo', 'bar' %} - -{{ foo }}{{ bar }} ---DATA-- -return array() ---EXPECT-- -foo -foo<br /> - - -foobar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture-empty.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture-empty.test deleted file mode 100644 index ec657f005..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture-empty.test +++ /dev/null @@ -1,9 +0,0 @@ ---TEST-- -"set" tag block empty capture ---TEMPLATE-- -{% set foo %}{% endset %} - -{% if foo %}FAIL{% endif %} ---DATA-- -return array() ---EXPECT-- diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture.test deleted file mode 100644 index f156a1a7f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/capture.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"set" tag block capture ---TEMPLATE-- -{% set foo %}f
    o
    o{% endset %} - -{{ foo }} ---DATA-- -return array() ---EXPECT-- -f
    o
    o diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/expression.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/expression.test deleted file mode 100644 index 8ff434a01..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/set/expression.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"set" tag ---TEMPLATE-- -{% set foo, bar = 'foo' ~ 'bar', 'bar' ~ 'foo' %} - -{{ foo }} -{{ bar }} ---DATA-- -return array() ---EXPECT-- -foobar -barfoo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/spaceless/simple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/spaceless/simple.test deleted file mode 100644 index dd06dec25..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/spaceless/simple.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"spaceless" tag removes whites between HTML tags ---TEMPLATE-- -{% spaceless %} - -
    foo
    - -{% endspaceless %} ---DATA-- -return array() ---EXPECT-- -
    foo
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/special_chars.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/special_chars.test deleted file mode 100644 index 789b4ba80..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/special_chars.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -"§" custom tag ---TEMPLATE-- -{% § %} ---DATA-- -return array() ---EXPECT-- -§ diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/trim_block.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/trim_block.test deleted file mode 100644 index 1d2273f88..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/trim_block.test +++ /dev/null @@ -1,74 +0,0 @@ ---TEST-- -Whitespace trimming on tags. ---TEMPLATE-- -{{ 5 * '{#-'|length }} -{{ '{{-'|length * 5 + '{%-'|length }} - -Trim on control tag: -{% for i in range(1, 9) -%} - {{ i }} -{%- endfor %} - - -Trim on output tag: -{% for i in range(1, 9) %} - {{- i -}} -{% endfor %} - - -Trim comments: - -{#- Invisible -#} - -After the comment. - -Trim leading space: -{% if leading %} - - {{- leading }} -{% endif %} - -{%- if leading %} - {{- leading }} - -{%- endif %} - - -Trim trailing space: -{% if trailing -%} - {{ trailing -}} - -{% endif -%} - -Combined: - -{%- if both -%} -
      -
    • {{- both -}}
    • -
    - -{%- endif -%} - -end ---DATA-- -return array('leading' => 'leading space', 'trailing' => 'trailing space', 'both' => 'both') ---EXPECT-- -15 -18 - -Trim on control tag: -123456789 - -Trim on output tag: -123456789 - -Trim comments:After the comment. - -Trim leading space: -leading space -leading space - -Trim trailing space: -trailing spaceCombined:
      -
    • both
    • -
    end diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/aliases.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/aliases.test deleted file mode 100644 index f887006f6..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/aliases.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "blocks.twig" with content as foo %} - -{{ block('foo') }} ---TEMPLATE(blocks.twig)-- -{% block content 'foo' %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/basic.test deleted file mode 100644 index 7364d76de..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/basic.test +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "blocks.twig" %} - -{{ block('content') }} ---TEMPLATE(blocks.twig)-- -{% block content 'foo' %} ---DATA-- -return array() ---EXPECT-- -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep.test deleted file mode 100644 index b551a1e60..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep.test +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "foo.twig" %} - -{{ block('content') }} -{{ block('foo') }} -{{ block('bar') }} ---TEMPLATE(foo.twig)-- -{% use "bar.twig" %} - -{% block content 'foo' %} -{% block foo 'foo' %} ---TEMPLATE(bar.twig)-- -{% block content 'bar' %} -{% block bar 'bar' %} ---DATA-- -return array() ---EXPECT-- -foo -foo -bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep_empty.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep_empty.test deleted file mode 100644 index 05cca682e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/deep_empty.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "foo.twig" %} ---TEMPLATE(foo.twig)-- -{% use "bar.twig" %} ---TEMPLATE(bar.twig)-- ---DATA-- -return array() ---EXPECT-- diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance.test deleted file mode 100644 index 6368b08de..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance.test +++ /dev/null @@ -1,25 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "parent.twig" %} - -{{ block('container') }} ---TEMPLATE(parent.twig)-- -{% use "ancestor.twig" %} - -{% block sub_container %} -
    overriden sub_container
    -{% endblock %} ---TEMPLATE(ancestor.twig)-- -{% block container %} -
    {{ block('sub_container') }}
    -{% endblock %} - -{% block sub_container %} -
    sub_container
    -{% endblock %} ---DATA-- -return array() ---EXPECT-- -
    overriden sub_container
    -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance2.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance2.test deleted file mode 100644 index 114e3015e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/inheritance2.test +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "ancestor.twig" %} -{% use "parent.twig" %} - -{{ block('container') }} ---TEMPLATE(parent.twig)-- -{% block sub_container %} -
    overriden sub_container
    -{% endblock %} ---TEMPLATE(ancestor.twig)-- -{% block container %} -
    {{ block('sub_container') }}
    -{% endblock %} - -{% block sub_container %} -
    sub_container
    -{% endblock %} ---DATA-- -return array() ---EXPECT-- -
    overriden sub_container
    -
    diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple.test deleted file mode 100644 index 198be0c5c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple.test +++ /dev/null @@ -1,21 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "foo.twig" %} -{% use "bar.twig" %} - -{{ block('content') }} -{{ block('foo') }} -{{ block('bar') }} ---TEMPLATE(foo.twig)-- -{% block content 'foo' %} -{% block foo 'foo' %} ---TEMPLATE(bar.twig)-- -{% block content 'bar' %} -{% block bar 'bar' %} ---DATA-- -return array() ---EXPECT-- -bar -foo -bar diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple_aliases.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple_aliases.test deleted file mode 100644 index 8de871a8a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/multiple_aliases.test +++ /dev/null @@ -1,23 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use "foo.twig" with content as foo_content %} -{% use "bar.twig" %} - -{{ block('content') }} -{{ block('foo') }} -{{ block('bar') }} -{{ block('foo_content') }} ---TEMPLATE(foo.twig)-- -{% block content 'foo' %} -{% block foo 'foo' %} ---TEMPLATE(bar.twig)-- -{% block content 'bar' %} -{% block bar 'bar' %} ---DATA-- -return array() ---EXPECT-- -bar -foo -bar -foo diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block.test deleted file mode 100644 index 59db23d95..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block.test +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use 'file2.html.twig' with foobar as base_base_foobar %} -{% block foobar %} - {{- block('base_base_foobar') -}} - Content of block (second override) -{% endblock foobar %} ---TEMPLATE(file2.html.twig)-- -{% use 'file1.html.twig' with foobar as base_foobar %} -{% block foobar %} - {{- block('base_foobar') -}} - Content of block (first override) -{% endblock foobar %} ---TEMPLATE(file1.html.twig)-- -{% block foobar -%} - Content of block -{% endblock foobar %} ---DATA-- -return array() ---EXPECT-- -Content of block -Content of block (first override) -Content of block (second override) diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block2.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block2.test deleted file mode 100644 index d3f302df0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block2.test +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use 'file2.html.twig'%} -{% block foobar %} - {{- parent() -}} - Content of block (second override) -{% endblock foobar %} ---TEMPLATE(file2.html.twig)-- -{% use 'file1.html.twig' %} -{% block foobar %} - {{- parent() -}} - Content of block (first override) -{% endblock foobar %} ---TEMPLATE(file1.html.twig)-- -{% block foobar -%} - Content of block -{% endblock foobar %} ---DATA-- -return array() ---EXPECT-- -Content of block -Content of block (first override) -Content of block (second override) diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block3.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block3.test deleted file mode 100644 index 95b55a469..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/use/parent_block3.test +++ /dev/null @@ -1,38 +0,0 @@ ---TEST-- -"use" tag ---TEMPLATE-- -{% use 'file2.html.twig' %} -{% use 'file1.html.twig' with foo %} -{% block foo %} - {{- parent() -}} - Content of foo (second override) -{% endblock foo %} -{% block bar %} - {{- parent() -}} - Content of bar (second override) -{% endblock bar %} ---TEMPLATE(file2.html.twig)-- -{% use 'file1.html.twig' %} -{% block foo %} - {{- parent() -}} - Content of foo (first override) -{% endblock foo %} -{% block bar %} - {{- parent() -}} - Content of bar (first override) -{% endblock bar %} ---TEMPLATE(file1.html.twig)-- -{% block foo -%} - Content of foo -{% endblock foo %} -{% block bar -%} - Content of bar -{% endblock bar %} ---DATA-- -return array() ---EXPECT-- -Content of foo -Content of foo (first override) -Content of foo (second override) -Content of bar -Content of bar (second override) diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/basic.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/basic.test deleted file mode 100644 index a95be5572..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/basic.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"verbatim" tag ---TEMPLATE-- -{% verbatim %} -{{ foo }} -{% endverbatim %} ---DATA-- -return array() ---EXPECT-- -{{ foo }} diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/mixed_usage_with_raw.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/mixed_usage_with_raw.test deleted file mode 100644 index 941dddcce..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/mixed_usage_with_raw.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"verbatim" tag ---TEMPLATE-- -{% verbatim %} -{{ foo }} -{% endraw %} ---DATA-- -return array() ---EXCEPTION-- -Twig_Error_Syntax: Unexpected end of file: Unclosed "verbatim" block in "index.twig" at line 2 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/whitespace_control.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/whitespace_control.test deleted file mode 100644 index eb6104446..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/verbatim/whitespace_control.test +++ /dev/null @@ -1,56 +0,0 @@ ---TEST-- -"verbatim" tag ---TEMPLATE-- -1*** - -{%- verbatim %} - {{ 'bla' }} -{% endverbatim %} - -1*** -2*** - -{%- verbatim -%} - {{ 'bla' }} -{% endverbatim %} - -2*** -3*** - -{%- verbatim -%} - {{ 'bla' }} -{% endverbatim -%} - -3*** -4*** - -{%- verbatim -%} - {{ 'bla' }} -{%- endverbatim %} - -4*** -5*** - -{%- verbatim -%} - {{ 'bla' }} -{%- endverbatim -%} - -5*** ---DATA-- -return array() ---EXPECT-- -1*** - {{ 'bla' }} - - -1*** -2***{{ 'bla' }} - - -2*** -3***{{ 'bla' }} -3*** -4***{{ 'bla' }} - -4*** -5***{{ 'bla' }}5*** diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/array.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/array.test deleted file mode 100644 index 1429d3753..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/array.test +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -array index test ---TEMPLATE-- -{% for key, value in days %} -{{ key }} -{% endfor %} ---DATA-- -return array('days' => array( - 1 => array('money' => 9), - 2 => array('money' => 21), - 3 => array('money' => 38), - 4 => array('money' => 6), - 18 => array('money' => 6), - 19 => array('money' => 3), - 31 => array('money' => 11), -)); ---EXPECT-- -1 -2 -3 -4 -18 -19 -31 diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/constant.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/constant.test deleted file mode 100644 index 60218ac04..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/constant.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"const" test ---TEMPLATE-- -{{ 8 is constant('E_NOTICE') ? 'ok' : 'no' }} -{{ 'bar' is constant('TwigTestFoo::BAR_NAME') ? 'ok' : 'no' }} -{{ value is constant('TwigTestFoo::BAR_NAME') ? 'ok' : 'no' }} -{{ 2 is constant('ARRAY_AS_PROPS', object) ? 'ok' : 'no' }} ---DATA-- -return array('value' => 'bar', 'object' => new ArrayObject(array('hi'))); ---EXPECT-- -ok -ok -ok -ok \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/defined.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/defined.test deleted file mode 100644 index cbfe03de5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/defined.test +++ /dev/null @@ -1,108 +0,0 @@ ---TEST-- -"defined" test ---TEMPLATE-- -{{ definedVar is defined ? 'ok' : 'ko' }} -{{ definedVar is not defined ? 'ko' : 'ok' }} -{{ undefinedVar is defined ? 'ko' : 'ok' }} -{{ undefinedVar is not defined ? 'ok' : 'ko' }} -{{ zeroVar is defined ? 'ok' : 'ko' }} -{{ nullVar is defined ? 'ok' : 'ko' }} -{{ nested.definedVar is defined ? 'ok' : 'ko' }} -{{ nested['definedVar'] is defined ? 'ok' : 'ko' }} -{{ nested.definedVar is not defined ? 'ko' : 'ok' }} -{{ nested.undefinedVar is defined ? 'ko' : 'ok' }} -{{ nested['undefinedVar'] is defined ? 'ko' : 'ok' }} -{{ nested.undefinedVar is not defined ? 'ok' : 'ko' }} -{{ nested.zeroVar is defined ? 'ok' : 'ko' }} -{{ nested.nullVar is defined ? 'ok' : 'ko' }} -{{ nested.definedArray.0 is defined ? 'ok' : 'ko' }} -{{ nested['definedArray'][0] is defined ? 'ok' : 'ko' }} -{{ object.foo is defined ? 'ok' : 'ko' }} -{{ object.undefinedMethod is defined ? 'ko' : 'ok' }} -{{ object.getFoo() is defined ? 'ok' : 'ko' }} -{{ object.getFoo('a') is defined ? 'ok' : 'ko' }} -{{ object.undefinedMethod() is defined ? 'ko' : 'ok' }} -{{ object.undefinedMethod('a') is defined ? 'ko' : 'ok' }} -{{ object.self.foo is defined ? 'ok' : 'ko' }} -{{ object.self.undefinedMethod is defined ? 'ko' : 'ok' }} -{{ object.undefinedMethod.self is defined ? 'ko' : 'ok' }} ---DATA-- -return array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'nullVar' => null, - 'nested' => array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'nullVar' => null, - 'definedArray' => array(0), - ), - 'object' => new TwigTestFoo(), -); ---EXPECT-- -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok ---DATA-- -return array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'nullVar' => null, - 'nested' => array( - 'definedVar' => 'defined', - 'zeroVar' => 0, - 'nullVar' => null, - 'definedArray' => array(0), - ), - 'object' => new TwigTestFoo(), -); ---CONFIG-- -return array('strict_variables' => false) ---EXPECT-- -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok -ok diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/empty.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/empty.test deleted file mode 100644 index a776d032b..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/empty.test +++ /dev/null @@ -1,45 +0,0 @@ ---TEST-- -"empty" test ---TEMPLATE-- -{{ foo is empty ? 'ok' : 'ko' }} -{{ bar is empty ? 'ok' : 'ko' }} -{{ foobar is empty ? 'ok' : 'ko' }} -{{ array is empty ? 'ok' : 'ko' }} -{{ zero is empty ? 'ok' : 'ko' }} -{{ string is empty ? 'ok' : 'ko' }} -{{ countable_empty is empty ? 'ok' : 'ko' }} -{{ countable_not_empty is empty ? 'ok' : 'ko' }} -{{ markup_empty is empty ? 'ok' : 'ko' }} -{{ markup_not_empty is empty ? 'ok' : 'ko' }} ---DATA-- - -class CountableStub implements Countable -{ - private $items; - - public function __construct(array $items) - { - $this->items = $items; - } - - public function count() - { - return count($this->items); - } -} -return array( - 'foo' => '', 'bar' => null, 'foobar' => false, 'array' => array(), 'zero' => 0, 'string' => '0', - 'countable_empty' => new CountableStub(array()), 'countable_not_empty' => new CountableStub(array(1, 2)), - 'markup_empty' => new Twig_Markup('', 'UTF-8'), 'markup_not_empty' => new Twig_Markup('test', 'UTF-8'), -); ---EXPECT-- -ok -ok -ok -ok -ko -ko -ok -ko -ok -ko diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/even.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/even.test deleted file mode 100644 index 695b4c2f8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/even.test +++ /dev/null @@ -1,14 +0,0 @@ ---TEST-- -"even" test ---TEMPLATE-- -{{ 1 is even ? 'ko' : 'ok' }} -{{ 2 is even ? 'ok' : 'ko' }} -{{ 1 is not even ? 'ok' : 'ko' }} -{{ 2 is not even ? 'ko' : 'ok' }} ---DATA-- -return array() ---EXPECT-- -ok -ok -ok -ok diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in.test deleted file mode 100644 index 545f51f81..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in.test +++ /dev/null @@ -1,128 +0,0 @@ ---TEST-- -Twig supports the in operator ---TEMPLATE-- -{% if bar in foo %} -TRUE -{% endif %} -{% if not (bar in foo) %} -{% else %} -TRUE -{% endif %} -{% if bar not in foo %} -{% else %} -TRUE -{% endif %} -{% if 'a' in bar %} -TRUE -{% endif %} -{% if 'c' not in bar %} -TRUE -{% endif %} -{% if '' in bar %} -TRUE -{% endif %} -{% if '' in '' %} -TRUE -{% endif %} -{% if '0' not in '' %} -TRUE -{% endif %} -{% if 'a' not in '0' %} -TRUE -{% endif %} -{% if '0' in '0' %} -TRUE -{% endif %} - -{{ false in [0, 1] ? 'TRUE' : 'FALSE' }} -{{ true in [0, 1] ? 'TRUE' : 'FALSE' }} -{{ '0' in [0, 1] ? 'TRUE' : 'FALSE' }} -{{ '' in [0, 1] ? 'TRUE' : 'FALSE' }} -{{ 0 in ['', 1] ? 'TRUE' : 'FALSE' }} - -{{ '' in 'foo' ? 'TRUE' : 'FALSE' }} -{{ 0 in 'foo' ? 'TRUE' : 'FALSE' }} -{{ false in 'foo' ? 'TRUE' : 'FALSE' }} -{{ false in '100' ? 'TRUE' : 'FALSE' }} -{{ true in '100' ? 'TRUE' : 'FALSE' }} - -{{ [] in [true, false] ? 'TRUE' : 'FALSE' }} -{{ [] in [true, ''] ? 'TRUE' : 'FALSE' }} -{{ [] in [true, []] ? 'TRUE' : 'FALSE' }} - -{{ resource ? 'TRUE' : 'FALSE' }} -{{ resource in 'foo'~resource ? 'TRUE' : 'FALSE' }} -{{ object in 'stdClass' ? 'TRUE' : 'FALSE' }} -{{ [] in 'Array' ? 'TRUE' : 'FALSE' }} -{{ dir_object in 'foo'~dir_object ? 'TRUE' : 'FALSE' }} - -{{ ''~resource in resource ? 'TRUE' : 'FALSE' }} -{{ 'stdClass' in object ? 'TRUE' : 'FALSE' }} -{{ 'Array' in [] ? 'TRUE' : 'FALSE' }} -{{ ''~dir_object in dir_object ? 'TRUE' : 'FALSE' }} - -{{ resource in [''~resource] ? 'TRUE' : 'FALSE' }} -{{ resource in [resource + 1 - 1] ? 'TRUE' : 'FALSE' }} -{{ dir_object in [''~dir_object] ? 'TRUE' : 'FALSE' }} - -{{ 5 in 125 ? 'TRUE' : 'FALSE' }} -{{ 5 in '125' ? 'TRUE' : 'FALSE' }} -{{ '5' in 125 ? 'TRUE' : 'FALSE' }} -{{ '5' in '125' ? 'TRUE' : 'FALSE' }} - -{{ 5.5 in 125.5 ? 'TRUE' : 'FALSE' }} -{{ 5.5 in '125.5' ? 'TRUE' : 'FALSE' }} -{{ '5.5' in 125.5 ? 'TRUE' : 'FALSE' }} ---DATA-- -return array('bar' => 'bar', 'foo' => array('bar' => 'bar'), 'dir_object' => new SplFileInfo(dirname(__FILE__)), 'object' => new stdClass(), 'resource' => opendir(dirname(__FILE__))) ---EXPECT-- -TRUE -TRUE -TRUE -TRUE -TRUE -TRUE -TRUE -TRUE -TRUE -TRUE - -TRUE -TRUE -TRUE -TRUE -TRUE - -TRUE -FALSE -FALSE -FALSE -FALSE - -TRUE -FALSE -TRUE - -TRUE -FALSE -FALSE -FALSE -FALSE - -FALSE -FALSE -FALSE -FALSE - -FALSE -FALSE -FALSE - -FALSE -TRUE -FALSE -TRUE - -FALSE -TRUE -FALSE diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in_with_objects.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in_with_objects.test deleted file mode 100644 index 8e08061bb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/in_with_objects.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -Twig supports the in operator when using objects ---TEMPLATE-- -{% if object in object_list %} -TRUE -{% endif %} ---DATA-- -$foo = new TwigTestFoo(); -$foo1 = new TwigTestFoo(); - -$foo->position = $foo1; -$foo1->position = $foo; - -return array( - 'object' => $foo, - 'object_list' => array($foo1, $foo), -); ---EXPECT-- -TRUE diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/iterable.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/iterable.test deleted file mode 100644 index ec5255013..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/iterable.test +++ /dev/null @@ -1,19 +0,0 @@ ---TEST-- -"iterable" test ---TEMPLATE-- -{{ foo is iterable ? 'ok' : 'ko' }} -{{ traversable is iterable ? 'ok' : 'ko' }} -{{ obj is iterable ? 'ok' : 'ko' }} -{{ val is iterable ? 'ok' : 'ko' }} ---DATA-- -return array( - 'foo' => array(), - 'traversable' => new ArrayIterator(array()), - 'obj' => new stdClass(), - 'val' => 'test', -); ---EXPECT-- -ok -ok -ko -ko \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/odd.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/odd.test deleted file mode 100644 index 1b8311e3d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Fixtures/tests/odd.test +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -"odd" test ---TEMPLATE-- -{{ 1 is odd ? 'ok' : 'ko' }} -{{ 2 is odd ? 'ko' : 'ok' }} ---DATA-- -return array() ---EXPECT-- -ok -ok \ No newline at end of file diff --git a/vendor/twig/twig/test/Twig/Tests/IntegrationTest.php b/vendor/twig/twig/test/Twig/Tests/IntegrationTest.php deleted file mode 100644 index 1908bcdf2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/IntegrationTest.php +++ /dev/null @@ -1,229 +0,0 @@ -position = 0; - } - - public function current() - { - return $this->array[$this->position]; - } - - public function key() - { - return 'a'; - } - - public function next() - { - ++$this->position; - } - - public function valid() - { - return isset($this->array[$this->position]); - } -} - -class TwigTestTokenParser_§ extends Twig_TokenParser -{ - public function parse(Twig_Token $token) - { - $this->parser->getStream()->expect(Twig_Token::BLOCK_END_TYPE); - - return new Twig_Node_Print(new Twig_Node_Expression_Constant('§', -1), -1); - } - - public function getTag() - { - return '§'; - } -} - -class TwigTestExtension extends Twig_Extension -{ - public function getTokenParsers() - { - return array( - new TwigTestTokenParser_§(), - ); - } - - public function getFilters() - { - return array( - new Twig_SimpleFilter('§', array($this, '§Filter')), - new Twig_SimpleFilter('escape_and_nl2br', array($this, 'escape_and_nl2br'), array('needs_environment' => true, 'is_safe' => array('html'))), - new Twig_SimpleFilter('nl2br', array($this, 'nl2br'), array('pre_escape' => 'html', 'is_safe' => array('html'))), - new Twig_SimpleFilter('escape_something', array($this, 'escape_something'), array('is_safe' => array('something'))), - new Twig_SimpleFilter('preserves_safety', array($this, 'preserves_safety'), array('preserves_safety' => array('html'))), - new Twig_SimpleFilter('*_path', array($this, 'dynamic_path')), - new Twig_SimpleFilter('*_foo_*_bar', array($this, 'dynamic_foo')), - ); - } - - public function getFunctions() - { - return array( - new Twig_SimpleFunction('§', array($this, '§Function')), - new Twig_SimpleFunction('safe_br', array($this, 'br'), array('is_safe' => array('html'))), - new Twig_SimpleFunction('unsafe_br', array($this, 'br')), - new Twig_SimpleFunction('*_path', array($this, 'dynamic_path')), - new Twig_SimpleFunction('*_foo_*_bar', array($this, 'dynamic_foo')), - ); - } - - public function getTests() - { - return array( - new Twig_SimpleTest('multi word', array($this, 'is_multi_word')), - ); - } - - public function §Filter($value) - { - return "§{$value}§"; - } - - public function §Function($value) - { - return "§{$value}§"; - } - - /** - * nl2br which also escapes, for testing escaper filters. - */ - public function escape_and_nl2br($env, $value, $sep = '
    ') - { - return $this->nl2br(twig_escape_filter($env, $value, 'html'), $sep); - } - - /** - * nl2br only, for testing filters with pre_escape. - */ - public function nl2br($value, $sep = '
    ') - { - // not secure if $value contains html tags (not only entities) - // don't use - return str_replace("\n", "$sep\n", $value); - } - - public function dynamic_path($element, $item) - { - return $element.'/'.$item; - } - - public function dynamic_foo($foo, $bar, $item) - { - return $foo.'/'.$bar.'/'.$item; - } - - public function escape_something($value) - { - return strtoupper($value); - } - - public function preserves_safety($value) - { - return strtoupper($value); - } - - public function br() - { - return '
    '; - } - - public function is_multi_word($value) - { - return false !== strpos($value, ' '); - } - - public function getName() - { - return 'integration_test'; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/LegacyFixtures/test.legacy.test b/vendor/twig/twig/test/Twig/Tests/LegacyFixtures/test.legacy.test deleted file mode 100644 index d9c1d5085..000000000 --- a/vendor/twig/twig/test/Twig/Tests/LegacyFixtures/test.legacy.test +++ /dev/null @@ -1,8 +0,0 @@ ---TEST-- -Old test classes usage ---TEMPLATE-- -{{ 'foo' is multi word ? 'yes' : 'no' }} ---DATA-- -return array() ---EXPECT-- -no diff --git a/vendor/twig/twig/test/Twig/Tests/LegacyIntegrationTest.php b/vendor/twig/twig/test/Twig/Tests/LegacyIntegrationTest.php deleted file mode 100644 index 055a61707..000000000 --- a/vendor/twig/twig/test/Twig/Tests/LegacyIntegrationTest.php +++ /dev/null @@ -1,54 +0,0 @@ - new Twig_Test_Method($this, 'is_multi_word'), - ); - } - - public function is_multi_word($value) - { - return false !== strpos($value, ' '); - } - - public function getName() - { - return 'legacy_integration_test'; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/LexerTest.php b/vendor/twig/twig/test/Twig/Tests/LexerTest.php deleted file mode 100644 index 4945d2247..000000000 --- a/vendor/twig/twig/test/Twig/Tests/LexerTest.php +++ /dev/null @@ -1,300 +0,0 @@ -getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - - $stream->expect(Twig_Token::BLOCK_START_TYPE); - $this->assertSame('§', $stream->expect(Twig_Token::NAME_TYPE)->getValue()); - } - - public function testNameLabelForFunction() - { - $template = '{{ §() }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - - $stream->expect(Twig_Token::VAR_START_TYPE); - $this->assertSame('§', $stream->expect(Twig_Token::NAME_TYPE)->getValue()); - } - - public function testBracketsNesting() - { - $template = '{{ {"a":{"b":"c"}} }}'; - - $this->assertEquals(2, $this->countToken($template, Twig_Token::PUNCTUATION_TYPE, '{')); - $this->assertEquals(2, $this->countToken($template, Twig_Token::PUNCTUATION_TYPE, '}')); - } - - protected function countToken($template, $type, $value = null) - { - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - - $count = 0; - while (!$stream->isEOF()) { - $token = $stream->next(); - if ($type === $token->getType()) { - if (null === $value || $value === $token->getValue()) { - ++$count; - } - } - } - - return $count; - } - - public function testLineDirective() - { - $template = "foo\n" - ."bar\n" - ."{% line 10 %}\n" - ."{{\n" - ."baz\n" - ."}}\n"; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - - // foo\nbar\n - $this->assertSame(1, $stream->expect(Twig_Token::TEXT_TYPE)->getLine()); - // \n (after {% line %}) - $this->assertSame(10, $stream->expect(Twig_Token::TEXT_TYPE)->getLine()); - // {{ - $this->assertSame(11, $stream->expect(Twig_Token::VAR_START_TYPE)->getLine()); - // baz - $this->assertSame(12, $stream->expect(Twig_Token::NAME_TYPE)->getLine()); - } - - public function testLineDirectiveInline() - { - $template = "foo\n" - ."bar{% line 10 %}{{\n" - ."baz\n" - ."}}\n"; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - - // foo\nbar - $this->assertSame(1, $stream->expect(Twig_Token::TEXT_TYPE)->getLine()); - // {{ - $this->assertSame(10, $stream->expect(Twig_Token::VAR_START_TYPE)->getLine()); - // baz - $this->assertSame(11, $stream->expect(Twig_Token::NAME_TYPE)->getLine()); - } - - public function testLongComments() - { - $template = '{# '.str_repeat('*', 100000).' #}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - - // should not throw an exception - } - - public function testLongVerbatim() - { - $template = '{% verbatim %}'.str_repeat('*', 100000).'{% endverbatim %}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - - // should not throw an exception - } - - public function testLongVar() - { - $template = '{{ '.str_repeat('x', 100000).' }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - - // should not throw an exception - } - - public function testLongBlock() - { - $template = '{% '.str_repeat('x', 100000).' %}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - - // should not throw an exception - } - - public function testBigNumbers() - { - $template = '{{ 922337203685477580700 }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->next(); - $node = $stream->next(); - $this->assertEquals('922337203685477580700', $node->getValue()); - } - - public function testStringWithEscapedDelimiter() - { - $tests = array( - "{{ 'foo \' bar' }}" => 'foo \' bar', - '{{ "foo \" bar" }}' => 'foo " bar', - ); - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - foreach ($tests as $template => $expected) { - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, $expected); - } - } - - public function testStringWithInterpolation() - { - $template = 'foo {{ "bar #{ baz + 1 }" }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::TEXT_TYPE, 'foo '); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'bar '); - $stream->expect(Twig_Token::INTERPOLATION_START_TYPE); - $stream->expect(Twig_Token::NAME_TYPE, 'baz'); - $stream->expect(Twig_Token::OPERATOR_TYPE, '+'); - $stream->expect(Twig_Token::NUMBER_TYPE, '1'); - $stream->expect(Twig_Token::INTERPOLATION_END_TYPE); - $stream->expect(Twig_Token::VAR_END_TYPE); - } - - public function testStringWithEscapedInterpolation() - { - $template = '{{ "bar \#{baz+1}" }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'bar #{baz+1}'); - $stream->expect(Twig_Token::VAR_END_TYPE); - } - - public function testStringWithHash() - { - $template = '{{ "bar # baz" }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'bar # baz'); - $stream->expect(Twig_Token::VAR_END_TYPE); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unclosed """ - */ - public function testStringWithUnterminatedInterpolation() - { - $template = '{{ "bar #{x" }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - } - - public function testStringWithNestedInterpolations() - { - $template = '{{ "bar #{ "foo#{bar}" }" }}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'bar '); - $stream->expect(Twig_Token::INTERPOLATION_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'foo'); - $stream->expect(Twig_Token::INTERPOLATION_START_TYPE); - $stream->expect(Twig_Token::NAME_TYPE, 'bar'); - $stream->expect(Twig_Token::INTERPOLATION_END_TYPE); - $stream->expect(Twig_Token::INTERPOLATION_END_TYPE); - $stream->expect(Twig_Token::VAR_END_TYPE); - } - - public function testStringWithNestedInterpolationsInBlock() - { - $template = '{% foo "bar #{ "foo#{bar}" }" %}'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::BLOCK_START_TYPE); - $stream->expect(Twig_Token::NAME_TYPE, 'foo'); - $stream->expect(Twig_Token::STRING_TYPE, 'bar '); - $stream->expect(Twig_Token::INTERPOLATION_START_TYPE); - $stream->expect(Twig_Token::STRING_TYPE, 'foo'); - $stream->expect(Twig_Token::INTERPOLATION_START_TYPE); - $stream->expect(Twig_Token::NAME_TYPE, 'bar'); - $stream->expect(Twig_Token::INTERPOLATION_END_TYPE); - $stream->expect(Twig_Token::INTERPOLATION_END_TYPE); - $stream->expect(Twig_Token::BLOCK_END_TYPE); - } - - public function testOperatorEndingWithALetterAtTheEndOfALine() - { - $template = "{{ 1 and\n0}}"; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $stream = $lexer->tokenize($template); - $stream->expect(Twig_Token::VAR_START_TYPE); - $stream->expect(Twig_Token::NUMBER_TYPE, 1); - $stream->expect(Twig_Token::OPERATOR_TYPE, 'and'); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unclosed "variable" at line 3 - */ - public function testUnterminatedVariable() - { - $template = ' - -{{ - -bar - - -'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unclosed "block" at line 3 - */ - public function testUnterminatedBlock() - { - $template = ' - -{% - -bar - - -'; - - $lexer = new Twig_Lexer(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $lexer->tokenize($template); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/ArrayTest.php b/vendor/twig/twig/test/Twig/Tests/Loader/ArrayTest.php deleted file mode 100644 index 1369a6bd0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/ArrayTest.php +++ /dev/null @@ -1,97 +0,0 @@ - 'bar')); - - $this->assertEquals('bar', $loader->getSource('foo')); - } - - /** - * @expectedException Twig_Error_Loader - */ - public function testGetSourceWhenTemplateDoesNotExist() - { - $loader = new Twig_Loader_Array(array()); - - $loader->getSource('foo'); - } - - public function testGetCacheKey() - { - $loader = new Twig_Loader_Array(array('foo' => 'bar')); - - $this->assertEquals('bar', $loader->getCacheKey('foo')); - } - - /** - * @expectedException Twig_Error_Loader - */ - public function testGetCacheKeyWhenTemplateDoesNotExist() - { - $loader = new Twig_Loader_Array(array()); - - $loader->getCacheKey('foo'); - } - - public function testSetTemplate() - { - $loader = new Twig_Loader_Array(array()); - $loader->setTemplate('foo', 'bar'); - - $this->assertEquals('bar', $loader->getSource('foo')); - } - - public function testIsFresh() - { - $loader = new Twig_Loader_Array(array('foo' => 'bar')); - $this->assertTrue($loader->isFresh('foo', time())); - } - - /** - * @expectedException Twig_Error_Loader - */ - public function testIsFreshWhenTemplateDoesNotExist() - { - $loader = new Twig_Loader_Array(array()); - - $loader->isFresh('foo', time()); - } - - public function testTemplateReference() - { - $name = new Twig_Test_Loader_TemplateReference('foo'); - $loader = new Twig_Loader_Array(array('foo' => 'bar')); - - $loader->getCacheKey($name); - $loader->getSource($name); - $loader->isFresh($name, time()); - $loader->setTemplate($name, 'foobar'); - } -} - -class Twig_Test_Loader_TemplateReference -{ - private $name; - - public function __construct($name) - { - $this->name = $name; - } - - public function __toString() - { - return $this->name; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php b/vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php deleted file mode 100644 index 4fe0db948..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php +++ /dev/null @@ -1,79 +0,0 @@ - 'bar')), - new Twig_Loader_Array(array('foo' => 'foobar', 'bar' => 'foo')), - )); - - $this->assertEquals('bar', $loader->getSource('foo')); - $this->assertEquals('foo', $loader->getSource('bar')); - } - - /** - * @expectedException Twig_Error_Loader - */ - public function testGetSourceWhenTemplateDoesNotExist() - { - $loader = new Twig_Loader_Chain(array()); - - $loader->getSource('foo'); - } - - public function testGetCacheKey() - { - $loader = new Twig_Loader_Chain(array( - new Twig_Loader_Array(array('foo' => 'bar')), - new Twig_Loader_Array(array('foo' => 'foobar', 'bar' => 'foo')), - )); - - $this->assertEquals('bar', $loader->getCacheKey('foo')); - $this->assertEquals('foo', $loader->getCacheKey('bar')); - } - - /** - * @expectedException Twig_Error_Loader - */ - public function testGetCacheKeyWhenTemplateDoesNotExist() - { - $loader = new Twig_Loader_Chain(array()); - - $loader->getCacheKey('foo'); - } - - public function testAddLoader() - { - $loader = new Twig_Loader_Chain(); - $loader->addLoader(new Twig_Loader_Array(array('foo' => 'bar'))); - - $this->assertEquals('bar', $loader->getSource('foo')); - } - - public function testExists() - { - $loader1 = $this->getMock('Twig_Loader_Array', array('exists', 'getSource'), array(), '', false); - $loader1->expects($this->once())->method('exists')->will($this->returnValue(false)); - $loader1->expects($this->never())->method('getSource'); - - $loader2 = $this->getMock('Twig_LoaderInterface'); - $loader2->expects($this->once())->method('getSource')->will($this->returnValue('content')); - - $loader = new Twig_Loader_Chain(); - $loader->addLoader($loader1); - $loader->addLoader($loader2); - - $this->assertTrue($loader->exists('foo')); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/FilesystemTest.php b/vendor/twig/twig/test/Twig/Tests/Loader/FilesystemTest.php deleted file mode 100644 index e07f374a3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/FilesystemTest.php +++ /dev/null @@ -1,175 +0,0 @@ -getCacheKey($template); - $this->fail(); - } catch (Twig_Error_Loader $e) { - $this->assertNotContains('Unable to find template', $e->getMessage()); - } - } - - public function getSecurityTests() - { - return array( - array("AutoloaderTest\0.php"), - array('..\\AutoloaderTest.php'), - array('..\\\\\\AutoloaderTest.php'), - array('../AutoloaderTest.php'), - array('..////AutoloaderTest.php'), - array('./../AutoloaderTest.php'), - array('.\\..\\AutoloaderTest.php'), - array('././././././../AutoloaderTest.php'), - array('.\\./.\\./.\\./../AutoloaderTest.php'), - array('foo/../../AutoloaderTest.php'), - array('foo\\..\\..\\AutoloaderTest.php'), - array('foo/../bar/../../AutoloaderTest.php'), - array('foo/bar/../../../AutoloaderTest.php'), - array('filters/../../AutoloaderTest.php'), - array('filters//..//..//AutoloaderTest.php'), - array('filters\\..\\..\\AutoloaderTest.php'), - array('filters\\\\..\\\\..\\\\AutoloaderTest.php'), - array('filters\\//../\\/\\..\\AutoloaderTest.php'), - array('/../AutoloaderTest.php'), - ); - } - - public function testPaths() - { - $basePath = dirname(__FILE__).'/Fixtures'; - - $loader = new Twig_Loader_Filesystem(array($basePath.'/normal', $basePath.'/normal_bis')); - $loader->setPaths(array($basePath.'/named', $basePath.'/named_bis'), 'named'); - $loader->addPath($basePath.'/named_ter', 'named'); - $loader->addPath($basePath.'/normal_ter'); - $loader->prependPath($basePath.'/normal_final'); - $loader->prependPath($basePath.'/named/../named_quater', 'named'); - $loader->prependPath($basePath.'/named_final', 'named'); - - $this->assertEquals(array( - $basePath.'/normal_final', - $basePath.'/normal', - $basePath.'/normal_bis', - $basePath.'/normal_ter', - ), $loader->getPaths()); - $this->assertEquals(array( - $basePath.'/named_final', - $basePath.'/named/../named_quater', - $basePath.'/named', - $basePath.'/named_bis', - $basePath.'/named_ter', - ), $loader->getPaths('named')); - - $this->assertEquals( - realpath($basePath.'/named_quater/named_absolute.html'), - realpath($loader->getCacheKey('@named/named_absolute.html')) - ); - $this->assertEquals("path (final)\n", $loader->getSource('index.html')); - $this->assertEquals("path (final)\n", $loader->getSource('@__main__/index.html')); - $this->assertEquals("named path (final)\n", $loader->getSource('@named/index.html')); - } - - public function testEmptyConstructor() - { - $loader = new Twig_Loader_Filesystem(); - $this->assertEquals(array(), $loader->getPaths()); - } - - public function testGetNamespaces() - { - $loader = new Twig_Loader_Filesystem(sys_get_temp_dir()); - $this->assertEquals(array(Twig_Loader_Filesystem::MAIN_NAMESPACE), $loader->getNamespaces()); - - $loader->addPath(sys_get_temp_dir(), 'named'); - $this->assertEquals(array(Twig_Loader_Filesystem::MAIN_NAMESPACE, 'named'), $loader->getNamespaces()); - } - - public function testFindTemplateExceptionNamespace() - { - $basePath = dirname(__FILE__).'/Fixtures'; - - $loader = new Twig_Loader_Filesystem(array($basePath.'/normal')); - $loader->addPath($basePath.'/named', 'named'); - - try { - $loader->getSource('@named/nowhere.html'); - } catch (Exception $e) { - $this->assertInstanceof('Twig_Error_Loader', $e); - $this->assertContains('Unable to find template "@named/nowhere.html"', $e->getMessage()); - } - } - - public function testFindTemplateWithCache() - { - $basePath = dirname(__FILE__).'/Fixtures'; - - $loader = new Twig_Loader_Filesystem(array($basePath.'/normal')); - $loader->addPath($basePath.'/named', 'named'); - - // prime the cache for index.html in the named namespace - $namedSource = $loader->getSource('@named/index.html'); - $this->assertEquals("named path\n", $namedSource); - - // get index.html from the main namespace - $this->assertEquals("path\n", $loader->getSource('index.html')); - } - - public function testLoadTemplateAndRenderBlockWithCache() - { - $loader = new Twig_Loader_Filesystem(array()); - $loader->addPath(dirname(__FILE__).'/Fixtures/themes/theme2'); - $loader->addPath(dirname(__FILE__).'/Fixtures/themes/theme1'); - $loader->addPath(dirname(__FILE__).'/Fixtures/themes/theme1', 'default_theme'); - - $twig = new Twig_Environment($loader); - - $template = $twig->loadTemplate('blocks.html.twig'); - $this->assertSame('block from theme 1', $template->renderBlock('b1', array())); - - $template = $twig->loadTemplate('blocks.html.twig'); - $this->assertSame('block from theme 2', $template->renderBlock('b2', array())); - } - - public function getArrayInheritanceTests() - { - return array( - 'valid array inheritance' => array('array_inheritance_valid_parent.html.twig'), - 'array inheritance with null first template' => array('array_inheritance_null_parent.html.twig'), - 'array inheritance with empty first template' => array('array_inheritance_empty_parent.html.twig'), - 'array inheritance with non-existent first template' => array('array_inheritance_nonexistent_parent.html.twig'), - ); - } - - /** - * @dataProvider getArrayInheritanceTests - * - * @param $templateName string Template name with array inheritance - */ - public function testArrayInheritance($templateName) - { - $loader = new Twig_Loader_Filesystem(array()); - $loader->addPath(dirname(__FILE__).'/Fixtures/inheritance'); - - $twig = new Twig_Environment($loader); - - $template = $twig->loadTemplate($templateName); - $this->assertSame('VALID Child', $template->renderBlock('body', array())); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_empty_parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_empty_parent.html.twig deleted file mode 100644 index 6977ebf66..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_empty_parent.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% extends ['','parent.html.twig'] %} - -{% block body %}{{ parent() }} Child{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_nonexistent_parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_nonexistent_parent.html.twig deleted file mode 100644 index 5b50a8b21..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_nonexistent_parent.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% extends ['nonexistent.html.twig','parent.html.twig'] %} - -{% block body %}{{ parent() }} Child{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_null_parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_null_parent.html.twig deleted file mode 100644 index a16b3aded..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_null_parent.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% extends [null,'parent.html.twig'] %} - -{% block body %}{{ parent() }} Child{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_valid_parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_valid_parent.html.twig deleted file mode 100644 index 4940dad41..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/array_inheritance_valid_parent.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% extends ['parent.html.twig','spare_parent.html.twig'] %} - -{% block body %}{{ parent() }} Child{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/parent.html.twig deleted file mode 100644 index d594c0ed4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/parent.html.twig +++ /dev/null @@ -1 +0,0 @@ -{% block body %}VALID{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/spare_parent.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/spare_parent.html.twig deleted file mode 100644 index 70b7360a2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/inheritance/spare_parent.html.twig +++ /dev/null @@ -1 +0,0 @@ -{% block body %}SPARE PARENT{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named/index.html deleted file mode 100644 index 9e5449c7c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named/index.html +++ /dev/null @@ -1 +0,0 @@ -named path diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_bis/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_bis/index.html deleted file mode 100644 index d3a272b19..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_bis/index.html +++ /dev/null @@ -1 +0,0 @@ -named path (bis) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_final/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_final/index.html deleted file mode 100644 index 9f05d1507..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_final/index.html +++ /dev/null @@ -1 +0,0 @@ -named path (final) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_quater/named_absolute.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_quater/named_absolute.html deleted file mode 100644 index b1fb5f5d7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_quater/named_absolute.html +++ /dev/null @@ -1 +0,0 @@ -named path (quater) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_ter/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_ter/index.html deleted file mode 100644 index 24fb68ad2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/named_ter/index.html +++ /dev/null @@ -1 +0,0 @@ -named path (ter) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal/index.html deleted file mode 100644 index e7a8fd4d0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal/index.html +++ /dev/null @@ -1 +0,0 @@ -path diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_bis/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_bis/index.html deleted file mode 100644 index bfa916049..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_bis/index.html +++ /dev/null @@ -1 +0,0 @@ -path (bis) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_final/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_final/index.html deleted file mode 100644 index 73a089bbd..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_final/index.html +++ /dev/null @@ -1 +0,0 @@ -path (final) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_ter/index.html b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_ter/index.html deleted file mode 100644 index b7ad97d8f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/normal_ter/index.html +++ /dev/null @@ -1 +0,0 @@ -path (ter) diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme1/blocks.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme1/blocks.html.twig deleted file mode 100644 index dd0cbc2e7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme1/blocks.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% block b1 %}block from theme 1{% endblock %} - -{% block b2 %}block from theme 1{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme2/blocks.html.twig b/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme2/blocks.html.twig deleted file mode 100644 index 07cf9db0d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Loader/Fixtures/themes/theme2/blocks.html.twig +++ /dev/null @@ -1,3 +0,0 @@ -{% use '@default_theme/blocks.html.twig' %} - -{% block b2 %}block from theme 2{% endblock %} diff --git a/vendor/twig/twig/test/Twig/Tests/NativeExtensionTest.php b/vendor/twig/twig/test/Twig/Tests/NativeExtensionTest.php deleted file mode 100644 index 942aff9e3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/NativeExtensionTest.php +++ /dev/null @@ -1,33 +0,0 @@ -markTestSkipped('Skip under HHVM as the behavior is not the same as plain PHP (which is an edge case anyway)'); - } - - $twig = new Twig_Environment(new Twig_Loader_Array(array('index' => '{{ d1.date }}{{ d2.date }}')), array( - 'debug' => true, - 'cache' => false, - 'autoescape' => false, - )); - - $d1 = new DateTime(); - $d2 = new DateTime(); - $output = $twig->render('index', compact('d1', 'd2')); - - // If it fails, PHP will crash. - $this->assertEquals($output, $d1->date.$d2->date); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/AutoEscapeTest.php b/vendor/twig/twig/test/Twig/Tests/Node/AutoEscapeTest.php deleted file mode 100644 index 25d16023f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/AutoEscapeTest.php +++ /dev/null @@ -1,32 +0,0 @@ -assertEquals($body, $node->getNode('body')); - $this->assertTrue($node->getAttribute('value')); - } - - public function getTests() - { - $body = new Twig_Node(array(new Twig_Node_Text('foo', 1))); - $node = new Twig_Node_AutoEscape(true, $body, 1); - - return array( - array($node, "// line 1\necho \"foo\";"), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/BlockReferenceTest.php b/vendor/twig/twig/test/Twig/Tests/Node/BlockReferenceTest.php deleted file mode 100644 index 84dac9bfa..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/BlockReferenceTest.php +++ /dev/null @@ -1,31 +0,0 @@ -assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - return array( - array(new Twig_Node_BlockReference('foo', 1), <<displayBlock('foo', \$context, \$blocks); -EOF - ), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/BlockTest.php b/vendor/twig/twig/test/Twig/Tests/Node/BlockTest.php deleted file mode 100644 index e7246dcc3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/BlockTest.php +++ /dev/null @@ -1,39 +0,0 @@ -assertEquals($body, $node->getNode('body')); - $this->assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - $body = new Twig_Node_Text('foo', 1); - $node = new Twig_Node_Block('foo', $body, 1); - - return array( - array($node, <<assertEquals($expr, $node->getNode('expr')); - } - - public function getTests() - { - $tests = array(); - - $expr = new Twig_Node_Expression_Constant('foo', 1); - $node = new Twig_Node_Do($expr, 1); - $tests[] = array($node, "// line 1\n\"foo\";"); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ArrayTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/ArrayTest.php deleted file mode 100644 index 4f83ab176..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ArrayTest.php +++ /dev/null @@ -1,37 +0,0 @@ -assertEquals($foo, $node->getNode(1)); - } - - public function getTests() - { - $elements = array( - new Twig_Node_Expression_Constant('foo', 1), - new Twig_Node_Expression_Constant('bar', 1), - - new Twig_Node_Expression_Constant('bar', 1), - new Twig_Node_Expression_Constant('foo', 1), - ); - $node = new Twig_Node_Expression_Array($elements, 1); - - return array( - array($node, 'array("foo" => "bar", "bar" => "foo")'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/AssignNameTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/AssignNameTest.php deleted file mode 100644 index bf365de49..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/AssignNameTest.php +++ /dev/null @@ -1,29 +0,0 @@ -assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - $node = new Twig_Node_Expression_AssignName('foo', 1); - - return array( - array($node, '$context["foo"]'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AddTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AddTest.php deleted file mode 100644 index 02310a1b0..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AddTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Add($left, $right, 1); - - return array( - array($node, '(1 + 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AndTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AndTest.php deleted file mode 100644 index 2df3c8e45..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/AndTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_And($left, $right, 1); - - return array( - array($node, '(1 && 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ConcatTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ConcatTest.php deleted file mode 100644 index 759e48289..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ConcatTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Concat($left, $right, 1); - - return array( - array($node, '(1 . 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/DivTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/DivTest.php deleted file mode 100644 index 0e54b10a3..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/DivTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Div($left, $right, 1); - - return array( - array($node, '(1 / 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/FloorDivTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/FloorDivTest.php deleted file mode 100644 index 602888fd5..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/FloorDivTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_FloorDiv($left, $right, 1); - - return array( - array($node, 'intval(floor((1 / 2)))'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ModTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ModTest.php deleted file mode 100644 index 4c663c787..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/ModTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Mod($left, $right, 1); - - return array( - array($node, '(1 % 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/MulTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/MulTest.php deleted file mode 100644 index e92c95e64..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/MulTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Mul($left, $right, 1); - - return array( - array($node, '(1 * 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/OrTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/OrTest.php deleted file mode 100644 index ec37c83eb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/OrTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Or($left, $right, 1); - - return array( - array($node, '(1 || 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/SubTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/SubTest.php deleted file mode 100644 index 061cb270f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/SubTest.php +++ /dev/null @@ -1,34 +0,0 @@ -assertEquals($left, $node->getNode('left')); - $this->assertEquals($right, $node->getNode('right')); - } - - public function getTests() - { - $left = new Twig_Node_Expression_Constant(1, 1); - $right = new Twig_Node_Expression_Constant(2, 1); - $node = new Twig_Node_Expression_Binary_Sub($left, $right, 1); - - return array( - array($node, '(1 - 2)'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/CallTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/CallTest.php deleted file mode 100644 index 43afcd292..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/CallTest.php +++ /dev/null @@ -1,116 +0,0 @@ - 'function', 'name' => 'date')); - $this->assertEquals(array('U', null), $node->getArguments('date', array('format' => 'U', 'timestamp' => null))); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Positional arguments cannot be used after named arguments for function "date". - */ - public function testGetArgumentsWhenPositionalArgumentsAfterNamedArguments() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'date')); - $node->getArguments('date', array('timestamp' => 123456, 'Y-m-d')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Argument "format" is defined twice for function "date". - */ - public function testGetArgumentsWhenArgumentIsDefinedTwice() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'date')); - $node->getArguments('date', array('Y-m-d', 'format' => 'U')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unknown argument "unknown" for function "date(format, timestamp)". - */ - public function testGetArgumentsWithWrongNamedArgumentName() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'date')); - $node->getArguments('date', array('Y-m-d', 'timestamp' => null, 'unknown' => '')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unknown arguments "unknown1", "unknown2" for function "date(format, timestamp)". - */ - public function testGetArgumentsWithWrongNamedArgumentNames() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'date')); - $node->getArguments('date', array('Y-m-d', 'timestamp' => null, 'unknown1' => '', 'unknown2' => '')); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Argument "case_sensitivity" could not be assigned for function "substr_compare(main_str, str, offset, length, case_sensitivity)" because it is mapped to an internal PHP function which cannot determine default value for optional argument "length". - */ - public function testResolveArgumentsWithMissingValueForOptionalArgument() - { - if (defined('HHVM_VERSION')) { - $this->markTestSkipped('Skip under HHVM as the behavior is not the same as plain PHP (which is an edge case anyway)'); - } - - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'substr_compare')); - $node->getArguments('substr_compare', array('abcd', 'bc', 'offset' => 1, 'case_sensitivity' => true)); - } - - public function testResolveArgumentsOnlyNecessaryArgumentsForCustomFunction() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'custom_function')); - - $this->assertEquals(array('arg1'), $node->getArguments(array($this, 'customFunction'), array('arg1' => 'arg1'))); - } - - public function testGetArgumentsForStaticMethod() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'custom_static_function')); - $this->assertEquals(array('arg1'), $node->getArguments(__CLASS__.'::customStaticFunction', array('arg1' => 'arg1'))); - } - - /** - * @expectedException LogicException - * @expectedExceptionMessage The last parameter of "Twig_Tests_Node_Expression_CallTest::customFunctionWithArbitraryArguments" for function "foo" must be an array with default value, eg. "array $arg = array()". - */ - public function testResolveArgumentsWithMissingParameterForArbitraryArguments() - { - $node = new Twig_Tests_Node_Expression_Call(array(), array('type' => 'function', 'name' => 'foo', 'is_variadic' => true)); - $node->getArguments(array($this, 'customFunctionWithArbitraryArguments'), array()); - } - - public static function customStaticFunction($arg1, $arg2 = 'default', $arg3 = array()) - { - } - - public function customFunction($arg1, $arg2 = 'default', $arg3 = array()) - { - } - - public function customFunctionWithArbitraryArguments() - { - } -} - -class Twig_Tests_Node_Expression_Call extends Twig_Node_Expression_Call -{ - public function getArguments($callable, $arguments) - { - return parent::getArguments($callable, $arguments); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConditionalTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConditionalTest.php deleted file mode 100644 index a3e8badff..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConditionalTest.php +++ /dev/null @@ -1,38 +0,0 @@ -assertEquals($expr1, $node->getNode('expr1')); - $this->assertEquals($expr2, $node->getNode('expr2')); - $this->assertEquals($expr3, $node->getNode('expr3')); - } - - public function getTests() - { - $tests = array(); - - $expr1 = new Twig_Node_Expression_Constant(1, 1); - $expr2 = new Twig_Node_Expression_Constant(2, 1); - $expr3 = new Twig_Node_Expression_Constant(3, 1); - $node = new Twig_Node_Expression_Conditional($expr1, $expr2, $expr3, 1); - $tests[] = array($node, '((1) ? (2) : (3))'); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConstantTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConstantTest.php deleted file mode 100644 index 2ff931822..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ConstantTest.php +++ /dev/null @@ -1,30 +0,0 @@ -assertEquals('foo', $node->getAttribute('value')); - } - - public function getTests() - { - $tests = array(); - - $node = new Twig_Node_Expression_Constant('foo', 1); - $tests[] = array($node, '"foo"'); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/FilterTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/FilterTest.php deleted file mode 100644 index d5ffb244d..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/FilterTest.php +++ /dev/null @@ -1,154 +0,0 @@ -assertEquals($expr, $node->getNode('node')); - $this->assertEquals($name, $node->getNode('filter')); - $this->assertEquals($args, $node->getNode('arguments')); - } - - public function getTests() - { - $environment = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $environment->addFilter(new Twig_SimpleFilter('bar', 'bar', array('needs_environment' => true))); - $environment->addFilter(new Twig_SimpleFilter('barbar', 'twig_tests_filter_barbar', array('needs_context' => true, 'is_variadic' => true))); - - $tests = array(); - - $expr = new Twig_Node_Expression_Constant('foo', 1); - $node = $this->createFilter($expr, 'upper'); - $node = $this->createFilter($node, 'number_format', array(new Twig_Node_Expression_Constant(2, 1), new Twig_Node_Expression_Constant('.', 1), new Twig_Node_Expression_Constant(',', 1))); - - if (function_exists('mb_get_info')) { - $tests[] = array($node, 'twig_number_format_filter($this->env, twig_upper_filter($this->env, "foo"), 2, ".", ",")'); - } else { - $tests[] = array($node, 'twig_number_format_filter($this->env, strtoupper("foo"), 2, ".", ",")'); - } - - // named arguments - $date = new Twig_Node_Expression_Constant(0, 1); - $node = $this->createFilter($date, 'date', array( - 'timezone' => new Twig_Node_Expression_Constant('America/Chicago', 1), - 'format' => new Twig_Node_Expression_Constant('d/m/Y H:i:s P', 1), - )); - $tests[] = array($node, 'twig_date_format_filter($this->env, 0, "d/m/Y H:i:s P", "America/Chicago")'); - - // skip an optional argument - $date = new Twig_Node_Expression_Constant(0, 1); - $node = $this->createFilter($date, 'date', array( - 'timezone' => new Twig_Node_Expression_Constant('America/Chicago', 1), - )); - $tests[] = array($node, 'twig_date_format_filter($this->env, 0, null, "America/Chicago")'); - - // underscores vs camelCase for named arguments - $string = new Twig_Node_Expression_Constant('abc', 1); - $node = $this->createFilter($string, 'reverse', array( - 'preserve_keys' => new Twig_Node_Expression_Constant(true, 1), - )); - $tests[] = array($node, 'twig_reverse_filter($this->env, "abc", true)'); - $node = $this->createFilter($string, 'reverse', array( - 'preserveKeys' => new Twig_Node_Expression_Constant(true, 1), - )); - $tests[] = array($node, 'twig_reverse_filter($this->env, "abc", true)'); - - // filter as an anonymous function - if (PHP_VERSION_ID >= 50300) { - $node = $this->createFilter(new Twig_Node_Expression_Constant('foo', 1), 'anonymous'); - $tests[] = array($node, 'call_user_func_array($this->env->getFilter(\'anonymous\')->getCallable(), array("foo"))'); - } - - // needs environment - $node = $this->createFilter($string, 'bar'); - $tests[] = array($node, 'bar($this->env, "abc")', $environment); - - $node = $this->createFilter($string, 'bar', array(new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'bar($this->env, "abc", "bar")', $environment); - - // arbitrary named arguments - $node = $this->createFilter($string, 'barbar'); - $tests[] = array($node, 'twig_tests_filter_barbar($context, "abc")', $environment); - - $node = $this->createFilter($string, 'barbar', array('foo' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_filter_barbar($context, "abc", null, null, array("foo" => "bar"))', $environment); - - $node = $this->createFilter($string, 'barbar', array('arg2' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_filter_barbar($context, "abc", null, "bar")', $environment); - - $node = $this->createFilter($string, 'barbar', array( - new Twig_Node_Expression_Constant('1', 1), - new Twig_Node_Expression_Constant('2', 1), - new Twig_Node_Expression_Constant('3', 1), - 'foo' => new Twig_Node_Expression_Constant('bar', 1), - )); - $tests[] = array($node, 'twig_tests_filter_barbar($context, "abc", "1", "2", array(0 => "3", "foo" => "bar"))', $environment); - - return $tests; - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unknown argument "foobar" for filter "date(format, timezone)" at line 1. - */ - public function testCompileWithWrongNamedArgumentName() - { - $date = new Twig_Node_Expression_Constant(0, 1); - $node = $this->createFilter($date, 'date', array( - 'foobar' => new Twig_Node_Expression_Constant('America/Chicago', 1), - )); - - $compiler = $this->getCompiler(); - $compiler->compile($node); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Value for argument "from" is required for filter "replace". - */ - public function testCompileWithMissingNamedArgument() - { - $value = new Twig_Node_Expression_Constant(0, 1); - $node = $this->createFilter($value, 'replace', array( - 'to' => new Twig_Node_Expression_Constant('foo', 1), - )); - - $compiler = $this->getCompiler(); - $compiler->compile($node); - } - - protected function createFilter($node, $name, array $arguments = array()) - { - $name = new Twig_Node_Expression_Constant($name, 1); - $arguments = new Twig_Node($arguments); - - return new Twig_Node_Expression_Filter($node, $name, $arguments, 1); - } - - protected function getEnvironment() - { - if (PHP_VERSION_ID >= 50300) { - return include 'PHP53/FilterInclude.php'; - } - - return parent::getEnvironment(); - } -} - -function twig_tests_filter_barbar($context, $string, $arg1 = null, $arg2 = null, array $args = array()) -{ -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/FunctionTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/FunctionTest.php deleted file mode 100644 index de2e0f8ee..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/FunctionTest.php +++ /dev/null @@ -1,110 +0,0 @@ -assertEquals($name, $node->getAttribute('name')); - $this->assertEquals($args, $node->getNode('arguments')); - } - - public function getTests() - { - $environment = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $environment->addFunction(new Twig_SimpleFunction('foo', 'foo', array())); - $environment->addFunction(new Twig_SimpleFunction('bar', 'bar', array('needs_environment' => true))); - $environment->addFunction(new Twig_SimpleFunction('foofoo', 'foofoo', array('needs_context' => true))); - $environment->addFunction(new Twig_SimpleFunction('foobar', 'foobar', array('needs_environment' => true, 'needs_context' => true))); - $environment->addFunction(new Twig_SimpleFunction('barbar', 'twig_tests_function_barbar', array('is_variadic' => true))); - - $tests = array(); - - $node = $this->createFunction('foo'); - $tests[] = array($node, 'foo()', $environment); - - $node = $this->createFunction('foo', array(new Twig_Node_Expression_Constant('bar', 1), new Twig_Node_Expression_Constant('foobar', 1))); - $tests[] = array($node, 'foo("bar", "foobar")', $environment); - - $node = $this->createFunction('bar'); - $tests[] = array($node, 'bar($this->env)', $environment); - - $node = $this->createFunction('bar', array(new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'bar($this->env, "bar")', $environment); - - $node = $this->createFunction('foofoo'); - $tests[] = array($node, 'foofoo($context)', $environment); - - $node = $this->createFunction('foofoo', array(new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'foofoo($context, "bar")', $environment); - - $node = $this->createFunction('foobar'); - $tests[] = array($node, 'foobar($this->env, $context)', $environment); - - $node = $this->createFunction('foobar', array(new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'foobar($this->env, $context, "bar")', $environment); - - // named arguments - $node = $this->createFunction('date', array( - 'timezone' => new Twig_Node_Expression_Constant('America/Chicago', 1), - 'date' => new Twig_Node_Expression_Constant(0, 1), - )); - $tests[] = array($node, 'twig_date_converter($this->env, 0, "America/Chicago")'); - - // arbitrary named arguments - $node = $this->createFunction('barbar'); - $tests[] = array($node, 'twig_tests_function_barbar()', $environment); - - $node = $this->createFunction('barbar', array('foo' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_function_barbar(null, null, array("foo" => "bar"))', $environment); - - $node = $this->createFunction('barbar', array('arg2' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_function_barbar(null, "bar")', $environment); - - $node = $this->createFunction('barbar', array( - new Twig_Node_Expression_Constant('1', 1), - new Twig_Node_Expression_Constant('2', 1), - new Twig_Node_Expression_Constant('3', 1), - 'foo' => new Twig_Node_Expression_Constant('bar', 1), - )); - $tests[] = array($node, 'twig_tests_function_barbar("1", "2", array(0 => "3", "foo" => "bar"))', $environment); - - // function as an anonymous function - if (PHP_VERSION_ID >= 50300) { - $node = $this->createFunction('anonymous', array(new Twig_Node_Expression_Constant('foo', 1))); - $tests[] = array($node, 'call_user_func_array($this->env->getFunction(\'anonymous\')->getCallable(), array("foo"))'); - } - - return $tests; - } - - protected function createFunction($name, array $arguments = array()) - { - return new Twig_Node_Expression_Function($name, new Twig_Node($arguments), 1); - } - - protected function getEnvironment() - { - if (PHP_VERSION_ID >= 50300) { - return include 'PHP53/FunctionInclude.php'; - } - - return parent::getEnvironment(); - } -} - -function twig_tests_function_barbar($arg1 = null, $arg2 = null, array $args = array()) -{ -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/GetAttrTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/GetAttrTest.php deleted file mode 100644 index 2764478c4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/GetAttrTest.php +++ /dev/null @@ -1,50 +0,0 @@ -addElement(new Twig_Node_Expression_Name('foo', 1)); - $args->addElement(new Twig_Node_Expression_Constant('bar', 1)); - $node = new Twig_Node_Expression_GetAttr($expr, $attr, $args, Twig_Template::ARRAY_CALL, 1); - - $this->assertEquals($expr, $node->getNode('node')); - $this->assertEquals($attr, $node->getNode('attribute')); - $this->assertEquals($args, $node->getNode('arguments')); - $this->assertEquals(Twig_Template::ARRAY_CALL, $node->getAttribute('type')); - } - - public function getTests() - { - $tests = array(); - - $expr = new Twig_Node_Expression_Name('foo', 1); - $attr = new Twig_Node_Expression_Constant('bar', 1); - $args = new Twig_Node_Expression_Array(array(), 1); - $node = new Twig_Node_Expression_GetAttr($expr, $attr, $args, Twig_Template::ANY_CALL, 1); - $tests[] = array($node, sprintf('%s%s, "bar", array())', $this->getAttributeGetter(), $this->getVariableGetter('foo', 1))); - - $node = new Twig_Node_Expression_GetAttr($expr, $attr, $args, Twig_Template::ARRAY_CALL, 1); - $tests[] = array($node, sprintf('%s%s, "bar", array(), "array")', $this->getAttributeGetter(), $this->getVariableGetter('foo', 1))); - - $args = new Twig_Node_Expression_Array(array(), 1); - $args->addElement(new Twig_Node_Expression_Name('foo', 1)); - $args->addElement(new Twig_Node_Expression_Constant('bar', 1)); - $node = new Twig_Node_Expression_GetAttr($expr, $attr, $args, Twig_Template::METHOD_CALL, 1); - $tests[] = array($node, sprintf('%s%s, "bar", array(0 => %s, 1 => "bar"), "method")', $this->getAttributeGetter(), $this->getVariableGetter('foo', 1), $this->getVariableGetter('foo'))); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/NameTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/NameTest.php deleted file mode 100644 index 8cbb2f764..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/NameTest.php +++ /dev/null @@ -1,35 +0,0 @@ -assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - $node = new Twig_Node_Expression_Name('foo', 1); - $context = new Twig_Node_Expression_Name('_context', 1); - - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('strict_variables' => true)); - $env1 = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('strict_variables' => false)); - - return array( - array($node, "// line 1\n".(PHP_VERSION_ID >= 50400 ? '(isset($context["foo"]) ? $context["foo"] : $this->getContext($context, "foo"))' : '$this->getContext($context, "foo")'), $env), - array($node, $this->getVariableGetter('foo', 1), $env1), - array($context, "// line 1\n\$context"), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FilterInclude.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FilterInclude.php deleted file mode 100644 index b5394bcf4..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FilterInclude.php +++ /dev/null @@ -1,6 +0,0 @@ -addFilter(new Twig_SimpleFilter('anonymous', function () {})); - -return $env; diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FunctionInclude.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FunctionInclude.php deleted file mode 100644 index e8f68c728..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FunctionInclude.php +++ /dev/null @@ -1,6 +0,0 @@ -addFunction(new Twig_SimpleFunction('anonymous', function () {})); - -return $env; diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/TestInclude.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/TestInclude.php deleted file mode 100644 index 9f818bc41..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/TestInclude.php +++ /dev/null @@ -1,6 +0,0 @@ -addTest(new Twig_SimpleTest('anonymous', function () {})); - -return $env; diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ParentTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/ParentTest.php deleted file mode 100644 index ab2bbe074..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/ParentTest.php +++ /dev/null @@ -1,28 +0,0 @@ -assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - $tests = array(); - $tests[] = array(new Twig_Node_Expression_Parent('foo', 1), '$this->renderParentBlock("foo", $context, $blocks)'); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/TestTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/TestTest.php deleted file mode 100644 index 55d3fcbf6..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/TestTest.php +++ /dev/null @@ -1,82 +0,0 @@ -assertEquals($expr, $node->getNode('node')); - $this->assertEquals($args, $node->getNode('arguments')); - $this->assertEquals($name, $node->getAttribute('name')); - } - - public function getTests() - { - $environment = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $environment->addTest(new Twig_SimpleTest('barbar', 'twig_tests_test_barbar', array('is_variadic' => true, 'need_context' => true))); - - $tests = array(); - - $expr = new Twig_Node_Expression_Constant('foo', 1); - $node = new Twig_Node_Expression_Test_Null($expr, 'null', new Twig_Node(array()), 1); - $tests[] = array($node, '(null === "foo")'); - - // test as an anonymous function - if (PHP_VERSION_ID >= 50300) { - $node = $this->createTest(new Twig_Node_Expression_Constant('foo', 1), 'anonymous', array(new Twig_Node_Expression_Constant('foo', 1))); - $tests[] = array($node, 'call_user_func_array($this->env->getTest(\'anonymous\')->getCallable(), array("foo", "foo"))'); - } - - // arbitrary named arguments - $string = new Twig_Node_Expression_Constant('abc', 1); - $node = $this->createTest($string, 'barbar'); - $tests[] = array($node, 'twig_tests_test_barbar("abc")', $environment); - - $node = $this->createTest($string, 'barbar', array('foo' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_test_barbar("abc", null, null, array("foo" => "bar"))', $environment); - - $node = $this->createTest($string, 'barbar', array('arg2' => new Twig_Node_Expression_Constant('bar', 1))); - $tests[] = array($node, 'twig_tests_test_barbar("abc", null, "bar")', $environment); - - $node = $this->createTest($string, 'barbar', array( - new Twig_Node_Expression_Constant('1', 1), - new Twig_Node_Expression_Constant('2', 1), - new Twig_Node_Expression_Constant('3', 1), - 'foo' => new Twig_Node_Expression_Constant('bar', 1), - )); - $tests[] = array($node, 'twig_tests_test_barbar("abc", "1", "2", array(0 => "3", "foo" => "bar"))', $environment); - - return $tests; - } - - protected function createTest($node, $name, array $arguments = array()) - { - return new Twig_Node_Expression_Test($node, $name, new Twig_Node($arguments), 1); - } - - protected function getEnvironment() - { - if (PHP_VERSION_ID >= 50300) { - return include 'PHP53/TestInclude.php'; - } - - return parent::getEnvironment(); - } -} - -function twig_tests_test_barbar($string, $arg1 = null, $arg2 = null, array $args = array()) -{ -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NegTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NegTest.php deleted file mode 100644 index b63337117..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NegTest.php +++ /dev/null @@ -1,32 +0,0 @@ -assertEquals($expr, $node->getNode('node')); - } - - public function getTests() - { - $node = new Twig_Node_Expression_Constant(1, 1); - $node = new Twig_Node_Expression_Unary_Neg($node, 1); - - return array( - array($node, '-1'), - array(new Twig_Node_Expression_Unary_Neg($node, 1), '- -1'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NotTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NotTest.php deleted file mode 100644 index d7c6f85e7..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/NotTest.php +++ /dev/null @@ -1,31 +0,0 @@ -assertEquals($expr, $node->getNode('node')); - } - - public function getTests() - { - $node = new Twig_Node_Expression_Constant(1, 1); - $node = new Twig_Node_Expression_Unary_Not($node, 1); - - return array( - array($node, '!1'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/PosTest.php b/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/PosTest.php deleted file mode 100644 index 057250f37..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/Expression/Unary/PosTest.php +++ /dev/null @@ -1,31 +0,0 @@ -assertEquals($expr, $node->getNode('node')); - } - - public function getTests() - { - $node = new Twig_Node_Expression_Constant(1, 1); - $node = new Twig_Node_Expression_Unary_Pos($node, 1); - - return array( - array($node, '+1'), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/ForTest.php b/vendor/twig/twig/test/Twig/Tests/Node/ForTest.php deleted file mode 100644 index b2c6fa42f..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/ForTest.php +++ /dev/null @@ -1,191 +0,0 @@ -setAttribute('with_loop', false); - - $this->assertEquals($keyTarget, $node->getNode('key_target')); - $this->assertEquals($valueTarget, $node->getNode('value_target')); - $this->assertEquals($seq, $node->getNode('seq')); - $this->assertTrue($node->getAttribute('ifexpr')); - $this->assertEquals('Twig_Node_If', get_class($node->getNode('body'))); - $this->assertEquals($body, $node->getNode('body')->getNode('tests')->getNode(1)->getNode(0)); - $this->assertNull($node->getNode('else')); - - $else = new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1); - $node = new Twig_Node_For($keyTarget, $valueTarget, $seq, $ifexpr, $body, $else, 1); - $node->setAttribute('with_loop', false); - $this->assertEquals($else, $node->getNode('else')); - } - - public function getTests() - { - $tests = array(); - - $keyTarget = new Twig_Node_Expression_AssignName('key', 1); - $valueTarget = new Twig_Node_Expression_AssignName('item', 1); - $seq = new Twig_Node_Expression_Name('items', 1); - $ifexpr = null; - $body = new Twig_Node(array(new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1)), array(), 1); - $else = null; - $node = new Twig_Node_For($keyTarget, $valueTarget, $seq, $ifexpr, $body, $else, 1); - $node->setAttribute('with_loop', false); - - $tests[] = array($node, <<getVariableGetter('items')}); -foreach (\$context['_seq'] as \$context["key"] => \$context["item"]) { - echo {$this->getVariableGetter('foo')}; -} -\$_parent = \$context['_parent']; -unset(\$context['_seq'], \$context['_iterated'], \$context['key'], \$context['item'], \$context['_parent'], \$context['loop']); -\$context = array_intersect_key(\$context, \$_parent) + \$_parent; -EOF - ); - - $keyTarget = new Twig_Node_Expression_AssignName('k', 1); - $valueTarget = new Twig_Node_Expression_AssignName('v', 1); - $seq = new Twig_Node_Expression_Name('values', 1); - $ifexpr = null; - $body = new Twig_Node(array(new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1)), array(), 1); - $else = null; - $node = new Twig_Node_For($keyTarget, $valueTarget, $seq, $ifexpr, $body, $else, 1); - $node->setAttribute('with_loop', true); - - $tests[] = array($node, <<getVariableGetter('values')}); -\$context['loop'] = array( - 'parent' => \$context['_parent'], - 'index0' => 0, - 'index' => 1, - 'first' => true, -); -if (is_array(\$context['_seq']) || (is_object(\$context['_seq']) && \$context['_seq'] instanceof Countable)) { - \$length = count(\$context['_seq']); - \$context['loop']['revindex0'] = \$length - 1; - \$context['loop']['revindex'] = \$length; - \$context['loop']['length'] = \$length; - \$context['loop']['last'] = 1 === \$length; -} -foreach (\$context['_seq'] as \$context["k"] => \$context["v"]) { - echo {$this->getVariableGetter('foo')}; - ++\$context['loop']['index0']; - ++\$context['loop']['index']; - \$context['loop']['first'] = false; - if (isset(\$context['loop']['length'])) { - --\$context['loop']['revindex0']; - --\$context['loop']['revindex']; - \$context['loop']['last'] = 0 === \$context['loop']['revindex0']; - } -} -\$_parent = \$context['_parent']; -unset(\$context['_seq'], \$context['_iterated'], \$context['k'], \$context['v'], \$context['_parent'], \$context['loop']); -\$context = array_intersect_key(\$context, \$_parent) + \$_parent; -EOF - ); - - $keyTarget = new Twig_Node_Expression_AssignName('k', 1); - $valueTarget = new Twig_Node_Expression_AssignName('v', 1); - $seq = new Twig_Node_Expression_Name('values', 1); - $ifexpr = new Twig_Node_Expression_Constant(true, 1); - $body = new Twig_Node(array(new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1)), array(), 1); - $else = null; - $node = new Twig_Node_For($keyTarget, $valueTarget, $seq, $ifexpr, $body, $else, 1); - $node->setAttribute('with_loop', true); - - $tests[] = array($node, <<getVariableGetter('values')}); -\$context['loop'] = array( - 'parent' => \$context['_parent'], - 'index0' => 0, - 'index' => 1, - 'first' => true, -); -foreach (\$context['_seq'] as \$context["k"] => \$context["v"]) { - if (true) { - echo {$this->getVariableGetter('foo')}; - ++\$context['loop']['index0']; - ++\$context['loop']['index']; - \$context['loop']['first'] = false; - } -} -\$_parent = \$context['_parent']; -unset(\$context['_seq'], \$context['_iterated'], \$context['k'], \$context['v'], \$context['_parent'], \$context['loop']); -\$context = array_intersect_key(\$context, \$_parent) + \$_parent; -EOF - ); - - $keyTarget = new Twig_Node_Expression_AssignName('k', 1); - $valueTarget = new Twig_Node_Expression_AssignName('v', 1); - $seq = new Twig_Node_Expression_Name('values', 1); - $ifexpr = null; - $body = new Twig_Node(array(new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1)), array(), 1); - $else = new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1); - $node = new Twig_Node_For($keyTarget, $valueTarget, $seq, $ifexpr, $body, $else, 1); - $node->setAttribute('with_loop', true); - - $tests[] = array($node, <<getVariableGetter('values')}); -\$context['_iterated'] = false; -\$context['loop'] = array( - 'parent' => \$context['_parent'], - 'index0' => 0, - 'index' => 1, - 'first' => true, -); -if (is_array(\$context['_seq']) || (is_object(\$context['_seq']) && \$context['_seq'] instanceof Countable)) { - \$length = count(\$context['_seq']); - \$context['loop']['revindex0'] = \$length - 1; - \$context['loop']['revindex'] = \$length; - \$context['loop']['length'] = \$length; - \$context['loop']['last'] = 1 === \$length; -} -foreach (\$context['_seq'] as \$context["k"] => \$context["v"]) { - echo {$this->getVariableGetter('foo')}; - \$context['_iterated'] = true; - ++\$context['loop']['index0']; - ++\$context['loop']['index']; - \$context['loop']['first'] = false; - if (isset(\$context['loop']['length'])) { - --\$context['loop']['revindex0']; - --\$context['loop']['revindex']; - \$context['loop']['last'] = 0 === \$context['loop']['revindex0']; - } -} -if (!\$context['_iterated']) { - echo {$this->getVariableGetter('foo')}; -} -\$_parent = \$context['_parent']; -unset(\$context['_seq'], \$context['_iterated'], \$context['k'], \$context['v'], \$context['_parent'], \$context['loop']); -\$context = array_intersect_key(\$context, \$_parent) + \$_parent; -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/IfTest.php b/vendor/twig/twig/test/Twig/Tests/Node/IfTest.php deleted file mode 100644 index e47dd6540..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/IfTest.php +++ /dev/null @@ -1,88 +0,0 @@ -assertEquals($t, $node->getNode('tests')); - $this->assertNull($node->getNode('else')); - - $else = new Twig_Node_Print(new Twig_Node_Expression_Name('bar', 1), 1); - $node = new Twig_Node_If($t, $else, 1); - $this->assertEquals($else, $node->getNode('else')); - } - - public function getTests() - { - $tests = array(); - - $t = new Twig_Node(array( - new Twig_Node_Expression_Constant(true, 1), - new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1), - ), array(), 1); - $else = null; - $node = new Twig_Node_If($t, $else, 1); - - $tests[] = array($node, <<getVariableGetter('foo')}; -} -EOF - ); - - $t = new Twig_Node(array( - new Twig_Node_Expression_Constant(true, 1), - new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1), - new Twig_Node_Expression_Constant(false, 1), - new Twig_Node_Print(new Twig_Node_Expression_Name('bar', 1), 1), - ), array(), 1); - $else = null; - $node = new Twig_Node_If($t, $else, 1); - - $tests[] = array($node, <<getVariableGetter('foo')}; -} elseif (false) { - echo {$this->getVariableGetter('bar')}; -} -EOF - ); - - $t = new Twig_Node(array( - new Twig_Node_Expression_Constant(true, 1), - new Twig_Node_Print(new Twig_Node_Expression_Name('foo', 1), 1), - ), array(), 1); - $else = new Twig_Node_Print(new Twig_Node_Expression_Name('bar', 1), 1); - $node = new Twig_Node_If($t, $else, 1); - - $tests[] = array($node, <<getVariableGetter('foo')}; -} else { - echo {$this->getVariableGetter('bar')}; -} -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/ImportTest.php b/vendor/twig/twig/test/Twig/Tests/Node/ImportTest.php deleted file mode 100644 index 36525b251..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/ImportTest.php +++ /dev/null @@ -1,40 +0,0 @@ -assertEquals($macro, $node->getNode('expr')); - $this->assertEquals($var, $node->getNode('var')); - } - - public function getTests() - { - $tests = array(); - - $macro = new Twig_Node_Expression_Constant('foo.twig', 1); - $var = new Twig_Node_Expression_AssignName('macro', 1); - $node = new Twig_Node_Import($macro, $var, 1); - - $tests[] = array($node, <<loadTemplate("foo.twig", null, 1); -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/IncludeTest.php b/vendor/twig/twig/test/Twig/Tests/Node/IncludeTest.php deleted file mode 100644 index 6fe5c17bf..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/IncludeTest.php +++ /dev/null @@ -1,83 +0,0 @@ -assertNull($node->getNode('variables')); - $this->assertEquals($expr, $node->getNode('expr')); - $this->assertFalse($node->getAttribute('only')); - - $vars = new Twig_Node_Expression_Array(array(new Twig_Node_Expression_Constant('foo', 1), new Twig_Node_Expression_Constant(true, 1)), 1); - $node = new Twig_Node_Include($expr, $vars, true, false, 1); - $this->assertEquals($vars, $node->getNode('variables')); - $this->assertTrue($node->getAttribute('only')); - } - - public function getTests() - { - $tests = array(); - - $expr = new Twig_Node_Expression_Constant('foo.twig', 1); - $node = new Twig_Node_Include($expr, null, false, false, 1); - $tests[] = array($node, <<loadTemplate("foo.twig", null, 1)->display(\$context); -EOF - ); - - $expr = new Twig_Node_Expression_Conditional( - new Twig_Node_Expression_Constant(true, 1), - new Twig_Node_Expression_Constant('foo', 1), - new Twig_Node_Expression_Constant('foo', 1), - 0 - ); - $node = new Twig_Node_Include($expr, null, false, false, 1); - $tests[] = array($node, <<loadTemplate(((true) ? ("foo") : ("foo")), null, 1)->display(\$context); -EOF - ); - - $expr = new Twig_Node_Expression_Constant('foo.twig', 1); - $vars = new Twig_Node_Expression_Array(array(new Twig_Node_Expression_Constant('foo', 1), new Twig_Node_Expression_Constant(true, 1)), 1); - $node = new Twig_Node_Include($expr, $vars, false, false, 1); - $tests[] = array($node, <<loadTemplate("foo.twig", null, 1)->display(array_merge(\$context, array("foo" => true))); -EOF - ); - - $node = new Twig_Node_Include($expr, $vars, true, false, 1); - $tests[] = array($node, <<loadTemplate("foo.twig", null, 1)->display(array("foo" => true)); -EOF - ); - - $node = new Twig_Node_Include($expr, $vars, true, true, 1); - $tests[] = array($node, <<loadTemplate("foo.twig", null, 1)->display(array("foo" => true)); -} catch (Twig_Error_Loader \$e) { - // ignore missing template -} -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/MacroTest.php b/vendor/twig/twig/test/Twig/Tests/Node/MacroTest.php deleted file mode 100644 index 901e57b91..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/MacroTest.php +++ /dev/null @@ -1,70 +0,0 @@ -assertEquals($body, $node->getNode('body')); - $this->assertEquals($arguments, $node->getNode('arguments')); - $this->assertEquals('foo', $node->getAttribute('name')); - } - - public function getTests() - { - $body = new Twig_Node_Text('foo', 1); - $arguments = new Twig_Node(array( - 'foo' => new Twig_Node_Expression_Constant(null, 1), - 'bar' => new Twig_Node_Expression_Constant('Foo', 1), - ), array(), 1); - $node = new Twig_Node_Macro('foo', $body, $arguments, 1); - - if (PHP_VERSION_ID >= 50600) { - $declaration = ', ...$__varargs__'; - $varargs = '$__varargs__'; - } else { - $declaration = ''; - $varargs = 'func_num_args() > 2 ? array_slice(func_get_args(), 2) : array()'; - } - - return array( - array($node, <<env->mergeGlobals(array( - "foo" => \$__foo__, - "bar" => \$__bar__, - "varargs" => $varargs, - )); - - \$blocks = array(); - - ob_start(); - try { - echo "foo"; - } catch (Exception \$e) { - ob_end_clean(); - - throw \$e; - } - - return ('' === \$tmp = ob_get_clean()) ? '' : new Twig_Markup(\$tmp, \$this->env->getCharset()); -} -EOF - ), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/ModuleTest.php b/vendor/twig/twig/test/Twig/Tests/Node/ModuleTest.php deleted file mode 100644 index 19a4be9ff..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/ModuleTest.php +++ /dev/null @@ -1,183 +0,0 @@ -assertEquals($body, $node->getNode('body')); - $this->assertEquals($blocks, $node->getNode('blocks')); - $this->assertEquals($macros, $node->getNode('macros')); - $this->assertEquals($parent, $node->getNode('parent')); - $this->assertEquals($filename, $node->getAttribute('filename')); - } - - public function getTests() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - - $tests = array(); - - $body = new Twig_Node_Text('foo', 1); - $extends = null; - $blocks = new Twig_Node(); - $macros = new Twig_Node(); - $traits = new Twig_Node(); - $filename = 'foo.twig'; - - $node = new Twig_Node_Module($body, $extends, $blocks, $macros, $traits, new Twig_Node(array()), $filename); - $tests[] = array($node, <<parent = false; - - \$this->blocks = array( - ); - } - - protected function doDisplay(array \$context, array \$blocks = array()) - { - // line 1 - echo "foo"; - } - - public function getTemplateName() - { - return "foo.twig"; - } - - public function getDebugInfo() - { - return array ( 19 => 1,); - } -} -EOF - , $twig); - - $import = new Twig_Node_Import(new Twig_Node_Expression_Constant('foo.twig', 1), new Twig_Node_Expression_AssignName('macro', 1), 2); - - $body = new Twig_Node(array($import)); - $extends = new Twig_Node_Expression_Constant('layout.twig', 1); - - $node = new Twig_Node_Module($body, $extends, $blocks, $macros, $traits, new Twig_Node(array()), $filename); - $tests[] = array($node, <<parent = \$this->loadTemplate("layout.twig", "foo.twig", 1); - \$this->blocks = array( - ); - } - - protected function doGetParent(array \$context) - { - return "layout.twig"; - } - - protected function doDisplay(array \$context, array \$blocks = array()) - { - // line 2 - \$context["macro"] = \$this->loadTemplate("foo.twig", "foo.twig", 2); - // line 1 - \$this->parent->display(\$context, array_merge(\$this->blocks, \$blocks)); - } - - public function getTemplateName() - { - return "foo.twig"; - } - - public function isTraitable() - { - return false; - } - - public function getDebugInfo() - { - return array ( 26 => 1, 24 => 2, 11 => 1,); - } -} -EOF - , $twig); - - $set = new Twig_Node_Set(false, new Twig_Node(array(new Twig_Node_Expression_AssignName('foo', 4))), new Twig_Node(array(new Twig_Node_Expression_Constant('foo', 4))), 4); - $body = new Twig_Node(array($set)); - $extends = new Twig_Node_Expression_Conditional( - new Twig_Node_Expression_Constant(true, 2), - new Twig_Node_Expression_Constant('foo', 2), - new Twig_Node_Expression_Constant('foo', 2), - 2 - ); - - $node = new Twig_Node_Module($body, $extends, $blocks, $macros, $traits, new Twig_Node(array()), $filename); - $tests[] = array($node, <<loadTemplate(((true) ? ("foo") : ("foo")), "foo.twig", 2); - } - - protected function doDisplay(array \$context, array \$blocks = array()) - { - // line 4 - \$context["foo"] = "foo"; - // line 2 - \$this->getParent(\$context)->display(\$context, array_merge(\$this->blocks, \$blocks)); - } - - public function getTemplateName() - { - return "foo.twig"; - } - - public function isTraitable() - { - return false; - } - - public function getDebugInfo() - { - return array ( 17 => 2, 15 => 4, 9 => 2,); - } -} -EOF - , $twig); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/PrintTest.php b/vendor/twig/twig/test/Twig/Tests/Node/PrintTest.php deleted file mode 100644 index 4e0990fac..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/PrintTest.php +++ /dev/null @@ -1,29 +0,0 @@ -assertEquals($expr, $node->getNode('expr')); - } - - public function getTests() - { - $tests = array(); - $tests[] = array(new Twig_Node_Print(new Twig_Node_Expression_Constant('foo', 1), 1), "// line 1\necho \"foo\";"); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/SandboxTest.php b/vendor/twig/twig/test/Twig/Tests/Node/SandboxTest.php deleted file mode 100644 index 46ecf9731..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/SandboxTest.php +++ /dev/null @@ -1,44 +0,0 @@ -assertEquals($body, $node->getNode('body')); - } - - public function getTests() - { - $tests = array(); - - $body = new Twig_Node_Text('foo', 1); - $node = new Twig_Node_Sandbox($body, 1); - - $tests[] = array($node, <<env->getExtension('sandbox'); -if (!\$alreadySandboxed = \$sandbox->isSandboxed()) { - \$sandbox->enableSandbox(); -} -echo "foo"; -if (!\$alreadySandboxed) { - \$sandbox->disableSandbox(); -} -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/SandboxedPrintTest.php b/vendor/twig/twig/test/Twig/Tests/Node/SandboxedPrintTest.php deleted file mode 100644 index 05e1854cb..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/SandboxedPrintTest.php +++ /dev/null @@ -1,33 +0,0 @@ -assertEquals($expr, $node->getNode('expr')); - } - - public function getTests() - { - $tests = array(); - - $tests[] = array(new Twig_Node_SandboxedPrint(new Twig_Node_Expression_Constant('foo', 1), 1), <<env->getExtension('sandbox')->ensureToStringAllowed("foo"); -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/SetTest.php b/vendor/twig/twig/test/Twig/Tests/Node/SetTest.php deleted file mode 100644 index 62ad2803e..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/SetTest.php +++ /dev/null @@ -1,69 +0,0 @@ -assertEquals($names, $node->getNode('names')); - $this->assertEquals($values, $node->getNode('values')); - $this->assertFalse($node->getAttribute('capture')); - } - - public function getTests() - { - $tests = array(); - - $names = new Twig_Node(array(new Twig_Node_Expression_AssignName('foo', 1)), array(), 1); - $values = new Twig_Node(array(new Twig_Node_Expression_Constant('foo', 1)), array(), 1); - $node = new Twig_Node_Set(false, $names, $values, 1); - $tests[] = array($node, <<env->getCharset()); -EOF - ); - - $names = new Twig_Node(array(new Twig_Node_Expression_AssignName('foo', 1)), array(), 1); - $values = new Twig_Node_Text('foo', 1); - $node = new Twig_Node_Set(true, $names, $values, 1); - $tests[] = array($node, <<env->getCharset()); -EOF - ); - - $names = new Twig_Node(array(new Twig_Node_Expression_AssignName('foo', 1), new Twig_Node_Expression_AssignName('bar', 1)), array(), 1); - $values = new Twig_Node(array(new Twig_Node_Expression_Constant('foo', 1), new Twig_Node_Expression_Name('bar', 1)), array(), 1); - $node = new Twig_Node_Set(false, $names, $values, 1); - $tests[] = array($node, <<getVariableGetter('bar')}); -EOF - ); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/SpacelessTest.php b/vendor/twig/twig/test/Twig/Tests/Node/SpacelessTest.php deleted file mode 100644 index 222ca0920..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/SpacelessTest.php +++ /dev/null @@ -1,37 +0,0 @@ -
    foo
    ', 1))); - $node = new Twig_Node_Spaceless($body, 1); - - $this->assertEquals($body, $node->getNode('body')); - } - - public function getTests() - { - $body = new Twig_Node(array(new Twig_Node_Text('
    foo
    ', 1))); - $node = new Twig_Node_Spaceless($body, 1); - - return array( - array($node, <<
    foo
    "; -echo trim(preg_replace('/>\s+<', ob_get_clean())); -EOF - ), - ); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Node/TextTest.php b/vendor/twig/twig/test/Twig/Tests/Node/TextTest.php deleted file mode 100644 index ceaf67f4c..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Node/TextTest.php +++ /dev/null @@ -1,28 +0,0 @@ -assertEquals('foo', $node->getAttribute('data')); - } - - public function getTests() - { - $tests = array(); - $tests[] = array(new Twig_Node_Text('foo', 1), "// line 1\necho \"foo\";"); - - return $tests; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/NodeVisitor/OptimizerTest.php b/vendor/twig/twig/test/Twig/Tests/NodeVisitor/OptimizerTest.php deleted file mode 100644 index b5ea7aac2..000000000 --- a/vendor/twig/twig/test/Twig/Tests/NodeVisitor/OptimizerTest.php +++ /dev/null @@ -1,124 +0,0 @@ -getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - - $stream = $env->parse($env->tokenize('{{ block("foo") }}', 'index')); - - $node = $stream->getNode('body')->getNode(0); - - $this->assertEquals('Twig_Node_Expression_BlockReference', get_class($node)); - $this->assertTrue($node->getAttribute('output')); - } - - public function testRenderParentBlockOptimizer() - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - - $stream = $env->parse($env->tokenize('{% extends "foo" %}{% block content %}{{ parent() }}{% endblock %}', 'index')); - - $node = $stream->getNode('blocks')->getNode('content')->getNode(0)->getNode('body'); - - $this->assertEquals('Twig_Node_Expression_Parent', get_class($node)); - $this->assertTrue($node->getAttribute('output')); - } - - public function testRenderVariableBlockOptimizer() - { - if (PHP_VERSION_ID >= 50400) { - return; - } - - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false, 'autoescape' => false)); - $stream = $env->parse($env->tokenize('{{ block(name|lower) }}', 'index')); - - $node = $stream->getNode('body')->getNode(0)->getNode(1); - - $this->assertEquals('Twig_Node_Expression_BlockReference', get_class($node)); - $this->assertTrue($node->getAttribute('output')); - } - - /** - * @dataProvider getTestsForForOptimizer - */ - public function testForOptimizer($template, $expected) - { - $env = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('cache' => false)); - - $stream = $env->parse($env->tokenize($template, 'index')); - - foreach ($expected as $target => $withLoop) { - $this->assertTrue($this->checkForConfiguration($stream, $target, $withLoop), sprintf('variable %s is %soptimized', $target, $withLoop ? 'not ' : '')); - } - } - - public function getTestsForForOptimizer() - { - return array( - array('{% for i in foo %}{% endfor %}', array('i' => false)), - - array('{% for i in foo %}{{ loop.index }}{% endfor %}', array('i' => true)), - - array('{% for i in foo %}{% for j in foo %}{% endfor %}{% endfor %}', array('i' => false, 'j' => false)), - - array('{% for i in foo %}{% include "foo" %}{% endfor %}', array('i' => true)), - - array('{% for i in foo %}{% include "foo" only %}{% endfor %}', array('i' => false)), - - array('{% for i in foo %}{% include "foo" with { "foo": "bar" } only %}{% endfor %}', array('i' => false)), - - array('{% for i in foo %}{% include "foo" with { "foo": loop.index } only %}{% endfor %}', array('i' => true)), - - array('{% for i in foo %}{% for j in foo %}{{ loop.index }}{% endfor %}{% endfor %}', array('i' => false, 'j' => true)), - - array('{% for i in foo %}{% for j in foo %}{{ loop.parent.loop.index }}{% endfor %}{% endfor %}', array('i' => true, 'j' => true)), - - array('{% for i in foo %}{% set l = loop %}{% for j in foo %}{{ l.index }}{% endfor %}{% endfor %}', array('i' => true, 'j' => false)), - - array('{% for i in foo %}{% for j in foo %}{{ foo.parent.loop.index }}{% endfor %}{% endfor %}', array('i' => false, 'j' => false)), - - array('{% for i in foo %}{% for j in foo %}{{ loop["parent"].loop.index }}{% endfor %}{% endfor %}', array('i' => true, 'j' => true)), - - array('{% for i in foo %}{{ include("foo") }}{% endfor %}', array('i' => true)), - - array('{% for i in foo %}{{ include("foo", with_context = false) }}{% endfor %}', array('i' => false)), - - array('{% for i in foo %}{{ include("foo", with_context = true) }}{% endfor %}', array('i' => true)), - - array('{% for i in foo %}{{ include("foo", { "foo": "bar" }, with_context = false) }}{% endfor %}', array('i' => false)), - - array('{% for i in foo %}{{ include("foo", { "foo": loop.index }, with_context = false) }}{% endfor %}', array('i' => true)), - ); - } - - public function checkForConfiguration(Twig_NodeInterface $node = null, $target, $withLoop) - { - if (null === $node) { - return; - } - - foreach ($node as $n) { - if ($n instanceof Twig_Node_For) { - if ($target === $n->getNode('value_target')->getAttribute('name')) { - return $withLoop == $n->getAttribute('with_loop'); - } - } - - $ret = $this->checkForConfiguration($n, $target, $withLoop); - if (null !== $ret) { - return $ret; - } - } - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/ParserTest.php b/vendor/twig/twig/test/Twig/Tests/ParserTest.php deleted file mode 100644 index b29dac311..000000000 --- a/vendor/twig/twig/test/Twig/Tests/ParserTest.php +++ /dev/null @@ -1,180 +0,0 @@ -getParser(); - $parser->setMacro('parent', $this->getMock('Twig_Node_Macro', array(), array(), '', null)); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage Unknown tag name "foo". Did you mean "for" at line 1 - */ - public function testUnknownTag() - { - $stream = new Twig_TokenStream(array( - new Twig_Token(Twig_Token::BLOCK_START_TYPE, '', 1), - new Twig_Token(Twig_Token::NAME_TYPE, 'foo', 1), - new Twig_Token(Twig_Token::BLOCK_END_TYPE, '', 1), - new Twig_Token(Twig_Token::EOF_TYPE, '', 1), - )); - $parser = new Twig_Parser(new Twig_Environment($this->getMock('Twig_LoaderInterface'))); - $parser->parse($stream); - } - - /** - * @dataProvider getFilterBodyNodesData - */ - public function testFilterBodyNodes($input, $expected) - { - $parser = $this->getParser(); - - $this->assertEquals($expected, $parser->filterBodyNodes($input)); - } - - public function getFilterBodyNodesData() - { - return array( - array( - new Twig_Node(array(new Twig_Node_Text(' ', 1))), - new Twig_Node(array()), - ), - array( - $input = new Twig_Node(array(new Twig_Node_Set(false, new Twig_Node(), new Twig_Node(), 1))), - $input, - ), - array( - $input = new Twig_Node(array(new Twig_Node_Set(true, new Twig_Node(), new Twig_Node(array(new Twig_Node(array(new Twig_Node_Text('foo', 1))))), 1))), - $input, - ), - ); - } - - /** - * @dataProvider getFilterBodyNodesDataThrowsException - * @expectedException Twig_Error_Syntax - */ - public function testFilterBodyNodesThrowsException($input) - { - $parser = $this->getParser(); - - $parser->filterBodyNodes($input); - } - - public function getFilterBodyNodesDataThrowsException() - { - return array( - array(new Twig_Node_Text('foo', 1)), - array(new Twig_Node(array(new Twig_Node(array(new Twig_Node_Text('foo', 1)))))), - ); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedExceptionMessage A template that extends another one cannot have a body but a byte order mark (BOM) has been detected; it must be removed at line 1. - */ - public function testFilterBodyNodesWithBOM() - { - $parser = $this->getParser(); - $parser->filterBodyNodes(new Twig_Node_Text(chr(0xEF).chr(0xBB).chr(0xBF), 1)); - } - - public function testParseIsReentrant() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array( - 'autoescape' => false, - 'optimizations' => 0, - )); - $twig->addTokenParser(new TestTokenParser()); - - $parser = new Twig_Parser($twig); - - $parser->parse(new Twig_TokenStream(array( - new Twig_Token(Twig_Token::BLOCK_START_TYPE, '', 1), - new Twig_Token(Twig_Token::NAME_TYPE, 'test', 1), - new Twig_Token(Twig_Token::BLOCK_END_TYPE, '', 1), - new Twig_Token(Twig_Token::VAR_START_TYPE, '', 1), - new Twig_Token(Twig_Token::NAME_TYPE, 'foo', 1), - new Twig_Token(Twig_Token::VAR_END_TYPE, '', 1), - new Twig_Token(Twig_Token::EOF_TYPE, '', 1), - ))); - - $this->assertNull($parser->getParent()); - } - - // The getVarName() must not depend on the template loaders, - // If this test does not throw any exception, that's good. - // see https://github.com/symfony/symfony/issues/4218 - public function testGetVarName() - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface'), array( - 'autoescape' => false, - 'optimizations' => 0, - )); - - $twig->parse($twig->tokenize(<<getMock('Twig_LoaderInterface'))); - $parser->setParent(new Twig_Node()); - $parser->stream = $this->getMockBuilder('Twig_TokenStream')->disableOriginalConstructor()->getMock(); - - return $parser; - } -} - -class TestParser extends Twig_Parser -{ - public $stream; - - public function filterBodyNodes(Twig_NodeInterface $node) - { - return parent::filterBodyNodes($node); - } -} - -class TestTokenParser extends Twig_TokenParser -{ - public function parse(Twig_Token $token) - { - // simulate the parsing of another template right in the middle of the parsing of the current template - $this->parser->parse(new Twig_TokenStream(array( - new Twig_Token(Twig_Token::BLOCK_START_TYPE, '', 1), - new Twig_Token(Twig_Token::NAME_TYPE, 'extends', 1), - new Twig_Token(Twig_Token::STRING_TYPE, 'base', 1), - new Twig_Token(Twig_Token::BLOCK_END_TYPE, '', 1), - new Twig_Token(Twig_Token::EOF_TYPE, '', 1), - ))); - - $this->parser->getStream()->expect(Twig_Token::BLOCK_END_TYPE); - - return new Twig_Node(array()); - } - - public function getTag() - { - return 'test'; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/AbstractTest.php b/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/AbstractTest.php deleted file mode 100644 index da97f478a..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/AbstractTest.php +++ /dev/null @@ -1,101 +0,0 @@ -getMockBuilder('Twig_Profiler_Profile')->disableOriginalConstructor()->getMock(); - - $profile->expects($this->any())->method('isRoot')->will($this->returnValue(true)); - $profile->expects($this->any())->method('getName')->will($this->returnValue('main')); - $profile->expects($this->any())->method('getDuration')->will($this->returnValue(1)); - $profile->expects($this->any())->method('getMemoryUsage')->will($this->returnValue(0)); - $profile->expects($this->any())->method('getPeakMemoryUsage')->will($this->returnValue(0)); - - $subProfiles = array( - $this->getIndexProfile( - array( - $this->getEmbeddedBlockProfile(), - $this->getEmbeddedTemplateProfile( - array( - $this->getIncludedTemplateProfile(), - ) - ), - $this->getMacroProfile(), - $this->getEmbeddedTemplateProfile( - array( - $this->getIncludedTemplateProfile(), - ) - ), - ) - ), - ); - - $profile->expects($this->any())->method('getProfiles')->will($this->returnValue($subProfiles)); - $profile->expects($this->any())->method('getIterator')->will($this->returnValue(new ArrayIterator($subProfiles))); - - return $profile; - } - - private function getIndexProfile(array $subProfiles = array()) - { - return $this->generateProfile('main', 1, true, 'template', 'index.twig', $subProfiles); - } - - private function getEmbeddedBlockProfile(array $subProfiles = array()) - { - return $this->generateProfile('body', 0.0001, false, 'block', 'embedded.twig', $subProfiles); - } - - private function getEmbeddedTemplateProfile(array $subProfiles = array()) - { - return $this->generateProfile('main', 0.0001, true, 'template', 'embedded.twig', $subProfiles); - } - - private function getIncludedTemplateProfile(array $subProfiles = array()) - { - return $this->generateProfile('main', 0.0001, true, 'template', 'included.twig', $subProfiles); - } - - private function getMacroProfile(array $subProfiles = array()) - { - return $this->generateProfile('foo', 0.0001, false, 'macro', 'index.twig', $subProfiles); - } - - /** - * @param string $name - * @param float $duration - * @param bool $isTemplate - * @param string $type - * @param string $templateName - * @param array $subProfiles - * - * @return Twig_Profiler_Profile - */ - private function generateProfile($name, $duration, $isTemplate, $type, $templateName, array $subProfiles = array()) - { - $profile = $this->getMockBuilder('Twig_Profiler_Profile')->disableOriginalConstructor()->getMock(); - - $profile->expects($this->any())->method('isRoot')->will($this->returnValue(false)); - $profile->expects($this->any())->method('getName')->will($this->returnValue($name)); - $profile->expects($this->any())->method('getDuration')->will($this->returnValue($duration)); - $profile->expects($this->any())->method('getMemoryUsage')->will($this->returnValue(0)); - $profile->expects($this->any())->method('getPeakMemoryUsage')->will($this->returnValue(0)); - $profile->expects($this->any())->method('isTemplate')->will($this->returnValue($isTemplate)); - $profile->expects($this->any())->method('getType')->will($this->returnValue($type)); - $profile->expects($this->any())->method('getTemplate')->will($this->returnValue($templateName)); - $profile->expects($this->any())->method('getProfiles')->will($this->returnValue($subProfiles)); - $profile->expects($this->any())->method('getIterator')->will($this->returnValue(new ArrayIterator($subProfiles))); - - return $profile; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/BlackfireTest.php b/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/BlackfireTest.php deleted file mode 100644 index 1a1b9d299..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/BlackfireTest.php +++ /dev/null @@ -1,32 +0,0 @@ -assertStringMatchesFormat(<<index.twig//1 %d %d %d -index.twig==>embedded.twig::block(body)//1 %d %d 0 -index.twig==>embedded.twig//2 %d %d %d -embedded.twig==>included.twig//2 %d %d %d -index.twig==>index.twig::macro(foo)//1 %d %d %d -EOF - , $dumper->dump($this->getProfile())); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/HtmlTest.php b/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/HtmlTest.php deleted file mode 100644 index 66a68c4be..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/HtmlTest.php +++ /dev/null @@ -1,30 +0,0 @@ -assertStringMatchesFormat(<<main %d.%dms/%d% -└ index.twig %d.%dms/%d% - └ embedded.twig::block(body) - └ embedded.twig - │ └ included.twig - └ index.twig::macro(foo) - └ embedded.twig - └ included.twig - -EOF - , $dumper->dump($this->getProfile())); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/TextTest.php b/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/TextTest.php deleted file mode 100644 index e2ea165ac..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Profiler/Dumper/TextTest.php +++ /dev/null @@ -1,30 +0,0 @@ -assertStringMatchesFormat(<<dump($this->getProfile())); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/Profiler/ProfileTest.php b/vendor/twig/twig/test/Twig/Tests/Profiler/ProfileTest.php deleted file mode 100644 index f786f06ca..000000000 --- a/vendor/twig/twig/test/Twig/Tests/Profiler/ProfileTest.php +++ /dev/null @@ -1,100 +0,0 @@ -assertEquals('template', $profile->getTemplate()); - $this->assertEquals('type', $profile->getType()); - $this->assertEquals('name', $profile->getName()); - } - - public function testIsRoot() - { - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::ROOT); - $this->assertTrue($profile->isRoot()); - - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::TEMPLATE); - $this->assertFalse($profile->isRoot()); - } - - public function testIsTemplate() - { - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::TEMPLATE); - $this->assertTrue($profile->isTemplate()); - - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::ROOT); - $this->assertFalse($profile->isTemplate()); - } - - public function testIsBlock() - { - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::BLOCK); - $this->assertTrue($profile->isBlock()); - - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::ROOT); - $this->assertFalse($profile->isBlock()); - } - - public function testIsMacro() - { - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::MACRO); - $this->assertTrue($profile->isMacro()); - - $profile = new Twig_Profiler_Profile('template', Twig_Profiler_Profile::ROOT); - $this->assertFalse($profile->isMacro()); - } - - public function testGetAddProfile() - { - $profile = new Twig_Profiler_Profile(); - $profile->addProfile($a = new Twig_Profiler_Profile()); - $profile->addProfile($b = new Twig_Profiler_Profile()); - - $this->assertSame(array($a, $b), $profile->getProfiles()); - $this->assertSame(array($a, $b), iterator_to_array($profile)); - } - - public function testGetDuration() - { - $profile = new Twig_Profiler_Profile(); - usleep(1); - $profile->leave(); - - $this->assertTrue($profile->getDuration() > 0, sprintf('Expected duration > 0, got: %f', $profile->getDuration())); - } - - public function testSerialize() - { - $profile = new Twig_Profiler_Profile('template', 'type', 'name'); - $profile1 = new Twig_Profiler_Profile('template1', 'type1', 'name1'); - $profile->addProfile($profile1); - $profile->leave(); - $profile1->leave(); - - $profile2 = unserialize(serialize($profile)); - $profiles = $profile->getProfiles(); - $this->assertCount(1, $profiles); - $profile3 = $profiles[0]; - - $this->assertEquals($profile->getTemplate(), $profile2->getTemplate()); - $this->assertEquals($profile->getType(), $profile2->getType()); - $this->assertEquals($profile->getName(), $profile2->getName()); - $this->assertEquals($profile->getDuration(), $profile2->getDuration()); - - $this->assertEquals($profile1->getTemplate(), $profile3->getTemplate()); - $this->assertEquals($profile1->getType(), $profile3->getType()); - $this->assertEquals($profile1->getName(), $profile3->getName()); - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/TemplateTest.php b/vendor/twig/twig/test/Twig/Tests/TemplateTest.php deleted file mode 100644 index 37836fdc8..000000000 --- a/vendor/twig/twig/test/Twig/Tests/TemplateTest.php +++ /dev/null @@ -1,693 +0,0 @@ -getMockForAbstractClass('Twig_Template', array(), '', false); - $template->displayBlock('foo', array(), array('foo' => array(new stdClass(), 'foo'))); - } - - /** - * @dataProvider getAttributeExceptions - */ - public function testGetAttributeExceptions($template, $message, $useExt) - { - $name = 'index_'.($useExt ? 1 : 0); - $templates = array( - $name => $template.$useExt, // appending $useExt makes the template content unique - ); - - $env = new Twig_Environment(new Twig_Loader_Array($templates), array('strict_variables' => true)); - if (!$useExt) { - $env->addNodeVisitor(new CExtDisablingNodeVisitor()); - } - $template = $env->loadTemplate($name); - - $context = array( - 'string' => 'foo', - 'null' => null, - 'empty_array' => array(), - 'array' => array('foo' => 'foo'), - 'array_access' => new Twig_TemplateArrayAccessObject(), - 'magic_exception' => new Twig_TemplateMagicPropertyObjectWithException(), - 'object' => new stdClass(), - ); - - try { - $template->render($context); - $this->fail('Accessing an invalid attribute should throw an exception.'); - } catch (Twig_Error_Runtime $e) { - $this->assertSame(sprintf($message, $name), $e->getMessage()); - } - } - - public function getAttributeExceptions() - { - $tests = array( - array('{{ string["a"] }}', 'Impossible to access a key ("a") on a string variable ("foo") in "%s" at line 1', false), - array('{{ null["a"] }}', 'Impossible to access a key ("a") on a null variable in "%s" at line 1', false), - array('{{ empty_array["a"] }}', 'Key "a" does not exist as the array is empty in "%s" at line 1', false), - array('{{ array["a"] }}', 'Key "a" for array with keys "foo" does not exist in "%s" at line 1', false), - array('{{ array_access["a"] }}', 'Key "a" in object with ArrayAccess of class "Twig_TemplateArrayAccessObject" does not exist in "%s" at line 1', false), - array('{{ string.a }}', 'Impossible to access an attribute ("a") on a string variable ("foo") in "%s" at line 1', false), - array('{{ string.a() }}', 'Impossible to invoke a method ("a") on a string variable ("foo") in "%s" at line 1', false), - array('{{ null.a }}', 'Impossible to access an attribute ("a") on a null variable in "%s" at line 1', false), - array('{{ null.a() }}', 'Impossible to invoke a method ("a") on a null variable in "%s" at line 1', false), - array('{{ empty_array.a }}', 'Key "a" does not exist as the array is empty in "%s" at line 1', false), - array('{{ array.a }}', 'Key "a" for array with keys "foo" does not exist in "%s" at line 1', false), - array('{{ attribute(array, -10) }}', 'Key "-10" for array with keys "foo" does not exist in "%s" at line 1', false), - array('{{ array_access.a }}', 'Method "a" for object "Twig_TemplateArrayAccessObject" does not exist in "%s" at line 1', false), - array('{% from _self import foo %}{% macro foo(obj) %}{{ obj.missing_method() }}{% endmacro %}{{ foo(array_access) }}', 'Method "missing_method" for object "Twig_TemplateArrayAccessObject" does not exist in "%s" at line 1', false), - array('{{ magic_exception.test }}', 'An exception has been thrown during the rendering of a template ("Hey! Don\'t try to isset me!") in "%s" at line 1.', false), - array('{{ object["a"] }}', 'Impossible to access a key "a" on an object of class "stdClass" that does not implement ArrayAccess interface in "%s" at line 1', false), - ); - - if (function_exists('twig_template_get_attributes')) { - foreach (array_slice($tests, 0) as $test) { - $test[2] = true; - $tests[] = $test; - } - } - - return $tests; - } - - public function testGetSource() - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), false); - - $this->assertSame("\n", $template->getSource()); - } - - /** - * @dataProvider getGetAttributeWithSandbox - */ - public function testGetAttributeWithSandbox($object, $item, $allowed, $useExt) - { - $twig = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - $policy = new Twig_Sandbox_SecurityPolicy(array(), array(), array(/*method*/), array(/*prop*/), array()); - $twig->addExtension(new Twig_Extension_Sandbox($policy, !$allowed)); - $template = new Twig_TemplateTest($twig, $useExt); - - try { - $template->getAttribute($object, $item, array(), 'any'); - - if (!$allowed) { - $this->fail(); - } - } catch (Twig_Sandbox_SecurityError $e) { - if ($allowed) { - $this->fail(); - } - - $this->assertContains('is not allowed', $e->getMessage()); - } - } - - public function getGetAttributeWithSandbox() - { - $tests = array( - array(new Twig_TemplatePropertyObject(), 'defined', false, false), - array(new Twig_TemplatePropertyObject(), 'defined', true, false), - array(new Twig_TemplateMethodObject(), 'defined', false, false), - array(new Twig_TemplateMethodObject(), 'defined', true, false), - ); - - if (function_exists('twig_template_get_attributes')) { - foreach (array_slice($tests, 0) as $test) { - $test[3] = true; - $tests[] = $test; - } - } - - return $tests; - } - - /** - * @dataProvider getGetAttributeWithTemplateAsObject - */ - public function testGetAttributeWithTemplateAsObject($useExt) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), $useExt); - $template1 = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), false); - - $this->assertInstanceof('Twig_Markup', $template->getAttribute($template1, 'string')); - $this->assertEquals('some_string', $template->getAttribute($template1, 'string')); - - $this->assertInstanceof('Twig_Markup', $template->getAttribute($template1, 'true')); - $this->assertEquals('1', $template->getAttribute($template1, 'true')); - - $this->assertInstanceof('Twig_Markup', $template->getAttribute($template1, 'zero')); - $this->assertEquals('0', $template->getAttribute($template1, 'zero')); - - $this->assertNotInstanceof('Twig_Markup', $template->getAttribute($template1, 'empty')); - $this->assertSame('', $template->getAttribute($template1, 'empty')); - - $this->assertFalse($template->getAttribute($template1, 'env', array(), Twig_Template::ANY_CALL, true)); - $this->assertFalse($template->getAttribute($template1, 'environment', array(), Twig_Template::ANY_CALL, true)); - $this->assertFalse($template->getAttribute($template1, 'getEnvironment', array(), Twig_Template::METHOD_CALL, true)); - $this->assertFalse($template->getAttribute($template1, 'displayWithErrorHandling', array(), Twig_Template::METHOD_CALL, true)); - } - - public function getGetAttributeWithTemplateAsObject() - { - $bools = array( - array(false), - ); - - if (function_exists('twig_template_get_attributes')) { - $bools[] = array(true); - } - - return $bools; - } - - /** - * @dataProvider getTestsDependingOnExtensionAvailability - */ - public function testGetAttributeOnArrayWithConfusableKey($useExt = false) - { - $template = new Twig_TemplateTest( - new Twig_Environment($this->getMock('Twig_LoaderInterface')), - $useExt - ); - - $array = array('Zero', 'One', -1 => 'MinusOne', '' => 'EmptyString', '1.5' => 'FloatButString', '01' => 'IntegerButStringWithLeadingZeros'); - - $this->assertSame('Zero', $array[false]); - $this->assertSame('One', $array[true]); - $this->assertSame('One', $array[1.5]); - $this->assertSame('One', $array['1']); - $this->assertSame('MinusOne', $array[-1.5]); - $this->assertSame('FloatButString', $array['1.5']); - $this->assertSame('IntegerButStringWithLeadingZeros', $array['01']); - $this->assertSame('EmptyString', $array[null]); - - $this->assertSame('Zero', $template->getAttribute($array, false), 'false is treated as 0 when accessing an array (equals PHP behavior)'); - $this->assertSame('One', $template->getAttribute($array, true), 'true is treated as 1 when accessing an array (equals PHP behavior)'); - $this->assertSame('One', $template->getAttribute($array, 1.5), 'float is casted to int when accessing an array (equals PHP behavior)'); - $this->assertSame('One', $template->getAttribute($array, '1'), '"1" is treated as integer 1 when accessing an array (equals PHP behavior)'); - $this->assertSame('MinusOne', $template->getAttribute($array, -1.5), 'negative float is casted to int when accessing an array (equals PHP behavior)'); - $this->assertSame('FloatButString', $template->getAttribute($array, '1.5'), '"1.5" is treated as-is when accessing an array (equals PHP behavior)'); - $this->assertSame('IntegerButStringWithLeadingZeros', $template->getAttribute($array, '01'), '"01" is treated as-is when accessing an array (equals PHP behavior)'); - $this->assertSame('EmptyString', $template->getAttribute($array, null), 'null is treated as "" when accessing an array (equals PHP behavior)'); - } - - public function getTestsDependingOnExtensionAvailability() - { - if (function_exists('twig_template_get_attributes')) { - return array(array(false), array(true)); - } - - return array(array(false)); - } - - /** - * @dataProvider getGetAttributeTests - */ - public function testGetAttribute($defined, $value, $object, $item, $arguments, $type, $useExt = false) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), $useExt); - - $this->assertEquals($value, $template->getAttribute($object, $item, $arguments, $type)); - } - - /** - * @dataProvider getGetAttributeTests - */ - public function testGetAttributeStrict($defined, $value, $object, $item, $arguments, $type, $useExt = false, $exceptionMessage = null) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('strict_variables' => true)), $useExt); - - if ($defined) { - $this->assertEquals($value, $template->getAttribute($object, $item, $arguments, $type)); - } else { - try { - $this->assertEquals($value, $template->getAttribute($object, $item, $arguments, $type)); - - throw new Exception('Expected Twig_Error_Runtime exception.'); - } catch (Twig_Error_Runtime $e) { - if (null !== $exceptionMessage) { - $this->assertSame($exceptionMessage, $e->getMessage()); - } - } - } - } - - /** - * @dataProvider getGetAttributeTests - */ - public function testGetAttributeDefined($defined, $value, $object, $item, $arguments, $type, $useExt = false) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), $useExt); - - $this->assertEquals($defined, $template->getAttribute($object, $item, $arguments, $type, true)); - } - - /** - * @dataProvider getGetAttributeTests - */ - public function testGetAttributeDefinedStrict($defined, $value, $object, $item, $arguments, $type, $useExt = false) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface'), array('strict_variables' => true)), $useExt); - - $this->assertEquals($defined, $template->getAttribute($object, $item, $arguments, $type, true)); - } - - /** - * @dataProvider getTestsDependingOnExtensionAvailability - */ - public function testGetAttributeCallExceptions($useExt = false) - { - $template = new Twig_TemplateTest(new Twig_Environment($this->getMock('Twig_LoaderInterface')), $useExt); - - $object = new Twig_TemplateMagicMethodExceptionObject(); - - $this->assertNull($template->getAttribute($object, 'foo')); - } - - public function getGetAttributeTests() - { - $array = array( - 'defined' => 'defined', - 'zero' => 0, - 'null' => null, - '1' => 1, - 'bar' => true, - '09' => '09', - '+4' => '+4', - ); - - $objectArray = new Twig_TemplateArrayAccessObject(); - $stdObject = (object) $array; - $magicPropertyObject = new Twig_TemplateMagicPropertyObject(); - $propertyObject = new Twig_TemplatePropertyObject(); - $propertyObject1 = new Twig_TemplatePropertyObjectAndIterator(); - $propertyObject2 = new Twig_TemplatePropertyObjectAndArrayAccess(); - $propertyObject3 = new Twig_TemplatePropertyObjectDefinedWithUndefinedValue(); - $methodObject = new Twig_TemplateMethodObject(); - $magicMethodObject = new Twig_TemplateMagicMethodObject(); - - $anyType = Twig_Template::ANY_CALL; - $methodType = Twig_Template::METHOD_CALL; - $arrayType = Twig_Template::ARRAY_CALL; - - $basicTests = array( - // array(defined, value, property to fetch) - array(true, 'defined', 'defined'), - array(false, null, 'undefined'), - array(false, null, 'protected'), - array(true, 0, 'zero'), - array(true, 1, 1), - array(true, 1, 1.0), - array(true, null, 'null'), - array(true, true, 'bar'), - array(true, '09', '09'), - array(true, '+4', '+4'), - ); - $testObjects = array( - // array(object, type of fetch) - array($array, $arrayType), - array($objectArray, $arrayType), - array($stdObject, $anyType), - array($magicPropertyObject, $anyType), - array($methodObject, $methodType), - array($methodObject, $anyType), - array($propertyObject, $anyType), - array($propertyObject1, $anyType), - array($propertyObject2, $anyType), - ); - - $tests = array(); - foreach ($testObjects as $testObject) { - foreach ($basicTests as $test) { - // properties cannot be numbers - if (($testObject[0] instanceof stdClass || $testObject[0] instanceof Twig_TemplatePropertyObject) && is_numeric($test[2])) { - continue; - } - - if ('+4' === $test[2] && $methodObject === $testObject[0]) { - continue; - } - - $tests[] = array($test[0], $test[1], $testObject[0], $test[2], array(), $testObject[1]); - } - } - - // additional properties tests - $tests = array_merge($tests, array( - array(true, null, $propertyObject3, 'foo', array(), $anyType), - )); - - // additional method tests - $tests = array_merge($tests, array( - array(true, 'defined', $methodObject, 'defined', array(), $methodType), - array(true, 'defined', $methodObject, 'DEFINED', array(), $methodType), - array(true, 'defined', $methodObject, 'getDefined', array(), $methodType), - array(true, 'defined', $methodObject, 'GETDEFINED', array(), $methodType), - array(true, 'static', $methodObject, 'static', array(), $methodType), - array(true, 'static', $methodObject, 'getStatic', array(), $methodType), - - array(true, '__call_undefined', $magicMethodObject, 'undefined', array(), $methodType), - array(true, '__call_UNDEFINED', $magicMethodObject, 'UNDEFINED', array(), $methodType), - )); - - // add the same tests for the any type - foreach ($tests as $test) { - if ($anyType !== $test[5]) { - $test[5] = $anyType; - $tests[] = $test; - } - } - - $methodAndPropObject = new Twig_TemplateMethodAndPropObject(); - - // additional method tests - $tests = array_merge($tests, array( - array(true, 'a', $methodAndPropObject, 'a', array(), $anyType), - array(true, 'a', $methodAndPropObject, 'a', array(), $methodType), - array(false, null, $methodAndPropObject, 'a', array(), $arrayType), - - array(true, 'b_prop', $methodAndPropObject, 'b', array(), $anyType), - array(true, 'b', $methodAndPropObject, 'B', array(), $anyType), - array(true, 'b', $methodAndPropObject, 'b', array(), $methodType), - array(true, 'b', $methodAndPropObject, 'B', array(), $methodType), - array(false, null, $methodAndPropObject, 'b', array(), $arrayType), - - array(false, null, $methodAndPropObject, 'c', array(), $anyType), - array(false, null, $methodAndPropObject, 'c', array(), $methodType), - array(false, null, $methodAndPropObject, 'c', array(), $arrayType), - - )); - - // tests when input is not an array or object - $tests = array_merge($tests, array( - array(false, null, 42, 'a', array(), $anyType, false, 'Impossible to access an attribute ("a") on a integer variable ("42")'), - array(false, null, 'string', 'a', array(), $anyType, false, 'Impossible to access an attribute ("a") on a string variable ("string")'), - array(false, null, array(), 'a', array(), $anyType, false, 'Key "a" does not exist as the array is empty'), - )); - - // add twig_template_get_attributes tests - - if (function_exists('twig_template_get_attributes')) { - foreach (array_slice($tests, 0) as $test) { - $test = array_pad($test, 7, null); - $test[6] = true; - $tests[] = $test; - } - } - - return $tests; - } -} - -class Twig_TemplateTest extends Twig_Template -{ - protected $useExtGetAttribute = false; - - public function __construct(Twig_Environment $env, $useExtGetAttribute = false) - { - parent::__construct($env); - $this->useExtGetAttribute = $useExtGetAttribute; - self::$cache = array(); - } - - public function getZero() - { - return 0; - } - - public function getEmpty() - { - return ''; - } - - public function getString() - { - return 'some_string'; - } - - public function getTrue() - { - return true; - } - - public function getTemplateName() - { - } - - public function getDebugInfo() - { - return array(); - } - - protected function doGetParent(array $context) - { - } - - protected function doDisplay(array $context, array $blocks = array()) - { - } - - public function getAttribute($object, $item, array $arguments = array(), $type = Twig_Template::ANY_CALL, $isDefinedTest = false, $ignoreStrictCheck = false) - { - if ($this->useExtGetAttribute) { - return twig_template_get_attributes($this, $object, $item, $arguments, $type, $isDefinedTest, $ignoreStrictCheck); - } else { - return parent::getAttribute($object, $item, $arguments, $type, $isDefinedTest, $ignoreStrictCheck); - } - } -} -/* */ -/* */ - -class Twig_TemplateArrayAccessObject implements ArrayAccess -{ - protected $protected = 'protected'; - - public $attributes = array( - 'defined' => 'defined', - 'zero' => 0, - 'null' => null, - '1' => 1, - 'bar' => true, - '09' => '09', - '+4' => '+4', - ); - - public function offsetExists($name) - { - return array_key_exists($name, $this->attributes); - } - - public function offsetGet($name) - { - return array_key_exists($name, $this->attributes) ? $this->attributes[$name] : null; - } - - public function offsetSet($name, $value) - { - } - - public function offsetUnset($name) - { - } -} - -class Twig_TemplateMagicPropertyObject -{ - public $defined = 'defined'; - - public $attributes = array( - 'zero' => 0, - 'null' => null, - '1' => 1, - 'bar' => true, - '09' => '09', - '+4' => '+4', - ); - - protected $protected = 'protected'; - - public function __isset($name) - { - return array_key_exists($name, $this->attributes); - } - - public function __get($name) - { - return array_key_exists($name, $this->attributes) ? $this->attributes[$name] : null; - } -} - -class Twig_TemplateMagicPropertyObjectWithException -{ - public function __isset($key) - { - throw new Exception('Hey! Don\'t try to isset me!'); - } -} - -class Twig_TemplatePropertyObject -{ - public $defined = 'defined'; - public $zero = 0; - public $null = null; - public $bar = true; - - protected $protected = 'protected'; -} - -class Twig_TemplatePropertyObjectAndIterator extends Twig_TemplatePropertyObject implements IteratorAggregate -{ - public function getIterator() - { - return new ArrayIterator(array('foo', 'bar')); - } -} - -class Twig_TemplatePropertyObjectAndArrayAccess extends Twig_TemplatePropertyObject implements ArrayAccess -{ - private $data = array(); - - public function offsetExists($offset) - { - return array_key_exists($offset, $this->data); - } - - public function offsetGet($offset) - { - return $this->offsetExists($offset) ? $this->data[$offset] : 'n/a'; - } - - public function offsetSet($offset, $value) - { - } - - public function offsetUnset($offset) - { - } -} - -class Twig_TemplatePropertyObjectDefinedWithUndefinedValue -{ - public $foo; - - public function __construct() - { - $this->foo = @$notExist; - } -} - -class Twig_TemplateMethodObject -{ - public function getDefined() - { - return 'defined'; - } - - public function get1() - { - return 1; - } - - public function get09() - { - return '09'; - } - - public function getZero() - { - return 0; - } - - public function getNull() - { - } - - public function isBar() - { - return true; - } - - protected function getProtected() - { - return 'protected'; - } - - public static function getStatic() - { - return 'static'; - } -} - -class Twig_TemplateMethodAndPropObject -{ - private $a = 'a_prop'; - public function getA() - { - return 'a'; - } - - public $b = 'b_prop'; - public function getB() - { - return 'b'; - } - - private $c = 'c_prop'; - private function getC() - { - return 'c'; - } -} - -class Twig_TemplateMagicMethodObject -{ - public function __call($method, $arguments) - { - return '__call_'.$method; - } -} - -class Twig_TemplateMagicMethodExceptionObject -{ - public function __call($method, $arguments) - { - throw new BadMethodCallException(sprintf('Unkown method %s', $method)); - } -} - -class CExtDisablingNodeVisitor implements Twig_NodeVisitorInterface -{ - public function enterNode(Twig_NodeInterface $node, Twig_Environment $env) - { - if ($node instanceof Twig_Node_Expression_GetAttr) { - $node->setAttribute('disable_c_ext', true); - } - - return $node; - } - - public function leaveNode(Twig_NodeInterface $node, Twig_Environment $env) - { - return $node; - } - - public function getPriority() - { - return 0; - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/TokenStreamTest.php b/vendor/twig/twig/test/Twig/Tests/TokenStreamTest.php deleted file mode 100644 index fd4ec6337..000000000 --- a/vendor/twig/twig/test/Twig/Tests/TokenStreamTest.php +++ /dev/null @@ -1,70 +0,0 @@ -isEOF()) { - $token = $stream->next(); - - $repr[] = $token->getValue(); - } - $this->assertEquals('1, 2, 3, 4, 5, 6, 7', implode(', ', $repr), '->next() advances the pointer and returns the current token'); - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedMessage Unexpected end of template - */ - public function testEndOfTemplateNext() - { - $stream = new Twig_TokenStream(array( - new Twig_Token(Twig_Token::BLOCK_START_TYPE, 1, 1), - )); - while (!$stream->isEOF()) { - $stream->next(); - } - } - - /** - * @expectedException Twig_Error_Syntax - * @expectedMessage Unexpected end of template - */ - public function testEndOfTemplateLook() - { - $stream = new Twig_TokenStream(array( - new Twig_Token(Twig_Token::BLOCK_START_TYPE, 1, 1), - )); - while (!$stream->isEOF()) { - $stream->look(); - $stream->next(); - } - } -} diff --git a/vendor/twig/twig/test/Twig/Tests/escapingTest.php b/vendor/twig/twig/test/Twig/Tests/escapingTest.php deleted file mode 100644 index 7b765caee..000000000 --- a/vendor/twig/twig/test/Twig/Tests/escapingTest.php +++ /dev/null @@ -1,320 +0,0 @@ - ''', - '"' => '"', - '<' => '<', - '>' => '>', - '&' => '&', - ); - - protected $htmlAttrSpecialChars = array( - '\'' => ''', - /* Characters beyond ASCII value 255 to unicode escape */ - 'Ā' => 'Ā', - /* Immune chars excluded */ - ',' => ',', - '.' => '.', - '-' => '-', - '_' => '_', - /* Basic alnums excluded */ - 'a' => 'a', - 'A' => 'A', - 'z' => 'z', - 'Z' => 'Z', - '0' => '0', - '9' => '9', - /* Basic control characters and null */ - "\r" => ' ', - "\n" => ' ', - "\t" => ' ', - "\0" => '�', // should use Unicode replacement char - /* Encode chars as named entities where possible */ - '<' => '<', - '>' => '>', - '&' => '&', - '"' => '"', - /* Encode spaces for quoteless attribute protection */ - ' ' => ' ', - ); - - protected $jsSpecialChars = array( - /* HTML special chars - escape without exception to hex */ - '<' => '\\x3C', - '>' => '\\x3E', - '\'' => '\\x27', - '"' => '\\x22', - '&' => '\\x26', - /* Characters beyond ASCII value 255 to unicode escape */ - 'Ā' => '\\u0100', - /* Immune chars excluded */ - ',' => ',', - '.' => '.', - '_' => '_', - /* Basic alnums excluded */ - 'a' => 'a', - 'A' => 'A', - 'z' => 'z', - 'Z' => 'Z', - '0' => '0', - '9' => '9', - /* Basic control characters and null */ - "\r" => '\\x0D', - "\n" => '\\x0A', - "\t" => '\\x09', - "\0" => '\\x00', - /* Encode spaces for quoteless attribute protection */ - ' ' => '\\x20', - ); - - protected $urlSpecialChars = array( - /* HTML special chars - escape without exception to percent encoding */ - '<' => '%3C', - '>' => '%3E', - '\'' => '%27', - '"' => '%22', - '&' => '%26', - /* Characters beyond ASCII value 255 to hex sequence */ - 'Ā' => '%C4%80', - /* Punctuation and unreserved check */ - ',' => '%2C', - '.' => '.', - '_' => '_', - '-' => '-', - ':' => '%3A', - ';' => '%3B', - '!' => '%21', - /* Basic alnums excluded */ - 'a' => 'a', - 'A' => 'A', - 'z' => 'z', - 'Z' => 'Z', - '0' => '0', - '9' => '9', - /* Basic control characters and null */ - "\r" => '%0D', - "\n" => '%0A', - "\t" => '%09', - "\0" => '%00', - /* PHP quirks from the past */ - ' ' => '%20', - '~' => '~', - '+' => '%2B', - ); - - protected $cssSpecialChars = array( - /* HTML special chars - escape without exception to hex */ - '<' => '\\3C ', - '>' => '\\3E ', - '\'' => '\\27 ', - '"' => '\\22 ', - '&' => '\\26 ', - /* Characters beyond ASCII value 255 to unicode escape */ - 'Ā' => '\\100 ', - /* Immune chars excluded */ - ',' => '\\2C ', - '.' => '\\2E ', - '_' => '\\5F ', - /* Basic alnums excluded */ - 'a' => 'a', - 'A' => 'A', - 'z' => 'z', - 'Z' => 'Z', - '0' => '0', - '9' => '9', - /* Basic control characters and null */ - "\r" => '\\D ', - "\n" => '\\A ', - "\t" => '\\9 ', - "\0" => '\\0 ', - /* Encode spaces for quoteless attribute protection */ - ' ' => '\\20 ', - ); - - protected $env; - - public function setUp() - { - $this->env = new Twig_Environment($this->getMock('Twig_LoaderInterface')); - } - - public function testHtmlEscapingConvertsSpecialChars() - { - foreach ($this->htmlSpecialChars as $key => $value) { - $this->assertEquals($value, twig_escape_filter($this->env, $key, 'html'), 'Failed to escape: '.$key); - } - } - - public function testHtmlAttributeEscapingConvertsSpecialChars() - { - foreach ($this->htmlAttrSpecialChars as $key => $value) { - $this->assertEquals($value, twig_escape_filter($this->env, $key, 'html_attr'), 'Failed to escape: '.$key); - } - } - - public function testJavascriptEscapingConvertsSpecialChars() - { - foreach ($this->jsSpecialChars as $key => $value) { - $this->assertEquals($value, twig_escape_filter($this->env, $key, 'js'), 'Failed to escape: '.$key); - } - } - - public function testJavascriptEscapingReturnsStringIfZeroLength() - { - $this->assertEquals('', twig_escape_filter($this->env, '', 'js')); - } - - public function testJavascriptEscapingReturnsStringIfContainsOnlyDigits() - { - $this->assertEquals('123', twig_escape_filter($this->env, '123', 'js')); - } - - public function testCssEscapingConvertsSpecialChars() - { - foreach ($this->cssSpecialChars as $key => $value) { - $this->assertEquals($value, twig_escape_filter($this->env, $key, 'css'), 'Failed to escape: '.$key); - } - } - - public function testCssEscapingReturnsStringIfZeroLength() - { - $this->assertEquals('', twig_escape_filter($this->env, '', 'css')); - } - - public function testCssEscapingReturnsStringIfContainsOnlyDigits() - { - $this->assertEquals('123', twig_escape_filter($this->env, '123', 'css')); - } - - public function testUrlEscapingConvertsSpecialChars() - { - foreach ($this->urlSpecialChars as $key => $value) { - $this->assertEquals($value, twig_escape_filter($this->env, $key, 'url'), 'Failed to escape: '.$key); - } - } - - /** - * Range tests to confirm escaped range of characters is within OWASP recommendation. - */ - - /** - * Only testing the first few 2 ranges on this prot. function as that's all these - * other range tests require. - */ - public function testUnicodeCodepointConversionToUtf8() - { - $expected = ' ~ޙ'; - $codepoints = array(0x20, 0x7e, 0x799); - $result = ''; - foreach ($codepoints as $value) { - $result .= $this->codepointToUtf8($value); - } - $this->assertEquals($expected, $result); - } - - /** - * Convert a Unicode Codepoint to a literal UTF-8 character. - * - * @param int $codepoint Unicode codepoint in hex notation - * - * @return string UTF-8 literal string - */ - protected function codepointToUtf8($codepoint) - { - if ($codepoint < 0x80) { - return chr($codepoint); - } - if ($codepoint < 0x800) { - return chr($codepoint >> 6 & 0x3f | 0xc0) - .chr($codepoint & 0x3f | 0x80); - } - if ($codepoint < 0x10000) { - return chr($codepoint >> 12 & 0x0f | 0xe0) - .chr($codepoint >> 6 & 0x3f | 0x80) - .chr($codepoint & 0x3f | 0x80); - } - if ($codepoint < 0x110000) { - return chr($codepoint >> 18 & 0x07 | 0xf0) - .chr($codepoint >> 12 & 0x3f | 0x80) - .chr($codepoint >> 6 & 0x3f | 0x80) - .chr($codepoint & 0x3f | 0x80); - } - throw new Exception('Codepoint requested outside of Unicode range'); - } - - public function testJavascriptEscapingEscapesOwaspRecommendedRanges() - { - $immune = array(',', '.', '_'); // Exceptions to escaping ranges - for ($chr = 0; $chr < 0xFF; ++$chr) { - if ($chr >= 0x30 && $chr <= 0x39 - || $chr >= 0x41 && $chr <= 0x5A - || $chr >= 0x61 && $chr <= 0x7A) { - $literal = $this->codepointToUtf8($chr); - $this->assertEquals($literal, twig_escape_filter($this->env, $literal, 'js')); - } else { - $literal = $this->codepointToUtf8($chr); - if (in_array($literal, $immune)) { - $this->assertEquals($literal, twig_escape_filter($this->env, $literal, 'js')); - } else { - $this->assertNotEquals( - $literal, - twig_escape_filter($this->env, $literal, 'js'), - "$literal should be escaped!"); - } - } - } - } - - public function testHtmlAttributeEscapingEscapesOwaspRecommendedRanges() - { - $immune = array(',', '.', '-', '_'); // Exceptions to escaping ranges - for ($chr = 0; $chr < 0xFF; ++$chr) { - if ($chr >= 0x30 && $chr <= 0x39 - || $chr >= 0x41 && $chr <= 0x5A - || $chr >= 0x61 && $chr <= 0x7A) { - $literal = $this->codepointToUtf8($chr); - $this->assertEquals($literal, twig_escape_filter($this->env, $literal, 'html_attr')); - } else { - $literal = $this->codepointToUtf8($chr); - if (in_array($literal, $immune)) { - $this->assertEquals($literal, twig_escape_filter($this->env, $literal, 'html_attr')); - } else { - $this->assertNotEquals( - $literal, - twig_escape_filter($this->env, $literal, 'html_attr'), - "$literal should be escaped!"); - } - } - } - } - - public function testCssEscapingEscapesOwaspRecommendedRanges() - { - // CSS has no exceptions to escaping ranges - for ($chr = 0; $chr < 0xFF; ++$chr) { - if ($chr >= 0x30 && $chr <= 0x39 - || $chr >= 0x41 && $chr <= 0x5A - || $chr >= 0x61 && $chr <= 0x7A) { - $literal = $this->codepointToUtf8($chr); - $this->assertEquals($literal, twig_escape_filter($this->env, $literal, 'css')); - } else { - $literal = $this->codepointToUtf8($chr); - $this->assertNotEquals( - $literal, - twig_escape_filter($this->env, $literal, 'css'), - "$literal should be escaped!"); - } - } - } -} diff --git a/vendor/twig/twig/test/bootstrap.php b/vendor/twig/twig/test/bootstrap.php deleted file mode 100644 index aecb976f7..000000000 --- a/vendor/twig/twig/test/bootstrap.php +++ /dev/null @@ -1,13 +0,0 @@ -