1 package org.kuali.common.util.service;
2
3 import java.io.File;
4
5 import org.junit.Test;
6
7 public class DefaultMySqlDumpServiceTest {
8
9 @Test
10 public void test() {
11 try {
12 MySqlDumpContext context = new MySqlDumpContext();
13 context.setSkipLinePrefix(MySqlDumpService.SKIP_LINE_PREFIX);
14 context.setSkipLineSuffix(MySqlDumpService.SKIP_LINE_SUFFIX);
15 context.setUsername("JDBCTEST");
16 context.setPassword("JDBCTEST");
17 context.setHostname("mysql.rice.kuali.org");
18 context.setDatabase("JDBCTEST");
19 context.setOutputFile(new File("/tmp/mysqldump/jtest.sql"));
20 MySqlDumpService service = new DefaultMySqlDumpService();
21 service.dump(context);
22 } catch (Exception e) {
23 e.printStackTrace();
24 }
25
26 }
27
28 }