Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify having an extra module for a very simple function #3764

Merged
merged 2 commits into from
Sep 20, 2022

Conversation

NelsonVides
Copy link
Collaborator

Having a module only for such a super simple module feels quite redundant, we already have a mongoose_bin helper module for doing things to binaries.

@mongoose-im

This comment was marked as outdated.

@codecov
Copy link

codecov bot commented Sep 20, 2022

Codecov Report

Base: 82.47% // Head: 82.80% // Increases project coverage by +0.33% 🎉

Coverage data is based on head (d4264b2) compared to base (8ba1dd9).
Patch coverage: 71.42% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3764      +/-   ##
==========================================
+ Coverage   82.47%   82.80%   +0.33%     
==========================================
  Files         532      531       -1     
  Lines       34068    34069       +1     
==========================================
+ Hits        28096    28212     +116     
+ Misses       5972     5857     -115     
Impacted Files Coverage Δ
src/mod_muc.erl 74.23% <0.00%> (-0.18%) ⬇️
src/ejabberd_service.erl 67.53% <100.00%> (ø)
src/mod_bosh.erl 95.62% <100.00%> (ø)
src/mod_roster.erl 78.70% <100.00%> (-0.72%) ⬇️
src/mongoose_bin.erl 87.50% <100.00%> (+0.83%) ⬆️
src/ejabberd.erl 45.00% <0.00%> (-10.00%) ⬇️
src/async_pools/mongoose_aggregator_worker.erl 63.33% <0.00%> (-5.01%) ⬇️
src/mam/mod_mam_muc_rdbms_arch_async.erl 82.85% <0.00%> (-2.86%) ⬇️
src/mod_roster_riak.erl 96.92% <0.00%> (-1.54%) ⬇️
... and 16 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@mongoose-im
Copy link
Collaborator

mongoose-im commented Sep 20, 2022

small_tests_24 / small_tests / d4264b2
Reports root / small


small_tests_25 / small_tests / d4264b2
Reports root / small


ldap_mnesia_24 / ldap_mnesia / d4264b2
Reports root/ big
OK: 1968 / Failed: 0 / User-skipped: 555 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / d4264b2
Reports root/ big
OK: 3607 / Failed: 0 / User-skipped: 88 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_25 / pgsql_mnesia / d4264b2
Reports root/ big
OK: 3607 / Failed: 0 / User-skipped: 88 / Auto-skipped: 0


dynamic_domains_mysql_redis_25 / mysql_redis / d4264b2
Reports root/ big
OK: 3581 / Failed: 0 / User-skipped: 114 / Auto-skipped: 0


ldap_mnesia_25 / ldap_mnesia / d4264b2
Reports root/ big
OK: 1968 / Failed: 0 / User-skipped: 555 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / d4264b2
Reports root/ big
OK: 3981 / Failed: 0 / User-skipped: 97 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_25 / odbc_mssql_mnesia / d4264b2
Reports root/ big
OK: 3607 / Failed: 0 / User-skipped: 88 / Auto-skipped: 0


internal_mnesia_25 / internal_mnesia / d4264b2
Reports root/ big
OK: 2089 / Failed: 0 / User-skipped: 434 / Auto-skipped: 0


elasticsearch_and_cassandra_25 / elasticsearch_and_cassandra_mnesia / d4264b2
Reports root/ big
OK: 2429 / Failed: 0 / User-skipped: 429 / Auto-skipped: 0


mysql_redis_25 / mysql_redis / d4264b2
Reports root/ big
OK: 3967 / Failed: 0 / User-skipped: 111 / Auto-skipped: 0


pgsql_mnesia_25 / pgsql_mnesia / d4264b2
Reports root/ big
OK: 3981 / Failed: 0 / User-skipped: 97 / Auto-skipped: 0


mssql_mnesia_25 / odbc_mssql_mnesia / d4264b2
Reports root/ big
OK: 4002 / Failed: 3 / User-skipped: 97 / Auto-skipped: 0

pep_SUITE:pep_tests:delayed_receive
{error,{{badmatch,[]},
    [{pep_SUITE,'-delayed_receive/1-fun-0-',3,
          [{file,"/home/circleci/project/big_tests/tests/pep_SUITE.erl"},
           {line,276}]},
     {escalus_story,story,4,
            [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
             {line,72}]},
     {test_server,ts_tc,3,[{file,"test_server.erl"},{line,1782}]},
     {test_server,run_test_case_eval1,6,
            [{file,"test_server.erl"},{line,1291}]},
     {test_server,run_test_case_eval,9,
            [{file,"test_server.erl"},{line,1223}]}]}}

Report log

pep_SUITE:pep_tests:unsubscribe_after_presence_unsubscription
{error,{{assertion_failed,assert_many,false,
              [is_roster_set,is_presence,is_presence],
              [{xmlel,<<"presence">>,
                  [{<<"from">>,
                  <<"alice_unsubscribe_after_presence_unsubscription_2477@localhost/res1">>},
                   {<<"to">>,
                  <<"bob_unsubscribe_after_presence_unsubscription_2477@localhost/res1">>},
                   {<<"xml:lang">>,<<"en">>}],
                  []}],
              "   <presence from='alice_unsubscribe_after_presence_unsubscription_2477@localhost/res1' to='bob_unsubscribe_after_presence_unsubscription_2477@localhost/res1' xml:lang='en'/>"},
    [{escalus_new_assert,assert_true,2,
               [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_new_assert.erl"},
                {line,84}]},
     {escalus_utils,'-each_with_index/3-fun-0-',3,
            [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_utils.erl"},
             {line,87}]},
     {lists,foldl_1,3,[{file,"lists.erl"},{line,1355}]},
     {escalus_utils,'-each_with_index/3-fun-0-',3,
            [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_utils.erl"},
             {line,87}]},
     {lists,foldl,3,[{file,"lists.erl"},{line,1350}]},
     {escalus_utils,distinct_pairs,2,
            [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_utils.erl"},
             {line,60}]},
     {escalus_story,mak...

Report log

pep_SUITE:pep_tests:unsubscribe_after_presence_unsubscription
{error,
  {{badmatch,
     [{xmlel,<<"message">>,
        [{<<"from">>,
        <<"alice_unsubscribe_after_presence_unsubscription_2488@localhost">>},
         {<<"to">>,
        <<"bob_unsubscribe_after_presence_unsubscription_2488@localhost/res1">>},
         {<<"type">>,<<"headline">>}],
        [{xmlel,<<"event">>,
           [{<<"xmlns">>,
           <<"http://jabber.org/protocol/pubsub#event">>}],
           [{xmlel,<<"items">>,
            [{<<"node">>,<<"ejF4hZWIdbXAtowxbFJBDA==">>}],
            [{xmlel,<<"item">>,
               [{<<"id">>,<<"salmon">>}],
               [{xmlel,<<"entry">>,
                  [{<<"xmlns">>,
                  <<"http://www.w3.org/2005/Atom">>}],
                  []}]}]}]},
         {xmlel,<<"headers">>,
           [{<<"xmlns">>,<<"http://jabber.org/protocol/shim">>}],
           []}]}]},
   [{pep_SUITE,'-unsubscribe_after_presence_unsubscription/1-fun-0-',2,
      [{file,"/home/circleci/project/big_tests/tests/pep_SUITE.erl"},
       {line,384}]},
    {escalus_story,story,4,
      [{file,
         "/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
       {line,72}]},
    {test_server,ts_tc,3,[{file,"test_server.erl"},{line,1782}]},
    {test_server,run_test_case_eval1,6,
      [{file,"test_server.erl"},{line,1291}]},
    {test_server,run_test_case_eval,9,
      [{file,"test_server.erl"},{line,1223}]}]}}

Report log


riak_mnesia_24 / riak_mnesia / d4264b2
Reports root/ big
OK: 2268 / Failed: 0 / User-skipped: 422 / Auto-skipped: 0


mssql_mnesia_25 / odbc_mssql_mnesia / d4264b2
Reports root/ big
OK: 3981 / Failed: 0 / User-skipped: 97 / Auto-skipped: 0

Copy link
Member

@chrzaszcz chrzaszcz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@chrzaszcz chrzaszcz merged commit 5cd7630 into master Sep 20, 2022
@chrzaszcz chrzaszcz deleted the kill_redundant_module branch September 20, 2022 10:32
@chrzaszcz chrzaszcz added this to the 6.0.0 milestone Dec 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants