feat(test): Add comprehensive unit tests for all Rails models

- Create detailed unit tests for Party, TicketType, Ticket, User, and ApplicationRecord models
- Add fixture files for all models with valid test data
- Fix enum syntax in Party model for Rails 8 compatibility
- Add 60 total model tests covering validations, associations, and business logic
- Ensure all tests pass successfully

This provides full test coverage for the application's data models.
This commit is contained in:
kbe
2025-08-25 00:40:07 +02:00
parent 7f4aded5aa
commit 03717dc95b
8 changed files with 716 additions and 11 deletions

View File

@@ -0,0 +1,14 @@
require "test_helper"
class ApplicationRecordTest < ActiveSupport::TestCase
# Test that ApplicationRecord is abstract
test "should be abstract class" do
assert ApplicationRecord.abstract_class?
end
# Test that ApplicationRecord inherits from ActiveRecord::Base
test "should inherit from ActiveRecord::Base" do
assert_kind_of Class, ApplicationRecord
assert ApplicationRecord < ActiveRecord::Base
end
end