Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2750)

Issue 99670045: testing/testbase: remove

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 years, 10 months ago by rog
Modified:
9 years, 10 months ago
Reviewers:
wwitzel3, frankban, mp+221560
Visibility:
Public.

Description

testing/testbase: remove It's unnecessary - we move FindJujuCoreImports to testing (and make it call the less specific version in github.com/juju/testing). We temporarily lose the ability to change the logging level in tests, but that will be reinstated directly in LoggingSuite - it's not crucial behaviour. Eventually most tests will use testing.IsolationSuite, but in the meantime, add testing.CleanupSuite to those tests that need it. https://code.launchpad.net/~rogpeppe/juju-core/562-lose-testbase/+merge/221560 (do not edit description out of merge proposal)

Patch Set 1 #

Patch Set 2 : testing/testbase: remove #

Patch Set 3 : testing/testbase: remove #

Total comments: 18

Patch Set 4 : testing/testbase: remove #

Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -181 lines) Patch
A [revision details] View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M agent/tools/tools_test.go View 2 chunks +1 line, -2 lines 0 comments Download
M cmd/args_test.go View 1 chunk +2 lines, -2 lines 0 comments Download
M cmd/package_test.go View 2 chunks +6 lines, -5 lines 0 comments Download
M cmd/supercommand_test.go View 2 chunks +2 lines, -2 lines 0 comments Download
M dependencies.tsv View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M environs/sync/sync_test.go View 5 chunks +15 lines, -2 lines 0 comments Download
M juju/osenv/package_test.go View 1 2 chunks +2 lines, -2 lines 0 comments Download
M state/api/rsyslog/rsyslog_test.go View 1 1 chunk +1 line, -1 line 0 comments Download
M testing/base.go View 1 2 3 3 chunks +13 lines, -4 lines 0 comments Download
M testing/imports.go View 2 chunks +5 lines, -42 lines 0 comments Download
D testing/testbase/log.go View 1 2 1 chunk +0 lines, -39 lines 0 comments Download
D testing/testbase/log_test.go View 1 chunk +0 lines, -53 lines 0 comments Download
D testing/testbase/package_test.go View 1 chunk +0 lines, -26 lines 0 comments Download

Messages

Total messages: 8
rog
Please take a look.
9 years, 10 months ago (2014-05-30 15:01:18 UTC) #1
rog
Please take a look.
9 years, 10 months ago (2014-05-30 15:34:47 UTC) #2
frankban
Thanks for this branch Roger! LGTM with some minor/questions below. https://codereview.appspot.com/99670045/diff/40001/cmd/package_test.go File cmd/package_test.go (right): https://codereview.appspot.com/99670045/diff/40001/cmd/package_test.go#newcode26 ...
9 years, 10 months ago (2014-05-30 16:14:57 UTC) #3
rog
https://codereview.appspot.com/99670045/diff/40001/cmd/package_test.go File cmd/package_test.go (right): https://codereview.appspot.com/99670045/diff/40001/cmd/package_test.go#newcode26 cmd/package_test.go:26: jc.DeepEquals, On 2014/05/30 16:14:56, frankban wrote: > So I ...
9 years, 10 months ago (2014-05-30 16:19:41 UTC) #4
wwitzel3
My feeling is, I don't care where and how things are aliased, but it should ...
9 years, 10 months ago (2014-05-30 16:30:53 UTC) #5
wwitzel3
On 2014/05/30 16:30:53, wwitzel3 wrote: > My feeling is, I don't care where and how ...
9 years, 10 months ago (2014-05-30 16:31:46 UTC) #6
rog
On 30 May 2014 17:30, <wayne.witzel@canonical.com> wrote: > My feeling is, I don't care where ...
9 years, 10 months ago (2014-06-02 13:46:01 UTC) #7
rog
9 years, 10 months ago (2014-06-02 13:47:24 UTC) #8
Please take a look.

https://codereview.appspot.com/99670045/diff/40001/cmd/supercommand_test.go
File cmd/supercommand_test.go (right):

https://codereview.appspot.com/99670045/diff/40001/cmd/supercommand_test.go#n...
cmd/supercommand_test.go:16: "launchpad.net/juju-core/testing"
On 2014/05/30 16:30:52, wwitzel3 wrote:
> Why not alias this to coretesting?

The original rationale was that juju-core/testing feels "native" so earns the
right to be unaliased when reasonable. I've left it that way here to save churn,
although it could easily be coretesting too.

https://codereview.appspot.com/99670045/diff/40001/environs/sync/sync_test.go
File environs/sync/sync_test.go (right):

https://codereview.appspot.com/99670045/diff/40001/environs/sync/sync_test.go...
environs/sync/sync_test.go:15: "testing"
On 2014/05/30 16:30:52, wwitzel3 wrote:
> Same vein. Here we don't alias to stdtesting.

Yeah, conventionally we would alias to stdtesting here
(after all, the identifier is only used once)

https://codereview.appspot.com/99670045/diff/40001/testing/base.go
File testing/base.go (right):

https://codereview.appspot.com/99670045/diff/40001/testing/base.go#newcode33
testing/base.go:33: t.CleanupSuite.SetUpSuite(c)
On 2014/05/30 16:19:40, rog wrote:
> On 2014/05/30 16:14:57, frankban wrote:
> > In the Isolation suite we use the reversed order:
> > s.CleanupSuite.SetUpSuite(c)
> > s.LoggingSuite.SetUpSuite(c)
> > I don't think in this case it makes so much difference, but keeping them in
> sync
> > now can avoid some confusion in the future.
> > What do you think?
> > This also applies to sync_test.
> 
> sgtm, will do.

Done.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b