Search in sources :

Example 86 with TestNAR

use of nars.test.TestNAR in project narchy by automenta.

the class NAL8EternalMixTest method goal_deduction_tensed_conseq.

@Test
public void goal_deduction_tensed_conseq() {
    TestNAR tester = test;
    tester.input("goto(x). :|:");
    tester.inputAt(10, "(goto($1) ==>+5 at(SELF,$1)).");
    tester.mustBelieve(cycles, "at(SELF,x)", 1.0f, 0.81f, 5);
}
Also used : TestNAR(nars.test.TestNAR) Test(org.junit.jupiter.api.Test) NAL7Test(nars.nal.nal7.NAL7Test) NALTest(nars.util.NALTest)

Example 87 with TestNAR

use of nars.test.TestNAR in project narchy by automenta.

the class NAL8EternalMixTest method goal_deduction_impl.

@Test
public void goal_deduction_impl() {
    TestNAR tester = test;
    tester.input("x:y! :|:");
    tester.input("(goto(z) ==>+5 x:y).");
    tester.mustGoal(cycles, "goto(z)", 1.0f, 0.45f, (t) -> t >= 0);
}
Also used : TestNAR(nars.test.TestNAR) Test(org.junit.jupiter.api.Test) NAL7Test(nars.nal.nal7.NAL7Test) NALTest(nars.util.NALTest)

Example 88 with TestNAR

use of nars.test.TestNAR in project narchy by automenta.

the class NAL8EternalMixTest method goal_ded_2.

@Test
public void goal_ded_2() {
    TestNAR tester = test;
    tester.inputAt(0, "at(SELF,{t001}). :|:");
    tester.inputAt(0, "(at(SELF,{t001}) &&+5 open({t001}))!");
    tester.mustGoal(cycles, "open({t001})", 1.0f, 0.43f, 5);
}
Also used : TestNAR(nars.test.TestNAR) Test(org.junit.jupiter.api.Test) NAL7Test(nars.nal.nal7.NAL7Test) NALTest(nars.util.NALTest)

Example 89 with TestNAR

use of nars.test.TestNAR in project narchy by automenta.

the class NAL8EternalMixTest method ded_with_var_temporal2.

@Test
public void ded_with_var_temporal2() {
    TestNAR tester = test;
    tester.input("goto({t003}). :|: ");
    tester.inputAt(10, "(goto($1) ==>+5 at(SELF,$1)). ");
    tester.mustBelieve(cycles, "at(SELF,{t003})", 1.0f, 0.81f, 5);
}
Also used : TestNAR(nars.test.TestNAR) Test(org.junit.jupiter.api.Test) NAL7Test(nars.nal.nal7.NAL7Test) NALTest(nars.util.NALTest)

Example 90 with TestNAR

use of nars.test.TestNAR in project narchy by automenta.

the class NAL8EternalMixTest method conditional_abduction_temporal_vs_eternal.

@Test
public void conditional_abduction_temporal_vs_eternal() {
    // maybe to nal7 lets see how we will split these in the future
    TestNAR tester = test;
    tester.input("at(SELF,{t003}). :|:");
    tester.inputAt(10, "(goto($1) ==>+5 at(SELF,$1)).");
    tester.mustBelieve(cycles, "goto({t003})", 1.0f, 0.45f, -5);
}
Also used : TestNAR(nars.test.TestNAR) Test(org.junit.jupiter.api.Test) NAL7Test(nars.nal.nal7.NAL7Test) NALTest(nars.util.NALTest)

Aggregations

TestNAR (nars.test.TestNAR)178 Test (org.junit.jupiter.api.Test)169 NALTest (nars.util.NALTest)162 NAL7Test (nars.nal.nal7.NAL7Test)18 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)11 Disabled (org.junit.jupiter.api.Disabled)5 NAR (nars.NAR)2 Concept (nars.concept.Concept)2 DoubleSummaryStatistics (java.util.DoubleSummaryStatistics)1 AtomicInteger (java.util.concurrent.atomic.AtomicInteger)1 BiFunction (java.util.function.BiFunction)1 IntFunction (java.util.function.IntFunction)1 nars (nars)1 NARS (nars.NARS)1 TaskStatistics (nars.task.util.TaskStatistics)1 Term (nars.term.Term)1 DeductiveMeshTest (nars.test.DeductiveMeshTest)1 ETERNAL (nars.time.Tense.ETERNAL)1 NotNull (org.jetbrains.annotations.NotNull)1 Assertions.assertNotEquals (org.junit.jupiter.api.Assertions.assertNotEquals)1