Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
2609 Zobrazení
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
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
2
čvc 22
9101
1
čvn 21
2383
2
úno 21
299
5
zář 20
14263
4
čvn 20
49661