kittoframework / kitto

Kitto is a framework for interactive dashboards written in Elixir
http://kitto.io/dashboards/sample
MIT License
955 stars 58 forks source link

Elixir 1.4 warnings when launching tests #91

Closed fusillicode closed 7 years ago

fusillicode commented 7 years ago

Environment

Current behavior

When launching mix tests there are various warnings related to missing parentheses:

Compiling 23 files (.ex)
warning: module attribute @max_restarts was set but never used
  lib/kitto/runner.ex:11

Generated kitto app

2.3.3p222 11:42:37 ~/data/dev/oss/kitto/kitto fix-elixir-1.4-warnings ✓ 07aa3d1
± mix test           
warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/test_helper.exs:7

Excluding tags: [pending: true]

...warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:59

warning: variable "make_ref" does not exist and is being expanded to "make_ref()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:63

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:73

warning: variable "make_ref" does not exist and is being expanded to "make_ref()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:77

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:87

warning: variable "make_ref" does not exist and is being expanded to "make_ref()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:91

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:101

warning: variable "make_ref" does not exist and is being expanded to "make_ref()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:105

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:115

warning: variable "make_ref" does not exist and is being expanded to "make_ref()", please use parentheses to remove the ambiguity or change the variable name
  test/code_reloader_test.exs:121

..warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:5

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:18

..warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:30

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:44

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:56

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/job_test.exs:69

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.dashboard_test.exs:7

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.dashboard_test.exs:20

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.dashboard_test.exs:21

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.widget_test.exs:7

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.widget_test.exs:10

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.widget_test.exs:24

warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/generators/kitto.gen.widget_test.exs:25

..warning: module attribute @job_gist_response was set but never used
  test/mix/tasks/kitto.install_test.exs:6

warning: module attribute @kitto was set but never used
  installer/lib/kitto_new.ex:5

warning: module attribute @lint was set but never used
  installer/lib/kitto_new.ex:10

..warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/router_test.exs:398

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/router_test.exs:396

..............warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/stats_server_test.exs:9

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/stats_server_test.exs:10

warning: variable "self" does not exist and is being expanded to "self()", please use parentheses to remove the ambiguity or change the variable name
  test/stats_server_test.exs:11

.....warning: variable "tmp_path" does not exist and is being expanded to "tmp_path()", please use parentheses to remove the ambiguity or change the variable name
  test/mix/tasks/kitto.new_test.exs:53

..................................................
11:43:00.973 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.973 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.973 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.973 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

11:43:00.974 [warn]  Kitto.StatsServer Kitto.StatsServer received unexpected message in handle_info/2: {:ok, :mocked}

warning: variable "binding" does not exist and is being expanded to "binding()", please use parentheses to remove the ambiguity or change the variable name
  test/fixtures/jobs/valid_job.exs:3

..warning: variable "binding" does not exist and is being expanded to "binding()", please use parentheses to remove the ambiguity or change the variable name
  test/fixtures/jobs/valid_job.exs:3

.warning: variable "binding" does not exist and is being expanded to "binding()", please use parentheses to remove the ambiguity or change the variable name
  test/fixtures/jobs/valid_job.exs:3

warning: variable "binding" does not exist and is being expanded to "binding()", please use parentheses to remove the ambiguity or change the variable name
  test/fixtures/jobs/valid_job.exs:3

.warning: variable "binding" does not exist and is being expanded to "binding()", please use parentheses to remove the ambiguity or change the variable name
  test/fixtures/jobs/valid_job.exs:3

.................................

Finished in 2.5 seconds
118 tests, 0 failures, 1 skipped

Randomized with seed 160770

This issue can be considered strongly related to the #89.

Expected behavior

The over mentioned warnings should not be present. Ideally there should be no warnings at all.

fusillicode commented 7 years ago

I'm closing this issue considering @Zorbash comment in #89