8000 Only 21 of 75 Tests succeed when running them on main. · Issue #28 · SwiftyLab/MetaCodable · GitHub
[go: up one dir, main page]

Skip to content
Only 21 of 75 Tests succeed when running them on main. #28
@Midbin

Description

@Midbin

When trying to work on some of the issues I filed earlier today, I discovered that when running the tests on main (simply opening the Package.swift in XCode an pressing Command + U) about 75% of the Tests fail.

The failures seem to indicate that @Codable is not expanded:

An example failure:

CodableTests.swift:75: failed - Actual output (+) differed from expected output (-):
 struct SomeCodable: Encodable {
     let value: String
 
     func encode(to encoder: Encoder) throws {
     }
 }
–
–extension SomeCodable: Decodable {
–    init(from decoder: Decoder) throws {
–        let container = try decoder.container(keyedBy: CodingKeys.self)
–        self.value = try container.decode(String.self, forKey: CodingKeys.value)
–    }
–}
–
–extension SomeCodable {
–    enum CodingKeys: String, CodingKey {
–        case value = "value"
–    }
–}

Actual expanded source:

struct SomeCodable: Encodable {
    let value: String

    func encode(to encoder: Encoder) throws {
    }
}

Is this an error on my end?

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is neededquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0