trueskill 0.9.0 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -2,6 +2,6 @@ require 'pp'
2
2
 
3
3
  require "#{File.dirname(__FILE__)}/gauss.rb"
4
4
 
5
- Dir.glob("#{File.dirname(__FILE__)}/trueskill/**/*.rb").each do |src|
5
+ Dir.glob("#{File.dirname(__FILE__)}/trueskill/**/*.rb").sort.each do |src|
6
6
  require src
7
7
  end
@@ -30,4 +30,28 @@ describe Saulabs::TrueSkill::FactorGraph do
30
30
 
31
31
  end
32
32
 
33
+ end
34
+
35
+ describe Saulabs::TrueSkill::FactorGraph do
36
+
37
+ before :each do
38
+ @teams = [
39
+ [
40
+ TrueSkill::Rating.new(8.3, 3.1, 0.8, 0.02),
41
+ TrueSkill::Rating.new(3.0, 3.1, 0.8, 0.02),
42
+ TrueSkill::Rating.new(2.2, 3.2, 0.8, 0.02)
43
+ ],
44
+ [
45
+ TrueSkill::Rating.new(25.0, 8.3333, 0.8, 0.02)
46
+ ]
47
+ ]
48
+ @skill = @teams.last.first
49
+ @graph = TrueSkill::FactorGraph.new(@teams, [1,2], :beta => 25.0, :draw_probability => 0.0)
50
+ end
51
+
52
+ it "should do something" do
53
+ 40.times { TrueSkill::FactorGraph.new(@teams, [1,2], :beta => 15.0, :draw_probability => 0.0).update_skills }
54
+ puts "#{@skill.to_s}"
55
+ end
56
+
33
57
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 9
8
- - 0
9
- version: 0.9.0
8
+ - 1
9
+ version: 0.9.1
10
10
  platform: ruby
11
11
  authors:
12
12
  - Lars Kuhnt