1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/test/ruby
duerst 3628eae2e7 implement special behavior for Georgian for String#capitalize
The modern Georgian script is special in that it has an 'uppercase'
variant called MTAVRULI which can be used for emphasis of whole words,
for screamy headlines, and so on. However, in contrast to all other
bicameral scripts, there is no usage of capitalizing the first letter
in a word or a sentence. Words with mixed capitalization are not used
at all.

We therefore implement special behavior for String#capitalize. Formally,
we define String#capitalize as first applying String#downcase for the
whole string, then using titlecase on the first letter. Because Georgian
defines titlecase as the identity function both for MTAVRULI ('uppercase')
and Mkhedruli (lowercase), this results in String#capitalize being
equivalent to String#downcase for Georgian. This avoids undesirable
mixed case.

* enc/unicode.c: Actual implementation

* string.c: Add mention of this special case for documentation

* test/ruby/enc/test_case_mapping.rb: Add two tests, a general one
  that uses String#capitalize on some (including nonsensical)
  combinations of MTAVRULI and Mkhedruli, and a canary test to
  detect the potential assignment of characters to the currently
  open slots (holes) at U+1CBB and U+1CBC.

* test/ruby/enc/test_case_comprehensive.rb: Tweak generation of
  expectation data.

Together with r65933, this closes issue #14839.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-12-09 23:14:29 +00:00
..
enc implement special behavior for Georgian for String#capitalize 2018-12-09 23:14:29 +00:00
allpairs.rb
beginmainend.rb
bug-11928.rb
bug-13526.rb
lbtest.rb
marshaltestlib.rb
sentence.rb
test_alias.rb
test_argf.rb Fix error when Encoding.default_external is Encoding::IBM437 2018-08-09 09:36:03 +00:00
test_arithmetic_sequence.rb enumerator.c: Fix ArithmeticSequence for complex step 2018-09-12 07:35:42 +00:00
test_arity.rb
test_array.rb Fix error message 2018-12-04 09:16:49 +00:00
test_assignment.rb
test_ast.rb Refine RubyVM::AbstractSyntaxTree::Node#type 2018-12-03 01:06:34 +00:00
test_autoload.rb try to remove some test skips for MJIT 2018-10-21 15:54:50 +00:00
test_backtrace.rb Revert "Add test for cause on pty" 2018-10-28 17:03:36 +00:00
test_basicinstructions.rb
test_beginendblock.rb
test_bignum.rb
test_call.rb
test_case.rb
test_class.rb
test_clone.rb
test_comparable.rb
test_complex.rb complex.c: small optimization of Complex#** 2018-10-20 02:49:18 +00:00
test_complex2.rb
test_complexrational.rb
test_condition.rb
test_const.rb
test_continuation.rb Give up support for cross-callcc set_trace_func. 2018-11-26 19:59:08 +00:00
test_default_gems.rb
test_defined.rb
test_dir.rb Fix r65926 test_dir.rb for windows (tilde) 2018-11-24 00:55:26 +00:00
test_dir_m17n.rb
test_econv.rb
test_encoding.rb
test_enum.rb introduce TransientHeap. [Bug #14858] 2018-10-30 21:53:56 +00:00
test_enumerator.rb Implement Enumerator#+ and Enumerable#chain [Feature #15144] 2018-11-24 08:38:35 +00:00
test_env.rb Removed Windows version condition 2018-10-01 07:50:08 +00:00
test_eval.rb
test_exception.rb Warn redefinitions of some methods on Object 2018-12-06 23:06:13 +00:00
test_fiber.rb Avoid GCing dead stack after switching away from a fiber 2018-12-01 03:49:52 +00:00
test_file.rb
test_file_exhaustive.rb Document File.{setuid?,setgid?,sticky?} support for IO objects [Bug #13972] 2018-10-20 11:47:45 +00:00
test_fixnum.rb
test_flip.rb
test_float.rb
test_fnmatch.rb
test_gc.rb
test_hash.rb Adjust reserved hash values 2018-12-07 12:03:16 +00:00
test_ifunless.rb
test_integer.rb Warn redefinitions of some methods on Object 2018-12-06 23:06:13 +00:00
test_integer_comb.rb
test_io.rb test/ruby/test_io.rb (test_recycled_fd_close): remove hacks 2018-11-30 11:44:21 +00:00
test_io_m17n.rb
test_iseq.rb Return same ISeq object for one src. 2018-12-06 10:52:27 +00:00
test_iterator.rb
test_jit.rb Speed up hash literals by duping 2018-12-06 18:28:21 +00:00
test_key_error.rb
test_keyword.rb parse.y: fix block passing with empty kwargs 2018-09-20 01:43:35 +00:00
test_lambda.rb
test_lazy_enumerator.rb
test_literal.rb Collapse putobject, putobject, newarray 2018-12-03 23:53:11 +00:00
test_m17n.rb string.c: setbyte silently ignores upper bits 2018-11-19 09:52:46 +00:00
test_m17n_comb.rb
test_marshal.rb
test_math.rb
test_metaclass.rb
test_method.rb Proc#<< and Proc#>> 2018-11-22 05:51:43 +00:00
test_mixed_unicode_escapes.rb
test_module.rb Fix problem about notimplemented case 2018-08-13 13:48:27 +00:00
test_not.rb
test_notimp.rb
test_numeric.rb enumerator.c: Introduce Enumerator::ArithmeticSequence 2018-08-06 09:08:28 +00:00
test_object.rb Warn redefinitions of some methods on Object 2018-12-06 23:06:13 +00:00
test_objectspace.rb
test_optimization.rb compile.c: fix peephole optimization 2018-10-24 10:38:39 +00:00
test_pack.rb pack.c: refine warning 2018-11-16 00:25:54 +00:00
test_parse.rb parse.y: remove "shadowing outer local variable" warning 2018-10-26 03:10:02 +00:00
test_path.rb
test_pipe.rb
test_primitive.rb
test_proc.rb Proc#<< and Proc#>> 2018-11-22 05:51:43 +00:00
test_process.rb process.c: fix ETXTBUSY from MJIT compiler process 2018-12-03 19:49:54 +00:00
test_rand.rb random.c: endless range random 2018-08-03 06:31:22 +00:00
test_range.rb range.c: Add Range#% 2018-09-28 02:18:58 +00:00
test_rational.rb refine parse_rat 2018-11-08 02:25:44 +00:00
test_rational2.rb
test_readpartial.rb
test_refinement.rb Enable refinements at Object#respond_to? 2018-11-22 08:29:02 +00:00
test_regexp.rb commit miss 2018-12-04 10:51:57 +00:00
test_require.rb
test_rubyoptions.rb parse.y: remove "shadowing outer local variable" warning 2018-10-26 03:10:02 +00:00
test_rubyvm.rb
test_rubyvm_mjit.rb skip tests if --disable-mjit-support. 2018-10-20 08:06:50 +00:00
test_settracefunc.rb add tests for script_compiled TP event. 2018-12-06 13:53:48 +00:00
test_signal.rb thread_pthread.c: main thread always gets hit by signals 2018-08-25 21:59:30 +00:00
test_sleep.rb
test_sprintf.rb test_sprintf.rb: test for %p 2018-09-15 08:39:07 +00:00
test_sprintf_comb.rb
test_string.rb change diaeresis from above to below for better visibility 2018-12-04 10:49:55 +00:00
test_stringchar.rb
test_struct.rb Enumerable#to_h with block and so on 2018-09-20 15:06:56 +00:00
test_super.rb
test_symbol.rb Revert "Symbol refinements" 2018-12-04 04:22:08 +00:00
test_syntax.rb parser: improve error messages 2018-11-25 08:31:40 +00:00
test_system.rb test/ruby/test_system.rb: suppress prompt and echo on Windows 2018-08-18 02:44:35 +00:00
test_thread.rb thread_sync.c (mutex_ptr): handle mutexes held by parent threads in children 2018-12-05 18:58:45 +00:00
test_thread_cv.rb revisit more MJIT test skips 2018-10-22 15:49:22 +00:00
test_thread_queue.rb appveyor.yml: give up running TestThreadQueue#test_queue_with_trap 2018-10-07 14:05:56 +00:00
test_threadgroup.rb
test_time.rb Normalize month-mday before finding epoch 2018-11-25 16:23:18 +00:00
test_time_tz.rb time.c: rescue find_timezone when loading 2018-11-28 14:08:35 +00:00
test_trace.rb
test_transcode.rb
test_undef.rb Test for undef'ed method in class hierachy 2018-11-16 04:21:57 +00:00
test_unicode_escape.rb
test_variable.rb
test_vm_dump.rb
test_weakmap.rb
test_whileuntil.rb
test_yield.rb
ut_eof.rb