From: rettenbe Date: Wed, 28 Oct 2009 09:14:49 +0000 (+0000) Subject: rearrangement of test directory X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=61ba8219132df5c3823619475d3deaad49b2e1cb;p=gosa.git rearrangement of test directory git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14666 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-si/tests/client.php b/gosa-si/tests/client.php index c9fde5ffd..c1c21443b 100755 --- a/gosa-si/tests/client.php +++ b/gosa-si/tests/client.php @@ -49,7 +49,7 @@ for($count = 1; $count <= $zahl; $count++) #$data = "
gosa_opsi_getSoftwareLicenseUsages
GOSA00:01:6C:9D:B9:FAkrakenarme.intranet.gonicus.de
"; #$data = "
gosa_opsi_getSoftwareLicenseUsages
GOSA00:01:6C:9D:B9:FALicensePool
"; #$data = "
gosa_opsi_getSoftwareLicenseUsages
GOSA00:01:6C:9D:B9:FA
"; - #$data = "
gosa_opsi_getSoftwareLicenseUsagesForProductId
GOSA00:01:6C:9D:B9:FAfirefox
"; + $data = "
gosa_opsi_getSoftwareLicenseUsagesForProductId
GOSA00:01:6C:9D:B9:FAfirefox
"; #$data = "
gosa_opsi_getSoftwareLicense_hash
GOSA00:01:6C:9D:B9:FAl_2009-09-22_09:50:58_0
"; @@ -114,7 +114,7 @@ for($count = 1; $count <= $zahl; $count++) # trigger jobs at client #$data = "
gosa_trigger_goto_settings_reload
00:01:6c:9d:b9:fa GOSA
"; #$data = "
gosa_detect_hardware
00:0C:29:4C:4B:0C GOSA
"; - $data = "
gosa_new_key_for_client
$mac GOSA $mac
"; + #$data = "
gosa_new_key_for_client
$mac GOSA $mac
"; #$data = "
gosa_trigger_action_wake
00:0C:29:4C:4B:0C GOSA
"; #$data = "
gosa_trigger_action_faireboot
00:0C:29:4C:4B:0C GOSA
"; #$data = "
gosa_trigger_action_reboot
00:0C:29:4C:4B:0C GOSA
"; diff --git a/gosa-si/tests/db-check-clients.pl b/gosa-si/tests/db-check-clients.pl deleted file mode 100755 index e3027465d..000000000 --- a/gosa-si/tests/db-check-clients.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "known_clients"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-fai-release.pl b/gosa-si/tests/db-check-fai-release.pl deleted file mode 100755 index ac4503dc4..000000000 --- a/gosa-si/tests/db-check-fai-release.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "fai_release"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-fai-server.pl b/gosa-si/tests/db-check-fai-server.pl deleted file mode 100755 index 1d6add484..000000000 --- a/gosa-si/tests/db-check-fai-server.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "fai_server"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-foreign-clients.pl b/gosa-si/tests/db-check-foreign-clients.pl deleted file mode 100755 index 95c420c9e..000000000 --- a/gosa-si/tests/db-check-foreign-clients.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "foreign_clients"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-incoming.pl b/gosa-si/tests/db-check-incoming.pl deleted file mode 100755 index 014b22c97..000000000 --- a/gosa-si/tests/db-check-incoming.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "incoming"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-jobs.pl b/gosa-si/tests/db-check-jobs.pl deleted file mode 100755 index 5ecbe49a9..000000000 --- a/gosa-si/tests/db-check-jobs.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "jobs"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-messaging.pl b/gosa-si/tests/db-check-messaging.pl deleted file mode 100755 index 08e45280a..000000000 --- a/gosa-si/tests/db-check-messaging.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "messaging"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-packages-list.pl b/gosa-si/tests/db-check-packages-list.pl deleted file mode 100755 index e99c5e068..000000000 --- a/gosa-si/tests/db-check-packages-list.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: sqlite_check_packages_list.pl -# -# USAGE: ./sqlite_check_packages_list.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 28.02.2008 11:09:15 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "packages_list"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-server.pl b/gosa-si/tests/db-check-server.pl deleted file mode 100755 index f0caeca3e..000000000 --- a/gosa-si/tests/db-check-server.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "known_server"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db-check-users.pl b/gosa-si/tests/db-check-users.pl deleted file mode 100755 index c86be7c31..000000000 --- a/gosa-si/tests/db-check-users.pl +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBmysql; -use Data::Dumper; - -print "START\n"; -my $table_name = "login_users"; - -print "\n############################################################\n"; -print "$table_name\n"; - -my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); - -my $col_names = $dbh->get_table_columns($table_name); -print join(', ', @{ $col_names } )."\n" ; - -my $answer = $dbh->show_table($table_name); -print $answer."\n"; - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-clients.pl b/gosa-si/tests/db/db-check-clients.pl new file mode 100755 index 000000000..e3027465d --- /dev/null +++ b/gosa-si/tests/db/db-check-clients.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "known_clients"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-fai-release.pl b/gosa-si/tests/db/db-check-fai-release.pl new file mode 100755 index 000000000..ac4503dc4 --- /dev/null +++ b/gosa-si/tests/db/db-check-fai-release.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "fai_release"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-fai-server.pl b/gosa-si/tests/db/db-check-fai-server.pl new file mode 100755 index 000000000..1d6add484 --- /dev/null +++ b/gosa-si/tests/db/db-check-fai-server.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "fai_server"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-foreign-clients.pl b/gosa-si/tests/db/db-check-foreign-clients.pl new file mode 100755 index 000000000..95c420c9e --- /dev/null +++ b/gosa-si/tests/db/db-check-foreign-clients.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "foreign_clients"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-incoming.pl b/gosa-si/tests/db/db-check-incoming.pl new file mode 100755 index 000000000..014b22c97 --- /dev/null +++ b/gosa-si/tests/db/db-check-incoming.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "incoming"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-jobs.pl b/gosa-si/tests/db/db-check-jobs.pl new file mode 100755 index 000000000..5ecbe49a9 --- /dev/null +++ b/gosa-si/tests/db/db-check-jobs.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "jobs"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-messaging.pl b/gosa-si/tests/db/db-check-messaging.pl new file mode 100755 index 000000000..08e45280a --- /dev/null +++ b/gosa-si/tests/db/db-check-messaging.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "messaging"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-packages-list.pl b/gosa-si/tests/db/db-check-packages-list.pl new file mode 100755 index 000000000..e99c5e068 --- /dev/null +++ b/gosa-si/tests/db/db-check-packages-list.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: sqlite_check_packages_list.pl +# +# USAGE: ./sqlite_check_packages_list.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 28.02.2008 11:09:15 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "packages_list"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-server.pl b/gosa-si/tests/db/db-check-server.pl new file mode 100755 index 000000000..f0caeca3e --- /dev/null +++ b/gosa-si/tests/db/db-check-server.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "known_server"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/db-check-users.pl b/gosa-si/tests/db/db-check-users.pl new file mode 100755 index 000000000..c86be7c31 --- /dev/null +++ b/gosa-si/tests/db/db-check-users.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBmysql; +use Data::Dumper; + +print "START\n"; +my $table_name = "login_users"; + +print "\n############################################################\n"; +print "$table_name\n"; + +my $dbh = GOSA::DBmysql->new('gosa_si', '127.0.0.1', 'gosa_si', 'gosa'); + +my $col_names = $dbh->get_table_columns($table_name); +print join(', ', @{ $col_names } )."\n" ; + +my $answer = $dbh->show_table($table_name); +print $answer."\n"; + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-clients.pl b/gosa-si/tests/db/sqlite-check-clients.pl new file mode 100755 index 000000000..218c91302 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-clients.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +print "START\n"; +my $res; +my $db_name; + +sub daemon_log {} + +$db_name = "/var/lib/gosa-si/clients.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "known_clients"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-concurrency.pl b/gosa-si/tests/db/sqlite-check-concurrency.pl new file mode 100755 index 000000000..ece1a356e --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-concurrency.pl @@ -0,0 +1,96 @@ +#!/usr/bin/perl -W + +package GOSA::DBsqlite; +use strict; +use warnings; + +use DBI; +use Data::Dumper; +use Time::HiRes qw(usleep); +use Fcntl ':flock'; +use threads; + + +sub daemon_log {} + +my %threads; +# Count of threads, if > 1 it corrupts the db +my $count= 10; +my $db_name= "./test.sqlite"; +my $lock = $db_name.".si.lock"; + +#if(stat($lock)) { +# unlink($lock); +#} +# +#if(stat($db_name)) { +# unlink($db_name) +#} + +for(my $i=0;$i<$count;$i++) { + $threads{$i}= threads->create(\&check_database); +} + +foreach my $thread (threads->list()) { + $thread->join(); +} + +sub check_database { + $threads{threads->self->tid()}= GOSA::DBsqlite->new($db_name); + threads->yield(); + $threads{threads->self->tid()}->run_test("test"); + + return; +} + +sub new { + my $class = shift; + my $db_name = shift; + + my $self = {dbh=>undef,db_name=>undef,db_lock=>undef,db_lock_handle=>undef}; + my $dbh = DBI->connect("dbi:SQLite:dbname=$db_name", "", "", {RaiseError => 1, AutoCommit => 1}); + $self->{dbh} = $dbh; + $self->{db_name} = $db_name; + $self->{db_lock} = $lock; + bless($self,$class); + return($self); +} + +sub lock { + my $self = shift; + open($self->{db_lock_handle}, ">>".($self->{db_lock})) unless ref $self->{db_lock_handle}; + flock($self->{db_lock_handle},LOCK_EX); + seek($self->{db_lock_handle}, 0, 2); +} + + +sub unlock { + my $self = shift; + flock($self->{db_lock_handle},LOCK_UN); +} + +sub run_test { + my $self= shift; + my $table_name= shift; + my $sql= "CREATE TABLE IF NOT EXISTS $table_name (id INTEGER PRIMARY KEY, status VARCHAR(255) DEFAULT 'none')"; + $self->lock(); + eval { + $self->{dbh}->do($sql); + }; + if($@) { + print STDERR Dumper($@); + } + $self->unlock(); + + for(my $i=0;$i<100;$i++) { + $sql= "INSERT INTO $table_name (id, status) VALUES (null, 'test $i')"; + $self->lock(); + eval { + $self->{dbh}->do($sql); + }; + if($@) { + print STDERR Dumper($@); + } + $self->unlock(); + } +} diff --git a/gosa-si/tests/db/sqlite-check-fai-release.pl b/gosa-si/tests/db/sqlite-check-fai-release.pl new file mode 100755 index 000000000..df90a7b96 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-fai-release.pl @@ -0,0 +1,45 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + +$db_name = "/var/lib/gosa-si/fai_release.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "fai_release"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-fai-server.pl b/gosa-si/tests/db/sqlite-check-fai-server.pl new file mode 100755 index 000000000..0e9c687b3 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-fai-server.pl @@ -0,0 +1,45 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + +$db_name = "/var/lib/gosa-si/fai_server.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "fai_server"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-foreign-clients.pl b/gosa-si/tests/db/sqlite-check-foreign-clients.pl new file mode 100755 index 000000000..61af80610 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-foreign-clients.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/foreign_clients.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "foreign_clients"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-incoming.pl b/gosa-si/tests/db/sqlite-check-incoming.pl new file mode 100755 index 000000000..e8fe202c5 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-incoming.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/incoming.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "incoming"; + print "$db_name\n"; + print "$table_name\n"; + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-jobs.pl b/gosa-si/tests/db/sqlite-check-jobs.pl new file mode 100755 index 000000000..5f6c0db49 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-jobs.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/jobs.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "jobs"; + print "$db_name\n"; + print "$table_name\n"; + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-messaging.pl b/gosa-si/tests/db/sqlite-check-messaging.pl new file mode 100755 index 000000000..075a915f6 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-messaging.pl @@ -0,0 +1,45 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; + + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/messaging.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "messaging"; + print "$db_name\n"; + print "$table_name\n"; + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-packages-list.pl b/gosa-si/tests/db/sqlite-check-packages-list.pl new file mode 100755 index 000000000..0b4433d46 --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-packages-list.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: sqlite_check_packages_list.pl +# +# USAGE: ./sqlite_check_packages_list.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 28.02.2008 11:09:15 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/packages.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "packages_list"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-server.pl b/gosa-si/tests/db/sqlite-check-server.pl new file mode 100755 index 000000000..6ef37571c --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-server.pl @@ -0,0 +1,46 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/servers.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "known_server"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + +print "\nFINISH\n"; diff --git a/gosa-si/tests/db/sqlite-check-users.pl b/gosa-si/tests/db/sqlite-check-users.pl new file mode 100755 index 000000000..fc6e0607d --- /dev/null +++ b/gosa-si/tests/db/sqlite-check-users.pl @@ -0,0 +1,47 @@ +#!/usr/bin/perl +#=============================================================================== +# +# FILE: DBD-SQlite.pl +# +# USAGE: ./DBD-SQlite.pl +# +# DESCRIPTION: +# +# OPTIONS: --- +# REQUIREMENTS: --- +# BUGS: --- +# NOTES: --- +# AUTHOR: (), <> +# COMPANY: +# VERSION: 1.0 +# CREATED: 20.12.2007 08:54:52 CET +# REVISION: --- +#=============================================================================== + +use strict; +use warnings; +use GOSA::DBsqlite; +use Data::Dumper; + +sub daemon_log {} +print "START\n"; +my $res; +my $db_name; + + +$db_name = "/var/lib/gosa-si/users.db"; +if (-e $db_name) { + print "\n############################################################\n"; + my $table_name = "login_users"; + print "$db_name\n"; + print "$table_name\n"; + + my $sqlite = GOSA::DBsqlite->new($db_name); + my $col_names = $sqlite->get_table_columns($table_name); + print join(', ', @{ $col_names } )."\n" ; + my $answer = $sqlite->show_table($table_name); + print $answer."\n"; +} + + +print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-clients.pl b/gosa-si/tests/sqlite-check-clients.pl deleted file mode 100755 index 218c91302..000000000 --- a/gosa-si/tests/sqlite-check-clients.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -print "START\n"; -my $res; -my $db_name; - -sub daemon_log {} - -$db_name = "/var/lib/gosa-si/clients.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "known_clients"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-concurrency.pl b/gosa-si/tests/sqlite-check-concurrency.pl deleted file mode 100755 index ece1a356e..000000000 --- a/gosa-si/tests/sqlite-check-concurrency.pl +++ /dev/null @@ -1,96 +0,0 @@ -#!/usr/bin/perl -W - -package GOSA::DBsqlite; -use strict; -use warnings; - -use DBI; -use Data::Dumper; -use Time::HiRes qw(usleep); -use Fcntl ':flock'; -use threads; - - -sub daemon_log {} - -my %threads; -# Count of threads, if > 1 it corrupts the db -my $count= 10; -my $db_name= "./test.sqlite"; -my $lock = $db_name.".si.lock"; - -#if(stat($lock)) { -# unlink($lock); -#} -# -#if(stat($db_name)) { -# unlink($db_name) -#} - -for(my $i=0;$i<$count;$i++) { - $threads{$i}= threads->create(\&check_database); -} - -foreach my $thread (threads->list()) { - $thread->join(); -} - -sub check_database { - $threads{threads->self->tid()}= GOSA::DBsqlite->new($db_name); - threads->yield(); - $threads{threads->self->tid()}->run_test("test"); - - return; -} - -sub new { - my $class = shift; - my $db_name = shift; - - my $self = {dbh=>undef,db_name=>undef,db_lock=>undef,db_lock_handle=>undef}; - my $dbh = DBI->connect("dbi:SQLite:dbname=$db_name", "", "", {RaiseError => 1, AutoCommit => 1}); - $self->{dbh} = $dbh; - $self->{db_name} = $db_name; - $self->{db_lock} = $lock; - bless($self,$class); - return($self); -} - -sub lock { - my $self = shift; - open($self->{db_lock_handle}, ">>".($self->{db_lock})) unless ref $self->{db_lock_handle}; - flock($self->{db_lock_handle},LOCK_EX); - seek($self->{db_lock_handle}, 0, 2); -} - - -sub unlock { - my $self = shift; - flock($self->{db_lock_handle},LOCK_UN); -} - -sub run_test { - my $self= shift; - my $table_name= shift; - my $sql= "CREATE TABLE IF NOT EXISTS $table_name (id INTEGER PRIMARY KEY, status VARCHAR(255) DEFAULT 'none')"; - $self->lock(); - eval { - $self->{dbh}->do($sql); - }; - if($@) { - print STDERR Dumper($@); - } - $self->unlock(); - - for(my $i=0;$i<100;$i++) { - $sql= "INSERT INTO $table_name (id, status) VALUES (null, 'test $i')"; - $self->lock(); - eval { - $self->{dbh}->do($sql); - }; - if($@) { - print STDERR Dumper($@); - } - $self->unlock(); - } -} diff --git a/gosa-si/tests/sqlite-check-fai-release.pl b/gosa-si/tests/sqlite-check-fai-release.pl deleted file mode 100755 index df90a7b96..000000000 --- a/gosa-si/tests/sqlite-check-fai-release.pl +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - -$db_name = "/var/lib/gosa-si/fai_release.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "fai_release"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-fai-server.pl b/gosa-si/tests/sqlite-check-fai-server.pl deleted file mode 100755 index 0e9c687b3..000000000 --- a/gosa-si/tests/sqlite-check-fai-server.pl +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - -$db_name = "/var/lib/gosa-si/fai_server.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "fai_server"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-foreign-clients.pl b/gosa-si/tests/sqlite-check-foreign-clients.pl deleted file mode 100755 index 61af80610..000000000 --- a/gosa-si/tests/sqlite-check-foreign-clients.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/foreign_clients.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "foreign_clients"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-incoming.pl b/gosa-si/tests/sqlite-check-incoming.pl deleted file mode 100755 index e8fe202c5..000000000 --- a/gosa-si/tests/sqlite-check-incoming.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/incoming.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "incoming"; - print "$db_name\n"; - print "$table_name\n"; - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-jobs.pl b/gosa-si/tests/sqlite-check-jobs.pl deleted file mode 100755 index 5f6c0db49..000000000 --- a/gosa-si/tests/sqlite-check-jobs.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/jobs.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "jobs"; - print "$db_name\n"; - print "$table_name\n"; - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-messaging.pl b/gosa-si/tests/sqlite-check-messaging.pl deleted file mode 100755 index 075a915f6..000000000 --- a/gosa-si/tests/sqlite-check-messaging.pl +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; - - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/messaging.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "messaging"; - print "$db_name\n"; - print "$table_name\n"; - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-packages-list.pl b/gosa-si/tests/sqlite-check-packages-list.pl deleted file mode 100755 index 0b4433d46..000000000 --- a/gosa-si/tests/sqlite-check-packages-list.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: sqlite_check_packages_list.pl -# -# USAGE: ./sqlite_check_packages_list.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 28.02.2008 11:09:15 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/packages.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "packages_list"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-server.pl b/gosa-si/tests/sqlite-check-server.pl deleted file mode 100755 index 6ef37571c..000000000 --- a/gosa-si/tests/sqlite-check-server.pl +++ /dev/null @@ -1,46 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/servers.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "known_server"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - -print "\nFINISH\n"; diff --git a/gosa-si/tests/sqlite-check-users.pl b/gosa-si/tests/sqlite-check-users.pl deleted file mode 100755 index fc6e0607d..000000000 --- a/gosa-si/tests/sqlite-check-users.pl +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/perl -#=============================================================================== -# -# FILE: DBD-SQlite.pl -# -# USAGE: ./DBD-SQlite.pl -# -# DESCRIPTION: -# -# OPTIONS: --- -# REQUIREMENTS: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: (), <> -# COMPANY: -# VERSION: 1.0 -# CREATED: 20.12.2007 08:54:52 CET -# REVISION: --- -#=============================================================================== - -use strict; -use warnings; -use GOSA::DBsqlite; -use Data::Dumper; - -sub daemon_log {} -print "START\n"; -my $res; -my $db_name; - - -$db_name = "/var/lib/gosa-si/users.db"; -if (-e $db_name) { - print "\n############################################################\n"; - my $table_name = "login_users"; - print "$db_name\n"; - print "$table_name\n"; - - my $sqlite = GOSA::DBsqlite->new($db_name); - my $col_names = $sqlite->get_table_columns($table_name); - print join(', ', @{ $col_names } )."\n" ; - my $answer = $sqlite->show_table($table_name); - print $answer."\n"; -} - - -print "\nFINISH\n";