Skip to content

Commit

Permalink
#2834 remove unnecessary java seq test
Browse files Browse the repository at this point in the history
  • Loading branch information
c71n93 committed Apr 11, 2024
1 parent 64f3f13 commit 8102f21
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 120 deletions.
2 changes: 1 addition & 1 deletion eo-runtime/src/test/eo/org/eolang/seq-tests.eo
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
1

# Test.
[] > seq-single-dataization-int-equal-to-test-bug
[] > seq-single-dataization-int-equal-to-cache-problem-test
(memory 0).alloc > x
eq. > nop
seq
Expand Down
119 changes: 0 additions & 119 deletions eo-runtime/src/test/java/EOorg/EOeolang/EOseqTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -84,123 +84,4 @@ public void calculatesAndReturnsObject() {
Matchers.startsWith("Hello")
);
}

/**
* Test.
*
* [] > parent
* memory 0 > counter
* seq > @
* *
* at.
* * 0 1
* counter.as-int
* counter.write (counter.as-int.plus 1)
* counter.as-int
*
* @since 1.0
*/
@Disabled
@Test
public void calculatesWithTupleAndReturnsObject() {
final Phi counter = new EOmemory(Phi.Φ);
counter.attr(0).put(new Data.ToPhi(0L));
final Phi arr = new PhWith(
new PhWith(
new EOtuple$EOempty(Phi.Φ).attr("with").get().copy(),
0, new Data.ToPhi(0L)
).attr("with").get().copy(),
0, new Data.ToPhi(1L)
);
final Phi get = new PhWith(
new PhCopy(new PhMethod(arr, "at")),
0, new PhMethod(counter, "as-int")
);
final Phi increment = new PhWith(
new PhCopy(new PhMethod(counter, "write")),
0,
new PhWith(
new PhCopy(new PhMethod(new PhMethod(counter, "as-int"), "plus")),
0, new Data.ToPhi(1L)
)
);
final Phi args = new PhWith(
new PhCopy(
new PhMethod(
new PhWith(
new PhCopy(
new PhMethod(
new PhWith(
new PhCopy(
new PhMethod(new EOtuple$EOempty(Phi.Φ), "with")
),
0,
get
),
"with"
)
),
0,
increment
),
"with"
)
),
0, new PhMethod(counter, "as-int")
);
MatcherAssert.assertThat(
new Dataized(
new PhWith(new EOseq(Phi.Φ), 0, args)
).take(Long.class),
Matchers.equalTo(1L)
);
}

/**
* Test.
*
* [] > parent
* memory 0 > counter
* seq > @
* *
* counter.write (counter.as-int.plus 1)
* counter.as-int
*
* @since 1.0
*/
@Disabled
@Test
public void calculatesWithoutTupleAndReturnsObject() {
final Phi counter = new EOmemory(Phi.Φ);
counter.attr(0).put(new Data.ToPhi(0L));
final Phi increment = new PhWith(
new PhCopy(new PhMethod(counter, "write")),
0,
new PhWith(
new PhCopy(new PhMethod(new PhMethod(counter, "as-int"), "plus")),
0, new Data.ToPhi(1L)
)
);
final Phi args = new PhWith(
new PhCopy(
new PhMethod(
new PhWith(
new PhCopy(
new PhMethod(new EOtuple$EOempty(Phi.Φ), "with")
),
0,
increment
),
"with"
)
),
0, new PhMethod(counter, "as-int")
);
MatcherAssert.assertThat(
new Dataized(
new PhWith(new EOseq(Phi.Φ), 0, args)
).take(Long.class),
Matchers.equalTo(1L)
);
}
}

0 comments on commit 8102f21

Please sign in to comment.