Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
erp5 erp5
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Labels
    • Labels
  • Merge requests 136
    • Merge requests 136
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Environments
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Jobs
  • Commits
Collapse sidebar
  • nexedi
  • erp5erp5
  • Merge requests
  • !1575

Merged
Created Mar 11, 2022 by Jérome Perrin@jeromeOwner

CodingStyle: verify that business template re-exporting is stable

  • Overview 4
  • Commits 13
  • Pipelines 9
  • Changes 84

re-exporting a business template that was just installed should not be different.

By having a test reporting diffs in export, we can detect changes in ERP5 or dependencies which would cause the business template format to become different. The primary reason for doing this was to make sure that on the way to Zope4 we don't have changes in exported data, especially lossly changes that would not be detected in test suite, but this is also good because it helps detecting changes that cause a difference in output - then if we introduce a change that cause different business template export, we also have to make a change to re-export everything to new format, which helps keeping the git history cleaner because there's one big commit with all the changes instead of having many small commits. This is also good because it detects mistakes when modifying business templates files directly with a text editor.

The test can be configured to ignore some paths, using fnmatch pattern (which unlike business patterns do not support ** for recursive match). This is also helpful when using this test case to check customer configuration business templates, where we may want to ignore some PathTemplateItem for conveniance.

This also include fix for almost all current cases where re-exporting produce a diff, except a few cases that the reason for the diff was not understood, they were added to the ignore list instead.

Edited Mar 14, 2022 by Jérome Perrin
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Source branch: feat/coding_style_rebuild
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7