DOMAIN-SPECIFIC LANGUAGE FOR INTELLIGENT TESTING OF MICROSERVICE SOFTWARE SYSTEMS BASED ON MOCK-OBJECT TECHNOLOGY

Authors

DOI:

https://doi.org/10.20998/2079-0023.2026.01.18

Keywords:

domain-specific language, intelligent approach, software, service-oriented architecture, microservice, testing, mock-object, distributed system, metric, quality

Abstract

Testing service-oriented and microservice-based systems is challenging due to strong dependencies on external services and distributed environments. Mock-based testing is widely used to address this issue; however, existing solutions rely on low-level configuration mechanisms that increase complexity and reduce maintainability. This paper proposes a domain-specific language (DSL) for intelligent specification and generation of mock services. The approach enables high-level, domain-oriented description of mock behavior and supports transformation into executable configurations for existing mocking platforms. The proposed solution aims to improve readability, reduce configuration effort, and enhance testing efficiency in distributed software systems. The paper reviews existing tools for mock-based testing of service-oriented applications and provides a comparative analysis based on ease of use, configuration flexibility, and the complexity of supported test scenarios. The analysis shows that existing solutions consistently trade off between expressiveness and accessibility, a limitation that the proposed DSL aims to address. To evaluate the proposed approach, a comparative experiment was conducted across four test scenarios of varying complexity. DSL-based configurations were compared against equivalent configurations defined without the DSL, using three metrics: specification size (SLOC), maximum nested block depth, and maintainability index. The results show that the DSL reduces cyclomatic complexity. The composite quality score of DSL-based configurations exceeds the baseline by 38 % on average. These findings confirm that the proposed DSL simplifies the creation of mock services and makes distributed system testing more accessible to a wider range of project participants.

References

MockServer. Official Website. Available at: https://www.mockserver.com/ (accessed: 15.02.2026).

Beck K. Kent Beck's Guide to Better Smalltalk. Cambridge, Cambridge University Press, 1998. 408 p. ISBN 978-0-521-64437-2.

Fowler M. Domain-Specific Languages. Boston, Addison-Wesley Professional, 2010. 640 p. ISBN 978-0-321-71294-3.

Mernik M., Heerin J., Sloane A. When and How to Develop DomainSpecific Languages. Available at: https://dl.acm.org/doi/10.1145/1118890.1118892 (accessed: 15.02.2026). DOI: https://doi.org/10.1145/1118890.1118892.

Ed-douibi H., Izquierdo J. L. C., Cabot J. Automatic Generation of Test Cases for REST APIs: A Specification-Based Approach. IEEE 22nd International Enterprise Distributed Object Computing Conference (EDOC). 2018. Available at: https://www.researchgate.net/publication/328991978_Automatic_Generation_of_Test_Cases_for_REST_APIs_A_SpecificationBased_Approach (accessed: 15.02.2026). DOI: 10.1109/EDOC.2018.00031.

Valle P., Arrieta A., Han L., Ali S., Yue T. Defining and generating multi-level and uncertainty-wise test oracles for cyber-physical systems. Softw Syst Model. 2025, vol. 24, pp. 679–704. Available at: https://link.springer.com/article/10.1007/s10270-025-01271-8 (accessed: 15.02.2026). DOI: 10.1007/s10270-025-01271-8.

De Almeida R., Da Silva R. M., Serrano L. S., Campos Junior H. S., Neves V. O. Mock Objects in Software Testing: An Analysis of Usage in Open-Source Projects. SBQS '23: Proceedings of the XXII Brazilian Symposium on Software Quality. 2023, pp. 72–79 Available at: https://doi.org/10.1145/3629479.3629510 (accessed: 15.02.2026).

Felderer, M., Enoiu, E. P., Tahvili, S. (2023). Artificial Intelligence Techniques in System Testing. Romero J. R., Medina-Bulo I., Chicano F. (eds). Optimising the Software Development Process with Artificial Intelligence. Natural Computing Series. Springer, Singapore. Available at: https://doi.org/10.1007/978-981-19-9948- 2_8 (accessed: 15.02.2026).

From External Chaos to Business Value: The Power of AI Mocking. Available at: https://speedscale.com/blog/from-external-chaos-tobusiness-value-the-power-of-ai-mocking/ (accessed: 15.02.2026).

Gomez N., Batham S., Volonte M., Tiffany D. Do. Virtual Interviewers, Real Results: Exploring AI-Driven Mock Technical Interviews on Student Readiness and Confidence. CSCW Companion '25: Companion Publication of the 2025 Conference on ComputerSupported Cooperative Work and Social Computing. 2025, pp. 209–213. Available at: https://dl.acm.org/doi/10.1145/3715070.3749227 (accessed: 15.02.2026). DOI: https://doi.org/10.1145/3715070.374922.

Bhatt K., Tarey V., Patel P. Analysis Of Source Lines Of Code (SLOC) Metric. International Journal of Emerging Technology and Advanced Engineering. 2012, vol. 2, iss. 5, pp. 150–154. Available at: https://www.researchgate.net/publication/281840565_Analysis_Of_Source_Lines_Of_CodeSLOC_Metric (accessed: 15.02.2026).

Harrison W. A., Magel K. I. A complexity measure based on nesting level. ACM SIGPLAN Notices. 1981, vol. 16, iss. 3, pp. 63–74. Available at: https://dl.acm.org/doi/10.1145/947825.947829 (accessed: 15.02.2026). DOI: https://doi.org/10.1145/947-825.947829

Oman P., Hagemeister J. Metrics for assessing a software system's maintainability. Proceedings of the International Conference on Software Maintenance (ICSM), 1992, pp. 337–344. Available at: https://www.researchgate.net/publication/2954310_Using_Metrics_to_Evaluate_Software_System_Maintainability (accessed: 15.02.2026). DOI: 10.1109/ICSM.1992.242525.

What is ANTLR (ANother Tool for Language Recognition)?‖, Terensi Parr. Available: https://www.antlr.org/ (accessed: 15.02.2026)

Downloads

Published

2026-05-20

How to Cite

Gamzayev, R., Tkachuk, M., & Legenkyi, G. (2026). DOMAIN-SPECIFIC LANGUAGE FOR INTELLIGENT TESTING OF MICROSERVICE SOFTWARE SYSTEMS BASED ON MOCK-OBJECT TECHNOLOGY. Bulletin of National Technical University "KhPI". Series: System Analysis, Control and Information Technologies, (1 (15), 115–122. https://doi.org/10.20998/2079-0023.2026.01.18

Issue

Section

INFORMATION TECHNOLOGY