forked from utPLSQL/utPLSQL
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall_tests.sql
More file actions
103 lines (95 loc) · 3.77 KB
/
install_tests.sql
File metadata and controls
103 lines (95 loc) · 3.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
set define off
whenever sqlerror exit failure rollback
whenever oserror exit failure rollback
--Install helpers
@@helpers/ut_test_table.sql
@@helpers/ut_example_tests.pks
@@helpers/ut_example_tests.pkb
@@helpers/ut_without_body.pks
@@helpers/ut_with_invalid_body.pks
@@helpers/ut_with_invalid_body.pkb
@@helpers/other_dummy_object.tps
@@helpers/test_dummy_object.tps
@@helpers/test_dummy_object_list.tps
--Install tests
@@core.pks
@@api/test_ut_runner.pks
@@core/test_ut_utils.pks
@@core/test_ut_suite.pks
@@core/test_ut_test.pks
@@core/annotations/test_annotation_parser.pks
@@core/annotations/test_annotation_manager.pks
@@core/expectations/test_matchers.pks
@@core/test_output_buffer.pks
@@core/test_suite_manager.pks
@@core/reporters/test_coverage.pks
@@core/reporters/test_coverage/test_coverage_sonar_reporter.pks
@@core/reporters/test_coverage/test_coveralls_reporter.pks
@@core/reporters/test_xunit_reporter.pks
@@core/expectations.pks
@@core/expectations/scalar_data/binary/test_be_greater_or_equal.pks
@@core/expectations/scalar_data/binary/test_be_greater_than.pks
@@core/expectations/scalar_data/binary/test_be_less_or_equal.pks
@@core/expectations/scalar_data/binary/test_equal.pks
@@core/expectations/scalar_data/binary/test_expect_to_be_less_than.pks
@@core/expectations/compound_data/test_expect_to_be_empty.pks
@@core/expectations/compound_data/test_expect_to_have_count.pks
@@core/expectations/compound_data/test_expectations_cursor.pks
@@core/expectations/compound_data/test_expectation_anydata.pks
@@core/expectations/scalar_data/unary/test_expect_not_to_be_null.pks
@@core/expectations/scalar_data/unary/test_expect_to_be_not_null.pks
@@core/expectations/scalar_data/unary/test_expect_to_be_null.pks
@@core/expectations/scalar_data/unary/test_expect_to_be_true_false.pks
@@core.pkb
@@api/test_ut_runner.pkb
@@core/test_ut_utils.pkb
@@core/test_ut_suite.pkb
@@core/test_ut_test.pkb
@@core/annotations/test_annotation_parser.pkb
@@core/annotations/test_annotation_manager.pkb
@@core/expectations/test_matchers.pkb
@@core/test_output_buffer.pkb
@@core/test_suite_manager.pkb
@@core/reporters/test_coverage.pkb
@@core/reporters/test_coverage/test_coverage_sonar_reporter.pkb
@@core/reporters/test_coverage/test_coveralls_reporter.pkb
@@core/reporters/test_xunit_reporter.pkb
@@core/expectations.pkb
@@core/expectations/scalar_data/binary/test_be_greater_or_equal.pkb
@@core/expectations/scalar_data/binary/test_be_greater_than.pkb
@@core/expectations/scalar_data/binary/test_be_less_or_equal.pkb
@@core/expectations/scalar_data/binary/test_equal.pkb
@@core/expectations/scalar_data/binary/test_expect_to_be_less_than.pkb
@@core/expectations/compound_data/test_expect_to_be_empty.pkb
@@core/expectations/compound_data/test_expect_to_have_count.pkb
@@core/expectations/compound_data/test_expectations_cursor.pkb
@@core/expectations/compound_data/test_expectation_anydata.pkb
@@core/expectations/scalar_data/unary/test_expect_not_to_be_null.pkb
@@core/expectations/scalar_data/unary/test_expect_to_be_not_null.pkb
@@core/expectations/scalar_data/unary/test_expect_to_be_null.pkb
@@core/expectations/scalar_data/unary/test_expect_to_be_true_false.pkb
set linesize 200
set define on
set verify off
column text format a100
column error_count noprint new_value error_count
prompt Validating installation
set heading on
select type, name, sequence, line, position, text, count(1) over() error_count
from all_errors
where owner = USER
and name not like 'BIN$%' --not recycled
and name != 'UT_WITH_INVALID_BODY'
-- errors only. ignore warnings
and attribute = 'ERROR'
order by name, type, sequence
/
begin
if to_number('&&error_count') > 0 then
raise_application_error(-20000, 'Not all sources were successfully installed.');
else
dbms_output.put_line('Installation completed successfully');
end if;
end;
/
exit