File tree 4 files changed +28
-18
lines changed
support/label/relation/skosxl
4 files changed +28
-18
lines changed Original file line number Diff line number Diff line change 1
1
require 'iqvoc/xllabel'
2
+
3
+ if Rails . env . test?
4
+ # FIXME: needed in tests for config.eager_load = true at rails boot
5
+ # move somewhere to test/
6
+ Iqvoc ::Xllabel . relation_class_names = [
7
+ 'Label::Relation::Skosxl::Translation' ,
8
+ 'Label::Relation::Skosxl::UnidirectionalRelation'
9
+ ]
10
+ end
Original file line number Diff line number Diff line change 18
18
19
19
class LabelsRelationTest < ActionDispatch ::IntegrationTest
20
20
21
- # sample bidirectional relation
22
- module Label ::Relation ::Skosxl
23
- class Translation < Label ::Relation ::Skosxl ::Base
24
- def self . bidirectional?
25
- true
26
- end
27
- end
28
-
29
- class UnidirectionalRelation < Label ::Relation ::Skosxl ::Base
30
- end
31
- end
32
-
33
- # add label relation to iqvoc initializer
34
- Iqvoc ::Xllabel . relation_class_names = [
35
- 'Label::Relation::Skosxl::Translation' ,
36
- 'Label::Relation::Skosxl::UnidirectionalRelation'
37
- ]
38
-
39
21
setup do
40
22
@dog_en = Iqvoc ::Xllabel . base_class . create! (
41
23
language : 'en' ,
Original file line number Diff line number Diff line change
1
+ module Label
2
+ module Relation
3
+ module Skosxl
4
+ class Translation < Label ::Relation ::Skosxl ::Base
5
+ def self . bidirectional?
6
+ true
7
+ end
8
+ end
9
+ end
10
+ end
11
+ end
Original file line number Diff line number Diff line change
1
+ module Label
2
+ module Relation
3
+ module Skosxl
4
+ class UnidirectionalRelation < Label ::Relation ::Skosxl ::Base
5
+ end
6
+ end
7
+ end
8
+ end
You can’t perform that action at this time.
0 commit comments