Skip to content

Commit

Permalink
update testcase.
Browse files Browse the repository at this point in the history
  • Loading branch information
huiguangjun committed Sep 14, 2024
1 parent 71cda28 commit f4ff37f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions oss_c_sdk_test/test_oss_object.c
Original file line number Diff line number Diff line change
Expand Up @@ -2055,6 +2055,13 @@ void test_object_with_invalid_endpoint(CuTest *tc)
params, &buffer, &resp_headers);
CuAssertIntEquals(tc, 200, s->code);

aos_str_set(&options->config->endpoint, "#www.test.com*www.aliyuncs.com");
s = oss_get_object_to_buffer(options, &bucket, &object, headers,
params, &buffer, &resp_headers);
CuAssertIntEquals(tc, AOSE_NAME_LOOKUP_ERROR, s->code);
CuAssertStrEquals(tc, AOS_HTTP_IO_ERROR_CODE, s->error_code);
CuAssertStrEquals(tc, "Couldn't resolve host name", s->error_msg);

aos_pool_destroy(p);

printf("test_object_with_invalid_endpoint ok\n");
Expand Down

0 comments on commit f4ff37f

Please sign in to comment.