Commit graph

303 commits

Author SHA1 Message Date
John Miller
39f5d329f1 Functional tests start jupyter using ein:jupyter-server-start
This reduces some of the complexity in testein.py, but unfortunately running
tests is still unreliable. Running batchwise tests don't work at all in Windows,
and running from inside emacs tests often need to be run multiple times before
they pass.

The worst offender is the delete notebook test, which will pass on usually only
1 out of 3 tries.

Testing seems to have revealed a couple bugs, so win??
2017-04-07 08:18:41 -05:00
John Miller
0d328470b3 What a waste of a commit. 2017-03-04 21:07:52 -06:00
John Miller
04061c968a Git rid of explicit use of mocker
Per #175 make mocker a dependency via Cask and avoid keeping an copy around in
the repository.
2017-02-15 19:39:45 -06:00
John Miller
ed633b1fd7 Functional tests that handle redirects. 2017-02-14 21:01:25 -06:00
John Miller
4bc3acf001 Desperate attempts to fix default coding when running testein. 2016-12-18 19:17:13 -06:00
John Miller
11a95db183 Merge remote-tracking branch 'refs/remotes/origin/master' into org-babel
# Conflicts:
#	lisp/ein-core.el
2016-10-15 13:11:38 -05:00
John Miller
256b14a49f Make synchronous comm a user configurable parameter.
EIN can communicate with the jupyter contents API synchronously or
asyncronously, with the default behavior the latter. For a time it has
been possible to force synchronous from the code, but now I have made
that a user-configurable parameter (see `ein:force-sync`).
2016-10-05 11:39:54 -05:00
John Miller
85744a78bd Fix delete test, travis config tweaking cont.
Make delete test slightly less complicated, but hopefully still as
test-y. More tweaking to travis config.
2016-10-03 11:36:27 -05:00
John Miller
cf70c7ecd9 Cleaning up testing
Trying to keep up with jupyter..
2016-09-30 13:24:28 -05:00
John Miller
b242519fa5 Merge branch 'master' into 38-fixing-testing 2016-09-24 12:26:24 -05:00
John Miller
71d8994ebb Undoing earlier bone-headedness
Finally getting Sam's PR right (sorry about that, Sam). Getting the
mocker subtree into the right place because apparently I cannot type.
2016-09-23 10:37:48 -05:00
John Miller
123cbed8c1 More submodule cleanup. 2016-09-09 10:10:00 -05:00
John Miller
e10bc60f30 Tweaks to functional testing and travis config.
Also adding environment definition for testing jupyter.
2016-05-17 16:22:05 -05:00
John Miller
a752e45772 Undo buffer-file-name madness.
No longer set buffer-file-name for ein:notebook buffers. This was
causing unexpected and potentially disastrous (as in data corruption)
behavior.

Some updates to travis configuration and testing. Still a long ways
from having that working, though.
2016-03-03 08:31:05 -06:00
John Miller
c5cf44a795 Fix saving new notebooks, whitespace updates.
Newly created notebooks no longer error on saving - bug in how
kernelspec metadata was being filled in.

Also a number of miscellaneous fixes to indentation that have
inexplicably appeared in the code.

Some small fixes for typos and catching up on version info.
2016-03-01 16:02:00 -06:00
John Miller
fdf626cc98 Creating legacy tests
In theory these tests are for IPython 2.x. Still need to work out how to include all this in travis.
2015-08-26 20:50:28 -05:00
John Miller
c49352e3b7 Fixing tests for IPython 3.x and Jupyter
Fixing test suite for changes in IPython introduced in 3.x and Jupyter. Still a long ways to go, but some improvements in how we generate test notebooks.
2015-08-26 20:49:20 -05:00
John Miller
ec35fc154c Improving test suite
For now focusing on testing against IPython 3.x. Getting 2.x working will have to wait until another day.
2015-08-13 16:41:40 -05:00
John Miller
127039e2aa Bump version.
Bump version (hope I found everywhere that it is documented). Fix
old-style print statements in one of the test notebooks.
2015-07-04 08:50:53 -05:00
John Miller
10044ddc9d Better cleanup
Remove Islands Tests.ipynb, we didn't need it. Remove temporary
notebooks after running tests - note that this is difficult to test
under Windows, so I am guessing that this is the right thing to do.
2015-06-30 17:16:10 -05:00
John Miller
bbda0d3ab8 Demo notebook for generating screenshots. 2015-05-19 06:41:34 -05:00
John Miller
2eeae04a03 Fix issue #35
Get ein:junk-new working again under IPython 2.x.

Some non-related work on fixing `ein:pytools-export-buffer`. Not quite
there yet, but I have an idea of what is going on.
2015-03-25 09:52:16 -05:00
John Miller
df72c1df12 Fix error reporting in IPython 3.0
Protocol for error reporting has changed in IPython 3.0 messaging and
ein was missing error messages.

EIN was also saving "*" for the notebook execution count and per
nbformat v4 execute_count can only be null or a number.
2015-02-25 14:55:09 -06:00
John Miller
f71676ac88 Refactoring notebook management
Work in progress.

Lots and lots of changes trying to clean up code so there are not so
many checks of IPython version. Also a significant amount of refactoring
all notebook server requests code to ein-contents-api.

Also moving away from notebook-id concept; instead use notebook path to
uniquely identify notebooks/content.

Made `ein:query-ipython-version` more efficient by caching results.
2015-02-10 14:53:08 -06:00
John Miller
40646b75ae Merge remote-tracking branch 'origin/fix-travis' into deferred-dev 2015-02-09 06:50:06 -06:00
John Miller
4eae3ce446 Clean up warnings in func-test.el 2015-02-03 19:12:25 -06:00
millejoh
84f478aed6 Improving ipython 3 support in testein.py. Lots of fixes for notebook tests to
properly test nbformat 3 notebooks.
2015-02-02 13:20:24 -06:00
John Miller
0796ed2dce Fix typos
Never can remember the names of the keywords for request.
2015-01-31 10:32:52 -06:00
John Miller
c30bad19a5 Content renaming
Call ein:content-rename to rename a content object in ein and at the
Jupyter server.
2015-01-31 10:31:20 -06:00
John Miller
55be1cbf26 Refactoring support for contents API
Start of a refactor of code for accessing Jupyter's new contents API.
First up an implementation of list contents.

New function for flattening lists borrowed from cl-alexandria (how did
we survive withoutthis in the before times?)

Updating author list here and there.
2015-01-31 10:13:49 -06:00
millejoh
d5b41c8f5d For testing reading and writing nbformats v3 (for IPython 2.x) and
v4 (for IPython-dev/3.0), many example notebooks.
2015-01-07 20:50:49 -06:00
John Miller
cbf4938d76 Make ein:query-ipython-version less whiny.
Calling ein:query-ipython-version with IPython 2.x running will result
in a request error since the api REST url is not implemented. Getting a
404 response is inevitable unless the IPython devs backport the api URL,
but I can make ein complain less when this happens.
2014-12-16 14:26:51 -06:00
John Miller
fe7dc935c5 Fixing notebooklist-new-notebook
IPython 2.x+ has a JSON response when creating a new notebook. We detect
this and correctly parse the info so we can open a buffer with the newly
created notebook.

Also more updating of test code.
2014-12-04 13:52:36 -06:00
John Miller
57a89bb112 Fixing test cases for ipython 2.x
Incorporating changes to REST api and nbformat that came with ipython
2.0.
2014-12-04 10:14:10 -06:00
John Miller
8aece1758b Fixing ein:connect-to-notebook
ein:connect-to-notebook seems to work now...
2014-12-03 19:44:02 -06:00
Takafumi Arakaki
0d7cf29002 Run test with curl and url-retrieve 2013-01-16 21:01:00 +01:00
Takafumi Arakaki
3966a6c22f Fix ein:testing-delete-notebook-by-name
ein:notebooklist-reload, which is called from success
callback of ein:notebooklist-delete-notebook, needs to
access ein:%notebooklist%.  However it was set to nil
in ein:testing-delete-notebook-by-name just after the
delete button is "clicked".  This was meant to detect
if the delete process is finished, but was not working.
To solve this problem, I add ein:notebooklist-after-open-hook
and use it to detect end of the delete process.
2012-12-30 15:59:16 +01:00
Takafumi Arakaki
3328dcc099 Fix tests in tests/test-ein-kernel.el 2012-12-29 18:55:06 +01:00
Takafumi Arakaki
1fdfda039c Add tests for ein:choose-setting 2012-12-06 23:16:44 +01:00
Takafumi Arakaki
5bf5086e8f Fix test ein:completer-finish-completing 2012-12-06 18:38:36 +01:00
Takafumi Arakaki
1606a8d32c Fix failing tests 2012-12-04 11:38:14 +01:00
Takafumi Arakaki
76d2336f8c Make ":" invalid as a notebook name
The JS client code was changed in this PR:
https://github.com/ipython/ipython/pull/1815
(commit: e264b9b48b)
2012-10-15 18:39:50 +02:00
Takafumi Arakaki
4a46447e4a Fix tests for header-line 2012-10-10 01:02:18 +02:00
Takafumi Arakaki
22c0e391c6 Fix & improve ein:notification-and-events
The constant "7" was not right as I added an event handler.
2012-10-09 20:39:23 +02:00
Takafumi Arakaki
28ba5e9ad1 Add execution_count.Kernel event 2012-10-09 20:09:23 +02:00
Takafumi Arakaki
7b85ead1a8 Fix failing tests due to the change in tab template 2012-10-09 19:57:27 +02:00
Takafumi Arakaki
509064d8d8 Test ein:find-leftmot-column more and fix it 2012-10-09 14:23:06 +02:00
Takafumi Arakaki
9c563828cd Test ein:find-leftmot-column for simple cases 2012-10-09 14:12:20 +02:00
Takafumi Arakaki
0af8362929 Add test ein:worksheet-beginning-of-cell-input-repeat 2012-10-05 15:51:51 +02:00
Takafumi Arakaki
c9f41f6b86 More tests for ein:worksheet-end-of-cell-input 2012-10-05 15:22:00 +02:00