(t *testing.T)
| 1746 | } |
| 1747 | |
| 1748 | func TestNewUploadRequest_pathTraversal(t *testing.T) { |
| 1749 | t.Parallel() |
| 1750 | c := mustNewClient(t) |
| 1751 | |
| 1752 | _, err := c.NewUploadRequest(t.Context(), "repos/x/../../../admin", nil, 0, "") |
| 1753 | if !errors.Is(err, ErrPathForbidden) { |
| 1754 | t.Fatalf("NewUploadRequest with path traversal: want ErrPathForbidden, got %v", err) |
| 1755 | } |
| 1756 | } |
| 1757 | |
| 1758 | func TestNewFormRequest(t *testing.T) { |
| 1759 | t.Parallel() |
nothing calls this directly
no test coverage detected
searching dependent graphs…