1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-18 20:34:39 +01:00

Fix test compilation

This commit is contained in:
David Sansome 2010-06-02 16:58:34 +00:00
parent 6e19e777d8
commit 531fa90cbd
2 changed files with 8 additions and 6 deletions

View File

@ -34,8 +34,9 @@ class LibraryBackendTest : public ::testing::Test {
protected:
virtual void SetUp() {
database_.reset(new MemoryDatabase);
backend_.reset(new LibraryBackend(database_.get(), Library::kSongsTable,
Library::kDirsTable, Library::kSubdirsTable));
backend_.reset(new LibraryBackend);
backend_->Init(database_, Library::kSongsTable,
Library::kDirsTable, Library::kSubdirsTable);
}
Song MakeDummySong(int directory_id) {
@ -49,7 +50,7 @@ class LibraryBackendTest : public ::testing::Test {
return ret;
}
boost::scoped_ptr<Database> database_;
boost::shared_ptr<Database> database_;
boost::scoped_ptr<LibraryBackend> backend_;
};

View File

@ -33,8 +33,9 @@ class LibraryModelTest : public ::testing::Test {
protected:
void SetUp() {
database_.reset(new MemoryDatabase);
backend_.reset(new LibraryBackend(database_.get(), Library::kSongsTable,
Library::kDirsTable, Library::kSubdirsTable));
backend_.reset(new LibraryBackend());
backend_->Init(database_, Library::kSongsTable,
Library::kDirsTable, Library::kSubdirsTable);
model_.reset(new LibraryModel(backend_.get()));
added_dir_ = false;
@ -68,7 +69,7 @@ class LibraryModelTest : public ::testing::Test {
return AddSong(song);
}
boost::scoped_ptr<Database> database_;
boost::shared_ptr<Database> database_;
boost::scoped_ptr<LibraryBackend> backend_;
boost::scoped_ptr<LibraryModel> model_;
boost::scoped_ptr<QSortFilterProxyModel> model_sorted_;