]> git.sur5r.net Git - bacula/bacula/commitdiff
regress: Start to test configuration menu in bweb
authorEric Bollengier <eric@eb.homelinux.org>
Thu, 11 Mar 2010 17:37:46 +0000 (18:37 +0100)
committerEric Bollengier <eric@eb.homelinux.org>
Mon, 2 Aug 2010 14:49:39 +0000 (16:49 +0200)
regress/tests/bweb-test.pl

index 82e67a350982f78f3bc54197d57e83dd7e3d30cd..4dac4dfd95f55cc4b7aa8ffa9284824176425a8b 100755 (executable)
@@ -481,3 +481,25 @@ if ($part{overview}) {
     $sel->is_text_present_ok("backup");
     $sel->is_text_present_ok("Full Set");
 }
+
+if ($part{config}) {
+    $sel->open_ok("/cgi-bin/bweb/bweb.pl");
+    $sel->click_ok("link=Configuration");
+    $sel->wait_for_page_to_load_ok("30000");
+    $sel->is_text_present_ok("Main Configuration");
+
+    $sel->click_ok("//button[\@name='action' and \@value='edit_main_conf']");
+    $sel->wait_for_page_to_load_ok("30000");
+    $sel->is_text_present_ok("Main Configuration");
+    my $dbi = $sel->get_text("dbi");
+    my $user = $sel->get_text("user");
+    my $pass = $sel->get_text("password");
+    my $histo = $sel->get_text("stat_job_table");
+
+    print "dbi=$dbi histo=$histo\n";
+    if ($histo eq 'Job') {
+        $sel->type_ok("stat_job_table", "JobHisto");
+    } else {
+        $sel->type_ok("stat_job_table", "Job");
+    }
+}