Defined the Artifact enumeration in the library target and conformed it to the Randomable protocol.
This commit is contained in:
1 parent
a6b8c08125
commit
5676f91bcb
1 file changed
+16
@@ -0,0 +1,16 @@
|
||||
public enum Artifact: String {
|
||||
case executable
|
||||
case image
|
||||
}
|
||||
|
||||
// MARK: - Randomable
|
||||
|
||||
extension Artifact: Randomable {
|
||||
|
||||
// MARK: Functions
|
||||
|
||||
static func random() -> Artifact {
|
||||
.allCases.randomElement() ?? .executable
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user