Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 44 for latest (0.14 sec)

  1. tests/docker-compose.yml

    version: '3'
    
    services:
      mysql:
        image: 'mysql/mysql-server:latest'
        ports:
          - "9910:3306"
        environment:
          - MYSQL_DATABASE=gorm
          - MYSQL_USER=gorm
          - MYSQL_PASSWORD=gorm
          - MYSQL_RANDOM_ROOT_PASSWORD="yes"
      postgres:
        image: 'postgres:latest'
        ports:
          - "9920:5432"
        environment:
          - TZ=Asia/Shanghai
          - POSTGRES_DB=gorm
          - POSTGRES_USER=gorm
    Others
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Mar 18 08:28:46 GMT 2024
    - 862 bytes
    - Viewed (0)
  2. .github/workflows/tests.yml

      sqlserver:
        strategy:
          matrix:
            go: ['1.21', '1.20', '1.19']
            platform: [ubuntu-latest] # can not run test in macOS and windows
        runs-on: ${{ matrix.platform }}
    
        services:
          mssql:
            image: mcmoe/mssqldocker:latest
            env:
              ACCEPT_EULA: Y
              SA_PASSWORD: LoremIpsum86
              MSSQL_DB: gorm
              MSSQL_USER: gorm
    Others
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Jan 29 02:34:20 GMT 2024
    - 6.6K bytes
    - Viewed (0)
  3. .github/workflows/reviewdog.yml

    name: reviewdog
    on: [pull_request]
    jobs:
      golangci-lint:
        name: runner / golangci-lint
        runs-on: ubuntu-latest
        steps:
          - name: Check out code into the Go module directory
            uses: actions/checkout@v4
          - name: golangci-lint
            uses: reviewdog/action-golangci-lint@v2
    
          - name: Setup reviewdog
            uses: reviewdog/action-setup@v1
    
          - name: gofumpt -s with reviewdog
            env:
    Others
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Oct 10 06:50:45 GMT 2023
    - 664 bytes
    - Viewed (0)
  4. scan.go

    							for _, name := range names[1 : subNameCount-1] {
    								rel = rel.FieldSchema.Relationships.Relations[name]
    								relFields = append(relFields, rel.Field)
    							}
    							// lastest name is raw dbname
    							dbName := names[subNameCount-1]
    							if field := rel.FieldSchema.LookUpField(dbName); field != nil && field.Readable {
    								fields[idx] = field
    
    								if len(joinFields) == 0 {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Apr 26 09:53:11 GMT 2024
    - 9.8K bytes
    - Viewed (0)
  5. callbacks/helper_test.go

    		name   string
    		input  map[string]interface{}
    		expect clause.Values
    	}{
    		{
    			name: "Test convert string value",
    			input: map[string]interface{}{
    				"name": "my name",
    			},
    			expect: clause.Values{
    				Columns: []clause.Column{{Name: "name"}},
    				Values:  [][]interface{}{{"my name"}},
    			},
    		},
    		{
    			name: "Test convert int value",
    			input: map[string]interface{}{
    				"age": 18,
    			},
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Mar 05 02:22:57 GMT 2024
    - 3.4K bytes
    - Viewed (0)
  6. schema/relationship_test.go

    package schema_test
    
    import (
    	"sync"
    	"testing"
    
    	"gorm.io/gorm"
    	"gorm.io/gorm/schema"
    )
    
    func checkStructRelation(t *testing.T, data interface{}, relations ...Relation) {
    	if s, err := schema.Parse(data, &sync.Map{}, schema.NamingStrategy{}); err != nil {
    		t.Errorf("Failed to parse schema, got error %v", err)
    	} else {
    		for _, rel := range relations {
    			checkSchemaRelation(t, s, rel)
    		}
    	}
    }
    
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Apr 15 03:20:20 GMT 2024
    - 25.5K bytes
    - Viewed (0)
  7. tests/connpool_test.go

    package tests_test
    
    import (
    	"context"
    	"database/sql"
    	"os"
    	"reflect"
    	"testing"
    
    	"gorm.io/driver/mysql"
    	"gorm.io/gorm"
    	. "gorm.io/gorm/utils/tests"
    )
    
    type wrapperTx struct {
    	*sql.Tx
    	conn *wrapperConnPool
    }
    
    func (c *wrapperTx) PrepareContext(ctx context.Context, query string) (*sql.Stmt, error) {
    	c.conn.got = append(c.conn.got, query)
    	return c.Tx.PrepareContext(ctx, query)
    }
    
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Feb 06 02:54:40 GMT 2024
    - 5.5K bytes
    - Viewed (0)
  8. tests/count_test.go

    package tests_test
    
    import (
    	"fmt"
    	"regexp"
    	"sort"
    	"strings"
    	"testing"
    
    	"gorm.io/gorm"
    	. "gorm.io/gorm/utils/tests"
    )
    
    func TestCountWithGroup(t *testing.T) {
    	DB.Create([]Company{
    		{Name: "company_count_group_a"},
    		{Name: "company_count_group_a"},
    		{Name: "company_count_group_a"},
    		{Name: "company_count_group_b"},
    		{Name: "company_count_group_c"},
    	})
    
    	var count1 int64
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Oct 30 09:15:49 GMT 2023
    - 6.9K bytes
    - Viewed (0)
  9. tests/create_test.go

    package tests_test
    
    import (
    	"errors"
    	"fmt"
    	"regexp"
    	"testing"
    	"time"
    
    	"github.com/jinzhu/now"
    	"gorm.io/gorm"
    	"gorm.io/gorm/clause"
    	. "gorm.io/gorm/utils/tests"
    )
    
    func TestCreate(t *testing.T) {
    	user := *GetUser("create", Config{})
    
    	if results := DB.Create(&user); results.Error != nil {
    		t.Fatalf("errors happened when create: %v", results.Error)
    	} else if results.RowsAffected != 1 {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Mar 19 03:50:28 GMT 2024
    - 26.4K bytes
    - Viewed (0)
  10. tests/embedded_struct_test.go

    	}
    
    	now := time.Now().Round(time.Second)
    	NewPost := HNPost{
    		BasePost: &BasePost{Title: "embedded_pointer_type2"},
    		Author: &Author{
    			Name:        "test",
    			Content:     Content{"test"},
    			ContentPtr:  nil,
    			Birthday:    now,
    			BirthdayPtr: nil,
    		},
    	}
    	DB.Create(&NewPost)
    
    	hnPost = HNPost{}
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Oct 26 03:58:13 GMT 2023
    - 7.3K bytes
    - Viewed (0)
Back to top