Skip to content

Instantly share code, notes, and snippets.

@marcisme
marcisme / swift-testing-playbook.md
Created July 17, 2025 13:40 — forked from steipete/swift-testing-playbook.md
The Ultimate Swift Testing Playbook (feed it your agents for better tests!)

The Ultimate Swift Testing Playbook (2024 WWDC Edition, expanded with Apple docs from June 2025)

Updated with info from https://developer.apple.com/documentation/testing fetched via Firecrawl on June 7, 2025.

See also my blog: See also my blog post: https://steipete.me/posts/2025/migrating-700-tests-to-swift-testing

A hands-on, comprehensive guide for migrating from XCTest to Swift Testing and mastering the new framework. This playbook integrates the latest patterns and best practices from WWDC 2024 and official Apple documentation to make your tests more powerful, expressive, and maintainable.


1. Migration & Tooling Baseline

@marcisme
marcisme / claude-log.md
Created March 26, 2025 02:43
Sony lens research

I'll search for the width and length of the Sony lenses you're interested in.​​​​​​​​​​​​​​​​

Let me search for information about the 200-600mm lens dimensions:​​​​​​​​​​​​​​​​

I need to search for additional specific information about the 300mm lens dimensions:​​​​​​​​​​​​​​​​

Let me use my last search to get information about the 400mm lens dimensions:​​​​​​​​​​​​​​​​

Hi! Thanks for looking
TL;DR - trying to do anything with os_signpost, but nothing is appearing in instruments.
UPDATE: on devices it's working. Is it supposed to work in the simulator? Points of Interest are on built-in templates, I figured it should work on the device...
The app is all objc, using the C API. See at the end for a swift attempt
More details:
Creating the log like this:
@marcisme
marcisme / Info.plist
Created September 5, 2021 22:35 — forked from BalestraPatrick/Info.plist
Custom URL scheme Launch Storyboard Info.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
//
// MSSAssertions.swift
// FastOne
//
// Created by Marc Schwieterman on 3/8/15.
// Copyright (c) 2015 Marc Schwieterman Software, LLC. All rights reserved.
//
import Foundation
@marcisme
marcisme / karabiner.json
Created June 26, 2017 03:30
Karabiner Elements Config
{
"profiles": [
{
"complex_modifications": {
"rules": [
{
"manipulators": [
{
"description": "Change caps_lock to control when used as modifier, escape when used alone",
"from": {
class KeyboardDodger {
private struct KeyboardValues {
private let userInfo: [AnyHashable : Any]
init(notification: Notification) {
userInfo = (notification as NSNotification).userInfo!
}
#!/bin/sh
git=$(sh /etc/profile; which git)
git_release_version=$("$git" describe --tags --always --abbrev=0)
number_of_commits=$("$git" rev-list master | wc -l | tr -d ' ')
target_plist="$TARGET_BUILD_DIR/$INFOPLIST_PATH"
dsym_plist="$DWARF_DSYM_FOLDER_PATH/$DWARF_DSYM_FILE_NAME/Contents/Info.plist"
for plist in "$target_plist" "$dsym_plist"; do
if [ -f "$plist" ]; then
@marcisme
marcisme / private.xml
Last active September 17, 2016 18:30
Karabiner configuration
<?xml version="1.0"?>
<root>
<item>
<name>F19 to Escape or Control</name>
<appendix>(Hold F19 to ctrl, tap F19 to send escape)</appendix>
<identifier>private.f19_escape_control</identifier>
<autogen>
__KeyDownUpToKey__
KeyCode::F19 <!-- caps-lock sends F19 -->
__{KeyCode::ESCAPE}__ <!-- send escape when released -->

Keybase proof

I hereby claim:

  • I am marcisme on github.
  • I am marcisme (https://keybase.io/marcisme) on keybase.
  • I have a public key whose fingerprint is E82D B1F9 077E 3873 0B4F 756A 8104 F332 FE5A D78E

To claim this, I am signing this object: