Packages
mysql_client
1.2.8
MySQL native client is written in Erlang and provides API that is very close to Connector/C library.
Current section
Files
Jump to
Current section
Files
priv/macro_test.erl
%% @author alexeikrasnopolski
%% @doc @todo Add description to macro_test.
-module(macro_test).
-include_lib("eunit/include/eunit.hrl").
-define(macro1(A, B), io:format(user, "~p~p~n", [A,B])).
-define(macro2, macro_replacement(A, B) -> begin A + B end).
%% ====================================================================
%% API functions
%% ====================================================================
-export([]).
macro_test_() ->
[
{"1. example", fun run/0}
].
run() ->
A = "A= ",
?macro1(A, 5),
io:format(user, "a: ~p~p~n", ["A= ", macro_replacement(2, 3)]).
%% ====================================================================
%% Internal functions
%% ====================================================================
?macro2.
a() -> ok.