Skip to content

Commit

Permalink
remove references to old repo
Browse files Browse the repository at this point in the history
  • Loading branch information
asahasrabuddhe committed Jul 27, 2022
1 parent 603f1c3 commit 2a20f20
Show file tree
Hide file tree
Showing 19 changed files with 38 additions and 34 deletions.
14 changes: 9 additions & 5 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion association_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"sort"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestBelongsTo(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion callbacks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"reflect"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func (s *Product) BeforeCreate() (err error) {
Expand Down
6 changes: 3 additions & 3 deletions create_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

"github.com/jinzhu/now"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestCreate(t *testing.T) {
Expand Down Expand Up @@ -303,11 +303,11 @@ func TestFixFullTableScanWhenInsertIgnore(t *testing.T) {

DB.Callback().Query().Register("gorm:fix_full_table_scan", func(scope *gorm.Scope) {
if strings.Contains(scope.SQL, "SELECT") && strings.Contains(scope.SQL, "pandas") && len(scope.SQLVars) == 0 {
t.Error("Should skip force reload when ignore duplicate panda insert")
t.Error("Should skip force reload when ignore duplicate panda insert")
}
})

if DB.Dialect().GetName() == "mysql" && DB.Set("gorm:insert_modifier", "IGNORE").Create(&pandaYuanYuan).Error != nil {
t.Error("Should ignore duplicate panda insert by insert modifier:IGNORE ")
}
}
}
2 changes: 1 addition & 1 deletion customize_column_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"testing"
"time"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

type CustomizeColumn struct {
Expand Down
2 changes: 1 addition & 1 deletion dialects/mssql/mssql.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
// Importing mssql driver package only in dialect file, otherwide not needed
_ "github.com/denisenkom/go-mssqldb"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func setIdentityInsert(scope *gorm.Scope) {
Expand Down
2 changes: 1 addition & 1 deletion errors_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"errors"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestErrorsCanBeUsedOutsideGorm(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion field_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"fmt"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

type CalculateField struct {
Expand Down
2 changes: 1 addition & 1 deletion join_table_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"testing"
"time"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

type Person struct {
Expand Down
8 changes: 4 additions & 4 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ const (
// db, err := gorm.Open("mysql", "user:password@/dbname?charset=utf8&parseTime=True&loc=Local")
// }
// GORM has wrapped some drivers, for easier to remember driver's import path, so you could import the mysql driver with
// import _ "github.com/jinzhu/gorm/dialects/mysql"
// // import _ "github.com/jinzhu/gorm/dialects/postgres"
// // import _ "github.com/jinzhu/gorm/dialects/sqlite"
// // import _ "github.com/jinzhu/gorm/dialects/mssql"
// import _ "github.com/projectleo/gorm/dialects/mysql"
// // import _ "github.com/projectleo/gorm/dialects/postgres"
// // import _ "github.com/projectleo/gorm/dialects/sqlite"
// // import _ "github.com/projectleo/gorm/dialects/mssql"
func Open(dialect string, args ...interface{}) (db *DB, err error) {
if len(args) == 0 {
err = errors.New("invalid database source")
Expand Down
11 changes: 6 additions & 5 deletions main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,13 @@ import (
"time"

"github.com/erikstmartin/go-testdb"
"github.com/jinzhu/gorm"
_ "github.com/jinzhu/gorm/dialects/mssql"
_ "github.com/jinzhu/gorm/dialects/mysql"
"github.com/jinzhu/gorm/dialects/postgres"
_ "github.com/jinzhu/gorm/dialects/sqlite"
"github.com/jinzhu/now"

"github.com/projectleo/gorm"
_ "github.com/projectleo/gorm/dialects/mssql"
_ "github.com/projectleo/gorm/dialects/mysql"
"github.com/projectleo/gorm/dialects/postgres"
_ "github.com/projectleo/gorm/dialects/sqlite"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion migration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"testing"
"time"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

type User struct {
Expand Down
2 changes: 1 addition & 1 deletion model_struct_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"sync"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

type ModelA struct {
Expand Down
2 changes: 1 addition & 1 deletion naming_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package gorm_test
import (
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestTheNamingStrategy(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion preload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"reflect"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func getPreloadUser(name string) *User {
Expand Down
5 changes: 2 additions & 3 deletions query_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ package gorm_test
import (
"fmt"
"reflect"

"github.com/jinzhu/gorm"

"testing"
"time"

"github.com/projectleo/gorm"
)

func TestFirstAndLast(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion scaner_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"errors"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestScannableSlices(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion scope_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"
"testing"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func NameIn1And2(d *gorm.DB) *gorm.DB {
Expand Down
2 changes: 1 addition & 1 deletion update_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"testing"
"time"

"github.com/jinzhu/gorm"
"github.com/projectleo/gorm"
)

func TestUpdate(t *testing.T) {
Expand Down

0 comments on commit 2a20f20

Please sign in to comment.