Sha256: 4dd7f44efeb67c9eacf9b75491c9f5cf823bfa19082ba4f3dc3a4cd5e591749d

Contents?: true

Size: 482 Bytes

Versions: 22

Compression:

Stored size: 482 Bytes

Contents

# frozen_string_literal: true

require_relative "../rails_helper"

describe "Hello World", js: true do
  it "the hello world example works" do
    visit "/hello_world"
    expect(heading).to have_text("Hello World")
    expect(message).to have_text("Stranger")
    name_input.set("John Doe")
    expect(message).to have_text("John Doe")
  end
end

private

def name_input
  page.first("input")
end

def message
  page.first(:css, "h3")
end

def heading
  page.first(:css, "h1")
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
react_on_rails-13.4.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.5 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.4 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.3 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.2 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.1 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.3.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.2.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.1.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.0.2 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.0.1 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.0.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-13.0.0.beta.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.6.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.5.2 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.5.1 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.5.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.4.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.4.0.rc.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb
react_on_rails-12.3.0 lib/generators/react_on_rails/templates/dev_tests/spec/system/hello_world_spec.rb