rresume 0.0.2
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/README +34 -0
- data/lib/README +14 -0
- data/lib/hula.html +62 -0
- data/lib/pdf-test.rb +8 -0
- data/lib/pdf-test2.rb +19 -0
- data/lib/rresume/duration.rb +19 -0
- data/lib/rresume/person.rb +12 -0
- data/lib/rresume/project.rb +121 -0
- data/lib/rresume/projectlist.rb +371 -0
- data/lib/rresume/tool.rb +14 -0
- data/lib/rresume.rb +6 -0
- data/lib/tables.rb +2 -0
- data/lib/thomas.rb +516 -0
- data/lib/thomas.template +7 -0
- data/lib/ttt.rb +9 -0
- data/test/tc_person.rb +122 -0
- data/test/tc_project.rb +16 -0
- data/test/tc_resume.rb +149 -0
- data/test/tc_tool.rb +20 -0
- data/test/ts_rresume.rb +5 -0
- metadata +66 -0
data/test/tc_resume.rb
ADDED
@@ -0,0 +1,149 @@
|
|
1
|
+
$:.unshift File.join(File.dirname(__FILE__), "..", "lib")
|
2
|
+
require 'test/unit' unless defined? $ZENTEST and $ZENTEST
|
3
|
+
require 'rresume/person'
|
4
|
+
require 'rresume/project'
|
5
|
+
require 'rresume/projectlist'
|
6
|
+
require 'rresume/tool'
|
7
|
+
|
8
|
+
# als Tool zaehlt ein Werkzeug wie eine Programmiersprache oder Datenbank,
|
9
|
+
# die einem Projekt zugeordnet werden kann.
|
10
|
+
# Einem Projekt k�nnen mehrere Tools zugeordnet werden.
|
11
|
+
|
12
|
+
class TestProject < Test::Unit::TestCase
|
13
|
+
def test_first_last_name
|
14
|
+
tp = Person.new
|
15
|
+
assert (tp.firstname == "")
|
16
|
+
assert (tp.lastname == "")
|
17
|
+
tp2 = Person.new("Thomas","Preymesser")
|
18
|
+
assert (tp2.firstname == "Thomas")
|
19
|
+
assert (tp2.lastname == "Preymesser")
|
20
|
+
end
|
21
|
+
|
22
|
+
def test_titel
|
23
|
+
p1 = Project.new "Philips"
|
24
|
+
assert (p1.titel == "Philips")
|
25
|
+
end
|
26
|
+
|
27
|
+
def test_zeiten
|
28
|
+
p1 = Project.new "Philips"
|
29
|
+
p1.von(1,1999)
|
30
|
+
p1.bis(3,2000)
|
31
|
+
assert(p1.von_monat == 1)
|
32
|
+
assert(p1.von_jahr == 1999)
|
33
|
+
assert(p1.bis_monat == 3)
|
34
|
+
assert(p1.bis_jahr == 2000)
|
35
|
+
assert(p1.monate == 15)
|
36
|
+
assert(p1.dauer.to_s == "15 Monate")
|
37
|
+
puts "Projekt: #{p1.titel} Dauer: #{p1.dauer}"
|
38
|
+
end
|
39
|
+
|
40
|
+
def test_beschreibung
|
41
|
+
p1 = Project.new "Philips"
|
42
|
+
p1.von(1,1999)
|
43
|
+
p1.bis(3,2000)
|
44
|
+
p1.beschreibung="Diverse Datenbankroutinen mit Ada95 geschrieben"
|
45
|
+
assert("Diverse Datenbankroutinen mit Ada95 geschrieben",p1.beschreibung)
|
46
|
+
puts p1.to_s
|
47
|
+
end
|
48
|
+
|
49
|
+
def test_branche
|
50
|
+
p1 = Project.new "Philips"
|
51
|
+
p1.von(1,1999)
|
52
|
+
p1.bis(3,2000)
|
53
|
+
p1.branche="Milit�r"
|
54
|
+
assert("Milit�r",p1.branche)
|
55
|
+
puts p1.to_s
|
56
|
+
end
|
57
|
+
|
58
|
+
def test_tool
|
59
|
+
projectlist = ProjectList.new("Thomas Preymesser")
|
60
|
+
p1 = Project.new "Philips"
|
61
|
+
p2 = Project.new "Signaal"
|
62
|
+
p3 = Project.new "Capup"
|
63
|
+
projectlist << p1;
|
64
|
+
projectlist << p2;
|
65
|
+
projectlist << p3;
|
66
|
+
projectlist.list
|
67
|
+
|
68
|
+
ada = Tool.new("Ada")
|
69
|
+
php = Tool.new("PHP")
|
70
|
+
oracle = Tool.new("Oracle")
|
71
|
+
p1.von(1,1999)
|
72
|
+
p1.bis(3,2000)
|
73
|
+
p1.branche="Milit�r"
|
74
|
+
|
75
|
+
p1.used_tool(php)
|
76
|
+
p1.used_tool(ada)
|
77
|
+
p1.used_tool(oracle)
|
78
|
+
|
79
|
+
puts projectlist.total_for("Ada")
|
80
|
+
p projectlist
|
81
|
+
assert(15 == projectlist.total_for("Ada"), "Total fuer ada muss 15 Monate sein")
|
82
|
+
assert(15 == projectlist.total_for("PHP"), "Total fuer php muss 15 Monate sein")
|
83
|
+
assert(15 == projectlist.total_for("Oracle"), "Total fuer oracle muss 15 Monate sein")
|
84
|
+
puts p1.to_s
|
85
|
+
|
86
|
+
#TODO: projectlist.tools_summary
|
87
|
+
end
|
88
|
+
|
89
|
+
def test_example1
|
90
|
+
# Container fuer saemtliche Projekte
|
91
|
+
projectlist = ProjectList.new("Thomas Preymesser") # z.b. mit Name der Person oder Firma
|
92
|
+
|
93
|
+
# folgende Tools koennen den Projekten zugeordnet werden
|
94
|
+
# hier koennen sowohl Programmiersprachen, Betriebssysteme, Datenbanken
|
95
|
+
# angegeben werden, je nach Vorlieben
|
96
|
+
ada = Tool.new("Ada")
|
97
|
+
php = Tool.new("PHP")
|
98
|
+
perl = Tool.new("Perl")
|
99
|
+
|
100
|
+
oracle = Tool.new("Oracle")
|
101
|
+
mysql = Tool.new("MySQL")
|
102
|
+
|
103
|
+
linux = Tool.new("Linux")
|
104
|
+
windows = Tool.new("Windows")
|
105
|
+
|
106
|
+
# ein erstes Projekt
|
107
|
+
philips = Project.new("mein Projekt bei Philips") # Text ist nur die interne Bezeichnung und wird nicht ausgegeben
|
108
|
+
|
109
|
+
# Start und Ende des Projekts (Monat/Jahr)
|
110
|
+
philips.von(1,1999)
|
111
|
+
philips.bis(3,2000)
|
112
|
+
# Branche und Beschreibung
|
113
|
+
philips.branche="Milit�r"
|
114
|
+
philips.beschreibung="umfangreiche Datenbankroutinen zu Flugprogrammen fuer Fernlenkraketen �ber und unter Wasser erstellt"
|
115
|
+
|
116
|
+
# welche Tools haben wir verwendet?
|
117
|
+
philips.used_tool(ada)
|
118
|
+
philips.used_tool(php)
|
119
|
+
philips.used_tool(oracle)
|
120
|
+
philips.used_tool(windows)
|
121
|
+
|
122
|
+
# nicht vergessen, das Projekt der Liste aller Projekt zuzuordnen
|
123
|
+
|
124
|
+
projectlist << philips
|
125
|
+
|
126
|
+
# noch ein Projekt
|
127
|
+
perl_projekt = Project.new("mein Perl-Projekt")
|
128
|
+
perl_projekt.von(4,2000)
|
129
|
+
perl_projekt.bis(6,2000)
|
130
|
+
perl_projekt.branche="Naturschutz"
|
131
|
+
perl_projekt.beschreibung="Statistische Analyse von Walbeobachtungsdaten"
|
132
|
+
perl_projekt.used_tool(perl)
|
133
|
+
projectlist << perl_projekt
|
134
|
+
|
135
|
+
# Ausgabe der Tools
|
136
|
+
puts "ingesamt Ada-Programmierung: "+projectlist.total_for("Ada").to_s
|
137
|
+
puts "ingesamt PHP-Programmierung: "+projectlist.total_for("PHP").to_s
|
138
|
+
puts "ingesamt Oracle-Programmierung: "+projectlist.total_for("Oracle").to_s
|
139
|
+
puts "ingesamt Windows-Programmierung: "+projectlist.total_for("Windows").to_s
|
140
|
+
# hier kommt 0 raus, da in keinem Projekt bisher verwendet
|
141
|
+
# nach dem Perl-projekt mu� hier nat�rlich 3 Monate rauskommen
|
142
|
+
puts "ingesamt Perl-Programmierung: "+projectlist.total_for("Perl").to_s
|
143
|
+
|
144
|
+
# alle Projekt auflisten
|
145
|
+
projectlist.output
|
146
|
+
|
147
|
+
assert(1)
|
148
|
+
end
|
149
|
+
end
|
data/test/tc_tool.rb
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
# Code Generated by ZenTest v. 3.3.0
|
2
|
+
# classname: asrt / meth = ratio%
|
3
|
+
# Tool: 0 / 2 = 0.00%
|
4
|
+
|
5
|
+
require 'test/unit' unless defined? $ZENTEST and $ZENTEST
|
6
|
+
|
7
|
+
class TestTool < Test::Unit::TestCase
|
8
|
+
|
9
|
+
def setup
|
10
|
+
@aTool = Tool.new("Ada")
|
11
|
+
end
|
12
|
+
|
13
|
+
def test_total
|
14
|
+
assert_equal("Ada", @aTool.name)
|
15
|
+
assert_equal(0,@aTool.total) # better tests!
|
16
|
+
assert_equal(@aTool.zuletzt, Date.new(1970,1,1))
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
# Number of errors detected: 2
|
data/test/ts_rresume.rb
ADDED
metadata
ADDED
@@ -0,0 +1,66 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
rubygems_version: 0.9.0
|
3
|
+
specification_version: 1
|
4
|
+
name: rresume
|
5
|
+
version: !ruby/object:Gem::Version
|
6
|
+
version: 0.0.2
|
7
|
+
date: 2006-08-09 00:00:00 +02:00
|
8
|
+
summary: Create resumes with Ruby
|
9
|
+
require_paths:
|
10
|
+
- lib
|
11
|
+
email: tp@thopre.de
|
12
|
+
homepage: http://www.thopre.de/rresume
|
13
|
+
rubyforge_project:
|
14
|
+
description:
|
15
|
+
autorequire: rresume
|
16
|
+
default_executable:
|
17
|
+
bindir: bin
|
18
|
+
has_rdoc: false
|
19
|
+
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
20
|
+
requirements:
|
21
|
+
- - ">"
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 0.0.0
|
24
|
+
version:
|
25
|
+
platform: ruby
|
26
|
+
signing_key:
|
27
|
+
cert_chain:
|
28
|
+
post_install_message:
|
29
|
+
authors:
|
30
|
+
- Thomas Preymesser
|
31
|
+
files:
|
32
|
+
- lib/pdf-test.rb
|
33
|
+
- lib/hula.html
|
34
|
+
- lib/README
|
35
|
+
- lib/thomas.rb
|
36
|
+
- lib/rresume
|
37
|
+
- lib/thomas.template
|
38
|
+
- lib/rresume.rb
|
39
|
+
- lib/pdf-test2.rb
|
40
|
+
- lib/tables.rb
|
41
|
+
- lib/ttt.rb
|
42
|
+
- lib/rresume/projectlist.rb
|
43
|
+
- lib/rresume/person.rb
|
44
|
+
- lib/rresume/tool.rb
|
45
|
+
- lib/rresume/project.rb
|
46
|
+
- lib/rresume/duration.rb
|
47
|
+
- test/ts_rresume.rb
|
48
|
+
- test/tc_resume.rb
|
49
|
+
- test/tc_project.rb
|
50
|
+
- test/tc_tool.rb
|
51
|
+
- test/tc_person.rb
|
52
|
+
- README
|
53
|
+
test_files:
|
54
|
+
- test/ts_rresume.rb
|
55
|
+
rdoc_options: []
|
56
|
+
|
57
|
+
extra_rdoc_files:
|
58
|
+
- README
|
59
|
+
executables: []
|
60
|
+
|
61
|
+
extensions: []
|
62
|
+
|
63
|
+
requirements: []
|
64
|
+
|
65
|
+
dependencies: []
|
66
|
+
|