You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I try to run scenarios with Outline end Examples sections I receive error message 'undefined method `registry' for #Cucumber::Wire::StepDefinition:0x00000000ed4cc0 (NoMethodError)'
when using cucember 2.4.0 or 3.1.2 version.
Expected Behavior
The identical wire protocol exhange not depending on cucumber version
Current Behavior
I've dumped the wire protocol exhange and there is logical difference in message sequence, version 3.1.2 doesn't include any invoke calls.
cucumber Version 3.1.2
["step_matches",{"name_to_match":"abonent"}]
["success",[{"args":[],"id":"1","regexp":"^abonent$","source":"AbonentSteps.cpp:50"}]]
["step_matches",{"name_to_match":"IMEI is 12345678901234"}]
["success",[{"args":[{"pos":8,"val":"12345678901234"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 111222333444555"}]
["success",[{"args":[{"pos":8,"val":"111222333444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 0"}]
["success",[{"args":[{"pos":12,"val":"0"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"is not expired"}]
["success",[{"args":[],"id":"6","regexp":"is not expired","source":"AbonentSteps.cpp:86"}]]
["step_matches",{"name_to_match":"make CheckIMEI request"}]
["success",[{"args":[],"id":"8","regexp":"make CheckIMEI request","source":"AbonentSteps.cpp:98"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 0"}]
["success",[{"args":[{"pos":23,"val":"0"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["step_matches",{"name_to_match":"IMEI is 12341234567890"}]
["success",[{"args":[{"pos":8,"val":"12341234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 555444333222111"}]
["success",[{"args":[{"pos":8,"val":"555444333222111"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 1"}]
["success",[{"args":[{"pos":12,"val":"1"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 1"}]
["success",[{"args":[{"pos":23,"val":"1"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["step_matches",{"name_to_match":"IMEI is 78901234567890"}]
["success",[{"args":[{"pos":8,"val":"78901234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 333222111444555"}]
["success",[{"args":[{"pos":8,"val":"333222111444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 2"}]
["success",[{"args":[{"pos":12,"val":"2"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 2"}]
["success",[{"args":[{"pos":23,"val":"2"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
cucumber 2.0.0
["step_matches",{"name_to_match":"abonent"}]
["success",[{"args":[],"id":"1","regexp":"^abonent$","source":"AbonentSteps.cpp:50"}]]
["step_matches",{"name_to_match":"IMEI is 12345678901234"}]
["success",[{"args":[{"pos":8,"val":"12345678901234"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 111222333444555"}]
["success",[{"args":[{"pos":8,"val":"111222333444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 0"}]
["success",[{"args":[{"pos":12,"val":"0"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"is not expired"}]
["success",[{"args":[],"id":"6","regexp":"is not expired","source":"AbonentSteps.cpp:86"}]]
["step_matches",{"name_to_match":"make CheckIMEI request"}]
["success",[{"args":[],"id":"8","regexp":"make CheckIMEI request","source":"AbonentSteps.cpp:98"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 0"}]
["success",[{"args":[{"pos":23,"val":"0"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["12345678901234"]}]
["success"]
["invoke",{"id":"4","args":["111222333444555"]}]
["success"]
["invoke",{"id":"5","args":["0"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["0"]}]
["success"]
["end_scenario"]
["success"]
["step_matches",{"name_to_match":"IMEI is 12341234567890"}]
["success",[{"args":[{"pos":8,"val":"12341234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 555444333222111"}]
["success",[{"args":[{"pos":8,"val":"555444333222111"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 1"}]
["success",[{"args":[{"pos":12,"val":"1"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 1"}]
["success",[{"args":[{"pos":23,"val":"1"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["12341234567890"]}]
["success"]
["invoke",{"id":"4","args":["555444333222111"]}]
["success"]
["invoke",{"id":"5","args":["1"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["1"]}]
["success"]
["end_scenario"]
["success"]
["step_matches",{"name_to_match":"IMEI is 78901234567890"}]
["success",[{"args":[{"pos":8,"val":"78901234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 333222111444555"}]
["success",[{"args":[{"pos":8,"val":"333222111444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 2"}]
["success",[{"args":[{"pos":12,"val":"2"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 2"}]
["success",[{"args":[{"pos":23,"val":"2"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["78901234567890"]}]
["success"]
["invoke",{"id":"4","args":["333222111444555"]}]
["success"]
["invoke",{"id":"5","args":["2"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["2"]}]
["success"]
["end_scenario"]
["success"]
Possible Solution
no idea
Steps to Reproduce (for bugs)
1. Scenario with Outline and Examples section
`# language: en
Feature: CheckIMEI test
testing Protei_EIR, first stage
Scenario Outline: getting equipment status
Given abonent
And IMEI is
And IMSI is
And ListType is
And is not expired
When make CheckIMEI request
Then the equipmentStatus is
Summary
When I try to run scenarios with Outline end Examples sections I receive error message 'undefined method `registry' for #Cucumber::Wire::StepDefinition:0x00000000ed4cc0 (NoMethodError)'
when using cucember 2.4.0 or 3.1.2 version.
Expected Behavior
The identical wire protocol exhange not depending on cucumber version
Current Behavior
I've dumped the wire protocol exhange and there is logical difference in message sequence, version 3.1.2 doesn't include any invoke calls.
cucumber Version 3.1.2
["step_matches",{"name_to_match":"abonent"}]
["success",[{"args":[],"id":"1","regexp":"^abonent$","source":"AbonentSteps.cpp:50"}]]
["step_matches",{"name_to_match":"IMEI is 12345678901234"}]
["success",[{"args":[{"pos":8,"val":"12345678901234"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 111222333444555"}]
["success",[{"args":[{"pos":8,"val":"111222333444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 0"}]
["success",[{"args":[{"pos":12,"val":"0"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"is not expired"}]
["success",[{"args":[],"id":"6","regexp":"is not expired","source":"AbonentSteps.cpp:86"}]]
["step_matches",{"name_to_match":"make CheckIMEI request"}]
["success",[{"args":[],"id":"8","regexp":"make CheckIMEI request","source":"AbonentSteps.cpp:98"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 0"}]
["success",[{"args":[{"pos":23,"val":"0"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["step_matches",{"name_to_match":"IMEI is 12341234567890"}]
["success",[{"args":[{"pos":8,"val":"12341234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 555444333222111"}]
["success",[{"args":[{"pos":8,"val":"555444333222111"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 1"}]
["success",[{"args":[{"pos":12,"val":"1"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 1"}]
["success",[{"args":[{"pos":23,"val":"1"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["step_matches",{"name_to_match":"IMEI is 78901234567890"}]
["success",[{"args":[{"pos":8,"val":"78901234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 333222111444555"}]
["success",[{"args":[{"pos":8,"val":"333222111444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 2"}]
["success",[{"args":[{"pos":12,"val":"2"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 2"}]
["success",[{"args":[{"pos":23,"val":"2"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
["begin_scenario"]
["success"]
["end_scenario"]
["success"]
cucumber 2.0.0
["step_matches",{"name_to_match":"abonent"}]
["success",[{"args":[],"id":"1","regexp":"^abonent$","source":"AbonentSteps.cpp:50"}]]
["step_matches",{"name_to_match":"IMEI is 12345678901234"}]
["success",[{"args":[{"pos":8,"val":"12345678901234"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 111222333444555"}]
["success",[{"args":[{"pos":8,"val":"111222333444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 0"}]
["success",[{"args":[{"pos":12,"val":"0"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"is not expired"}]
["success",[{"args":[],"id":"6","regexp":"is not expired","source":"AbonentSteps.cpp:86"}]]
["step_matches",{"name_to_match":"make CheckIMEI request"}]
["success",[{"args":[],"id":"8","regexp":"make CheckIMEI request","source":"AbonentSteps.cpp:98"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 0"}]
["success",[{"args":[{"pos":23,"val":"0"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["12345678901234"]}]
["success"]
["invoke",{"id":"4","args":["111222333444555"]}]
["success"]
["invoke",{"id":"5","args":["0"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["0"]}]
["success"]
["end_scenario"]
["success"]
["step_matches",{"name_to_match":"IMEI is 12341234567890"}]
["success",[{"args":[{"pos":8,"val":"12341234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 555444333222111"}]
["success",[{"args":[{"pos":8,"val":"555444333222111"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 1"}]
["success",[{"args":[{"pos":12,"val":"1"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 1"}]
["success",[{"args":[{"pos":23,"val":"1"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["12341234567890"]}]
["success"]
["invoke",{"id":"4","args":["555444333222111"]}]
["success"]
["invoke",{"id":"5","args":["1"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["1"]}]
["success"]
["end_scenario"]
["success"]
["step_matches",{"name_to_match":"IMEI is 78901234567890"}]
["success",[{"args":[{"pos":8,"val":"78901234567890"}],"id":"3","regexp":"^IMEI is (\d+)$","source":"AbonentSteps.cpp:65"}]]
["step_matches",{"name_to_match":"IMSI is 333222111444555"}]
["success",[{"args":[{"pos":8,"val":"333222111444555"}],"id":"4","regexp":"^IMSI is (\d+)$","source":"AbonentSteps.cpp:72"}]]
["step_matches",{"name_to_match":"ListType is 2"}]
["success",[{"args":[{"pos":12,"val":"2"}],"id":"5","regexp":"^ListType is (\d+)$","source":"AbonentSteps.cpp:79"}]]
["step_matches",{"name_to_match":"the equipmentStatus is 2"}]
["success",[{"args":[{"pos":23,"val":"2"}],"id":"9","regexp":"the equipmentStatus is (\d+)","source":"AbonentSteps.cpp:112"}]]
["begin_scenario"]
["success"]
["invoke",{"id":"1","args":[]}]
["success"]
["invoke",{"id":"3","args":["78901234567890"]}]
["success"]
["invoke",{"id":"4","args":["333222111444555"]}]
["success"]
["invoke",{"id":"5","args":["2"]}]
["success"]
["invoke",{"id":"6","args":[]}]
["success"]
["invoke",{"id":"8","args":[]}]
["success"]
["invoke",{"id":"9","args":["2"]}]
["success"]
["end_scenario"]
["success"]
Possible Solution
no idea
Steps to Reproduce (for bugs)
1. Scenario with Outline and Examples section
`# language: en
Feature: CheckIMEI test
testing Protei_EIR, first stage
Scenario Outline: getting equipment status
Given abonent
And IMEI is
And IMSI is
And ListType is
And is not expired
When make CheckIMEI request
Then the equipmentStatus is
Examples:
| IMSI | IMEI | ListType | status |
| 111222333444555 | 12345678901234 | 0 | 0 |
| 555444333222111 | 12341234567890 | 1 | 1 |
| 333222111444555 | 78901234567890 | 2 | 2 |`
2. Some Code
`#include <DataModel/DB/Abonent.h>
struct Tm_AbonentContext
{
Tm_Abonent m_Abonent;
int m_nStatus;
}/* Context*/;
typedef cucumber::ScenarioScope<Tm_AbonentContext> Tm_AbonentScenarioContext;
GIVEN("^abonent$") {
}
GIVEN("^IMEI is (\d+), IMSI is (\d+), ListType is (\d+)$")
{
REGEX_PARAM(std::string, s1);
REGEX_PARAM(std::string, s2);
REGEX_PARAM(int, n);
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_sIMEI = s1;
Context->m_Abonent.m_sIMSI = s2;
Context->m_Abonent.m_nListType = n;
};
GIVEN("^IMEI is (\d+)$")
{
REGEX_PARAM(std::string, s);
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_sIMEI = s;
};
GIVEN("^IMSI is (\d+)$")
{
REGEX_PARAM(std::string, s);
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_sIMSI = s;
};
GIVEN("^ListType is (\d+)$")
{
REGEX_PARAM(int, n);
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_nListType = n;
};
GIVEN("is not expired")
{
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_dtExpiry = Tm_DateTime::Now().AddDays(1);
};
GIVEN("is expired")
{
Tm_AbonentScenarioContext Context;
Context->m_Abonent.m_dtExpiry = Tm_DateTime::Now().AddDays(-1);
};
WHEN("make CheckIMEI request")
{
//fetch nStatus
Tm_AbonentScenarioContext Context;
EXPECT_EQ(true, Context->m_Abonent.CreateOrUpdate());
Tm_Abonent::ptr_type pAbonent = Tm_Abonent::FindByIMEI(Context->m_Abonent.m_sIMEI);
EXPECT_NE(nullptr, pAbonent);
if (pAbonent)
{
std::cout << "find abonent: " << *pAbonent << std::endl;
Context->m_nStatus = pAbonent->m_nListType;
}
};
THEN("the equipmentStatus is (\d+)")
{
REGEX_PARAM(int, expected);
Tm_AbonentScenarioContext Context;
EXPECT_EQ(expected, Context->m_nStatus);
};
`
3. Run test
Your Environment
Unfortunately, there is no support for pcap files
The text was updated successfully, but these errors were encountered: