anchor.diff:  -include_lib("radius/include/radius.hrl").
   -include("ocs_eap_codec.hrl").
   -include_lib("common_test/include/ct.hrl").
  +-include_lib("diameter/include/diameter.hrl").
  +-include_lib("diameter/include/diameter_gen_base_rfc6733.hrl").
  +-include_lib("../include/diameter_gen_eap_application_rfc4072.hrl").
  +
  +-define(SVC, diameter_client_service).
  +-define(BASE_APPLICATION_ID, 0).
  +-define(EAP_APPLICATION_ID, 5).
   
   %%---------------------------------------------------------------------
   %%  Test server callback functions
  
positive.code: 			data = AuthTypes} = ocs_eap_codec:eap_packet(EapMsg),
  	{EapId, AuthTypes}.
  
  
negative.code: init_per_suite(Config) ->
  	ok = ocs_test_lib:initialize_db(),
  	ok = ocs_test_lib:start(),
  	{ok, [{auth, DiaAuthInstance}, {acct, _}]} = application:get_env(ocs, diameter),
  	[{Address, Port, _}] = DiaAuthInstance,
  	true = diameter:subscribe(?SVC),
  	ok = diameter:start_service(?SVC, client_service_opts()),
  	{ok, _Ref} = connect(?SVC, Address, Port, diameter_tcp),
  	receive
  		#diameter_event{service = ?SVC, info = start} ->
  			[{diameter_client, Address}] ++ Config;
  		_ ->
  			{skip, diameter_client_service_not_started}
  	end.
  
  -spec end_per_suite(Config :: [tuple()]) -> any().
  %% Cleanup after the whole suite.
  %%
  end_per_suite(Config) ->
  	ok = diameter:stop_service(?SVC),
  	ok = ocs_test_lib:stop(),
  	Config.
  
  -spec init_per_testcase(TestCase :: atom(), Config :: [tuple()]) -> Config :: [tuple()].
  %% Initialization before each test case.
  %%
  init_per_testcase(TestCase, Config) when TestCase == eap_identity_diameter ->
  	{ok, [{auth, DiaAuthInstance}, _]} = application:get_env(ocs, diameter),
  	[{Address, Port, _}] = DiaAuthInstance,
  	Secret = "87dhcbwhc",
  	ok = ocs:add_client(Address, Port, diameter, Secret),
  	[{diameter_client, Address}] ++ Config;
  init_per_testcase(_TestCase, Config) ->
  	{ok, [{auth, RadAuthInstance}, {acct, _RadAcctInstance}]} = application:get_env(ocs, radius),
  	[{RadIP, RadPort, _}] = RadAuthInstance,
  	{ok, Socket} = gen_udp:open(0, [{active, false}, inet, {ip, RadIP}, binary]),
  	SharedSecret = ct:get_config(radius_shared_secret),
  	Protocol = radius,
  	ok = ocs:add_client(RadIP, RadPort, Protocol, SharedSecret),
  	NasId = atom_to_list(node()),
  	[{nas_id, NasId}, {socket, Socket}, {radius_client, RadIP}] ++ Config.
  
  -spec end_per_testcase(TestCase :: atom(), Config :: [tuple()]) -> any().
  %% Cleanup after each test case.
  %%
  end_per_testcase(TestCase, Config) when TestCase == eap_identity_diameter ->
  	DClient = ?config(diameter_client, Config),
  	ok = ocs:delete_client(DClient);
  end_per_testcase(_TestCase, Config) ->
  	Socket = ?config(socket, Config),
  	RadClient = ?config(radius_client, Config),
  	ok = ocs:delete_client(RadClient),
  	ok = 	gen_udp:close(Socket).
  
  -spec sequences() -> Sequences :: [{SeqName :: atom(), Testcases :: [atom()]}].
  