Improve tests in cadi-core