Commit Graph
1153 Commits
Author SHA1 Message Date
José Valim 658d7c7913 ExUnit callbacks must return :ok or { :ok, data } 2013-02-17 20:43:01 -07:00
José Valim 8ca4517563 Merge pull request #847 from jeremyjh/apply-doc-fix
correct apply/3 example
2013-02-17 18:38:51 -08:00
Jeremy Huffman 4e8690cd8e correct apply/3 example 2013-02-17 21:22:11 -05:00
José Valim 8f57b4c9af Add metadata support to ExUnit
Defining setup/teardown/test explicitly is now deprecated.
They should now be defined via their respective macros:

    def setup do
      ...
    end

Now becomes:

    setup do
      ...
    end

When defined using the new format, setup callbacks can
return metadata:

    setup do
      [do_this: :do_that]
    end

And now the test macro can access this metadata:

    test "check metadata", data do
      assert data[:do_this] == :do_that
    end
2013-02-17 18:23:31 -07:00
José Valim 19d402b7d5 Disable native compilation when on_load attributes is present
This is a work around an Erlang bug, see #845 for more information.
Closes #845.
2013-02-17 12:22:08 -07:00
José Valim 5557e620ff Backwards incompatible change on before_compile and after_compile
Both callbacks now receive the environment as
first argument instead of the module.
2013-02-16 19:57:14 -07:00
José Valim 683153ef05 Switches are now overridden by default but can be kept in order if chosen, closes #782 2013-02-16 19:17:35 -07:00
José Valim a05592fdd9 Only accept the IO device on inspect when we have three args 2013-02-16 16:43:41 -07:00
José Valim 1946feb4e1 Merge pull request #842 from happy4crazy/doc-fixes
Kernel doc fixes
2013-02-15 14:27:24 -08:00
Alan O'Donnell a0101bc056 Doc typos, misc. style cleanup 2013-02-15 17:08:22 -05:00
Yurii Rashkovskii 129725a168 Suppress minor warning (unused variable) in hash_dict.ex 2013-02-15 13:02:16 -08:00
Alan O'Donnell f6058afb26 Misc. documentation cleanup 2013-02-15 14:59:25 -05:00
Alan O'Donnell 67b5236874 Fix invalid bit syntax in docs. 2013-02-15 13:07:03 -05:00
José Valim 9ebce19f36 Push a test case related to the nested vars in clauses 2013-02-14 10:46:20 -07:00
José Valim fb82b0c679 Pick latest variable in between clauses instead of picking a random one 2013-02-14 09:43:54 -07:00
Yurii Rashkovskii 9dc7f44049 Drop HashDict.t type and spec HashDict.new with Dict.t 2013-02-12 12:39:23 -08:00
Yurii Rashkovskii 5e2c6e14be Add HashDict.t type 2013-02-12 11:36:55 -08:00
Kim Shrier ced13c159f Change references or invocations of Process.self to Kernel.self 2013-02-09 15:41:09 -07:00
José Valim 5fe1544ff3 Deprecate Process.self in favor of Kernel.self to make imports easier, closes #832 2013-02-09 12:10:15 -07:00
José Valim 96c7f68a62 Merge pull request #825 from khia/node_connect
Node.connect/1
2013-02-08 10:36:00 -08:00
Yurii Rashkovskii d0dc9f5c2c Minor indentation fix 2013-02-06 10:32:26 -08:00
Yurii Rashkovskii 8a130978b2 Remove some garbage 2013-02-05 11:20:04 -08:00
Yurii Rashkovskii 71e2252064 Unpack __block__ in type specs
Fixes #827
2013-02-05 11:18:49 -08:00
ILYA Khlopotov ddc9733cf2 Add Node.connect/1 method 2013-02-04 12:34:11 -08:00
ILYA Khlopotov 9bcc4be3f5 Fix typo in typespec of Node.disconnect 2013-02-04 12:32:29 -08:00
José Valim f66206b4f3 s/on/in 2013-02-04 08:38:52 -07:00
José Valim 28211b2714 Ensure aliases expansion also works for implicit aliases 2013-02-03 21:57:39 -07:00
José Valim 109c07e757 Improve aliases hygiene by using metadata 2013-02-03 15:12:38 -07:00
José Valim eb36c2b288 Improve docs for File 2013-02-03 14:03:59 -07:00
José Valim 3537bbbbf4 Refactor aliases handling 2013-02-03 13:07:20 -07:00
José Valim cd51c80362 Tidy up and clean up quote API, closes #814 2013-02-03 12:14:18 -07:00
Yurii Rashkovskii a1a576e9d1 Implement as_boolean/1 type
Closes #798
2013-02-03 10:40:35 -08:00
Yurii Rashkovskii 1812e652db Minor IO.ANSI.terminal?/0 documentation improvement 2013-02-02 15:13:47 -08:00
Yurii Rashkovskii 7f73cb3128 Add missing specification for IO.ANSI.terminal?/1 2013-02-02 14:37:41 -08:00
Yurii Rashkovskii 0123edd8a3 Better error reporting for invalid ANSI escape sequences 2013-02-02 14:25:10 -08:00
Yurii Rashkovskii 87af330589 Don't emit ANSI sequence escape codes in shell in OTP prior to R16 2013-02-02 14:10:27 -08:00
José Valim de3bd8ec86 Expand current module macros with Macro.expand, closes #815 2013-02-02 15:04:30 -07:00
Yurii Rashkovskii 3fea472cc2 IO.ANSI.escape shouldn't emit a reset sequence if no ANSI sequence was emitted
Closes #807
2013-02-02 13:02:51 -08:00
Yurii Rashkovskii 7cb18091d0 Better error reporting for invalid type specifications
Closes #818
2013-02-02 12:47:17 -08:00
José Valim 8994feb0a3 Fix unused vars warnings 2013-02-02 13:33:00 -07:00
José Valim f4aed8e873 Reduce vars footprint in case/receive clauses 2013-02-02 13:20:59 -07:00
José Valim 008ee62f8b Take into account Erlang may pass line numbers as none 2013-02-02 09:00:43 -07:00
José Valim 7196543060 Improve how aliases for defmodule are generated 2013-01-30 16:43:29 -07:00
José Valim fade5452e1 R16A fixes 2013-01-30 11:15:40 -07:00
Yurii Rashkovskii 9e46866851 Allow building Elixir on R16 2013-01-30 09:41:32 -08:00
José Valim 3137bfc614 Move bootstrap code for IEx to IEx.CLI 2013-01-29 12:30:09 -07:00
José Valim 4d3d61e173 Deprecate :local.(args) syntax 2013-01-28 21:21:18 -07:00
Yurii Rashkovskii 2e66218f58 Minor IO.ANSI documentation fix 2013-01-28 12:22:05 -08:00
José Valim 3a1fbde95d Remove deprecated branches 2013-01-28 13:08:18 -07:00
José Valim 249f83e82b IO should default to the group leader 2013-01-28 13:03:08 -07:00