Skip to content

Instantly share code, notes, and snippets.

View SketchSystems.spec
highlight -> Empty
type -> Non-Empty
cancel -> Absent
unfocus -> Absent

Non-Deterministic Testing Overview

Background/motivation: After working through the Unison tour, in particular the section on testing, I feel a little weird about caching property test results. I raised this on the Unison Slack, and we decided that it would be helpful for me to write up an overview of non-deterministic testing as a way to contribute. So, here goes!

Non-deterministic tests generally fall into two categories:

  1. property tests, where random values are fed into a function to assure a property holds (e.g. to assert that a function is idempotent by checking fn a == fn (fn a).) Examples: QuickCheck (Haskell/Erlang), Hedgehog (Haskell/F#/C#/R/Scala), Hypothesis (Python), elm-test (Elm)
  2. fuzz tests, where a random bytes are given to a program to make sure it behaves properly in the face of malformed input. These tests usually start with a corpus of inputs and mutate them using a genetic algorithm guided by co
View QGMLWY.tfl
"id": "custom-833cffe0-8447-4941-b97e-bdd4870bdeef",
"name": "QGMLWY",
"version": 1,
"keys": {
"KeyQ": {
"default": {
"base": "q",
"shift": "Q"
View Slice.elm
module Slice exposing
( Slice, slice
, Multiple, Position(..), before, after, getList
, Single, first, last, get, map
{-| Bisect a `Todos` in whatever way.
# initializing a slice
View Main.elm
module Main exposing (main)
import Benchmark exposing (..)
import Benchmark.Runner exposing (BenchmarkProgram, program)
main : BenchmarkProgram
main =
program <| "map2 vs case"
BrianHicks / SketchSystems.spec
Last active Mar 25, 2019
HighlightRevise Question
View SketchSystems.spec
HighlightRevise Question
Must Justify Lack of Highlights
No Highlights
continue -> Justify Highlight
highlight -> Highlighted
Justify Highlight
enter text -> Next Question
highlight -> Highlighted
View SketchSystems.spec
Multiple Choice
click not yet -> Not yet
click sort of -> Sort of
click definitely -> Definitely
No selection
Previous selection
continue -> Next Question
Not yet
continue -> Next Question
View export-things-area.js
#!/usr/bin/env osascript -l JavaScript
function run(argv) {
area = argv.join(" ");
var things = Application("Things3");
if (!things.running()) {
console.log("Things 3 is not running! Go start it and try me again.");

Brian's Ridiculous Customizations For Kinesis Advantage 2

I got a Kinesis Advantage 2 recently! It's great! But the stock layout (see appendix) has some problems:

  • I don't like cmd and ctrl being on the tiny buttons. I have to move my hands too much.
  • I don't like escape being in the function row. Needs to be somewhere easier to reach.
  • There are no media or volume keys bound by default.
  • Let's be honest, I never use home, end, page up, or page down. Almost everywhere I need to do those, I use cmd-left, cmd-right, space, and shift-space or readline shortcuts like c-e and c-a. They're easier to reach for me on most keyboards.
  • I really really really want a hyper key. It's easy to get to on most layouts (since the modifiers are all together) but not here. We also don't have a special switch, so we'll have to modify the software. Easy enough, right? (wrong.)
View gist:80f53e7fbc140ecd88d373fc51d1e2c4
Verifying my Blockstack ID is secured with the address 1Gf4sVtqRmLXesrbPXdrxZEBq1iy5XLXhE
You can’t perform that action at this time.