e2351b133933cbf0356447b6623ca39fa6cb4963 |
24-Aug-2013 |
Elliott Hughes <enh@google.com> |
Fix three failing tests. Increase an overly-tight timeout in SelectorTest. Remove an incorrect assertion about a return type. Remove an assertion testing fallback behavior of Currency.getDisplayName where icu4c's behavior changes between releases and the RI doesn't match its own documentation. (cherry-pick of 8b3d7dfa1b50eb611b20824242f35eba2cfba46e.) Bug: 10210895 Change-Id: Ia21b7c20056646cfc3e8cc784741ef2cbd10b7df
hannels/SelectorTest.java
|
f5d8857b623192a985e449453de5bf1efaa4ea79 |
16-Aug-2013 |
Elliott Hughes <enh@google.com> |
Fix a bunch of Charset tests. The isRegistered test is still failing. The problem is that icu4c's convrtrs.txt has names like "windows-1252" that are both the canonical name for one charset and an alias for another legacy charset. I need to work out how to resolve that. Bug: 10210999 (cherry picked from commit ea1caf4ccc5c2255f384c0774aa9e055763a6a41) Change-Id: I83cf1b9ae1d29f9956f443ef914a3e473e0f4692
harset/CharsetTest.java
|
d2c0afea30836a78a134a87fa23197cf72f83e6e |
14-Aug-2013 |
Elliott Hughes <enh@google.com> |
Remove tests of charsets not in a regular icu4c build. (cherry picked from commit 01118de1969214fa0ce09a28bbe74c89e166e482) Change-Id: Ib774cb1ab4bc85e529299b8174bcbf7e794f2225
harset/OldCharset_GSM0338.java
harset/OldCharset_ISO_8859_16.java
|
9edca89080204647492b04f848107bcb90798a1c |
14-Aug-2013 |
Elliott Hughes <enh@google.com> |
Work around icu4c causing canEncode to always return true for surrogates. Bug: 10310751 (cherry picked from commit bb317b5a6ff071ee4ffa0b4e811367be962238b7) Change-Id: Id31ea5715c1e3f744ed8eb33d6a7f3cca03159d1
harset/OldCharset_AbstractTest.java
|
37d444181115a38ebb3b5183f2da66669c2de06a |
14-Aug-2013 |
Elliott Hughes <enh@google.com> |
Fix CharsetTest for SCSU and Shift_JIS. We went from using approximations to using the real thing, but didn't tell the tests. I've also added the reverse tests, because that's what we really care about --- that the byte sequence decodes as the replacement character. Bug: 10310458 (cherry picked from commit 075bdfb276c6377cc90e568bdfcf6ffb31bed1f6) Change-Id: I344c5a74c31fea9491bbe43198fde606dac7722c
harset/CharsetTest.java
|
817b74b58acb99b2e161228e329a6e6ae2d9d62b |
23-Jul-2013 |
Elliott Hughes <enh@google.com> |
Remove HistoricalCharsetNames. Bug: 3032697 Change-Id: Idbf92cded4a7c55b97ee558b0fa844237d262206
harset/CharsetTest.java
|
fc481238e31d95648c1f0181bb0df1d8e7d0dedb |
22-Jul-2013 |
Elliott Hughes <enh@google.com> |
Various icu-related test fixes. Change-Id: I5661145c7a9ff4b3f3187659a74c0696c59d7a26
harset/CharsetEncoderTest.java
harset/Charset_TestGenerator.java
harset/OldCharset_AbstractTest.java
harset/OldCharset_MultiByte_EUC_JP.java
harset/OldCharset_MultiByte_EUC_JP_Android.java
harset/OldCharset_MultiByte_ISO_2022_JP.java
|
57656d21f772aacbe0d05e54b1274f4c58993a52 |
10-Jul-2013 |
Elliott Hughes <enh@google.com> |
Fix Selector to allow read and write at the same time. Bug: https://code.google.com/p/android/issues/detail?id=57456 Change-Id: I29e6688aafce886803bbbd12793df3ab952459c8
hannels/SelectorTest.java
|
c43083ece7c4479fbe38001983a0d28893d0812a |
22-Jun-2013 |
Elliott Hughes <enh@google.com> |
Fix the SocketChannel accept locking behavior. Fixes a harmony-tests/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/ServerSocketChannelTest test that had been failing since we turned it back on. Change-Id: I76cbc5edc1ab9edc4d2818bd23649f4b906d662c
hannels/SocketChannelTest.java
|
c6ad01d286af243fd300dd105eb2e4437e0b6b16 |
21-Jun-2013 |
Elliott Hughes <enh@google.com> |
Fix non-blocking SocketChannel connects. There are many reasons why the initial connect(2) may have resulted in a ConnectException, only one of which (EINPROGRESS) means we haven't yet failed. Bug: https://code.google.com/p/android/issues/detail?id=56684 Change-Id: I2115998bce9043f076418fb0d1c22a26e04ee2e1
hannels/SocketChannelTest.java
|
9ce6a2533b50ffcd24b8b10bae7f234042768819 |
29-Mar-2013 |
Joel Dice <joel.dice@gmail.com> |
Use long instead of int for address in DirectByteBuffer constructor This allows the code to be used on 64-bit platforms. Change-Id: I1c42d48696296f74135cd209b3042b8973779e40
ufferTest.java
|
fe5da19e0e366286cd4d95f7628fe9442b9062c8 |
27-Mar-2013 |
Elliott Hughes <enh@google.com> |
Simplify the nio Buffer implementations, and fix MappedByteBuffer. * Fix the reported bug caused by delegation in the MappedByteBuffer implementation. * Collapse the three classes (ReadOnly*, ReadWrite*, and *) used to implement most buffer types into one class each. * Rename HeapByteBuffer to ByteArrayBuffer to match its companions. * Remove BaseByteBuffer. * Give the classes used to implement asXBuffer sane names (their existing names were backwards). Bug: https://code.google.com/p/android/issues/detail?id=53637 Change-Id: I2a7ff4f1d502564389615384324afadabccb04f9
ufferTest.java
|
856cd831370ab9d10c8bde1bbf6e4cd02ff7c342 |
17-Jan-2013 |
Elliott Hughes <enh@google.com> |
Add a regression test for an icu4c bug. The bug was already fixed as part of the icu4c 4.9 upgrade, so there's no corresponding fix. Bug: http://code.google.com/p/android/issues/detail?id=42769 Change-Id: I2ceed6e9c1bc230683e6c8b9f38aaadee371eeef
harset/CharsetTest.java
|
385c6f4303341beb9b091b6d252811b7ca3b9f42 |
20-Dec-2012 |
Nick Kralevich <nnk@google.com> |
FileChannelImpl: Ignore ftruncate failures on non-regular files Truncate only works on regular files. On other files, such as UNIX character devices, truncate returns EINVAL, which causes an IOException to be thrown. With this change, we now have support for creating a MappedByteBuffer on UNIX character devices such as /dev/zero, if the underlying device node supports mmap(). Change-Id: I094371d821b187abe3da32edc411ff76a81b047e
ufferTest.java
|
babccbf9e429c4c78aca24c205825ceaaf7d3f37 |
13-Oct-2012 |
Elliott Hughes <enh@google.com> |
Fix ConcurrentCloseTest flakiness. We can't rely on consuming all the listen(2) backlog. For the tests we've seen fail because they sometimes connect rather than time out, switch to an unroutable address. Bug: 6971145 Change-Id: I259d31b1a15123bcd78c36849d5ed863d392ac20
hannels/SelectorTest.java
|
8962582befb42ab2cfe642ab107d0694f844f84c |
30-Jul-2012 |
Elliott Hughes <enh@google.com> |
am b7dd9ee6: Merge "Repair the damage I did removing "useless" checkIndex calls from the asXBuffer adapter classes." * commit 'b7dd9ee69383daef7e0192b83bdc8257739679bd': Repair the damage I did removing "useless" checkIndex calls from the asXBuffer adapter classes.
|
86f5f3e0e2bd808e4c85b0563ae50f17b7d48309 |
30-Jul-2012 |
Elliott Hughes <enh@google.com> |
Repair the damage I did removing "useless" checkIndex calls from the asXBuffer adapter classes. The checkIndex calls were unnecessary as far as throwing the right Exception subclass goes, but they're necessary if you want the detail message to use the units of the wrapping buffer rather than the wrapped buffer. And we want that. An IndexOutOfBoundsException that says "offset=0, limit=1" is only going to confuse developers. (Fixes bug introduced by 26841c0bb838d54fea2e1a06390e413fab561e27.) Bug: 6085292 Change-Id: I9a1a5991ad383b7712642e40bced9af91440bed2
ufferTest.java
|
7a593cd77d71a19f3d003a75582b9808d9f3b207 |
27-Jul-2012 |
Elliott Hughes <enh@google.com> |
am f9b430c6: Merge "Remove useless checkIndex calls from the asXBuffer adapter classes." * commit 'f9b430c6d3dbb89da2b93d96ff42e7b84f9c2a13': Remove useless checkIndex calls from the asXBuffer adapter classes.
|
26841c0bb838d54fea2e1a06390e413fab561e27 |
26-Jul-2012 |
Elliott Hughes <enh@google.com> |
Remove useless checkIndex calls from the asXBuffer adapter classes. Also add tests that we throw the expected exceptions. Bug: 6085292 Change-Id: Ibcc44bdb546cba5365cdf557847e068fea77e1ca
ufferTest.java
|
7c6ba10e58381610d0028375406dab3137b0eb0c |
19-Jul-2012 |
Elliott Hughes <enh@google.com> |
resolved conflicts for merge of 02ba68ce to jb-dev-plus-aosp Change-Id: I1c896520ac7c4d5cd76463a091af2a98b76ddd30
|
903b3f5b6a6e524cb4d88b83ea32e7c355392271 |
19-Jul-2012 |
Elliott Hughes <enh@google.com> |
Start removing Support_PortManager. A bad idea, badly implemented. Bug: 2441548 Change-Id: I34c990f6fd9d746771846f186a7ab3ab59e78a9f
hannels/OldServerSocketChannelTest.java
hannels/OldSocketChannelTest.java
|
6a57effa362779c04081a5b1588410c3953aa2b1 |
17-Jul-2012 |
Elliott Hughes <enh@google.com> |
Remove flakiness from OldSocketChannelTest#test_socketChannel_read_DirectByteBuffer. Bug: 6744638 Change-Id: Ic0cf7d51d9aa709e19d611b1cee27771487ed55e
hannels/OldSocketChannelTest.java
|
f7bd2a99f6f4024e9034300b30a13a2ea871aa97 |
12-May-2012 |
Elliott Hughes <enh@google.com> |
Work around poll(2) failing with EINTR. This restores the gingerbread behavior, which is arguably pretty annoying too, but it's what we've always done so less likely to be disruptive. Bug: 6453247 Change-Id: I22635e36a37cb36cf2b22d1739ab6a28662c9188
hannels/SelectorTest.java
|
bdd17cde8cf675f5d5703aad4dfb565932fb4c50 |
08-Feb-2012 |
Elliott Hughes <enh@google.com> |
Fix an ICS regression with hasArray on a JNI-allocated DirectByteBuffer. Bug: http://code.google.com/p/android/issues/detail?id=24327 Change-Id: Ib31b60fe01e3d0b5a1ed7125ddf047e09fd64056
ufferTest.java
|
fb2316ae2477e30908bd4b68f48ad576778af186 |
13-Jun-2011 |
claireho <chinglanho@gmail.com> |
am eda291fb: Merge "Libcore changes corresponding to ICU4.6 upgrade." * commit 'eda291fb13114022525fb7687eb6b33206c02f5f': Libcore changes corresponding to ICU4.6 upgrade.
|
e3d7539b3cb1e763f1ed5832120684468e635d94 |
10-Jun-2011 |
Elliott Hughes <enh@google.com> |
Tidy transferFrom a little. Other than documentation, the only real change here is to stop using direct buffers, which doesn't gain us anything (and does have a cost). Bug: 4109660 Change-Id: Iebf3eb9cee6038af68443cd061718d584040010e
hannels/OldFileChannelTest.java
|
e3b6fa2bf357f2712ab2ee9e8487f157595ea0c7 |
10-Jun-2011 |
Elliott Hughes <enh@google.com> |
Expose pread and pwrite. And fix FileChannel to use them. Bug: 4183719 Bug: 3107501 Change-Id: I51114a16522b93bf959b5953bec658e6889054c6
hannels/OldFileChannelTest.java
|
3be1277a4644a149c158f99febbab890fc7b708f |
09-Jun-2011 |
claireho <chinglanho@gmail.com> |
Libcore changes corresponding to ICU4.6 upgrade. 1. libcore_icu_ICU.cpp: ICU resource files format change. 2. OldCharset_SingleByte_ISO_8859_11.java : charset alias name change. 3. CollatorTest.java : Collation key value change. 4. Pattern2Test.java : character property change - pick another char with Me property. Change-Id: Iff80c6098f5fd7c82b07e41b4532548d98448ad7
harset/OldCharset_SingleByte_ISO_8859_11.java
|
dbde5bd893290c02bb289460fc61e48eda63daa2 |
20-May-2011 |
Elliott Hughes <enh@google.com> |
FileChannelImpl doesn't need to special-case O_APPEND. ...we have an OS kernel for such things. Bug: 4455730 Change-Id: I23efc0ceaa534bffdc0da9a5ff1426ff9d56547f
hannels/FileChannelTest.java
hannels/OldFileChannelTest.java
|
d3992b82602c2eef8e83ae7150f987cc9e0864fd |
11-May-2011 |
Elliott Hughes <enh@google.com> |
Move the selector tests into one file. Change-Id: I95691beaf3cee3ef89f16001c1a0176da3817c54
electorTest.java
hannels/SelectorTest.java
|
a7bb29434692e01aed843b88cd042628bab74a23 |
11-May-2011 |
Elliott Hughes <enh@google.com> |
Clean up the select(2) implementation. I wasn't planning on touching this code (since I want to replace it), but the purported "fix" for http://code.google.com/p/android/issues/detail?id=6309 was actually a regression. The supplied test fails on the RI. This patch replaces the bogus test with new tests, and reverts the old "fix". This was found while trying to work out what "true" and "false" return values from OSNetworkSystem.select are supposed to mean. This patch also switches to a more traditional int return value. Bug: 3107501 Change-Id: Iddce55e081d440b7eb3ddcf94db7d0739dc89c70
electorTest.java
|
897b649912d132bef7e07c9f6612d0a3f880cec0 |
11-May-2011 |
Elliott Hughes <enh@google.com> |
Clean up a test. The contents of this test should be moved to *channels*/SelectorTest.java, but I wanted to make the deliberate fix of the bug URL clear. I've also cleaned up the test to avoid the use of the horrible Support_PortManager hack. (18 files left to remove it from.) Change-Id: Ic71669fb56217111a7fd33cbd54348b7a0f2e0db
electorTest.java
|
42d75577588240e7d79fe52e635f0c1df070672e |
06-May-2011 |
Elliott Hughes <enh@google.com> |
Add a test for a publicly-reported bug I already fixed. Another casualty of the honeycomb asXBuffer byte order bug. Bug: http://code.google.com/p/android/issues/detail?id=16598 Change-Id: I885d9f1651238a5d2aadf3fef7d119775f742fdf
ufferTest.java
|
a3b57e9cb41fb00ac607cd330fa73270b564b66c |
06-May-2011 |
Elliott Hughes <enh@google.com> |
Fix non-blocking DatagramChannel.receive and ServerSocketChannel.accept. The former problem was the reported bug, but the latter was another instance of the same mistake, and much harder to fix. The interesting change here is that we now create the SocketImpl (and thus the underlying OS socket) for a ServerSocket much sooner than we used to: if the constructor doesn't throw, you've got yourself a usable socket. Bug: http://code.google.com/p/android/issues/detail?id=16579 Change-Id: Iac8b707e74cd1367ee0fdc22fc3969677cfa566c
hannels/DatagramChannelTest.java
hannels/ServerSocketChannelTest.java
|
87c354d8d6faa77dee1820df2f0ad2666b9f0331 |
29-Apr-2011 |
Elliott Hughes <enh@google.com> |
Fix the byte order of non-ByteBuffer duplicate and slice results. ByteBuffer.duplicate and ByteBuffer.slice always return big-endian buffers. Any other kind of buffer returns a buffer with the same endian as itself. We didn't have tests for the latter, and broke this in Honeycomb. Bug: http://code.google.com/p/android/issues/detail?id=16434 Change-Id: I08e98c4817f6340a0c396de060431185240d3ca3
ufferTest.java
|
0568a63ba1086a78ffb4cff68dd2eac4f9908e13 |
26-Apr-2011 |
Elliott Hughes <enh@google.com> |
Fix ByteBuffer.put(ByteBuffer). To do this tastefully required some cunning in the native code. The new ScopedBytesRO/ScopedBytesRW classes let us paper over the differences between byte[] and DirectByteBuffer, which in turn lets us paper over the differences between the various kinds of ByteBuffer. I've also rewritten Posix.read/Posix.readDirectBuffer and Posix.write/Posix.writeDirectBuffer to use the same idea. I haven't rewritten readv and writev, but can do and probably should. Bug: http://code.google.com/p/android/issues/detail?id=16184 Change-Id: Ia30d2f2fe1b1716a8f068187df2218b407a55aae
ufferTest.java
|
54298028777ffe4d5ec02e7908b333400d4f23a6 |
07-Apr-2011 |
Elliott Hughes <enh@google.com> |
Fix asReadOnlyBuffer to conserve the byte order (on everything except ByteBuffer). And add tests to exercise another wart of non-uniformity on this heinous API. Bug: http://code.google.com/p/android/issues/detail?id=15994 Change-Id: I49d2488a68a626e798f9bb39b47e710445b23fab
ufferTest.java
|
bbac92e691de7d570928ddfba639067978e55b06 |
29-Mar-2011 |
Elliott Hughes <enh@google.com> |
Add readv(2)/writev(2). The old implementation would cheat if it was given non-direct buffers, copying them into newly-allocated direct buffers. (The network Channel implementations are worse: they copy all the data into a single buffer, and then read/write that. I'll get to them eventually.) Bug: 3107501 Change-Id: I1655bacb042e7ebcde7e5bc5cf2c71e7ce5e30af
hannels/FileChannelTest.java
|
4af0d8c99d68bcacff182699527d983a1d34fdbe |
28-Mar-2011 |
Elliott Hughes <enh@google.com> |
Support read-only ByteBuffers. Buffer.array() and Buffer.arrayOffset() throw for read-only buffers. We need to work round this. We know that this is safe because we trust ourselves not to write to read-only buffers and because all non-direct buffers have a backing array. Bug: 3107501 Change-Id: I501a5f7ddba2c66d22864bf4a41b927263493293
hannels/FileChannelTest.java
|
10959ae7eb41e8ceecb16378c25395eb2f29106c |
18-Mar-2011 |
Jesse Wilson <jessewilson@google.com> |
Don't block a selector if the current thread has been interrupted. This changes setInterruptAction to be push/pop rather than set/unset. During testing I found that different classes were conflicting with the interrupt action: Channels and Selectors were setting it simultaneously. Change-Id: Ie1f96c2a1db9412863f4a181cfa29a239ffa5996 http://code.google.com/p/android/issues/detail?id=15388
electorTest.java
|
c6210a287dad8ae2447387ec840696b0e366046f |
04-Feb-2011 |
Elliott Hughes <enh@google.com> |
Fix a couple of tests. Now direct buffers are backed by byte[]s on the Java heap, allocating a direct buffer is no longer an easy way to get a Buffer that will return false for hasArray. There's a work-around for one test, but I think the other's impossible even if you're prepared to try custom a subclass. Change-Id: I74ce36e46d3170c3147c4576e0eaa43e15826825
harset/OldCharsetEncoderDecoderBufferTest.java
|
52b939cbcc060c6bf71b65f2588e9837a86f7c5f |
04-Feb-2011 |
Elliott Hughes <enh@google.com> |
Remove @Test cruft from all tests under luni/src/test/java/libcore. Change-Id: I1c5a4f3109147830009d5fc1780e43ed875313ca
hannels/OldFileChannelTest.java
hannels/OldServerSocketChannelTest.java
hannels/OldSocketChannelTest.java
|
2981b5e8cf7c19dfd85b2088b18b7a6146825317 |
03-Feb-2011 |
Elliott Hughes <enh@google.com> |
Improve CharsetDecoder's quality of implementation, like CharsetEncoder. As I suspected, CharsetDecoder doesn't cope with a character's bytes being split across multiple writes any more than CharsetEncoder could cope with halves of a surrogate pair being split across multiple writes. This seems much more likely to have harmed applications than CharsetEncoder (since surrogates are rare). Anyway, ICU does the right thing here too, so the fix is basically the same. I've also gone through the decoder/encoder code a bit to bring them more in line with each other. Bug: 3410124 Change-Id: I151d043e474161e324361cddfc73188ba73fd59c
harset/CharsetDecoderTest.java
harset/OldCharsetDecoderTest.java
|
dbf863488607fbb16a3d28c09f772d9581bd64ad |
02-Feb-2011 |
Elliott Hughes <enh@google.com> |
Bring CharsetDecoderICU more in line with CharsetEncoderICU. There's no need for separate 'flush' native code here either. I've also explicitly set inEnd to 0 in CharsetEncoderICU which was an oversight before; I've added a failing test. (Existing tests for CharsetDecoder failed without the corresponding line.) I've also made a comment in InputStreamReader match the equivalent comment in OutputStreamWriter. I'll make more invasive changes (looking at the INPUT_HELD stuff) when I've written some tests for CharsetDecoder. Change-Id: I39a3b2c017da1f991bdff33ebc8c226fc56841ba
harset/CharsetEncoderTest.java
|
33604713c5c70f9e6cad61dee6eb628db666bb22 |
01-Feb-2011 |
Elliott Hughes <enh@google.com> |
Improve CharsetEncoder to handle surrogates gracefully. Behave like ICU rather than the RI, and transparently handle surrogate pairs split across buffers. This fixes callers who were unaware of the bad design, and shouldn't harm those callers who try to work around it (since they'll never find themselves in the bad state). Bug: 3408061 Change-Id: I6b5675196a14b15efdaa7084a82a483d8d2c47ad
harset/CharsetEncoderTest.java
|
555453327f26f4c9c610caa2851c87c3794c7764 |
31-Jan-2011 |
Elliott Hughes <enh@google.com> |
Tidying of OutputStreamWriter and a couple of related tests. Change-Id: I591f573cd1e57f7bce8f47db29c8838896fa8b0b
harset/CharsetEncoderTest.java
|
3bdd9bb460941429ab11dfa13596768f3dc246ad |
31-Jan-2011 |
Elliott Hughes <enh@google.com> |
Fix OutputStreamWriter's handling of surrogates. CharsetEncoder doesn't behave how you'd expect. It doesn't track surrogate pairs across calls to encode. This is true of the RI, too, not just our ICU-based implementation. (I've included new CharsetEncoder tests to demonstrate this. They don't all pass on Android, because we don't behave exactly the same, but we're the same as far as is relevant for this OutputStreamWriter bug.) I've added new OutputStreamWriter tests too, that test the actual behavior beyond the trivial "do we throw IllegalStateException?" tests harmony had. Their fix for this bug didn't fix the real problem, but this patch fixes both of the failures I found. I think there's probably another one (marked with a TODO), but I haven't been able to write a test to provoke it yet, and I'm unwilling to add code I can't test. I've also changed the behavior of OutputStreamWriter.write so that we don't flush the underlying stream. This was a bug: only OutputStreamWriter.flush should flush the underlying stream (as opposed to "flush" in the sense of writing bytes from OutputStreamWriter's buffer into the underlying stream). I've confirmed the truth of this assertion with another test. Bug: 3403615 Change-Id: I567d49403b5498f4fb0a70fa3bfde0bd02ef430e
harset/CharsetEncoderTest.java
|
bc01e68730f04cb8dbbf7f3b7da82006c2151ebf |
29-Jan-2011 |
Elliott Hughes <enh@google.com> |
Fix NoArrayTest, and fix ReadOnlyDirectByteBuffer too. This test was bogus, but fixing the test pointed out an actual bug in my recent DirectByteBuffer change --- our DirectByteBuffers might be backed by arrays, but that doesn't mean that a ReadOnlyDirectByteBuffer should expose it (because it could then be modified). Bug: 3403619 Change-Id: Ide91d42e072b5befc819e78a29dbccd0f2db9a61
oArrayTest.java
|
38f919c84cc2714ae2564ea1a04e2ced9c5aad04 |
26-Jan-2011 |
Elliott Hughes <enh@google.com> |
Our DirectByteBuffer can implement array(), arrayOffset(), and hasArray(). An interesting side-effect of moving direct buffers onto the Java heap. Sufficiently sophisticated code can now have the best of both worlds. Bug: 3384431 Change-Id: I741fc457277704016bc773cc2aec22e89045f839
ufferTest.java
|
617329e227c071828c4b2616f548d0e0f29cd75a |
17-Dec-2010 |
Jesse Wilson <jessewilson@google.com> |
Don't be specific about exception priority in OldFileChannelTest. Change-Id: I147b60df59446fe1edbdc24249f66a2a15e9814e
hannels/OldFileChannelTest.java
|
5a1e8cc38e1cc6c3f2fc66f039ca0fc5309a0dc3 |
16-Dec-2010 |
Elliott Hughes <enh@google.com> |
MappedByteBuffer get(byte[]) and get(byte[], int, int) weren't updating 'position'. The majority of this change is work to extend our tests to cover MappedByteBuffer too, plus new tests to check that 'position' is always updated correctly by ByteBuffer's relative get/put methods. Bug: 3291927 Change-Id: I58217de45ba65675730f30771fba592cb2af28ff
ufferTest.java
|
990640f1775dc6f429a5f8b9fc6cab6b4220c03a |
15-Dec-2010 |
Jesse Wilson <jessewilson@google.com> |
Move 41 tests to libcore, closer to the tested code. Change-Id: I0ecaacd0e68b8319806555f71ddf347f01b17be9 http://b/3073226
ldAndroidNIOTest.java
|
3d09992b375338188c75268dddbe07635a505bbe |
07-Dec-2010 |
Jesse Wilson <jessewilson@google.com> |
Relax assumptions made in OldFileChannelTest about the maximum supported offsets. This test was failing on the host where larger offsets can be locked. Change-Id: I1c1946fab32a88f4ca13234eb2c74b22a3e45b1e
hannels/OldFileChannelTest.java
|
252a236cdd624c1e2e98d81ed9be09ef5861e149 |
22-Oct-2010 |
Elliott Hughes <enh@google.com> |
There's nothing old about OldCharsetTest. I wrote this test, fairly recently. It was accidentally bundled in with other deprecated tests. Change-Id: I987267deaac312578475c9ab12d427f0f09a69fe
harset/CharsetTest.java
harset/OldCharsetTest.java
|
17b2f493468764dc1f237c02d94747d122dbd101 |
08-Oct-2010 |
Elliott Hughes <enh@google.com> |
Fix our byte order behavior for slice and wrap operations. Our documentation was correct, but our implementation was not. Includes extensive new tests. Bug: 3066167 Change-Id: Ie7d6e6432f1d675f20af020cc662dab6eb181a50
ufferTest.java
|
bd3fa20df1d41ddb1310bb03d82b2f5aa11e0dfb |
25-Sep-2010 |
Jesse Wilson <jessewilson@google.com> |
Don't expect bug-compatibility with the RI's missing IllegalBlockingModeException. The RI promises to throw when a non-blocking channel is read via a stream. It doesn't throw, and our tests were validating that. This also cleans up ScannerTest, which was duplicated with Harmony. Change-Id: Ife522d29c0b0734e188462b4d23f0a872727ce38
hannels/ChannelsTest.java
|
8f498ad08cf4b4a828a8aa030e738ef6a82bdb7c |
24-Sep-2010 |
Jesse Wilson <jessewilson@google.com> |
Make failures in replacement characters more granual. We're failing for UTF-16, but that shouldn't cause other charset's tests to not run. Change-Id: Ib7bfc088c45527b9649d0e114fb3e67911b34067
harset/CharsetEncoderTest.java
harset/OldCharsetEncoderTest.java
|
8fbc397fc09158bee0bc0cb231c609c4c6e9fc15 |
18-Sep-2010 |
Elliott Hughes <enh@google.com> |
Optimize non-direct (heap) buffer bulk put. I've also factored out the bounds checking, even though the JIT can't yet inline it back. I'm unwilling to duplicate all that code again. This patch also fixes bugs in the previous checkin relating to offsets and positions. In real life (and, seemingly, in all our tests) these tend to be 0, making it rare that anyone trips over these bugs. (The first nio change I made was fixing just such a bug.) I've improved the test I added last time so that it covers more of these cases. Here are the "after" performance figures for heap buffer bulk copies: CharBuffer_getCharArray 5797 CharBuffer_putCharArray 5818 DoubleBuffer_getDoubleArray 13053 DoubleBuffer_putDoubleArray 13026 FloatBuffer_getFloatArray 8216 FloatBuffer_putFloatArray 8283 IntBuffer_getIntArray 8253 IntBuffer_putIntArray 8371 LongBuffer_getLongArray 13053 LongBuffer_putLongArray 13020 ShortBuffer_getShortArray 5796 ShortBuffer_putShortArray 5864 This compares well with with direct buffer performance (just gets shown here): CharBuffer_getCharArray 4412 DoubleBuffer_getDoubleArray 11594 FloatBuffer_getFloatArray 6787 IntBuffer_getIntArray 6791 LongBuffer_getLongArray 11672 ShortBuffer_getShortArray 4430 Bug: 2985452 Change-Id: I37307f9b304c87a87af5313790444dcdf6174ff1
ufferTest.java
|
6944bea4a129dc2d4be687c72f2a9f228ec532bc |
17-Sep-2010 |
Elliott Hughes <enh@google.com> |
Make nio heap (non-direct) buffer bulk get orders of magnitude faster. Bug: 2985452 Change-Id: I8bd210d1a623e434121f30eca6e2555e1aea11cd
ufferTest.java
|
54f969b83377b1540efc0180962966df0732a479 |
15-Sep-2010 |
Jesse Wilson <jessewilson@google.com> |
Moving Android-authored charset tests into the libcore tree. Change-Id: I8b3477249ffcd8c6baf34887c502e609d0c0b238
harset/CharsetDecoderTest.java
harset/CharsetEncoderTest.java
harset/CharsetTest.java
harset/Charset_TestGenerator.java
harset/OldCharsetDecoderTest.java
harset/OldCharsetEncoderDecoderBufferTest.java
harset/OldCharsetEncoderTest.java
harset/OldCharsetTest.java
harset/OldCharset_AbstractTest.java
harset/OldCharset_GSM0338.java
harset/OldCharset_ISO_8859_10.java
harset/OldCharset_ISO_8859_14.java
harset/OldCharset_ISO_8859_16.java
harset/OldCharset_MultiByte_Big5.java
harset/OldCharset_MultiByte_Big5_Android.java
harset/OldCharset_MultiByte_EUC_JP.java
harset/OldCharset_MultiByte_EUC_JP_Android.java
harset/OldCharset_MultiByte_EUC_KR.java
harset/OldCharset_MultiByte_GB2312.java
harset/OldCharset_MultiByte_GBK.java
harset/OldCharset_MultiByte_GBK_Android.java
harset/OldCharset_MultiByte_ISO_2022_JP.java
harset/OldCharset_MultiByte_UTF_16.java
harset/OldCharset_MultiByte_UTF_16BE.java
harset/OldCharset_MultiByte_UTF_16LE.java
harset/OldCharset_MultiByte_UTF_16_Android.java
harset/OldCharset_MultiByte_UTF_8.java
harset/OldCharset_MultiByte_x_windows_950.java
harset/OldCharset_SingleByteAbstractTest.java
harset/OldCharset_SingleByte_IBM864.java
harset/OldCharset_SingleByte_ISO_8859_1.java
harset/OldCharset_SingleByte_ISO_8859_11.java
harset/OldCharset_SingleByte_ISO_8859_13.java
harset/OldCharset_SingleByte_ISO_8859_15.java
harset/OldCharset_SingleByte_ISO_8859_2.java
harset/OldCharset_SingleByte_ISO_8859_3.java
harset/OldCharset_SingleByte_ISO_8859_4.java
harset/OldCharset_SingleByte_ISO_8859_5.java
harset/OldCharset_SingleByte_ISO_8859_6.java
harset/OldCharset_SingleByte_ISO_8859_7.java
harset/OldCharset_SingleByte_ISO_8859_8.java
harset/OldCharset_SingleByte_ISO_8859_9.java
harset/OldCharset_SingleByte_KOI8_R.java
harset/OldCharset_SingleByte_US_ASCII.java
harset/OldCharset_SingleByte_windows_1250.java
harset/OldCharset_SingleByte_windows_1251.java
harset/OldCharset_SingleByte_windows_1252.java
harset/OldCharset_SingleByte_windows_1253.java
harset/OldCharset_SingleByte_windows_1254.java
harset/OldCharset_SingleByte_windows_1255.java
harset/OldCharset_SingleByte_windows_1256.java
harset/OldCharset_SingleByte_windows_1257.java
harset/OldCharset_SingleByte_windows_1258.java
harset/OldCharset_SingleByte_x_IBM874.java
harset/OldCharset_macintosh.java
|
81550e2d43bbf16be983722877519362799e7d90 |
14-Sep-2010 |
Jesse Wilson <jessewilson@google.com> |
Remove NIO tests duplicated from Harmony. The only major differences were some tests marked disabled_testReadByteBuffer_Block_close() which weren't running anyway. I could try to enable these tests, but I think effort would be better spent writing new tests where they're needed. Change-Id: I58748fd553bc1c9531ec91fddc432b192fbdef47
oArrayTest.java
ldDirectIntBufferTest.java
ldDirectShortBufferTest.java
|
60a0a96f334f159418763cab17c48a09c97cbd2f |
13-Aug-2010 |
Elliott Hughes <enh@google.com> |
Fix reading from an empty non-blocking pipe. The active ingredient here is getting rid of the lines that threw InterruptedIOException in "OSFileSystem.cpp". I don't think that code was ever right, but until I rewrote Pipe it wasn't possible to exercise that code. The other changes are cosmetic, made while understanding this code well enough to find the bug, plus a new test for this behavior. Bug: 2901552 Change-Id: Id9cd3cdd6a97b225bbf7c352a6e0c535e9f9da1d
hannels/PipeTest.java
|
4557728efb66c455a52b7669a8eefef7a9e54854 |
11-Aug-2010 |
Jesse Wilson <jessewilson@google.com> |
Moving tests to be under the libcore.* package. This is indended to make it easier to run on VMs that restrict the packages from which application classes can be loaded. For example, on the RI you need to use the bootclasspath to load these tests. Change-Id: I52193f35c5fcca18b5a3e1d280505b1e29b388af
electorTest.java
hannels/DatagramChannelTest.java
hannels/FileChannelTest.java
hannels/OldFileChannelTest.java
hannels/OldServerSocketChannelTest.java
hannels/OldSocketChannelTest.java
hannels/SelectorTest.java
hannels/SocketChannelTest.java
harset/CharsetDecoderTest.java
harset/CharsetEncoderTest.java
harset/CharsetTest.java
|