cauldron 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +2 -0
- data/Rakefile +7 -0
- data/VERSION +1 -1
- data/features/cauldron_generates_runtime_method.feature +3 -2
- data/features/step_definitions/cauldron_steps.rb +0 -1
- data/features/support/method_1.example +3 -0
- data/features/support/method_2.example +6 -0
- data/lib/Chain.rb +140 -264
- data/lib/CodeHandler.rb +0 -4
- data/lib/ScopeDependencies.rb +1 -0
- data/lib/Theory.rb +12 -15
- data/lib/UnifiedChain.rb +265 -8
- data/lib/cauldron.rb +1 -1
- data/lib/cauldron/demos.rb +280 -0
- data/lib/cauldron/pot.rb +56 -30
- data/lib/cauldron/sexp2cauldron.rb +109 -126
- data/lib/cauldron/terminal.rb +5 -74
- data/lib/core/ClassMethodCallContainer.rb +14 -0
- data/lib/core/Container.rb +12 -2
- data/lib/core/InstanceCallContainer.rb +30 -4
- data/lib/core/TheoryGenerator.rb +2 -9
- data/lib/core/assignment/Equal.rb +1 -1
- data/lib/core/assignment/Equivalent.rb +1 -1
- data/lib/core/assignment/NotEqual.rb +1 -1
- data/lib/core/call_container/CallContainer.rb +7 -1
- data/lib/core/instance_call/Chop.rb +0 -9
- data/lib/core/instance_call/instance_calls.rb +8 -0
- data/lib/core/instance_call/length_equal.rb +1 -1
- data/lib/core/requirement/Requirement.rb +1 -0
- data/lib/core/runtime_class/class_names.rb +12 -12
- data/lib/core/runtime_method/ActsAsRuntimeMethod.rb +0 -7
- data/lib/core/runtime_method/RuntimeMethod.rb +59 -45
- data/lib/core/statement/ActsAsStatement.rb +1 -1
- data/lib/core/statement/ArrayAccess.rb +28 -2
- data/lib/core/statement/OpenStatement.rb +7 -0
- data/lib/core/statement/Statement.rb +22 -18
- data/lib/core/statement/TheoryStatement.rb +8 -1
- data/lib/core/syntax/Addition.rb +3 -2
- data/lib/core/syntax/If.rb +8 -0
- data/lib/core/syntax/Return.rb +1 -1
- data/lib/core/variable/BaseVariable.rb +0 -2
- data/lib/core/variable/MethodParameter.rb +4 -31
- data/lib/core/variable/Unknown.rb +1 -5
- data/lib/implemented_chain.rb +3 -2
- data/lib/required.rb +0 -1
- data/lib/ruby_code/String.rb +0 -17
- data/lib/theories.rb +25 -1
- data/lib/theory/TheoryAction.rb +35 -5
- data/lib/theory/TheoryChainValidator.rb +10 -8
- data/lib/theory/TheoryComponent.rb +17 -0
- data/lib/theory/TheoryConnector.rb +76 -9
- data/lib/theory/TheoryDependent.rb +2 -2
- data/lib/theory/TheoryImplementation.rb +7 -7
- data/lib/util/ClassEvaluation.rb +2 -7
- data/lib/util/MethodValidation.rb +10 -6
- data/lib/util/Parser.rb +26 -20
- data/lib/util/StringToTheory.rb +27 -3
- data/spec/cauldron/chain_spec.rb +24 -0
- data/spec/cauldron/demos_spec.rb +30 -0
- data/spec/cauldron/pot_spec.rb +66 -0
- data/spec/cauldron/runtime_method_spec.rb +47 -5
- data/spec/cauldron/sexp_2_cauldron_spec.rb +92 -0
- data/spec/cauldron/terminal_spec.rb +1 -1
- data/spec/cauldron/theory_action_spec.rb +20 -0
- data/spec/cauldron/theory_connector_spec.rb +52 -0
- data/spec/cauldron/theory_spec.rb +59 -0
- data/spec/cauldron/unified_chain_spec.rb +102 -0
- data/spec/spec_helper.rb +10 -1
- data/tasks/theory_tasks.rake +274 -0
- data/test/fixtures/implementation_results/0/dump +0 -0
- data/test/fixtures/theories/0/dump +0 -0
- data/test/fixtures/theories/1/dump +0 -0
- data/test/fixtures/theories/10/dump +0 -0
- data/test/fixtures/theories/11/dump +0 -0
- data/test/fixtures/theories/12/dump +0 -0
- data/test/fixtures/theories/13/declaration.txt +1 -1
- data/test/fixtures/theories/13/desc +1 -1
- data/test/fixtures/theories/13/dump +0 -0
- data/test/fixtures/theories/14/dump +0 -0
- data/test/fixtures/theories/15/dump +0 -0
- data/test/fixtures/theories/16/dump +0 -0
- data/test/fixtures/theories/17/dump +0 -0
- data/test/fixtures/theories/18/dump +0 -0
- data/test/fixtures/theories/19/dump +0 -0
- data/test/fixtures/theories/2/dump +0 -0
- data/test/fixtures/theories/20/declaration.txt +1 -1
- data/test/fixtures/theories/20/desc +1 -1
- data/test/fixtures/theories/20/dump +0 -0
- data/test/fixtures/theories/3/dump +0 -0
- data/test/fixtures/theories/4/dump +0 -0
- data/test/fixtures/theories/5/dump +0 -0
- data/test/fixtures/theories/6/dump +0 -0
- data/test/fixtures/theories/7/dump +0 -0
- data/test/fixtures/theories/8/dump +0 -0
- data/test/fixtures/theories/9/dump +0 -0
- data/test/fixtures/theory_implementations/0/declaration.txt +1 -1
- data/test/fixtures/theory_implementations/0/dump +0 -0
- data/test/fixtures/theory_implementations/1/declaration.txt +11 -0
- data/test/fixtures/theory_implementations/1/dump +0 -0
- data/test/fixtures/theory_implementations/2/declaration.txt +11 -0
- data/test/fixtures/theory_implementations/2/dump +0 -0
- data/test/output/simple_method.txt +0 -1
- data/test/tc_contextual_variables.rb +2 -41
- data/test/tc_describe.rb +1 -2
- data/test/tc_method.rb +2 -5
- data/test/unit/core/runtime_method/tc_realised_runtime_method.rb +5 -3
- data/test/unit/core/runtime_method/tc_runtime_method.rb +34 -56
- data/test/unit/core/statement/tc_block_statement.rb +2 -0
- data/test/unit/core/statement/tc_open_statement.rb +15 -6
- data/test/unit/core/statement/tc_statement.rb +4 -5
- data/test/unit/core/statement/tc_statement_dependencies.rb +1 -0
- data/test/unit/core/statement/tc_theory_statement.rb +2 -0
- data/test/unit/core/syntax/tc_if_container.rb +5 -5
- data/test/unit/core/tc_theory_generator_heavy.rb +1 -1
- data/test/unit/core/tracking/tc_history.rb +3 -1
- data/test/unit/core/variable/tc_method_parameter_variable.rb +2 -2
- data/test/unit/tc_chain_with_case_1.rb +1 -1
- data/test/unit/tc_method_usage.rb +1 -1
- data/test/unit/tc_theory.rb +8 -2
- data/test/unit/theory/tc_theory_action.rb +37 -5
- data/test/unit/theory/tc_theory_chain_validator.rb +3 -3
- data/test/unit/theory/tc_theory_connector.rb +2 -37
- data/test/unit/theory/tc_theory_dependent.rb +2 -0
- data/test/unit/theory/tc_theory_implementation.rb +5 -1
- data/test/unit/theory/tc_theory_result.rb +3 -2
- data/test/unit/util/tc_method_validation.rb +4 -1
- data/test/unit/util/tc_parser.rb +2 -0
- data/test/unit/util/tc_string_to_theory.rb +3 -2
- data/tmp/runtime_method_evaluation.rb +7 -4
- metadata +59 -13
- data/lib/core/syntax/IfContainer.rb +0 -100
@@ -36,7 +36,7 @@ class TestChainWithCase1 < Test::Unit::TestCase
|
|
36
36
|
)
|
37
37
|
t1_action = TheoryAction.new(
|
38
38
|
TheoryStatement.new(StringToTheory.run(
|
39
|
-
'OpenStatement.new(
|
39
|
+
'OpenStatement.new(Statement.new(If.new,Container.new(var1.params[var6],Equivalent.new,var2[var3][:params][var6])))'
|
40
40
|
)),
|
41
41
|
StringToTheory.run('var1.statement_id')
|
42
42
|
)
|
@@ -9,7 +9,7 @@ class TestMethodUsage < Test::Unit::TestCase
|
|
9
9
|
@empty_method_usage = MethodUsage.new
|
10
10
|
|
11
11
|
# Requires a string variable
|
12
|
-
@method_var_a = MethodParameter.new
|
12
|
+
@method_var_a = MethodParameter.new
|
13
13
|
@string_paramater_case = MethodUsage.new(@method_var_a)
|
14
14
|
|
15
15
|
end
|
data/test/unit/tc_theory.rb
CHANGED
@@ -1,4 +1,7 @@
|
|
1
|
-
|
1
|
+
$LOAD_PATH << File.expand_path('../../../lib',__FILE__)
|
2
|
+
|
3
|
+
require 'cauldron'
|
4
|
+
|
2
5
|
require 'test/unit'
|
3
6
|
|
4
7
|
class TestTheory < Test::Unit::TestCase
|
@@ -373,7 +376,7 @@ class TestTheory < Test::Unit::TestCase
|
|
373
376
|
|
374
377
|
def test_map_to_case1_theory_1
|
375
378
|
|
376
|
-
theory =Theory.load_theory
|
379
|
+
theory =Theory.load_theory(9)
|
377
380
|
# runtime_method = RuntimeMethod.new(MethodUsage.new(MethodParameter.new))
|
378
381
|
# test_cases = [
|
379
382
|
# {:params=>['something'], :output=>'exists'},
|
@@ -386,6 +389,9 @@ class TestTheory < Test::Unit::TestCase
|
|
386
389
|
4=>1.to_literal,
|
387
390
|
6=>1.to_literal
|
388
391
|
})
|
392
|
+
puts theory.write
|
393
|
+
puts theory.all_theory_variables.length
|
394
|
+
puts theory.map_to(mapping).write
|
389
395
|
assert_equal(
|
390
396
|
0,
|
391
397
|
theory.map_to(mapping).all_theory_variables.length
|
@@ -1,4 +1,8 @@
|
|
1
|
-
|
1
|
+
$LOAD_PATH << File.expand_path('../../../../lib',__FILE__)
|
2
|
+
|
3
|
+
require 'cauldron'
|
4
|
+
|
5
|
+
#require 'required'
|
2
6
|
require 'test/unit'
|
3
7
|
|
4
8
|
class TestTheoryAction < Test::Unit::TestCase
|
@@ -62,6 +66,34 @@ class TestTheoryAction < Test::Unit::TestCase
|
|
62
66
|
)
|
63
67
|
end
|
64
68
|
|
69
|
+
def test_map_to_with_complex_action
|
70
|
+
action = TheoryAction.new(
|
71
|
+
TheoryStatement.new(StringToTheory.run(
|
72
|
+
'OpenStatement.new(If.new,Container.new(var1.params[var3],Equivalent.new,var2[var4][:params][var5]))')
|
73
|
+
),
|
74
|
+
StringToTheory.run('var1.statement_id')
|
75
|
+
)
|
76
|
+
# #<Mapping:0xb7027288
|
77
|
+
# @hash=
|
78
|
+
# {5=>#<TheoryVariable:0xb7027148 @theory_variable_id=2>,
|
79
|
+
# 1=>#<TheoryVariable:0xb7027198 @theory_variable_id=1>,
|
80
|
+
# 2=>#<TheoryVariable:0xb70270f8 @theory_variable_id=3>,
|
81
|
+
# 3=>#<TheoryVariable:0xb70271fc @theory_variable_id=0>,
|
82
|
+
# 4=>#<TheoryVariable:0xb70270a8 @theory_variable_id=4>}>
|
83
|
+
m = Mapping.new({
|
84
|
+
1=>TheoryVariable.new(1),
|
85
|
+
2=>TheoryVariable.new(3),
|
86
|
+
3=>TheoryVariable.new(0),
|
87
|
+
4=>TheoryVariable.new(4),
|
88
|
+
5=>TheoryVariable.new(2)
|
89
|
+
})
|
90
|
+
assert_equal(
|
91
|
+
action.map_to(m).write,
|
92
|
+
"runtime_method.add_statement_at(OpenStatement.new(If.new, Container.new(var1.params[var0], Equivalent.new, var3[var4][:params][var2])),var1.statement_id)"
|
93
|
+
)
|
94
|
+
|
95
|
+
end
|
96
|
+
|
65
97
|
def test_map_to_case_1_theory_1_action
|
66
98
|
action = TheoryAction.new(
|
67
99
|
TheoryStatement.new(StringToTheory.run(
|
@@ -71,10 +103,10 @@ class TestTheoryAction < Test::Unit::TestCase
|
|
71
103
|
StringToTheory.run('var1.statement_id')
|
72
104
|
)
|
73
105
|
mapping = {2=>IntrinsicTestCases.new,3=>Literal.new(0),6=>0.to_literal}
|
74
|
-
assert_equal(
|
75
|
-
"<runtime_method>.add_statement_at(IfStatement.new(<test_cases>[0][:params][0], Equivalent.new, <test_cases>[0][:output]),#{TheoryVariable.variable_colour(1)}var1#{TheoryVariable::NORMAL}.statement_id)",
|
76
|
-
action.map_to(mapping).describe
|
77
|
-
)
|
106
|
+
# assert_equal(
|
107
|
+
# "<runtime_method>.add_statement_at(IfStatement.new(<test_cases>[0][:params][0], Equivalent.new, <test_cases>[0][:output]),#{TheoryVariable.variable_colour(1)}var1#{TheoryVariable::NORMAL}.statement_id)",
|
108
|
+
# action.map_to(mapping).describe
|
109
|
+
# )
|
78
110
|
end
|
79
111
|
|
80
112
|
end
|
@@ -229,7 +229,7 @@ class TestTheoryChainValidator < Test::Unit::TestCase
|
|
229
229
|
last_real_method = Parser.run('last_runtime_method')
|
230
230
|
|
231
231
|
finish = OpenStatement.new(
|
232
|
-
|
232
|
+
Statement.new(If.new,Container.new(InstanceCallContainer.new(real_method,AllPass.new,tc)))
|
233
233
|
)
|
234
234
|
finish << Statement.new(Return.new,True.new)
|
235
235
|
potential_values = MappingValues.new([tc,tc_index_0,tc_index_1,param_0,real_method,last_real_method])
|
@@ -265,7 +265,7 @@ class TestTheoryChainValidator < Test::Unit::TestCase
|
|
265
265
|
real_method = Parser.run('runtime_method')
|
266
266
|
|
267
267
|
finish = OpenStatement.new(
|
268
|
-
|
268
|
+
Statement.new(If.new,Container.new(InstanceCallContainer.new(real_method,Pass.new,ArrayAccess.new(tc,tc_index_0))))
|
269
269
|
)
|
270
270
|
finish << Statement.new(Return.new,True.new)
|
271
271
|
potential_values = MappingValues.new([
|
@@ -310,7 +310,7 @@ class TestTheoryChainValidator < Test::Unit::TestCase
|
|
310
310
|
# real_method = Parser.run('runtime_method')
|
311
311
|
#
|
312
312
|
# finish = OpenStatement.new(
|
313
|
-
#
|
313
|
+
# Statement.new(If.new,Container.new(InstanceCallContainer.new(real_method,Pass.new,ArrayAccess.new(tc,tc_index_0))))
|
314
314
|
# )
|
315
315
|
# finish << Statement.new(Return.new,True.new)
|
316
316
|
# potential_values = MappingValues.new([
|
@@ -273,42 +273,7 @@ class TestTheoryConnector < Test::Unit::TestCase
|
|
273
273
|
initial_chain
|
274
274
|
).any? {|x| x.length > 1 }
|
275
275
|
)
|
276
|
-
|
277
|
-
|
278
|
-
# runtime_method = RuntimeMethod.new(MethodUsage.new(MethodParameter.new))
|
279
|
-
# test_case_1 = CTestCase.new
|
280
|
-
# test_case_1[:params] = ['something']
|
281
|
-
# test_case_1[:output] = 'exists'
|
282
|
-
# test_case_2 = CTestCase.new
|
283
|
-
# test_case_2[:params] = ['my willpower']
|
284
|
-
# test_case_2[:output] = 'does not exist'
|
285
|
-
# test_cases = [
|
286
|
-
# test_case_1,test_case_2
|
287
|
-
# ]
|
288
|
-
#
|
289
|
-
# tc = Parser.run('test_cases')
|
290
|
-
# tc_index_0 = IntrinsicLiteral.new(0)
|
291
|
-
# tc_index_1 = IntrinsicLiteral.new(1)
|
292
|
-
# param_0 = IntrinsicLiteral.new(0)
|
293
|
-
# real_method = Parser.run('runtime_method')
|
294
|
-
# last_real_method = Parser.run('last_runtime_method')
|
295
|
-
#
|
296
|
-
# finish = OpenStatement.new(
|
297
|
-
# IfContainer.new(InstanceCallContainer.new(real_method,AllPass.new,tc))
|
298
|
-
# )
|
299
|
-
# finish << Statement.new(Return.new,True.new)
|
300
|
-
# potential_values = MappingValues.new([tc,tc_index_0,tc_index_1,param_0,real_method,last_real_method])
|
301
|
-
# connector = TheoryConnector.new(potential_values)
|
302
|
-
# assert_equal(
|
303
|
-
# 36,
|
304
|
-
# connector.chain(runtime_method,test_cases,finish,[theory_1,theory_2,theory_3,theory_4]).length
|
305
|
-
# )
|
306
|
-
|
307
|
-
# # DEVELOPMENT - Output each chain to a file
|
308
|
-
# res = connector.chain(runtime_method,test_cases,finish,[theory_1,theory_2,theory_3,theory_4])
|
309
|
-
# res.each_with_index do |x,i|
|
310
|
-
# end
|
311
|
-
|
276
|
+
|
312
277
|
end
|
313
278
|
|
314
279
|
def test_unify_chain_with_a_very_simple_problem
|
@@ -373,7 +338,7 @@ class TestTheoryConnector < Test::Unit::TestCase
|
|
373
338
|
real_method = Parser.run('runtime_method')
|
374
339
|
|
375
340
|
finish = OpenStatement.new(
|
376
|
-
|
341
|
+
Statement.new(If.new,Container.new(InstanceCallContainer.new(real_method,Pass.new,ArrayAccess.new(tc,tc_index_0))))
|
377
342
|
)
|
378
343
|
finish << Statement.new(Return.new,True.new)
|
379
344
|
potential_values = MappingValues.new([
|
@@ -1,3 +1,5 @@
|
|
1
|
+
$LOAD_PATH << File.expand_path('../../../../lib',__FILE__)
|
2
|
+
|
1
3
|
require 'required'
|
2
4
|
require 'test/unit'
|
3
5
|
|
@@ -46,7 +48,7 @@ class TestTheoryResult < Test::Unit::TestCase
|
|
46
48
|
evaluation_code += 'runtime_method.add_statement_at(Statement.new(Return.new, runtime_method.params[0]),runtime_method.statement_id)'+"\n"
|
47
49
|
|
48
50
|
evaluation_code += 'return runtime_method'+"\n"
|
49
|
-
result = CodeEvaluation.new.evaluate_code(evaluation_code)
|
51
|
+
result = CodeEvaluation.new.evaluate_code(evaluation_code)
|
50
52
|
assert(true,implementation.results.all? {|x| x.validates?(result,test_cases)})
|
51
53
|
|
52
54
|
end
|
@@ -68,7 +70,6 @@ class TestTheoryResult < Test::Unit::TestCase
|
|
68
70
|
def test_same_structure_4
|
69
71
|
# TODO Fixtures should include implemented TheoryResult and TheoryResults - I don't like using first
|
70
72
|
theory = Theory.load_theory(4)
|
71
|
-
|
72
73
|
implemented_result = load_implementation_result(0)
|
73
74
|
theory_result = theory.results.first
|
74
75
|
assert_equal(
|
@@ -1,3 +1,5 @@
|
|
1
|
+
$LOAD_PATH << File.expand_path('../../../../lib',__FILE__)
|
2
|
+
|
1
3
|
require 'required'
|
2
4
|
require 'test/unit'
|
3
5
|
|
@@ -19,7 +21,8 @@ class TestMethodValidation < Test::Unit::TestCase
|
|
19
21
|
assert_equal(
|
20
22
|
true,
|
21
23
|
MethodValidation.new.use_runtime_method(
|
22
|
-
validation_test_1,
|
24
|
+
validation_test_1,
|
25
|
+
ParametersContainer.new(RuntimeMethod.new(MethodUsage.new).to_declaration)
|
23
26
|
)
|
24
27
|
)
|
25
28
|
|
data/test/unit/util/tc_parser.rb
CHANGED
@@ -1,7 +1,8 @@
|
|
1
|
+
$LOAD_PATH << File.expand_path('../../../../lib',__FILE__)
|
2
|
+
|
1
3
|
require 'required'
|
2
4
|
require 'test/unit'
|
3
5
|
|
4
|
-
|
5
6
|
class TestStringToTheory < Test::Unit::TestCase
|
6
7
|
|
7
8
|
def setup
|
@@ -92,7 +93,7 @@ class TestStringToTheory < Test::Unit::TestCase
|
|
92
93
|
end
|
93
94
|
|
94
95
|
def test_variable_assignment
|
95
|
-
|
96
|
+
a = StringToTheory.run("var1.length = var2.length")
|
96
97
|
assert_equal(
|
97
98
|
"#{TheoryVariable.variable_colour(1)}var1#{TheoryVariable::NORMAL}.length = #{TheoryVariable.variable_colour(2)}var2#{TheoryVariable::NORMAL}.length",
|
98
99
|
StringToTheory.run("var1.length = var2.length").describe
|
@@ -1,10 +1,13 @@
|
|
1
|
-
class
|
1
|
+
class RuntimeMethodEvaluation3
|
2
2
|
|
3
3
|
#
|
4
|
-
# This is the method that is being evaluated using '
|
4
|
+
# This is the method that is being evaluated using 'RuntimeMethodEvaluation3.new.method_1
|
5
5
|
#
|
6
|
-
def method_1(
|
7
|
-
|
6
|
+
def method_1(var_0)
|
7
|
+
if(var_0 == 'fish')
|
8
|
+
return 'animal'
|
9
|
+
end
|
10
|
+
return 'vegtable'
|
8
11
|
end
|
9
12
|
|
10
13
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cauldron
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 25
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 1
|
10
|
+
version: 0.1.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Warren Sangster
|
@@ -15,9 +15,11 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-
|
18
|
+
date: 2011-07-04 00:00:00 +01:00
|
19
|
+
default_executable: cauldron
|
19
20
|
dependencies:
|
20
21
|
- !ruby/object:Gem::Dependency
|
22
|
+
type: :development
|
21
23
|
version_requirements: &id001 !ruby/object:Gem::Requirement
|
22
24
|
none: false
|
23
25
|
requirements:
|
@@ -27,11 +29,11 @@ dependencies:
|
|
27
29
|
segments:
|
28
30
|
- 0
|
29
31
|
version: "0"
|
30
|
-
type: :development
|
31
32
|
requirement: *id001
|
32
33
|
prerelease: false
|
33
34
|
name: shoulda
|
34
35
|
- !ruby/object:Gem::Dependency
|
36
|
+
type: :development
|
35
37
|
version_requirements: &id002 !ruby/object:Gem::Requirement
|
36
38
|
none: false
|
37
39
|
requirements:
|
@@ -43,11 +45,11 @@ dependencies:
|
|
43
45
|
- 0
|
44
46
|
- 15
|
45
47
|
version: 1.0.15
|
46
|
-
type: :development
|
47
48
|
requirement: *id002
|
48
49
|
prerelease: false
|
49
50
|
name: bundler
|
50
51
|
- !ruby/object:Gem::Dependency
|
52
|
+
type: :development
|
51
53
|
version_requirements: &id003 !ruby/object:Gem::Requirement
|
52
54
|
none: false
|
53
55
|
requirements:
|
@@ -59,11 +61,11 @@ dependencies:
|
|
59
61
|
- 6
|
60
62
|
- 2
|
61
63
|
version: 1.6.2
|
62
|
-
type: :development
|
63
64
|
requirement: *id003
|
64
65
|
prerelease: false
|
65
66
|
name: jeweler
|
66
67
|
- !ruby/object:Gem::Dependency
|
68
|
+
type: :development
|
67
69
|
version_requirements: &id004 !ruby/object:Gem::Requirement
|
68
70
|
none: false
|
69
71
|
requirements:
|
@@ -73,10 +75,41 @@ dependencies:
|
|
73
75
|
segments:
|
74
76
|
- 0
|
75
77
|
version: "0"
|
76
|
-
type: :development
|
77
78
|
requirement: *id004
|
78
79
|
prerelease: false
|
79
80
|
name: rcov
|
81
|
+
- !ruby/object:Gem::Dependency
|
82
|
+
type: :development
|
83
|
+
version_requirements: &id005 !ruby/object:Gem::Requirement
|
84
|
+
none: false
|
85
|
+
requirements:
|
86
|
+
- - ~>
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
hash: 21
|
89
|
+
segments:
|
90
|
+
- 1
|
91
|
+
- 2
|
92
|
+
- 5
|
93
|
+
version: 1.2.5
|
94
|
+
requirement: *id005
|
95
|
+
prerelease: false
|
96
|
+
name: ruby2ruby
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
type: :development
|
99
|
+
version_requirements: &id006 !ruby/object:Gem::Requirement
|
100
|
+
none: false
|
101
|
+
requirements:
|
102
|
+
- - ~>
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
hash: 3
|
105
|
+
segments:
|
106
|
+
- 2
|
107
|
+
- 0
|
108
|
+
- 6
|
109
|
+
version: 2.0.6
|
110
|
+
requirement: *id006
|
111
|
+
prerelease: false
|
112
|
+
name: ruby_parser
|
80
113
|
description: Cauldron generates a methd from a number of examples that describe the input and the expected output. It is still at a very early stage of development right now so you're unlikely to get much practical use out of it.
|
81
114
|
email: warrensangster@yahoo.com
|
82
115
|
executables:
|
@@ -110,6 +143,8 @@ files:
|
|
110
143
|
- features/step_definitions/cauldron_steps.rb
|
111
144
|
- features/step_definitions/terminal_steps.rb
|
112
145
|
- features/support/env.rb
|
146
|
+
- features/support/method_1.example
|
147
|
+
- features/support/method_2.example
|
113
148
|
- lib/Chain.rb
|
114
149
|
- lib/ChainMapping.rb
|
115
150
|
- lib/CodeHandler.rb
|
@@ -120,6 +155,7 @@ files:
|
|
120
155
|
- lib/UnifiedChain.rb
|
121
156
|
- lib/cauldron.rb
|
122
157
|
- lib/cauldron/conversion.rb
|
158
|
+
- lib/cauldron/demos.rb
|
123
159
|
- lib/cauldron/pot.rb
|
124
160
|
- lib/cauldron/sexp2cauldron.rb
|
125
161
|
- lib/cauldron/terminal.rb
|
@@ -234,7 +270,6 @@ files:
|
|
234
270
|
- lib/core/syntax/Do.rb
|
235
271
|
- lib/core/syntax/False.rb
|
236
272
|
- lib/core/syntax/If.rb
|
237
|
-
- lib/core/syntax/IfContainer.rb
|
238
273
|
- lib/core/syntax/Nil.rb
|
239
274
|
- lib/core/syntax/Return.rb
|
240
275
|
- lib/core/syntax/Subtract.rb
|
@@ -315,12 +350,18 @@ files:
|
|
315
350
|
- lib/util/StatementCheck.rb
|
316
351
|
- lib/util/StringToTheory.rb
|
317
352
|
- lib/util/System.rb
|
353
|
+
- spec/cauldron/chain_spec.rb
|
354
|
+
- spec/cauldron/demos_spec.rb
|
318
355
|
- spec/cauldron/pot_spec.rb
|
319
356
|
- spec/cauldron/runtime_method_spec.rb
|
320
357
|
- spec/cauldron/sexp_2_cauldron_spec.rb
|
321
358
|
- spec/cauldron/terminal_spec.rb
|
322
359
|
- spec/cauldron/theory_action_spec.rb
|
360
|
+
- spec/cauldron/theory_connector_spec.rb
|
361
|
+
- spec/cauldron/theory_spec.rb
|
362
|
+
- spec/cauldron/unified_chain_spec.rb
|
323
363
|
- spec/spec_helper.rb
|
364
|
+
- tasks/theory_tasks.rake
|
324
365
|
- test/fixtures/chains/1/declaration.txt
|
325
366
|
- test/fixtures/chains/1/dump
|
326
367
|
- test/fixtures/chains/2/declaration.txt
|
@@ -396,9 +437,11 @@ files:
|
|
396
437
|
- test/fixtures/theory_implementations/0/desc.txt
|
397
438
|
- test/fixtures/theory_implementations/0/dump
|
398
439
|
- test/fixtures/theory_implementations/0/theory_id
|
440
|
+
- test/fixtures/theory_implementations/1/declaration.txt
|
399
441
|
- test/fixtures/theory_implementations/1/desc.txt
|
400
442
|
- test/fixtures/theory_implementations/1/dump
|
401
443
|
- test/fixtures/theory_implementations/1/theory_id
|
444
|
+
- test/fixtures/theory_implementations/2/declaration.txt
|
402
445
|
- test/fixtures/theory_implementations/2/desc.txt
|
403
446
|
- test/fixtures/theory_implementations/2/dump
|
404
447
|
- test/fixtures/theory_implementations/2/theory_id
|
@@ -485,6 +528,7 @@ files:
|
|
485
528
|
- test/unit/util/tc_string_to_theory.rb
|
486
529
|
- test/unit/variable/tc_method_usage_variable.rb
|
487
530
|
- tmp/runtime_method_evaluation.rb
|
531
|
+
has_rdoc: true
|
488
532
|
homepage: http://github.com/theinbetweens/cauldron
|
489
533
|
licenses:
|
490
534
|
- MIT
|
@@ -498,10 +542,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
498
542
|
requirements:
|
499
543
|
- - ">="
|
500
544
|
- !ruby/object:Gem::Version
|
501
|
-
hash:
|
545
|
+
hash: 31
|
502
546
|
segments:
|
503
|
-
-
|
504
|
-
|
547
|
+
- 1
|
548
|
+
- 6
|
549
|
+
- 8
|
550
|
+
version: 1.6.8
|
505
551
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
506
552
|
none: false
|
507
553
|
requirements:
|
@@ -514,7 +560,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
514
560
|
requirements: []
|
515
561
|
|
516
562
|
rubyforge_project:
|
517
|
-
rubygems_version: 1.
|
563
|
+
rubygems_version: 1.4.2
|
518
564
|
signing_key:
|
519
565
|
specification_version: 3
|
520
566
|
summary: Generate simple ruby methods from the input(s) and expected output
|