Skip to content

Commit

Permalink
disabling more stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
leogdion committed May 13, 2024
1 parent dfe6de5 commit 55f8fdf
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 39 deletions.
46 changes: 23 additions & 23 deletions Tests/FeatherQuillTests/AudienceType.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,26 @@
// OTHER DEALINGS IN THE SOFTWARE.
//

import FeatherQuill

public struct AudienceType: UserType {
public typealias RawValue = Int
public static let proSubscriber: AudienceType = .init(rawValue: 1)
public static let testFlightBeta: AudienceType = .init(rawValue: 2)
public static let any: AudienceType = .init(rawValue: .max)
public static let `default`: AudienceType = [.testFlightBeta, proSubscriber]
public static let none: AudienceType = []
public var rawValue: Int

public init(rawValue: Int) {
self.rawValue = rawValue
}

public static func includes(_ value: AudienceType) -> Bool {
guard value.rawValue > 0 else {
return false
}
let value: Bool = .random()
return value
}
}
//import FeatherQuill
//
//public struct AudienceType: UserType {
// public typealias RawValue = Int
// public static let proSubscriber: AudienceType = .init(rawValue: 1)
// public static let testFlightBeta: AudienceType = .init(rawValue: 2)
// public static let any: AudienceType = .init(rawValue: .max)
// public static let `default`: AudienceType = [.testFlightBeta, proSubscriber]
// public static let none: AudienceType = []
// public var rawValue: Int
//
// public init(rawValue: Int) {
// self.rawValue = rawValue
// }
//
// public static func includes(_ value: AudienceType) -> Bool {
// guard value.rawValue > 0 else {
// return false
// }
// let value: Bool = .random()
// return value
// }
//}
2 changes: 1 addition & 1 deletion Tests/FeatherQuillTests/FeatureTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
// OTHER DEALINGS IN THE SOFTWARE.
//

@testable import FeatherQuill
//@testable import FeatherQuill
import XCTest

//internal final class FeatureTests: XCTestCase {
Expand Down
30 changes: 15 additions & 15 deletions Tests/FeatherQuillTests/MockFeatureFlag.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,18 @@
// OTHER DEALINGS IN THE SOFTWARE.
//

#if canImport(SwiftUI)
import FeatherQuill

internal struct MockFeatureFlag: FeatureFlag {
internal typealias UserTypeValue = AudienceType

internal static let initialValue: Int = .random(in: 1_000 ... 9_999)

internal static let probability: Double = .random(in: 0 ..< 1)

internal static func evaluateUser(_: AudienceType) async -> Bool {
true
}
}
#endif
//#if canImport(SwiftUI)
// import FeatherQuill
//
// internal struct MockFeatureFlag: FeatureFlag {
// internal typealias UserTypeValue = AudienceType
//
// internal static let initialValue: Int = .random(in: 1_000 ... 9_999)
//
// internal static let probability: Double = .random(in: 0 ..< 1)
//
// internal static func evaluateUser(_: AudienceType) async -> Bool {
// true
// }
// }
//#endif

0 comments on commit 55f8fdf

Please sign in to comment.