Highlighted
Absent Member.
Absent Member.
1297 views

Unit testing with AMB

Hello,

 

I am currently coaching mainframe teams in adopting practices that make up Continuous Delivery. This is part of a bigger agile transformation the organisation is going through.

The teams develop in AMB (AppMaster Builder) using Micro Focus Mainframe Express (MFE) v3.1 on Windows. I've understood AMB is a language similar to COBOL that generates native Mainframe COBOL. What I don't know yet is: can the AMB code be directly executed inside MFE on Windows without first generating the COBOL ?

I would like to introduce the concept of automated unit testing. Googling around I found COBOLUnit, IBM zUnit and that Micro Focus actually also has a unit testing framework.

First of all, can any COBOL code directly call AMB code. So can any unit testing framework call AMB code and have this executed inside MFE on Windows ?

Second, does Micro Focus have a unit testing framework specifically for AMB ?

 

Thank you for your time.

Regards,

Thierry

0 Likes
2 Replies
Highlighted
Absent Member.
Absent Member.

No, AMB is used to develop your application program which then creates your COBOL program. There is nothing you can execute/call within AMB, it is purely for developing your application.
0 Likes
Highlighted
Micro Focus Contributor
Micro Focus Contributor

Hi Thierry,
hi bazc,

I do not agree that it is not possible to do Unit Testing with AMB code once it is generated under MFE EE. As bazc states correctly AMB generates your COBOL source but then MFE has the compiler and run-time environment for the mainframe subsystems such as CICS, IMS, Batch to execute/debug those programs.
So as I understand you are looking to build a Unit Test framework. The Micro Focus Unit Test framework supports native COBOL only but not programs that require the IMS or CICS environment for example. And it is only available in latest product version of Enterprise Developer not with MFE EE.
Saying that you would be able write your own Framework once you understand the interface of the AMB generated COBOL programs to call.
Another discussion which is currently ongoing is what do you define as Unit able to test in a (monolithic) legacy mainframe application. Without re-architecture and applying microservice architecture it might be your IMS or CICS transaction, which in most cases has a BMS/MFS 3270 screen, IMS Connect or CTG interface or triggered by MQ. So your unit test framework might have to stick with those interfaces.
The beauty is that with MFE EE you already have Test Coverage which at the end produces a report to document that you have tested your actual module and also which lines of the generated COBOL code has been tested.

If you need more information please let me know.

I hope that helps,

Mathias
mathias.mezger@microfocus.com

Best regards,

Mathias

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.