- Sort Score
- Result 10 results
- Languages All
Results 671 - 680 of 1,733 for testFind (0.04 sec)
-
tests/submodel_test.go
package tests_test import ( "testing" "gorm.io/gorm" ) type Man struct { ID int Age int Name string Detail string } // Panic-safe BeforeUpdate hook that checks for Changed("age") func (m *Man) BeforeUpdate(tx *gorm.DB) (err error) { if !tx.Statement.Changed("age") { return nil } return nil } func TestSubModel(t *testing.T) { man := Man{Age: 18, Name: "random-name"}Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Mon Sep 08 09:19:22 UTC 2025 - 947 bytes - Viewed (0) -
schema/serializer_test.go
package schema import ( "context" "math" "reflect" "testing" "time" ) func TestUnixSecondSerializer_Value(t *testing.T) { var ( intValue = math.MaxInt64 int8Value = int8(math.MaxInt8) int16Value = int16(math.MaxInt16) int32Value = int32(math.MaxInt32) int64Value = int64(math.MaxInt64) uintValue = uint(math.MaxInt64) uint8Value = uint8(math.MaxUint8)
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Sun Oct 26 12:29:44 UTC 2025 - 4.8K bytes - Viewed (0) -
tests/gorm_test.go
package tests_test import ( "testing" "gorm.io/driver/mysql" "gorm.io/gorm" ) func TestOpen(t *testing.T) { dsn := "gorm:gorm@tcp(localhost:9910)/gorm?loc=Asia%2FHongKong" // invalid loc _, err := gorm.Open(mysql.Open(dsn), &gorm.Config{}) if err == nil { t.Fatalf("should returns error but got nil") } } func TestReturningWithNullToZeroValues(t *testing.T) { dialect := DB.Dialector.Name() switch dialect {
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Thu Jun 01 07:22:21 UTC 2023 - 3.3K bytes - Viewed (0) -
internal/store/store_test.go
// // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. package store import ( "testing" ) func TestKeyString(t *testing.T) { testCases := []struct { key Key expectedString string }{ { key: Key{ Name: "01894394-d046-4783-ba0d-f1c6885790dc", Extension: ".event", },
Registered: Sun Dec 28 19:28:13 UTC 2025 - Last Modified: Fri Sep 06 23:06:30 UTC 2024 - 4K bytes - Viewed (0) -
tests/postgres_test.go
package tests_test import ( "testing" "time" "github.com/google/uuid" "github.com/lib/pq" "gorm.io/gorm" "gorm.io/gorm/clause" . "gorm.io/gorm/utils/tests" ) func TestPostgresReturningIDWhichHasStringType(t *testing.T) { if DB.Dialector.Name() != "postgres" { t.Skip() } type Yasuo struct { ID string `gorm:"default:gen_random_uuid()"` Name string
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Sat Oct 08 09:16:32 UTC 2022 - 6.4K bytes - Viewed (0) -
tests/error_translator_test.go
package tests_test import ( "errors" "testing" "gorm.io/gorm" "gorm.io/gorm/utils/tests" ) func TestDialectorWithErrorTranslatorSupport(t *testing.T) { // it shouldn't translate error when the TranslateError flag is false translatedErr := errors.New("translated error") untranslatedErr := errors.New("some random error") db, _ := gorm.Open(tests.DummyDialector{TranslatedErr: translatedErr}) err := db.AddError(untranslatedErr)
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 3.1K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/TestMultisetGenerator.java
* See the License for the specific language governing permissions and * limitations under the License. */ package com.google.common.collect.testing.google; import com.google.common.annotations.GwtCompatible; import com.google.common.collect.Multiset; import com.google.common.collect.testing.TestCollectionGenerator; import org.jspecify.annotations.NullMarked; import org.jspecify.annotations.Nullable; /**
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Sun Dec 22 03:38:46 UTC 2024 - 1.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/SingletonImmutableMapWithUnhashableValueMapInterfaceTest.java
* limitations under the License. */ package com.google.common.collect; import com.google.common.annotations.GwtIncompatible; import com.google.common.collect.testing.SampleElements.Unhashables; import com.google.common.collect.testing.UnhashableObject; import java.util.Map; import org.jspecify.annotations.NullUnmarked; @GwtIncompatible // GWT's ImmutableMap emulation is backed by java.util.HashMap. @NullUnmarked
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Dec 19 18:03:30 UTC 2024 - 1.3K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/features/SetFeature.java
* See the License for the specific language governing permissions and * limitations under the License. */ package com.google.common.collect.testing.features; import static com.google.common.collect.testing.Helpers.copyToSet; import com.google.common.annotations.GwtCompatible; import java.lang.annotation.Inherited; import java.lang.annotation.Retention;
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Jan 30 16:59:10 UTC 2025 - 1.6K bytes - Viewed (0) -
cmd/endpoint_contrib_test.go
* See the License for the specific language governing permissions and * limitations under the License. */ package cmd import ( "testing" "github.com/minio/minio-go/v7/pkg/set" ) func TestUpdateDomainIPs(t *testing.T) { tempGlobalMinioPort := globalMinioPort defer func() { globalMinioPort = tempGlobalMinioPort }() globalMinioPort = "9000"
Registered: Sun Dec 28 19:28:13 UTC 2025 - Last Modified: Fri Apr 30 15:50:39 UTC 2021 - 2.2K bytes - Viewed (0)