[BUG][FIX} Linux 2.8 VM running the Network Unit tests

Rob Withers slosher2 at home.com
Tue Jul 18 05:35:53 UTC 2000


I downloaded the Craig Latta's correspondents port from John's site and
I am trying to get them running in a rebuilt Linux VM with a 2.8 image. 
When running the tests, without flow and correspondents, I am getting
errors in the Resolver Tests (and the Socket tests, but I haven't
drilled deeper there yet).  At first I had a configuration problem with
my localHostName not having an address in my hosts file, but I got that
fixed.   I think there was a bug in one of the Resolver tests with a
misnamed host name.  I am attaching a proposed fix.

Then I got to the root of the three failed tests, in resolver:

NetworkResolverTest>>testAbortLookup
NetworkResolverTest>>testAddressForName
NetworkResolverTest>>testNameForAddress

In the last two, it is testing a badAddress/Name and the error code from
the Plugin is different than the Test is expecting.  The status is a 3,
which is correct, but the resolverError is a 1 where the test expects
-23045 or -3162.  I suppose we could look at the Mac plugin and the man
pages to find out the error codes.  Or we could code an error dictionary
for each platform (yuk!).  Is anyone working on this?

The first one is testing a 'working' situation, but it looks like a call
set an error.   I am not sure if checkStatusOK is the right thing here -
is it?

regards,
Rob


-- 
--------------------------------------------------
Smalltalking by choice.  Isn't it nice to have one!
-------------- next part --------------
'From Squeak2.8 of 16 July 2000 [latest update: #2348] on 17 July 2000 at 10:34:39 pm'!

!NetworkResolverTest methodsFor: 'testing' stamp: 'rww 7/17/2000 19:15'!
testNameForAddress
	| appleAddress |

	addressString _ self goodNameForAddress: ourLocalHostAddress timeout: self timeOutValue.
	self shouldnt: [addressString isNil].
	self checkStatusOk.

	address _ self goodAddressForName: addressString timeout: self timeOutValue.
	self should: [address = ourLocalHostAddress].
	self checkStatusOk.

	appleAddress _ self goodAddressForName: 'apple.com' timeout: self timeOutValue.
	self shouldnt: [appleAddress isNil].
	self checkStatusOk.

	addressString _ self goodNameForAddress: appleAddress timeout: self timeOutValue.
	self should: [addressString = 'apple.com'].
	self checkStatusOk.

	address _ self goodAddressForName: addressString timeout: self timeOutValue.
	self should: [address = appleAddress].
	self checkStatusOk.

	addressString _ self badNameForAddress: (NetNameResolver addressFromString: '1.2.3.4') timeout: self timeOutValue.
	self checkStatusAddressStringIsBad.
	! !



More information about the Squeak-dev mailing list