1VERSION 5.00
2Begin VB.Form frmCoinMP
3   Caption         =   "CoinMP Test"
4   ClientHeight    =   6720
5   ClientLeft      =   60
6   ClientTop       =   450
7   ClientWidth     =   7485
8   LinkTopic       =   "Form1"
9   ScaleHeight     =   6720
10   ScaleWidth      =   7485
11   StartUpPosition =   3  'Windows Default
12   Begin VB.TextBox txt
13      Height          =   5535
14      Left            =   240
15      MultiLine       =   -1  'True
16      ScrollBars      =   2  'Vertical
17      TabIndex        =   2
18      Top             =   240
19      Width           =   6975
20   End
21   Begin VB.CommandButton cmdClear
22      Caption         =   "Clear"
23      Height          =   495
24      Left            =   4200
25      TabIndex        =   1
26      Top             =   6000
27      Width           =   1335
28   End
29   Begin VB.CommandButton cmdRunTest
30      Caption         =   "Run Test"
31      Height          =   495
32      Left            =   1560
33      TabIndex        =   0
34      Top             =   6000
35      Width           =   1335
36   End
37End
38Attribute VB_Name = "frmCoinMP"
39Attribute VB_GlobalNameSpace = False
40Attribute VB_Creatable = False
41Attribute VB_PredeclaredId = True
42Attribute VB_Exposed = False
43Option Explicit
44
45Const MAX_NAME_LEN As Long = 100
46
47Private Sub cmdClear_Click()
48    LogEmptyText
49End Sub
50
51Private Sub cmdRunTest_Click()
52
53Call SolveProblemBakery
54Call SolveProblemCoinTest
55Call SolveProblemAfiro
56Call SolveProblemP0033
57Call SolveProblemExMip1
58
59End Sub
60
61
62Private Sub Form_Load()
63
64Dim result As Long
65Dim length As Long
66Dim solverName As String
67Dim version As Double
68
69
70    result = CoinInitSolver("")
71
72    solverName = String(MAX_NAME_LEN, vbNullChar)
73    length = CoinGetSolverNameBuf(solverName, MAX_NAME_LEN)
74    solverName = Left(solverName, length)
75
76    version = CoinGetVersion()
77
78    LogEmptyText
79    LogWriteLine "Solver: " & solverName
80    LogWriteLine "Version:  " & version
81
82
83End Sub
84
85
86Private Sub Form_Unload(Cancel As Integer)
87
88Dim result As Long
89
90result = CoinFreeSolver()
91LogWriteLine "All unit tests completed successfully"
92
93End Sub
94
95