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 json | |
import os | |
import requests | |
import sys | |
import time | |
import unittest | |
# URL of SlimerJS / PhantomJS server | |
url = os.getenv('COMPATIPEDE_TAB_URL', 'http://192.168.1.6:8778') |
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 json | |
import os | |
import requests | |
import sys | |
import time | |
import unittest | |
from ../shared_config import do_command | |
class TestConsoleLogging(unittest.TestCase): |
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 requests | |
import json | |
import sys | |
import time | |
import pdb | |
import argparse | |
def do_command(url, command, data={}): | |
print "executing %s/%s\n" % (url, command), | |
headers = {'Content-type': 'application/json', 'Accept': 'text/plain'} |
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
function(){ | |
/* | |
Analyses applied CSS and sums up findings | |
We want to return a list of objects referring to elements | |
in the page with the following details: | |
selector: a CSS selector that will match the element (not necessarily the one in the CSS) | |
index: the index of the element in the selection you get | |
if you do document.querySelectorAll(selector) | |
coords: {x: y: width: height: } | |
problems: [ {property: value: } ] |
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
"use strict"; | |
var assert = require('assert'); | |
var request = require('request'); | |
require('should'); | |
var serviceURL, released, instance; | |
//Running simple http server here you can see when tab becomes available | |
require('http').createServer((req, resp) => { | |
let body = ''; |
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
# Get the client id and client secret from GitHub if you're part of the webcompat | |
# organization. Otherwise, create your own test and production applications, | |
# and take note of the client id and client secret GitHub gives you. | |
# | |
# [1]<https://github.com/organizations/webcompat/settings/applications/> | |
# If you're running this locally, you can ignore PRODUCTION and DEVELOPMENT | |
# blocks | |
# Production = webcompat.com | |
if PRODUCTION: | |
GITHUB_CLIENT_ID = "" |
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
(function(window, undefined) { | |
"use strict"; | |
/* -------->8 above stuff is start.js */ | |
/* -------->8 below stuff is shared/private-html5.js */ | |
var _globalConfig = {}; | |
var _document = window.document, | |
_Error = Error, | |
_hasOwn = window.Object.prototype.hasOwnProperty; |
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
/** | |
* A LabelList is a list of labels. It takes care of all namespace | |
* prefixing and unprefixing, so that the rest of the app doesn't | |
* ever need to worry about those details. Just pass in a list | |
* of labels from the server or a URL. | |
*/ | |
issues.LabelList = Backbone.Model.extend({ | |
initialize: function() { | |
this.set('namespaceRegex', /(browser|closed|os|status)-(.+)/i); | |
this.set('allLabelsURL', '/api/issues/labels'); // see "need a complete list" below |
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
<pre></pre> | |
<script> | |
var pre = document.getElementsByTagName('pre')[0]; | |
document.onbeforepaste = document.onbeforecopy = document.onbeforecut = function (e) { | |
pre.appendChild(document.createTextNode(e.type)); | |
} | |
for(var cmd in {'copy':1, 'cut':1, 'paste':1}){ | |
pre.appendChild(document.createTextNode('\n\n' + cmd.toUpperCase() + '\n')); |
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
@echo off | |
setlocal EnableDelayedExpansion | |
set SLJS_TEST=%SLJS_TEST% | |
echo. | |
echo No quotes added. Path is %SLJS_TEST% | |
echo. |