GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Changing new line delimiters to \\R · biojava/biojava@126f4ec

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • biojava-core/src/test/java/org/biojava/nbio/core
    • alignment/matrices
      • SubstitutionMatrixTest.java
    • sequence/io
      • FastaGeneWriterTest.java
  • biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align
    • FlipAFPChainTest.java
    • fatcat
      • FlipAFPChainTest.java
      • TestOutputStrings.java
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎biojava-core/src/test/java/org/biojava/nbio/core/alignment/matrices/SubstitutionMatrixTest.java‎

Copy file name to clipboardExpand all lines: biojava-core/src/test/java/org/biojava/nbio/core/alignment/matrices/SubstitutionMatrixTest.java
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ void getMatrixReturnsCopy(){
5454
void matrixToString(){
5555
String asString = sm.toString();
5656
// description + 5*2 for ATCGNatcgn + 1 header + 1 for '-'
57-
assertEquals(13, asString.split("\n").length);
58-
String header = asString.split("\r?\n")[1];
57+
assertEquals(13, asString.split("\\n").length);
58+
String header = asString.split("\\R")[1];
5959
assertTrue(header.replaceAll(" ","").matches("[ATCGatcgNn-]+"));
6060
}
6161

@@ -64,8 +64,8 @@ void matrixAsString(){
6464
String asString = sm.getMatrixAsString();
6565

6666
// 5*2 for ATCGNatcgn + 1 header + 1 for '-'
67-
assertEquals(12, asString.split("\n").length);
68-
String header = asString.split("\r?\n")[0];
67+
assertEquals(12, asString.split("\\n").length);
68+
String header = asString.split("\\R")[0];
6969
assertTrue(header.replaceAll(" ","").matches("[ATCGatcgNn-]+"));
7070
}
7171
}
Collapse file

‎biojava-core/src/test/java/org/biojava/nbio/core/sequence/io/FastaGeneWriterTest.java‎

Copy file name to clipboardExpand all lines: biojava-core/src/test/java/org/biojava/nbio/core/sequence/io/FastaGeneWriterTest.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ void basicGeneWriterTest() throws Exception {
5858
fastaWriter.process();
5959

6060
String output = new String(os.toByteArray(), "UTF-8");
61-
String [] lines = output.split("\r?\n");
61+
String [] lines = output.split("\\R");
6262
assertEquals(4,lines.length);
6363
assertEquals(">gene1", lines[0]);
6464
assertEquals("ATATATATATaTATAtatat", lines[1]);
Collapse file

‎biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/FlipAFPChainTest.java‎

Copy file name to clipboardExpand all lines: biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/FlipAFPChainTest.java
+2-3Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -185,10 +185,9 @@ public static void rotateAtoms2(AFPChain afpChain,Atom[] ca2){
185185
}
186186

187187

188-
private static final String newline = System.getProperty("line.separator");
189188
private void printFirstMismatch(String s1, String s2){
190-
String[] spl1 = s1.split(newline);
191-
String[] spl2 = s2.split(newline);
189+
String[] spl1 = s1.split("\\R");
190+
String[] spl2 = s2.split("\\R");
192191

193192
for (int i = 0 ; i < spl1.length ; i++){
194193

Collapse file

‎biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/fatcat/FlipAFPChainTest.java‎

Copy file name to clipboardExpand all lines: biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/fatcat/FlipAFPChainTest.java
+2-3Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,10 +204,9 @@ public static void rotateAtoms2(AFPChain afpChain,Atom[] ca2){
204204
}
205205

206206

207-
static final String newline = System.getProperty("line.separator");
208207
public void printFirstMismatch(String s1, String s2){
209-
String[] spl1 = s1.split(newline);
210-
String[] spl2 = s2.split(newline);
208+
String[] spl1 = s1.split("\\R");
209+
String[] spl2 = s2.split("\\R");
211210

212211
for (int i = 0 ; i < spl1.length ; i++){
213212

Collapse file

‎biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/fatcat/TestOutputStrings.java‎

Copy file name to clipboardExpand all lines: biojava-integrationtest/src/test/java/org/biojava/nbio/structure/test/align/fatcat/TestOutputStrings.java
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ public class TestOutputStrings {
2828
private static final String newline = System.getProperty("line.separator");
2929

3030
public void printFirstMismatch(String s1, String s2){
31-
String[] spl1 = s1.split(newline);
32-
String[] spl2 = s2.split(newline);
31+
String[] spl1 = s1.split("\\R");
32+
String[] spl2 = s2.split("\\R");
3333

3434
for (int i = 0 ; i < spl1.length ; i++){
3535

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.