- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 22 for isSqlite (0.97 sec)
-
tests/helper_test.go
} } func isTiDB() bool { return os.Getenv("GORM_DIALECT") == "tidb" } func isMysql() bool { return os.Getenv("GORM_DIALECT") == "mysql" } func isSqlite() bool { return os.Getenv("GORM_DIALECT") == "sqlite" } func db(unscoped bool) *gorm.DB { if unscoped { return DB.Unscoped() } else { return DB }
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Tue Mar 19 03:50:28 UTC 2024 - 8K bytes - Viewed (0) -
tests/create_test.go
t.Fatal("failed to create data from map with table, @id != id") } } } func TestCreateFromMapWithTable(t *testing.T) { tableDB := DB.Table("users") supportLastInsertID := isMysql() || isSqlite() // case 1: create from map[string]interface{} record := map[string]interface{}{"name": "create_from_map_with_table", "age": 18} if err := tableDB.Create(record).Error; err != nil {
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 09:55:20 UTC 2025 - 26.8K bytes - Viewed (0) -
tests/tests_test.go
//go:debug x509negativeserial=1 package tests_test import ( "log" "math/rand" "os" "path/filepath" "time" "gorm.io/driver/gaussdb" "gorm.io/driver/mysql" "gorm.io/driver/postgres" "gorm.io/driver/sqlite" "gorm.io/driver/sqlserver" "gorm.io/gorm" "gorm.io/gorm/logger" . "gorm.io/gorm/utils/tests" ) var DB *gorm.DB var (
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 3.7K bytes - Viewed (0) -
tests/tests_all.sh
#!/bin/bash -e dialects=("sqlite" "mysql" "postgres" "gaussdb" "sqlserver" "tidb") if [[ $(pwd) == *"gorm/tests"* ]]; then cd .. fi if [ -d tests ] then cd tests go get -u -t ./... go mod download go mod tidy cd .. fi # SqlServer for Mac M1 if [[ -z $GITHUB_ACTION && -d tests ]]; then cd tests if [[ $(uname -a) == *" arm64" ]]; then
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 1.6K bytes - Viewed (0) -
tests/error_translator_test.go
Name string `gorm:"unique"` } db, err := OpenTestConnection(&gorm.Config{TranslateError: true}) if err != nil { t.Fatalf("failed to connect database, got error %v", err) } dialectors := map[string]bool{"sqlite": true, "postgres": true, "gaussdb": true, "mysql": true, "sqlserver": true} if supported, found := dialectors[db.Dialector.Name()]; !(found && supported) { return } DB.Migrator().DropTable(&City{})
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 3.1K bytes - Viewed (0) -
tests/multi_primary_keys_test.go
sort.Strings(contents) return reflect.DeepEqual(tagContents, contents) } func TestManyToManyWithMultiPrimaryKeys(t *testing.T) { if name := DB.Dialector.Name(); name == "sqlite" || name == "sqlserver" { t.Skip("skip sqlite, sqlserver due to it doesn't support multiple primary keys with auto increment") } if name := DB.Dialector.Name(); name == "postgres" || name == "mysql" || name == "gaussdb" {
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 13.1K bytes - Viewed (0) -
docs/pt/docs/tutorial/sql-databases.md
* PostgreSQL * MySQL * SQLite * Oracle * Microsoft SQL Server, etc. Neste exemplo, usaremos **SQLite**, porque ele usa um único arquivo e o Python tem suporte integrado. Assim, você pode copiar este exemplo e executá-lo como está.
Registered: Sun Sep 07 07:19:17 UTC 2025 - Last Modified: Sun Oct 27 15:25:29 UTC 2024 - 15.8K bytes - Viewed (0) -
tests/delete_test.go
t.Errorf("user's %v expects: %v, got %v", key, value, count) } } } // only sqlite, postgres, gaussdb, sqlserver support returning func TestSoftDeleteReturning(t *testing.T) { if DB.Dialector.Name() != "sqlite" && DB.Dialector.Name() != "postgres" && DB.Dialector.Name() != "gaussdb" && DB.Dialector.Name() != "sqlserver" { return } users := []*User{
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 9.5K bytes - Viewed (0) -
tests/go.mod
github.com/jinzhu/now v1.1.5 github.com/lib/pq v1.10.9 github.com/stretchr/testify v1.11.1 gorm.io/driver/gaussdb v0.1.0 gorm.io/driver/mysql v1.6.0 gorm.io/driver/postgres v1.6.0 gorm.io/driver/sqlite v1.6.0 gorm.io/driver/sqlserver v1.6.1 gorm.io/gorm v1.30.2 ) require ( filippo.io/edwards25519 v1.1.0 // indirect github.com/HuaweiCloudDeveloper/gaussdb-go v1.0.0-rc1 // indirect
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Thu Sep 04 13:13:16 UTC 2025 - 1.3K bytes - Viewed (0) -
.github/workflows/tests.yml
name: tests on: push: branches-ignore: - 'gh-pages' pull_request: branches-ignore: - 'gh-pages' permissions: contents: read jobs: # Label of the container job sqlite: strategy: matrix: go: ['1.23', '1.24'] platform: [ubuntu-latest] # can not run in windows OS runs-on: ${{ matrix.platform }} steps: - name: Set up Go 1.x
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 8.9K bytes - Viewed (0)