Skip to content

Proper template location order - #29827

Merged
DeepDiver1975 merged 1 commit into
masterfrom
fix-29628
Dec 15, 2017
Merged

DeepDiver1975 merged 1 commit into
masterfrom
fix-29628

Conversation

@VicDeo

@VicDeo VicDeo commented Dec 12, 2017 •

Copy link
Copy Markdown
Contributor

Description

List a templates directory from the active theme as the first possible template dir and from app/core/settings as the second

Related Issue

Fixes #29628

Motivation and Context

How Has This Been Tested?

By overriding core/settings/app templates from theme

A special test case was provided by @PVince81 in the related issue

Steps

  1. All kind of themes should be disabled.
  2. Setup ownCloud with two apps folders "apps" and "apps2"
  3. Install "customgroups" app version 0.3.1 into "apps"
  4. Install "customgroups" app version 0.3.5 into "apps2"
  5. occ app:enable customgroups
  6. run make test-php in apps2/customgroups

Expected result

tests are passing

Actual result

1) OCA\CustomGroups\Tests\unit\SettingsPanelTest::testGetPanel
Failed asserting that '
<div id="customgroups" class="section"></div>
' contains "<div id="customgroups" class="section" data-cancreategroups="true"></div>".

/srv/www/htdocs/owncloud/apps3/customgroups/tests/unit/SettingsPanelTest.php:50
/srv/www/htdocs/owncloud/apps3/customgroups/lib/composer/phpunit/phpunit/src/TextUI/Command.php:188
/srv/www/htdocs/owncloud/apps3/customgroups/lib/composer/phpunit/phpunit/src/TextUI/Command.php:118

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@VicDeo VicDeo added this to the development milestone Dec 12, 2017
@VicDeo VicDeo self-assigned this Dec 12, 2017
@codecov

codecov Bot commented Dec 13, 2017 •

Copy link
Copy Markdown

Codecov Report

Merging #29827 into master will increase coverage by <.01%.
The diff coverage is 95.23%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #29827      +/-   ##
============================================
+ Coverage     60.51%   60.52%   +<.01%     
- Complexity    18374    18379       +5     
============================================
  Files          1090     1090              
  Lines         60933    60943      +10     
============================================
+ Hits          36874    36883       +9     
- Misses        24059    24060       +1
Impacted Files Coverage Δ Complexity Δ
lib/private/legacy/template.php 44.65% <100%> (+0.7%) 39 <0> (+1) ⬆️
lib/private/Template/Base.php 73.58% <94.11%> (+2.47%) 17 <7> (+4) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f3c40fb...6489943. Read the comment docs.

@VicDeo
VicDeo force-pushed the fix-29628 branch 5 times, most recently from be9ac5e to a77bca4 Compare December 14, 2017 19:54
@VicDeo VicDeo changed the title [WIP] Proper template location order Proper template location order Dec 14, 2017
@VicDeo VicDeo added p2-high Escalation, on top of current planning, release blocker backport-request labels Dec 14, 2017
@VicDeo
VicDeo requested a review from PVince81 December 14, 2017 20:52

@PVince81 PVince81 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good 👍

@lock

lock Bot commented Aug 1, 2019

Copy link
Copy Markdown

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock Bot locked as resolved and limited conversation to collaborators Aug 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

3 - To Review p2-high Escalation, on top of current planning, release blocker

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Template resource locator troubles when app code exists twice

3 participants