Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Testing C code using the web

Tags:

c

forms

I have a number of C functions which implement mathematical formulae. To-date these have been tested for mathematical "soundness" by passing parameters through command line applications or compiling DLL's for applications like Excel. Is there an easy way of doing this testing over the web?

Ideally something along the lines of:

  • compile a library
  • spend five minutes defining a web form which calls this code
  • testers can view the webpage, input parameters and review the output

A simple example of a calculation could be to calculate the "accrued interest" of a bond:

Inputs: current date, maturity date, coupon payment frequency (integer), coupon amount (double)

Outputs: the accrued interest (double)

like image 564
user50207 Avatar asked Mar 02 '23 03:03

user50207


1 Answers

You should have a look into automated testing. Manual tests will all have to be repeated every time you change something in your code. Automated tests are the solution for your kind of tests. Let testers write test cases with the accompanying results, then make them into unit tests.

See also: unit testing

like image 151
Thorsten79 Avatar answered Apr 19 '23 03:04

Thorsten79