mirror of
https://github.com/joaotavora/yasnippet.git
synced 2025-12-12 00:14:18 +00:00
Last commit before tagging and releasing
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: bm-
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: Benchmark.bmbm do .. end
|
||||
# --
|
||||
TESTS = ${1:10_000}
|
||||
Benchmark.bmbm do |results|
|
||||
$0
|
||||
end
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: as
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert(..)
|
||||
# --
|
||||
assert`snippet_paren.rb`${1:test}, "${0:Failure message.}"`snippet_paren.rb end`
|
||||
6
extras/imported/ruby-mode/Tests/assert_equal.yasnippet
Normal file
6
extras/imported/ruby-mode/Tests/assert_equal.yasnippet
Normal file
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: ase
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_equal(..)
|
||||
# --
|
||||
assert_equal`snippet_paren.rb`${1:expected}, ${0:actual}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asid
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_in_delta(..)
|
||||
# --
|
||||
assert_in_delta`snippet_paren.rb`${1:expected_float}, ${2:actual_float}, ${0:2 ** -20}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asio
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_instance_of(..)
|
||||
# --
|
||||
assert_instance_of`snippet_paren.rb`${1:ExpectedClass}, ${0:actual_instance}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asko
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_kind_of(..)
|
||||
# --
|
||||
assert_kind_of`snippet_paren.rb`${1:ExpectedKind}, ${0:actual_instance}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asm
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_match(..)
|
||||
# --
|
||||
assert_match`snippet_paren.rb`/${1:expected_pattern}/, ${0:actual_string}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asn
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_nil(..)
|
||||
# --
|
||||
assert_nil`snippet_paren.rb`${0:instance}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asnm
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_no_match(..)
|
||||
# --
|
||||
assert_no_match`snippet_paren.rb`/${1:unexpected_pattern}/, ${0:actual_string}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asne
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_not_equal(..)
|
||||
# --
|
||||
assert_not_equal`snippet_paren.rb`${1:unexpected}, ${0:actual}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asnn
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_not_nil(..)
|
||||
# --
|
||||
assert_not_nil`snippet_paren.rb`${0:instance}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asns
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_not_same(..)
|
||||
# --
|
||||
assert_not_same`snippet_paren.rb`${1:unexpected}, ${0:actual}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asnr
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_nothing_raised(..) { .. }
|
||||
# --
|
||||
assert_nothing_raised(${1:Exception}) { $0 }
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asnt
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_nothing_thrown { .. }
|
||||
# --
|
||||
assert_nothing_thrown { $0 }
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: aso
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_operator(..)
|
||||
# --
|
||||
assert_operator`snippet_paren.rb`${1:left}, :${2:operator}, ${0:right}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asr
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_raise(..) { .. }
|
||||
# --
|
||||
assert_raise(${1:Exception}) { $0 }
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: asrt
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_respond_to(..)
|
||||
# --
|
||||
assert_respond_to`snippet_paren.rb`${1:object}, :${0:method}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: ass
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_same(..)
|
||||
# --
|
||||
assert_same`snippet_paren.rb`${1:expected}, ${0:actual}`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: ass
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_send(..)
|
||||
# --
|
||||
assert_send`snippet_paren.rb`[${1:object}, :${2:message}, ${0:args}]`snippet_paren.rb end`
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: ast
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: assert_throws(..) { .. }
|
||||
# --
|
||||
assert_throws(:${1:expected}) { $0 }
|
||||
@@ -0,0 +1,14 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: tc
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: class .. < Test::Unit::TestCase .. end
|
||||
# --
|
||||
require "test/unit"
|
||||
|
||||
require "${1:library_file_name}"
|
||||
|
||||
class Test${2:${1/([\w&&[^_]]+)|./\u$1/g}} < Test::Unit::TestCase
|
||||
def test_${3:case_name}
|
||||
$0
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,8 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: deft
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: def test_ .. end
|
||||
# --
|
||||
def test_${1:case_name}
|
||||
$0
|
||||
end
|
||||
6
extras/imported/ruby-mode/Tests/flunk(..) (fl).yasnippet
Normal file
6
extras/imported/ruby-mode/Tests/flunk(..) (fl).yasnippet
Normal file
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: fl
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: flunk(..)
|
||||
# --
|
||||
flunk`snippet_paren.rb`"${0:Failure message.}"`snippet_paren.rb end`
|
||||
@@ -0,0 +1,9 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: ts
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: require "tc_.." ..
|
||||
# --
|
||||
require "test/unit"
|
||||
|
||||
require "tc_${1:test_case_file}"
|
||||
require "tc_${2:test_case_file}"
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- mode: snippet -*-
|
||||
# key: rep
|
||||
# contributor: Translated from TextMate Snippet
|
||||
# name: results.report(..) { .. }
|
||||
# --
|
||||
results.report("${1:name}:") { TESTS.times { $0 } }
|
||||
Reference in New Issue
Block a user