Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply pattern matching datasource config files #968

Merged
merged 2 commits into from
Jan 15, 2015
Merged

Apply pattern matching datasource config files #968

merged 2 commits into from
Jan 15, 2015

Conversation

Vinai
Copy link
Contributor

@Vinai Vinai commented Jan 14, 2015

The Magento\Ui\DataProvider\Config\FileResolver class currently uses the hardcoded pattern '/*/*/etc/data_source/*' to search for data source configuration files.
The method argument $filename, which contains the file pattern that should be matched, is not used.
Due to this temorarily excludng files by renaming them with a different file type ending is not possible.
For example

etc/data_source/customer.xml -> etc/data_source/customer.xml.off

This patch applies the specified file name pattern to the pattern.

The Magento\Ui\DataProvider\Config\FileResolver does not apply the
filename glob pattern passed to the method while matching files.
This test triggers the error.
@vpelipenko vpelipenko added the CS label Jan 15, 2015
/**
* @test
*/
public function itShouldApplyTheFilenamePattern()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It will be better to use "test" prefix at the beginning of name of this method, instead of "@test" in annotation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prefer to use the annotation, but if the prefix it policy then of course I'll use it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We suggest to use prefix. Thank you for fixing that.

The Magento\Ui\DataProvider\Config\FileResolver class currently
uses the hardcoded pattern '/*/*/etc/data_source/*' to search
for data source configuration files.
The method argument $filename, which contains the file pattern that should
be matched, is not used.
Due to this temorarily excludng files by renaming them
with a different file type ending is not possible.
For example

    etc/data_source/customer.xml -> etc/data_source/customer.xml.off

This patch applies the specified file name pattern to the pattern.
@vpelipenko
Copy link
Contributor

CR: passed
Builds: green
Resolution: OK to merge
Ticket: MAGETWO-32768

vpelipenko added a commit that referenced this pull request Jan 15, 2015
Apply pattern matching datasource config files
@vpelipenko vpelipenko merged commit 313019d into magento:develop Jan 15, 2015
magento-team pushed a commit that referenced this pull request Jan 16, 2015
…#968

- added copyright
- removed excess namespace aliases
SchumacherFM added a commit to SchumacherFM/magento2 that referenced this pull request Jan 16, 2015
…iREST

* upstream/develop: (149 commits)
  MAGETWO-31053: M2 GitHub Update (version 0.42.0-beta4)
  MAGETWO-31053: M2 GitHub Update (version 0.42.0-beta4)
  MAGETWO-32765: [GITHUB] Added 'status' command for cache cli cache script magento#949
  MAGETWO-32768: [GITHUB] Apply pattern matching datasource config files magento#968
  MAGETWO-32720: [GITHUB] Add integration test for View\Page\Config\Reader\Html magento#902
  Apply pattern matching datasource config files
  Add test to uncover glob pattern not being applied
  MAGETWO-32602: Almost all static tests are skipped in L3 Bamboo plan  - commit composer.lock
  MAGETWO-32602: Almost all static tests are skipped in L3 Bamboo plan
  Merge remote-tracking branch 'remotes/origin/MAGETWO-31559' into develop
  MAGETWO-32602: Almost all static tests are skipped in L3 Bamboo plan
  MAGETWO-32475: Create pull request for bug fixing
  Merge remote-tracking branch 'remotes/main/develop' into develop
  MAGETWO-26655: [TD] Compiler Can't Verify Case Sensitive Dependency
  Merge remote-tracking branch 'remotes/main/develop' into develop
  MAGETWO-32645: Fix L* builds failures
  MAGETWO-32645: Fix L* builds failures
  MAGETWO-32645: Fix L* builds failures
  MAGETWO-31999: oAuth issue [from github]
  MAGETWO-31999: oAuth issue [from github]
  ...

Conflicts:
	composer.lock
magento-team added a commit to buskamuza/magento2-community-edition that referenced this pull request Jan 20, 2015
* Various improvements:
    * Updated Copyright Notice and provided reference to the license file
    * Updated test framework to support stores other than default
    * Removed version information from theme.xml files leaving it only in composer.json files
* Fixed bugs:
    * Fixed an issue where coupon code was reported to be invalid if it has been removed from reorder in backend and then re-applied
    * Fixed an issue where the 'Guide to Using Sample Data' link was incorrect in the web setup UI
    * Fixed an issue where the link to System Requirements in bootstrap.php was incorrect
    * Fixed an issue where Compiler could not verify case sensitive dependency
    * Fixed an issue where the Recently Compared Products and Recently Viewed Products widgets were not displayed in sidebars
    * Fixed an issue where the Orders and Returns widget type contained unnecessary tab
    * Fixed an issue where an image added to a CMS page using the WYSIWYG editor was displayed as a broken link after turning off the allow_url_fopen parameter in php.ini
    * Fixed an issue where it was impossible to log in to the backend from the first attempt after changing Base URL
    * Fixed an issue where it was impossible to set back the default English (United States) interface locale for the admin user after changing it so an other value
    * Fixed an issue where it was possible to execute malicious JavaScript code in the context of website via the Sender Email parameter
    * Fixed an issue where the Product Stock Alert email was sent to a customer from a store view different than a customer account was created in
    * Fixed an issue where the "Server cannot understand Accept HTTP header media type" error message was not informative enough
    * Fixed an issue where unit tests did not work as expected after installing Magento 2
    * Fixed an issue where the password change email notification was sent after saving admin account settings even if password was not changed
    * Fixed an issue where static tests failed as a result of adding  API functional tests
    * Fixed API functional tests after merging pull request [#927](magento/magento2#927)
    * Fixed an issue where the Edit button was present for invoiced orders
    * Fixed an issue where function _underscore did not work with keys like SKeyName ('s_key_name')
    * Fixed an issue where a fatal error occurred when browsing categories if web server did not have write permissions for media/catalog/product
* Github requests:
    * [#792](magento/magento2#792) -- Failed to set ini option "session.save_path" to value
    * [#796](magento/magento2#796) -- install.log cannot be created with open_basedir restriction
    * [#823](magento/magento2#823) -- Installation bug
    * [#920](magento/magento2#920) -- "web setup wizard is not accessible" error message but the setup wizard is actually accessible
    * [#829](magento/magento2#829) -- [API] OAuth1.0 request token request failing / Consumer key has expired
    * [#658](magento/magento2#658) -- Inline translate malfunctioning
    * [#950](magento/magento2#950) -- Fix for the missed trailing end of line in indexer.php usage help text
    * [#932](magento/magento2#932) -- Migration tool - not all input has comments
    * [#959](magento/magento2#959) -- Replace UTF8 'en dash' with minus in error message
    * [#911](magento/magento2#911) -- Fix test assertion and slight cleanup refactoring
    * [#936](magento/magento2#936) -- Bugfix for regions with single quote in name
    * [#902](magento/magento2#902) -- Add integration test for View\Page\Config\Reader\Html
    * [#925](magento/magento2#925) -- Failed test due to Class not following the naming conventions
    * [#943](magento/magento2#943) -- magento2-925 Failed Test due to Class not following the naming conventions
    * [#968](magento/magento2#968) -- Apply pattern matching datasource config files
    * [#949](magento/magento2#949) -- Added 'status' command for cache cli script / Also improved readability
* PHP 5.6 in composer.json:
    * Added PHP 5.6.0 to the list of required PHP versions in all composer.json files
    * Updated Travis CI configuration to include PHP 5.6 builds
* Framework improvements:
    * Removed TODOs in the Integration and Authorization modules
    * Removed leading backslash from the 'use' statement throughout the code base
magento-team added a commit to buskamuza/magento2-community-edition that referenced this pull request Jan 20, 2015
* Various improvements:
    * Updated Copyright Notice and provided reference to the license file
    * Updated test framework to support stores other than default
    * Removed version information from theme.xml files leaving it only in composer.json files
* Fixed bugs:
    * Fixed an issue where coupon code was reported to be invalid if it has been removed from reorder in backend and then re-applied
    * Fixed an issue where the 'Guide to Using Sample Data' link was incorrect in the web setup UI
    * Fixed an issue where the link to System Requirements in bootstrap.php was incorrect
    * Fixed an issue where Compiler could not verify case sensitive dependency
    * Fixed an issue where the Recently Compared Products and Recently Viewed Products widgets were not displayed in sidebars
    * Fixed an issue where the Orders and Returns widget type contained unnecessary tab
    * Fixed an issue where an image added to a CMS page using the WYSIWYG editor was displayed as a broken link after turning off the allow_url_fopen parameter in php.ini
    * Fixed an issue where it was impossible to log in to the backend from the first attempt after changing Base URL
    * Fixed an issue where it was impossible to set back the default English (United States) interface locale for the admin user after changing it so an other value
    * Fixed an issue where it was possible to execute malicious JavaScript code in the context of website via the Sender Email parameter
    * Fixed an issue where the Product Stock Alert email was sent to a customer from a store view different than a customer account was created in
    * Fixed an issue where the "Server cannot understand Accept HTTP header media type" error message was not informative enough
    * Fixed an issue where unit tests did not work as expected after installing Magento 2
    * Fixed an issue where the password change email notification was sent after saving admin account settings even if password was not changed
    * Fixed an issue where static tests failed as a result of adding  API functional tests
    * Fixed API functional tests after merging pull request [#927](magento/magento2#927)
    * Fixed an issue where the Edit button was present for invoiced orders
    * Fixed an issue where function _underscore did not work with keys like SKeyName ('s_key_name')
    * Fixed an issue where a fatal error occurred when browsing categories if web server did not have write permissions for media/catalog/product
* Github requests:
    * [#792](magento/magento2#792) -- Failed to set ini option "session.save_path" to value
    * [#796](magento/magento2#796) -- install.log cannot be created with open_basedir restriction
    * [#823](magento/magento2#823) -- Installation bug
    * [#920](magento/magento2#920) -- "web setup wizard is not accessible" error message but the setup wizard is actually accessible
    * [#829](magento/magento2#829) -- [API] OAuth1.0 request token request failing / Consumer key has expired
    * [#658](magento/magento2#658) -- Inline translate malfunctioning
    * [#950](magento/magento2#950) -- Fix for the missed trailing end of line in indexer.php usage help text
    * [#932](magento/magento2#932) -- Migration tool - not all input has comments
    * [#959](magento/magento2#959) -- Replace UTF8 'en dash' with minus in error message
    * [#911](magento/magento2#911) -- Fix test assertion and slight cleanup refactoring
    * [#936](magento/magento2#936) -- Bugfix for regions with single quote in name
    * [#902](magento/magento2#902) -- Add integration test for View\Page\Config\Reader\Html
    * [#925](magento/magento2#925) -- Failed test due to Class not following the naming conventions
    * [#943](magento/magento2#943) -- magento2-925 Failed Test due to Class not following the naming conventions
    * [#968](magento/magento2#968) -- Apply pattern matching datasource config files
    * [#949](magento/magento2#949) -- Added 'status' command for cache cli script / Also improved readability
* PHP 5.6 in composer.json:
    * Added PHP 5.6.0 to the list of required PHP versions in all composer.json files
    * Updated Travis CI configuration to include PHP 5.6 builds
* Framework improvements:
    * Removed TODOs in the Integration and Authorization modules
    * Removed leading backslash from the 'use' statement throughout the code base
magento-team pushed a commit that referenced this pull request Mar 28, 2017
[East] MAGETWO-66470: Refactor catalog module 2.1.4 version data and schema update
magento-team pushed a commit that referenced this pull request Dec 12, 2017
 - Merge Pull Request magento-engcom/magento2ce#968 from nmalevanec/magento2:8011
 - Merged commits:
   1. 59cedcd
   2. 0c069a2
   3. 1e26ee8
magento-team pushed a commit that referenced this pull request Dec 12, 2017
EngCom] Public Pull Requests - 2.2-develop
 - MAGETWO-85520: Remove @escapenotverified from documentation #12639
 - MAGETWO-85317: 12526: Currency change, Bank Transfer but checkout page shows "Your credit card will be charged for" #993
 - MAGETWO-85298: 8011: Strip Tags from attribute. #968
 - MAGETWO-85294: 12535: Product change sku via repository. #984
 - MAGETWO-85274: Update CrontabManager.php #12610
 - MAGETWO-84994: 8862: Can't emptying values by magento 2 api #916
magento-engcom-team added a commit that referenced this pull request Oct 2, 2019
…gurable produ… #968

 - Merge Pull Request magento/graphql-ce#968 from magento/graphql-ce:MAGETWO-24676-adding-variation-from-another-configurable-product-to-cart
 - Merged commits:
   1. ae2e92b
   2. add6651
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants