Package org.syncany.config

Examples of org.syncany.config.Config


   
    configTO.setMachineName("invalid machine name");
   
    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Machine name should not have been accepted.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("Machine name", e);     
    }     
View Full Code Here


   
    configTO.setMachineName(null); // <<< Invalid
     
    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Machine name should not have been accepted.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("Machine name", e);     
   
View Full Code Here

   
    repoTO.setMultiChunker(null); // <<< INVALID !!
       
    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Config should not been have initialized.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("No multichunker", e);     
    }   
View Full Code Here

    repoTO.setChunkerTO(null); // <<< INVALID !!

    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Config should not been have initialized.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("No multichunker", e);     
    }   
View Full Code Here

   
    repoTO.setTransformers(transformers); // <<< INVALID !
   
    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Transformer should NOT have been found.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("invalid-typeXXX", e);     
    }   
View Full Code Here

    transformers.add(invalidTransformerTO);
   
    repoTO.setTransformers(transformers); // <<< valid
   
    // Run!
    Config config = new Config(localDir, configTO, repoTO);
   
    // Test
    assertNotNull(config.getChunker());
    assertNotNull(config.getMultiChunker());
    assertNotNull(config.getTransformer());
    assertEquals("CipherTransformer", config.getTransformer().getClass().getSimpleName());
 
View Full Code Here

   
    repoTO.setTransformers(transformers);
   
    // Run!
    try {
      new Config(localDir, configTO, repoTO);
      fail("Transformer should NOT have been able to initialize.");
    }
    catch (ConfigException e) { 
      TestAssertUtil.assertErrorStackTraceContains("INVALIDXXXX", e);     
   
View Full Code Here

*/
public class FileVersionDaoTest
  @Test
  public void testFileVersionGetCurrentFileTree() throws Exception {
    // Setup
    Config testConfig = TestConfigUtil.createTestLocalConfig();
    Connection databaseConnection = testConfig.createDatabaseConnection();
       
    // Run
    TestSqlUtil.runSqlFromResource(databaseConnection, "test.insert.set2.sql");

    FileVersionSqlDao fileVersionDao = new FileVersionSqlDao(databaseConnection);       
View Full Code Here

  }
 
  @Test
  public void testFileVersionGetFileTreeAtDate() throws Exception {
    // Setup
    Config testConfig = TestConfigUtil.createTestLocalConfig();
    Connection databaseConnection = testConfig.createDatabaseConnection();
       
    // Run
    TestSqlUtil.runSqlFromResource(databaseConnection, "test.insert.set1.sql");

    FileVersionSqlDao fileVersionDao = new FileVersionSqlDao(databaseConnection);       
View Full Code Here

  }
 
  @Test
  public void testFileVersionGetByPath() throws Exception {
    // Setup
    Config testConfig = TestConfigUtil.createTestLocalConfig();
    Connection databaseConnection = testConfig.createDatabaseConnection();
       
    // Run
    TestSqlUtil.runSqlFromResource(databaseConnection, "test.insert.set1.sql");

    FileVersionSqlDao fileVersionDao = new FileVersionSqlDao(databaseConnection);       
View Full Code Here

TOP

Related Classes of org.syncany.config.Config

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.