[ASTERIXDB-2787][TEST] Support .md extension for LICENSE and NOTICE

- user model changes: no
- storage format changes: no
- interface changes: no

Details:
- Currently, only LICENSE (no extension) and LICENSE.txt
  are supported for LICENSE and NOTICE files. This adds
  support to .md extension as well (LICENSE.md).

Change-Id: Ie29e061176964ccb85df34ccc17843177b58d838
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/8444
Reviewed-by: Michael Blow <mblow@apache.org>
Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Tested-by: Hussain Towaileb <hussainht@gmail.com>
diff --git a/hyracks-fullstack/hyracks/hyracks-maven-plugins/license-automation-plugin/src/main/java/org/apache/hyracks/maven/license/GenerateFileMojo.java b/hyracks-fullstack/hyracks/hyracks-maven-plugins/license-automation-plugin/src/main/java/org/apache/hyracks/maven/license/GenerateFileMojo.java
index e69887c..6bc92b8 100644
--- a/hyracks-fullstack/hyracks/hyracks-maven-plugins/license-automation-plugin/src/main/java/org/apache/hyracks/maven/license/GenerateFileMojo.java
+++ b/hyracks-fullstack/hyracks/hyracks-maven-plugins/license-automation-plugin/src/main/java/org/apache/hyracks/maven/license/GenerateFileMojo.java
@@ -335,16 +335,18 @@
     }
 
     private void resolveNoticeFiles() throws MojoExecutionException, IOException {
-        // TODO(mblow): this will match *any* NOTICE[.txt] file located within the artifact- this seems way too liberal
+        // TODO(mblow): this will match *any* NOTICE[.(txt|md)] file located within the artifact-
+        // this seems way too liberal
         resolveArtifactFiles("NOTICE", IGNORE_MISSING_EMBEDDED_NOTICE, ALTERNATE_NOTICE_FILE,
-                entry -> entry.getName().matches("(.*/|^)" + "NOTICE" + "(.txt)?"), Project::setNoticeText,
+                entry -> entry.getName().matches("(.*/|^)" + "NOTICE" + "(.(txt|md))?"), Project::setNoticeText,
                 text -> stripFoundationAssertionFromNotices ? FOUNDATION_PATTERN.matcher(text).replaceAll("") : text);
     }
 
     private void resolveLicenseFiles() throws MojoExecutionException, IOException {
-        // TODO(mblow): this will match *any* LICENSE[.txt] file located within the artifact- this seems way too liberal
+        // TODO(mblow): this will match *any* LICENSE[.(txt|md)] file located within the artifact-
+        // this seems way too liberal
         resolveArtifactFiles("LICENSE", IGNORE_MISSING_EMBEDDED_LICENSE, ALTERNATE_LICENSE_FILE,
-                entry -> entry.getName().matches("(.*/|^)" + "LICENSE" + "(.txt)?"), Project::setLicenseText,
+                entry -> entry.getName().matches("(.*/|^)" + "LICENSE" + "(.(txt|md))?"), Project::setLicenseText,
                 UnaryOperator.identity());
     }