Skip to content

Commit

Permalink
chore: Update codegen.json (#29)
Browse files Browse the repository at this point in the history
  • Loading branch information
box-sdk-build authored Mar 1, 2024
1 parent b20d63b commit 2efe130
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .codegen.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "engineHash": "ee76251", "specHash": "b2f7568", "version": "0.1.0" }
{ "engineHash": "905c6a0", "specHash": "b2f7568", "version": "0.1.0" }
7 changes: 3 additions & 4 deletions Tests/Auth/AuthManagerTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,12 @@ class AuthManagerTests: XCTestCase {
public func testOauthAuthRevoke() async throws {
let config: OAuthConfig = OAuthConfig(clientId: Utils.getEnvironmentVariable(name: "CLIENT_ID"), clientSecret: Utils.getEnvironmentVariable(name: "CLIENT_SECRET"))
let auth: BoxOAuth = BoxOAuth(config: config)
let client: BoxClient = BoxClient(auth: auth)
let token: AccessToken = try await getAccessToken()
try await auth.tokenStorage.store(token: token)
let tokenBeforeRevoke: AccessToken? = try await auth.tokenStorage.get()
try await client.users.getUserMe()
try await auth.revokeToken()
let tokenAfterRevoke: AccessToken? = try await auth.tokenStorage.get()
XCTAssertTrue(tokenBeforeRevoke != nil)
XCTAssertTrue(tokenAfterRevoke == nil)
await XCTAssertThrowsErrorAsync(try await client.users.getUserMe())
}

public func testOauthAuthDownscope() async throws {
Expand Down

0 comments on commit 2efe130

Please sign in to comment.