Browse Source

Removed old unused test

Donovan Muller 10 years ago
parent
commit
bfc96d39ab

+ 0 - 40
frameworks/Java/play2-java/play2-java-jpa/README.md

@@ -1,40 +0,0 @@
-#Play Benchmarking Test
-
-This is the Play portion of a [benchmarking test suite](../) comparing a variety of web development platforms.
-
-### JSON Encoding Test
-
-* [JSON test controller](app/controllers/Application.java)
-
-### Data-Store/Database Mapping Test
-
-* [Database test controller](app/controllers/Application.java)
-* [Database World test model](app/models/World.java)
-* [Database Fortune test model](app/models/Fortune.java)
-
-### Plain Text Test
-
-* [Plain text test controller](app/controllers/Application.java)
-
-## Infrastructure Software Versions
-The tests were run with:
-
-* [Java OpenJDK 1.7](http://openjdk.java.net/)
-* [Play 2.3.6](http://http://www.playframework.com/)
-
-## Test URLs
-### JSON Encoding Test
-
-* http://localhost/json
-
-### Data-Store/Database Mapping Test
-
-* http://localhost/db
-* http://localhost/queries?queries=10
-* http://localhost/fortunes
-* http://localhost/update?queries=10
-
-### Plain Text Test
-
-* http://localhost/plaintext
-

+ 0 - 34
frameworks/Java/play2-java/play2-java-jpa/app/models/Fortune.java

@@ -1,34 +0,0 @@
-package models;
-
-import play.db.jpa.JPA;
-
-import javax.persistence.Entity;
-import javax.persistence.Id;
-import javax.persistence.criteria.CriteriaQuery;
-import java.util.List;
-
-@Entity
-public class Fortune {
-
-    @Id
-    public Long id = 0L;
-
-    public String message;
-
-    public Fortune() {
-    }
-
-    public Fortune(String message) {
-        this.message = message;
-    }
-
-    public static List<Fortune> findAll() throws Throwable {
-        return JPA.withTransaction("default", true, new play.libs.F.Function0<List<Fortune>>() {
-            public List<Fortune> apply() {
-                CriteriaQuery<Fortune> criteria = JPA.em().getCriteriaBuilder().createQuery(Fortune.class);
-                criteria.select(criteria.from(Fortune.class));
-                return JPA.em().createQuery(criteria).getResultList();
-            }
-        });
-    }
-}

+ 0 - 38
frameworks/Java/play2-java/play2-java-jpa/app/models/World.java

@@ -1,38 +0,0 @@
-package models;
-
-import play.db.jpa.JPA;
-
-import javax.persistence.Column;
-import javax.persistence.Entity;
-import javax.persistence.Id;
-import java.util.List;
-
-@Entity
-public class World {
-
-    @Id
-    public Long id;
-
-    @Column(name = "randomNumber")
-    public Long randomNumber;
-
-    public static World findById(final Long id) throws Throwable {
-        return JPA.withTransaction("default", true, new play.libs.F.Function0<World>() {
-            public World apply() {
-                return JPA.em().find(World.class, id);
-            }
-        });
-    }
-
-    public static List<World> save(final List<World> worlds) throws Throwable {
-        for (final World world : worlds) {
-            JPA.withTransaction("default", false, new play.libs.F.Function0<World>() {
-                public World apply() {
-                    return JPA.em().merge(world);
-                }
-            });
-        }
-
-        return worlds;
-    }
-}

+ 0 - 21
frameworks/Java/play2-java/play2-java-jpa/app/utils/Headers.java

@@ -1,21 +0,0 @@
-package utils;
-
-import org.joda.time.DateTime;
-import org.joda.time.format.DateTimeFormat;
-import org.joda.time.format.DateTimeFormatter;
-import play.libs.F;
-import play.mvc.Action;
-import play.mvc.Http;
-import play.mvc.Result;
-
-public class Headers extends Action.Simple {
-
-    private static final DateTimeFormatter RFC_1123_DATE_TIME = DateTimeFormat.forPattern("EEE, dd MMM yyyy HH:mm:ss 'GMT'").withZoneUTC();
-
-    @Override
-    public F.Promise<Result> call(Http.Context context) throws Throwable {
-        context.response().setHeader("Server", "play2-java-jpa");
-        context.response().setHeader("Date", RFC_1123_DATE_TIME.print(new DateTime()));
-        return delegate.call(context);
-    }
-}

+ 0 - 16
frameworks/Java/play2-java/play2-java-jpa/app/views/fortunes.scala.html

@@ -1,16 +0,0 @@
-@(fortunes: List[Fortune])
-
-@main() {
-    <table>
-        <tr>
-            <th>id</th>
-            <th>message</th>
-        </tr>
-        @for(fortune <- fortunes) {
-        <tr>
-            <td>@fortune.id</td>
-            <td>@fortune.message</td>
-        </tr>
-        }
-    </table>
-}

+ 0 - 12
frameworks/Java/play2-java/play2-java-jpa/app/views/main.scala.html

@@ -1,12 +0,0 @@
-@()(content: Html)
-
-<!DOCTYPE html>
-
-<html>
-    <head>
-        <title>Fortunes</title>
-    </head>
-    <body>
-    @content
-    </body>
-</html>

+ 0 - 6
frameworks/Java/play2-java/setup_java_ebean.py

@@ -1,6 +0,0 @@
-
-# This file was generated by frameworks/Java/play2-java/generate_config.py.
-# Do not edit this file directly, use the script to regenerate.
-from .setup_common import make_setup_for_dir
-
-make_setup_for_dir(globals(), 'play2-java-ebean')

+ 0 - 6
frameworks/Java/play2-java/setup_java_jpa.py

@@ -1,6 +0,0 @@
-
-# This file was generated by frameworks/Java/play2-java/generate_config.py.
-# Do not edit this file directly, use the script to regenerate.
-from .setup_common import make_setup_for_dir
-
-make_setup_for_dir(globals(), 'play2-java-jpa')