Skip to content

Commit

Permalink
fix: updated test description and context tag
Browse files Browse the repository at this point in the history
  • Loading branch information
adriangohjw committed May 21, 2024
1 parent 9fa72b1 commit 548c0a2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion spec/react_on_rails/shakapacker_utils_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

module ReactOnRails
describe ShakapackerUtils do
describe ".using_webapcker?" do
describe ".using_shakapacker?" do
subject do
described_class.using_shakapacker?
end
Expand Down
8 changes: 4 additions & 4 deletions spec/react_on_rails/utils_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ module ReactOnRails
allow(ReactOnRails::ShakapackerUtils).to receive(:using_shakapacker?).and_return(true)
end

context "when file in manifest", :webpacker do
context "when file in manifest", :shakapacker do
before do
# Note Shakapacker manifest lookup is inside of the public_output_path
# [2] (pry) ReactOnRails::ShakapackerUtils: 0> Shakapacker.manifest.lookup("app-bundle.js")
Expand Down Expand Up @@ -107,7 +107,7 @@ module ReactOnRails
.and_return(Pathname.new("public/webpack/development"))
end

context "with server file not in manifest", :webpacker do
context "with server file not in manifest", :shakapacker do
it "returns the unhashed server path" do
server_bundle_name = "server-bundle.js"
allow(ReactOnRails).to receive_message_chain("configuration.server_bundle_js_file")
Expand All @@ -122,7 +122,7 @@ module ReactOnRails
end
end

context "with server file in the manifest, used for client", :webpacker do
context "with server file in the manifest, used for client", :shakapacker do
it "returns the correct path hashed server path" do
allow(ReactOnRails).to receive_message_chain("configuration.server_bundle_js_file")
.and_return("webpack-bundle.js")
Expand Down Expand Up @@ -161,7 +161,7 @@ module ReactOnRails
end

context "with dev-server running, and server file in the manifest, and separate client/server files",
:webpacker do
:shakapacker do
it "returns the correct path hashed server path" do
allow(ReactOnRails).to receive_message_chain("configuration.server_bundle_js_file")
.and_return("server-bundle.js")
Expand Down

0 comments on commit 548c0a2

Please sign in to comment.