diff options
author | Narayan Kamath <narayan@google.com> | 2013-11-13 13:05:58 +0000 |
---|---|---|
committer | Narayan Kamath <narayan@google.com> | 2013-11-14 18:36:15 +0000 |
commit | 1399e0b42af7a565f34b9a2441f0a079e6ab3854 (patch) | |
tree | dcf9b8632f66ba364f58d12a7f69be0a6f22ffe5 /harmony-tests/src/test/resources | |
parent | cb318c6f4fe5b0e20099fa85f1b95ccb2d24119f (diff) | |
download | libcore-1399e0b42af7a565f34b9a2441f0a079e6ab3854.zip libcore-1399e0b42af7a565f34b9a2441f0a079e6ab3854.tar.gz libcore-1399e0b42af7a565f34b9a2441f0a079e6ab3854.tar.bz2 |
Fix a few failures in FileURLConnectionTest.
Some tests still fail, but they appear to be valid
tests. There are at least two separate issues here :
- ClassLoader#getResource seems to be constructing a
bogus URL (at least in this context). findResource
returns a non null URL, but URL#openStream throws.
- URLs with fragments (#foo) don't appear to work
correctly.
Change-Id: Iabf03e49c56659039feb85a0e528efcaaed0b49d
Diffstat (limited to 'harmony-tests/src/test/resources')
-rw-r--r-- | harmony-tests/src/test/resources/resources/test.doc | 20 | ||||
-rw-r--r-- | harmony-tests/src/test/resources/resources/test.htx | 22 | ||||
-rw-r--r-- | harmony-tests/src/test/resources/resources/test.java | 20 | ||||
-rw-r--r-- | harmony-tests/src/test/resources/resources/test.rtf | 20 | ||||
-rw-r--r-- | harmony-tests/src/test/resources/resources/test.xml | 22 |
5 files changed, 104 insertions, 0 deletions
diff --git a/harmony-tests/src/test/resources/resources/test.doc b/harmony-tests/src/test/resources/resources/test.doc new file mode 100644 index 0000000..9d88f15 --- /dev/null +++ b/harmony-tests/src/test/resources/resources/test.doc @@ -0,0 +1,20 @@ +/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/* A bogus doc file used to see if we can detect
+ * file type based on its file extension.
+ */
\ No newline at end of file diff --git a/harmony-tests/src/test/resources/resources/test.htx b/harmony-tests/src/test/resources/resources/test.htx new file mode 100644 index 0000000..2aa810e --- /dev/null +++ b/harmony-tests/src/test/resources/resources/test.htx @@ -0,0 +1,22 @@ +<html>
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/* A bogus html file used to see if we can detect
+ * file type based on its file extension / content.
+ */
\ No newline at end of file diff --git a/harmony-tests/src/test/resources/resources/test.java b/harmony-tests/src/test/resources/resources/test.java new file mode 100644 index 0000000..3ea4660 --- /dev/null +++ b/harmony-tests/src/test/resources/resources/test.java @@ -0,0 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* A bogus java file used to see if we can detect + * file type based on its file extension. + */
\ No newline at end of file diff --git a/harmony-tests/src/test/resources/resources/test.rtf b/harmony-tests/src/test/resources/resources/test.rtf new file mode 100644 index 0000000..aa1d82d --- /dev/null +++ b/harmony-tests/src/test/resources/resources/test.rtf @@ -0,0 +1,20 @@ +/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/* A bogus RTF file used to see if we can detect
+ * file type based on its file extension.
+ */
\ No newline at end of file diff --git a/harmony-tests/src/test/resources/resources/test.xml b/harmony-tests/src/test/resources/resources/test.xml new file mode 100644 index 0000000..cb5c342 --- /dev/null +++ b/harmony-tests/src/test/resources/resources/test.xml @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<!-- A bogus XML file used to see if we can detect + file type based on its file extension / content. +-->
\ No newline at end of file |