Fixed Google search test.

This commit is contained in:
Erik C. Thauvin 2021-05-04 17:57:47 -07:00
parent bd14a1e15e
commit bf985d5626
2 changed files with 6 additions and 6 deletions

View file

@ -47,9 +47,9 @@ class GoogleSearchTest : LocalProperties() {
val apiKey = getProperty(GoogleSearch.GOOGLE_API_KEY_PROP) val apiKey = getProperty(GoogleSearch.GOOGLE_API_KEY_PROP)
val cseKey = getProperty(GoogleSearch.GOOGLE_CSE_KEY_PROP) val cseKey = getProperty(GoogleSearch.GOOGLE_CSE_KEY_PROP)
try { try {
var messages = searchGoogle("mobibot site:github.com", apiKey, cseKey) var messages = searchGoogle("mobitopia", apiKey, cseKey)
assertThat(messages).`as`("mobibot results not empty").isNotEmpty assertThat(messages).`as`("mobitopia results not empty").isNotEmpty
assertThat(messages[0].msg).`as`("found mobitopia").contains("mobibot") assertThat(messages[0].msg).`as`("found freenode").contains("freenode")
messages = searchGoogle("aapl", apiKey, cseKey) messages = searchGoogle("aapl", apiKey, cseKey)
assertThat(messages).`as`("aapl results not empty").isNotEmpty assertThat(messages).`as`("aapl results not empty").isNotEmpty
assertThat(messages[0].msg).`as`("found apple").containsIgnoringCase("apple") assertThat(messages[0].msg).`as`("found apple").containsIgnoringCase("apple")

View file

@ -1,9 +1,9 @@
#Generated by the Semver Plugin for Gradle #Generated by the Semver Plugin for Gradle
#Tue May 04 11:01:30 PDT 2021 #Tue May 04 17:52:51 PDT 2021
version.buildmeta=610 version.buildmeta=618
version.major=0 version.major=0
version.minor=8 version.minor=8
version.patch=0 version.patch=0
version.prerelease=beta version.prerelease=beta
version.project=mobibot version.project=mobibot
version.semver=0.8.0-beta+610 version.semver=0.8.0-beta+618