]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.databoard/testcases/org/simantics/databoard/tests/testFileUtil.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.databoard / testcases / org / simantics / databoard / tests / testFileUtil.java
index 36e47fedccfbdbd8974bf4123b46e8423de04f67..a7c8cb6b4195c03b821b7fe959827b6bdd37e6c6 100644 (file)
@@ -1,23 +1,23 @@
-/*******************************************************************************\r
- *  Copyright (c) 2010 Association for Decentralized Information Management in\r
- *  Industry THTH ry.\r
- *  All rights reserved. This program and the accompanying materials\r
- *  are made available under the terms of the Eclipse Public License v1.0\r
- *  which accompanies this distribution, and is available at\r
- *  http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- *  Contributors:\r
- *      VTT Technical Research Centre of Finland - initial API and implementation\r
- *******************************************************************************/\r
+/*******************************************************************************
+ *  Copyright (c) 2010 Association for Decentralized Information Management in
+ *  Industry THTH ry.
+ *  All rights reserved. This program and the accompanying materials
+ *  are made available under the terms of the Eclipse Public License v1.0
+ *  which accompanies this distribution, and is available at
+ *  http://www.eclipse.org/legal/epl-v10.html
+ *
+ *  Contributors:
+ *      VTT Technical Research Centre of Finland - initial API and implementation
+ *******************************************************************************/
 package org.simantics.databoard.tests;
 
-import java.io.File;\r
-import java.io.IOException;\r
-import java.io.RandomAccessFile;\r
-\r
-import junit.framework.TestCase;\r
-\r
-import org.simantics.databoard.util.binary.BinaryFile;\r
+import java.io.File;
+import java.io.IOException;
+import java.io.RandomAccessFile;
+
+import junit.framework.TestCase;
+
+import org.simantics.databoard.util.binary.BinaryFile;
 
 public class testFileUtil extends TestCase {
 
@@ -46,18 +46,18 @@ public class testFileUtil extends TestCase {
                for (int iter=0; iter<iterCount; iter++) {
                // Verify content
                // 1. half
-               file = new RandomAccessFile(tmp1, "rw");\r
+               file = new RandomAccessFile(tmp1, "rw");
                BinaryFile read = new BinaryFile(file);         
                read.position(0);
                for (int i=0; i<1024*1024; i++)
                        assertEquals(i^0x53, read.readInt());
-               read.close();\r
+               read.close();
                file.close();
                
                // Add 256 kb at 2MB
                System.gc();
                long startTime = System.currentTimeMillis();
-               file = new RandomAccessFile(tmp1, "rw");\r
+               file = new RandomAccessFile(tmp1, "rw");
                BinaryFile.insertBytes(file, 512*1024*4, 256*1024);
                long elapsedTime = System.currentTimeMillis() - startTime;
                totInsertTime += elapsedTime;
@@ -76,11 +76,11 @@ public class testFileUtil extends TestCase {
                read.position(512*1024*4+256*1024);
                for (int i=512*1024; i<1024*1024; i++)
                        assertEquals(i^0x53, read.readInt());
-               read.close();\r
+               read.close();
                file.close();
 
                // Remove content
-               file = new RandomAccessFile(tmp1, "rw");\r
+               file = new RandomAccessFile(tmp1, "rw");
                System.gc();
                startTime = System.currentTimeMillis();
                BinaryFile.removeBytes(file, 512*1024*4, 256*1024);