Sonar Fixes, Formatting
[aaf/authz.git] / auth / auth-core / src / test / java / org / onap / aaf / auth / local / test / JU_DataFile.java
1 /**
2  * ============LICENSE_START====================================================
3  * org.onap.aaf
4  * ===========================================================================
5  * Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
6  * ===========================================================================
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  * ============LICENSE_END====================================================
19  *
20  */
21
22 package org.onap.aaf.auth.local.test;
23
24 import java.io.File;
25 import java.util.ArrayList;
26 import java.util.List;
27 import static org.junit.Assert.*;
28 import org.junit.AfterClass;
29 import org.junit.Test;
30 import org.onap.aaf.auth.local.DataFile;
31 import org.onap.aaf.auth.local.DataFile.Token;
32 import org.onap.aaf.auth.local.DataFile.Token.Field;
33
34 public class JU_DataFile {
35
36     @AfterClass
37     public static void tearDownAfterClass() throws Exception {
38     }
39
40 //    @Test
41 //    public void netYetTested() {
42 //        fail("Tests not yet implemented");
43 //    }
44
45 //    @Test
46 //    public void test() throws Exception {
47 //        File file = new File("../authz-batch/data/v1.dat");
48 //        DataFile df = new DataFile(file,"r");
49 //        int count = 0;
50 //        List<String> list = new ArrayList<>();
51 //        try {
52 //            df.open();
53 //            Token tok = df.new Token(1024000);
54 //            Field fld = tok.new Field('|');
55 //
56 //            while (tok.nextLine()) {
57 //                ++count;
58 //                fld.reset();
59 //                list.add(fld.at(0));
60 //            }
61 ////            Collections.sort(list);
62 //            for (String s: list) {
63 //                System.out.println(s);
64 //
65 //            }
66 //        } finally {
67 //            System.out.printf("%15s:%12d\n","Total",count);
68 //        }
69 //    }
70
71 }