@@ -356,6 +356,75 @@ public void include_object() throws Exception {
356356 assertEquals ("app.pkg_test_me,app.test_pkg_test_me" , utPlsqlMojo .includeObject );
357357 }
358358
359+ /**
360+ * Include an object by regex
361+ * <p>
362+ * Given : a pom.xml with a regex to include
363+ * When : pom is read
364+ * Then : Objects are included
365+ */
366+ @ Test
367+ public void include_object_expr () throws Exception {
368+ UtPlsqlMojo utPlsqlMojo = createUtPlsqlMojo ("include_object_expr" );
369+ assertNotNull (utPlsqlMojo );
370+
371+ utPlsqlMojo .execute ();
372+
373+ assertEquals ("*" , utPlsqlMojo .includeObjectExpr );
374+ }
375+
376+ /**
377+ * Exclude an object by regex
378+ * <p>
379+ * Given : a pom.xml with a regex to exclude
380+ * When : pom is read
381+ * Then : Objects are included
382+ */
383+ @ Test
384+ public void exclude_object_expr () throws Exception {
385+ UtPlsqlMojo utPlsqlMojo = createUtPlsqlMojo ("exclude_object_expr" );
386+ assertNotNull (utPlsqlMojo );
387+
388+ utPlsqlMojo .execute ();
389+
390+ assertEquals ("*" , utPlsqlMojo .excludeObjectExpr );
391+ }
392+
393+
394+ /**
395+ * Include a schema by regex
396+ * <p>
397+ * Given : a pom.xml with a regex to include
398+ * When : pom is read
399+ * Then : Objects are included
400+ */
401+ @ Test
402+ public void include_schema_expr () throws Exception {
403+ UtPlsqlMojo utPlsqlMojo = createUtPlsqlMojo ("include_schema_expr" );
404+ assertNotNull (utPlsqlMojo );
405+
406+ utPlsqlMojo .execute ();
407+
408+ assertEquals ("*" , utPlsqlMojo .includeSchemaExpr );
409+ }
410+
411+ /**
412+ * Exclude a schema by regex
413+ * <p>
414+ * Given : a pom.xml with a regex to exclude
415+ * When : pom is read
416+ * Then : Objects are included
417+ */
418+ @ Test
419+ public void exclude_schema_expr () throws Exception {
420+ UtPlsqlMojo utPlsqlMojo = createUtPlsqlMojo ("exclude_schema_expr" );
421+ assertNotNull (utPlsqlMojo );
422+
423+ utPlsqlMojo .execute ();
424+
425+ assertEquals ("*" , utPlsqlMojo .excludeSchemaExpr );
426+ }
427+
359428 private UtPlsqlMojo createUtPlsqlMojo (String directory ) throws Exception {
360429 return (UtPlsqlMojo ) rule .lookupConfiguredMojo (new File ("src/test/resources/unit-tests/" + directory ), "test" );
361430 }
0 commit comments