[Pkg] Rio: Rio-Test-kph.50.mcz
squeak-dev-noreply at lists.squeakfoundation.org
squeak-dev-noreply at lists.squeakfoundation.org
Mon Nov 10 17:01:04 UTC 2008
A new version of Rio-Test was added to project Rio:
http://www.squeaksource.com/Rio/Rio-Test-kph.50.mcz
==================== Summary ====================
Name: Rio-Test-kph.50
Author: kph
Time: 10 November 2008, 5:01:02 pm
UUID: 897857b0-91f5-4173-a1d2-3f76cdf7f757
Ancestors: Rio-Test-kph.49
Re-architected to be cleaner, remove dnus etc
=============== Diff against Rio-Test-kph.49 ===============
Item was changed:
----- Method: RioVirtualTestFSDos>>rioClass (in category 'as yet unclassified') -----
rioClass
+ ^ Notification signal!
- ^ Smalltalk at: rioClass!
Item was changed:
----- Method: RioArchiveTest>>archiveContents (in category 'tests-archive') -----
archiveContents
| all |
self makeArchive.
self assert: (archive zip entries asSet = (Set with: (Rio new: 'testing_rio'))).
all := archive zip all entries.
self assert: (all asSet =
{ (Rio new: 'testing_rio').
+ (Rio new: 'testing_rio/t_a/f 1').
+ (Rio new: 'testing_rio/t_a/t 1').
- (Rio new: 'testing_rio/t_a/f_1').
- (Rio new: 'testing_rio/t_a/t_1').
(Rio new: 'testing_rio/t_a/t_2'). } asArray asOrderedCollection asSet).
self assert: (all first isDirectory).
self assert: (all second isFile).
!
Item was changed:
----- Method: RioGzipTest>>gzipWriteAndRead (in category 'tests') -----
gzipWriteAndRead
self assert: (self fox size = 44).
+ rio := (self useTestDir / 'zip.gz') gzip writer: [ :out | out << self fox ].
- rio := (self useTestDir / 'zip.gz') gzip writer: [ :out | out << self testString ].
self assert: (rio isFile & rio fileSize = 62).
"reading from a gzip file should honour the binary setting of the stream even though the actual on disk file is binary"
+ self assert: ( rio contents = self fox ).
- self assert: ( rio contents = self testString ).
self assert: ( rio contents size = 44 ).
!
Item was changed:
+ RioLocalExecutive subclass: #RioVirtualTestFSUnix
+ instanceVariableNames: ''
- RioLocalFileSystem subclass: #RioVirtualTestFSUnix
- instanceVariableNames: 'rioClass'
classVariableNames: ''
poolDictionaries: ''
category: 'Rio-Test'!
Item was added:
+ ----- Method: RioVirtualFSCommonTest>>runCaseWith: (in category 'as yet unclassified') -----
+ runCaseWith: aBlock
+
+ aBlock on: Notification do: [ :ex | ex resume: rioClass ]!
Item was added:
+ ----- Method: RioVirtualTestFSUnix>>initialize (in category 'as yet unclassified') -----
+ initialize
+
+ self initializeDefault!
Item was changed:
----- Method: RioCaseInsensitiveTest>>setOfRios (in category 'tests') -----
setOfRios
rio := Set new.
rio
+ add: ( (Rio new: 'hello') executive: (RioLocalCaseInsensitiveExecutive new) ).
- add: ( (Rio new: 'hello') executive: (RioLocalCaseInsensitiveFileSystem new) ).
self assert: rio size = 1.
rio
+ add: ((Rio new: 'heLLo') executive: (RioLocalCaseInsensitiveExecutive new) ).
- add: ((Rio new: 'heLLo') executive: (RioLocalCaseInsensitiveFileSystem new) ).
self assert: rio size = 1!
Item was changed:
----- Method: RioDirTest>>addTree (in category 'tests-directory copying') -----
addTree
self makeDirectoriesAndFiles.
destDir mkdir addTree: testDir.
self assert: (destDir all entries size = 5).
self assert: ((testDir / 't_a' / 'f 1') contents = 'test file').
self assert: ((destDir / 'testing_rio'/ 't_a' / 'f 1') contents = 'test file').!
Item was changed:
----- Method: RioVirtualFSDosKernelTest>>setUp (in category 'fixture') -----
setUp
- RioLocalFileSystem testFileSystem: RioVirtualTestFSDos newUsingRioKernel.
-
rioClass := RioKernel.
+
+ RioLocalExecutive testFileSystem: RioVirtualTestFSDos new.
+
!
Item was changed:
----- Method: RioModeTests>>testBinaryModes (in category 'binary mode') -----
testBinaryModes
rio := self useTestDir / self hello.
self deny: (rio binary == rio).
+ self assert: (rio beBinary == rio).
- self assert: (rio setModeToBinary == rio).
!
Item was changed:
----- Method: RioKernelTest>>rootIsDirectory (in category 'tests-standard') -----
rootIsDirectory
+ rio := rioClass new: RioLocalExecutive current root value.
- rio := rioClass new: RioLocalFileSystem current root value.
self assert: (rio isRoot).
self assert: (rio isDirectory).
!
Item was changed:
----- Method: RioVirtualFSCommonTest>>currentFileSystem (in category 'fixtures') -----
currentFileSystem
+ ^ RioLocalExecutive current!
- ^ RioLocalFileSystem current!
Item was added:
+ ----- Method: RioVirtualTestFSDos>>initialize (in category 'as yet unclassified') -----
+ initialize
+
+ self initializeDefault!
Item was changed:
----- Method: RioVirtualTestFSUnix>>rioClass (in category 'as yet unclassified') -----
rioClass
+ ^ Notification signal!
- ^ Smalltalk at: rioClass!
Item was changed:
----- Method: RioTest>>http (in category 'tests') -----
http
rio := Rio new: 'http://www.google.com'.
+ self assert: rio class = Rio.
+ self assert: rio executive class = RioHttpExecutive!
- self assert: rio class = RioHttp!
Item was changed:
----- Method: RioVirtualFSUnixKernelTest>>setUp (in category 'fixture') -----
setUp
+
+ rioClass := RioKernel.
+ RioLocalExecutive testFileSystem: RioVirtualTestFSUnix new.
-
- RioLocalFileSystem testFileSystem: RioVirtualTestFSUnix newUsingRioKernel.
+ !
- rioClass := RioKernel.!
Item was changed:
+ RioLocalDosExecutive subclass: #RioVirtualTestFSDos
+ instanceVariableNames: ''
- RioLocalDosFileSystem subclass: #RioVirtualTestFSDos
- instanceVariableNames: 'rioClass'
classVariableNames: ''
poolDictionaries: ''
category: 'Rio-Test'!
Item was changed:
----- Method: RioGzipTest>>gzipWriteAndReadBinary (in category 'tests') -----
gzipWriteAndReadBinary
self assert: (self fox size = 44).
+ rio := (self useTestDir / 'zip.gz') gzip beBinary writer: [ :out | out << self fox asByteArray ].
- rio := (self useTestDir / 'zip.gz') gzip setModeToBinary writer: [ :out | out << self testString asByteArray ].
self assert: (rio isFile & rio fileSize = 62).
+ self assert: ( rio beBinary contents = self fox asByteArray ).
- self assert: ( rio setModeToBinary contents = self testString asByteArray ).
+ self assert: ( rio beBinary contents size = 44 ).!
- self assert: ( rio setModeToBinary contents size = 44 ).!
Item was changed:
----- Method: RioModeTests>>testGzipModes (in category 'binary mode') -----
testGzipModes
rio := self useTestDir / self hello.
self deny: (rio gzip == rio).
+
- self assert: (rio setModeToGzip == rio).
!
Item was changed:
----- Method: RioModeTests>>testRenamingModes (in category 'renaming mode') -----
testRenamingModes
rio := self useTestDir / self hello.
self deny: (rio rename == rio).
+ self assert: (rio beRenaming == rio).
- self assert: (rio setModeToRenaming == rio).
!
Item was changed:
----- Method: RioVirtualFSDosRioTest>>setUp (in category 'fixture') -----
setUp
+
+ rioClass := Rio.
+ RioLocalExecutive testFileSystem: RioVirtualTestFSDos new.
+
+ !
- RioVirtualTestFSDos newUsingRio.
- rioClass := Rio.!
Item was changed:
----- Method: RioVirtualFSCommonTest>>tearDown (in category 'fixtures') -----
tearDown
+ RioLocalExecutive testEnd!
- RioLocalFileSystem testEnd!
Item was changed:
----- Method: RioVirtualFSUnixRioTest>>setUp (in category 'fixture') -----
setUp
+
+ rioClass := Rio.
+ RioLocalExecutive testFileSystem: RioVirtualTestFSUnix new.
- RioLocalFileSystem testFileSystem: RioVirtualTestFSUnix newUsingRio.
+ !
- rioClass := Rio.!
Item was changed:
----- Method: RioTest>>ftp (in category 'tests') -----
ftp
rio := Rio new: 'ftp://ftp.seasidehosting.st'.
+ self assert: rio class = Rio.
+ self assert: rio executive class = RioFtpExecutive.!
- self assert: rio class = RioFtp!
Item was removed:
- ----- Method: RioVirtualTestFSDos class>>newUsingRioKernel (in category 'as yet unclassified') -----
- newUsingRioKernel
-
- ^ (RioLocalFileSystem testFileSystem: self new useRioKernel)
- initializeDefault;
- yourself!
Item was removed:
- ----- Method: RioVirtualTestFSUnix class>>newUsingRio (in category 'as yet unclassified') -----
- newUsingRio
-
- ^ (RioLocalFileSystem testFileSystem: self new useRio)
- initializeDefault;
- yourself!
Item was removed:
- ----- Method: RioVirtualTestFSDos>>useRio (in category 'as yet unclassified') -----
- useRio
-
- rioClass := #Rio !
Item was removed:
- ----- Method: RioVirtualTestFSDos class>>newUsingRio (in category 'as yet unclassified') -----
- newUsingRio
-
- ^ (RioLocalFileSystem testFileSystem: self new useRio)
- initializeDefault;
- yourself!
Item was removed:
- ----- Method: RioVirtualTestFSUnix class>>newUsingRioKernel (in category 'as yet unclassified') -----
- newUsingRioKernel
-
- ^ (RioLocalFileSystem testFileSystem: self new useRioKernel)
- initializeDefault;
- yourself!
Item was removed:
- ----- Method: RioVirtualTestFSDos>>useRioKernel (in category 'as yet unclassified') -----
- useRioKernel
-
- rioClass := #RioKernel!
Item was removed:
- ----- Method: RioVirtualTestFSUnix>>useRio (in category 'as yet unclassified') -----
- useRio
-
- rioClass := #Rio !
Item was removed:
- ----- Method: RioVirtualTestFSUnix>>useRioKernel (in category 'as yet unclassified') -----
- useRioKernel
-
- rioClass := #RioKernel!
More information about the Packages
mailing list