summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2013-05-31 02:52:06 +0000
committerTed Trask <ttrask01@yahoo.com>2013-05-31 02:52:06 +0000
commita769edbb0ed7402e2cf8af954efbfce246ee30d6 (patch)
tree4f77efe0360913a918ac45c0e02a719f8135c7d5
parent70c138e43c35d9c56bab89c9d2f953c9ba9be64e (diff)
downloadacf-weblog-a769edbb0ed7402e2cf8af954efbfce246ee30d6.tar.bz2
acf-weblog-a769edbb0ed7402e2cf8af954efbfce246ee30d6.tar.xz
Fix logon failure string and return test results on failure
-rw-r--r--weblog-model.lua8
1 files changed, 2 insertions, 6 deletions
diff --git a/weblog-model.lua b/weblog-model.lua
index cd515f7..b205c85 100644
--- a/weblog-model.lua
+++ b/weblog-model.lua
@@ -616,7 +616,7 @@ local connecttosource = function(source, cookiesfile)
local resultpage, errtxt = modelfunctions.run_executable({"wget", "-O", "-", "--no-check-certificate", "--save-cookies", cookiesfile, "--keep-session-cookies", "--post-file", cookiesfile, source.method.."://"..source.source.."/cgi-bin/acf/acf-util/logon/logon"})
if resultpage == "" then
logme("Failed to connect to "..source.sourcename)
- elseif string.find(resultpage, "/acf-util/logon/logon") then
+ elseif string.find(resultpage, "/acf%-util/logon/logon") then
logme("Failed to log on to "..source.sourcename)
else
success = true
@@ -901,11 +901,7 @@ function testsource(self, test)
os.remove(cookiesfile)
-- fix the result
- if test.errtxt then
- test.descr = nil
- else
- test.descr = table.concat(test.descr, "\n") or ""
- end
+ test.descr = table.concat(test.descr, "\n") or ""
logme = temp
return test