- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 43 for getUses (0.09 sec)
-
tests/benchmark_test.go
func BenchmarkCreate(b *testing.B) { user := *GetUser("bench", Config{}) for x := 0; x < b.N; x++ { user.ID = 0 DB.Create(&user) } } func BenchmarkFind(b *testing.B) { user := *GetUser("find", Config{}) DB.Create(&user) for x := 0; x < b.N; x++ { DB.Find(&User{}, "id = ?", user.ID) } } func BenchmarkScan(b *testing.B) { user := *GetUser("scan", Config{}) DB.Create(&user)
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 01 03:50:57 UTC 2022 - 1.5K bytes - Viewed (0) -
tests/delete_test.go
package tests_test import ( "errors" "testing" "gorm.io/gorm" "gorm.io/gorm/clause" . "gorm.io/gorm/utils/tests" ) func TestDelete(t *testing.T) { users := []User{*GetUser("delete", Config{}), *GetUser("delete", Config{}), *GetUser("delete", Config{})} if err := DB.Create(&users).Error; err != nil { t.Errorf("errors happened when create: %v", err) } for _, user := range users { if user.ID == 0 {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Tue Oct 10 07:03:34 UTC 2023 - 9.4K bytes - Viewed (0) -
tests/distinct_test.go
import ( "regexp" "testing" "gorm.io/gorm" . "gorm.io/gorm/utils/tests" ) func TestDistinct(t *testing.T) { users := []User{ *GetUser("distinct", Config{}), *GetUser("distinct", Config{}), *GetUser("distinct", Config{}), *GetUser("distinct-2", Config{}), *GetUser("distinct-3", Config{}), } users[0].Age = 20 if err := DB.Create(&users).Error; err != nil {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Jan 06 07:02:53 UTC 2022 - 2.5K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/app/web/api/admin/user/ApiAdminUserAction.java
* governing permissions and limitations under the License. */ package org.codelibs.fess.app.web.api.admin.user; import static org.codelibs.fess.app.web.admin.user.AdminUserAction.getUser; import static org.codelibs.fess.app.web.admin.user.AdminUserAction.validateAttributes; import java.util.List; import java.util.stream.Collectors; import org.apache.logging.log4j.LogManager;
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Feb 22 01:53:18 UTC 2024 - 5.8K bytes - Viewed (0) -
tests/associations_belongs_to_test.go
DB.Model(&users).Association("Manager").Append( GetUser("manager-slice-belongs-to-1", Config{}), GetUser("manager-slice-belongs-to-2", Config{}), GetUser("manager-slice-belongs-to-3", Config{}), ) AssertAssociationCount(t, users, "Manager", 3, "After Append") if err := DB.Model(&users).Association("Manager").Append( GetUser("manager-slice-belongs-to-test-1", Config{}), ).Error; err == nil {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Oct 30 09:15:49 UTC 2023 - 9.3K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/testers/SetEqualsTester.java
assertFalse( "Sets of different sizes should not be equal.", getSet().equals(MinimalSet.from(moreElements))); } public void testEquals_list() { assertFalse("A List should never equal a Set.", getSet().equals(copyToList(getSet()))); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 3.5K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/testers/SetEqualsTester.java
assertFalse( "Sets of different sizes should not be equal.", getSet().equals(MinimalSet.from(moreElements))); } public void testEquals_list() { assertFalse("A List should never equal a Set.", getSet().equals(copyToList(getSet()))); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 3.5K bytes - Viewed (0) -
tests/scopes_test.go
return func(d *gorm.DB) *gorm.DB { return d.Where("name in (?)", names) } } func TestScopes(t *testing.T) { users := []*User{ GetUser("ScopeUser1", Config{}), GetUser("ScopeUser2", Config{}), GetUser("ScopeUser3", Config{}), } DB.Create(&users) var users1, users2, users3 []User DB.Scopes(NameIn1And2).Find(&users1) if len(users1) != 2 {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Jan 12 08:42:21 UTC 2024 - 3.3K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/testers/SetAddAllTester.java
assertTrue( "add(somePresent) should return true", getSet().addAll(MinimalCollection.of(e3(), e0()))); expectAdded(e3()); } @CollectionFeature.Require(SUPPORTS_ADD) public void testAddAll_withDuplicates() { MinimalCollection<E> elementsToAdd = MinimalCollection.of(e3(), e4(), e3(), e4()); assertTrue("add(hasDuplicates) should return true", getSet().addAll(elementsToAdd)); expectAdded(e3(), e4()); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Jul 24 20:12:35 UTC 2024 - 2.3K bytes - Viewed (0) -
tests/count_test.go
t.Errorf("Count with group should be 2, but got count: %v", count2) } } func TestCount(t *testing.T) { var ( user1 = *GetUser("count-1", Config{}) user2 = *GetUser("count-2", Config{}) user3 = *GetUser("count-3", Config{}) users []User count, count1, count2 int64 ) DB.Save(&user1).Save(&user2).Save(&user3)
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Oct 30 09:15:49 UTC 2023 - 6.9K bytes - Viewed (0)