You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by GitBox <gi...@apache.org> on 2022/01/14 03:15:01 UTC

[GitHub] [daffodil-schema.g8] tuxji commented on a change in pull request #3: Add 'namespaced' property to support flat vs deep directory structure

tuxji commented on a change in pull request #3:
URL: https://github.com/apache/daffodil-schema.g8/pull/3#discussion_r784476786



##########
File path: .gitignore
##########
@@ -14,3 +14,4 @@
 # limitations under the License.
 
 target
+.bsp

Review comment:
       Should we add some more lines and sort all lines?
   
   ```
   .bloop
   .idea
   .metals
   .vscode
   project/metals.sbt
   target
   ```
   

##########
File path: src/main/g8/build.sbt
##########
@@ -20,14 +20,29 @@ organization := "$package$"
 
 version := "0.1.0-SNAPSHOT"
 
-scalaVersion := "2.12.11"
+scalaVersion := "2.12.15"
 
 libraryDependencies ++= Seq(
   "org.apache.daffodil" %% "daffodil-tdml-processor" % "$daffodil_version$" % "test",
-  "com.novocode" % "junit-interface" % "0.11" % "test",
-  "junit" % "junit" % "4.12" % "test",
+  "com.github.sbt" % "junit-interface" % "0.13.2" % "test",
+  "junit" % "junit" % "4.13.2" % "test",
+  "org.apache.logging.log4j" % "log4j-core" % "2.17.1" % "test",

Review comment:
       Might as well keep all the dependencies sorted alphabetically, right?

##########
File path: src/main/g8/$if(namespaced.truthy)$src$else$.$endif$/test/$if(namespaced.truthy)$resources$else$.$endif$/$if(namespaced.truthy)$$package$$else$.$endif$/$if(namespaced.truthy)$$name__camel$$else$.$endif$/Test$name__Camel$.tdml
##########
@@ -26,12 +26,12 @@ limitations under the License.
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   defaultRoundTrip="onePass">
 
-  <tdml:parserTestCase name="test_$name;format="camel"$_01" root="$name;format="Camel"$" model="$package;format="packaged"$/$name;format="camel"$/xsd/$name;format="camel"$.dfdl.xsd">
+  <tdml:parserTestCase name="test_$name;format="camel"$_01" root="$name;format="Camel"$" model="$if(namespaced.truthy)$$package;format="packaged"$/$name;format="camel"$/xsd/$endif$$name;format="camel"$.dfdl.xsd">
     <tdml:document>
-      <tdml:documentPart type="file">$package;format="packaged"$/$name;format="camel"$/data/test_01.$name;format="camel"$</tdml:documentPart>
+      <tdml:documentPart type="file">$if(namespaced.truthy)$$package;format="packaged"$/$name;format="camel"$/$endif$data/test_01.$name;format="camel"$</tdml:documentPart>
     </tdml:document>
     <tdml:infoset>
-      <tdml:dfdlInfoset type="file">$package;format="packaged"$/$name;format="camel"$/infosets/test_01.$name;format="camel"$.xml</tdml:dfdlInfoset>
+      <tdml:dfdlInfoset type="file">$if(namespaced.truthy)$$package;format="packaged"$/$name;format="camel"$/$endif$infosets/test_01.$name;format="camel"$.xml</tdml:dfdlInfoset>

Review comment:
       As long as the TDML file, data subdirectory, and infosets subdirectory are all in the same directory, you shouldn't need any namespace directory names.  As I said before, relative-looking filenames are sufficient regardless of which namespace packages the files actually live under:
   
   ```
         <tdml:documentPart type="file">data/test_01.$name;format="camel"$</tdml:documentPart>
   ```

##########
File path: src/main/g8/.gitignore
##########
@@ -15,3 +15,4 @@ $!
 # limitations under the License.
 !$
 target
+.bsp

Review comment:
       Ditto, should we add some more lines and sort all lines?
   
   ```
   .bloop
   .idea
   .metals
   .vscode
   project/metals.sbt
   target
   ```
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@daffodil.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org