Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 74f6bc9

Browse files
committed
splitted old and new tests
rearranged installation procedure, splitted into two phases
1 parent 2bde41a commit 74f6bc9

5 files changed

Lines changed: 37 additions & 13 deletions

File tree

.travis.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,10 @@ before_script:
8585
script:
8686
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/install.sh; fi
8787
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/install_utplsql_release.sh; fi
88-
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/run_examples_and_tests.sh; fi
8988
- if [ "${TRAVIS_TAG}" = "" ]; then bash test/install_and_run_tests.sh; fi
89+
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/create_additional_grants_for_old_tests.sh; fi
90+
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/run_examples.sh; fi
91+
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/run_old_tests.sh; fi
9092
- if [ "${TRAVIS_TAG}" = "" ] && [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ]; then sonar-scanner; fi
9193
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/coveralls_uploader.sh; fi
9294
- bash .travis/build_docs.sh
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/bash
2+
3+
cd source
4+
set -ev
5+
6+
#additional privileges to run scripted tests
7+
"$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL
8+
set feedback on
9+
--needed for Mystats script to work
10+
grant select any dictionary to $UT3_OWNER;
11+
--Needed for testing a coverage outside ut3_owner.
12+
grant create any procedure, drop any procedure, execute any procedure to $UT3_OWNER;
13+
14+
exit
15+
SQL
16+
17+
#Create additional users
18+
"$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL
19+
set feedback off
20+
@create_utplsql_owner.sql $UT3_USER $UT3_USER_PASSWORD $UT3_TABLESPACE
21+
22+
exit
23+
SQL

.travis/install.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,10 @@ SQL
2626
#Create additional users
2727
"$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL
2828
set feedback off
29-
@create_utplsql_owner.sql $UT3_USER $UT3_USER_PASSWORD $UT3_TABLESPACE
3029
@create_utplsql_owner.sql $UT3_TESTER $UT3_TESTER_PASSWORD $UT3_TABLESPACE
31-
exit
32-
SQL
3330
34-
"$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL
3531
set feedback on
3632
--Needed for testing coverage outside of main UT3 schema.
37-
grant create any procedure, drop any procedure, execute any procedure to $UT3_TESTER;
33+
grant create any procedure, drop any procedure, execute any procedure, execute any type to $UT3_TESTER;
3834
exit
3935
SQL
Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,4 @@ conn $UT3_USER/$UT3_USER_PASSWORD@//$CONNECTION_STR
1414
1515
exit
1616
17-
SQL
18-
19-
"$SQLCLI" $UT3_OWNER/$UT3_OWNER_PASSWORD@//$CONNECTION_STR <<SQL
20-
cd tests
21-
@RunAll.sql
22-
exit
23-
SQL
17+
SQL

.travis/run_old_tests.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash
2+
3+
set -ev
4+
5+
"$SQLCLI" $UT3_OWNER/$UT3_OWNER_PASSWORD@//$CONNECTION_STR <<SQL
6+
cd tests
7+
@RunAll.sql
8+
exit
9+
SQL

0 commit comments

Comments
 (0)