[JBoss JIRA] (DROOLS-1994) Test Scenarios: Problems setting fields of global facts
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1994?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-1181 to DROOLS-1994:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1994 (was: GUVNOR-1181)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 5.5.0.Final
(was: drools-5.1)
> Test Scenarios: Problems setting fields of global facts
> --------------------------------------------------------
>
> Key: DROOLS-1994
> URL: https://issues.jboss.org/browse/DROOLS-1994
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 5.5.0.Final
> Environment: Fedora 12, JDK 1.6 Sun/Oracle, BRMS 5.1, Firefox 3.5.6
> Reporter: Alessandro Lazarotti
> Assignee: Toni Rikkola
> Priority: Critical
>
> When in test scenario is clicked on global and selected a complex type, it is displayed the button "Add Field". However selecting the field from the dropdown and clicked on 'OK', the field is added in the background and the popup doesn't close (you are forced to click on X). Additionally is not possible set any value for the field inserted.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1995) Test Scenarios: Warning for non existent ksession does not disappear when an existing ksession is selected
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1995?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-2716 to DROOLS-1995:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1995 (was: GUVNOR-2716)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
> Test Scenarios: Warning for non existent ksession does not disappear when an existing ksession is selected
> ----------------------------------------------------------------------------------------------------------
>
> Key: DROOLS-1995
> URL: https://issues.jboss.org/browse/DROOLS-1995
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Reporter: Toni Rikkola
> Priority: Minor
>
> # Make two ksessions:
> ## KSessionOne
> ## KSessionRemoveMe
> # Both need to stateful with a pseudo clock.
> # Make a Test scenario. Use KSessionRemoveMe in the test scenario.
> # Save and close the test scenario.
> # Remove KSessionRemoveMe.
> # Reopen the test scenario. You see a warning "KSession does not exist"
> # Select KSessionOne
> The error message should disappear.
> Instead it still shows.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1996) Test Scenario Indexing broken
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1996?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-2451 to DROOLS-1996:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1996 (was: GUVNOR-2451)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 6.4.0.Beta2
(was: drools_6.4.0.Beta2)
> Test Scenario Indexing broken
> -----------------------------
>
> Key: DROOLS-1996
> URL: https://issues.jboss.org/browse/DROOLS-1996
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 6.4.0.Beta2
> Reporter: Michael Anstis
> Assignee: Guilherme Carreiro
>
> I built kie-drools-wb locally and ran on EAP6.4 (with .niogit and .index deleted).
> The start log contains (lots) of these type of error (probably one for each Test Scenario):-
> {code}
> 16:05:21,732 ERROR [org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioFileIndexer] (EJB default - 7) Unable to index 'default://master@uf-playground/mortgages/src/test/resources/org/mortgages/Pricing%20low%20end.scenario'.: java.lang.NullPointerException
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioIndexVisitor.getFieldFullyQualifiedClassName(TestScenarioIndexVisitor.java:158) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioIndexVisitor.visit(TestScenarioIndexVisitor.java:105) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioIndexVisitor.visit(TestScenarioIndexVisitor.java:79) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioIndexVisitor.visit(TestScenarioIndexVisitor.java:74) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioIndexVisitor.visit(TestScenarioIndexVisitor.java:68) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> at org.drools.workbench.screens.testscenario.backend.server.indexing.TestScenarioFileIndexer.toKObject(TestScenarioFileIndexer.java:81) [drools-wb-test-scenario-editor-backend-6.4.0-SNAPSHOT.jar:6.4.0-SNAPSHOT]
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1984) Test Scenario Editor does not remove inserted facts
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1984?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-1589 to DROOLS-1984:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1984 (was: GUVNOR-1589)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 5.5.0.Final
(was: drools-5.2.0.Final)
> Test Scenario Editor does not remove inserted facts
> ---------------------------------------------------
>
> Key: DROOLS-1984
> URL: https://issues.jboss.org/browse/DROOLS-1984
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 5.5.0.Final
> Reporter: Jaroslaw Kijanowski
> Assignee: Toni Rikkola
>
> I have a declarative model (Person.sex, Policy.value) and a rule:
> rule "r2"
> dialect "mvel"
> when
> Person( sex == "male" )
> then
> Policy fact0 = new Policy();
> fact0.setValue( 100 );
> insert(fact0 );
> end
> The test is:
> insert Person(sex=male)
> expect Policy(value=100)
> Now I go to the QA section and click on "Run all scenarios" - test passed, cool.
> I change the test and set sex to female, go to the QA section and run all scenarios - test failed, cool.
> However if I go to the test scenario editor and run the test from there, I get a false positive:
> - the first time I run the test, it tells me that the test failed, cool
> - I change sex to male and the test passes
> - I change sex to female and the test passes which is bad ;) (however telling me that no rules fired)
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1985) Test Scenario fails to populate Date field
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1985?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-2061 to DROOLS-1985:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1985 (was: GUVNOR-2061)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 5.5.0.Final
(was: drools-5.5.0.Final)
> Test Scenario fails to populate Date field
> ------------------------------------------
>
> Key: DROOLS-1985
> URL: https://issues.jboss.org/browse/DROOLS-1985
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 5.5.0.Final
> Reporter: Toshiya Kobayashi
> Assignee: Mark Coble
> Attachments: repository_export_mvel_date.zip
>
>
> Under the conditions:
> - Model A has a Date field
> - Model B extends Model A
> - All rules have "java" dialect
> When you set a value to the Date field of Model B in a Test Scenario, the Test scenario fails to run and throws the Exception.
> {noformat}
> 20:59:23,323 INFO [stdout] (http--127.0.0.1-8080-1) ERROR 14-11 20:59:23,322 (LoggingHelper.java:error:74) Unable to run the scenario.
> 20:59:23,323 INFO [stdout] (http--127.0.0.1-8080-1) [Error: could not access/write property (dateTime) in: defaultPackage.SubModel]
> 20:59:23,323 INFO [stdout] (http--127.0.0.1-8080-1) [Near : {... __fact__.dateTime= __val__ ....}]
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) ^
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) [Line: 1, Column: 1]
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.PropertyAccessor.set(PropertyAccessor.java:372)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.PropertyAccessor.set(PropertyAccessor.java:139)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.ast.DeepAssignmentNode.getReducedValue(DeepAssignmentNode.java:97)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.MVELInterpretedRuntime.parseAndExecuteInterpreted(MVELInterpretedRuntime.java:106)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.MVELInterpretedRuntime.parse(MVELInterpretedRuntime.java:49)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.mvel2.MVEL.eval(MVEL.java:165)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.ide.common.server.testscenarios.populators.FieldPopulator.populateField(FieldPopulator.java:47)
> 20:59:23,324 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.ide.common.server.testscenarios.populators.SimpleFieldPopulator.populate(SimpleFieldPopulator.java:35)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.ide.common.server.testscenarios.populators.FactPopulator.populate(FactPopulator.java:52)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.ide.common.server.testscenarios.ScenarioRunner.applyFixtures(ScenarioRunner.java:119)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.ide.common.server.testscenarios.ScenarioRunner.run(ScenarioRunner.java:82)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.guvnor.server.TestScenarioServiceImplementation.runScenario(TestScenarioServiceImplementation.java:160)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.guvnor.server.TestScenarioServiceImplementation.runScenario(TestScenarioServiceImplementation.java:111)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.guvnor.server.TestScenarioServiceImplementation.runScenario(TestScenarioServiceImplementation.java:101)
> 20:59:23,325 INFO [stdout] (http--127.0.0.1-8080-1) at org.drools.guvnor.server.TestScenarioServiceServlet.runScenario(TestScenarioServiceServlet.java:39)
> {noformat}
> This is because org.drools.ide.common.server.testscenarios.populators.FieldPopulatorFactory.isDate() uses Class.getDeclaredMethods which doesn't return super class methods.
> {code:java}
> private boolean isDate(String fieldName) {
> for (Method method : factObject.getClass().getDeclaredMethods()) {
> if (hasMutator(fieldName, method)) {
> if (java.util.Date.class.isAssignableFrom(method.getParameterTypes()[0])) {
> return true;
> }
> }
> }
> return false;
> }
> {code}
> BTW, if your rules use "mvel" dialect, Guvnor will load org.drools.base.mvel.MVELCompilationUnit class and its static block registers for Date and Calendar org.mvel2.DataConversion. Hence this issue will not occur.
> {code:java}
> static {
> //for handling dates as string literals
> DataConversion.addConversionHandler( Date.class,
> new MVELDateCoercion() );
> DataConversion.addConversionHandler( Calendar.class,
> new MVELCalendarCoercion() );
> }
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1986) Issue with Date format while running test scenario
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1986?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-1767 to DROOLS-1986:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1986 (was: GUVNOR-1767)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
> Issue with Date format while running test scenario
> --------------------------------------------------
>
> Key: DROOLS-1986
> URL: https://issues.jboss.org/browse/DROOLS-1986
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Environment: Guvnor 5.2 and 5.3 on Linux
> Reporter: Alex N
> Assignee: Toni Rikkola
>
> The test scenario fails when comparing dates in the Expects section. The test scenario has date in format dd-MMM-yyyy while the value returned by the rule is in java.util.Date format e.g. Thu Apr 24 00:00:00 EST 1975. Hence the assertion birthDate equals 24-Apr-1975 fails while running the test scenario.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1987) [Test Scenario] Rules are not loaded into 'New expectation' dialogue
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1987?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-2817 to DROOLS-1987:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1987 (was: GUVNOR-2817)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 7.0.0.Beta5
(was: 7.0.0.Beta5)
> [Test Scenario] Rules are not loaded into 'New expectation' dialogue
> --------------------------------------------------------------------
>
> Key: DROOLS-1987
> URL: https://issues.jboss.org/browse/DROOLS-1987
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 7.0.0.Beta5
> Reporter: Jozef Marko
> Assignee: Toni Rikkola
> Labels: dtable_testday_preparation, qe-suggest-pre-7.0.0.Final, qe-test-day, reported-by-qe
>
> There is *(show list)* button in the *New expectation* dialogue. This button should show list of rules available in the current package. However my rules from the same package are not loaded. For more details, please see steps to reproduce.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months
[JBoss JIRA] (DROOLS-1989) Test scenarios: Firing a MVEL rule, whose salience is java.lang.Long.MAX_VALUE, in Guvnor
by Michael Anstis (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1989?page=com.atlassian.jira.plugi... ]
Michael Anstis moved GUVNOR-2075 to DROOLS-1989:
------------------------------------------------
Project: Drools (was: Guvnor)
Key: DROOLS-1989 (was: GUVNOR-2075)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Test Scenarios Editor
(was: Test Scenarios)
Affects Version/s: 5.5.0.Final
(was: drools-5.5.0.Final)
> Test scenarios: Firing a MVEL rule, whose salience is java.lang.Long.MAX_VALUE, in Guvnor
> -----------------------------------------------------------------------------------------
>
> Key: DROOLS-1989
> URL: https://issues.jboss.org/browse/DROOLS-1989
> Project: Drools
> Issue Type: Bug
> Components: Test Scenarios Editor
> Affects Versions: 5.5.0.Final
> Reporter: hisao furuichi
> Attachments: repository_export.xml
>
>
> Problem to fire a MVEL rule, whose salience is 9223372036854775807, in Guvnor. The value 9223372036854775807 is java.lang.Long.MAX_VALUE. If I run a test program in JBDS, I can run without any Exception.
> Additional info:
> If I change a dialect of the rule from "mvel" to "java", I can run the test without any Exception.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 8 months