You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2014/11/18 14:20:31 UTC
[3/6] isis git commit: ISIS-928: recreating todoapp archetype
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/simple/Util.java
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/simple/Util.java b/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/simple/Util.java
deleted file mode 100644
index 133a35b..0000000
--- a/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/simple/Util.java
+++ /dev/null
@@ -1,39 +0,0 @@
-#set( $symbol_pound = '#' )
-#set( $symbol_dollar = '$' )
-#set( $symbol_escape = '\' )
-/*
- * 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 fixture.todo.simple;
-
-public final class Util {
-
- private Util(){}
-
- static String localNameFor(final String prefix, String user) {
- return prefix + "-" + coalesce(user, "current");
- }
-
- static String coalesce(final String... strings) {
- for (String str : strings) {
- if(str != null) { return str; }
- }
- return null;
- }
-
-}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/util/Util.java
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/util/Util.java b/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/util/Util.java
new file mode 100644
index 0000000..7a0ae71
--- /dev/null
+++ b/example/archetype/todoapp/src/main/resources/archetype-resources/fixture/src/main/java/fixture/todo/util/Util.java
@@ -0,0 +1,35 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+/*
+ * 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 fixture.todo.util;
+
+public final class Util {
+
+ private Util(){}
+
+ public static String coalesce(final String... strings) {
+ for (String str : strings) {
+ if(str != null) { return str; }
+ }
+ return null;
+ }
+
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemContributionsIntegTest.java
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemContributionsIntegTest.java b/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemContributionsIntegTest.java
index 3500adb..0725ca9 100644
--- a/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemContributionsIntegTest.java
+++ b/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemContributionsIntegTest.java
@@ -34,6 +34,8 @@ import org.apache.isis.applib.fixturescripts.FixtureScripts;
import static org.hamcrest.CoreMatchers.containsString;
import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.CoreMatchers.not;
+import static org.hamcrest.CoreMatchers.nullValue;
import static org.junit.Assert.assertThat;
public abstract class ToDoItemContributionsIntegTest extends AbstractToDoIntegTest {
@@ -59,7 +61,8 @@ public abstract class ToDoItemContributionsIntegTest extends AbstractToDoIntegTe
@Before
public void setUp() throws Exception {
- toDoItem = wrap(fixture.lookup("integ-test/complete-current/create-current/item-2", ToDoItem.class));
+ toDoItem = wrap(fixture.lookup("integ-test/to-do-items-recreate-and-complete-several/to-do-item-complete-for-buy-stamps/item-1", ToDoItem.class));
+ assertThat(toDoItem, is(not(nullValue())));
toDoItemContributionsWrapped = wrap(toDoItemContributions);
}
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemIntegTest.java
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemIntegTest.java b/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemIntegTest.java
index e40a39c..68c2619 100644
--- a/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemIntegTest.java
+++ b/example/archetype/todoapp/src/main/resources/archetype-resources/integtests/src/test/java/integration/tests/ToDoItemIntegTest.java
@@ -104,7 +104,8 @@ public class ToDoItemIntegTest extends AbstractToDoIntegTest {
final List<ToDoItem> all = wrap(toDoItems).notYetComplete();
toDoItem = wrap(all.get(0));
- toDoItem = wrap(fixture.lookup("integ-test/complete-current/create-current/item-2", ToDoItem.class));
+ toDoItem = wrap(fixture.lookup("integ-test/to-do-items-recreate-and-complete-several/to-do-items-recreate/to-do-item-for-buy-bread/item-1", ToDoItem.class));
+ assertThat(toDoItem, is(not(nullValue())));
nextTransaction();
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/main/resources/archetype-resources/webapp/src/main/webapp/WEB-INF/isis.properties
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/main/resources/archetype-resources/webapp/src/main/webapp/WEB-INF/isis.properties b/example/archetype/todoapp/src/main/resources/archetype-resources/webapp/src/main/webapp/WEB-INF/isis.properties
index b9cf19e..97fae7f 100644
--- a/example/archetype/todoapp/src/main/resources/archetype-resources/webapp/src/main/webapp/WEB-INF/isis.properties
+++ b/example/archetype/todoapp/src/main/resources/archetype-resources/webapp/src/main/webapp/WEB-INF/isis.properties
@@ -161,7 +161,7 @@ ${symbol_pound} Fixtures are used to seed the object store with an initial set o
${symbol_pound} in-memory object store, the fixtures are installed on every run. For other
${symbol_pound} object stores, they are used only when the object store is first initialized.
${symbol_pound}
-isis.fixtures=fixture.todo.scenarios.RecreateToDoItemsForSven
+isis.fixtures=fixture.todo.scenarios.ToDoItemsRecreateForSven
${symbol_pound}
http://git-wip-us.apache.org/repos/asf/isis/blob/60c5e045/example/archetype/todoapp/src/test/resources/projects/basic/archetype.properties
----------------------------------------------------------------------
diff --git a/example/archetype/todoapp/src/test/resources/projects/basic/archetype.properties b/example/archetype/todoapp/src/test/resources/projects/basic/archetype.properties
index ab81106..da0d140 100644
--- a/example/archetype/todoapp/src/test/resources/projects/basic/archetype.properties
+++ b/example/archetype/todoapp/src/test/resources/projects/basic/archetype.properties
@@ -1,4 +1,4 @@
-#Sat Nov 15 10:26:47 GMT 2014
+#Tue Nov 18 11:41:25 CET 2014
package=it.pkg
version=0.1-SNAPSHOT
groupId=archetype.it