View a.rb
https://gist.github.com/df9861cc1d105701265df4256c7fd3bb
View a.rb
https://gist.github.com/df9861cc1d105701265df4256c7fd3bb
View a.rb
App/Containers/Loadable.js
View gist:5f80459e971eeec0cc4b84038e24df31
Theorem andb_eq_orb :
forall (b c : bool),
b && c = b || c ->
b = c.
Proof.
intros b c.
destruct b.
- simpl.
destruct c.
+ reflexivity.
View competition_actions.ex
defmodule Api.CompetitionActions do
use Api.Web, :action
alias Api.{Competition, TeamActions, Vote, PaperVote, Team}
alias Ecto.{Changeset}
defp _get do
Repo.one(from(c in Competition)) || %Competition{}
end
View competition_actions.ex
defmodule Api.CompetitionActions do
use Api.Web, :action
alias Api.{Competition, TeamActions, Vote, PaperVote, Team}
alias Ecto.{Changeset}
defp _get do
Repo.one(from(c in Competition)) || %Competition{}
end
View -
diff --git a/test/controllers/admin/admin_paper_vote_controller_test.exs b/test/controllers/admin/admin_paper_vote_controller_test.exs
new file mode 100644
index 0000000..f63d82a
--- /dev/null
+++ b/test/controllers/admin/admin_paper_vote_controller_test.exs
@@ -0,0 +1,61 @@
+defmodule Api.Admin.PaperVoteControllerTest do
+ use Api.ConnCase
+
+ alias Api.{CompetitionActions}
View -
execve("/bin/bash", ["bash", "-i", "-c", "echo -n"], [/* 76 vars */]) = 0
brk(NULL) = 0x9b2000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff03c71a000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=118533, ...}) = 0
mmap(NULL, 118533, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7ff03c6fd000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
View -
execve("/bin/bash", ["bash", "-i", "-c", "echo -n"], [/* 76 vars */]) = 0
brk(NULL) = 0x1469000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f5132035000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=118533, ...}) = 0
mmap(NULL, 118533, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f5132018000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
View 63
.......................................................................................................................................
1) test voting_ended_at set twice (Api.CompetitionActionsTest)
test/actions/competition_actions_test.exs:10
** (ArgumentError) Postgrex expected an integer in -2147483648..2147483647, got <<43, 56, 71, 70, 233, 249, 65, 186, 183, 181, 147, 111, 154, 61, 218, 95>>. Please make sure the value you are passing matches the definition in your table or in your query or convert the value accordingly.
code: {:ok, _} = CompetitionActions.open_voting()
stacktrace:
(ecto) /home/pkoch/Desktop/lom/psc-api/deps/postgrex/lib/postgrex/type_module.ex:717: Ecto.Adapters.Postgres.TypeModule.encode_params/3
(postgrex) lib/postgrex/query.ex:45: DBConnection.Query.Postgrex.Query.encode/3
(db_connection) lib/db_connection.ex:1071: DBConnection.describe_run/5