Skip to content

Commit 91588fe

Browse files
committed
Add System test example
1 parent a60002e commit 91588fe

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# frozen_string_literal: true
2+
3+
require "rails_helper"
4+
5+
RSpec.describe "InertiaExample", type: :system do
6+
it "renders the text and increments the counter" do
7+
visit inertia_example_path(name: "TestUser")
8+
9+
expect(page).to have_content("Hello TestUser!")
10+
expect(page).to have_content("count is 0")
11+
12+
find("button", text: "count is 0").click
13+
14+
expect(page).to have_content("count is 1")
15+
end
16+
end

0 commit comments

Comments
 (0)