# HG changeset patch # User Patrik Svestka # Date 1654689232 -7200 # Node ID 98caa7f380f77f4084ba2a06a98e46dd5a0a7543 # Parent ca73e0f717dc470aa3b436ad5660c8dc7d1e39ca Testing FontPanel initialization with incomplete Font information diff -r ca73e0f717dc -r 98caa7f380f7 tests/FontPanelTests.st --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/FontPanelTests.st Wed Jun 08 13:53:52 2022 +0200 @@ -0,0 +1,66 @@ +" +COPYRIGHT (c) 2022 Patrik Svestka + + All Rights Reserved + + This software is furnished under a license and may be used + only in accordance with the terms of that license and with the + inclusion of the above copyright notice. This software may not + be provided or otherwise made available to, or used by, any + other person. No title to or ownership of the software is + hereby transferred. +" +"{ Package: 'stx:libwidg/tests' }" + +"{ NameSpace: Smalltalk }" + +TestCase subclass:#FontPanelTests + instanceVariableNames:'' + classVariableNames:'' + poolDictionaries:'' + category:'Views-Text-Tests' +! + +!FontPanelTests class methodsFor:'documentation'! + +copyright +" +COPYRIGHT (c) 2022 Patrik Svestka + + All Rights Reserved + + This software is furnished under a license and may be used + only in accordance with the terms of that license and with the + inclusion of the above copyright notice. This software may not + be provided or otherwise made available to, or used by, any + other person. No title to or ownership of the software is + hereby transferred. +" +! ! + +!FontPanelTests methodsFor:'tests'! + +testFontPanelInit + "Testing initialization of a Font Panel with incomplete font information" + |aFont labelTitle aFontSettingsPanel | + + aFont := Font family:'courier' face:nil style:nil size:14 sizeUnit:#pt encoding:nil. + labelTitle := 'Font for Edited Text'. + + aFontSettingsPanel := FontPanel new. + self shouldnt: [ + aFontSettingsPanel initialFont: aFont. + aFontSettingsPanel label: labelTitle. + aFontSettingsPanel encodingFilter: nil + ] raise: Error. + + "Created: / 08-06-2022 / 13:51:07 / Patrik Svestka " +! ! + +!FontPanelTests class methodsFor:'documentation'! + +version_HG + + ^ '$Changeset: $' +! ! + diff -r ca73e0f717dc -r 98caa7f380f7 tests/Make.proto --- a/tests/Make.proto Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/Make.proto Wed Jun 08 13:53:52 2022 +0200 @@ -1,132 +1,133 @@ -# $Header$ -# -# DO NOT EDIT -# automagically generated from the projectDefinition: stx_libwidg_tests. -# -# Warning: once you modify this file, do not rerun -# stmkmp or projectDefinition-build again - otherwise, your changes are lost. -# -# The Makefile as generated by this Make.proto supports the following targets: -# make - compile all st-files to a classLib -# make clean - clean all temp files -# make clobber - clean all -# -# This file contains definitions for Unix based platforms. -# It shares common definitions with the win32-make in Make.spec. - -# -# position (of this package) in directory hierarchy: -# (must point to ST/X top directory, for tools and includes) -TOP=../.. -INCLUDE_TOP=$(TOP)/.. - -# subdirectories where targets are to be made: -SUBDIRS= - - -# subdirectories where Makefiles are to be made: -# (only define if different from SUBDIRS) -# ALLSUBDIRS= - -REQUIRED_SUPPORT_DIRS= - -# if your embedded C code requires any system includes, -# add the path(es) here:, -# ********** OPTIONAL: MODIFY the next lines *** -# LOCALINCLUDES=-Ifoo -Ibar -LOCALINCLUDES= -I$(INCLUDE_TOP)/stx/goodies/sunit -I$(INCLUDE_TOP)/stx/libbasic -I$(INCLUDE_TOP)/stx/libview -I$(INCLUDE_TOP)/stx/libwidg - - -# if you need any additional defines for embedded C code, -# add them here:, -# ********** OPTIONAL: MODIFY the next lines *** -# LOCALDEFINES=-Dfoo -Dbar -DDEBUG -LOCALDEFINES= - -LIBNAME=libstx_libwidg_tests -STCLOCALOPT='-package=$(PACKAGE)' -I. $(LOCALINCLUDES) $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALDEFINES) -headerDir=. -varPrefix=$(LIBNAME) - - -# ********** OPTIONAL: MODIFY the next line *** -# additional C-libraries that should be pre-linked with the class-objects -LD_OBJ_LIBS= -LOCAL_SHARED_LIBS= - - -# ********** OPTIONAL: MODIFY the next line *** -# additional C targets or libraries should be added below -LOCAL_EXTRA_TARGETS= - -OBJS= $(COMMON_OBJS) $(UNIX_OBJS) - - - -all:: preMake classLibRule postMake - -pre_objs:: - - - - - - -# Enforce recompilation of package definition class if Mercurial working -# copy state changes. Together with --guessVersion it ensures that package -# definition class always contains correct binary revision string. -ifneq (**NOHG**, $(shell hg root 2> /dev/null || echo -n '**NOHG**')) -stx_libwidg_tests.$(O): $(shell hg root)/.hg/dirstate -endif - - - - -# run default testsuite for this package -test: $(TOP)/goodies/builder/reports - $(MAKE) -C $(TOP)/goodies/builder/reports -f Makefile.init - $(TOP)/goodies/builder/reports/report-runner.sh -D . -r Builder::TestReport -p $(PACKAGE) - - - -# add more install actions here -install:: - -# add more install actions for aux-files (resources) here -installAux:: - -# add more preMake actions here -preMake:: - -# add more postMake actions here -postMake:: cleanjunk - -# build all mandatory prerequisite packages (containing superclasses) for this package -prereq: - cd ../../libbasic && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - cd ../../libbasic2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - cd ../../libview && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - cd ../../libview2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - cd ../../goodies/sunit && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - - - -# build all packages containing referenced classes for this package -# they are not needed to compile the package (but later, to load it) -references: - - -cleanjunk:: - -rm -f *.s *.s2 - -clean:: - -rm -f *.o *.H - -clobber:: clean - -rm -f *.so *.dll - - -# BEGINMAKEDEPEND --- do not remove this line; make depend needs it -$(OUTDIR)EditFieldTests.$(O) EditFieldTests.$(C) EditFieldTests.$(H): EditFieldTests.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/goodies/sunit/TestCase.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) -$(OUTDIR)stx_libwidg_tests.$(O) stx_libwidg_tests.$(C) stx_libwidg_tests.$(H): stx_libwidg_tests.st $(INCLUDE_TOP)/stx/libbasic/LibraryDefinition.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libbasic/ProjectDefinition.$(H) $(STCHDR) - -# ENDMAKEDEPEND --- do not remove this line - +# $Header$ +# +# DO NOT EDIT +# automagically generated from the projectDefinition: stx_libwidg_tests. +# +# Warning: once you modify this file, do not rerun +# stmkmp or projectDefinition-build again - otherwise, your changes are lost. +# +# The Makefile as generated by this Make.proto supports the following targets: +# make - compile all st-files to a classLib +# make clean - clean all temp files +# make clobber - clean all +# +# This file contains definitions for Unix based platforms. +# It shares common definitions with the win32-make in Make.spec. + +# +# position (of this package) in directory hierarchy: +# (must point to ST/X top directory, for tools and includes) +TOP=../.. +INCLUDE_TOP=$(TOP)/.. + +# subdirectories where targets are to be made: +SUBDIRS= + + +# subdirectories where Makefiles are to be made: +# (only define if different from SUBDIRS) +# ALLSUBDIRS= + +REQUIRED_SUPPORT_DIRS= + +# if your embedded C code requires any system includes, +# add the path(es) here:, +# ********** OPTIONAL: MODIFY the next lines *** +# LOCALINCLUDES=-Ifoo -Ibar +LOCALINCLUDES= -I$(INCLUDE_TOP)/stx/goodies/sunit -I$(INCLUDE_TOP)/stx/libbasic -I$(INCLUDE_TOP)/stx/libbasic3 -I$(INCLUDE_TOP)/stx/libview -I$(INCLUDE_TOP)/stx/libwidg + + +# if you need any additional defines for embedded C code, +# add them here:, +# ********** OPTIONAL: MODIFY the next lines *** +# LOCALDEFINES=-Dfoo -Dbar -DDEBUG +LOCALDEFINES= + +LIBNAME=libstx_libwidg_tests +STCLOCALOPT='-package=$(PACKAGE)' -I. $(LOCALINCLUDES) $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALDEFINES) -headerDir=. -varPrefix=$(LIBNAME) + + +# ********** OPTIONAL: MODIFY the next line *** +# additional C-libraries that should be pre-linked with the class-objects +LD_OBJ_LIBS= +LOCAL_SHARED_LIBS= + + +# ********** OPTIONAL: MODIFY the next line *** +# additional C targets or libraries should be added below +LOCAL_EXTRA_TARGETS= + +OBJS= $(COMMON_OBJS) $(UNIX_OBJS) + + + +all:: preMake classLibRule postMake + +pre_objs:: + + + + + + +# Enforce recompilation of package definition class if Mercurial working +# copy state changes. Together with --guessVersion it ensures that package +# definition class always contains correct binary revision string. +ifneq (**NOHG**, $(shell hg root 2> /dev/null || echo -n '**NOHG**')) +stx_libwidg_tests.$(O): $(shell hg root)/.hg/dirstate +endif + + + + +# run default testsuite for this package +test: $(TOP)/goodies/builder/reports + $(MAKE) -C $(TOP)/goodies/builder/reports -f Makefile.init + $(TOP)/goodies/builder/reports/report-runner.sh -D . -r Builder::TestReport -p $(PACKAGE) + + + +# add more install actions here +install:: + +# add more install actions for aux-files (resources) here +installAux:: + +# add more preMake actions here +preMake:: + +# add more postMake actions here +postMake:: cleanjunk + +# build all mandatory prerequisite packages (containing superclasses) for this package +prereq: + cd ../../libbasic && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + cd ../../libbasic2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + cd ../../libview && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + cd ../../libview2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + cd ../../goodies/sunit && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + + + +# build all packages containing referenced classes for this package +# they are not needed to compile the package (but later, to load it) +references: + + +cleanjunk:: + -rm -f *.s *.s2 + +clean:: + -rm -f *.o *.H + +clobber:: clean + -rm -f *.so *.dll + + +# BEGINMAKEDEPEND --- do not remove this line; make depend needs it +$(OUTDIR)EditFieldTests.$(O) EditFieldTests.$(C) EditFieldTests.$(H): EditFieldTests.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/goodies/sunit/TestCase.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) +$(OUTDIR)FontPanelTests.$(O) FontPanelTests.$(C) FontPanelTests.$(H): FontPanelTests.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/goodies/sunit/TestCase.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) +$(OUTDIR)stx_libwidg_tests.$(O) stx_libwidg_tests.$(C) stx_libwidg_tests.$(H): stx_libwidg_tests.st $(INCLUDE_TOP)/stx/libbasic/LibraryDefinition.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libbasic/ProjectDefinition.$(H) $(STCHDR) + +# ENDMAKEDEPEND --- do not remove this line + diff -r ca73e0f717dc -r 98caa7f380f7 tests/Make.spec --- a/tests/Make.spec Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/Make.spec Wed Jun 08 13:53:52 2022 +0200 @@ -1,65 +1,67 @@ -# $Header$ -# -# DO NOT EDIT -# automagically generated from the projectDefinition: stx_libwidg_tests. -# -# Warning: once you modify this file, do not rerun -# stmkmp or projectDefinition-build again - otherwise, your changes are lost. -# -# This file contains specifications which are common to all platforms. -# - -# Do NOT CHANGE THESE DEFINITIONS -# (otherwise, ST/X will have a hard time to find out the packages location from its packageID, -# to find the source code of a class and to find the library for a package) -MODULE=stx -MODULE_DIR=libwidg/tests -PACKAGE=$(MODULE):$(MODULE_DIR) - - -# Argument(s) to the stc compiler (stc --usage). -# -headerDir=. : create header files locally -# (if removed, they will be created as common -# -Pxxx : defines the package -# -Zxxx : a prefix for variables within the classLib -# -Dxxx : defines passed to CC for inline C-code -# -Ixxx : include path passed to CC for inline C-code -# +optspace : optimized for space -# +optspace2 : optimized more for space -# +optspace3 : optimized even more for space -# +optinline : generate inline code for some ST constructs -# +inlineNew : additionally inline new -# +inlineMath : additionally inline some floatPnt math stuff -# -# ********** OPTIONAL: MODIFY the next line(s) *** -# STCLOCALOPTIMIZATIONS=+optinline +inlineNew -# STCLOCALOPTIMIZATIONS=+optspace3 -STCLOCALOPTIMIZATIONS=+optspace3 - - -# Argument(s) to the stc compiler (stc --usage). -# -warn : no warnings -# -warnNonStandard : no warnings about ST/X extensions -# -warnEOLComments : no warnings about EOL comment extension -# -warnPrivacy : no warnings about privateClass extension -# -warnUnused : no warnings about unused variables -# -# ********** OPTIONAL: MODIFY the next line(s) *** -# STCWARNINGS=-warn -# STCWARNINGS=-warnNonStandard -# STCWARNINGS=-warnEOLComments -STCWARNINGS=-warnNonStandard - -COMMON_CLASSES= \ - EditFieldTests \ - stx_libwidg_tests \ - - - - -COMMON_OBJS= \ - $(OUTDIR)EditFieldTests.$(O) \ - $(OUTDIR)stx_libwidg_tests.$(O) \ - - - +# $Header$ +# +# DO NOT EDIT +# automagically generated from the projectDefinition: stx_libwidg_tests. +# +# Warning: once you modify this file, do not rerun +# stmkmp or projectDefinition-build again - otherwise, your changes are lost. +# +# This file contains specifications which are common to all platforms. +# + +# Do NOT CHANGE THESE DEFINITIONS +# (otherwise, ST/X will have a hard time to find out the packages location from its packageID, +# to find the source code of a class and to find the library for a package) +MODULE=stx +MODULE_DIR=libwidg/tests +PACKAGE=$(MODULE):$(MODULE_DIR) + + +# Argument(s) to the stc compiler (stc --usage). +# -headerDir=. : create header files locally +# (if removed, they will be created as common +# -Pxxx : defines the package +# -Zxxx : a prefix for variables within the classLib +# -Dxxx : defines passed to CC for inline C-code +# -Ixxx : include path passed to CC for inline C-code +# +optspace : optimized for space +# +optspace2 : optimized more for space +# +optspace3 : optimized even more for space +# +optinline : generate inline code for some ST constructs +# +inlineNew : additionally inline new +# +inlineMath : additionally inline some floatPnt math stuff +# +# ********** OPTIONAL: MODIFY the next line(s) *** +# STCLOCALOPTIMIZATIONS=+optinline +inlineNew +# STCLOCALOPTIMIZATIONS=+optspace3 +STCLOCALOPTIMIZATIONS=+optspace3 + + +# Argument(s) to the stc compiler (stc --usage). +# -warn : no warnings +# -warnNonStandard : no warnings about ST/X extensions +# -warnEOLComments : no warnings about EOL comment extension +# -warnPrivacy : no warnings about privateClass extension +# -warnUnused : no warnings about unused variables +# +# ********** OPTIONAL: MODIFY the next line(s) *** +# STCWARNINGS=-warn +# STCWARNINGS=-warnNonStandard +# STCWARNINGS=-warnEOLComments +STCWARNINGS=-warnNonStandard + +COMMON_CLASSES= \ + EditFieldTests \ + FontPanelTests \ + stx_libwidg_tests \ + + + + +COMMON_OBJS= \ + $(OUTDIR)EditFieldTests.$(O) \ + $(OUTDIR)FontPanelTests.$(O) \ + $(OUTDIR)stx_libwidg_tests.$(O) \ + + + diff -r ca73e0f717dc -r 98caa7f380f7 tests/Makefile.init --- a/tests/Makefile.init Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/Makefile.init Wed Jun 08 13:53:52 2022 +0200 @@ -1,27 +1,27 @@ -# -# DO NOT EDIT -# -# make uses this file (Makefile) only, if there is no -# file named "makefile" (lower-case m) in the same directory. -# My only task is to generate the real makefile and call make again. -# Thereafter, I am no longer used and needed. -# -# MACOSX caveat: -# as filenames are not case sensitive (in a default setup), -# we cannot use the above trick. Therefore, this file is now named -# "Makefile.init", and you have to execute "make -f Makefile.init" to -# get the initial makefile. This is now also done by the toplevel CONFIG -# script. - -.PHONY: run - -run: makefile - $(MAKE) -f makefile - -#only needed for the definition of $(TOP) -include Make.proto - -makefile: mf - -mf: - $(TOP)/rules/stmkmf +# +# DO NOT EDIT +# +# make uses this file (Makefile) only, if there is no +# file named "makefile" (lower-case m) in the same directory. +# My only task is to generate the real makefile and call make again. +# Thereafter, I am no longer used and needed. +# +# MACOSX caveat: +# as filenames are not case sensitive (in a default setup), +# we cannot use the above trick. Therefore, this file is now named +# "Makefile.init", and you have to execute "make -f Makefile.init" to +# get the initial makefile. This is now also done by the toplevel CONFIG +# script. + +.PHONY: run + +run: makefile + $(MAKE) -f makefile + +#only needed for the definition of $(TOP) +include Make.proto + +makefile: mf + +mf: + $(TOP)/rules/stmkmf diff -r ca73e0f717dc -r 98caa7f380f7 tests/abbrev.stc --- a/tests/abbrev.stc Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/abbrev.stc Wed Jun 08 13:53:52 2022 +0200 @@ -1,6 +1,7 @@ -# automagically generated by the project definition -# this file is needed for stc to be able to compile modules independently. -# it provides information about a classes filename, category and especially namespace. -EditFieldTests EditFieldTests stx:libwidg/tests 'Views-Basic-Tests' 1 -stx_libwidg_tests stx_libwidg_tests stx:libwidg/tests '* Projects & Packages *' 3 -EditTextViewTests EditTextViewTests stx:libwidg/tests 'Views-Text-Tests' 1 +# automagically generated by the project definition +# this file is needed for stc to be able to compile modules independently. +# it provides information about a classes filename, category and especially namespace. +EditFieldTests EditFieldTests stx:libwidg/tests 'Views-Basic-Tests' 1 +FontPanelTests FontPanelTests stx:libwidg/tests 'Views-Text-Tests' 1 +stx_libwidg_tests stx_libwidg_tests stx:libwidg/tests '* Projects & Packages *' 3 +EditTextViewTests EditTextViewTests stx:libwidg/tests 'Views-Text-Tests' 1 diff -r ca73e0f717dc -r 98caa7f380f7 tests/bc.mak --- a/tests/bc.mak Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/bc.mak Wed Jun 08 13:53:52 2022 +0200 @@ -1,87 +1,88 @@ -# $Header$ -# -# DO NOT EDIT -# automagically generated from the projectDefinition: stx_libwidg_tests. -# -# Warning: once you modify this file, do not rerun -# stmkmp or projectDefinition-build again - otherwise, your changes are lost. -# -# Notice, that the name bc.mak is historical (from times, when only borland c was supported). -# This file contains make rules for the win32 platform using either borland-bcc or visual-c. -# It shares common definitions with the unix-make in Make.spec. -# The bc.mak supports the following targets: -# bmake - compile all st-files to a classLib (dll) -# bmake clean - clean all temp files -# bmake clobber - clean all -# -# Historic Note: -# this used to contain only rules to make with borland -# (called via bmake, by "make.exe -f bc.mak") -# this has changed; it is now also possible to build using microsoft visual c -# (called via vcmake, by "make.exe -f bc.mak -DUSEVC") -# -TOP=..\.. -INCLUDE_TOP=$(TOP)\.. - - - -!INCLUDE $(TOP)\rules\stdHeader_bc - -!INCLUDE Make.spec - -LIBNAME=libstx_libwidg_tests -MODULE_PATH=libwidg\tests -RESFILES=stx_libwidg_testsWINrc.$(RES) - - - -LOCALINCLUDES= -I$(INCLUDE_TOP)\stx\goodies\sunit -I$(INCLUDE_TOP)\stx\libbasic -I$(INCLUDE_TOP)\stx\libview -I$(INCLUDE_TOP)\stx\libwidg -LOCALDEFINES= - -STCLOCALOPT=-package=$(PACKAGE) -I. $(LOCALINCLUDES) -headerDir=. $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALDEFINES) -varPrefix=$(LIBNAME) -LOCALLIBS= - -OBJS= $(COMMON_OBJS) $(WIN32_OBJS) - -ALL:: classLibRule - -classLibRule: $(OUTDIR) $(OUTDIR)$(LIBNAME).dll - -!INCLUDE $(TOP)\rules\stdRules_bc - -# build all mandatory prerequisite packages (containing superclasses) for this package -prereq: - pushd ..\..\libbasic & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - pushd ..\..\libbasic2 & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - pushd ..\..\libview & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - pushd ..\..\libview2 & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - pushd ..\..\goodies\sunit & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " - - - - - - - -test: $(TOP)\goodies\builder\reports - pushd $(TOP)\goodies\builder\reports & $(MAKE_BAT) - $(TOP)\goodies\builder\reports\report-runner.bat -D . -r Builder::TestReport -p $(PACKAGE) - -clean:: - -del *.$(CSUFFIX) - - -# BEGINMAKEDEPEND --- do not remove this line; make depend needs it -$(OUTDIR)EditFieldTests.$(O) EditFieldTests.$(C) EditFieldTests.$(H): EditFieldTests.st $(INCLUDE_TOP)\stx\goodies\sunit\TestAsserter.$(H) $(INCLUDE_TOP)\stx\goodies\sunit\TestCase.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) -$(OUTDIR)stx_libwidg_tests.$(O) stx_libwidg_tests.$(C) stx_libwidg_tests.$(H): stx_libwidg_tests.st $(INCLUDE_TOP)\stx\libbasic\LibraryDefinition.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(INCLUDE_TOP)\stx\libbasic\ProjectDefinition.$(H) $(STCHDR) - -# ENDMAKEDEPEND --- do not remove this line - -# **Must be at end** - -# Enforce recompilation of package definition class if Mercurial working -# copy state changes. Together with --guessVersion it ensures that package -# definition class always contains correct binary revision string. -!IFDEF HGROOT -$(OUTDIR)stx_libwidg_tests.$(O): $(HGROOT)\.hg\dirstate -!ENDIF +# $Header$ +# +# DO NOT EDIT +# automagically generated from the projectDefinition: stx_libwidg_tests. +# +# Warning: once you modify this file, do not rerun +# stmkmp or projectDefinition-build again - otherwise, your changes are lost. +# +# Notice, that the name bc.mak is historical (from times, when only borland c was supported). +# This file contains make rules for the win32 platform using either borland-bcc or visual-c. +# It shares common definitions with the unix-make in Make.spec. +# The bc.mak supports the following targets: +# bmake - compile all st-files to a classLib (dll) +# bmake clean - clean all temp files +# bmake clobber - clean all +# +# Historic Note: +# this used to contain only rules to make with borland +# (called via bmake, by "make.exe -f bc.mak") +# this has changed; it is now also possible to build using microsoft visual c +# (called via vcmake, by "make.exe -f bc.mak -DUSEVC") +# +TOP=..\.. +INCLUDE_TOP=$(TOP)\.. + + + +!INCLUDE $(TOP)\rules\stdHeader_bc + +!INCLUDE Make.spec + +LIBNAME=libstx_libwidg_tests +MODULE_PATH=libwidg\tests +RESFILES=stx_libwidg_testsWINrc.$(RES) + + + +LOCALINCLUDES= -I$(INCLUDE_TOP)\stx\goodies\sunit -I$(INCLUDE_TOP)\stx\libbasic -I$(INCLUDE_TOP)\stx\libbasic3 -I$(INCLUDE_TOP)\stx\libview -I$(INCLUDE_TOP)\stx\libwidg +LOCALDEFINES= + +STCLOCALOPT=-package=$(PACKAGE) -I. $(LOCALINCLUDES) -headerDir=. $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALDEFINES) -varPrefix=$(LIBNAME) +LOCALLIBS= + +OBJS= $(COMMON_OBJS) $(WIN32_OBJS) + +ALL:: classLibRule + +classLibRule: $(OUTDIR) $(OUTDIR)$(LIBNAME).dll + +!INCLUDE $(TOP)\rules\stdRules_bc + +# build all mandatory prerequisite packages (containing superclasses) for this package +prereq: + pushd ..\..\libbasic & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + pushd ..\..\libbasic2 & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + pushd ..\..\libview & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + pushd ..\..\libview2 & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + pushd ..\..\goodies\sunit & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) " + + + + + + + +test: $(TOP)\goodies\builder\reports + pushd $(TOP)\goodies\builder\reports & $(MAKE_BAT) + $(TOP)\goodies\builder\reports\report-runner.bat -D . -r Builder::TestReport -p $(PACKAGE) + +clean:: + -del *.$(CSUFFIX) + + +# BEGINMAKEDEPEND --- do not remove this line; make depend needs it +$(OUTDIR)EditFieldTests.$(O) EditFieldTests.$(C) EditFieldTests.$(H): EditFieldTests.st $(INCLUDE_TOP)\stx\goodies\sunit\TestAsserter.$(H) $(INCLUDE_TOP)\stx\goodies\sunit\TestCase.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) +$(OUTDIR)FontPanelTests.$(O) FontPanelTests.$(C) FontPanelTests.$(H): FontPanelTests.st $(INCLUDE_TOP)\stx\goodies\sunit\TestAsserter.$(H) $(INCLUDE_TOP)\stx\goodies\sunit\TestCase.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) +$(OUTDIR)stx_libwidg_tests.$(O) stx_libwidg_tests.$(C) stx_libwidg_tests.$(H): stx_libwidg_tests.st $(INCLUDE_TOP)\stx\libbasic\LibraryDefinition.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(INCLUDE_TOP)\stx\libbasic\ProjectDefinition.$(H) $(STCHDR) + +# ENDMAKEDEPEND --- do not remove this line + +# **Must be at end** + +# Enforce recompilation of package definition class if Mercurial working +# copy state changes. Together with --guessVersion it ensures that package +# definition class always contains correct binary revision string. +!IFDEF HGROOT +$(OUTDIR)stx_libwidg_tests.$(O): $(HGROOT)\.hg\dirstate +!ENDIF diff -r ca73e0f717dc -r 98caa7f380f7 tests/bmake.bat --- a/tests/bmake.bat Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/bmake.bat Wed Jun 08 13:53:52 2022 +0200 @@ -1,15 +1,15 @@ -@REM ------- -@REM make using Borland bcc32 -@REM type bmake, and wait... -@REM do not edit - automatically generated from ProjectDefinition -@REM ------- -@SET DEFINES= -@REM Kludge got Mercurial, cannot be implemented in Borland make -@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i -@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" - -make.exe -N -f bc.mak %DEFINES% %* - - - - +@REM ------- +@REM make using Borland bcc32 +@REM type bmake, and wait... +@REM do not edit - automatically generated from ProjectDefinition +@REM ------- +@SET DEFINES= +@REM Kludge got Mercurial, cannot be implemented in Borland make +@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i +@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" + +make.exe -N -f bc.mak %DEFINES% %* + + + + diff -r ca73e0f717dc -r 98caa7f380f7 tests/libInit.cc --- a/tests/libInit.cc Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/libInit.cc Wed Jun 08 13:53:52 2022 +0200 @@ -1,40 +1,42 @@ -/* - * $Header$ - * - * DO NOT EDIT - * automagically generated from the projectDefinition: stx_libwidg_tests. - */ -#define __INDIRECTVMINITCALLS__ -#include - -#ifdef WIN32 -# pragma codeseg INITCODE "INITCODE" -#endif - -#if defined(INIT_TEXT_SECTION) || defined(DLL_EXPORT) -DLL_EXPORT void _libstx_libwidg_tests_Init() INIT_TEXT_SECTION; -DLL_EXPORT void _libstx_libwidg_tests_InitDefinition() INIT_TEXT_SECTION; -#endif - -extern void _EditFieldTests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd); -extern void _stx_137libwidg_137tests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd); - - - -void _libstx_libwidg_tests_InitDefinition(int pass, struct __vmData__ *__pRT__, OBJ snd) -{ - __BEGIN_PACKAGE2__("libstx_libwidg_tests__DFN", _libstx_libwidg_tests_InitDefinition, "stx:libwidg/tests"); - _stx_137libwidg_137tests_Init(pass,__pRT__,snd); - - __END_PACKAGE__(); -} - -void _libstx_libwidg_tests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd) -{ - __BEGIN_PACKAGE2__("libstx_libwidg_tests", _libstx_libwidg_tests_Init, "stx:libwidg/tests"); - _EditFieldTests_Init(pass,__pRT__,snd); - _stx_137libwidg_137tests_Init(pass,__pRT__,snd); - - - __END_PACKAGE__(); -} +/* + * $Header$ + * + * DO NOT EDIT + * automagically generated from the projectDefinition: stx_libwidg_tests. + */ +#define __INDIRECTVMINITCALLS__ +#include + +#ifdef WIN32 +# pragma codeseg INITCODE "INITCODE" +#endif + +#if defined(INIT_TEXT_SECTION) || defined(DLL_EXPORT) +DLL_EXPORT void _libstx_libwidg_tests_Init() INIT_TEXT_SECTION; +DLL_EXPORT void _libstx_libwidg_tests_InitDefinition() INIT_TEXT_SECTION; +#endif + +extern void _EditFieldTests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd); +extern void _FontPanelTests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd); +extern void _stx_137libwidg_137tests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd); + + + +void _libstx_libwidg_tests_InitDefinition(int pass, struct __vmData__ *__pRT__, OBJ snd) +{ + __BEGIN_PACKAGE2__("libstx_libwidg_tests__DFN", _libstx_libwidg_tests_InitDefinition, "stx:libwidg/tests"); + _stx_137libwidg_137tests_Init(pass,__pRT__,snd); + + __END_PACKAGE__(); +} + +void _libstx_libwidg_tests_Init(int pass, struct __vmData__ *__pRT__, OBJ snd) +{ + __BEGIN_PACKAGE2__("libstx_libwidg_tests", _libstx_libwidg_tests_Init, "stx:libwidg/tests"); + _EditFieldTests_Init(pass,__pRT__,snd); + _FontPanelTests_Init(pass,__pRT__,snd); + _stx_137libwidg_137tests_Init(pass,__pRT__,snd); + + + __END_PACKAGE__(); +} diff -r ca73e0f717dc -r 98caa7f380f7 tests/mingwmake.bat --- a/tests/mingwmake.bat Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/mingwmake.bat Wed Jun 08 13:53:52 2022 +0200 @@ -1,18 +1,18 @@ -@REM ------- -@REM make using mingw gnu compiler -@REM type mingwmake, and wait... -@REM do not edit - automatically generated from ProjectDefinition -@REM ------- -@SET DEFINES= -@REM Kludge got Mercurial, cannot be implemented in Borland make -@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i -@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" - -@pushd ..\..\rules -@call find_mingw.bat -@popd -make.exe -N -f bc.mak %DEFINES% %USEMINGW_ARG% %* - - - - +@REM ------- +@REM make using mingw gnu compiler +@REM type mingwmake, and wait... +@REM do not edit - automatically generated from ProjectDefinition +@REM ------- +@SET DEFINES= +@REM Kludge got Mercurial, cannot be implemented in Borland make +@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i +@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" + +@pushd ..\..\rules +@call find_mingw.bat +@popd +make.exe -N -f bc.mak %DEFINES% %USEMINGW_ARG% %* + + + + diff -r ca73e0f717dc -r 98caa7f380f7 tests/stx_libwidg_tests.st --- a/tests/stx_libwidg_tests.st Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/stx_libwidg_tests.st Wed Jun 08 13:53:52 2022 +0200 @@ -76,7 +76,8 @@ Please also take a look at the #mandatoryPreRequisites method" ^ #( - #'stx:libview' "Image - referenced by EditFieldTests>>test_issue_261a" + #'stx:libbasic3' "MessageTracer - referenced by EditTextViewTests>>setUp" + #'stx:libview' "Font - referenced by FontPanelTests>>testFontPanelInit" #'stx:libwidg' "EditField - referenced by EditFieldTests>>setUp" ) ! @@ -102,6 +103,7 @@ ^ #( " or ( attributes...) in load order" EditFieldTests + FontPanelTests #'stx_libwidg_tests' (EditTextViewTests autoload) ) diff -r ca73e0f717dc -r 98caa7f380f7 tests/vcmake.bat --- a/tests/vcmake.bat Wed Jun 08 10:30:56 2022 +0200 +++ b/tests/vcmake.bat Wed Jun 08 13:53:52 2022 +0200 @@ -1,22 +1,22 @@ -@REM ------- -@REM make using Microsoft Visual C compiler -@REM type vcmake, and wait... -@REM do not edit - automatically generated from ProjectDefinition -@REM ------- - -@if not defined VSINSTALLDIR ( - pushd ..\..\rules - call vcsetup.bat - popd -) -@SET DEFINES= -@REM Kludge got Mercurial, cannot be implemented in Borland make -@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i -@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" - - -make.exe -N -f bc.mak -DUSEVC=1 %DEFINES% %* - - - - +@REM ------- +@REM make using Microsoft Visual C compiler +@REM type vcmake, and wait... +@REM do not edit - automatically generated from ProjectDefinition +@REM ------- + +@if not defined VSINSTALLDIR ( + pushd ..\..\rules + call vcsetup.bat + popd +) +@SET DEFINES= +@REM Kludge got Mercurial, cannot be implemented in Borland make +@FOR /F "tokens=*" %%i in ('hg root') do SET HGROOT=%%i +@IF "%HGROOT%" NEQ "" SET DEFINES=%DEFINES% "-DHGROOT=%HGROOT%" + + +make.exe -N -f bc.mak -DUSEVC=1 %DEFINES% %* + + + +