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

Skip to content

Commit 8644316

Browse files
committed
Added shortcuts to all the matchers
1 parent d393dd0 commit 8644316

14 files changed

Lines changed: 192 additions & 7 deletions

source/expectations/ut_expectation_date.tpb

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,31 @@ create or replace type body ut_expectation_date as
2626
ut_utils.debug_log('ut_expectation_date.to_be_between(self in ut_expectation_date, a_lower_bound date, a_upper_bound date)');
2727
self.to_( ut_be_between(a_lower_bound,a_upper_bound) );
2828
end;
29+
30+
member procedure to_be_greater_or_equal(self in ut_expectation_date, a_expected date) is
31+
32+
begin
33+
ut_utils.debug_log('ut_expectation_date.to_be_greater_or_equal(self in ut_expectation_date, a_expected date)');
34+
self.to_( ut_be_greater_or_equal (a_expected) );
35+
end;
36+
37+
member procedure to_be_greater_than(self in ut_expectation_date, a_expected date) is
38+
begin
39+
ut_utils.debug_log('ut_expectation_date.to_be_greater_than(self in ut_expectation_date, a_expected date)');
40+
self.to_( ut_be_greater_than (a_expected) );
41+
end;
42+
43+
member procedure to_be_less_or_equal(self in ut_expectation_date, a_expected date) is
44+
begin
45+
ut_utils.debug_log('ut_expectation_date.to_be_less_or_equal(self in ut_expectation_date, a_expected date)');
46+
self.to_( ut_be_less_or_equal (a_expected) );
47+
end;
48+
49+
member procedure to_be_less_than(self in ut_expectation_date, a_expected date) is
50+
begin
51+
ut_utils.debug_log('ut_expectation_date.to_be_less_than(self in ut_expectation_date, a_expected date');
52+
self.to_( ut_be_less_than (a_expected) );
53+
end;
2954

3055
end;
3156
/

source/expectations/ut_expectation_date.tps

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ create or replace type ut_expectation_date under ut_expectation(
1616
limitations under the License.
1717
*/
1818
overriding member procedure to_equal(self in ut_expectation_date, a_expected date, a_nulls_are_equal boolean := null),
19-
member procedure to_be_between(self in ut_expectation_date, a_lower_bound date, a_upper_bound date)
19+
member procedure to_be_between(self in ut_expectation_date, a_lower_bound date, a_upper_bound date),
20+
member procedure to_be_greater_or_equal(self in ut_expectation_date, a_expected date),
21+
member procedure to_be_greater_than(self in ut_expectation_date, a_expected date),
22+
member procedure to_be_less_or_equal(self in ut_expectation_date, a_expected date),
23+
member procedure to_be_less_than(self in ut_expectation_date, a_expected date)
2024
)
2125
/

source/expectations/ut_expectation_dsinterval.tpb

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,27 @@ create or replace type body ut_expectation_dsinterval as
2626
ut_utils.debug_log('ut_expectation_dsinterval.to_be_between(self in ut_expectation_dsinterval, a_lower_bound dsinterval_unconstrained, a_upper_bound dsinterval_unconstrained)');
2727
self.to_( ut_be_between(a_lower_bound,a_upper_bound) );
2828
end;
29+
30+
member procedure to_be_greater_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained) is
31+
begin
32+
ut_utils.debug_log('ut_expectation_dsinterval.to_be_greater_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained)');
33+
self.to_( ut_be_greater_or_equal (a_expected) );
34+
end;
35+
member procedure to_be_greater_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained) is
36+
begin
37+
ut_utils.debug_log('ut_expectation_dsinterval.to_be_greater_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained)');
38+
self.to_( ut_be_greater_than (a_expected) );
39+
end;
40+
member procedure to_be_less_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained) is
41+
begin
42+
ut_utils.debug_log('ut_expectation_dsinterval.to_be_less_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained)');
43+
self.to_( ut_be_less_or_equal (a_expected) );
44+
end;
45+
member procedure to_be_less_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained) is
46+
begin
47+
ut_utils.debug_log('ut_expectation_dsinterval.to_be_less_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained)');
48+
self.to_( ut_be_less_than (a_expected) );
49+
end;
2950

3051
end;
3152
/

source/expectations/ut_expectation_dsinterval.tps

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ create or replace type ut_expectation_dsinterval under ut_expectation(
1616
limitations under the License.
1717
*/
1818
overriding member procedure to_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained, a_nulls_are_equal boolean := null),
19-
member procedure to_be_between(self in ut_expectation_dsinterval, a_lower_bound dsinterval_unconstrained, a_upper_bound dsinterval_unconstrained)
19+
member procedure to_be_between(self in ut_expectation_dsinterval, a_lower_bound dsinterval_unconstrained, a_upper_bound dsinterval_unconstrained),
20+
member procedure to_be_greater_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained),
21+
member procedure to_be_greater_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained),
22+
member procedure to_be_less_or_equal(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained),
23+
member procedure to_be_less_than(self in ut_expectation_dsinterval, a_expected dsinterval_unconstrained)
2024
)
2125
/

source/expectations/ut_expectation_number.tpb

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,30 @@ create or replace type body ut_expectation_number as
2626
ut_utils.debug_log('ut_expectation_number.to_be_between(self in ut_expectation_date, a_lower_bound number, a_upper_bound number)');
2727
self.to_( ut_be_between(a_lower_bound,a_upper_bound) );
2828
end;
29+
30+
member procedure to_be_greater_or_equal(self in ut_expectation_number, a_expected number) is
31+
begin
32+
ut_utils.debug_log('ut_expectation_number.to_be_greater_or_equal(self in ut_expectation_number, a_expected number)');
33+
self.to_( ut_be_greater_or_equal (a_expected) );
34+
end;
35+
36+
member procedure to_be_greater_than(self in ut_expectation_number, a_expected number) is
37+
begin
38+
ut_utils.debug_log('ut_expectation_number.to_be_greater_than(self in ut_expectation_number, a_expected number)');
39+
self.to_( ut_be_greater_than (a_expected) );
40+
end;
41+
42+
member procedure to_be_less_or_equal(self in ut_expectation_number, a_expected number) is
43+
begin
44+
ut_utils.debug_log('ut_expectation_number.to_be_less_or_equal(self in ut_expectation_number, a_expected number)');
45+
self.to_( ut_be_less_or_equal (a_expected) );
46+
end;
47+
48+
member procedure to_be_less_than(self in ut_expectation_number, a_expected number) is
49+
begin
50+
ut_utils.debug_log('ut_expectation_number.to_be_less_than(self in ut_expectation_number, a_expected number');
51+
self.to_( ut_be_less_than (a_expected) );
52+
end;
2953

3054
end;
3155
/

source/expectations/ut_expectation_number.tps

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ create or replace type ut_expectation_number under ut_expectation(
1616
limitations under the License.
1717
*/
1818
overriding member procedure to_equal(self in ut_expectation_number, a_expected number, a_nulls_are_equal boolean := null),
19-
member procedure to_be_between(self in ut_expectation_number, a_lower_bound number, a_upper_bound number)
19+
member procedure to_be_between(self in ut_expectation_number, a_lower_bound number, a_upper_bound number),
20+
member procedure to_be_greater_or_equal(self in ut_expectation_number, a_expected number),
21+
member procedure to_be_greater_than(self in ut_expectation_number, a_expected number),
22+
member procedure to_be_less_or_equal(self in ut_expectation_number, a_expected number),
23+
member procedure to_be_less_than(self in ut_expectation_number, a_expected number)
2024
)
2125
/

source/expectations/ut_expectation_timestamp.tpb

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,30 @@ create or replace type body ut_expectation_timestamp as
2626
ut_utils.debug_log('ut_expectation_timestamp.to_be_between(self in ut_expectation_timestamp, a_lower_bound timestamp_unconstrained, a_upper_bound timestamp_unconstrained)');
2727
self.to_( ut_be_between(a_lower_bound, a_upper_bound) );
2828
end;
29+
30+
member procedure to_be_greater_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained) is
31+
begin
32+
ut_utils.debug_log('ut_expectation_timestamp.to_be_greater_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained)');
33+
self.to_( ut_be_greater_or_equal (a_expected) );
34+
end;
35+
36+
member procedure to_be_greater_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained) is
37+
begin
38+
ut_utils.debug_log('ut_expectation_timestamp.to_be_greater_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained)');
39+
self.to_( ut_be_greater_than (a_expected) );
40+
end;
41+
42+
member procedure to_be_less_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained) is
43+
begin
44+
ut_utils.debug_log('ut_expectation_timestamp.to_be_less_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained)');
45+
self.to_( ut_be_less_or_equal (a_expected) );
46+
end;
47+
48+
member procedure to_be_less_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained) is
49+
begin
50+
ut_utils.debug_log('ut_expectation_timestamp.to_be_less_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained)');
51+
self.to_( ut_be_less_than (a_expected) );
52+
end;
2953

3054
end;
3155
/

source/expectations/ut_expectation_timestamp.tps

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ create or replace type ut_expectation_timestamp under ut_expectation(
1616
limitations under the License.
1717
*/
1818
overriding member procedure to_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained, a_nulls_are_equal boolean := null),
19-
member procedure to_be_between(self in ut_expectation_timestamp, a_lower_bound timestamp_unconstrained, a_upper_bound timestamp_unconstrained)
19+
member procedure to_be_between(self in ut_expectation_timestamp, a_lower_bound timestamp_unconstrained, a_upper_bound timestamp_unconstrained),
20+
member procedure to_be_greater_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained),
21+
member procedure to_be_greater_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained),
22+
member procedure to_be_less_or_equal(self in ut_expectation_timestamp, a_expected timestamp_unconstrained),
23+
member procedure to_be_less_than(self in ut_expectation_timestamp, a_expected timestamp_unconstrained)
2024
)
2125
/

source/expectations/ut_expectation_timestamp_ltz.tpb

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,27 @@ create or replace type body ut_expectation_timestamp_ltz as
2626
ut_utils.debug_log('ut_expectation_timestamp_ltz.to_be_between(self in ut_expectation_timestamp_ltz, a_lower_bound timestamp_ltz_unconstrained, a_upper_bound timestamp_ltz_unconstrained)');
2727
self.to_( ut_be_between(a_lower_bound, a_upper_bound) );
2828
end;
29+
30+
member procedure to_be_greater_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained) is
31+
begin
32+
ut_utils.debug_log('ut_expectation_timestamp_ltz.to_be_greater_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained)');
33+
self.to_( ut_be_greater_or_equal (a_expected) );
34+
end;
35+
member procedure to_be_greater_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained) is
36+
begin
37+
ut_utils.debug_log('ut_expectation_timestamp_ltz.to_be_greater_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained)');
38+
self.to_( ut_be_greater_than (a_expected) );
39+
end;
40+
member procedure to_be_less_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained) is
41+
begin
42+
ut_utils.debug_log('ut_expectation_timestamp_ltz.to_be_less_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained)');
43+
self.to_( ut_be_less_or_equal (a_expected) );
44+
end;
45+
member procedure to_be_less_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained) is
46+
begin
47+
ut_utils.debug_log('ut_expectation_timestamp_ltz.to_be_less_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained)');
48+
self.to_( ut_be_less_than (a_expected) );
49+
end;
2950

3051
end;
3152
/

source/expectations/ut_expectation_timestamp_ltz.tps

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ create or replace type ut_expectation_timestamp_ltz under ut_expectation(
1616
limitations under the License.
1717
*/
1818
overriding member procedure to_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained, a_nulls_are_equal boolean := null),
19-
member procedure to_be_between(self in ut_expectation_timestamp_ltz, a_lower_bound timestamp_ltz_unconstrained, a_upper_bound timestamp_ltz_unconstrained)
19+
member procedure to_be_between(self in ut_expectation_timestamp_ltz, a_lower_bound timestamp_ltz_unconstrained, a_upper_bound timestamp_ltz_unconstrained),
20+
member procedure to_be_greater_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained),
21+
member procedure to_be_greater_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained),
22+
member procedure to_be_less_or_equal(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained),
23+
member procedure to_be_less_than(self in ut_expectation_timestamp_ltz, a_expected timestamp_ltz_unconstrained)
2024
)
2125
/

0 commit comments

Comments
 (0)