improvement: upgrade ash dep

chore: remove comment
test: add a sort test
This commit is contained in:
Zach Daniel 2021-07-22 15:23:38 -04:00
parent 9ed3b67978
commit 85f27337d6
4 changed files with 9 additions and 4 deletions

View file

@ -1238,8 +1238,6 @@ defmodule AshPostgres.DataLayer do
@known_inner_join_predicates @known_inner_join_functions ++ @known_inner_join_operators
# For consistency's sake, this logic was removed.
# We can revisit it sometime though.
defp can_inner_join?(path, expr, seen_an_or? \\ false)
defp can_inner_join?(path, %{expression: expr}, seen_an_or?),

View file

@ -95,7 +95,7 @@ defmodule AshPostgres.MixProject do
{:ecto_sql, "~> 3.5"},
{:jason, "~> 1.0"},
{:postgrex, ">= 0.0.0"},
{:ash, ash_version("~> 1.46 and >= 1.46.11")},
{:ash, ash_version("~> 1.46 and >= 1.46.13")},
{:git_ops, "~> 2.4.3", only: :dev},
{:ex_doc, "~> 0.22", only: :dev, runtime: false},
{:ex_check, "~> 0.11.0", only: :dev},

View file

@ -1,5 +1,5 @@
%{
"ash": {:hex, :ash, "1.46.11", "bc404875dad27ed5a9e4fc2ad5369287342da1eeb571ec1b85b21c024515b9f7", [:mix], [{:comparable, "~> 1.0", [hex: :comparable, repo: "hexpm", optional: false]}, {:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:ecto, "~> 3.4", [hex: :ecto, repo: "hexpm", optional: false]}, {:ets, "~> 0.8.0", [hex: :ets, repo: "hexpm", optional: false]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: false]}, {:nimble_options, "~> 0.3.5", [hex: :nimble_options, repo: "hexpm", optional: false]}, {:picosat_elixir, "~> 0.1.5", [hex: :picosat_elixir, repo: "hexpm", optional: false]}, {:timex, ">= 3.0.0", [hex: :timex, repo: "hexpm", optional: false]}], "hexpm", "685814bb094dbc2cc4c9dd460778670f6d248c006fcd02e8a75fe173350bb0b1"},
"ash": {:hex, :ash, "1.46.13", "a35031db1be028d871f1a381901643f1cbdc2e52aaf6752ad9893af45dcdbd3e", [:mix], [{:comparable, "~> 1.0", [hex: :comparable, repo: "hexpm", optional: false]}, {:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:ecto, "~> 3.4", [hex: :ecto, repo: "hexpm", optional: false]}, {:ets, "~> 0.8.0", [hex: :ets, repo: "hexpm", optional: false]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: false]}, {:nimble_options, "~> 0.3.5", [hex: :nimble_options, repo: "hexpm", optional: false]}, {:picosat_elixir, "~> 0.1.5", [hex: :picosat_elixir, repo: "hexpm", optional: false]}, {:timex, ">= 3.0.0", [hex: :timex, repo: "hexpm", optional: false]}], "hexpm", "776a44f14c874a7bdf668540c02b80d1232d5e92dca469474a9b7fc606fea3d9"},
"bunt": {:hex, :bunt, "0.2.0", "951c6e801e8b1d2cbe58ebbd3e616a869061ddadcc4863d0a2182541acae9a38", [:mix], [], "hexpm", "7af5c7e09fe1d40f76c8e4f9dd2be7cebd83909f31fee7cd0e9eadc567da8353"},
"certifi": {:hex, :certifi, "2.6.1", "dbab8e5e155a0763eea978c913ca280a6b544bfa115633fa20249c3d396d9493", [:rebar3], [], "hexpm", "524c97b4991b3849dd5c17a631223896272c6b0af446778ba4675a1dff53bb7e"},
"combine": {:hex, :combine, "0.10.0", "eff8224eeb56498a2af13011d142c5e7997a80c8f5b97c499f84c841032e429f", [:mix], [], "hexpm", "1b1dbc1790073076580d0d1d64e42eae2366583e7aecd455d1215b0d16f2451b"},

View file

@ -103,4 +103,11 @@ defmodule AshPostgres.SortTest do
|> Ash.Query.select([:title, :score])
)
end
test "calculations can be sorted on w/o loading aggregates they reference" do
Post
|> Ash.Query.load(:count_of_comments)
|> Ash.Query.sort(:c_times_p)
|> Api.read!()
end
end