public inbox for gentoo-portage-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: Jason Stubbs <jasonbstubbs@mailandnews.com>
To: gentoo-portage-dev@gentoo.org
Subject: [gentoo-portage-dev] Portage Modularisation
Date: Thu, 27 Nov 2003 18:07:44 +0900	[thread overview]
Message-ID: <200311271807.45306.jasonbstubbs@mailandnews.com> (raw)
In-Reply-To: <20031127084244.GA29988@unm.edu>

On Thursday 27 November 2003 17:42, Jason Mobarak wrote:
> On 17:03 Thu 27 Nov     , Jason Stubbs wrote:
> > Okay, so the unit tests are more for the separation of portage rather
> > than the> documentation of it. I did a little search on the definition of
> > unit test and found "Controlled evaluation performed by a system
> > programmer in the Development step to ensure that a piece of program code
> > performs as defined in the specification". Hence, my question. Now, I
> > understand what you want.
>
> To define unit tests with more precision I'll give a portage example --
> carpaski changes massive amounts of global variables, moving them around so
> that the portage module isn't dependant on modifying globals (which is a
> *very* *very* bad practice in python, you should always know where
> variables are being modified and not have "procedures" that modify stuff in
> the global namespace, or any other namespace except the most immediate one
> -- saves headaches and makes for saner code). These changes to reliance on
> globals variables has the potential of breaking many facets of portage the
> API, so you need a set of tests that spans across all of portage and
> effectively tests everything for proper behaviour, if a failure is
> encounter it can be quickly located and diagnosed.
>
> Somethings you need to do to get up to speed on unit tests:
>
> 1) Read the documentation for the unittest module in the Python standard
> library.
> 2) Read http://pyunit.sourceforge.net/pyunit.html
> 3) Get a CVS CO of Twistedmatrix.com's CVS and look over how they do there
> unit tests, they use their own implementation of unittest but the
> differences are minor

Will research up on that.

> > I can checkout your module by CVS daily and then send you patches if you
> > like.
>
> This is kind of going to be PITA, we need CVS, sometime in the future I'll
> find out if we can get you a developer account, but for the time being if
> you have a dedicated server that you can set up CVS on that'd be great,
> otherwise I can set you up with an account on my machine
> (shamash.eece.unm.edu) which is on a university network and "always on and
> reliable". Shamash has CVS and we can set up a portage module on there and
> I'll do regular commits of our combined changes to gentoo-src.

I have a machine that is always on and connected but is not publicly 
accessible. If you could set that up with shamash that would be great.

> > b) You document and separate and I unit test what has been completed.
>
> I like (b),

Okay. Will research unit tests quicker. ;-)

> > BTW, will this work become redundant by portage-ng?
>
> I hope after portage is separated into a library the code can be
> incorporated into "portage-ng", we could very well be working on the
> beginnings of the next generation of portage. I want to add "layers" to how
> everything interacts, key design patterns being heavy focusing on "plug-in"
> orientation and
> model-view-control. Some keywords you should research if you are interested
> in this are Mix-In style programming and the use of interfaces to abstract
> aggregate interaction between sections of a program.
>
> "Portage-ng" is being touted as a complete rewrite currently (from what I
> remember) and it seems senseless to throw away the 10k lines of code that
> make up the current portage system.

That's good to hear. Otherwise would be a bit demotivating...

> Also, please subscribe to the "gentoo-portage-dev" mailing list. I am going
> to CC this message to the mailing list.

Was already there. Even without a role in the development, I still like to 
know what's going on. ;-)

Regards,
Jason Stubbs

--
gentoo-portage-dev@gentoo.org mailing list


  reply	other threads:[~2003-11-27  9:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1069588805.28236.17.camel@antares.hausnetz>
     [not found] ` <200311271548.01028.jasonbstubbs@mailandnews.com>
     [not found]   ` <20031127065907.GA28671@unm.edu>
     [not found]     ` <200311271703.47562.jasonbstubbs@mailandnews.com>
2003-11-27  8:42       ` [gentoo-portage-dev] Re: [gentoo-dev] Web-based Portage Frontendg Jason Mobarak
2003-11-27  9:07         ` Jason Stubbs [this message]
2003-11-29 14:46         ` Jason Stubbs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200311271807.45306.jasonbstubbs@mailandnews.com \
    --to=jasonbstubbs@mailandnews.com \
    --cc=gentoo-portage-dev@gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox