File tree Expand file tree Collapse file tree 1 file changed +18
-2
lines changed
src/test/java/com/ibm/watson/developer_cloud/alchemy/v1 Expand file tree Collapse file tree 1 file changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -89,6 +89,22 @@ public void testGetEntitiesHtml() {
8989 Assert .assertFalse (entities .getEntities ().isEmpty ());
9090 }
9191
92+ /**
93+ * Test Get entities HTML.
94+ */
95+ @ Test
96+ public void testGetEntitiesWithDifferentCharacters () {
97+ Map <String , Object > params = new HashMap <String , Object >();
98+ String text = "Mr. Vice President, my old colleague from Massachusetts" +
99+ "and your new Speaker & John McCormack, Members of the 87th Congress, " +
100+ "ladies and gentlemen: -.*&^%$#@!@#$%^&*()" ;
101+ params .put (AlchemyLanguage .TEXT , text );
102+
103+ Entities entities = service .getEntities (params );
104+ Assert .assertNotNull (entities );
105+ Assert .assertFalse (entities .getEntities ().isEmpty ());
106+ }
107+
92108 /**
93109 * Test Get keywords URL.
94110 */
@@ -319,10 +335,10 @@ public void testComboined() {
319335 public void testApiKeyIsNull () {
320336 Map <String , Object > params = new HashMap <String , Object >();
321337 params .put (AlchemyLanguage .URL , "http://www.techcrunch.com/" );
322-
338+
323339 AlchemyLanguage language = new AlchemyLanguage ();
324340 language .getKeywords (params );
325341 language .setApiKey (null );
326342 }
327-
343+
328344}
You can’t perform that action at this time.
0 commit comments