Skip to content

Commit

Permalink
test: move test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
jpedroh committed Mar 12, 2024
1 parent 68eec68 commit 9d2109d
Show file tree
Hide file tree
Showing 8 changed files with 96 additions and 2,563 deletions.
31 changes: 31 additions & 0 deletions bin/tests/scenarios/fancy_argument_types_matching_issue/base.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
package de.fosd.jdime.common;

import AST.*;

public class ASTNodeArtifact extends Artifact<ASTNodeArtifact> {
private ASTNodeArtifact(final ASTNode<?> astnode) {
assert (astnode != null);
this.astnode = astnode;

this.initializeChildren();
}

public ASTNodeArtifact(final FileArtifact artifact) {
assert (artifact != null);

setRevision(artifact.getRevision());

ASTNode<?> astnode;
if (artifact.isEmpty()) {
astnode = new ASTNode<>();
} else {
Program p = initProgram();
p.addSourceFile(artifact.getPath());
astnode = p;
}

this.astnode = astnode;
this.initializeChildren();
renumberTree();
}
}
32 changes: 32 additions & 0 deletions bin/tests/scenarios/fancy_argument_types_matching_issue/left.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
package de.fosd.jdime.common;

import AST.*;
import de.fosd.jdime.common.operations.ConflictOperation;

public class ASTNodeArtifact extends Artifact<ASTNodeArtifact> {
private ASTNodeArtifact(final ASTNode<?> astnode) {
assert (astnode != null);
this.astnode = astnode;

this.initializeChildren();
}

public ASTNodeArtifact(final FileArtifact artifact) {
assert (artifact != null);

setRevision(artifact.getRevision());

ASTNode<?> astnode;
if (artifact.isEmpty()) {
astnode = new ASTNode<>();
} else {
Program p = initProgram();
p.addSourceFile(artifact.getPath());
astnode = p;
}

this.astnode = astnode;
this.initializeChildren();
renumberTree();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
package de . fosd . jdime . common ; import de . fosd . jdime . common . operations . AddOperation ; import AST . * ; import de . fosd . jdime . common . operations . ConflictOperation ; public class ASTNodeArtifact extends Artifact < ASTNodeArtifact > { private ASTNodeArtifact ( final ASTNode < ? > astnode ) { assert ( astnode != null ) ; this . astnode = astnode ; this . initializeChildren ( ) ; } public ASTNodeArtifact ( final FileArtifact artifact ) { assert ( artifact != null ) ; setRevision ( artifact . getRevision ( ) ) ; ASTNode < ? > astnode ; if ( artifact . isEmpty ( ) ) { astnode = new ASTNode < > ( ) ; } else { Program p = initProgram ( ) ; p . addSourceFile ( artifact . getPath ( ) ) ; astnode = p ; } this . astnode = astnode ; this . initializeChildren ( ) ; renumberTree ( ) ; } }
32 changes: 32 additions & 0 deletions bin/tests/scenarios/fancy_argument_types_matching_issue/right.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
package de.fosd.jdime.common;

import de.fosd.jdime.common.operations.AddOperation;
import AST.*;

public class ASTNodeArtifact extends Artifact<ASTNodeArtifact> {
private ASTNodeArtifact(final ASTNode<?> astnode) {
assert (astnode != null);
this.astnode = astnode;

this.initializeChildren();
}

public ASTNodeArtifact(final FileArtifact artifact) {
assert (artifact != null);

setRevision(artifact.getRevision());

ASTNode<?> astnode;
if (artifact.isEmpty()) {
astnode = new ASTNode<>();
} else {
Program p = initProgram();
p.addSourceFile(artifact.getPath());
astnode = p;
}

this.astnode = astnode;
this.initializeChildren();
renumberTree();
}
}
Loading

0 comments on commit 9d2109d

Please sign in to comment.