16470: Adds ArvadosModel test exposing a bug with audit logs.
authorLucas Di Pentima <lucas@di-pentima.com.ar>
Tue, 28 Jul 2020 16:55:50 +0000 (13:55 -0300)
committerLucas Di Pentima <lucas@di-pentima.com.ar>
Tue, 28 Jul 2020 16:55:50 +0000 (13:55 -0300)
commit9f3c3500b06fe1d02155d37be77fe78f8ffbd3d0
treeee30f615e74024c243c91e29ef21796e35f79ad6
parent571e9ea468feaa22ccf56b9585a36d6d84f1b8bd
16470: Adds ArvadosModel test exposing a bug with audit logs.

When audit logs are enabled, fetching objects from models with serialized
attributes (for example: User or ContainerRequest) return an unpersisted
instance even if reload() is called on it.
This is a problem because from Rails 5.2, lock!() and with_lock() will raise
an exception when called on unpersisted instances.

Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <lucas@di-pentima.com.ar>
services/api/test/unit/arvados_model_test.rb