Skip to content

TestXMLDocument: un-XFAIL test_documentWithDTD on Linux #1482

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 22, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 24 additions & 52 deletions TestFoundation/TestXMLDocument.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
//



#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
Expand All @@ -21,57 +20,30 @@
class TestXMLDocument : XCTestCase {

static var allTests: [(String, (TestXMLDocument) -> () throws -> Void)] {
#if os(OSX) || os(iOS)
return [
("test_basicCreation", test_basicCreation),
("test_nextPreviousNode", test_nextPreviousNode),
("test_xpath", test_xpath),
("test_elementCreation", test_elementCreation),
("test_elementChildren", test_elementChildren),
("test_stringValue", test_stringValue),
("test_objectValue", test_objectValue),
("test_attributes", test_attributes),
("test_comments", test_comments),
("test_processingInstruction", test_processingInstruction),
("test_parseXMLString", test_parseXMLString),
("test_prefixes", test_prefixes),
// ("test_validation_success", test_validation_success),
// ("test_validation_failure", test_validation_failure),
("test_dtd", test_dtd),
("test_documentWithDTD", test_documentWithDTD),
("test_dtd_attributes", test_dtd_attributes),
("test_documentWithEncodingSetDoesntCrash", test_documentWithEncodingSetDoesntCrash),
("test_nodeFindingWithNamespaces", test_nodeFindingWithNamespaces),
("test_createElement", test_createElement),
("test_addNamespace", test_addNamespace),
("test_removeNamespace", test_removeNamespace),
]
#else // On Linux, currently the tests that rely on NSError are segfaulting in swift_dynamicCast
return [
("test_basicCreation", test_basicCreation),
("test_nextPreviousNode", test_nextPreviousNode),
("test_xpath", test_xpath),
("test_elementCreation", test_elementCreation),
("test_elementChildren", test_elementChildren),
("test_stringValue", test_stringValue),
("test_objectValue", test_objectValue),
("test_attributes", test_attributes),
("test_comments", test_comments),
("test_processingInstruction", test_processingInstruction),
("test_parseXMLString", test_parseXMLString),
("test_prefixes", test_prefixes),
// ("test_validation_success", test_validation_success),
// ("test_validation_failure", test_validation_failure),
("test_dtd", test_dtd),
// ("test_documentWithDTD", test_documentWithDTD),
("test_dtd_attributes", test_dtd_attributes),
("test_documentWithEncodingSetDoesntCrash", test_documentWithEncodingSetDoesntCrash),
("test_nodeFindingWithNamespaces", test_nodeFindingWithNamespaces),
("test_createElement", test_createElement),
("test_addNamespace", test_addNamespace),
("test_removeNamespace", test_removeNamespace),
]
#endif
return [
("test_basicCreation", test_basicCreation),
("test_nextPreviousNode", test_nextPreviousNode),
("test_xpath", test_xpath),
("test_elementCreation", test_elementCreation),
("test_elementChildren", test_elementChildren),
("test_stringValue", test_stringValue),
("test_objectValue", test_objectValue),
("test_attributes", test_attributes),
("test_comments", test_comments),
("test_processingInstruction", test_processingInstruction),
("test_parseXMLString", test_parseXMLString),
("test_prefixes", test_prefixes),
// XFAIL: <rdar://31567922> ("test_validation_success", test_validation_success),
// XFAIL: <rdar://31567922> ("test_validation_failure", test_validation_failure),
("test_dtd", test_dtd),
("test_documentWithDTD", test_documentWithDTD),
("test_dtd_attributes", test_dtd_attributes),
("test_documentWithEncodingSetDoesntCrash", test_documentWithEncodingSetDoesntCrash),
("test_nodeFindingWithNamespaces", test_nodeFindingWithNamespaces),
("test_createElement", test_createElement),
("test_addNamespace", test_addNamespace),
("test_removeNamespace", test_removeNamespace),
]
}

func test_basicCreation() {
Expand Down