I am fairly new to SAP/ABAP and would like to ensure the quality of code with goes into our SAP ERP. If we could trust all the developers who work with us, then this task would be much easily achieved. Even if that were the case I still think those techniques are quite helpful (not to say, essential).
In Java, or any other mainstream platform, they use TDD, BDD, Continuous Integration (like Jenkins) and other plugins, like:
We could add many other plugins if we want to, but those are the basic ones which most serious projects use when the platform is Java. I know most of you guys are familiar with those concepts and techniques, which have been in use since last millenium .
Now, what are the tools, concepts or techniques which can be used in SAP/ABAP to achieve similar level of code quality and also quick feedback? I have found there is ABAPUnit (for the TDD part), but I wasn't able to find anyone who used it in real projects. What about BDD, CI...?
Even better, what are the companies using those?
Any help would be much appreciated.
In my experience most of good developers mainly concentrate on -
3. As much as possible less database hit and processing in application server
There are few SAP provided tools like code inspector, extended syntax check, memory usage global variables are together can guide to good performed code.
Beside that there are some settings in SAP ABAP editor like - give error if read without binary search for sorted table helps to improve performance.
In SAP you have tools like Code Inspector (SCI), Extended Program check (SLIN), Program analysis (SAT & ST12). You can use these tools to make sure, they pass from the standard checks.
There is not much written content about the ABAP Units. I know there are people who have used it who are working on Agile and TDD. I have used it couple of clients place. Due to the face - lack of mock objects make is difficult to write Unit Tests for few of the methods. The code needs to separate out the logic vs access to DB, calls to BAPIs, etc.
SAP offers various tools and techniques to ensure high quality software. These tools underly an evolution and depending on the release of your system may offer more or less features.
Your system should contain some documentation on quality related tools and their capabilities. So for the tool part you may get some info from the system itself, as starting point you may try transaction /NABAPHELP and search for the term ABAP Unit. The hits should somehow refer to a page like this:
There are 2 things to ensure this:
1. Standard Tools inside SAP
2. Code review checklist (which we can prepare)
Tthe tools are extended program check (SLIN) and code inspector.
They will basically highlight general abnormalities. If those abnormalities are corrected, the code will be generally ok. However as below,
However, there are some points eg. Clearing a itab/variable/structure before populating, authorization check in our program. change history logging inside the code, hardcoding and constants, checking if ITAB is not empty just before using FOR all entires, etc which standard tools will not detect normally. Hence for such things, we can design a CHECKLIST kind of document (based on our experience and general guidelines). The code should be reviewed against this checklist to ensure better quality.
Hope this helps.