anchor.diff:      PublNode = publish_node_with_content_stanza(NodeName, ItemTopublish),
       pubsub_stanza([PublNode], ?NS_PUBSUB).
   
  -%% Similar to above but with different entry body - mimicking "real" physical 
  +%% Similar to above but with different entry body - mimicking "real" physical
   %% device with hardware "identifier" - device 1
   create_publish_node_content_stanza_second(NodeName, ItemId) ->
       PublishEntry = publish_entry(entry_body_with_sample_device_id()),
  
positive.code: %%% @copyright (C) 2015, Erlang Solutions Ltd.
  %%% @doc Suite for testing pubsub features as described in XEP-0060
  %%% @Helper module - only pubsub specific stanzas generation
  %%% @functions. 
  %%% @end
  %%%===================================================================
  
  -module(escalus_pubsub_stanza).
  %%-compile(export_all).
  
  -include_lib("escalus/include/escalus.hrl").
  -include_lib("common_test/include/ct.hrl").
  
negative.code: -include_lib("exml/include/exml_stream.hrl").
  
  -export([
           create_node_stanza/3,
           create_specific_node_stanza/1,
           create_subscribe_node_stanza/2,
           create_request_allitems_stanza/1,
           create_publish_node_content_stanza/2,
           create_publish_node_content_stanza_second/2,
           create_publish_node_content_stanza_third/2,
           create_sub_unsubscribe_from_node_stanza/3,
           create_unsubscribe_from_node_stanza/2,
           delete_node_stanza/1,
           entry_body_sample1/0,
           entry_body_with_sample_device_id/0,
           get_subscription_change_list_stanza/1,
           iq_with_id/5,
           iq_set_get_rest/3,
           publish_item/2,
           publish_entry/1,
           pubsub_stanza/2,
           publish_node_with_content_stanza/2,
           publish_sample_content_stanza/5,
           retract_from_node_stanza/2,
           retrieve_subscriptions_stanza/1,
           set_subscriptions_stanza/2,
           subscribe_by_user_stanza/3,
           unsubscribe_by_user_stanza/3
          ]).
  
  
  pubsub_stanza(Children, NS) ->
      #xmlel{name = <<"pubsub">>,
             attrs = [{<<"xmlns">>, NS} ],
             children = Children  }.
  
  publish_sample_content_stanza(DestinationTopicName, DestinationNode, PublishItemId, User, SampleNumber) ->
      PublishToNode = case SampleNumber of
                          sample_one ->
                              create_publish_node_content_stanza(DestinationTopicName, PublishItemId);
                          sample_two ->
                              create_publish_node_content_stanza_second(DestinationTopicName, PublishItemId);
                          sample_three ->
                              create_publish_node_content_stanza_third(DestinationTopicName, PublishItemId);
                          _ ->
                              create_publish_node_content_stanza(DestinationTopicName, PublishItemId)
                      end,
      IqId = <<"publish1">>,
      escalus_pubsub_stanza:iq_with_id(set, IqId, DestinationNode, User,  [PublishToNode]).
  
  create_node_stanza(User, DestinationNodeAddr, DestinationNodeName) ->
      PubSubCreate = create_specific_node_stanza(DestinationNodeName),
      PubSub = pubsub_stanza([PubSubCreate], ?NS_PUBSUB),
      Id = <<"create1">>,
      iq_with_id(set, Id, DestinationNodeAddr, User,  [PubSub]).
  
  create_specific_node_stanza(NodeName) ->
      #xmlel{name = <<"create">>,  attrs = [{<<"node">>, NodeName}] }.
  
  iq_with_id(TypeAtom, Id, To, From, Body) ->
      S1 = escalus_stanza:iq(To, atom_to_binary(TypeAtom, latin1), Body),
      iq_set_get_rest(S1, Id, From).
  
  iq_set_get_rest(SrcIq, Id, From) ->
      S2 = escalus_stanza:set_id(SrcIq, Id),
      escalus_stanza:from(S2, escalus_utils:get_jid(From)).
  
  %% ----------------------------- sample entry bodies ------------------------
  