diff --git a/lib/kino_db/connection_cell.ex b/lib/kino_db/connection_cell.ex index 60f8da4..33342df 100644 --- a/lib/kino_db/connection_cell.ex +++ b/lib/kino_db/connection_cell.ex @@ -198,7 +198,6 @@ defmodule KinoDB.ConnectionCell do quote do opts = unquote(shared_options(attrs)) - if opts[:ssl] == true, do: :ssl.start() {:ok, unquote(quoted_var(attrs["variable"]))} = Kino.start_child({Postgrex, opts}) end end @@ -207,7 +206,6 @@ defmodule KinoDB.ConnectionCell do quote do opts = unquote(shared_options(attrs)) - if opts[:ssl] == true, do: :ssl.start() {:ok, unquote(quoted_var(attrs["variable"]))} = Kino.start_child({MyXQL, opts}) end end diff --git a/mix.exs b/mix.exs index 3db764c..fe5601d 100644 --- a/mix.exs +++ b/mix.exs @@ -28,7 +28,7 @@ defmodule KinoDB.MixProject do [ {:kino, "~> 0.7"}, {:table, "~> 0.1.2"}, - {:postgrex, "~> 0.16.3 or ~> 0.17", optional: true}, + {:postgrex, "~> 0.16.3 or ~> 0.17.3 or ~> 0.18", optional: true}, {:exqlite, "~> 0.11", optional: true}, {:myxql, "~> 0.6.2 or ~> 0.7", optional: true}, {:db_connection, "~> 2.4.2", optional: true}, diff --git a/test/kino_db/connection_cell_test.exs b/test/kino_db/connection_cell_test.exs index ca0842a..c9ad562 100644 --- a/test/kino_db/connection_cell_test.exs +++ b/test/kino_db/connection_cell_test.exs @@ -52,11 +52,6 @@ defmodule KinoDB.ConnectionCellTest do assert source == """ opts = [hostname: "localhost", port: 5432, username: "", password: "", database: ""] - - if opts[:ssl] == true do - :ssl.start() - end - {:ok, conn} = Kino.start_child({Postgrex, opts})\ """ end @@ -73,10 +68,6 @@ defmodule KinoDB.ConnectionCellTest do database: "default" ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, db} = Kino.start_child({Postgrex, opts})\ ''' @@ -92,10 +83,6 @@ defmodule KinoDB.ConnectionCellTest do socket_options: [:inet6] ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, db} = Kino.start_child({Postgrex, opts})\ ''' @@ -111,10 +98,6 @@ defmodule KinoDB.ConnectionCellTest do ssl: true ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, db} = Kino.start_child({Postgrex, opts})\ ''' @@ -129,10 +112,6 @@ defmodule KinoDB.ConnectionCellTest do database: "default" ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, db} = Kino.start_child({Postgrex, opts})\ ''' @@ -145,10 +124,6 @@ defmodule KinoDB.ConnectionCellTest do database: "default" ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, db} = Kino.start_child({MyXQL, opts})\ ''' @@ -229,11 +204,6 @@ defmodule KinoDB.ConnectionCellTest do assert_smart_cell_update(kino, %{"hostname" => "myhost"}, """ opts = [hostname: "myhost", port: 5432, username: "", password: "", database: ""] - - if opts[:ssl] == true do - :ssl.start() - end - {:ok, conn} = Kino.start_child({Postgrex, opts})\ """) end @@ -260,11 +230,6 @@ defmodule KinoDB.ConnectionCellTest do assert_smart_cell_update(kino, %{"type" => "mysql", "port" => 3306}, """ opts = [hostname: "localhost", port: 3306, username: "", password: "", database: ""] - - if opts[:ssl] == true do - :ssl.start() - end - {:ok, conn} = Kino.start_child({MyXQL, opts})\ """) end @@ -295,10 +260,6 @@ defmodule KinoDB.ConnectionCellTest do database: "" ] - if opts[:ssl] == true do - :ssl.start() - end - {:ok, conn} = Kino.start_child({Postgrex, opts})\ """ )