mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-14 03:39:53 +03:00
https://github.com/gohugoio/hugo/releases/tag/v0.147.2 https://github.com/gohugoio/hugo/releases Fix `TestVimeoShortcode` test, skip `TestSilenceDependencyDeprecations` test. ``` --- FAIL: TestVimeoShortcode (0.35s) shortcodes_integration_test.go:486: error: no substring match found [...] stack: github.com/gohugoio/hugo/hugolib/integrationtest_builder.go:323 <cannot parse source file: open github.com/gohugoio/hugo/hugolib/integrationtest_builder.go: no such file or directory> github.com/gohugoio/hugo/tpl/tplimpl/shortcodes_integration_test.go:486 <cannot parse source file: open github.com/gohugoio/hugo/tpl/tplimpl/shortcodes_integration_test.go: no such file or directory> FAIL FAIL github.com/gohugoio/hugo/tpl/tplimpl 2.804s ```
40 lines
2.1 KiB
Diff
40 lines
2.1 KiB
Diff
Patch-Source: https://github.com/gohugoio/hugo/commit/84d7a108e892e67cde43560606c125cff0f5b4cc
|
|
---
|
|
From 84d7a108e892e67cde43560606c125cff0f5b4cc Mon Sep 17 00:00:00 2001
|
|
From: Joe Mooring <joe@mooring.com>
|
|
Date: Fri, 9 May 2025 10:02:00 -0700
|
|
Subject: [PATCH] tpl/tplimpl: Fix vimeo shortcode test to accommodate API
|
|
changes
|
|
|
|
Fixes #13687
|
|
---
|
|
tpl/tplimpl/embedded/templates/_shortcodes/vimeo_simple.html | 2 +-
|
|
tpl/tplimpl/shortcodes_integration_test.go | 2 +-
|
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/tpl/tplimpl/embedded/templates/_shortcodes/vimeo_simple.html b/tpl/tplimpl/embedded/templates/_shortcodes/vimeo_simple.html
|
|
index 86a6dfc9f4c..2e5f882829c 100644
|
|
--- a/tpl/tplimpl/embedded/templates/_shortcodes/vimeo_simple.html
|
|
+++ b/tpl/tplimpl/embedded/templates/_shortcodes/vimeo_simple.html
|
|
@@ -37,7 +37,7 @@
|
|
{{- $thumbnail := .thumbnail_url -}}
|
|
{{- $original := $thumbnail | replaceRE "(_.*\\.)" "." -}}
|
|
<div class="{{ $class }}">
|
|
- <a href="{{ .provider_url }}{{ .video_id }}" rel="noopener" target="_blank">
|
|
+ <a href="{{ .provider_url }}{{ .video_id | string }}" rel="noopener" target="_blank">
|
|
<img src="{{ $thumbnail }}" srcset="{{ $thumbnail }} 1x, {{ $original }} 2x" alt="{{ .title }}">
|
|
<div class="play">
|
|
{{ template "__h_simple_icon_play" $.ctx.Page }}
|
|
diff --git a/tpl/tplimpl/shortcodes_integration_test.go b/tpl/tplimpl/shortcodes_integration_test.go
|
|
index 9d7af4a3da8..838dc16d745 100644
|
|
--- a/tpl/tplimpl/shortcodes_integration_test.go
|
|
+++ b/tpl/tplimpl/shortcodes_integration_test.go
|
|
@@ -495,7 +495,7 @@ Content: {{ .Content }}
|
|
// Simple mode
|
|
files = strings.ReplaceAll(files, "privacy.vimeo.simple = false", "privacy.vimeo.simple = true")
|
|
b = hugolib.Test(t, files)
|
|
- b.AssertFileContent("public/p1/index.html", "c5bf16d87e2a370b")
|
|
+ b.AssertFileContent("public/p1/index.html", "04d861fc957ee638")
|
|
|
|
// Simple mode with non-existent id
|
|
files = strings.ReplaceAll(files, "{{< vimeo 55073825 >}}", "{{< vimeo __id_does_not_exist__ >}}")
|