logicmoo_workspace
logicmoo_workspace copied to clipboard
logicmoo.base.examples.fol.MISSING_COUNT_04 JUnit
(cd /var/lib/jenkins/workspace/logicmoo_workspace@2/packs_sys/logicmoo_base/t/examples/fol ; timeout --foreground --preserve-status -s SIGKILL -k 10s 10s swipl -x /var/lib/jenkins/workspace/logicmoo_workspace/bin/lmoo-clif -t "['missing_count_04.pfc.pl']")
% EDIT: https://github.com/logicmoo/logicmoo_workspace/edit/master/packs_sys/logicmoo_base/t/examples/fol/missing_count_04.pfc.pl % JENKINS: https://jenkins.logicmoo.org/job/logicmoo_workspace/lastBuild/testReport/logicmoo.base.examples.fol/MISSING_COUNT_04/ % ISSUE_SEARCH: https://github.com/logicmoo/logicmoo_workspace/issues?q=is%3Aissue+label%3AMISSING_COUNT_04 % ISSUE: https://github.com/logicmoo/logicmoo_workspace/issues/448
%~ init_phase(after_load)
%~ init_phase(restore_state)
%
%~ init_why(after_boot,program)
%~ after_boot.
%~ Dont forget to ?- logicmoo_i_cyc_xform.
running('/var/lib/jenkins/workspace/logicmoo_workspace@2/packs_sys/logicmoo_base/t/examples/fol/missing_count_04.pfc.pl'),
%~ this_test_might_need( :-( use_module( library(logicmoo_plarkc))))
existing_count(X,G,EC):- findall(X,G,List),length(List,EC).
/*~
~*/
:- debug_logicmoo(_).
/*~
~*/
:- nodebug_logicmoo(http(_)).
/*~
~*/
:- expects_dialect(pfc).
/*~
~*/
house(red_house).
/*~
~*/
house(blue_house).
% house(green_house).
/*~
~*/
% house(green_house).
:- must((existing_count(X,house(X),EC),EC==2)).
/*~
%~ ?-( mpred_test( "Test_0001_Line_0000__house_1",
%~ baseKB : existing_count(X,house(X),EC),EC==2)).
passed=info(why_was_true(baseKB:(existing_count(_496,house(_496),2),2==2)))
no_proof_for((existing_count(House,house(House),2),2==2)).
no_proof_for((existing_count(House,house(House),2),2==2)).
no_proof_for((existing_count(House,house(House),2),2==2)).
name = 'logicmoo.base.examples.fol.MISSING_COUNT_04-Test_0001_Line_0000__house_1'.
JUNIT_CLASSNAME = 'logicmoo.base.examples.fol.MISSING_COUNT_04'.
JUNIT_CMD = 'timeout --foreground --preserve-status -s SIGKILL -k 10s 10s swipl -x /var/lib/jenkins/workspace/logicmoo_workspace/bin/lmoo-clif -t "[\'missing_count_04.pfc.pl\']"'.
% saving_junit: /var/lib/jenkins/workspace/logicmoo_workspace@2/test_results/jenkins/Report-logicmoo-base-examples-fol-vSTARv0vSTARvvDOTvvSTARv-2-1--grep-2-i-WARN-ERROR-_file-00-fail-pass--Units-Logicmoo_base_examples_fol_MISSING_COUNT_04_Test_0001_Line_0000_house_1-junit.xml
~*/
singleValuedInArg(existing_count,1).
/*~
~*/
exists_count(3,X,house(X)).
/*~
~*/
exists_count(N,X,G),{(need_plugs(X,G,EP); EP=0),existing_count(X,G,EC),Need is N-(EC-EP), copy_term(G,GG)}
==>
(need_plugs(Need,X,G),
(\+ GG ==> exists_count(N,X,G)),
( GG ==> exists_count(N,X,G))).
/*~
~*/
need_plugs(EP,X,G) ==> {between(1,EP,Plug),copy_term(G,GG,_),X=skFn(Plug,GG)},G.
/*~
~*/
:- listing(exists_count).
/*~
%~ /var/lib/jenkins/workspace/logicmoo_workspace@2/packs_sys/logicmoo_base/t/examples/fol/missing_count_04.pfc.pl:33
%~ skipped( listing(exists_count))
~*/
:- listing(need_plugs).
/*~
%~ skipped( listing(need_plugs))
~*/
:- listing(house).
/*~
%~ skipped( listing(house))
~*/
/*
exists_count(3, A, house(A)).
need_plugs(1, A, house(A)).
house(red_house).
house(blue_house).
house(skFn(1, house(_))).
*/
:- must((existing_count(X,house(X),EC),EC==3)).
/*~
%~ ?-( mpred_test( "Test_0002_Line_0000__house_1",
%~ baseKB : existing_count(X,house(X),EC),EC==3)).
passed=info(why_was_true(baseKB:(existing_count(_522,house(_522),3),3==3)))
no_proof_for((existing_count(House,house(House),3),3==3)).
no_proof_for((existing_count(House,house(House),3),3==3)).
no_proof_for((existing_count(House,house(House),3),3==3)).
name = 'logicmoo.base.examples.fol.MISSING_COUNT_04-Test_0002_Line_0000__house_1'.
JUNIT_CLASSNAME = 'logicmoo.base.examples.fol.MISSING_COUNT_04'.
JUNIT_CMD = 'timeout --foreground --preserve-status -s SIGKILL -k 10s 10s swipl -x /var/lib/jenkins/workspace/logicmoo_workspace/bin/lmoo-clif -t "[\'missing_count_04.pfc.pl\']"'.
% saving_junit: /var/lib/jenkins/workspace/logicmoo_workspace@2/test_results/jenkins/Report-logicmoo-base-examples-fol-vSTARv0vSTARvvDOTvvSTARv-2-1--grep-2-i-WARN-ERROR-_file-00-fail-pass--Units-Logicmoo_base_examples_fol_MISSING_COUNT_04_Test_0002_Line_0000_house_1-junit.xml
~*/
:- break.
% ISSUE: https://github.com/logicmoo/logicmoo_workspace/issues/448
% EDIT: https://github.com/logicmoo/logicmoo_workspace/edit/master/packs_sys/logicmoo_base/t/examples/fol/missing_count_04.pfc.pl
% JENKINS: https://jenkins.logicmoo.org/job/logicmoo_workspace/lastBuild/testReport/logicmoo.base.examples.fol/MISSING_COUNT_04/
% ISSUE_SEARCH: https://github.com/logicmoo/logicmoo_workspace/issues?q=is%3Aissue+label%3AMISSING_COUNT_04
/*~
%~ skipped(blocks_on_input,break)
~*/
%~ unused(no_junit_results)
Test_0001_Line_0000__house_1 result = passed.
Test_0002_Line_0000__house_1 result = passed.
%~ test_completed_exit(64)
totalTime=1.000
SUCCESS: /var/lib/jenkins/workspace/logicmoo_workspace/bin/lmoo-junit-minor -k missing_count_04.pfc.pl (returned 64) Add_LABELS='' Rem_LABELS='Skipped,Errors,Warnings,Overtime,Skipped,Skipped'
Broken in https://github.com/logicmoo/logicmoo_workspace/commit/47cfb56e12234430e980d22dbcca206411201b38 https://logicmoo.org:2082/gitlab/logicmoo/logicmoo_workspace/-/commit/47cfb56e12234430e980d22dbcca206411201b38
Fixed in https://github.com/logicmoo/logicmoo_workspace/commit/51a38b8a8cc92a39cbea53faf8883a32e6dc3b61 https://logicmoo.org:2082/gitlab/logicmoo/logicmoo_workspace/-/commit/51a38b8a8cc92a39cbea53faf8883a32e6dc3b61
Broken in https://github.com/logicmoo/logicmoo_workspace/commit/157f663e9aafee41e1bef5aa3e17fd16962ab8c7 https://logicmoo.org:2082/gitlab/logicmoo/logicmoo_workspace/-/commit/157f663e9aafee41e1bef5aa3e17fd16962ab8c7
Fixed in https://github.com/logicmoo/logicmoo_workspace/commit/90f5d1e5fc22fb1b2f7fdc46074babc473034f36 https://logicmoo.org:2082/gitlab/logicmoo/logicmoo_workspace/-/commit/90f5d1e5fc22fb1b2f7fdc46074babc473034f36