1 package com.powerset.heritrix.writer.test;
2
3 import java.io.IOException;
4
5 import org.testng.Assert;
6 import org.testng.annotations.Test;
7
8 import com.powerset.heritrix.writer.HBaseWriter;
9
10
11
12
13
14 public class TestHBaseWriter {
15
16
17 String master = "localhost:60000";
18
19
20 String table = "test";
21
22
23 int poolMaximumActive = 10;
24
25
26 int poolMaximumWait = 20;
27
28
29 HBaseWriter hw;
30
31
32
33
34
35
36
37 @Test()
38 public void testCreateHBaseWriter() throws IOException {
39
40 try {
41 hw = new HBaseWriter(master, null);
42 Assert.assertNull(hw);
43 } catch (IllegalArgumentException e) {
44 Assert.assertNotNull(e);
45 }
46
47 try {
48 hw = new HBaseWriter(master, "");
49 Assert.assertNull(hw);
50 } catch (IllegalArgumentException e) {
51 Assert.assertNotNull(e);
52 }
53
54 }
55 }