From 3964202ea267c4b84bb5aacf87b57f96f954ad69 Mon Sep 17 00:00:00 2001 From: Mathew Polzin Date: Tue, 27 Nov 2018 11:53:21 -0800 Subject: [PATCH] Mention JSONAPITestLib in the README --- README.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0d5d90e..5b085db 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,14 @@ The primary goals of this framework are: 3. Do not sacrifice type safety. 4. Be platform agnostic so that Swift code can be written once and used by both the client and the server. +## Dev Environment +### Prerequisites +1. Swift 4.2+ and Swift Package Manager + +### Xcode project +To create an Xcode project for JSONAPI, run +`swift package generate-xcodeproj` + ## Project Status ### Decoding @@ -89,8 +97,6 @@ The primary goals of this framework are: - [ ] Make it easier to construct `Attributes` and `Relationships` values. ## Usage -### Prerequisites -1. Swift 4.2+ and Swift Package Manager ### `EntityDescription` @@ -322,3 +328,6 @@ extension String: CreatableRawIdType { } } ``` + +## Testing +JSONAPI comes with a test library to help you test your JSON API integration. The test library is called `JSONAPITestLib`. It provides literal expressibility for `Attribute`, `ToOneRelationship`, and `Id` in many situations so that you can easily write test `Entity` values into your unit tests. You can see the JSONAPITestLib in action in the Playground included with the JSONAPI repository.