Cross Reference: theorem_factory.rb
xref
: /
ontohub
/
spec
/
factories
/
theorem_factory.rb
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
FactoryGirl.define
do
factory
:
theorem
do
|
theorem
|
name
{
generate
:
sentence_name
}
text
{
Faker
::
Lorem.sentence
}
proof_status
{
create
:
proof_status_open
}
state
{
'not_started_yet'
}
theorem.after
(:
build
)
do
|
theorem
|
if
!
theorem.ontology
parent_onto
=
create
:
distributed_ontology
, :
with_versioned_children
theorem.ontology
=
parent_onto.children.first
end
end
end
end