I am not sure whether I miss something or what…
So I am using index-test.php to test my application.
I have separated database connection, in main application which declared in config/main.php connect to "xxx" database
while the other for testing purpose, declared in config/test.php connected to “xxx_test” database (both component using same name, ‘db’ )
There is no problem in using Active Record, it use the correct database. But when I use CDBCommand, somehow it use the "xxx" database, because it queried out the "xxx" database content instead of "xxx_test" database. Is it an expected result? Or is this a bug?