From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: [babel] Specified colnames Date: Fri, 12 Apr 2013 15:42:35 -0600 Message-ID: <871uaffk5g.fsf@gmail.com> References: <86y5cuxfro.fsf@somewhere.org> <87obdp0ybb.fsf@gmail.com> <86ip3w957l.fsf@somewhere.org> <87fvz0zslt.fsf@gmail.com> <86a9p8928u.fsf@somewhere.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:41127) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQmdw-000127-2N for emacs-orgmode@gnu.org; Fri, 12 Apr 2013 18:40:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UQmdr-0007wF-NW for emacs-orgmode@gnu.org; Fri, 12 Apr 2013 18:40:27 -0400 Received: from mail-da0-x230.google.com ([2607:f8b0:400e:c00::230]:52710) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQmdr-0007vw-HW for emacs-orgmode@gnu.org; Fri, 12 Apr 2013 18:40:23 -0400 Received: by mail-da0-f48.google.com with SMTP id p8so1307593dan.35 for ; Fri, 12 Apr 2013 15:40:22 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Sebastien Vauban Cc: emacs-orgmode@gnu.org "Sebastien Vauban" writes: > Eric, > > Eric Schulte wrote: >>> Extra question: tested with a sh block, both of the above do work, that= is >>> with strings or symbols. Which one is supposed to be better (that is, w= ill be >>> more portable with time), if there is one? >> >> Both will be maintained. The contribution of a test exercising both >> options could provide an extra guarantee of perseverance. This is also >> a good first step towards editing the code. :) > > Here's my trial to do so. > > --8<---------------cut here---------------start------------->8--- > (ert-deftest test-ob/specific-column-names-symbols () > "Test passing specific column names as a list of symbols." > (should > (equal "#+name: input-table > | id | var1 | > |----+------| > | 1 | bar | > | 2 | baz | > > #+begin_src sh :var data=3Dinput-table :exports results :colnames '(Rev A= uthor) > echo \"$data\" > #+end_src > > #+results: > | Rev | Author | > |-----+--------| > | 1 | bar | > | 2 | baz | > > " > (org-test-with-temp-text "#+name: input-table > | id | var1 | > |----+------| > | 1 | bar | > | 2 | baz | > > #+begin_src sh :var data=3Dinput-table :exports results :colnames '(Rev A= uthor) > echo \"$data\" > #+end_src > " > (org-babel-execute-src-block) > (buffer-string))))) > --8<---------------cut here---------------end--------------->8--- > > Does this correspond to what you're asking for? > Close, could you prepare this as a patch against the current code base? That way I can simply apply it locally and more easily test it. > > However, running it did not succeed. I must do something wrong, or NOT do > something good... > > =E2=95=AD=E2=94=80=E2=94=80=E2=94=80=E2=94=80 > =E2=94=82 Selector: t > =E2=94=82 Passed: 0 > =E2=94=82 Failed: 0 > =E2=94=82 Total: 0/1 > =E2=94=82=20 > =E2=94=82 Started at: 2013-04-08 22:45:19+0200 > =E2=94=82 Aborted. > =E2=94=82 Aborted at: 2013-04-08 22:45:19+0200 > =E2=94=82=20 > =E2=94=82 A > =E2=94=82=20 > =E2=94=82 A test-ob/specific-column-names-symbols > =E2=94=82 Test passing specific column names as a list of symbols. > =E2=94=82 aborted > =E2=95=B0=E2=94=80=E2=94=80=E2=94=80=E2=94=80 > > The worse is that I don't get a backtrace, even after: > > - setting debug-on-error to t, or > - M-x'ing toggle-debug-on-error. > > Weird, but not the first time -- seems related to Emacs 24.2 or so (+ my > config?). > Integration these tests with the existing tests should help to illuminate whatever is causing these failures. Assuming that the existing tests are passing on your system that is. Cheers, > > Best regards, > Seb --=20 Eric Schulte http://cs.unm.edu/~eschulte