capykit 0.0.38 → 0.0.40

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/bin/capykit CHANGED
@@ -27,8 +27,10 @@ CapybaraApi.send :xload #call protected methods
27
27
  # puts code
28
28
  # end
29
29
  #end
30
-
31
-
30
+ puts ""
31
+ puts "~> capy_methods"
32
+ p CapybaraApi.capy_methods
33
+ puts " => nil "
32
34
  puts "Capykit loaded..."
33
35
  def IRB.start_capybara_console
34
36
  IRB.setup(__FILE__)
@@ -11,8 +11,13 @@ module Capykit::Base::Ref
11
11
 
12
12
  def capy_methods
13
13
  arr=modules_methods.sort!
14
- ar2=arr.select{|xx|xx.length==1}
15
- ar2 + (arr-ar2)
14
+ a_len1=arr.select{|xx|xx.length==1}
15
+ a_grt1=arr-a_len1
16
+ a_meth=a_grt1.select{|xx|xx=~/_methods$/}
17
+ a_selc=a_grt1.select{|xx|xx=~/^aselector/}
18
+ a_site=a_grt1.select{|xx|xx=~/^vsite/}
19
+ a_rest=a_grt1-(a_meth+a_selc+a_site)
20
+ a_len1 + a_meth + a_selc + a_site + a_rest
16
21
  end
17
22
 
18
23
  def auto_methods
@@ -44,9 +44,24 @@ module Capykit::Base::Util
44
44
  task[1] if task
45
45
  end
46
46
 
47
+ def tasks(*arg)
48
+ if arg.length==0
49
+ @tasks
50
+ else
51
+ key=@tasks.keys.select{|kk|kk.to_s=~/#{arg[0]}/i}[0]
52
+ key ? @tasks[key] : nil
53
+ end
54
+ end
55
+
47
56
  #def x_se_go(kwd,sym=:g)
48
57
  # v sym if !w('[name=q]',1)
49
58
  # f "q:#{kwd}",:submit
50
59
  #end
51
60
 
61
+ end
62
+
63
+ class Symbol
64
+ def task
65
+ CapybaraApi.tasks self.to_s
66
+ end
52
67
  end
@@ -1,3 +1,3 @@
1
1
  module Capykit
2
- VERSION = "0.0.38"
2
+ VERSION = "0.0.40"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capykit
3
3
  version: !ruby/object:Gem::Version
4
- hash: 83
5
- prerelease: false
4
+ hash: 79
5
+ prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 38
10
- version: 0.0.38
9
+ - 40
10
+ version: 0.0.40
11
11
  platform: ruby
12
12
  authors:
13
13
  - Widi Harsojo
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-03-17 00:00:00 +07:00
18
+ date: 2011-03-30 00:00:00 +07:00
19
19
  default_executable: capykit
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -85,7 +85,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
85
85
  requirements: []
86
86
 
87
87
  rubyforge_project: capykit
88
- rubygems_version: 1.3.7
88
+ rubygems_version: 1.6.2
89
89
  signing_key:
90
90
  specification_version: 3
91
91
  summary: Capybara mini dsl extension