Skip to content
Permalink
Browse files
Add basic test structure / data
  • Loading branch information
brogand93 committed May 31, 2014
1 parent 17f98cd commit 1639b96ab97b1ccb7f218f2a1dc8c7d553ae21b8
Showing 33 changed files with 962 additions and 0 deletions.
@@ -0,0 +1,8 @@
from unittest import TestCase

class GStackTestCase(TestCase):
pass

class GStackAppTestCase(FlaskTestCaseMixin, GStackTestCase):


@@ -0,0 +1,32 @@
{ "queryasyncjobresultresponse": {
"accountid": "2edb0c28-95e4-11e3-b2e4-d19c9d3e5e1d",
"userid": "2edb33ec-95e4-11e3-b2e4-d19c9d3e5e1d",
"cmd": "org.apache.cloudstack.api.command.user.securitygroup.AuthorizeSecurityGroupIngressCmd",
"jobstatus": 1,
"jobprocstatus": 0,
"jobresultcode": 0,
"jobresulttype": "object",
"jobresult": {
"securitygroup": {
"id": "01104a6a-bd3c-4804-86fd-1ca6231f128d",
"name": "test5",
"description": "test5",
"account": "test",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"domain": "ROOT",
"ingressrule": [
{
"ruleid": "739f53a3-ce50-4790-a86d-1051f77dd3d2",
"protocol": "tcp",
"startport": 1000,
"endport": 1024,
"cidr": "0.0.0.0/0"
}
],
"egressrule": [],
"tags": []
}
},
"created": "2014-02-26T23:05:55+0000",
"jobid": "ed5d7cc6-776a-4fda-b4c4-b71421b56c82"
} }
@@ -0,0 +1,3 @@
{ "deletesshkeypairresponse": {
"success": "true"
} }
@@ -0,0 +1,5 @@
{
"deletevolumeresponse": {
"success": "true"
}
}
@@ -0,0 +1,3 @@
{
"listdiskofferingsresponse": {}
}
@@ -0,0 +1,5 @@
{
"listtemplatesresponse": {
"template": {}
}
}
@@ -0,0 +1,5 @@
{
"listvirtualmachinesresponse": {
"virtualmachine": {}
}
}
@@ -0,0 +1,5 @@
{
"listsshkeypairsresponse": {
"sshkeypair": {}
}
}
@@ -0,0 +1,5 @@
{
"listsecuritygroupsresponse": {
"securitygroup": {}
}
}
@@ -0,0 +1,5 @@
{
"listzonesresponse": {
"zone": {}
}
}
@@ -0,0 +1,8 @@
{
"listtemplatesresponse": {
"errorcode": 431,
"uuidlist": [],
"cserrorcode": 4350,
"errortext": "Please specify a valid template ID."
}
}
@@ -0,0 +1,19 @@
{
"listzonesresponse": {
"count": 1,
"zone": [
{
"localstorageenabled": false,
"name": "Sandbox-simulator",
"zonetoken": "038bf1a4-c55c-3d1e-9176-b42e22ee00c1",
"dns1": "8.8.8.8",
"securitygroupsenabled": true,
"allocationstate": "Enabled",
"internaldns1": "8.8.8.8",
"dhcpprovider": "VirtualRouter",
"networktype": "Basic",
"id": "1e47a2fc-61c7-401c-b90e-416b472ada64"
}
]
}
}
@@ -0,0 +1,7 @@
{ "createsshkeypairresponse": {
"keypair": {
"name": "Test",
"fingerprint": "f1:85:d8:d6:54:3c:3e:41:49:52:82:1b:a6:4e:7e:31",
"privateKey": "-----BEGIN RSA PRIVATE KEY-----\nMIICWwIBAAKBgQCLFWb+Y+zxkDMSTmLu7XzOIFccIe6/TWG0BLA53xOPyoRTM4j0\n1cGF2m4VSQ8QLOXztqO22O+zOU5eOtps5kZKk0IHpVGiTeNEfovogVnQx4A3qcC+\nwKHFvjidlT6Cdy8av6erBS18W2NEtkipPEN1Kyirf5EDCz8gMcqRFxvIIQIDAQAB\nAoGAK8Dy4qp62s97UZH5S6LIdWv1G3ONUP898kzbR4lm9QBHuojm1+b692ns4aNX\nKsaFHLNjM11xotcvUTOAjWuvxsDaiE8wAxJI8Zv40QjJ3YO9zbrsbYoysXKJCVLx\nEDB+HWaAb6gRprffuxu50py54RwTyXmhsuuIFcpKn07p32UCQQD42dCvq9p2Qu4Y\nLuVn88kukc7wE3u/phLBaGGxAOEYvXH19rByKgzNYcKeZkrOrqbFEd7YiH/rsJz5\nuY1Jh/OPAkEAjxRMiy5G3SbToC8IOEsLPY0USyOmx1Domd6HEGDOT7OIUoP9gsSr\nuH23C73IzBFstxxhU+MkjZIY2dEY8ULxTwJAbNUl9Y5dTtdatezcm6f81ociT9DV\nkC2bikaSYw0VZPKFgqLO7D8DtlcI/KmUEexEN2/nXB/mgjeNj5Hc/smcdQJATEfK\nNznI1gbpNLFedIStzXb1psmvFPxxxfb5kyXJWHyi5TsxYRJxar67ZCsebo2rpEQh\nL5Qd3MxTK21rGtVRyQJAM4HcYNW/VbH0SrhbtkLoHabjPkb3H0g05THq1ZTohWa0\n1UckpzFX46gc2as+ooHGH0KsA7prUqI9AOmAwc28yw==\n-----END RSA PRIVATE KEY-----\n"
}
} }
@@ -0,0 +1,12 @@
{
"createsecuritygroupresponse": {
"securitygroup": {
"account": "account",
"domainid": "66d69e46-a95b-437b-ac6c-bcaa5331999d",
"name": "securitygroupname",
"domain": "domain",
"id": "9684da98-3f7c-4a0b-b968-3ad143f7650d",
"description": "security group description"
}
}
}
@@ -0,0 +1,5 @@
{
"deletesecuritygroupresponse": {
"success": "true"
}
}
@@ -0,0 +1,35 @@
{
"listtemplatesresponse": {
"count": 1,
"template": [
{
"domain": "ROOT",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"ostypename": "CentOS 5.3 (32-bit)",
"zoneid": "1e47a2fc-61c7-401c-b90e-416b472ada64",
"displaytext": "CentOS 5.3(64-bit) no GUI (Simulator)",
"ostypeid": "2e678976-95e4-11e3-b2e4-d19c9d3e5e1d",
"passwordenabled": false,
"id": "a32d70ee-95e4-11e3-b2e4-d19c9d3e5e1d",
"size": 2147483648,
"isready": true,
"format": "VHD",
"templatetype": "BUILTIN",
"crosszones": true,
"zonename": "Sandbox-simulator",
"status": "Download Complete",
"isdynamicallyscalable": false,
"tags": [],
"isfeatured": true,
"sshkeyenabled": false,
"isextractable": false,
"account": "system",
"name": "CentOS 5.3(64-bit) no GUI (Simulator)",
"created": "2014-02-15T02:50:13+0000",
"hypervisor": "Simulator",
"ispublic": true,
"checksum": ""
}
]
}
}
@@ -0,0 +1,35 @@
{
"listtemplatesresponse": {
"count": 1,
"template": [
{
"domain": "ROOT",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"ostypename": "CentOS 5.3 (32-bit)",
"zoneid": "1e47a2fc-61c7-401c-b90e-416b472ada64",
"displaytext": "CentOS 5.3(64-bit) no GUI (Simulator)",
"ostypeid": "2e678976-95e4-11e3-b2e4-d19c9d3e5e1d",
"passwordenabled": false,
"id": "a32d70ee-95e4-11e3-b2e4-d19c9d3e5e1d",
"size": 2147483648,
"isready": true,
"format": "VHD",
"templatetype": "BUILTIN",
"crosszones": true,
"zonename": "Sandbox-simulator",
"status": "Download Complete",
"isdynamicallyscalable": false,
"tags": [],
"isfeatured": true,
"sshkeyenabled": false,
"isextractable": false,
"account": "system",
"name": "CentOS 5.3(64-bit) no GUI (Simulator)",
"created": "2014-02-15T02:50:13+0000",
"hypervisor": "Simulator",
"ispublic": true,
"checksum": ""
}
]
}
}
@@ -0,0 +1,42 @@
{
"listvirtualmachinesresponse": {
"count": 2,
"virtualmachine": [
{
"domain": "ROOT",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"haenable": false,
"templatename": "CentOS 5.3(64-bit) no GUI (Simulator)",
"zoneid": "1e47a2fc-61c7-401c-b90e-416b472ada64",
"cpunumber": 1,
"passwordenabled": false,
"instancename": "i-2-5-QA",
"id": "43791f77-26f8-48ca-b557-3a9392f735ae",
"networkkbswrite": 21184512,
"hostname": "SimulatedAgent.74a0cc00-96c0-4b60-a170-7c749c6e2f10",
"displayvm": true,
"state": "Running",
"guestosid": "2e678976-95e4-11e3-b2e4-d19c9d3e5e1d",
"cpuused": "10%",
"memory": 512,
"serviceofferingid": "739292ce-3e12-4643-8ca1-abfdc2b2eb76",
"zonename": "Sandbox-simulator",
"isdynamicallyscalable": false,
"tags": [],
"cpuspeed": 500,
"templateid": "a32d70ee-95e4-11e3-b2e4-d19c9d3e5e1d",
"affinitygroup": [],
"account": "admin",
"hostid": "e880bd0f-1597-4cec-b108-c61dd02d78fd",
"name": "43791f77-26f8-48ca-b557-3a9392f735ae",
"networkkbsread": 42369024,
"created": "2014-02-21T17:28:40+0000",
"hypervisor": "Simulator",
"rootdevicetype": "ROOT",
"rootdeviceid": 0,
"serviceofferingname": "Small Instance",
"templatedisplaytext": "CentOS 5.3(64-bit) no GUI (Simulator)"
}
]
}
}
@@ -0,0 +1,77 @@
{
"listvirtualmachinesresponse": {
"count": 2,
"virtualmachine": [
{
"domain": "ROOT",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"haenable": false,
"templatename": "CentOS 5.3(64-bit) no GUI (Simulator)",
"zoneid": "1e47a2fc-61c7-401c-b90e-416b472ada64",
"cpunumber": 1,
"passwordenabled": false,
"instancename": "i-2-5-QA",
"id": "43791f77-26f8-48ca-b557-3a9392f735ae",
"networkkbswrite": 21184512,
"hostname": "SimulatedAgent.74a0cc00-96c0-4b60-a170-7c749c6e2f10",
"displayvm": true,
"state": "Running",
"guestosid": "2e678976-95e4-11e3-b2e4-d19c9d3e5e1d",
"cpuused": "10%",
"memory": 512,
"serviceofferingid": "739292ce-3e12-4643-8ca1-abfdc2b2eb76",
"zonename": "Sandbox-simulator",
"isdynamicallyscalable": false,
"tags": [],
"cpuspeed": 500,
"templateid": "a32d70ee-95e4-11e3-b2e4-d19c9d3e5e1d",
"affinitygroup": [],
"account": "admin",
"hostid": "e880bd0f-1597-4cec-b108-c61dd02d78fd",
"name": "43791f77-26f8-48ca-b557-3a9392f735ae",
"networkkbsread": 42369024,
"created": "2014-02-21T17:28:40+0000",
"hypervisor": "Simulator",
"rootdevicetype": "ROOT",
"rootdeviceid": 0,
"serviceofferingname": "Small Instance",
"templatedisplaytext": "CentOS 5.3(64-bit) no GUI (Simulator)"
},
{
"domain": "ROOT",
"domainid": "2edae3e4-95e4-11e3-b2e4-d19c9d3e5e1d",
"haenable": false,
"templatename": "CentOS 5.3(64-bit) no GUI (Simulator)",
"zoneid": "1e47a2fc-61c7-401c-b90e-416b472ada64",
"cpunumber": 1,
"passwordenabled": false,
"instancename": "i-2-3-QA",
"id": "aa10a43e-56db-4a34-88bd-1c2a51c0bc04",
"networkkbswrite": 119291904,
"hostname": "SimulatedAgent.74a0cc00-96c0-4b60-a170-7c749c6e2f10",
"displayvm": true,
"state": "Running",
"guestosid": "2e678976-95e4-11e3-b2e4-d19c9d3e5e1d",
"cpuused": "10%",
"memory": 512,
"serviceofferingid": "739292ce-3e12-4643-8ca1-abfdc2b2eb76",
"zonename": "Sandbox-simulator",
"isdynamicallyscalable": false,
"tags": [],
"cpuspeed": 500,
"templateid": "a32d70ee-95e4-11e3-b2e4-d19c9d3e5e1d",
"affinitygroup": [],
"account": "admin",
"hostid": "e880bd0f-1597-4cec-b108-c61dd02d78fd",
"name": "aa10a43e-56db-4a34-88bd-1c2a51c0bc04",
"networkkbsread": 238583808,
"created": "2014-02-15T20:04:05+0000",
"hypervisor": "Simulator",
"rootdevicetype": "ROOT",
"rootdeviceid": 0,
"serviceofferingname": "Small Instance",
"templatedisplaytext": "CentOS 5.3(64-bit) no GUI (Simulator)"
}
]
}
}
@@ -0,0 +1,11 @@
{
"listsshkeypairsresponse": {
"count": 1,
"sshkeypair": [
{
"name": "test",
"fingerprint": "89:e8:53:79:81:75:ac:ae:c3:95:e0:ee:e0:e7:c0:06"
}
]
}
}

0 comments on commit 1639b96

Please sign in to comment.