Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
server
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GitHub Mirror
Nextcloud
server
Commits
1257a3c9
Commit
1257a3c9
authored
Jul 19, 2013
by
Thomas Müller
Browse files
Options
Downloads
Patches
Plain Diff
parallel execution support for mysql added
parent
fdfb224d
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
autotest.sh
+19
-12
19 additions, 12 deletions
autotest.sh
with
19 additions
and
12 deletions
autotest.sh
+
19
−
12
View file @
1257a3c9
...
@@ -8,6 +8,7 @@
...
@@ -8,6 +8,7 @@
#$EXECUTOR_NUMBER is set by Jenkins and allows us to run autotest in parallel
#$EXECUTOR_NUMBER is set by Jenkins and allows us to run autotest in parallel
DATABASENAME
=
oc_autotest
$EXECUTOR_NUMBER
DATABASENAME
=
oc_autotest
$EXECUTOR_NUMBER
DATABASEUSER
=
oc_autotest
$EXECUTOR_NUMBER
ADMINLOGIN
=
admin
$EXECUTOR_NUMBER
ADMINLOGIN
=
admin
$EXECUTOR_NUMBER
DATADIR
=
data-autotest
DATADIR
=
data-autotest
BASEDIR
=
$PWD
BASEDIR
=
$PWD
...
@@ -21,7 +22,7 @@ cat > ./tests/autoconfig-sqlite.php <<DELIM
...
@@ -21,7 +22,7 @@ cat > ./tests/autoconfig-sqlite.php <<DELIM
'installed' => false,
'installed' => false,
'dbtype' => 'sqlite',
'dbtype' => 'sqlite',
'dbtableprefix' => 'oc_',
'dbtableprefix' => 'oc_',
'adminlogin' =>
$ADMINLOGIN
,
'adminlogin' =>
'
$ADMINLOGIN
'
,
'adminpass' => 'admin',
'adminpass' => 'admin',
'directory' => '
$BASEDIR
/
$DATADIR
',
'directory' => '
$BASEDIR
/
$DATADIR
',
);
);
...
@@ -33,11 +34,11 @@ cat > ./tests/autoconfig-mysql.php <<DELIM
...
@@ -33,11 +34,11 @@ cat > ./tests/autoconfig-mysql.php <<DELIM
'installed' => false,
'installed' => false,
'dbtype' => 'mysql',
'dbtype' => 'mysql',
'dbtableprefix' => 'oc_',
'dbtableprefix' => 'oc_',
'adminlogin' =>
$ADMINLOGIN
,
'adminlogin' =>
'
$ADMINLOGIN
'
,
'adminpass' => 'admin',
'adminpass' => 'admin',
'directory' => '
$BASEDIR
/
$DATADIR
',
'directory' => '
$BASEDIR
/
$DATADIR
',
'dbuser' => '
oc_autotest
',
'dbuser' => '
$DATABASEUSER
',
'dbname' =>
$DATABASENAME
,
'dbname' =>
'
$DATABASENAME
'
,
'dbhost' => 'localhost',
'dbhost' => 'localhost',
'dbpass' => 'owncloud',
'dbpass' => 'owncloud',
);
);
...
@@ -49,11 +50,11 @@ cat > ./tests/autoconfig-pgsql.php <<DELIM
...
@@ -49,11 +50,11 @@ cat > ./tests/autoconfig-pgsql.php <<DELIM
'installed' => false,
'installed' => false,
'dbtype' => 'pgsql',
'dbtype' => 'pgsql',
'dbtableprefix' => 'oc_',
'dbtableprefix' => 'oc_',
'adminlogin' =>
$ADMINLOGIN
,
'adminlogin' =>
'
$ADMINLOGIN
'
,
'adminpass' => 'admin',
'adminpass' => 'admin',
'directory' => '
$BASEDIR
/
$DATADIR
',
'directory' => '
$BASEDIR
/
$DATADIR
',
'dbuser' => '
oc_autotest
',
'dbuser' => '
$DATABASEUSER
',
'dbname' =>
$DATABASENAME
,
'dbname' =>
'
$DATABASENAME
'
,
'dbhost' => 'localhost',
'dbhost' => 'localhost',
'dbpass' => 'owncloud',
'dbpass' => 'owncloud',
);
);
...
@@ -65,10 +66,10 @@ cat > ./tests/autoconfig-oci.php <<DELIM
...
@@ -65,10 +66,10 @@ cat > ./tests/autoconfig-oci.php <<DELIM
'installed' => false,
'installed' => false,
'dbtype' => 'oci',
'dbtype' => 'oci',
'dbtableprefix' => 'oc_',
'dbtableprefix' => 'oc_',
'adminlogin' =>
$ADMINLOGIN
,
'adminlogin' =>
'
$ADMINLOGIN
'
,
'adminpass' => 'admin',
'adminpass' => 'admin',
'directory' => '
$BASEDIR
/
$DATADIR
',
'directory' => '
$BASEDIR
/
$DATADIR
',
'dbuser' =>
$DATABASENAME
,
'dbuser' =>
'
$DATABASENAME
'
,
'dbname' => 'XE',
'dbname' => 'XE',
'dbhost' => 'localhost',
'dbhost' => 'localhost',
'dbpass' => 'owncloud',
'dbpass' => 'owncloud',
...
@@ -93,10 +94,10 @@ function execute_tests {
...
@@ -93,10 +94,10 @@ function execute_tests {
# drop database
# drop database
if
[
"
$1
"
==
"mysql"
]
;
then
if
[
"
$1
"
==
"mysql"
]
;
then
mysql
-u
oc_autotest
-powncloud
-e
"DROP DATABASE
$DATABASENAME
"
mysql
-u
$DATABASEUSER
-powncloud
-e
"DROP DATABASE
$DATABASENAME
"
fi
fi
if
[
"
$1
"
==
"pgsql"
]
;
then
if
[
"
$1
"
==
"pgsql"
]
;
then
dropdb
-U
oc_autotest
$DATABASENAME
dropdb
-U
$DATABASEUSER
$DATABASENAME
fi
fi
if
[
"
$1
"
==
"oci"
]
;
then
if
[
"
$1
"
==
"oci"
]
;
then
echo
"drop the database"
echo
"drop the database"
...
@@ -158,8 +159,14 @@ fi
...
@@ -158,8 +159,14 @@ fi
#
#
# NOTES on mysql:
# NOTES on mysql:
# - CREATE DATABASE oc_autotest;
# - CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY 'owncloud';
# - CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY 'owncloud';
# - grant access permissions: grant all on oc_autotest.* to 'oc_autotest'@'localhost';
# - grant all on oc_autotest.* to 'oc_autotest'@'localhost';
#
# - for parallel executor support with EXECUTOR_NUMBER=0:
# - CREATE DATABASE oc_autotest0;
# - CREATE USER 'oc_autotest0'@'localhost' IDENTIFIED BY 'owncloud';
# - grant all on oc_autotest0.* to 'oc_autotest0'@'localhost';
#
#
# NOTES on pgsql:
# NOTES on pgsql:
# - su - postgres
# - su - postgres
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment