Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
2580 Prikazi
res = ''
vals = {
    
"name""test",
    
"partner_id"1000,
}
koko_base_config = 
self.env['koko.bn.mno']
res = koko_base_config.create(vals)
self.assertRaises(IntegrityError, res.write, vals)
This gives me:
psycopg2.IntegrityError: insert or update on table "koko_bn_mno" violates foreign key constraint "koko_bn_mno_partner_id_fkey"

How to handle it for running wrong testcase successfully?
Avatar
Opusti
Related Posts Odgovori Prikazi Aktivnost
2
jul. 22
9052
1
jun. 21
2324
2
feb. 21
299
5
sep. 20
14185
4
jun. 20
49626