We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fbf62a9 commit 165dd98Copy full SHA for 165dd98
processors_test.go
@@ -1029,3 +1029,22 @@ func TestAfterLoadProcessor(t *testing.T) {
1029
assert.NoError(t, bs[i].Err)
1030
}
1031
1032
+
1033
+type AfterInsertStruct struct {
1034
+ Id int64
1035
+}
1036
1037
+func (a *AfterInsertStruct) AfterInsert() {
1038
+ if a.Id == 0 {
1039
+ panic("a.Id")
1040
+ }
1041
1042
1043
+func TestAfterInsert(t *testing.T) {
1044
+ assert.NoError(t, prepareEngine())
1045
1046
+ assertSync(t, new(AfterInsertStruct))
1047
1048
+ _, err := testEngine.Insert(&AfterInsertStruct{})
1049
+ assert.NoError(t, err)
1050
0 commit comments