in a test setup, I'd like to sanity check that I'm...
# lucee
d
in a test setup, I'd like to sanity check that I'm pointing at the right db
Copy code
// throws 'Datasource defined in the application event handler has no name.'
getPageContext().getDataSource("foo").getDatabase()
is there a way to pull the db name out of a datasource definition?
z
how's the datasource defined?
d
sometimes all it takes is a little prodding (on this end I mean)
Copy code
this.datasources.foo = {
    class: '...',
    bundleName: '...',
    bundleVersion: '...',
    connectionString: "...databasename=...",
    username : dbUser,
    password : dbPass
}
i guess we never tell lucee what it is, we just provide a connection string