テストにフルーツを使用するプロジェクト(fortranコード)があります。これは私のコードです。
電卓.f90
module calculator
implicit none
contains
subroutine add (a, b, output)
integer, intent(in) :: a, b
integer, intent(out):: output
output = a+b
end subroutine add
end module calculator
そして私のテストの計算機_test.f90
module calculator_test
use fruit
contains
subroutine test_5_2_2
use calculator, only: add
integer :: result
call add(2,2,result)
call assertEquals(4,result)
end subroutine test_5_2_2
subroutine test_5_2_3
use calculator, only: add
integer :: result
call add(2,3,result)
call assertEquals(5,result)
end subroutine test_5_2_3
end module
ここで、Cmake を使用してテストをビルドして実行したいので (jenkins によってトリガーされます)、私の質問は次のとおりです。それでどうやって?私はオンラインで多くのことを検索しましたが、cmake でのすべてのテストは c++ で行われ、次に実行可能なテストファイル ファイルを使用して行われるようです。
ありがとう!-ミンデ