Full-featured ORM library for Golang with associations, hooks, transactions, migrations, and developer-friendly chainable API
Overall
score
81%
Build a user profile management system that models a one-to-one relationship between users and their profile information.
You need to create two related data structures:
User Model - represents a user with:
Profile Model - represents profile information with:
The relationship structure: each user has exactly one profile, and the profile belongs to that user.
Initialize an in-memory SQLite database and automatically migrate the models to create the necessary tables.
Provides object-relational mapping for database operations.
SQLite database driver for GORM.
Implement the solution in main.go with all required data structures and database operations. Include tests in main_test.go that verify the test cases above.
Install with Tessl CLI
npx tessl i tessl/golang-gorm-io--gormdocs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10