Jake Wharton
1a6069382e
Provide Array.fill in common stdlib
...
KT-32359
2019-08-01 19:02:38 +03:00
Ilya Gorbunov
804d2b2d8c
Helper utilities to execute test code on particular platforms
2019-06-18 03:59:52 +03:00
Ilya Gorbunov
8badfca459
Fix titlecase lowering in decapitalize
...
Replace isUpperCase() with !isLowerCase check to lower both
upper- and titlecased first chars.
2019-05-29 03:54:46 +03:00
Ilya Gorbunov
a921bd04e0
capitalize/decapitalize: improve docs, add one test
2019-05-29 03:54:46 +03:00
Jake Wharton
af31794f60
Add Locale-accepting overloads for (de)capitalize in JDK stdlib
...
#KT-28933 fixed
2019-05-29 03:35:33 +03:00
Abduqodiri Qurbonzoda
c8a4fa58cd
Implement String to/from ByteArray conversion (KT-24810)
2019-05-06 15:54:28 +03:00
nikita.movshin
65244b4bea
Update copyright.
...
Change the copyright from "JetBrains s.r.o." to
"JetBrains s.r.o. and Kotlin Project contributors"
Update only 2 lines copyright.
2019-04-23 20:09:22 +03:00
Ilya Gorbunov
91c7233ed8
Make Throwable.addSuppressed extension work without kotlin-stdlib-jdk7*
...
*given that it runs on JDK7 and higher. The addSuppressed member
is called with reflection when it's available.
kotlin-stdlib-jdk7 extension still overrides that and calls
addSuppressed member statically as before.
#KT-30560 Fixed
2019-03-28 22:42:20 +03:00
Abduqodiri Qurbonzoda
876dff6d22
Implement fill extension function for UArrays (KT-28339)
2019-03-08 23:34:33 +03:00
Abduqodiri Qurbonzoda
550c74bb6b
Implement binarySearch method for UArrays (KT-27262)
2019-03-08 23:34:33 +03:00
Ilya Gorbunov
f50820045a
Allow setting seed only once, as it is set from superclass constructor
...
Add tests for Java<->Kotlin Random wrappers.
#KT-29520 Fixed
2019-02-13 00:21:22 +03:00
Ilya Gorbunov
7b08f6f8f1
readLine: extend buffer to decode surrogate pairs from utf-8 correctly
...
CharBuffer had capacity to hold 2 chars, which was not enough to append
a surrogate pair when the buffer was not empty.
The buffer was extended and the decoding algorithm rewritten to deal with
a buffer of any length.
#KT-28572 Fixed
2018-12-07 17:42:09 +03:00
Ilya Gorbunov
a534bfc32f
Move index overflow tests to another test source set
...
To avoid reporting them as ignored and to make it more easy to run them
when needed.
2018-11-30 07:27:07 +03:00
Ilya Gorbunov
673844a059
Move coroutine tests to other stdlib-jvm tests
2018-11-28 06:05:02 +03:00
Ilya Gorbunov
8d0d6d1bf3
Do not mutate Matcher in MatchResult.next()
...
Instead of mutating the matcher create a new one when `next()` is called.
This allows getting named groups from that matcher later.
Add lookbehind in matchSequence test to ensure this change doesn't alter
the existing behavior.
Also fixes #KT-20865
2018-11-16 20:29:38 +03:00
Alexander Udalov
55c8b35eee
Remove unneeded default imports in stdlib and tests
2018-10-01 13:39:02 +02:00
Ilya Gorbunov
6786b9ece2
Stdlib tests: cleanup warnings
2018-09-14 15:32:08 +03:00
Mikhail Zarechenskiy
3431123cab
Fixes for tests about mod
...
#KT-25217
2018-09-10 06:31:55 +03:00
Ilya Gorbunov
357c5be4fb
Make sure index and count do not overflow for long sequences
...
Throw an exception immediately before an overflow becomes observable.
Place check to prevent negative index from indexOf, indexOfFirst.
Do not insert overflow checks for arrays, lists, maps and char sequences.
#KT-16097
2018-08-30 14:57:05 +03:00
Ilya Gorbunov
c44f62a3d4
Allow dropping and taking a lot of elements in very long sequences
...
For example allow dropping and taking Int.MAX_VALUE elements from
a sequence that is a result of another Int.MAX_VALUE dropping.
2018-08-30 14:57:03 +03:00
Ilya Gorbunov
eaa0902ea5
Add a class for long-running sequence/iterable tests
...
These tests will not run neither locally nor on CI unless the explicit
"kotlin.stdlib.test.long.sequences" parameter is specified.
2018-08-30 14:57:01 +03:00
Ilya Gorbunov
17e04b2665
Deprecate readBytes with estimatedSize parameter, add overload without parameters
...
Add a test for readBytes.
#KT-19305 Fixed
2018-08-30 14:56:23 +03:00
Ilya Gorbunov
f010231ff7
Change range iteration tests so they are runnable on all platforms
...
Remove JS and Native backend exclusions
2018-08-30 14:56:13 +03:00
Ilya Gorbunov
5f3a7f0147
Use Char.MIN_VALUE and MAX_VALUE in tests
2018-08-30 14:55:45 +03:00
Ilya Gorbunov
db7f4bb402
Deprecate js Math.random and provide replacement with Random.nextDouble
...
#KT-23564 Fixed
2018-08-30 14:52:47 +03:00
Ilya Gorbunov
ed53983e1e
Add support for CASE_INSENSITIVE_ORDER in JS and common
...
#KT-18067
2018-08-15 21:28:54 +03:00
Ilya Gorbunov
be8cb94105
Add failing tests for overflow in empty progressions KT-24204
2018-07-09 22:08:01 +03:00
Ilya Gorbunov
cbc3480d9e
Split common builtin companion tests from JVM-only tests
...
Remove duplicated tests from NumbersJVMTest.
2018-07-03 19:58:53 +03:00
Florian Steitz
8453ed1803
[KT-10456] Move tests from StringNumberConversionJVMTest to StringNumberConversionTest
2018-05-11 15:42:11 +03:00
Ilya Gorbunov
ecf0d7ec0d
Reformat stdlib tests and samples
...
#KT-5558
2018-04-27 05:28:57 +03:00
Ilya Gorbunov
e21c235bbb
Add or update copyrights in the standard library sources
2018-04-26 21:57:50 +03:00
Ilya Gorbunov
2c74b91de4
Remove JvmVersion annotation and its usages
2018-04-23 19:05:13 +03:00
Ilya Gorbunov
f7546c809d
Minor: use common implementation of doubleTotalOrderEquals for tests
2018-04-12 17:53:00 +03:00
Ilya Gorbunov
9b38e5e7b5
stdlib tests: move JVM-only test source files
2018-04-12 17:53:00 +03:00