AvdLee / appstoreconnect-swift-sdk

The Swift SDK to work with the App Store Connect API from Apple.
Other
1.48k stars 198 forks source link

Implement list users limit #82

Closed adamjcampbell closed 4 years ago

adamjcampbell commented 4 years ago

Awesome work on the SDK 😄 Found a missing feature so I thought I'd implement it

Changes

This PR adds the ability to limit the number of resources (users) returned from the list users endpoint

Notes

I wasn't sure how to test the project how it is currently set up but was to enable the use of swift test by adding the following test target

        .testTarget(
            name: "AppStoreConnect-Swift-SDK-Tests",
            dependencies: ["AppStoreConnect-Swift-SDK"],
            path: "Tests",
            exclude: ["LinuxMain.swift"]
        )
SwiftLeeBot commented 4 years ago
Messages
:book: View more details on Bitrise
:book: AppStoreConnect-Swift-SDK: Executed 149 tests, with 0 failures (0 unexpected) in 0.631 (1.437) seconds

AppStoreConnect_Swift_SDK.framework: Coverage: 81.64

File Coverage
ListUsers.swift 100.0% ✅

Generated by :no_entry_sign: Danger Swift against 1a2807da1c1d4863da3adce0f4593ad128233e8a

adamjcampbell commented 4 years ago

@AvdLee would having that test target added to Package.swift in another PR be helpful?

Or is there another way to run the tests from the command line or Xcode?

AvdLee commented 4 years ago

~@adamjcampbell we have a test target in the Package.swift but it's commented out. If we wouldn't do that, every package fetch would also fetch our test target and its dependencies.~

I now realize we don't have that test target, so yes, please do add it if you will! However, add it with the // dev if possible due to the above reasons.

This is fixed in Swift 5.2 but not yet implemented. Therefore, we still have the // dev in front of each. https://github.com/AvdLee/appstoreconnect-swift-sdk/blob/master/Package.swift#L21

SwiftLeeBot commented 4 years ago

Congratulations! :tada: This was released as part of Release 1.0.2 :rocket: