Skip to content

Instantly share code, notes, and snippets.

View corteggo's full-sized avatar

Cristian Ortega corteggo

View GitHub Profile
@corteggo
corteggo / remove_last_character_string.swift
Created September 25, 2018 18:46
Remove last character of a String in Swift 4.2
let yourString: String = "Hello World"
let yourSubstring: String = yourString.dropLast()
print(yourSubstring) // Will print: "Hello Worl"
@corteggo
corteggo / Springboard.swift
Last active March 18, 2025 22:04
Uninstalling app in XCUITests
/// Springboard UITests helper
/// USAGE: Springboard.uninstallApp(named: "Instagram")
internal final class Springboard {
// MARK; - Constants
/// Press duration
private static let pressDuration: Double = 1.3
/// Delete button name
private static let deleteButtonName: String = "Delete"