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:
21
test/fixtures/parties.yml
vendored
Normal file
21
test/fixtures/parties.yml
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
# Read about fixtures at https://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
|
||||
|
||||
one:
|
||||
name: Summer Party
|
||||
description: A great summer party with music and drinks
|
||||
state: published
|
||||
venue_name: Beach Club
|
||||
venue_address: 123 Ocean Drive
|
||||
latitude: 40.7128
|
||||
longitude: -74.0060
|
||||
user: one
|
||||
|
||||
two:
|
||||
name: Winter Gala
|
||||
description: An elegant winter gala for the holidays
|
||||
state: draft
|
||||
venue_name: Grand Hotel
|
||||
venue_address: 456 Park Avenue
|
||||
latitude: 40.7589
|
||||
longitude: -73.9851
|
||||
user: two
|
||||
Reference in New Issue
Block a user