Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Current »

Overview

A key part of making a good sample is to use <Author><Fix > commands to modify the translation so to ensure the desired changes are produces systematically and not clouded by various reformatting and other changes made the Visual Studio.  Of course you can use VS to help you do the analysis and design for the require corrections, but then you go back to the script and redo them using Author/Fix.  Note: gmStudio Task context menu as a Rebundle operation that will combine the files in the deploy folder into a bundle file (*.bnd.new).  And then open it in your comparison tool (i.e. BeyondCompare) to allow you to see/extract the desired changes easily.  I have a NotePad++ macro that converts those changes into <Replace> blocks..

 

MakeTest is an old and primitive utility created many years ago; it does a simple job and it works, but it is a bit clumsy for sharing with customers.

Since its creation, the gmStudio application has been given a command line interface to make new projects. MakeTest should be retired and its features should be added to gmStudio as an option off the help menu. Eventually, this tool would allow picking pieces of VB6 code from the customer codebase to integrate with the test code.

Using MakeTest

The Template ComboBox fills from the SubFolders of the _MakeTest\Templates directory.  The Template folders contain the gmStudio files used to "seed" the upgrade files in the test directory.

C:\gmSpec\_MakeTest\TEMPLATES>tree /f

├───_C#_and_VBNet
│ package.cmd
│ Test.gmproj
│ tran.Test.xml

└───_C#_Only
package.cmd
Test.gmproj
tran.Test.xml

The Category ComboBox fills with the folders in the working directory of the program.    The folders organized the test upgrade codes created by the program. 

Arch
ASP
COM
Forms
GmTest
Lang
Migrate
Util
The MakeText folder contains the actual VB6 code files for the test:
clsTest.cls 
frmTest.frm
modTest.bas
testCON.vbp
testDLL.vbp
testFORM.vbp

The MakeTest folder also contains the exes and batch files that create the Upgrade Unit test from these template files:

maketest.cmd
MakeTestApp.exe
ssed.exe 

Clicking [Make Test] produces something like the following example:

C:\gmSpec\Lang\MyTest
├───proj
│ │     MyTest.gmProj : gmStudio project file
│ │
│ ├───package
│ │     package.cmd   : packaging script for gathering code, results, etc.
│ │
│ └───usr
│      tran.MyTest.xml  : default translation script
│
└───src
       modMyTest.bas :  VB6 code
       MyTest.vbp    :  VB6 test

 

 

I updated the IssuesLab.gmProj so it contains two tasks: one with TaskTag=upg and one with TaskTag=nofix

 

 

 

I modified the IssueLab Author Fixes in ScriptRules.xml so they apply only if TaskTag=”upg”

 

<ScriptRule id="IssuesLab" Condition="%SrcName%=='Issueslab'">

   <Author Condition="%TaskTag%=='upg'">

   <Fix name="PostEdit">

   <Replace name="correct switch Color">

 

  • The TaskTag=upg reflects the desired results using post-edits to make the changes.
  • The TaskTag=nofix reflects the current results produced without the p;ost-edits.

 

Now I one can run and compare these side by side.  That will show us what is done by the tool and what is done by “hand”.

 

 
  • No labels