forked from lcnetdev/marc2bibframe2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathConvSpec-3XX.xspec
338 lines (304 loc) · 38.1 KB
/
ConvSpec-3XX.xspec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
<?xml version="1.0" encoding="UTF-8"?>
<x:description xmlns:x="http://www.jenitennison.com/xslt/xspec"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:marc="http://www.loc.gov/MARC21/slim"
xmlns:bf="http://id.loc.gov/ontologies/bibframe/"
xmlns:bflc="http://id.loc.gov/ontologies/bflc/"
xmlns:madsrdf="http://www.loc.gov/mads/rdf/v1#"
stylesheet="../xsl/marc2bibframe2.xsl"
xslt-version="1.0">
<x:scenario label="300 - PHYSICAL DESCRIPTION">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="300 creates an extent property of the Instance" test="count(//bf:Instance[1]/bf:extent) = 2"/>
<x:expect label="$a, $f, $g create the rdfs:label property of the Extent" test="//bf:Instance[1]/bf:extent[1]/bf:Extent/rdfs:label = '1 box 2 x 4 x 3 1/2 ft.'"/>
<x:expect label="$b creates a note property of the Instance" test="//bf:Instance[1]/bf:note[1]/bf:Note/rdfs:label = 'ill.'"/>
<x:expect label="...with rdf:type mnotetype/physical" test="//bf:Instance[1]/bf:note[1]/bf:Note/rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/physical'"/>
<x:expect label="$c creates a dimensions property of the Instance" test="//bf:Instance[1]/bf:dimensions[1] = '21 cm'"/>
<x:expect label="$e creates a note property of the Instance" test="//bf:Instance[1]/bf:note[2]/bf:Note/rdfs:label = '1 answer book'"/>
<x:expect label="...with rdf:type mnotetype/accmat" test="//bf:Instance[1]/bf:note[2]/bf:Note/rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/accmat'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the Extent and the Notes" test="//bf:Instance[1]/bf:extent[1]/bf:Extent/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'records'"/>
</x:scenario>
<x:scenario label="306 - PLAYING TIME">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="Each 306 $a creates a duration property of the Instance" test="//bf:Instance[1]/bf:duration[1] = '002016' and //bf:Instance[1]/bf:duration[2] = '014500'"/>
<x:expect label="...with xs:duration data type" test="//bf:Instance[1]/bf:duration[1]/@rdf:datatype='http://www.w3.org/2001/XMLSchema#duration'"/>
</x:scenario>
<x:scenario label="310 - CURRENT PUBLICATION FREQUENCY">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="310 creates a frequency property of the Instance" test="//bf:Instance[1]/bf:frequency[1]/bf:Frequency/rdfs:label = 'Annual'"/>
<x:expect label=" ... with a bf:status of 'current'" test="//bf:Instance[1]/bf:frequency[1]/bf:Frequency/bf:status[1]/bf:Status/rdfs:label = 'current'"/>
<x:expect label="$b creates a date property of the Frequency" test="//bf:Instance[1]/bf:frequency[1]/bf:Frequency/bf:date = '1983-'"/>
<x:expect label="$2 creates a source property of the Frequency" test="//bf:Instance[1]/bf:frequency[1]/bf:Frequency/bf:source/bf:Source/bf:code='freq'"/>
<x:expect label="$0 can set the URI of the Frequency" test="//bf:Instance[1]/bf:frequency[1]/bf:Frequency/@rdf:about='http://id.loc.gov/vocabulary/frequencies/anl'"/>
</x:scenario>
<x:scenario label="321 - FORMER PUBLICATION FREQ.">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="321 creates a frequency property of the Instance" test="//bf:Instance[1]/bf:frequency[2]/bf:Frequency/rdfs:label = 'Semiannual'"/>
<x:expect label=" ... with a bf:status of 'former'" test="//bf:Instance[1]/bf:frequency[2]/bf:Frequency/bf:status/bf:Status/rdfs:label='former'"/>
<x:expect label="$b creates a date property of the Frequency" test="//bf:Instance[1]/bf:frequency[2]/bf:Frequency/bf:date = '1981-1982'"/>
<x:expect label="$2 creates a source property of the Frequency" test="//bf:Instance[1]/bf:frequency[2]/bf:Frequency/bf:source/bf:Source/bf:code='freq'"/>
<x:expect label="$0 can create an identifier property of the Frequency" test="//bf:Instance[1]/bf:frequency[2]/bf:Frequency/bf:identifiedBy/bf:Identifier/rdf:value='sma'"/>
</x:scenario>
<x:scenario label="f - MODE OF ISSUANCE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="334 creates a content property of the Instance" test="count(//bf:Instance[1]/bf:issuance) = 1"/>
<x:expect label="$a creates an rdfs:label property of the Issuance" test="//bf:Instance[1]/bf:issuance[1]/bf:Issuance/rdfs:label = 'single unit'"/>
<x:expect label="$b creates an rdf:about attribute of the Issuance" test="//bf:Instance[1]/bf:issuance[1]/bf:Issuance/@rdf:about = 'http://id.loc.gov/vocabulary/issuance/mono'"/>
</x:scenario>
<x:scenario label="336 - CONTENT TYPE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="336 creates a content property of the Work" test="count(//bf:Work[1]/bf:content) = 1"/>
<x:expect label="$a creates an rdfs:label property of the Content" test="//bf:Work[1]/bf:content[1]/bf:Content/rdfs:label = 'performed music'"/>
<x:expect label="$b creates an rdf:about attribute of the Content" test="//bf:Work[1]/bf:content[1]/bf:Content/@rdf:about = 'http://id.loc.gov/vocabulary/contentTypes/prm'"/>
<x:expect label="$2 creates a source property of the Content" test="//bf:Work[1]/bf:content[1]/bf:Content/bf:source/bf:Source/@rdf:about = 'http://id.loc.gov/vocabulary/genreFormSchemes/rdacontent'"/>
<x:expect label="$0 used as identifier of the Content" test="//bf:Work[1]/bf:content[1]/bf:Content/@rdf:about = 'http://id.loc.gov/vocabulary/contentTypes/prm'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the Content" test="//bf:Work[1]/bf:content[1]/bf:Content/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'record'"/>
</x:scenario>
<x:scenario label="337 - MEDIA TYPE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="337 creates a media property of the Instance" test="count(//bf:Instance[1]/bf:media) = 1"/>
<x:expect label="$a creates an rdfs:label property of the Media" test="//bf:Instance[1]/bf:media[1]/bf:Media/rdfs:label = 'audio'"/>
<x:expect label="$b creates an rdf:about attribute of the Media" test="//bf:Instance[1]/bf:media[1]/bf:Media/@rdf:about = 'http://id.loc.gov/vocabulary/mediaTypes/s'"/>
<x:expect label="$2 creates a source property of the Media" test="//bf:Instance[1]/bf:media[1]/bf:Media/bf:source/bf:Source/@rdf:about = 'http://id.loc.gov/vocabulary/genreFormSchemes/rdamedia'"/>
<x:expect label="$0 used as identifier of the Media" test="//bf:Instance[1]/bf:media[1]/bf:Media/@rdf:about = 'http://id.loc.gov/vocabulary/mediaTypes/s'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the Media" test="//bf:Instance[1]/bf:media[1]/bf:Media/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'soundtrack'"/>
</x:scenario>
<x:scenario label="338 - CARRIER TYPE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="337 creates a carrier property of the Instance" test="count(//bf:Instance[1]/bf:carrier) = 1"/>
<x:expect label="$a creates an rdfs:label property of the Carrier" test="//bf:Instance[1]/bf:carrier[1]/bf:Carrier/rdfs:label = 'audio disc'"/>
<x:expect label="$b creates an rdf:about attribute of the Carrier" test="//bf:Instance[1]/bf:carrier[1]/bf:Carrier/@rdf:about = 'http://id.loc.gov/vocabulary/carriers/sd'"/>
<x:expect label="$2 creates a source property of the Carrier" test="//bf:Instance[1]/bf:carrier[1]/bf:Carrier/bf:source/bf:Source/@rdf:about = 'http://id.loc.gov/vocabulary/genreFormSchemes/rdacarrier'"/>
<x:expect label="$0 used as identifier of the Carrier" test="//bf:Instance[1]/bf:carrier[1]/bf:Carrier/@rdf:about = 'http://id.loc.gov/vocabulary/carriers/sd'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the Carrier" test="//bf:Instance[1]/bf:carrier[1]/bf:Carrier/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'soundtrack'"/>
</x:scenario>
<x:scenario label="33X URIs">
<x:context mode="mURI33X">
<x:param name="pTag" select="'338'"/>
<x:param name="pCode" select="'b'"/>
<x:param name="pStem" select="'http://id.loc.gov/vocabulary/carriers/'"/>
<marc:record>
<marc:datafield tag="338" ind1=" " ind2=" ">
<marc:subfield code="b">sd</marc:subfield>
<marc:subfield code="2">rdacarrier</marc:subfield>
</marc:datafield>
<marc:datafield tag="338" ind1=" " ind2=" ">
<marc:subfield code="b">vd</marc:subfield>
<marc:subfield code="2">rdacarrier</marc:subfield>
</marc:datafield>
</marc:record>
</x:context>
<x:expect label="mURI template should return list of URIs for matching"
select="'http://id.loc.gov/vocabulary/carriers/sd http://id.loc.gov/vocabulary/carriers/vd'"/>
</x:scenario>
<x:scenario label="340 - PHYSICAL MEDIUM">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a baseMaterial property of the Instance" test="//bf:Instance[1]/bf:baseMaterial[1]/bf:BaseMaterial/rdfs:label = 'rice paper'"/>
<x:expect label="$b creates a dimensions property of the Instance" test="//bf:Instance[1]/bf:dimensions[2] = '7" x 9"'"/>
<x:expect label="$c creates an appliedMaterial property of the Instance" test="//bf:Instance[1]/bf:appliedMaterial[1]/bf:AppliedMaterial/rdfs:label = 'colored inks'"/>
<x:expect label="$d creates a productionMethod property of the Instance" test="//bf:Instance[1]/bf:productionMethod[1]/bf:ProductionMethod/rdfs:label = 'microfilm'"/>
<x:expect label="$e creates a mount property of the Instance" test="//bf:Instance[1]/bf:mount[1]/bf:Mount/rdfs:label = 'none'"/>
<x:expect label="$f creates a reductionRatio value property of the Instance" test="//bf:Instance[1]/bf:reductionRatio[1]/bf:ReductionRatio/rdf:value = '48x'"/>
<x:expect label="$g creates a colorContent property of the Instance" test="//bf:Instance[1]/bf:colorContent[1]/bf:ColorContent/rdfs:label = 'color'"/>
<x:expect label="$i creates a systemRequirement property of the Instance" test="//bf:Instance[1]/bf:systemRequirement[1]/bf:SystemRequirement/rdfs:label = 'Ibord Model 74 tape reader'"/>
<x:expect label="$j creates a generation property of the Instance" test="//bf:Instance[1]/bf:generation[1]/bf:Generation/rdfs:label = 'original'"/>
<x:expect label="$k creates a layout property of the Instance" test="//bf:Instance[1]/bf:layout[1]/bf:Layout/rdfs:label = 'double-sided'"/>
<x:expect label="$l creates a binding property of the Instance" test="//bf:Instance[1]/bf:binding[1]/bf:Binding/rdfs:label = 'saddle stitch binding'"/>
<x:expect label="$m creates a bookFormat property of the Instance" test="//bf:Instance[1]/bf:bookFormat[1]/bf:BookFormat/rdfs:label = 'folio'"/>
<x:expect label="$n creates a fontSize property of the Instance" test="//bf:Instance[1]/bf:fontSize[1]/bf:FontSize/rdfs:label = 'giant print (36 point)'"/>
<x:expect label="$o creates a polarity property of the Instance" test="//bf:Instance[1]/bf:polarity[1]/bf:Polarity/rdfs:label = 'positive'"/>
<x:expect label="$p creates an illustrativeContent property of the Work" test="//bf:Work[1]/bf:illustrativeContent/bf:Illustration/rdfs:label = 'illustrations'"/>
<x:expect label="$q creates a reductionRatio label property of the Instance" test="//bf:Instance[1]/bf:reductionRatio[1]/bf:ReductionRatio/rdf:value = '48x'"/>
<x:expect label="$0 creates an identifiedBy property of the generated object" test="//bf:Instance[1]/bf:colorContent[1]/bf:ColorContent/bf:identifiedBy/bf:Identifier/rdf:value = '123456'"/>
<x:expect label="...or sets the URI of the generated object" test="//bf:Instance[1]/bf:fontSize[1]/bf:FontSize/@rdf:about = 'http://rdaregistry.info/termList/fontSize/1001'"/>
<x:expect label="$2 creates a source property on generated Resources" test="//bf:Instance[1]/bf:generation[1]/bf:Generation/bf:source/bf:Source/bf:code = 'rda'"/>
</x:scenario>
<x:scenario label="341 - ACCESSIBILITY CONTENT">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="341 creates a contentAccessibility property of the Work" test="count(//bf:Work[1]/bf:contentAccessibility) = 4"/>
<x:expect label="$a creates an rdfs:label with prefix 'Content access mode:'" test="//bf:Work[1]/bf:contentAccessibility[1]/bf:ContentAccessibility/rdfs:label[1] = 'Content access mode: auditory'"/>
<x:expect label="$b creates an rdfs:label with prefix 'Textual assistive features:'" test="//bf:Work[1]/bf:contentAccessibility[1]/bf:ContentAccessibility/rdfs:label[2] = 'Textual assistive features: transcript'"/>
<x:expect label="$c creates an rdfs:label with prefix 'Visual assistive features:'" test="//bf:Work[1]/bf:contentAccessibility[2]/bf:ContentAccessibility/rdfs:label[2] = 'Visual assistive features: signLanguage'"/>
<x:expect label="$d creates an rdfs:label with prefix 'Auditory assistive features:'" test="//bf:Work[1]/bf:contentAccessibility[3]/bf:ContentAccessibility/rdfs:label[2] = 'Auditory assistive features: audioDescription'"/>
<x:expect label="$e creates an rdfs:label with prefix 'Tactile assistive features:'" test="//bf:Work[1]/bf:contentAccessibility[4]/bf:ContentAccessibility/rdfs:label[2] = 'Tactile assistive features: braille'"/>
<x:expect label="$2 creates a source property on the ContentAccessibility subject" test="//bf:Work[1]/bf:contentAccessibility[1]/bf:ContentAccessibility/bf:source/bf:Source/bf:code = 'termList'"/>
<x:expect label="$3 creates a bflc:appliesTo property on ContentAccessibility subject" test="//bf:Work[1]/bf:contentAccessibility[1]/bf:ContentAccessibility/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'accompanying audio CD'"/>
</x:scenario>
<x:scenario label="344 - SOUND CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a soundCharacteristic/RecordingMethod property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[1]/bf:RecordingMethod/rdfs:label = 'digital'"/>
<x:expect label="...with an rdf:about attribute if 'analog' or 'digital'" test="//bf:Instance[1]/bf:soundCharacteristic[1]/bf:RecordingMethod/@rdf:about = 'http://id.loc.gov/vocabulary/mrectype/digital'"/>
<x:expect label="$b creates a soundCharacteristic/RecordingMedium property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[2]/bf:RecordingMedium/rdfs:label = 'optical'"/>
<x:expect label="...with an rdf:about attribute if 'magnetic', 'optical', or 'magneto-optical'" test="//bf:Instance[1]/bf:soundCharacteristic[2]/bf:RecordingMedium/@rdf:about = 'http://id.loc.gov/vocabulary/mrecmedium/opt'"/>
<x:expect label="$c creates a soundCharacteristic/PlayingSpeed property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[6]/bf:PlayingSpeed/rdfs:label = '78 rpm'"/>
<x:expect label="$d creates a soundCharacteristic/GrooveCharacteristic property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[7]/bf:GrooveCharacteristic/rdfs:label = 'coarse groove'"/>
<x:expect label="...with an rdf:about attribute if 'coarse groove' or 'microgroove'" test="//bf:Instance[1]/bf:soundCharacteristic[7]/bf:GrooveCharacteristic/@rdf:about = 'http://id.loc.gov/vocabulary/mgroove/coarse'"/>
<x:expect label="$e creates a soundCharacteristic/TrackConfig property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[8]/bf:TrackConfig/rdfs:label = 'edge track'"/>
<x:expect label="$f creates a soundCharacteristic/TapeConfig property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[9]/bf:TapeConfig/rdfs:label = '12 track'"/>
<x:expect label="$g creates a soundCharacteristic/PlaybackChannels property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[3]/bf:PlaybackChannels/rdfs:label = 'surround'"/>
<x:expect label="...with an rdf:about attribute if 'mono', 'quadraphonic', 'stereo', or 'surround'" test="//bf:Instance[1]/bf:soundCharacteristic[3]/bf:PlaybackChannels/@rdf:about = 'http://id.loc.gov/vocabulary/mplayback/mul'"/>
<x:expect label="$h creates a soundCharacteristic/PlaybackCharacteristic property of the Instance" test="//bf:Instance[1]/bf:soundCharacteristic[4]/bf:PlaybackCharacteristic/rdfs:label = 'Dolby'"/>
<x:expect label="...with an rdf:about attribute if recognized value (see specs for details)" test="//bf:Instance[1]/bf:soundCharacteristic[4]/bf:PlaybackCharacteristic/@rdf:about = 'http://id.loc.gov/vocabulary/mspecplayback/dolby'"/>
<x:expect label="$i creates a soundContent/SoundContent property of the Instance" test="//bf:Instance[1]/bf:soundContent/bf:SoundContent/rdfs:label = 'sound'"/>
<x:expect label="...with an rdf:about attribute if 'silent' or 'sound'" test="//bf:Instance[1]/bf:soundContent/bf:SoundContent/@rdf:about = 'http://id.loc.gov/vocabulary/msoundcontent/sound'"/>
<x:expect label="$0 used as identifier of the generated object" test="//bf:Instance[1]/bf:soundCharacteristic[4]/bf:PlaybackCharacteristic/@rdf:about = 'http://id.loc.gov/vocabulary/mspecplayback/dolby'"/>
<x:expect label="$2 creates a source property on generated Resources" test="//bf:Instance[1]/bf:soundCharacteristic[1]/bf:RecordingMethod/bf:source/bf:Source/bf:code = 'rda'"/>
<x:expect label="$3 creates a bflc:appliesTo property on generated Resources" test="//bf:Instance[1]/bf:soundCharacteristic[1]/bf:RecordingMethod/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'audio disc'"/>
<x:expect label="One soundCharacteristic/RecordingMedium property when multiple, equal 344s present" test="count(//bf:Instance[2]/bf:soundCharacteristic/bf:RecordingMedium/rdfs:label[. = 'optical']) = 1"/>
</x:scenario>
<x:scenario label="345 - PROJECTION CHARACTERISTICS OF MOVING IMAGE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a projectionCharacteristic/PresentationFormat property of the Instance" test="//bf:Instance[1]/bf:projectionCharacteristic[1]/bf:PresentationFormat/rdfs:label = 'Cinerama'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:projectionCharacteristic[1]/bf:PresentationFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mpresformat/ciner'"/>
<x:expect label="$b creates a projectionCharacteristic/ProjectionSpeed property of the Instance" test="//bf:Instance[1]/bf:projectionCharacteristic[2]/bf:ProjectionSpeed/rdfs:label = '24 fps'"/>
<x:expect label="$c creates an aspectRatio/AspectRatio/rdf:value property of the Instance" test="//bf:Instance[1]/bf:aspectRatio[1]/bf:AspectRatio/rdf:value = '16:9'"/>
<x:expect label="$d creates an aspectRatio/AspectRatio/rdfs:label property of the Instance" test="//bf:Instance[1]/bf:aspectRatio[2]/bf:AspectRatio/rdfs:label = 'wide screen'"/>
<x:expect label="$0 used as identifier of the generated object" test="//bf:Instance[1]/bf:projectionCharacteristic[1]/bf:PresentationFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mpresformat/ciner'"/>
<x:expect label="$2 creates a source property on generated Resources" test="//bf:Instance[1]/bf:projectionCharacteristic[1]/bf:PresentationFormat/bf:source/bf:Source/bf:code = 'rda'"/>
<x:expect label="$3 creates a bflc:appliesTo property on generated Resources" test="//bf:Instance[1]/bf:projectionCharacteristic[1]/bf:PresentationFormat/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'filmstrip'"/>
</x:scenario>
<x:scenario label="346 - VIDEO CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a videoCharacteristic/VideoFormat property of the Instance" test="//bf:Instance[1]/bf:videoCharacteristic[1]/bf:VideoFormat/rdfs:label = 'Betamax'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:videoCharacteristic[1]/bf:VideoFormat/@rdf:about='http://id.loc.gov/vocabulary/mvidformat/betamax'"/>
<x:expect label="$b creates a videoCharacteristic/BroadcastStandard property of the Instance" test="//bf:Instance[1]/bf:videoCharacteristic[2]/bf:BroadcastStandard/rdfs:label = 'PAL'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:videoCharacteristic[2]/bf:BroadcastStandard/@rdf:about = 'http://id.loc.gov/vocabulary/mbroadstd/pal'"/>
<x:expect label="$0 used as identifier of the generated object" test="//bf:Instance[1]/bf:videoCharacteristic[2]/bf:BroadcastStandard/@rdf:about = 'http://id.loc.gov/vocabulary/mbroadstd/pal'"/>
<x:expect label="$2 creates a source property on generated Resources" test="//bf:Instance[1]/bf:videoCharacteristic[1]/bf:VideoFormat/bf:source/bf:Source/bf:code = 'rda'"/>
<x:expect label="$3 creates a bflc:appliesTo property on generated Resources" test="//bf:Instance[1]/bf:videoCharacteristic[1]/bf:VideoFormat/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'videotape'"/>
</x:scenario>
<x:scenario label="347 - DIGITAL FILE CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a digitalCharacteristic/FileType property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[1]/bf:FileType/rdfs:label = 'image file'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:digitalCharacteristic[1]/bf:FileType/@rdf:about = 'http://id.loc.gov/vocabulary/mfiletype/image'"/>
<x:expect label="$b creates a digitalCharacteristic/EncodingFormat property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[2]/bf:EncodingFormat/rdfs:label = 'Blu-ray video'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:digitalCharacteristic[2]/bf:EncodingFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mencformat/bluray'"/>
<x:expect label="$c creates a digitalCharacteristic/FileSize property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[3]/bf:FileSize/rdfs:label = '182 KB'"/>
<x:expect label="$d creates a digitalCharacteristic/Resolution property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[4]/bf:Resolution/rdfs:label = '3.1 megapixels'"/>
<x:expect label="$e creates a digitalCharacteristic/RegionalEncoding property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[5]/bf:RegionalEncoding/rdfs:label = 'region 4'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:digitalCharacteristic[5]/bf:RegionalEncoding/@rdf:about = 'http://id.loc.gov/vocabulary/mregencoding/region4'"/>
<x:expect label="$f creates a digitalCharacteristic/EncodedBitrate property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[6]/bf:EncodedBitrate/rdfs:label = '32 kbps'"/>
<x:expect label="$0 used as identifier of the generated object" test="//bf:Instance[1]/bf:digitalCharacteristic[2]/bf:EncodingFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mencformat/bluray'"/>
<x:expect label="$2 creates a source property on generated Resources" test="//bf:Instance[1]/bf:digitalCharacteristic[1]/bf:FileType/bf:source/bf:Source/bf:code = 'rda'"/>
<x:expect label="$3 creates a bflc:appliesTo property on generated Resources" test="//bf:Instance[1]/bf:digitalCharacteristic[1]/bf:FileType/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'computer disc'"/>
<x:expect label="$b creates a digitalCharacteristic/EncodingFormat property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[11]/bf:EncodingFormat/rdfs:label = 'cD audoi'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Instance[1]/bf:digitalCharacteristic[12]/bf:EncodingFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mencformat/mp3'"/>
</x:scenario>
<x:scenario label="348 - FORMAT OF NOTATED MUSIC">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="348 creates a musicFormat/MusicFormat property of the Instance" test="count(//bf:Work[1]/bf:musicFormat) = 1"/>
<x:expect label="$a creates an rdfs:label property of the MusicFormat" test="//bf:Work[1]/bf:musicFormat[1]/bf:MusicFormat/rdfs:label = 'vocal score'"/>
<x:expect label="...with an rdf:about attribute if matches string in spec" test="//bf:Work[1]/bf:musicFormat[1]/bf:MusicFormat/@rdf:about = 'http://id.loc.gov/vocabulary/mmusicformat/vocalscore'"/>
<x:expect label="$c creates a notation/Notation property of the Work" test="//bf:Work[1]/bf:notation/bf:MusicNotation/rdfs:label = 'staff notation'"/>
<x:expect label="$0 creates an identifiedBy property of the MusicFormat" test="//bf:Work[1]/bf:musicFormat[1]/bf:MusicFormat/bf:identifiedBy/bf:Identifier/rdf:value = '12345'"/>
<x:expect label="$2 creates a source property of the MusicFormat" test="//bf:Work[1]/bf:musicFormat[1]/bf:MusicFormat/bf:source/bf:Source/bf:code = 'foo'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the MusicFormat" test="//bf:Work[1]/bf:musicFormat[1]/bf:MusicFormat/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'enclosed score'"/>
</x:scenario>
<!--
<x:scenario label="350 - PRICE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="350 creates an acquisitionSource/AcquisitionSource property of the Instance" test="//bf:Instance[1]/bf:acquisitionSource[1]/bf:AcquisitionSource/bf:acquisitionTerms = '$20.00'"/>
</x:scenario>
-->
<x:scenario label="351 - ORGANIZATION AND ARRANGEMENT OF MATERIALS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="351 creates a collectionArrangement/CollectionArrangement property of the Work" test="count(//bf:Work[1]/bf:collectionArrangement/bf:CollectionArrangement) = 1"/>
<x:expect label="$a creates a collectionOrganization property of the CollectionArrangement" test="//bf:Work[1]/bf:collectionArrangement[1]/bf:CollectionArrangement/bf:collectionOrganization = 'Hierarchical'"/>
<x:expect label="$b creates a pattern property of the CollectionArrangement" test="//bf:Work[1]/bf:collectionArrangement[1]/bf:CollectionArrangement/bf:pattern = 'Arranged by form of material'"/>
<x:expect label="$c creates a hierarchicalLevel property of the CollectionArrangement" test="//bf:Work[1]/bf:collectionArrangement[1]/bf:CollectionArrangement/bf:hierarchicalLevel = 'Series'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the CollectionArrangement" test="//bf:Work[1]/bf:collectionArrangement[1]/bf:CollectionArrangement/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'Records'"/>
</x:scenario>
<x:scenario label="352 - DIGITAL GRAPHIC REPRESENTATION">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a digitalCharacteristic/CartographicDataType property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[7]/bf:CartographicDataType/rdfs:label = 'Vector'"/>
<x:expect label="$b creates a digitalCharacteristic/CartographicObjectType property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[9]/bf:CartographicObjectType/rdfs:label = 'Point'"/>
<x:expect label="$c creates a digitalCharacteristic/ObjectCount property of the CartographicObjectType" test="//bf:Instance[1]/bf:digitalCharacteristic[9]/bf:CartographicObjectType/bf:count = '13671'"/>
<x:expect label="$q creates a digitalCharacteristic/EncodingFormat property of the Instance" test="//bf:Instance[1]/bf:digitalCharacteristic[8]/bf:EncodingFormat/rdfs:label = 'ARC/INFO export'"/>
</x:scenario>
<x:scenario label="353 - SUPPLEMENTARY CONTENT CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="353 creates a supplementaryContent/SupplementaryContent property of the Work" test="count(//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent) = 1"/>
<x:expect label="$a creates rdfs:label of SupplementaryContent" test="//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent/rdfs:label = 'biography of creator'"/>
<x:expect label="$b generates URI for SupplementaryContent" test="//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent/@rdf:about = 'http://id.loc.gov/vocabulary/msupplcont/creatorbio'"/>
<!-- <x:expect label="$0 creates an identifiedBy property of the SupplementaryContent" test="//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent/bf:identifiedBy/bf:Identifier/rdf:value/@rdf:resource = 'http://example.com/bio'"/> -->
<!-- <x:expect label="$2 creates a source property of the SupplementaryContent" test="//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent/bf:source/bf:Source/bf:code='msupplcont'"/> -->
<!-- <x:expect label="$3 creates a bflc:appliesTo property of the SupplementaryContent" test="//bf:Work[1]/bf:supplementaryContent/bf:SupplementaryContent/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'Bio supplement'"/> -->
</x:scenario>
<x:scenario label="362 - DATES OF PUBLICATION AND/OR SEQUENTIAL DESIGNATION">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="ind1=0 creates a firstIssue/lastIssue property of the Instance" test="//bf:Instance[1]/bf:firstIssue = 'Vol. 1, no. 1 (Apr. 1983)' and //bf:Instance[1]/bf:lastIssue = 'v. 1, no. 3 (June 1983)'"/>
<x:expect label="ind1=1 creates a note property of the Instance with rdf:type 'http://id.loc.gov/vocabulary/mnotetype/number'" test="//bf:Instance[1]/bf:note/bf:Note[rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/number']/rdfs:label = '3 issues in vol. 1, ceased with 3 (1983)'"/>
</x:scenario>
<x:scenario label="362 - edge cases">
<x:context href="data/ConvSpec-3XX/marc362-edge.xml"/>
<x:expect label="Unformatted dates create a note property" test="//bf:Instance[1]/bf:note[1]/bf:Note[rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/number']/rdfs:label = 'Began in 1989'"/>
<x:expect label="Pre-AACR2 formatting creates a note" test="//bf:Instance[1]/bf:note[2]/bf:Note[rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/number']/rdfs:label = 'no. 1-3; 1975-1977.'"/>
<x:expect label="Parallel statements create multiple firstIssue/lastIssue elements" test="//bf:Instance[1]/bf:firstIssue[1] = 'Vol. 62 (May 1959)' and //bf:Instance[1]/bf:firstIssue[2] = 'No. 768'"/>
<x:expect label="Some dates can't be reliably split, so they create a note" test="//bf:Instance[1]/bf:note[3]/bf:Note[rdf:type/@rdf:resource = 'http://id.loc.gov/vocabulary/mnotetype/number']/rdfs:label = '[Dai 1-gō] (Shōwa 41-nen 12-gatsu [Dec. 1966])'"/>
<x:expect label="But we should be able to parse if there is a ')-' in the string" test="//bf:Instance[1]/bf:firstIssue[3] = 'Vol. 1 (1865-1866)'"/>
<x:expect label="Trailing hyphen creates only firstIssue property" test="//bf:Instance[2]/bf:firstIssue = 'No. 1' and count(//bf:Instance[2]/bf:lastIssue) = 0"/>
<x:expect label="Leading hyphen creates only lastIssue property" test="//bf:Instance[3]/bf:lastIssue = '6th (Sept. 28, 1972).' and count(//bf:Instance[3]/bf:firstIssue) = 0"/>
</x:scenario>
<x:scenario label="370 - ASSOCIATED PLACE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$c creates an originPlace property of the Work" test="//bf:Work[1]/bf:originPlace[1]/bf:Place/rdfs:label='Latvia'"/>
<x:expect label="$g creates an originPlace property of the Work" test="//bf:Work[1]/bf:originPlace[2]/bf:Place/rdfs:label='Riga, Latvia'"/>
<x:expect label="$0 can set the URI of the Place" test="//bf:Work[1]/bf:originPlace[2]/bf:Place/@rdf:about='http://id.loc.gov/authorities/subjects/sh2007010623'"/>
<x:expect label="$2 creates a bf:source property of the Place" test="//bf:Work[1]/bf:originPlace[1]/bf:Place/bf:source/bf:Source/@rdf:about='http://id.loc.gov/vocabulary/subjectSchemes/lcsh'"/>
</x:scenario>
<x:scenario label="377 - ASSOCIATED LANGUAGE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="Each $a creates a language/Language property of the Work with a URI" test="//bf:Work[1]/bf:language[1]/bf:Language/@rdf:about='http://id.loc.gov/vocabulary/languages/eng'"/>
<x:expect label="...unless ind2=7" test="not(//bf:Work/bf:language[3]/bf:Language/@rdf:about) and //bf:Work/bf:language[3]/bf:Language/rdf:value='foo'"/>
<x:expect label="...process $2 if ind2=7" test="//bf:Work/bf:language[3]/bf:Language/bf:source/bf:Source/bf:code='bazz'"/>
<x:expect label="Each $l creates a language/Language property of the Work" test="//bf:Work[1]/bf:language[4]/bf:Language/rdfs:label='foobar'"/>
<x:expect label="$0 can set the URI of the Language" test="//bf:Work[1]/bf:language[4]/bf:Language/@rdf:about = 'http://example.org/languages/foo'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the Language" test="//bf:Work[1]/bf:language[1]/bf:Language/bflc:appliesTo = 'Lecture'"/>
</x:scenario>
<x:scenario label="380 - FORM OF WORK">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="380 creates genreForm properties of the Work" test="//bf:Work[1]/bf:genreForm[1]/bf:GenreForm/rdfs:label = 'Play'"/>
<x:expect label="$2 creates source property with URI from genreFormSchemes" test="//bf:Work[1]/bf:genreForm[1]/bf:GenreForm/bf:source/bf:Source/@rdf:about='http://id.loc.gov/vocabulary/genreFormSchemes/lcgft'"/>
<x:expect label="...and code from $2" test="//bf:Work[1]/bf:genreForm[1]/bf:GenreForm/bf:source/bf:Source/bf:code='lcgft'"/>
</x:scenario>
<x:scenario label="382 - MEDIUM OF PERFORMANCE">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="382 creates a musicMedium/MusicMedium property of the Work" test="count(//bf:Work[1]/bf:musicMedium/bf:MusicMedium) = 1"/>
<x:expect label="If ind1=1, generate status property of the MusicMedium" test="//bf:Work[1]/bf:musicMedium/bf:MusicMedium/bf:status/bf:Status/@rdf:about = 'http://id.loc.gov/vocabulary/mstatus/part'"/>
<x:expect label="Generate bflc:readMarc382 property of the MusicMedium from all subfields" test="//bf:Work[1]/bf:musicMedium/bf:MusicMedium/bflc:readMarc382 = '3821 $3Nach Bach$apiano$n1$vplayed on altered piano$pbaritone horn$n2$dsynthesizer$n1$s2$vpiano is prominent, but not all other instruments are not identified$2lcmpt'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the MusicMedium" test="//bf:Work[1]/bf:musicMedium[1]/bf:MusicMedium/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'Nach Bach'"/>
</x:scenario>
<x:scenario label="383 - NUMERIC DESIGNATION OF MUSICAL WORK">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a musicSerialNumber property of the Work" test="//bf:Work[1]/bf:musicSerialNumber[1] = 'no. 14'"/>
<x:expect label="$b creates a musicOpusNumber property of the Work" test="//bf:Work[1]/bf:musicOpusNumber[1] = 'op. 27, no. 2'"/>
<x:expect label="Each $c concatenated with $d creates a musicThematicNumber property of the Work" test="//bf:Work[1]/bf:musicThematicNumber = 'F. I, 22-25 Fanna'"/>
</x:scenario>
<x:scenario label="384 - KEY">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a musicKey property of the Work" test="//bf:Work[1]/bf:musicKey = 'B minor'"/>
</x:scenario>
<x:scenario label="385 - AUDIENCE CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates an intendedAudience property of the Work" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/rdfs:label = 'Children'"/>
<x:expect label="$b creates a code property of the IntendedAudience..." test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bf:code = 'kid'"/>
<x:expect label="If there is a $0 with a standard number value starting with 'dg', it becomes the URI of the IntendedAudience" test="//bf:Work[1]/bf:intendedAudience[2]/bf:IntendedAudience/@rdf:about = 'http://id.loc.gov/authorities/demographicTerms/dg2015060010'"/>
<x:expect label="$m creates a bflc:demographicGroup property of the IntendedAudience" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bflc:demographicGroup/bflc:DemographicGroup/rdfs:label = 'Age group'"/>
<x:expect label="$n sets the URI of the DemographicGroup" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bflc:demographicGroup/bflc:DemographicGroup/@rdf:about = 'http://id.loc.gov/authorities/demographicTerms/age'"/>
<x:expect label="$2 creates a source property of the IntendedAudience" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bf:source/bf:Source/bf:code = 'ws'"/>
<x:expect label="...with URI from subjectSchemes" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bf:source/bf:Source/@rdf:about='http://id.loc.gov/vocabulary/subjectSchemes/ws'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the IntendedAudience" test="//bf:Work[1]/bf:intendedAudience[1]/bf:IntendedAudience/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'Nonsense'"/>
</x:scenario>
<x:scenario label="386 - CREATOR/CONTRIBUTOR CHARACTERISTICS">
<x:context href="data/ConvSpec-3XX/marc.xml"/>
<x:expect label="$a creates a bflc:creatorCharacteristic property of the Work" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/rdfs:label = 'Females'"/>
<x:expect label="$b creates a code property of the CreatorCharacteristic" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bf:code='f'"/>
<x:expect label="If there is a $0 with a standard number value starting with 'dg', it becomes the URI of the CreatorCharacteristic" test="//bf:Work[1]/bflc:creatorCharacteristic[2]/bflc:CreatorCharacteristic/@rdf:about = 'http://id.loc.gov/authorities/demographicTerms/dg2015060010'"/>
<x:expect label="$m creates a bflc:demographicGroup property of the CreatorCharacteristic" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bflc:demographicGroup/bflc:DemographicGroup/rdfs:label = 'Gender group'"/>
<x:expect label="$n sets the URI of the DemographicGroup" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bflc:demographicGroup/bflc:DemographicGroup/@rdf:about = 'http://id.loc.gov/authorities/demographicTerms/gen'"/>
<x:expect label="$2 creates a source property of the CreatorCharacteristic" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bf:source/bf:Source/bf:code = 'ericd'"/>
<x:expect label="...with URI from subjectSchemes" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bf:source/bf:Source/@rdf:about = 'http://id.loc.gov/vocabulary/subjectSchemes/ericd'"/>
<x:expect label="$3 creates a bflc:appliesTo property of the CreatorCharacteristic" test="//bf:Work[1]/bflc:creatorCharacteristic[1]/bflc:CreatorCharacteristic/bflc:appliesTo/bflc:AppliesTo/rdfs:label = 'Other stuff'"/>
</x:scenario>
</x:description>