On Thu, Dec 11, 2008 at 2:19 AM, Marcus <[EMAIL PROTECTED]> wrote:
>
> Same problem here. The error message "Database table not found"
> appeared with changeset 7870 of CakePHP.
>
So an earlier changeset might work for me?

> When calling ClassRegistry::init('Foo') in the startTest method of a
> test case, Cake tries to set up 'Foo' with all the associated models
> and fails when initializing the first related model: CakePHP reads the
> schema definition from database with wrong connection.
>

> When calling ClassRegistry::init('Foo'), Cake uses the 'default'
> connection for getting the schema for 'Foo' and everything works fine.
> Then the first related Model is initialized, CakePHP tries to read the
> schema, but now with the 'test_suite' connection, which raises the
> error because the table doesn't exist in the test database.
>

I poked around some more and I think I am seeing the same thing.

> Is this an error that should be filed to trac?
>
Nothing open in trac at the moment. perhaps a closed
> Marcus

On Thu, Dec 11, 2008 at 8:22 AM, mark_story <[EMAIL PROTECTED]> wrote:
>
> How are your fixtures setup?
        var $fixtures = array('app.form', 'app.program');

> Are you using imports?
App::import('Model', 'Form');

> Are you initializing your models in setup() or startTest()?
        function start() {
                parent::start();
                $this->Form = new TestForm();
        }

> Are you using ClassRegistry::init() or are you use new Model()?
Tried both. But it came with new Model();

It seems like a DB connection issue, as Marcus said. I wonder if it
work with models with no associations.

Ed
> >
>



-- 
Ed Howland
http://greenprogrammer.blogspot.com
http://twitter.com/ed_howland

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to