Project

General

Profile

Actions

Bug #26612

closed

Renderer test suite do not like snippet-in-snippet

Added by Lukas Zapletal about 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Templates
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

When we include a snippet from a snippet, renderer test blows up:

Foreman::Exception: ERF42-7327 [Foreman::Exception]: The snippet 'pxegrub2_chainload' threw an error: The specified snippet 'pxegrub2_discovery' does not exist, or is not a snippet.
    lib/foreman/renderer/scope/macros/snippet_rendering.rb:18:in `snippet'
    lib/foreman/renderer/scope/macros/base.rb:56:in `indent'
    lib/foreman/renderer/unsafe_mode_renderer.rb:7:in `render'
    lib/foreman/renderer/base_renderer.rb:16:in `render'
    lib/foreman/renderer.rb:45:in `render'
    app/models/template.rb:173:in `render'
    lib/foreman/renderer/scope/macros/snippet_rendering.rb:24:in `snippet'
    lib/foreman/renderer/unsafe_mode_renderer.rb:7:in `render'
    lib/foreman/renderer/base_renderer.rb:16:in `render'
    lib/foreman/renderer.rb:45:in `render'
    test/unit/foreman/renderer_test.rb:48:in `render_template'
    test/unit/foreman/renderer_test.rb:40:in `assert_template'
    test/unit/foreman/renderer_test.rb:32:in `block (3 levels) in <class:RendererTest>' (Foreman::Exception)
/home/jenkins/workspace/test_develop_pr_core/database/postgresql/ruby/2.4/slave/fast/test/unit/foreman/renderer_test.rb:32    

Since it is blocking 1.22 branching I am creating this ticket and refactor templates until we can figure this out. The converstaion is at https://github.com/theforeman/foreman/pull/6678

Actions #1

Updated by The Foreman Bot about 5 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Timo Goebel
  • Pull request https://github.com/theforeman/foreman/pull/6687 added
Actions #2

Updated by Timo Goebel almost 5 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF