Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions tests/update_has_many_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ import (
. "github.com/oracle-samples/gorm-oracle/tests/utils"

"gorm.io/gorm"
"gorm.io/gorm/clause"
)

func TestUpdateHasManyAssociations(t *testing.T) {
t.Skip()
user := *GetUser("update-has-many", Config{})

if err := DB.Create(&user).Error; err != nil {
Expand All @@ -67,7 +67,7 @@ func TestUpdateHasManyAssociations(t *testing.T) {
pet.Name += "new"
}

if err := DB.Save(&user).Error; err != nil {
if err := DB.Omit(clause.Associations).Save(&user).Error; err != nil {
t.Fatalf("errors happened when update: %v", err)
}

Expand Down Expand Up @@ -103,7 +103,7 @@ func TestUpdateHasManyAssociations(t *testing.T) {
user.Toys[idx].Name += "new"
}

if err := DB.Save(&user).Error; err != nil {
if err := DB.Omit(clause.Associations).Save(&user).Error; err != nil {
t.Fatalf("errors happened when update: %v", err)
}

Expand Down
Loading