Commit graph

20 commits

Author SHA1 Message Date
Oleksandr Byelkin
ea75a0b600 Merge branch '11.4' into 11.5 2024-08-05 17:50:18 +02:00
Sergei Golubchik
66f14ef6a1 update C/C 3.4
note that:
* unit.conc_tls is broken in mtr
* schannel now doesn't fail on invalid ca path unless
  --ssl-verify-server-cert is used. openssl still does.
2024-08-04 17:28:08 +02:00
Alexander Barkov
fd247cc21f MDEV-31340 Remove MY_COLLATION_HANDLER::strcasecmp()
This patch also fixes:
  MDEV-33050 Build-in schemas like oracle_schema are accent insensitive
  MDEV-33084 LASTVAL(t1) and LASTVAL(T1) do not work well with lower-case-table-names=0
  MDEV-33085 Tables T1 and t1 do not work well with ENGINE=CSV and lower-case-table-names=0
  MDEV-33086 SHOW OPEN TABLES IN DB1 -- is case insensitive with lower-case-table-names=0
  MDEV-33088 Cannot create triggers in the database `MYSQL`
  MDEV-33103 LOCK TABLE t1 AS t2 -- alias is not case sensitive with lower-case-table-names=0
  MDEV-33109 DROP DATABASE MYSQL -- does not drop SP with lower-case-table-names=0
  MDEV-33110 HANDLER commands are case insensitive with lower-case-table-names=0
  MDEV-33119 User is case insensitive in INFORMATION_SCHEMA.VIEWS
  MDEV-33120 System log table names are case insensitive with lower-cast-table-names=0

- Removing the virtual function strnncoll() from MY_COLLATION_HANDLER

- Adding a wrapper function CHARSET_INFO::streq(), to compare
  two strings for equality. For now it calls strnncoll() internally.
  In the future it will turn into a virtual function.

- Adding new accent sensitive case insensitive collations:
    - utf8mb4_general1400_as_ci
    - utf8mb3_general1400_as_ci
  They implement accent sensitive case insensitive comparison.
  The weight of a character is equal to the code point of its
  upper case variant. These collations use Unicode-14.0.0 casefolding data.

  The result of
     my_charset_utf8mb3_general1400_as_ci.strcoll()
  is very close to the former
     my_charset_utf8mb3_general_ci.strcasecmp()

  There is only a difference in a couple dozen rare characters, because:
    - the switch from "tolower" to "toupper" comparison, to make
      utf8mb3_general1400_as_ci closer to utf8mb3_general_ci
    - the switch from Unicode-3.0.0 to Unicode-14.0.0
  This difference should be tolarable. See the list of affected
  characters in the MDEV description.

  Note, utf8mb4_general1400_as_ci correctly handles non-BMP characters!
  Unlike utf8mb4_general_ci, it does not treat all BMP characters
  as equal.

- Adding classes representing names of the file based database objects:

    Lex_ident_db
    Lex_ident_table
    Lex_ident_trigger

  Their comparison collation depends on the underlying
  file system case sensitivity and on --lower-case-table-names
  and can be either my_charset_bin or my_charset_utf8mb3_general1400_as_ci.

- Adding classes representing names of other database objects,
  whose names have case insensitive comparison style,
  using my_charset_utf8mb3_general1400_as_ci:

  Lex_ident_column
  Lex_ident_sys_var
  Lex_ident_user_var
  Lex_ident_sp_var
  Lex_ident_ps
  Lex_ident_i_s_table
  Lex_ident_window
  Lex_ident_func
  Lex_ident_partition
  Lex_ident_with_element
  Lex_ident_rpl_filter
  Lex_ident_master_info
  Lex_ident_host
  Lex_ident_locale
  Lex_ident_plugin
  Lex_ident_engine
  Lex_ident_server
  Lex_ident_savepoint
  Lex_ident_charset
  engine_option_value::Name

- All the mentioned Lex_ident_xxx classes implement a method streq():

  if (ident1.streq(ident2))
     do_equal();

  This method works as a wrapper for CHARSET_INFO::streq().

- Changing a lot of "LEX_CSTRING name" to "Lex_ident_xxx name"
  in class members and in function/method parameters.

- Replacing all calls like
    system_charset_info->coll->strcasecmp(ident1, ident2)
  to
    ident1.streq(ident2)

- Taking advantage of the c++11 user defined literal operator
  for LEX_CSTRING (see m_strings.h) and Lex_ident_xxx (see lex_ident.h)
  data types. Use example:

  const Lex_ident_column primary_key_name= "PRIMARY"_Lex_ident_column;

  is now a shorter version of:

  const Lex_ident_column primary_key_name=
    Lex_ident_column({STRING_WITH_LEN("PRIMARY")});
2024-04-18 15:22:10 +04:00
Marko Mäkelä
f9b856b052 Merge 10.2 into 10.3 2021-10-21 17:39:34 +03:00
Sergei Krivonos
7d6617e966 MDEV-19129: Xcode compatibility update: mysql-test-run.pl: rename $opt_vs_config to $multiconfig to use with other cmake multiconfig generators 2021-10-21 16:48:00 +03:00
Monty
ecc1cd219d Fixed that unit.pcre_test works again. 2021-03-05 14:12:56 +02:00
Monty
3f15d3bad9 Fixed unit test to not 'bail out' if some tests are not compiled.
Before the changes two things could happen:
- "path required name explain_filename path" error
- unit test never finishead (as it tried to execute just /bin/sh as
  a test case)
2021-03-01 22:09:05 +02:00
Sergei Golubchik
b942aa34c1 Merge branch '10.1' into 10.2 2018-06-21 23:47:39 +02:00
Sergei Golubchik
d8192f5495 Merge branch '5.5' into 10.0 2018-06-21 00:44:10 +02:00
Sergei Golubchik
2b8f2b3e88 Fix unit suite on Windows and in out-of-source builds 2018-06-21 00:06:15 +02:00
Sergei Golubchik
0a9d78f51d Revert "MDEV-16075: Workaround to run MTR test suite for make test"
This reverts commit d39629f01e.

Because running mtr for many hours with no output whatsoever
is not really what we should do.

And in 5.5 `make test` just works anyway, nothing to fix here.
2018-06-20 23:27:23 +02:00
Vicențiu Ciorbaru
3ead951180 Merge branch '5.5' into 10.0 2018-06-10 17:16:27 +03:00
Teodor Mircea Ionita
d39629f01e MDEV-16075: Workaround to run MTR test suite for make test
Assign all tests added via MY_ADD_TEST to a bogus default_ignore target,
so that they are not ran by default when doing bare make test. Add default
test named MTR that calls mysql-test-run suite, which is now the single
test run by make test.

In consequence, modified unit/suite.pm to exclude the MTR test and run the
real ctests flagged for default_ignore target, thus no circular
loop.
2018-06-10 10:14:31 +03:00
Vladislav Vaintroub
d49f8e9f05 Windows,tests : fix pcre_test_bat test from pcre library.
Tests that are not available in certain configurations, are marked as
Test command : NOT_AVAILABLE in ctest output.

pcre_test_bat does not work without ctest's -C option (--build-config
that was used earlier was wrong).
2018-02-14 23:21:58 +00:00
Sergei Golubchik
9ec8500998 update libmariadb, enable C/C unit tests 2017-03-30 09:27:03 +02:00
Sergei Golubchik
8599f16b9d fix mysql-test unit suite to work for out-of-source builds 2017-03-30 09:12:33 +02:00
Sergei Golubchik
10e1ff83ec better identify C/C unit tests in mysql-test 2016-09-12 17:51:50 +02:00
Alexander Barkov
285e7aa179 MDEV-4425 REGEXP enhancements 2013-09-26 18:02:17 +04:00
Sergei Golubchik
b3223453f7 post-merge changes to the mysql-test suite
mysql-test/include/check_ipv6.inc:
  don't try to connect to ipv6 address - the server isn't necessarily listening
  (e.g. a master doesn't, but a slave does. or vice versa)
mysql-test/include/default_mysqld.cnf:
  move hard-coded values from ConfigFactory.pm to a template.
  really disable syncs
mysql-test/include/have_archive_plugin.inc:
  wrong test. plugin is loaded in the test, it cannot be available before it
mysql-test/include/have_blackhole_plugin.inc:
  wrong test. plugin is loaded in the test, it cannot be available before it
mysql-test/include/have_federated_plugin.inc:
  wrong test. plugin is loaded in the test, it cannot be available before it
mysql-test/lib/My/ConfigFactory.pm:
  move hard-coded values from ConfigFactory.pm to a template.
  really disable syncs
mysql-test/mysql-test-run.pl:
  formatting
mysql-test/suite/funcs_1/t/is_engines_federated.opt:
  federated can be a plugin
mysql-test/suite/innodb/suite.pm:
  don't load xtradb plugin in embedded server - it lacks some symbols that xtradb needs
mysql-test/suite/unit/suite.pm:
  don't run unit tests in --embedded-server
  (for simplicity and speed)
2011-10-19 23:01:15 +02:00
Sergei Golubchik
011cbe9088 move ctest handling from mtr to a separate suite 2011-07-16 09:59:15 +02:00