Fundamental Capstone 2.2

Hello,

For task 2.2 in the fundamental capstone, I ran the separate function test which came back passed but when I run the end of section test, it fails? 

Due to the way I have written it, the function definition is returned but if I do a manual test on it [e.g. extractBrokerId “CME-TSLA20200920C1700-709”], it returns the correct result. 

I have also tried inputting the input directly in the function by swapping the parameter name (exchMsg) to “CME-TSLA20200920C1700-709” - in which, instead of the function definition being returned like my initial attempt, this returns the correct answer directly to the console.

Both attempts are passing its specific function test but the end of section test for 2.2 is still failed.

I’d appreciate any help. Thanks in advance.

Hi Enisha, I have shared the test case for 2.2 below to help you get to the bottom of the difference.

feature exercise2.2 before //make the table as per the data generation method code .test.instRef:(inst_id:1+til 10; inst_syb : AAPLMSFTNFLXGOOGLIBMMCDKOTSLAFBRACE; inst_name:(“Apple”;“Microsoft”;“Netflix”;“Alphabet”;“IBM”;“Mc Donald’s”;“Coca-Cola”;“Tesla”;“Facebook”;“Ferrari”) ); .test.instRef: select from .test.instRef where inst_id in 7 8 9; should instRef Has Correct Format expect //check this matchs the .test.instRef ~ instRef