Skip to content

Commit a1ff509

Browse files
remove logging in alchemy test cases
1 parent 83c1ae6 commit a1ff509

File tree

3 files changed

+0
-42
lines changed

3 files changed

+0
-42
lines changed

src/test/java/com/ibm/watson/developer_cloud/alchemy/v1/AlchemyDataNewsTest.java

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
import java.util.HashMap;
1919
import java.util.Map;
20-
import java.util.logging.Logger;
2120

2221
import org.junit.Assert;
2322
import org.junit.Before;
@@ -33,11 +32,6 @@
3332
public class AlchemyDataNewsTest extends WatsonServiceTest {
3433

3534

36-
/**
37-
* The Constant log.
38-
*/
39-
private static final Logger log = Logger.getLogger(AlchemyDataNewsTest.class.getName());
40-
4135
/**
4236
* The service.
4337
*/
@@ -63,7 +57,6 @@ public void setUp() throws Exception {
6357
public void testGetCount() {
6458
VolumeResult result = service.getVolume("now-30", "now", null);
6559
Assert.assertNotNull(result);
66-
log.info(result.toString());
6760
}
6861

6962
/**
@@ -73,7 +66,6 @@ public void testGetCount() {
7366
public void testGetCountTimeSlice() {
7467
VolumeResult result = service.getVolume("now-7d", "now", "12h");
7568
Assert.assertNotNull(result);
76-
log.info(result.toString());
7769
}
7870

7971
/**
@@ -92,6 +84,5 @@ public void testNews() {
9284

9385
DocumentsResult result = service.getNewsDocuments(params);
9486
Assert.assertNotNull(result);
95-
log.info(result.toString());
9687
}
9788
}

src/test/java/com/ibm/watson/developer_cloud/alchemy/v1/AlchemyLanguageTest.java

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
import java.io.IOException;
2020
import java.util.HashMap;
2121
import java.util.Map;
22-
import java.util.logging.Logger;
2322

2423
import org.junit.Assert;
2524
import org.junit.Before;
@@ -50,9 +49,6 @@ public class AlchemyLanguageTest extends WatsonServiceTest {
5049
/** The html example. */
5150
private String htmlExample;
5251

53-
/** The Constant log. */
54-
private static final Logger log = Logger.getLogger(AlchemyLanguageTest.class.getName());
55-
5652
/*
5753
* (non-Javadoc)
5854
*
@@ -78,7 +74,6 @@ public void testGetEntitiesUrl() {
7874
Entities entities = service.getEntities(params);
7975
Assert.assertNotNull(entities);
8076
Assert.assertFalse(entities.getEntities().isEmpty());
81-
log.info(entities.toString());
8277
}
8378

8479
/**
@@ -92,8 +87,6 @@ public void testGetEntitiesHtml() {
9287
Entities entities = service.getEntities(params);
9388
Assert.assertNotNull(entities);
9489
Assert.assertFalse(entities.getEntities().isEmpty());
95-
log.info(entities.toString());
96-
9790
}
9891

9992
/**
@@ -106,7 +99,6 @@ public void testGetWordsUrl() {
10699
Keywords keywords = service.getKeywords(params);
107100
Assert.assertNotNull(keywords);
108101
Assert.assertFalse(keywords.getKeywords().isEmpty());
109-
log.info(keywords.toString());
110102
}
111103

112104
/**
@@ -123,7 +115,6 @@ public void testGetWordsHtml() throws IOException {
123115
Keywords keywords = service.getKeywords(params);
124116
Assert.assertNotNull(keywords);
125117
Assert.assertFalse(keywords.getKeywords().isEmpty());
126-
log.info(keywords.toString());
127118
}
128119

129120
/**
@@ -136,7 +127,6 @@ public void testGeTaxonomyUrl() {
136127
Taxonomies taxonomy = service.geTaxonomy(params);
137128
Assert.assertNotNull(taxonomy);
138129
Assert.assertFalse(taxonomy.getTaxonomy().isEmpty());
139-
log.info(taxonomy.toString());
140130
}
141131

142132
/**
@@ -152,7 +142,6 @@ public void testGeTaxonomyHtml() throws IOException {
152142
Taxonomies taxonomy = service.geTaxonomy(params);
153143
Assert.assertNotNull(taxonomy);
154144
Assert.assertFalse(taxonomy.getTaxonomy().isEmpty());
155-
log.info(taxonomy.toString());
156145
}
157146

158147
/**
@@ -164,7 +153,6 @@ public void testGetTextSentimentUrl() {
164153
params.put(AlchemyLanguage.URL, "http://www.techcrunch.com/");
165154
DocumentSentiment documentSentiment = service.getSentiment(params);
166155
Assert.assertNotNull(documentSentiment);
167-
log.info(documentSentiment.toString());
168156
}
169157

170158
/**
@@ -232,7 +220,6 @@ public void testGetRelationsHtml() throws IOException {
232220
params.put(AlchemyLanguage.HTML, htmlExample);
233221
SAORelations relations = service.getRelations(params);
234222
Assert.assertNotNull(relations);
235-
log.info(relations.toString());
236223
}
237224

238225
/**
@@ -244,7 +231,6 @@ public void testGetLanguage() {
244231
params.put(AlchemyLanguage.URL, "http://news.google.fr/");
245232
Language language = service.getLanguage(params);
246233
Assert.assertNotNull(language);
247-
log.info(language.toString());
248234
}
249235

250236
/**
@@ -256,7 +242,6 @@ public void testGetTitle() {
256242
params.put(AlchemyLanguage.URL, "http://www.techcrunch.com/");
257243
DocumentTitle title = service.getTitle(params);
258244
Assert.assertNotNull(title);
259-
log.info(title.toString());
260245
}
261246

262247
/**
@@ -269,7 +254,6 @@ public void testGetAuthors() {
269254
"http://www.politico.com/blogs/media/2012/02/detroit-news-ed-upset-over-romney-edit-115247.html");
270255
DocumentAuthors authors = service.getAuthors(params);
271256
Assert.assertNotNull(authors);
272-
log.info(authors.toString());
273257
}
274258

275259
/**
@@ -281,7 +265,6 @@ public void testText() {
281265
params.put(AlchemyLanguage.URL, "http://www.techcrunch.com/");
282266
DocumentText text = service.getText(params);
283267
Assert.assertNotNull(text);
284-
log.info(text.toString());
285268
}
286269

287270
/**
@@ -294,7 +277,6 @@ public void testRawText() {
294277
params.put(AlchemyLanguage.RAW, true);
295278
DocumentText text = service.getText(params);
296279
Assert.assertNotNull(text);
297-
log.info(text.toString());
298280
}
299281

300282
/**
@@ -306,7 +288,6 @@ public void testFeeds() {
306288
params.put(AlchemyLanguage.URL, "http://www.techcrunch.com/");
307289
Feeds feeds = service.getFeeds(params);
308290
Assert.assertNotNull(feeds);
309-
log.info(feeds.toString());
310291
}
311292

312293
/**
@@ -318,7 +299,6 @@ public void testMicroformats() {
318299
params.put(AlchemyLanguage.URL, "http://microformats.org/wiki/hcard");
319300
Microformats microformats = service.getMicroformats(params);
320301
Assert.assertNotNull(microformats);
321-
log.info(microformats.toString());
322302
}
323303

324304
/**
@@ -330,7 +310,6 @@ public void testComboined() {
330310
params.put(AlchemyLanguage.URL, "http://www.techcrunch.com/");
331311
CombinedResults combined = service.getCombinedResults(params);
332312
Assert.assertNotNull(combined);
333-
log.info(combined.toString());
334313
}
335314

336315
}

src/test/java/com/ibm/watson/developer_cloud/alchemy/v1/AlchemyVisionTest.java

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
import java.io.FileInputStream;
2020
import java.util.HashMap;
2121
import java.util.Map;
22-
import java.util.logging.Logger;
2322

2423
import org.junit.Assert;
2524
import org.junit.Before;
@@ -35,9 +34,6 @@
3534
*/
3635
public class AlchemyVisionTest extends WatsonServiceTest {
3736

38-
/** The Constant log. */
39-
private static final Logger log = Logger.getLogger(AlchemyVisionTest.class.getName());
40-
4137
/** The service. */
4238
private AlchemyVision service;
4339

@@ -67,7 +63,6 @@ public void testGetImageFromURL() {
6763
params.put(AlchemyVision.URL, "http://www.techcrunch.com/");
6864
ImageLink image = service.getImageLink(params);
6965
Assert.assertNotNull(image);
70-
log.info(image.toString());
7166
}
7267

7368
/**
@@ -79,7 +74,6 @@ public void testGetImageWithHTML() {
7974
params.put(AlchemyVision.HTML, htmlExample);
8075
ImageLink image = service.getImageLink(params);
8176
Assert.assertNotNull(image);
82-
log.info(image.toString());
8377
}
8478

8579
/**
@@ -92,7 +86,6 @@ public void testGetRankedImageKeywordsFromURL() {
9286
ImageKeywords image = service.getImageKeywords(params);
9387

9488
Assert.assertNotNull(image);
95-
log.info(image.toString());
9689
}
9790

9891
/**
@@ -106,7 +99,6 @@ public void testGetRankedImageKeywordsFromImage() {
10699
ImageKeywords image = service.getImageKeywords(params);
107100

108101
Assert.assertNotNull(image);
109-
log.info(image.toString());
110102

111103
}
112104

@@ -120,10 +112,8 @@ public void testRecognizeFacesFromURL() {
120112
ImageFaces image = service.recognizeFaces(params);
121113

122114
Assert.assertNotNull(image);
123-
log.info(image.toString());
124115
}
125116

126-
127117
/**
128118
* Test recognize faces from image.
129119
*/
@@ -135,7 +125,5 @@ public void testRecognizeFacesFromImage() {
135125
ImageFaces image = service.recognizeFaces(params);
136126

137127
Assert.assertNotNull(image);
138-
log.info(image.toString());
139-
140128
}
141129
}

0 commit comments

Comments
 (0)