This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -- FILE: features/steps/example_steps.py | |
from behave import given, when, then, step | |
import time | |
@given('we have behave installed') | |
def step_impl(context): | |
time.sleep(1) | |
@when('we implement {number:d} tests') | |
def step_impl(context, number): # -- NOTE: number is converted into integer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import win32com.client | |
import win32gui | |
wmp = win32com.client.dynamic.Dispatch("WMPlayer.OCX") | |
wmp.settings.autoStart = True | |
wmp.settings.volume = 50 | |
wmp.URL = "sample.wma" | |
while wmp.Playstate != 1: | |
win32gui.PumpWaitingMessages() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# rc definitions for dark backgrounds | |
lines.color: white | |
patch.edgecolor: white | |
text.color: white | |
axes.facecolor: black | |
axes.edgecolor: white | |
axes.labelcolor: white |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pyaudio | |
p = pyaudio.PyAudio() | |
for i in range(p.get_device_count()): | |
print p.get_device_info_by_index(i) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import vlc | |
import time | |
p = vlc.MediaPlayer("organfinale.wav") | |
p.play() | |
device = p.audio_output_device_enum() | |
while device: | |
print "playing on..." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def assert_file_equal(a, b): | |
a = open(a, "rb").read() | |
b = open(b, "rb").read() | |
if a != b: | |
diff = difflib.ndiff(a.splitlines(True), | |
b.splitlines(True)) | |
message = ''.join(diff) | |
raise AssertionError("Not equal:\n" + message) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set DEVCON="C:\Program Files (x86)\Windows Kits\10\Tools\x64\devcon.exe" | |
REM DevCon hwids - https://msdn.microsoft.com/en-us/library/windows/hardware/ff544772(v=vs.85).aspx | |
%DEVCON% hwids invalid > devcon_hwids_invalid.txt 2>&1 | |
%DEVCON% hwids * > devcon_hwids_star.txt 2>&1 | |
%DEVCON% hwids =AudioEndpoint > devcon_hwids_class.txt 2>&1 | |
%DEVCON% hwids MMDEVAPI\AudioEndpoints > devcon_hwids_hwid.txt 2>&1 | |
%DEVCON% hwids @SWD\MMDEVAPI\{0.0.0.00000000}.{32247EDD-EAC6-46F8-BEFB-44448BDBC8D3} > devcon_hwids_instanceid.txt 2>&1 | |
REM DevCon classes - https://msdn.microsoft.com/en-us/library/windows/hardware/ff544712(v=vs.85).aspx |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# see http://about.travis-ci.org/docs/user/languages/php/ for more hints | |
language: php | |
# list any PHP version you want to test against | |
php: | |
# using major version aliases | |
# aliased to 5.2.17 | |
- 5.2 | |
# aliased to 5.3.29 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" ?> | |
<testsuite errors="0" failures="2" hostname="curzona-desktop" name="TestHelloJUnit" skipped="0" tests="2" time="0.049" timestamp="2015-07-31T06:46:01"> | |
<properties> | |
<property name="ant.project.invoked-targets" value="test" /> | |
<property name="java.runtime.name" value="OpenJDK Runtime Environment" /> | |
<property name="sun.boot.library.path" value="/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/amd64" /> | |
<property name="java.vm.version" value="24.79-b02" /> | |
<property name="ant.library.dir" value="/usr/share/ant/lib" /> | |
<property name="ant.version" value="Apache Ant(TM) version 1.9.3 compiled on April 8 2014" /> | |
<property name="ant.java.version" value="1.7" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
python -c "import thing; thing.foo()" |