<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
On 30/08/2010 18:32, Jones, Larry wrote:
<blockquote
cite="mid:E8096D1789BBDA489C4DA48FAC97563A02AFD17E@hqmail4.corp.aspentech.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft Word 12 (filtered
medium)">
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
span.EmailStyle17
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="Section1">
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);">Thanks,
Michael, for the
information. I copied the file unittest.py from my
IronPython 2.6 installation
to my IronPython 2.7 installation.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);">It
did seem to work, although
discovering that in 2.7 unittest is a directory containing a
number of other
files, was a bit disconcerting. I renamed the v2.7 unittest
directory (to
unittest.000) and then copied unittest.py from the
IronPython 2.6 installation.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);">I
greatly appreciate your help
on this.</span></p>
</div>
</blockquote>
<br>
In Python 2.6 unittest was a single file (unittest.py). In Python
2.7 it is a package (a directory containing several modules). The
unittest package in Python 2.7 is a lot more capable, but using the
Python 2.6 version of unittest.py will certainly work.<br>
<br>
All the best,<br>
<br>
Michael Foord<br>
<br>
<blockquote
cite="mid:E8096D1789BBDA489C4DA48FAC97563A02AFD17E@hqmail4.corp.aspentech.com"
type="cite">
<div class="Section1">
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
<div>
<div style="border-right: medium none; border-width: 1pt
medium medium; border-style: solid none none; border-color:
rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color;
padding: 3pt 0in 0in;">
<p class="MsoNormal"><b><span style="font-size: 10pt;
font-family:
"Tahoma","sans-serif"; color:
windowtext;">From:</span></b><span style="font-size:
10pt; font-family:
"Tahoma","sans-serif"; color:
windowtext;"> <a class="moz-txt-link-abbreviated" href="mailto:users-bounces@lists.ironpython.com">users-bounces@lists.ironpython.com</a>
[<a class="moz-txt-link-freetext" href="mailto:users-bounces@lists.ironpython.com">mailto:users-bounces@lists.ironpython.com</a>] <b>On
Behalf Of </b>Michael Foord<br>
<b>Sent:</b> Monday, August 30, 2010 9:33 AM<br>
<b>To:</b> Discussion of IronPython<br>
<b>Subject:</b> Re: [IronPython] Unittest Module
Unavailable in V2.7a1<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">On 30/08/2010 16:38, Jones, Larry wrote: <o:p></o:p></p>
<p class="MsoNormal">My team is currently using VS2010 for work.
I want to
demonstrate that using IronPython as our “unit testing
language”
can be more productive than using either NUnit or Microsoft
Test.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">In order to integrate with VS2010, I
believe I must use
IronPython 2.7a1. I believe this is the only release that
includes the
IronPython Tools. However, IronPython 2.7a1 fails when
executing ‘import
unittest’. I’ve submitted a work item, 28709, to the
IronPython
issue tracker; however, I’m wondering if another work around
exists then
writing code in 2.6.1 – which will execute outside VS2010 –
but
cannot be executed from within Visual Studio (it invoke
IronPython 2.7a1).<o:p></o:p></p>
<p class="MsoNormal"><span style="font-size: 12pt; font-family:
"Times New Roman","serif";"><br>
The IronPython team is aware of this problem, it was caused
by a 'bug' in the
tools that package the installer.<br>
<br>
A simple workaround (that will probably work) is to copy the
unittest package
from a CPython 2.7 installation into your IronPython Lib
directory. In
IronPython 2.7 the unittest package is missing some files.<br>
<br>
All the best,<br>
<br>
Michael Foord<br>
<br>
<br>
<br>
<br>
<o:p></o:p></span></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Thanks.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Have a great day!<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span style="font-size: 12pt; font-family:
"Times New Roman","serif";"><br>
******************************************************************
<br>
This e-mail and any attachments are intended only for use by
the addressee(s)
named herein and may contain legally privileged and/or
confidential
information. If you are not the intended recipient of this
e-mail, you are
hereby notified any dissemination, distribution or copying
of this email, and
any attachments thereto, is strictly prohibited. If you
receive this email in
error please immediately notify the sender and permanently
delete the original
copy and any copy of any e-mail, and any printout thereof. <o:p></o:p></span></p>
<pre><o:p> </o:p></pre>
<pre><o:p> </o:p></pre>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>Users mailing list<o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a><o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a><o:p></o:p></pre>
<p class="MsoNormal"><span style="font-size: 12pt; font-family:
"Times New Roman","serif";"><br>
<br>
<br>
<o:p></o:p></span></p>
<pre>-- <o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="http://www.ironpythoninaction.com/">http://www.ironpythoninaction.com/</a><o:p></o:p></pre>
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a>
<a class="moz-txt-link-freetext" href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
<a class="moz-txt-link-freetext" href="http://www.ironpythoninaction.com/">http://www.ironpythoninaction.com/</a></pre>
</body>
</html>