From 2988503d7d58f9aba373339918c602980f6eb6e0 Mon Sep 17 00:00:00 2001 From: Mathew Polzin Date: Fri, 25 Jan 2019 11:59:05 -0800 Subject: [PATCH] Add Sampleable conformance to Unidentified. Rename file slightly. --- ...{Sampleable+JSONAPI.swift => JSONAPI+Sampleable.swift} | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) rename Sources/JSONAPIOpenAPI/Sampleable/{Sampleable+JSONAPI.swift => JSONAPI+Sampleable.swift} (89%) diff --git a/Sources/JSONAPIOpenAPI/Sampleable/Sampleable+JSONAPI.swift b/Sources/JSONAPIOpenAPI/Sampleable/JSONAPI+Sampleable.swift similarity index 89% rename from Sources/JSONAPIOpenAPI/Sampleable/Sampleable+JSONAPI.swift rename to Sources/JSONAPIOpenAPI/Sampleable/JSONAPI+Sampleable.swift index 6dd53f2..bcb832b 100644 --- a/Sources/JSONAPIOpenAPI/Sampleable/Sampleable+JSONAPI.swift +++ b/Sources/JSONAPIOpenAPI/Sampleable/JSONAPI+Sampleable.swift @@ -1,5 +1,5 @@ // -// Sampleable+JSONAPI.swift +// JSONAPI+Sampleable.swift // JSONAPIOpenAPI // // Created by Mathew Polzin on 1/24/19. @@ -43,6 +43,12 @@ extension UnknownJSONAPIError: Sampleable { } } +extension Unidentified: Sampleable { + public static var sample: Unidentified { + return Unidentified() + } +} + extension Attribute: Sampleable where RawValue: Sampleable { public static var sample: Attribute { return .init(value: RawValue.sample)