Skip to content

Instantly share code, notes, and snippets.

@BeforeClass
public void setupOnce() {
try {
autocompleter = new String(FileUtility.readFully("input/autocompleter.rb"));
indenter = new String(FileUtility.readFully("input/indenter.rb"));
snippetInserter = new String(FileUtility.readFully("input/snippet_inserter.rb"));
String[] patterns = {
"\\\\(?:0\\d{1,2}|x[\\da-fA-F]{1,2}|.)", "(#\\$)[a-zA-Z_]\\w*",
$ jruby -J-XstartOnFirstThread lib/env.rb
Feature: Menu bar should appear
Scenario: whuh
Then the browser should be viewing the url "http://www.google.co.uk/"
1 scenario (1 passed)
1 step (1 passed)
0m0.011s
module Monitoring
class Act < ActiveRecord::Base
validates_presence_of :details
serialize :details
end
end
@it = Monitoring::Act.new(:details => {:foo => "bar"})
p @it
module Cucumber
module Formatter
class SwtFormatter < Pretty
# step must execute in the correct thread:
def visit_step(*)
block = RRunnable.new do
super
end
Redcar::ApplicationSWT.display.syncExec(block)
w keyCode: 119, character: 119, statemask: 0
Shift+w keyCode: 119, character: 87, statemask: 131072
Ctrl+w keyCode: 119, character: 23, statemask: 262144
Alt+w keyCode: 119, character: 8721, statemask: 65536
Cmd+w keyCode: 119, character: 119, statemask: 4194304
key character
Alt+a 229
Alt+b 8747
Alt+c 231
def foo
foo
end
def bar
begin
foo
rescue => e
p :caught
end
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:danlucraft/redcar.git
[branch "master"]
--server
Total load time is about 16s:
rbconfig - 524ms
open-uri - 887ms (removable for default case)
fileutils - 316ms
java - 573ms
yaml - 548ms
logging library - 936ms (NOT loaded through gems)
jruby irb:
>> " foo.bar".match(/(\s|[^\w]){2,}/).end(0)
=> 1
mri irb:
>> " foo.bar".match(/(\s|[^\w]){2,}/)
=> nil
file:
------
re=<<RE
(?x)^
(?= [ ]{,3}&gt;.
| ([ ]{4}|\t)(?!$)
| [#]{1,6}\s*+
| [ ]{,3}(?<marker>[-*_])([ ]{,2}\k<marker>){2,}[ \t]*+$
)
RE