Skip to content

Commit d234932

Browse files
Update iota cclf pattern to include PRT identifier
1 parent a2f2f5e commit d234932

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

bcda/cclf/parser.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,8 @@ func getCCLFFileMetadata(cmsID, fileName string) (cclfFileMetadata, error) {
160160

161161
// CCLF file name convention for SSP with BCD identifier: P.BCD.A****.ZC[0|8][Y|R]**.Dyymmdd.Thhmmsst
162162
ssp = `A\d{4}`
163-
// CCLF file name convention for IOTA with BCD identifier: P.BCD.IOTA***.ZC(Y|R).Dyymmdd.Thhmmsst
164-
iotaPattern = `IOTA\d{3}`
163+
// CCLF file name convention for IOTA with PRT identifier: P.IOTA***.PRT.ZC[0|8](Y|R).Dyymmdd.Thhmmsst
164+
iotaPrt = `IOTA\d{3}(?:\.PRT)`
165165
// CCLF file name convention for NGACO: P.V***.ACO.ZC[0|8][Y|R].Dyymmdd.Thhmmsst
166166
ngaco = `V\d{3}`
167167
// CCLF file name convention for CEC: P.CEC.ZC[0|8][Y|R].Dyymmdd.Thhmmsst
@@ -179,7 +179,7 @@ func getCCLFFileMetadata(cmsID, fileName string) (cclfFileMetadata, error) {
179179

180180
pattern = prefix + `(` +
181181
bcd + ssp + `|` +
182-
bcd + iotaPattern + `|` +
182+
iotaPrt + `|` +
183183
ngaco + aco + `|` +
184184
cec + `|` +
185185
ckcc + aco + `|` +

bcda/cclf/parser_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ func TestGetCCLFMetadata(t *testing.T) {
199199
const (
200200
sspID, iotaID, cecID, ngacoID, ckccID, kcfID, dcID, testID, sbxID = "A9999", "IOTA965", "E9999", "V999", "C9999", "K9999", "D9999", "TEST999", "SBXBD001"
201201
sspProd, sspTest = "P.BCD." + sspID, "T.BCD." + sspID
202-
iotaProd, iotaTest = "P.BCD." + iotaID, "T.BCD." + iotaID
202+
iotaProd, iotaTest = "P." + iotaID + ".PRT", "T." + iotaID + ".PRT"
203203
cecProd, cecTest = "P.CEC", "T.CEC"
204204
ngacoProd, ngacoTest = "P." + ngacoID + ".ACO", "T." + ngacoID + ".ACO"
205205
ckccProd, ckccTest = "P." + ckccID + ".ACO", "T." + ckccID + ".ACO"

0 commit comments

Comments
 (0)