Package com.pugh.sockso.tests

Examples of com.pugh.sockso.tests.TestDatabase


       
    }
   
    public void testGetArtistsByLetterQuery() throws Exception {
       
        final Database db = new TestDatabase();
        final ByLetterer b = new ByLetterer();
       
        b.setDatabase( db );
        b.getArtistsByLetter( "A" );
       
View Full Code Here


   
    private MusicSearch search;
   
    @Override
    protected void setUp() throws Exception {
        db = new TestDatabase();
        db.fixture( "singleTrack" );
        db.fixture( "singlePlaylist" );
        search = new MusicSearch( db );
    }
View Full Code Here

    private User user;
   
    @Override
    public void setUp() throws Exception {
        user = new User( 1, "Foo" );
        db = new TestDatabase();
        db.fixture( "playlists" );
    }
View Full Code Here

       
    }

    public void testGetArtistAlbumsQuery() throws Exception {
       
        final Database db = new TestDatabase();
        final Artister b = new Artister();
       
        b.setDatabase( db );
        b.getArtistAlbums( -1 );
View Full Code Here

    }
   
    public void testGetArtistQuery() throws Exception {
       
        final Database db = new TestDatabase();
        final Artister b = new Artister();
       
        b.setDatabase( db );
        try {
            b.getArtist( -1 );
View Full Code Here

    private DefaultTreeModel model;
    private DefaultMutableTreeNode root;

    @Override
    public void setUp() throws Exception {
        TestDatabase db = new TestDatabase();
        db.fixture( "musicTree" );
        t = new MusicTree( db );
        t.init();
        model = (DefaultTreeModel) t.getModel();
        root = (DefaultMutableTreeNode) model.getRoot();
    }
View Full Code Here

        verify( rs );
       
    }
   
    public void testGetUsersQuery() throws Exception {
        final Database db = new TestDatabase();
        final HttpResponse res = new HttpResponse( null, db, p, null, null, false );
        res.getRecentUsers();
    }
View Full Code Here

import com.pugh.sockso.tests.TestDatabase;

public class PlaylistPanelTest extends SocksoTestCase {

    public void testCheckingPlaylistExists() throws Exception {
        TestDatabase db = new TestDatabase();
        PlaylistPanel p = new PlaylistPanel( null, db, null );
        db.fixture( "singlePlaylist" );
        assertTrue( p.playlistExists("Foo Bar") );
        assertFalse( p.playlistExists("Bar Foo") );
    }
View Full Code Here

    @Override
    public void setUp() {
        p = new StringProperties();
        p.set( Constants.WWW_BROWSE_FOLDERS_ENABLED, Properties.YES );
        db = new TestDatabase();
        res = new TestResponse();
        req = new TestRequest( "GET / HTTP/1.1" );
        js = new Jsoner( null, null );
        js.setRequest( req );
        js.setResponse( res );
View Full Code Here

    @Override
    public void setUp() {
        locale = new TestLocale();
        locale.setString( "con.msg.userCreated", "user added" );
        locale.setString( "con.err.usernameExists", "username exists" );
        db = new TestDatabase();
        cmd = new UserAdd( db, locale );
    }
View Full Code Here

TOP

Related Classes of com.pugh.sockso.tests.TestDatabase

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.