![](https://secure.gravatar.com/avatar/519d491fa9fe7dfd0caf0f0a9c2ca61e.jpg?s=120&d=mm&r=g)
Hi devs, I have an odd issue that I can’t seem to diagnose. I’m setting up an answer test for two arrays, which are not related to anything in a dataset. I’m doing it using the GenericArrayTest (it’s in the answer testing framework), which compares two NumPy arrays. Here’s my test—the way you get the arrays is immaterial, all you need to know is the stuff at the bottom where I’m comparing two NumPy arrays: http://paste.yt-project.org/show/5976/ <http://paste.yt-project.org/show/5976/> Here’s the error message I get: http://paste.yt-project.org/show/5977/ <http://paste.yt-project.org/show/5977/> I’ve looked into the answer testing code, but I can’t decipher why this is happening. This is under Python 2. Best, John
![](https://secure.gravatar.com/avatar/7857f26c1ef2e9bdbfa843f9087710f7.jpg?s=120&d=mm&r=g)
Hi John, I'm not sure. It looks like the reference_storage gets set up inside the plugin setup function, which *should* be called when you do the tests --with-answer-testing. Do you have an example nosetests invocation you are doing that triggers this error? Also, now that I look at it, it looks like the current uses of the GenericArrayTest in the test suite are not actually being run. Both the SZ answer tests and the photon simulator answer tests don't have a job on fido. I'd suggest you coordinate with Kacper to get that enabled... So that means the GenericArrayTests are not actually being used anywhere by anyone in the test suite. It's possible they have a bug... -Nathan On Wed, Oct 14, 2015 at 7:40 PM, John ZuHone <jzuhone@gmail.com> wrote:
Hi devs,
I have an odd issue that I can’t seem to diagnose. I’m setting up an answer test for two arrays, which are not related to anything in a dataset. I’m doing it using the GenericArrayTest (it’s in the answer testing framework), which compares two NumPy arrays.
Here’s my test—the way you get the arrays is immaterial, all you need to know is the stuff at the bottom where I’m comparing two NumPy arrays:
http://paste.yt-project.org/show/5976/
Here’s the error message I get:
http://paste.yt-project.org/show/5977/
I’ve looked into the answer testing code, but I can’t decipher why this is happening. This is under Python 2.
Best,
John
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
![](https://secure.gravatar.com/avatar/519d491fa9fe7dfd0caf0f0a9c2ca61e.jpg?s=120&d=mm&r=g)
Ok, so I was a moron and included all the right flags to execute nose answer tests *except* “—with-answer-testing”. However, I was under the impression that we didn’t error out if we forgot to include this—that they were just ignored. Thoughts?
On Oct 15, 2015, at 1:10 AM, Nathan Goldbaum <nathan12343@gmail.com> wrote:
Hi John,
I'm not sure. It looks like the reference_storage gets set up inside the plugin setup function, which *should* be called when you do the tests --with-answer-testing.
Do you have an example nosetests invocation you are doing that triggers this error?
Also, now that I look at it, it looks like the current uses of the GenericArrayTest in the test suite are not actually being run. Both the SZ answer tests and the photon simulator answer tests don't have a job on fido. I'd suggest you coordinate with Kacper to get that enabled...
So that means the GenericArrayTests are not actually being used anywhere by anyone in the test suite. It's possible they have a bug...
-Nathan
On Wed, Oct 14, 2015 at 7:40 PM, John ZuHone <jzuhone@gmail.com <mailto:jzuhone@gmail.com>> wrote: Hi devs,
I have an odd issue that I can’t seem to diagnose. I’m setting up an answer test for two arrays, which are not related to anything in a dataset. I’m doing it using the GenericArrayTest (it’s in the answer testing framework), which compares two NumPy arrays.
Here’s my test—the way you get the arrays is immaterial, all you need to know is the stuff at the bottom where I’m comparing two NumPy arrays:
http://paste.yt-project.org/show/5976/ <http://paste.yt-project.org/show/5976/>
Here’s the error message I get:
http://paste.yt-project.org/show/5977/ <http://paste.yt-project.org/show/5977/>
I’ve looked into the answer testing code, but I can’t decipher why this is happening. This is under Python 2.
Best,
John
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org <mailto:yt-dev@lists.spacepope.org> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org <http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org>
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
![](https://secure.gravatar.com/avatar/bbf1912c02dbb920e27ef0b9de0ba2ce.jpg?s=120&d=mm&r=g)
On 10/15/2015 08:47 AM, John ZuHone wrote:
Ok, so I was a moron and included all the right flags to execute nose answer tests *except* “—with-answer-testing”.
However, I was under the impression that we didn’t error out if we forgot to include this—that they were just ignored. Thoughts?
I think they didn't error out only if function is wrapped with @require_ds. Cheers, Kacper
On Oct 15, 2015, at 1:10 AM, Nathan Goldbaum <nathan12343@gmail.com> wrote:
Hi John,
I'm not sure. It looks like the reference_storage gets set up inside the plugin setup function, which *should* be called when you do the tests --with-answer-testing.
Do you have an example nosetests invocation you are doing that triggers this error?
Also, now that I look at it, it looks like the current uses of the GenericArrayTest in the test suite are not actually being run. Both the SZ answer tests and the photon simulator answer tests don't have a job on fido. I'd suggest you coordinate with Kacper to get that enabled...
So that means the GenericArrayTests are not actually being used anywhere by anyone in the test suite. It's possible they have a bug...
-Nathan
On Wed, Oct 14, 2015 at 7:40 PM, John ZuHone <jzuhone@gmail.com <mailto:jzuhone@gmail.com>> wrote: Hi devs,
I have an odd issue that I can’t seem to diagnose. I’m setting up an answer test for two arrays, which are not related to anything in a dataset. I’m doing it using the GenericArrayTest (it’s in the answer testing framework), which compares two NumPy arrays.
Here’s my test—the way you get the arrays is immaterial, all you need to know is the stuff at the bottom where I’m comparing two NumPy arrays:
http://paste.yt-project.org/show/5976/ <http://paste.yt-project.org/show/5976/>
Here’s the error message I get:
http://paste.yt-project.org/show/5977/ <http://paste.yt-project.org/show/5977/>
I’ve looked into the answer testing code, but I can’t decipher why this is happening. This is under Python 2.
Best,
John
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org <mailto:yt-dev@lists.spacepope.org> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org <http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org>
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
_______________________________________________ yt-dev mailing list yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
participants (3)
-
John ZuHone
-
Kacper Kowalik
-
Nathan Goldbaum