POST 2 test updates

This commit is contained in:
Ankit Mahato
2024-03-12 02:24:35 +05:30
parent 9be445072c
commit fc7a051285
6 changed files with 16 additions and 6 deletions

View File

@ -115,7 +115,12 @@ void main() {
--url 'https://api.apidash.dev/case/lower' \ --url 'https://api.apidash.dev/case/lower' \
--header 'Content-Type: application/json' \ --header 'Content-Type: application/json' \
--data '{ --data '{
"text": "I LOVE Flutter" "text": "I LOVE Flutter",
"flag": null,
"male": true,
"female": false,
"no": 1.2,
"arr": ["null", "true", "false", null]
}'"""; }'""";
expect(curlCodeGen.getCode(requestModelPost2, "https"), expectedCode); expect(curlCodeGen.getCode(requestModelPost2, "https"), expectedCode);
}); });

View File

@ -409,7 +409,12 @@ void main() async {
var uri = Uri.parse('https://api.apidash.dev/case/lower'); var uri = Uri.parse('https://api.apidash.dev/case/lower');
String body = r'''{ String body = r'''{
"text": "I LOVE Flutter" "text": "I LOVE Flutter",
"flag": null,
"male": true,
"female": false,
"no": 1.2,
"arr": ["null", "true", "false", null]
}'''; }''';
var headers = {'content-type': 'application/json'}; var headers = {'content-type': 'application/json'};

View File

@ -383,7 +383,7 @@ axios(config)
headers: { headers: {
"Content-Type": "application/json" "Content-Type": "application/json"
}, },
data: "{\n\"text\": \"I LOVE Flutter\"\n}" data: "{\n\"text\": \"I LOVE Flutter\",\n\"flag\": null,\n\"male\": true,\n\"female\": false,\n\"no\": 1.2,\n\"arr\": [\"null\", \"true\", \"false\", null]\n}"
}; };
axios(config) axios(config)

View File

@ -429,7 +429,7 @@ let options = {
"Content-Type": "application/json" "Content-Type": "application/json"
}, },
body: body:
"{\n\"text\": \"I LOVE Flutter\"\n}" "{\n\"text\": \"I LOVE Flutter\",\n\"flag\": null,\n\"male\": true,\n\"female\": false,\n\"no\": 1.2,\n\"arr\": [\"null\", \"true\", \"false\", null]\n}"
}; };
let status; let status;

View File

@ -415,7 +415,7 @@ let config = {
headers: { headers: {
"Content-Type": "application/json" "Content-Type": "application/json"
}, },
data: "{\n\"text\": \"I LOVE Flutter\"\n}" data: "{\n\"text\": \"I LOVE Flutter\",\n\"flag\": null,\n\"male\": true,\n\"female\": false,\n\"no\": 1.2,\n\"arr\": [\"null\", \"true\", \"false\", null]\n}"
}; };
axios(config) axios(config)

View File

@ -451,7 +451,7 @@ let options = {
"Content-Type": "application/json" "Content-Type": "application/json"
}, },
body: body:
"{\n\"text\": \"I LOVE Flutter\"\n}" "{\n\"text\": \"I LOVE Flutter\",\n\"flag\": null,\n\"male\": true,\n\"female\": false,\n\"no\": 1.2,\n\"arr\": [\"null\", \"true\", \"false\", null]\n}"
}; };
let status; let status;