         _testRoundTrip(of: TopLevelWrapper(decimal), expectedYAML: expectedYAML)
 
         // Optional Decimals should encode the same way.
-        // FIXME: following test is blocked by https://bugs.swift.org/browse/SR-5206
-//            _testRoundTrip(of: OptionalTopLevelWrapper(decimal), expectedYAML: expectedYAML)
+    #if swift(>=4.0.3)
+        // following test requires that https://bugs.swift.org/browse/SR-5206 is fixed.
+        _testRoundTrip(of: OptionalTopLevelWrapper(decimal), expectedYAML: expectedYAML)
+    #endif
     }
 
     func testInterceptURL() {

        _testRoundTrip(of: TopLevelWrapper(url), expectedYAML: expectedYAML)

        // Optional URLs should encode the same way.
        // FIXME: following test is blocked by https://bugs.swift.org/browse/SR-5206
//            _testRoundTrip(of: OptionalTopLevelWrapper(url), expectedYAML: expectedYAML)
    }

    func testValuesInSingleValueContainer() throws {

    func testEncodingTopLevelStructuredSingleClass() {
        // Mapping is a class which encodes as a dictionary through a single value container.
        let mapping = Mapping.testValue
    #if swift(>=4.0.3)
        // fixing https://bugs.swift.org/browse/SR-5206 changes result.
        _testRoundTrip(of: mapping, with: YAMLEncoder.Options(sortKeys: true), expectedYAML: """
            Apple: http://apple.com
            localhost: http://127.0.0.1

            """)
    #else
        _testRoundTrip(of: mapping, with: YAMLEncoder.Options(sortKeys: true), expectedYAML: """
            Apple:
              relative: http://apple.com
