usergrid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From toddn...@apache.org
Subject [12/50] git commit: adding create application
Date Thu, 06 Nov 2014 00:14:58 GMT
adding create application


Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/4082891a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/4082891a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/4082891a

Branch: refs/heads/two-dot-o
Commit: 4082891a923a12f04e269b75d67bcaf1cf92da38
Parents: 035c818
Author: Shawn Feldman <sfeldman@apache.org>
Authored: Fri Oct 31 17:21:40 2014 -0600
Committer: Shawn Feldman <sfeldman@apache.org>
Committed: Fri Oct 31 17:21:40 2014 -0600

----------------------------------------------------------------------
 .../org/apache/usergrid/scenarios/ApplicationScenarios.scala     | 4 ++--
 .../scala/org/apache/usergrid/scenarios/NotifierScenarios.scala  | 1 +
 .../simulations/PushNotificationTargetUserSimulation.scala       | 4 +++-
 3 files changed, 6 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/4082891a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/ApplicationScenarios.scala
----------------------------------------------------------------------
diff --git a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/ApplicationScenarios.scala
b/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/ApplicationScenarios.scala
index ffc7d96..d125f9d 100755
--- a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/ApplicationScenarios.scala
+++ b/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/ApplicationScenarios.scala
@@ -36,10 +36,10 @@ import io.gatling.http.Predef._
 object ApplicationScenarios {
 
   val createApplication = exec(http("Create Application")
-    .post("/management/organizations/${org}/applications")
+    .post(Settings.baseUrl +  "/management/organizations/"+Settings.org+"/applications")
     .headers(Headers.jsonAuthorized)
     .body(StringBody("{\"name\":\"" + Settings.app + "\"}"))
-    .check(status.is(200))
+    .check(status.in(200 to 204))
 
     )
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/4082891a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/NotifierScenarios.scala
----------------------------------------------------------------------
diff --git a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/NotifierScenarios.scala
b/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/NotifierScenarios.scala
index 5c4f1f6..4349d92 100755
--- a/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/NotifierScenarios.scala
+++ b/stack/loadtests/src/main/scala/org/apache/usergrid/scenarios/NotifierScenarios.scala
@@ -56,6 +56,7 @@ object NotifierScenarios {
 
     .exec(http("Create Notifier")
     .post(Settings.baseAppUrl+"/notifiers")
+    .headers(Headers.jsonAuthorized)
     .body(StringBody("{\"name\":\"" + notifier + "\",\"provider\":\"" + provider + "\"}"))
     .check(status.in(200 to 400)))
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/4082891a/stack/loadtests/src/main/scala/org/apache/usergrid/simulations/PushNotificationTargetUserSimulation.scala
----------------------------------------------------------------------
diff --git a/stack/loadtests/src/main/scala/org/apache/usergrid/simulations/PushNotificationTargetUserSimulation.scala
b/stack/loadtests/src/main/scala/org/apache/usergrid/simulations/PushNotificationTargetUserSimulation.scala
index 5a0e0d8..6ba55be 100644
--- a/stack/loadtests/src/main/scala/org/apache/usergrid/simulations/PushNotificationTargetUserSimulation.scala
+++ b/stack/loadtests/src/main/scala/org/apache/usergrid/simulations/PushNotificationTargetUserSimulation.scala
@@ -41,8 +41,9 @@ class PushNotificationTargetUserSimulation extends Simulation {
   val createUser = UserScenarios.postUser
   val createOrg = OrganizationScenarios.createOrgAndAdmin
   val connectUserToDevice = ConnectionScenarios.postUserToDeviceConnection
+  val createApp = ApplicationScenarios.createApplication
 
-  val getManagementToken = OrganizationScenarios.getManagementToken;
+  val getManagementToken = OrganizationScenarios.getManagementToken
 
   val getUserToken = UserScenarios.getUserToken
 
@@ -54,6 +55,7 @@ class PushNotificationTargetUserSimulation extends Simulation {
     .feed(orgFeeder)
     .exec(createOrg)
     .exec(getManagementToken)
+    .exec(createApp)
     .exec(createNotifier)
 
   val scnToRun = scenario("Create Push Notification")


Mime
View raw message