Skip to content

Commit

Permalink
Add more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
alexarice committed Apr 8, 2020
1 parent 102f86d commit 4af3db1
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 2 deletions.
10 changes: 10 additions & 0 deletions src/Function/Bijection/Strict.agda
Original file line number Diff line number Diff line change
Expand Up @@ -120,3 +120,13 @@ f ∘ g = record
; surjective = Surjection.surjective (Surj._∘_ (surjection f) (surjection g))
}
} where open Bijection

private
test : {a b} {A : Setoid a b} {f g h : Bijection A A} (f ∘ g) ∘ h ≡ f ∘ (g ∘ h)
test = P.refl

testid : {a b} {A : Setoid a b} {f : Bijection A A} f ∘ id ≡ f
testid = P.refl

idtest : {a b} {A : Setoid a b} {f : Bijection A A} id ∘ f ≡ f
idtest = P.refl
8 changes: 7 additions & 1 deletion src/Function/Inverse/Strict.agda
Original file line number Diff line number Diff line change
Expand Up @@ -189,5 +189,11 @@ zip t f pres eq₁ eq₂ = record
} where open Inverse

private
test : {a b} {A : Setoid a b} {f g h : Inverse A A} f ∘ (g ∘ h)(f ∘ g) ∘ h
test : {a b} {A : Setoid a b} {f g h : Inverse A A} (f ∘ g) ∘ h ≡ f ∘ (g ∘ h)
test = P.refl

testid : {a b} {A : Setoid a b} {f : Inverse A A} f ∘ id ≡ f
testid = P.refl

idtest : {a b} {A : Setoid a b} {f : Inverse A A} id ∘ f ≡ f
idtest = P.refl
6 changes: 6 additions & 0 deletions src/Function/LeftInverse/Strict.agda
Original file line number Diff line number Diff line change
Expand Up @@ -150,3 +150,9 @@ _∘_ {F = F} f g = record
private
test : {a b} {A : Setoid a b} {f g h : LeftInverse A A} (f ∘ g) ∘ h ≡ f ∘ (g ∘ h)
test = P.refl

testid : {a b} {A : Setoid a b} {f : LeftInverse A A} f ∘ id ≡ f
testid = P.refl

idtest : {a b} {A : Setoid a b} {f : LeftInverse A A} id ∘ f ≡ f
idtest = P.refl
8 changes: 7 additions & 1 deletion src/Function/Surjection/Strict.agda
Original file line number Diff line number Diff line change
Expand Up @@ -126,5 +126,11 @@ f ∘ g = record
g∘f = Left._∘_ (right-inverse g) (right-inverse f)

private
test : {a b} {A : Setoid a b} {f g h : Surjection A A} f ∘ (g ∘ h)(f ∘ g) ∘ h
test : {a b} {A : Setoid a b} {f g h : Surjection A A} (f ∘ g) ∘ h ≡ f ∘ (g ∘ h)
test = P.refl

testid : {a b} {A : Setoid a b} {f : Surjection A A} f ∘ id ≡ f
testid = P.refl

idtest : {a b} {A : Setoid a b} {f : Surjection A A} id ∘ f ≡ f
idtest = P.refl

0 comments on commit 4af3db1

Please sign in to comment.