[Pharo-project] FileReference should throw error when deleting unexisting files?
Mariano Martinez Peck
marianopeck at gmail.com
Tue Jun 12 03:49:40 EDT 2012
Hi Stef. It looks we are minority. So today I will:
- add #testExists (becuase it was broken but no test)
- add #ensureDeleted
- add #testEnsureDeleted
- fix FileSystemHandleTest >> tearDown to #ensureDeleted the reference.
On Tue, Jun 12, 2012 at 7:25 AM, Stéphane Ducasse <stephane.ducasse at inria.fr
> Yes to me ensureDelete or ensureDeleted is not explicit enough. I prefer
> On Jun 12, 2012, at 1:41 AM, Schwab,Wilhelm K wrote:
> > I generally default to saying "of course there should be an error." I
> much prefer to get my bad news early rather than having to fish around or
> it after the fact. Toward that end, I would recommend having
> #deleteIfAbsent: and #delete that provides an error-raising block and
> forwards to #deleteifAbsent:. That is consistent with collections, which
> are not a bad model/source-of-inspiration for managing directory contents.
> > Having #ensureDeleted in addition to above does no real harm. I would
> prefer that the selector start with "delete" so it appears close to the
> other methods in browsers, even w/o category filtering - makes it more
> > Just my 2 asCents.
> > Bill
> > ________________________________________
> > From: pharo-project-bounces at lists.gforge.inria.fr [
> pharo-project-bounces at lists.gforge.inria.fr] on behalf of Chris
> Cunningham [cunningham.cb at gmail.com]
> > Sent: Monday, June 11, 2012 5:55 PM
> > To: Pharo-project at lists.gforge.inria.fr
> > Subject: Re: [Pharo-project] FileReference should throw error when
> deleting unexisting files?
> > On Mon, Jun 11, 2012 at 2:32 PM, <petton.nicolas at gmail.com> wrote:
> >> Maybe #ensureDeleted would be better?
> >> Nico
> > I like #ensureDeleted (make sure it doesn't exist)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Pharo-dev