mirror of
https://github.com/System-End/hackatime.git
synced 2026-04-19 19:55:16 +00:00
* Fix data export + Capybara * Continue? * A ton of system tests :D + test cleanup * More system tests * Add placeholder keys for tests? * Get rid of the double-query! * Speed up CI Chrome setup by avoiding snap installs * Pin CI Chrome version to reduce system test flakiness * Stabilize integrations settings system test interaction
22 lines
658 B
Ruby
22 lines
658 B
Ruby
require "test_helper"
|
|
|
|
class DocsControllerTest < ActionDispatch::IntegrationTest
|
|
# -- docs show .md format --
|
|
|
|
test "docs show returns markdown content when requested with .md format" do
|
|
get "/docs/getting-started/quick-start.md"
|
|
|
|
assert_response :success
|
|
assert_match %r{text/markdown}, response.content_type
|
|
|
|
expected_content = File.read(Rails.root.join("docs", "getting-started", "quick-start.md"))
|
|
assert_equal expected_content, response.body
|
|
end
|
|
|
|
test "docs show returns HTML/Inertia by default" do
|
|
get "/docs/getting-started/quick-start"
|
|
|
|
assert_response :success
|
|
assert_inertia_component "Docs/Show"
|
|
end
|
|
end
|