<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>Hello,</p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 11/16/23 11:02, Sergey Kaplun wrote:<br>
    </div>
    <p><br>
    </p>
    <p><snipped></p>
    <blockquote type="cite" cite="mid:ZVXMjrD8dZsln_yl@root"><span
      style="white-space: pre-wrap">
</span>
      <blockquote type="cite">
        <pre class="moz-quote-pre" wrap="">
diff --git a/test/tarantool-c-tests/lj-881-fix-lua-concat.test.c 
b/test/tarantool-c-tests/lj-881-fix-lua-concat.test.c
index 1835d273..f028c457 100644
--- a/test/tarantool-c-tests/lj-881-fix-lua-concat.test.c
+++ b/test/tarantool-c-tests/lj-881-fix-lua-concat.test.c
@@ -77,7 +77,7 @@ static int lua_concat_testcase(void *test_state)
      const char *str = lua_tostring(L, -1);
      assert_int_equal(lua_gettop(L), top - 2 + 1);
      const char expected_str[] = CONCAT("A + ", TEST_VALUE);
-    assert_str_equal(str, expected_str, strlen(expected_str));
+    assert_str_equal(str, expected_str);

      /* Teardown. */
      lua_settop(L, 0);
diff --git a/test/tarantool-c-tests/test.h b/test/tarantool-c-tests/test.h
index 2f2d9ea2..5e5c96b2 100644
--- a/test/tarantool-c-tests/test.h
+++ b/test/tarantool-c-tests/test.h
@@ -212,15 +212,15 @@ static inline int todo(const char *reason)
      );                                \
  } while (0)

-#define assert_str_equal(got, expected, n) do {                \
-    assert_general(strncmp(got, expected, n) == 0,            \
+#define assert_str_equal(got, expected) do {                \
+    assert_general(strncmp(got, expected, strlen(expected)) == 0,    \
</pre>
      </blockquote>
      <pre class="moz-quote-pre" wrap="">
On the second thought, I insist on using `strcmp()` here since the
expected string is always `\0` terminated, and we use "not safe" the
`strlen()` anyway.</pre>
    </blockquote>
    <p><br>
    </p>
    <p>Updated.</p>
    <p>diff --git a/test/tarantool-c-tests/test.h
      b/test/tarantool-c-tests/test.h<br>
      index 5e5c96b2..3b22fb92 100644<br>
      --- a/test/tarantool-c-tests/test.h<br>
      +++ b/test/tarantool-c-tests/test.h<br>
      @@ -213,14 +213,14 @@ static inline int todo(const char *reason)<br>
       } while (0)<br>
       <br>
       #define assert_str_equal(got, expected) do
      {                           \<br>
      -       assert_general(strncmp(got, expected, strlen(expected)) ==
      0,   \<br>
      +       assert_general(strcmp(got, expected) ==
      0,                      \<br>
                             ASSERT_EQUAL_FMT(str,
      "%s"),                     \<br>
                             __FILE__, __LINE__, (got),
      (expected)            \<br>
             
      );                                                              \<br>
       } while (0)<br>
       <br>
       #define assert_str_not_equal(got, unexpected) do
      {                     \<br>
      -       assert_general(strncmp(got, expected, strlen(expected)) !=
      0,   \<br>
      +       assert_general(strcmp(got, expected) !=
      0,                      \<br>
                             ASSERT_NOT_EQUAL_FMT(str,
      "%s"),                 \<br>
                             __FILE__, __LINE__, (got),
      (unexpected)          \<br>
             
      );                                                              \<br>
      <br>
    </p>
    <pre class="moz-quote-pre" wrap="">
</pre>
    <p></p>
    <blockquote type="cite" cite="mid:ZVXMjrD8dZsln_yl@root">
      <pre class="moz-quote-pre" wrap="">

</pre>
      <blockquote type="cite">
        <pre class="moz-quote-pre" wrap="">                 ASSERT_EQUAL_FMT(str, "%s"),            \
                 __FILE__, __LINE__, (got), (expected)        \
      );                                \
  } while (0)

-#define assert_str_not_equal(got, unexpected, n) do { \
-    assert_general(strncmp(got, expected, n) != 0,            \
+#define assert_str_not_equal(got, unexpected) do {            \
+    assert_general(strncmp(got, expected, strlen(expected)) != 0,    \
</pre>
      </blockquote>
      <pre class="moz-quote-pre" wrap="">
Ditto.</pre>
    </blockquote>
    Ditto.<br>
    <blockquote type="cite" cite="mid:ZVXMjrD8dZsln_yl@root">
      <pre class="moz-quote-pre" wrap="">

</pre>
      <blockquote type="cite">
        <pre class="moz-quote-pre" wrap="">                 ASSERT_NOT_EQUAL_FMT(str, "%s"),            \
                 __FILE__, __LINE__, (got), (unexpected)        \
      );                                \

</pre>
        <blockquote type="cite">
          <pre class="moz-quote-pre" wrap="">
</pre>
          <blockquote type="cite">
            <pre class="moz-quote-pre" wrap="">+                       ASSERT_NOT_EQUAL_FMT(str, "%s"),                 \
+                       __FILE__, __LINE__, (got), (unexpected)          \
+        );                                                              \
+} while (0)
+
  #endif /* TARANTOOL_LUAJIT_TEST_H */
</pre>
          </blockquote>
        </blockquote>
      </blockquote>
      <pre class="moz-quote-pre" wrap="">
</pre>
    </blockquote>
  </body>
</html>