Skip to content

Instantly share code, notes, and snippets.

View ptc-mrucci's full-sized avatar

Marco Rucci ptc-mrucci

  • PTC
  • Zurich, Switzerland
View GitHub Profile
@ptc-mrucci
ptc-mrucci / unit.sh
Last active March 31, 2023 10:49 — forked from tvlooy/unit.sh
Bash test: get the directory of a script
#!/bin/bash
tmp=$(python -c "import os, sys; print(os.path.realpath('/tmp'))")
function test {
MESSAGE=$1
RECEIVED=$2
EXPECTED=$3
if [ "$RECEIVED" = "$EXPECTED" ]; then