Skip to content

Commit bf525f3

Browse files
authored
[5.x] CI fixes (#3106)
* Update ruby.yml * Update Gemfile-rails-edge * Update helper_test.rb
1 parent 8fa4f22 commit bf525f3

File tree

3 files changed

+22
-18
lines changed

3 files changed

+22
-18
lines changed

.github/workflows/ruby.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,6 @@ jobs:
2929
gemfile: gemfiles/Gemfile-rails.6.0.x
3030
experimental: [false]
3131
include:
32-
- ruby: 2.5
33-
os: ubuntu-latest
34-
gemfile: gemfiles/Gemfile-rails-edge
35-
experimental: true
36-
- ruby: 2.6
37-
os: ubuntu-latest
38-
gemfile: gemfiles/Gemfile-rails-edge
39-
experimental: true
4032
- ruby: 2.7
4133
os: ubuntu-latest
4234
gemfile: gemfiles/Gemfile-rails-edge

gemfiles/Gemfile-rails-edge

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ git_source(:github) { |repo| "https://github.com/#{repo}.git" }
44

55
gemspec path: "../"
66

7-
gem "rails", github: "rails/rails"
7+
gem "rails", github: "rails/rails", branch: "main"
88
gem "arel", github: "rails/arel"
99
gem "rake", ">= 11.1"
1010
gem "rack-proxy", require: false

test/helper_test.rb

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -117,29 +117,41 @@ def test_preload_pack_asset
117117
end
118118

119119
def test_stylesheet_pack_tag_split_chunks
120-
assert_equal \
121-
%(<link rel="stylesheet" media="screen" href="/packs/1-c20632e7baf2c81200d3.chunk.css" />\n) +
120+
assert_equal stylesheet_packs_with_chunks_tag("application", "hello_stimulus").in?([
121+
%(<link rel="stylesheet" href="/packs/1-c20632e7baf2c81200d3.chunk.css" media="screen" />\n) +
122+
%(<link rel="stylesheet" href="/packs/application-k344a6d59eef8632c9d1.chunk.css" media="screen" />\n) +
123+
%(<link rel="stylesheet" href="/packs/hello_stimulus-k344a6d59eef8632c9d1.chunk.css" media="screen" />),
124+
125+
%(<link rel="stylesheet" media="screen" href="/packs/1-c20632e7baf2c81200d3.chunk.css" />\n) +
122126
%(<link rel="stylesheet" media="screen" href="/packs/application-k344a6d59eef8632c9d1.chunk.css" />\n) +
123127
%(<link rel="stylesheet" media="screen" href="/packs/hello_stimulus-k344a6d59eef8632c9d1.chunk.css" />),
124-
stylesheet_packs_with_chunks_tag("application", "hello_stimulus")
128+
]),
129+
true
125130
end
126131

127132
def test_stylesheet_pack_tag
128-
assert_equal \
133+
assert_equal stylesheet_pack_tag("bootstrap.css").in?([
134+
%(<link rel="stylesheet" href="/packs/bootstrap-c38deda30895059837cf.css" media="screen" />),
135+
129136
%(<link rel="stylesheet" media="screen" href="/packs/bootstrap-c38deda30895059837cf.css" />),
130-
stylesheet_pack_tag("bootstrap.css")
137+
]), true
131138
end
132139

133140
def test_stylesheet_pack_tag_symbol
134-
assert_equal \
141+
assert_equal stylesheet_pack_tag(:bootstrap).in?([
142+
%(<link rel="stylesheet" href="/packs/bootstrap-c38deda30895059837cf.css" media="screen" />),
143+
135144
%(<link rel="stylesheet" media="screen" href="/packs/bootstrap-c38deda30895059837cf.css" />),
136-
stylesheet_pack_tag(:bootstrap)
145+
]), true
137146
end
138147

139148
def test_stylesheet_pack_tag_splat
140-
assert_equal \
149+
assert_equal stylesheet_pack_tag("bootstrap.css", "application.css", media: "all").in?([
150+
%(<link rel="stylesheet" href="/packs/bootstrap-c38deda30895059837cf.css" media="all" />\n) +
151+
%(<link rel="stylesheet" href="/packs/application-dd6b1cd38bfa093df600.css" media="all" />),
152+
141153
%(<link rel="stylesheet" media="all" href="/packs/bootstrap-c38deda30895059837cf.css" />\n) +
142154
%(<link rel="stylesheet" media="all" href="/packs/application-dd6b1cd38bfa093df600.css" />),
143-
stylesheet_pack_tag("bootstrap.css", "application.css", media: "all")
155+
]), true
144156
end
145157
end

0 commit comments

Comments
 (0)