Creating Automation test cases for POST

4 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$49.99
List Price:  $69.99
You save:  $20
€42.45
List Price:  €59.44
You save:  €16.98
£37.03
List Price:  £51.84
You save:  £14.81
CA$69.01
List Price:  CA$96.63
You save:  CA$27.61
A$75.79
List Price:  A$106.11
You save:  A$30.32
S$64.13
List Price:  S$89.79
You save:  S$25.66
HK$388.46
List Price:  HK$543.88
You save:  HK$155.41
CHF 39.68
List Price:  CHF 55.55
You save:  CHF 15.87
NOK kr496.55
List Price:  NOK kr695.21
You save:  NOK kr198.65
DKK kr316.88
List Price:  DKK kr443.66
You save:  DKK kr126.77
NZ$85.33
List Price:  NZ$119.47
You save:  NZ$34.14
د.إ183.58
List Price:  د.إ257.03
You save:  د.إ73.45
৳6,091.23
List Price:  ৳8,528.21
You save:  ৳2,436.98
₹4,414.11
List Price:  ₹6,180.11
You save:  ₹1,765.99
RM210.18
List Price:  RM294.27
You save:  RM84.09
₦74,789.53
List Price:  ₦104,711.33
You save:  ₦29,921.80
₨14,214.28
List Price:  ₨19,901.13
You save:  ₨5,686.85
฿1,588.68
List Price:  ฿2,224.28
You save:  ฿635.60
₺2,068.80
List Price:  ₺2,896.48
You save:  ₺827.68
B$266.66
List Price:  B$373.34
You save:  B$106.68
R863.86
List Price:  R1,209.47
You save:  R345.61
Лв83.10
List Price:  Лв116.35
You save:  Лв33.24
₩69,540.62
List Price:  ₩97,362.44
You save:  ₩27,821.81
₪167.48
List Price:  ₪234.49
You save:  ₪67
₱2,845.58
List Price:  ₱3,984.04
You save:  ₱1,138.46
¥7,391.49
List Price:  ¥10,348.68
You save:  ¥2,957.19
MX$919.30
List Price:  MX$1,287.10
You save:  MX$367.79
QR181.98
List Price:  QR254.79
You save:  QR72.80
P667.24
List Price:  P934.19
You save:  P266.95
KSh6,458.70
List Price:  KSh9,042.70
You save:  KSh2,584
E£2,410.65
List Price:  E£3,375.10
You save:  E£964.45
ብር7,189.19
List Price:  ብር10,065.44
You save:  ብር2,876.25
Kz45,588.63
List Price:  Kz63,827.73
You save:  Kz18,239.10
CLP$47,707.95
List Price:  CLP$66,794.95
You save:  CLP$19,087
CN¥355.55
List Price:  CN¥497.80
You save:  CN¥142.25
RD$3,105.59
List Price:  RD$4,348.08
You save:  RD$1,242.48
DA6,479.35
List Price:  DA9,071.61
You save:  DA2,592.26
FJ$112.59
List Price:  FJ$157.63
You save:  FJ$45.04
Q383.39
List Price:  Q536.78
You save:  Q153.39
GY$10,471.66
List Price:  GY$14,661.16
You save:  GY$4,189.50
ISK kr6,063.28
List Price:  ISK kr8,489.08
You save:  ISK kr2,425.80
DH451.51
List Price:  DH632.15
You save:  DH180.64
L824.85
List Price:  L1,154.86
You save:  L330
ден2,614.40
List Price:  ден3,660.37
You save:  ден1,045.97
MOP$401.21
List Price:  MOP$561.73
You save:  MOP$160.51
N$869.06
List Price:  N$1,216.76
You save:  N$347.69
C$1,843.18
List Price:  C$2,580.60
You save:  C$737.42
रु7,056.78
List Price:  रु9,880.06
You save:  रु2,823.27
S/174.35
List Price:  S/244.11
You save:  S/69.75
K209.36
List Price:  K293.12
You save:  K83.76
SAR187.49
List Price:  SAR262.50
You save:  SAR75.01
ZK1,184.48
List Price:  ZK1,658.37
You save:  ZK473.88
L215.46
List Price:  L301.67
You save:  L86.20
Kč1,029.79
List Price:  Kč1,441.79
You save:  Kč411.99
Ft16,525.78
List Price:  Ft23,137.42
You save:  Ft6,611.63
SEK kr469.08
List Price:  SEK kr656.75
You save:  SEK kr187.67
ARS$73,726.45
List Price:  ARS$103,222.93
You save:  ARS$29,496.48
Bs345.86
List Price:  Bs484.23
You save:  Bs138.37
COP$194,533
List Price:  COP$272,361.77
You save:  COP$77,828.76
₡25,268.07
List Price:  ₡35,377.32
You save:  ₡10,109.25
L1,312.81
List Price:  L1,838.04
You save:  L525.23
₲356,685.57
List Price:  ₲499,388.34
You save:  ₲142,702.77
$U1,994.72
List Price:  $U2,792.78
You save:  $U798.05
zł180.90
List Price:  zł253.27
You save:  zł72.37
Already have an account? Log In

Transcript

Hi, now we will see how to create test cases for create users APA. Right click new test case create users uses our test case is created. We can see both manual and script method here. In manual method, we are going to add a web service keyword send request and we are parsing the object. Here we are parsing create new user object and I am selecting ok and clicking this OK button. I am going to script mode here I am assigning or defining on variable def space create you as our create user SQL two and I am saving it and am adding this very fe status response score in the script in next line and I am passing this create user object in this method and then verifying its status reporting Score is 200 are not actually the AP REST request has will return the status code us to not one.

So, if it returns to not one, our test case is passed. So, here I am giving their their status request response code is 200 or not two not one or not I am verifying that I'm saving it and I am going to manual mode and I see like verify response status score manual method is also created with create user under to not one input and I am running it you can either run by from script mode or manual. Let me run here and our test case is launching begins to run. Let us wait for a few seconds to see there is Yeah, it started raining here you can see and in a very fade it status response code is two not one. Let us fail this test case. Let me tell the core verify whether it has status code is 200 or not and I am passing or running the script.

Now, our test case should fail because the actual response score will be two, not one We are asking the Corps to verify whether it is 200 or not. No, it will verify and it will throw a failed message. It is running. Yeah. In the Send request, you can see it is paused in very free status score. You can see like, it is failed in the error message you can see status code is 200 expected status code is here you can see like expected status code is 200 but actual status code is 201.

This is how we can verify our test cases.

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.