@@ -29,53 +29,40 @@ def negative_graph_match_test():
29
29
"""Test of FRIR identifiers against tricky RDF graphs with blank nodes."""
30
30
testInputs = [ # noqa: N806
31
31
[
32
- str (
33
- """@prefix : <http://example.org/ns#> .
32
+ """@prefix : <http://example.org/ns#> .
34
33
<http://example.org> :rel
35
34
[ :label "Same" ].
36
- """
37
- ),
38
- str (
39
- """@prefix : <http://example.org/ns#> .
35
+ """ ,
36
+ """@prefix : <http://example.org/ns#> .
40
37
<http://example.org> :rel
41
38
[ :label "Same" ],
42
39
[ :label "Same" ].
43
- """
44
- ),
40
+ """ ,
45
41
False ,
46
42
],
47
43
[
48
- str (
49
- """@prefix : <http://example.org/ns#> .
44
+ """@prefix : <http://example.org/ns#> .
50
45
<http://example.org> :rel
51
46
<http://example.org/a>.
52
- """
53
- ),
54
- str (
55
- """@prefix : <http://example.org/ns#> .
47
+ """ ,
48
+ """@prefix : <http://example.org/ns#> .
56
49
<http://example.org> :rel
57
50
<http://example.org/a>,
58
51
<http://example.org/a>.
59
- """
60
- ),
52
+ """ ,
61
53
True ,
62
54
],
63
55
[
64
- str (
65
- """@prefix : <http://example.org/ns#> .
56
+ """@prefix : <http://example.org/ns#> .
66
57
:linear_two_step_symmetry_start :related [ :related [ :related :linear_two_step_symmatry_end]],
67
- [ :related [ :related :linear_two_step_symmatry_end]]."""
68
- ),
69
- str (
70
- """@prefix : <http://example.org/ns#> .
58
+ [ :related [ :related :linear_two_step_symmatry_end]].""" ,
59
+ """@prefix : <http://example.org/ns#> .
71
60
:linear_two_step_symmetry_start :related [ :related [ :related :linear_two_step_symmatry_end]],
72
- [ :related [ :related :linear_two_step_symmatry_end]]."""
73
- ),
61
+ [ :related [ :related :linear_two_step_symmatry_end]].""" ,
74
62
True ,
75
63
],
76
64
[
77
- str (
78
- """@prefix : <http://example.org/ns#> .
65
+ """@prefix : <http://example.org/ns#> .
79
66
_:a :rel [
80
67
:rel [
81
68
:rel [
@@ -84,10 +71,8 @@ def negative_graph_match_test():
84
71
];
85
72
];
86
73
];
87
- ]."""
88
- ),
89
- str (
90
- """@prefix : <http://example.org/ns#> .
74
+ ].""" ,
75
+ """@prefix : <http://example.org/ns#> .
91
76
_:a :rel [
92
77
:rel [
93
78
:rel [
@@ -98,14 +83,12 @@ def negative_graph_match_test():
98
83
];
99
84
];
100
85
];
101
- ]."""
102
- ),
86
+ ].""" ,
103
87
False ,
104
88
],
105
89
# This test fails because the algorithm purposefully breaks the symmetry of symetric
106
90
[
107
- str (
108
- """@prefix : <http://example.org/ns#> .
91
+ """@prefix : <http://example.org/ns#> .
109
92
_:a :rel [
110
93
:rel [
111
94
:rel [
@@ -114,10 +97,8 @@ def negative_graph_match_test():
114
97
];
115
98
];
116
99
];
117
- ]."""
118
- ),
119
- str (
120
- """@prefix : <http://example.org/ns#> .
100
+ ].""" ,
101
+ """@prefix : <http://example.org/ns#> .
121
102
_:a :rel [
122
103
:rel [
123
104
:rel [
@@ -126,13 +107,11 @@ def negative_graph_match_test():
126
107
];
127
108
];
128
109
];
129
- ]."""
130
- ),
110
+ ].""" ,
131
111
True ,
132
112
],
133
113
[
134
- str (
135
- """@prefix : <http://example.org/ns#> .
114
+ """@prefix : <http://example.org/ns#> .
136
115
_:a :rel [
137
116
:rel [
138
117
:label "foo";
@@ -142,10 +121,8 @@ def negative_graph_match_test():
142
121
];
143
122
];
144
123
];
145
- ]."""
146
- ),
147
- str (
148
- """@prefix : <http://example.org/ns#> .
124
+ ].""" ,
125
+ """@prefix : <http://example.org/ns#> .
149
126
_:a :rel [
150
127
:rel [
151
128
:rel [
@@ -154,13 +131,11 @@ def negative_graph_match_test():
154
131
];
155
132
];
156
133
];
157
- ]."""
158
- ),
134
+ ].""" ,
159
135
False ,
160
136
],
161
137
[
162
- str (
163
- """@prefix : <http://example.org/ns#> .
138
+ """@prefix : <http://example.org/ns#> .
164
139
_:0001 :rel _:0003, _:0004.
165
140
_:0002 :rel _:0005, _:0006.
166
141
_:0003 :rel _:0001, _:0007, _:0010.
@@ -171,10 +146,8 @@ def negative_graph_match_test():
171
146
_:0008 :rel _:0004, _:0006, _:0010.
172
147
_:0009 :rel _:0004, _:0005, _:0007.
173
148
_:0010 :rel _:0003, _:0006, _:0008.
174
- """
175
- ),
176
- str (
177
- """@prefix : <http://example.org/ns#> .
149
+ """ ,
150
+ """@prefix : <http://example.org/ns#> .
178
151
_:0001 :rel _:0003, _:0004.
179
152
_:0002 :rel _:0005, _:0006.
180
153
_:0003 :rel _:0001, _:0007, _:0010.
@@ -185,8 +158,7 @@ def negative_graph_match_test():
185
158
_:0005 :rel _:0002, _:0007, _:0009.
186
159
_:0006 :rel _:0002, _:0008, _:0010.
187
160
_:0007 :rel _:0003, _:0005, _:0009.
188
- """
189
- ),
161
+ """ ,
190
162
True ,
191
163
],
192
164
]
0 commit comments