Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #37831

Re: Calling deprecated methods

Path csiph.com!news.swapon.de!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From Eric Sosman <esosman@comcast-dot-net.invalid>
Newsgroups comp.lang.java.programmer
Subject Re: Calling deprecated methods
Date Tue, 12 Dec 2017 17:57:07 -0500
Organization A noiseless patient Spider
Lines 26
Message-ID <p0pms6$4o2$1@dont-email.me> (permalink)
References <b1215ae8-2a70-4220-b98a-6d25088c5ae6@googlegroups.com> <p0p09n$fed$1@news.albasani.net> <9db47be9-1c38-48a9-bad9-9799f54df59a@googlegroups.com> <p0pcpd$j65$1@news.albasani.net> <p0peu7$cd4$1@dont-email.me> <p0pg91$b3f$1@news.albasani.net> <c0757a6b-fed6-4ee8-b75d-e6b220bfa894@googlegroups.com> <p0plu3$tqm$1@news.albasani.net>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding 7bit
Injection-Date Tue, 12 Dec 2017 22:57:10 -0000 (UTC)
Injection-Info reader02.eternal-september.org; posting-host="ec17ec02168981cce4dacdac14a84254"; logging-data="4866"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19ZZEyUPopjYtvtDJrIecS1"
User-Agent Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0
In-Reply-To <p0plu3$tqm$1@news.albasani.net>
Content-Language en-US
Cancel-Lock sha1:IjAkdyJgcKl1amws7wvRBxToFg8=
Xref csiph.com comp.lang.java.programmer:37831

Show key headers only | View raw


On 12/12/2017 5:41 PM, Kiwi User wrote:
> On Tue, 12 Dec 2017 13:33:06 -0800, Eric Douglas wrote:
> 
>> I currently work for a small business, so not a lot of time to waste
>> writing tests that can guarantee every enhancement won't break any
>> existing code much less comment blocks, when we have a dozen big
>> enhancement requests and 2 developers.
>>
> If a class is largely getters and setters and its other methods for
> linear things, then you're right.

     ... or mostly right.  A setter that is supposed to enforce a
restriction like "the value must be strictly positive" should be
tested to ensure that it does in fact throw the proper exception.
Similarly for setters with state dependencies like "the value can
be changed at will before the doItNowBabe() method is called, but
cannot be changed thereafter."

> [... good advice about test harnesses ...]
> Been there, done that, got the benefits.

     Ditto, seconded, and Aayy-men!

-- 
esosman@comcast-dot-net.invalid
Eleven hundred thirty-five days to go.

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-12 08:09 -0800
  Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-12 16:31 +0000
    Re: Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-12 10:24 -0800
      Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-12 20:05 +0000
        Re: Calling deprecated methods Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-12-12 15:41 -0500
          Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-12 21:04 +0000
            Re: Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-12 13:33 -0800
              Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-12 22:41 +0000
                Re: Calling deprecated methods Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-12-12 17:57 -0500
                Re: Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-13 04:51 -0800
                Re: Calling deprecated methods Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-12-13 08:21 -0500
                Re: Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-13 05:40 -0800
                Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-13 15:19 +0000
                Re: Calling deprecated methods Eric Douglas <e.d.programmer@gmail.com> - 2017-12-13 07:57 -0800
                Re: Calling deprecated methods Kiwi User <martin@mydomain.invalid> - 2017-12-13 17:30 +0000

csiph-web