Skip to content

Instantly share code, notes, and snippets.

View shinglyu's full-sized avatar

Shing Lyu shinglyu

View GitHub Profile
{
"some/file/name":
[
{
"priority": 1.0,
"steps": [
{
"expected": "",
"step": "create pre-recorded user name and password"
},
# Foo
<script> alert('hi')</script>
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
import sys
from marionette.runner import (
BaseMarionetteOptions,
BaseMarionetteTestRunner,
MarionetteTestResult,
@shinglyu
shinglyu / stk_summary.sh
Created May 15, 2015 03:06
Shell script for parsing STK logs
# How to capture STK log:
# * Enable RIL log
# * adb logcat | grep typeOfCommand --line-buffered | tee /tmp/stk.log
if [ $# -lt 1 ]; then
echo "Usage: stk_summary.sh <log file>"
exit
fi
fname=$1
@shinglyu
shinglyu / teatcase.txt
Created April 28, 2015 07:21
moztrap-cli create new case syntax
TEST THAT fxos.rocketbar.search-provider.0
WHEN I search "star trek" using Yahoo
THEN The search page of Yahoo that searches "star trek" is shown correctly
=====
TEST THAT fxos.rocketbar.search-provider.1
WHEN I search "star wars" using Google
@shinglyu
shinglyu / gist:ae8880369428f6b42845
Created April 13, 2015 06:20
dev server router for BzDeck
<?php
// This file is used for testing bzdeck with php's built-in web server.
// Usage:
// 1. php -S localhost:8000 dev-router.php
// 2. Visit http://localhost:8000
if (basename($_SERVER["PHP_SELF"]) == 'index.html' || basename($_SERVER["PHP_SELF"]) == ''){
// php's built-in server does not process html files
include('index.html');
} else {
@shinglyu
shinglyu / gist:3335a8db8dead142e651
Created January 5, 2015 14:22
Failed host replacement
./mach run http://web1.localhost.test/
\\task 'ScriptTask' panicked at 'Failed to load page URL http://www.google.com
/, error: HttpIoError(Name or service not known)', parse/html.rs:195
stack backtrace:
1: 0x7fe894744010 - rt::backtrace::imp::write::h83394c9d811f80f16Ss
2: 0x7fe894747060 - failure::on_fail::h66ce8c5cd14ce043Tet
3: 0x7fe8947631a0 - unwind::begin_unwind_inner::h4d92541238adf4bcPad
4: 0x7fe894762e20 - unwind::begin_unwind_fmt::hd0f802b9c1361fb6h8c
5: 0x7fe8938f44f0 - parse::html::parse_html::hc6f6d762245955cbl2x
6: 0x7fe893b1bf40 - script_task::ScriptTask::load::h7124c2c99360f05dvDz
@shinglyu
shinglyu / gist:9887d46912dff12ac65c
Created November 22, 2014 14:03
Blob slice codegen fail log
Compiling script v0.0.1 (file:///home/shinglyu/workspace/servo)
Failed to run custom build command for `script v0.0.1 (file:///home/shinglyu/workspace/servo)`
Process didn't exit successfully: `make -f makefile.cargo` (status=2)
--- stdout
/usr/bin/python2.7 /home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/pythonpath.py \
-I/home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/parser -I/home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/ply \
-D/home/shinglyu/workspace/servo/components/script/dom/bindings/codegen \
/home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/GlobalGen.py /home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/Bindings.conf . \
--cachedir=/home/shinglyu/workspace/servo/components/script/dom/bindings/codegen/_cache \
/home/shinglyu/workspace/servo/components/script/dom/webidls/Attr.webidl /home/shinglyu/workspace/servo/components/script/dom/webidls/Blob.webidl /home/shinglyu/works