Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: RIOT-OS/RIOT
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: a1fd37b7cf544ecb2aace5053a45e4a3d06b3916
Choose a base ref
..
head repository: RIOT-OS/RIOT
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 6c24d62b0689b8d341d5593fe8323de6cc6a04bc
Choose a head ref
Showing with 10 additions and 10 deletions.
  1. +10 −10 tests/unittests/tests-uri_parser/tests-uri_parser.c
20 changes: 10 additions & 10 deletions tests/unittests/tests-uri_parser/tests-uri_parser.c
Original file line number Diff line number Diff line change
@@ -45,8 +45,8 @@ static void _print_return_expectation(const char *uri, int expected, int observe
* The uri_parser returns string-buffer(not zero terminated strings).
* This function compares a given string with a given uri_parser buffer + length.
* Additionally, it takes the original uri (from the test vector) and a name
* in order to print a precise and helpfull error message if the buffer and string
* arn't identical.
* in order to print a precise and helpful error message if the buffer and string
* aren't identical.
*/
static int _compare_string_buffer(const char *name, const char *input_uri, const char *expected_str,
const char *actual_str, size_t actual_len)
@@ -64,10 +64,10 @@ static int _compare_string_buffer(const char *name, const char *input_uri, const
/*
* Given a simple valid uri, this test checks that the parsing returns success
*/
static void _successfull_parsing_of_valid_uri(void)
static void _successful_parsing_of_valid_uri(void)
{
char *failure_msg = "Failure: The uri_parser failed to parse a correct and valid uri.";
int expected_ret = 0; /* Indicates a successfull parsing */
int expected_ret = 0; /* Indicates a successful parsing */

char *simple_uri_00 = "coap://example.org/foo/bar";
char *simple_uri_01 = "ftp://riot-os.org/bar/foo";
@@ -159,7 +159,7 @@ static void _successfull_parsing_of_valid_uri(void)
/*
* Given a simple invalid uri, this test checks that the parsing returns an error
*/
static void _successfull_rejecting_of_invalid_uri(void)
static void _successful_rejecting_of_invalid_uri(void)
{
char *failure_msg = "Failure: The uri_parser failed to reject an invalid uri.";
int expected_ret = -1; /* Indicates an invalid uri */
@@ -272,7 +272,7 @@ static void _error_if_port_str_contains_illegal_characters(void)

/*
* Given a uri which contains a scheme, this tests checks that the
* uri_parser can isolate that scheme successfull.
* uri_parser can isolate that scheme successful.
*/
static void _result_component_scheme_matches_input_scheme(void)
{
@@ -317,7 +317,7 @@ static void _result_component_scheme_matches_input_scheme(void)
/* if the uri_parser return indicates success
* the length of the schemes must match.
* we can't use strlen on the result scheme as it is not null terminated,
* but the uri_parser provides the length seperatly*/
* but the uri_parser provides the length separately*/
if (uri_res.scheme_len != strlen(test_vec[i]->scheme)) {
printf(
"With given input uri '%s', expected a scheme with the length '%d' but got '%d'\n",
@@ -494,7 +494,7 @@ static void _result_components_matches_input(void)
/* if the uri_parser return indicates success
* the length of the schemes must match.
* we can't use strlen on the result scheme as it is not null terminated,
* but the uri_provides the length seperatly*/
* but the uri_provides the length separately*/
if (uri_res.scheme_len != strlen(this_vec->scheme)) {
printf(
"With given input uri '%s', expected a scheme with the length '%d' but got '%d'\n",
@@ -609,8 +609,8 @@ static void test_uri_parser__unterminated_string(void)
Test *tests_uri_parser_tests(void)
{
EMB_UNIT_TESTFIXTURES(fixtures) {
new_TestFixture(_successfull_parsing_of_valid_uri),
new_TestFixture(_successfull_rejecting_of_invalid_uri),
new_TestFixture(_successful_parsing_of_valid_uri),
new_TestFixture(_successful_rejecting_of_invalid_uri),
new_TestFixture(_error_if_port_str_is_too_long),
new_TestFixture(_error_if_port_str_contains_illegal_characters),
new_TestFixture(_result_component_scheme_matches_input_scheme),