(b *testing.B)
| 246 | } |
| 247 | |
| 248 | func BenchmarkObjectMapperSlice(b *testing.B) { |
| 249 | m := NewMapper() |
| 250 | var fromSlice []*FromStruct |
| 251 | var toSlice []*ToStruct |
| 252 | for i := 0; i < 10; i++ { |
| 253 | fromSlice = append(fromSlice, &FromStruct{Name: "From" + strconv.Itoa(i), Sex: true, AA: "AA" + strconv.Itoa(i)}) |
| 254 | } |
| 255 | for i := 0; i < b.N; i++ { |
| 256 | m.MapperSlice(fromSlice, &toSlice) |
| 257 | } |
| 258 | } |
| 259 | |
| 260 | func Test_Object_AutoMapper(t *testing.T) { |
| 261 | m := NewMapper() |
nothing calls this directly
no test coverage detected
searching dependent graphs…