This commit is contained in:
2025-11-07 13:34:32 -08:00
commit 1e8c5a972b
436 changed files with 11000 additions and 0 deletions

13
test/models/leaf_test.rb Normal file
View File

@@ -0,0 +1,13 @@
require "test_helper"
class LeafTest < ActiveSupport::TestCase
test "slug is generated from title" do
leaf = Leaf.new(title: "Hello, World!")
assert_equal "hello-world", leaf.slug
end
test "slug is never completely blank" do
leaf = Leaf.new(title: "")
assert_equal "-", leaf.slug
end
end