Fix test equality for ports and add Apache header
diff --git a/taverna-scufl2-cwl/src/test/java/org/apache/taverna/scufl2/cwl/TestParser.java b/taverna-scufl2-cwl/src/test/java/org/apache/taverna/scufl2/cwl/TestParser.java
index 89c81ba..4e3e69e 100644
--- a/taverna-scufl2-cwl/src/test/java/org/apache/taverna/scufl2/cwl/TestParser.java
+++ b/taverna-scufl2-cwl/src/test/java/org/apache/taverna/scufl2/cwl/TestParser.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
 package org.apache.taverna.scufl2.cwl;
 
 
@@ -48,9 +66,12 @@
     @Test
     public void testParseInputs() throws Exception {
 
+        workflow.setParent(null);
         NamedSet<InputWorkflowPort> workflowInputs = workflow.getInputPorts();
-        NamedSet<InputWorkflowPort> expectedInputs = new NamedSet<>();
-        expectedInputs.add(new InputWorkflowPort(workflow, "name"));
+
+        Workflow expectedWorkflow = new Workflow(workflow.getName());
+        NamedSet<InputWorkflowPort> expectedInputs = expectedWorkflow.getInputPorts();
+        expectedInputs.add(new InputWorkflowPort(expectedWorkflow, "name"));
 
         assertEquals(expectedInputs, workflowInputs);
     }
@@ -67,9 +88,12 @@
     @Test
     public void testParseProcessors() throws Exception {
 
+        workflow.setParent(null);
         NamedSet<Processor> workflowProcessors = workflow.getProcessors();
-        NamedSet<Processor> expectedProcessors = new NamedSet<>();
-        expectedProcessors.add(new Processor(workflow, "step1"));
+
+        Workflow expectedWorkflow = new Workflow(workflow.getName());
+        NamedSet<Processor> expectedProcessors = expectedWorkflow.getProcessors();
+        expectedProcessors.add(new Processor(expectedWorkflow, "step1"));
 
         assertEquals(expectedProcessors, workflowProcessors);
     }
@@ -79,10 +103,9 @@
 
         Set<DataLink> workflowDataLinks = workflow.getDataLinks();
         Set<DataLink> expectedDataLinks = new HashSet<>();
-        Set<Processor> processorSet = workflow.getProcessors();
+        NamedSet<Processor> processorSet = workflow.getProcessors();
         // processorSet has one processor
-        Processor processor = processorSet.iterator().next();
-
+        Processor processor = processorSet.getByName("step1");
         expectedDataLinks.add(
                 new DataLink(
                         workflow,
@@ -91,6 +114,7 @@
                 )
         );
 
+        assertEquals(1, workflowDataLinks.size());
         assertEquals(expectedDataLinks, workflowDataLinks);
     }
 }
diff --git a/taverna-scufl2-cwl/src/test/resources/1st-tool.cwl b/taverna-scufl2-cwl/src/test/resources/1st-tool.cwl
index e292134..be272f2 100644
--- a/taverna-scufl2-cwl/src/test/resources/1st-tool.cwl
+++ b/taverna-scufl2-cwl/src/test/resources/1st-tool.cwl
@@ -1,3 +1,19 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements. See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership. The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License. You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied. See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
 cwlVersion: v1.0
 class: CommandLineTool
 baseCommand: echo
diff --git a/taverna-scufl2-cwl/src/test/resources/hello_world.cwl b/taverna-scufl2-cwl/src/test/resources/hello_world.cwl
index d716812..2172578 100644
--- a/taverna-scufl2-cwl/src/test/resources/hello_world.cwl
+++ b/taverna-scufl2-cwl/src/test/resources/hello_world.cwl
@@ -1,4 +1,22 @@
 #!/usr/bin/env cwl-runner
+
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements. See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership. The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License. You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied. See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
 cwlVersion: v1.0
 class: Workflow
 
diff --git a/taverna-scufl2-cwl/src/test/resources/int_input.cwl b/taverna-scufl2-cwl/src/test/resources/int_input.cwl
index ffb79e6..f2041da 100644
--- a/taverna-scufl2-cwl/src/test/resources/int_input.cwl
+++ b/taverna-scufl2-cwl/src/test/resources/int_input.cwl
@@ -1,3 +1,19 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements. See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership. The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License. You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied. See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
 inputs:
   example_int:
     type: int
diff --git a/taverna-scufl2-cwl/src/test/resources/simple_string_input.cwl b/taverna-scufl2-cwl/src/test/resources/simple_string_input.cwl
index b474f9d..059338f 100644
--- a/taverna-scufl2-cwl/src/test/resources/simple_string_input.cwl
+++ b/taverna-scufl2-cwl/src/test/resources/simple_string_input.cwl
@@ -1,3 +1,19 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements. See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership. The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License. You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied. See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
 inputs:
   example_string: string
 steps:
diff --git a/taverna-scufl2-cwl/src/test/resources/worklflow2.cwl b/taverna-scufl2-cwl/src/test/resources/worklflow2.cwl
index 43f164c..fc5e846 100644
--- a/taverna-scufl2-cwl/src/test/resources/worklflow2.cwl
+++ b/taverna-scufl2-cwl/src/test/resources/worklflow2.cwl
@@ -1,4 +1,21 @@
 #!/usr/bin/env cwl-runner
+
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements. See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership. The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License. You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied. See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
 cwlVersion: v1.0
 class: Workflow