Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update refs to connectrpc #539

Merged
merged 20 commits into from
Sep 6, 2023
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Contributing
============

We'd love your help making `connect-crosstest` more thorough!
We'd love your help making `connect-conformance` more thorough!

If you'd like to add new tests, please [open an issue][open-issue] describing
your proposal — discussing API changes ahead of time makes pull request
Expand All @@ -22,9 +22,9 @@ enabled][docker-compose-v2].
```
mkdir -p $GOPATH/src/github.com/bufbuild
cd $GOPATH/src/github.com/bufbuild
git clone [email protected]:your_github_username/connect-crosstest.git
cd connect-crosstest
git remote add upstream https://github.com/bufbuild/connect-crosstest.git
git clone [email protected]:your_github_username/conformance.git
cd conformance
git remote add upstream https://github.com/connectrpc/conformance.git
git fetch upstream
```

Expand All @@ -40,7 +40,7 @@ make
Start by creating a new branch for your changes:

```
cd $GOPATH/src/github.com/bufbuild/connect-crosstest
cd $GOPATH/src/github.com/connectrpc/conformance
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Think this file needs to be updated more carefully - wherever we're using the import path (for example, when cloning into GOPATH), we should use connectrpc.com/conformance.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Akshay. I assume this also goes for the actual module name itself in go.mod right? Also, should it apply to the links at the bottom?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It applies to go.mod, because that's the import path. The links below are to Github, though, so they should be github.com/connectrpc/conformance.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it. Updated. Let me know what you think.

git checkout main
git fetch upstream
git rebase upstream/main
Expand Down Expand Up @@ -69,7 +69,7 @@ We're much more likely to approve your changes if you:
* Write a [good commit message][commit-message].
* Maintain backward compatibility.

[fork]: https://github.com/bufbuild/connect-crosstest/fork
[open-issue]: https://github.com/bufbuild/connect-crosstest/issues/new
[fork]: https://github.com/connectrpc/conformance/fork
[open-issue]: https://github.com/connectrpc/conformance/issues/new
[commit-message]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
[docker-compose-v2]: https://www.docker.com/blog/announcing-compose-v2-general-availability/#still-using-compose-v1
24 changes: 12 additions & 12 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ jobs:
uses: actions/cache@v3
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-connect-crosstest-ci-${{ hashFiles('**/go.sum') }}
restore-keys: ${{ runner.os }}-connect-crosstest-ci-
key: ${{ runner.os }}-conformance-ci-${{ hashFiles('**/go.sum') }}
restore-keys: ${{ runner.os }}-conformance-ci-
- name: Test
run: make dockercomposetest # Make target includes clean-up
env:
Expand All @@ -47,9 +47,9 @@ jobs:
- ci
# This job only runs when
# 1. The previous ci job has completed successfully
# 2. The repository is not a fork, i.e. it will only run on the official bufbuild/connect-crosstest
# 2. The repository is not a fork, i.e. it will only run on the official connectrpc/conformance
# 3. The workflow run is triggered by push to main branch
if: ${{ success() && github.repository == 'bufbuild/connect-crosstest' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
if: ${{ success() && github.repository == 'connectrpc/conformance' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
steps:
# qemu is used when executing things like `apk` in the final build
# stage which must execute on the target platform. We currently do
Expand All @@ -71,21 +71,21 @@ jobs:
- name: docker-build-push
uses: docker/build-push-action@v4
with:
file: Dockerfile.crosstestgo
file: Dockerfile.conformancego
platforms: ${{ steps.qemu.outputs.platforms }}
push: true
tags: |
bufbuild/connect-crosstest:latest
bufbuild/connect-crosstest:${{ github.sha }}
connectrpc/conformance:latest
connectrpc/conformance:${{ github.sha }}
docker-web:
runs-on: ubuntu-latest
needs:
- ci
# This job only runs when
# 1. The previous ci job has completed successfully
# 2. The repository is not a fork, i.e. it will only run on the official bufbuild/connect-crosstest
# 2. The repository is not a fork, i.e. it will only run on the official connectrpc/conformance
# 3. The workflow run is triggered by push to main branch
if: ${{ success() && github.repository == 'bufbuild/connect-crosstest' && github.event_name == 'push' }}
if: ${{ success() && github.repository == 'connectrpc/conformance' && github.event_name == 'push' }}
&& github.ref == 'refs/heads/main' }}
steps:
- name: setup-docker-buildx
Expand All @@ -98,9 +98,9 @@ jobs:
- name: docker-build-push-web
uses: docker/build-push-action@v4
with:
file: Dockerfile.crosstestweb
file: Dockerfile.conformanceweb
platforms: ${{ steps.qemu.outputs.platforms }}
push: true
tags: |
bufbuild/connect-crosstest-web:latest
bufbuild/connect-crosstest-web:${{ github.sha }}
bufbuild/conformance-web:latest
bufbuild/conformance-web:${{ github.sha }}
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: crosstest-cc
name: conformance-cc
on:
workflow_dispatch
permissions:
contents: read
jobs:
crosstest-cc:
conformance-cc:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: crosstest-go
name: conformance-go
on:
schedule:
- cron: '14 10 * * *' # Runs 14:10 UTC, 10:10 Eastern
Expand All @@ -17,7 +17,7 @@ permissions:
contents: read
issues: write
jobs:
crosstest-go:
conformance-go:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
Expand All @@ -44,6 +44,6 @@ jobs:
env:
GITHUB_TOKEN: ${{ github.token }}
with:
filename: .github/crosstest-issue-template.md
filename: .github/conformance-issue-template.md
update_existing: true
search_existing: open
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: crosstest-web
name: conformance-web
on:
schedule:
- cron: '14 10 * * *' # Runs 14:10 UTC, 10:10 Eastern
Expand All @@ -21,7 +21,7 @@ permissions:
contents: read
issues: write
jobs:
crosstest-web:
conformance-web:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
Expand Down Expand Up @@ -49,6 +49,6 @@ jobs:
env:
GITHUB_TOKEN: ${{ github.token }}
with:
filename: .github/crosstest-issue-template.md
filename: .github/conformance-issue-template.md
update_existing: true
search_existing: open
4 changes: 2 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ linters-settings:
exhaustruct:
include:
# No zero values for param structs.
- 'github\.com/bufbuild/connect-crosstest\..*[pP]arams'
- 'github\.com/connectrpc/conformance\..*[pP]arams'
forbidigo:
forbid:
- '^fmt\.Print'
Expand All @@ -21,7 +21,7 @@ linters-settings:
ignore-decls:
- i int
- t *console.TB
- t crosstesting.TB
- t conformancetesting.TB
- t testing.TB
- ok bool
linters:
Expand Down
14 changes: 14 additions & 0 deletions Dockerfile.cc
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
// Copyright 2022 Buf Technologies, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

FROM --platform=arm64 gcr.io/bazel-public/bazel

ARG PORT
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.crosstestgo → Dockerfile.conformancego
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ COPY cmd /workspace/cmd
COPY internal /workspace/internal
COPY proto /workspace/proto
COPY cert /workspace/cert
RUN if [ ! -z "$TEST_CONNECT_GO_BRANCH" ]; then go get github.com/bufbuild/connect-go@$TEST_CONNECT_GO_BRANCH; fi
RUN if [ ! -z "$TEST_CONNECT_GO_BRANCH" ]; then go get connectrpc.com/connect@$TEST_CONNECT_GO_BRANCH; fi
RUN --mount=type=cache,target=/root/.cache/go-build \
CGO_ENABLED=0 GOOS=${TARGETOS} GOARCH=${TARGETARCH} \
go build -o /go/bin/client ./cmd/client
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.crosstestweb → Dockerfile.conformanceweb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ RUN local_npm_packages="" && \
local_npm_packages="${local_npm_packages} ../protobuf-es/packages/protobuf/"; \
fi && \
if [ ! -z "${TEST_CONNECT_WEB_BRANCH}" ]; then \
git clone --branch "${TEST_CONNECT_WEB_BRANCH}" --depth 1 https://github.com/bufbuild/connect-es.git ../connect-web && \
git clone --branch "${TEST_CONNECT_WEB_BRANCH}" --depth 1 https://github.com/connectrpc/connect-es.git ../connect-web && \
cd ../connect-web && make build && cd - \
local_npm_packages="${local_npm_packages} ../connect-web/packages/connect-web/"; \
fi && \
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ $(BIN)/golangci-lint: Makefile
$(BIN)/protoc-gen-connect-go: Makefile go.mod
@mkdir -p $(@D)
@# Pinned by go.mod.
GOBIN=$(abspath $(@D)) $(GO) install github.com/bufbuild/connect-go/cmd/protoc-gen-connect-go
GOBIN=$(abspath $(@D)) $(GO) install connectrpc.com/connect/cmd/protoc-gen-connect-go

$(BIN)/protoc-gen-go-grpc: Makefile
@mkdir -p $(@D)
Expand Down
48 changes: 24 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# connect-crosstest
# connect-conformance

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just conformance seems more straight-forward to me.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be lowercase conformance? Also, on line 9 then should it say

conformance runs a suite of cross-compatibility...

Kinda sounds weird to me but if you guys are fine with it, works for me.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sentence sounds weird to me too, but couldn't you simply use "This repository runs..." to avoid it?

[![License](https://img.shields.io/github/license/bufbuild/connect-crosstest?color=blue)][license]
[![CI](https://github.com/bufbuild/connect-crosstest/actions/workflows/ci.yaml/badge.svg?branch=main)][ci]
[![crosstest-go](https://github.com/bufbuild/connect-crosstest/actions/workflows/crosstest-go.yaml/badge.svg?branch=main)][github-action-go]
[![crosstest-web](https://github.com/bufbuild/connect-crosstest/actions/workflows/crosstest-web.yaml/badge.svg?branch=main)][github-action-web]
[![License](https://img.shields.io/github/license/connectrpc/conformance?color=blue)][license]
[![CI](https://github.com/connectrpc/conformance/actions/workflows/ci.yaml/badge.svg?branch=main)][ci]
[![conformance-go](https://github.com/connectrpc/conformance/actions/workflows/conformance-go.yaml/badge.svg?branch=main)][github-action-go]
[![conformance-web](https://github.com/connectrpc/conformance/actions/workflows/conformance-web.yaml/badge.svg?branch=main)][github-action-web]

`connect-crosstest` runs a suite of cross-compatibility tests using every combination of the
`connect-conformance` runs a suite of cross-compatibility tests using every combination of the
following clients and servers:

### Servers
Expand All @@ -17,10 +17,10 @@ following clients and servers:

- [connect-go][connect-go] (connect protocol, gRPC protocol and gRPC-web protocol)
- [grpc-go][grpc-go]
- [connect-web][connect-web] (connect protocol and gRPC-web protocol)
- [connect-es][connect-es] (connect protocol and gRPC-web protocol)
- [grpc-web][grpc-web]

The test suite is run daily against the latest commits of [connect-go][connect-go], [connect-web][connect-web]
The test suite is run daily against the latest commits of [connect-go][connect-go], [connect-es][connect-es]
and [protobuf-es][protobuf-es] to ensure that we are continuously testing for compatibility.

For more on Connect, see the [announcement blog post][blog], the documentation
Expand All @@ -33,7 +33,7 @@ The test suite is a superset of [gRPC][grpc-interop] and [grpc-web][grpc-web-int
tests. Clients and servers use the [gRPC interop Protobuf definitions][test.proto] and cover
a range of expected behaviours and functionality for gRPC and Connect.

| Test Case | `connect-go`, `grpc-go` | `connect-web`, `grpc-web` |
| Test Case | `connect-go`, `grpc-go` | `connect-es`, `grpc-web` |
|------------------------------------------|-------------------------|---------------------------|
| `empty_unary` | ✓ | ✓ |
| `cacheable_unary` | ✓ | ✓ |
Expand Down Expand Up @@ -132,8 +132,8 @@ and a non-ASCII message with error details.
RPC: `FailStreamingOutputCall`

Client calls `FailStreamingOutputCall`, and asks for four response messages. The server
responds with the messages, the status `RESOURCE_EXHAUSTED` and a non-ASCII message, and
error details. The client verifies that four response messages and the error status with
responds with the messages, the status `RESOURCE_EXHAUSTED` and a non-ASCII message, and
error details. The client verifies that four response messages and the error status with
code, message, and details was received.

#### cancel_after_begin
Expand Down Expand Up @@ -166,7 +166,7 @@ and expects the same metadata to be attached to the response. Client calls `Stre
with a request with a custom header and custom binary trailer and expects the same metadata
to be attached to the response when stream is closed. Client calls `FullDuplexCall`
with a request with a custom header and custom binary trailer and expects the same metadata
to be attached to the response when stream is closed. The `web` flows only test the unary and
to be attached to the response when stream is closed. The `web` flows only test the unary and
server streaming RPC.

#### duplicated_custom_metadata
Expand Down Expand Up @@ -230,8 +230,8 @@ Client calls an unresolvable host and expects an error with the status `UNAVAILA

### Github Actions

There are Github Actions workflows for [go][github-action-go] and [web][github-action-web] configured for running the daily crosstest against
the latest commits of [connect-go][connect-go], [connect-web][connect-web] and [protobuf-es][protobuf-es].
There are Github Actions workflows for [go][github-action-go] and [web][github-action-web] configured for running the daily conformance suite against
the latest commits of [connect-go][connect-go], [connect-es][connect-es] and [protobuf-es][protobuf-es].

### Locally

Expand All @@ -244,30 +244,30 @@ You can run the tests using `make dockercomposetest`.

## Support and Versioning

`connect-crosstest` works with:
`connect-conformance` works with:

* The most recent release of Go.

Unlike Connect's Go implementation, `connect-crosstest` has no exported APIs
Unlike Connect's Go implementation, `connect-conformance` has no exported APIs
and makes no backward compatibility guarantees. We'd like to release it as an
interoperability testing toolkit eventually, but don't have a concrete timeline
in mind.

[Getting Started]: https://connect.build/go/getting-started
[blog]: https://buf.build/blog/connect-a-better-grpc
[ci]: https://github.com/bufbuild/connect-crosstest/actions/workflows/ci.yaml
[connect-go]: https://github.com/bufbuild/connect-go
[connect-web]: https://github.com/bufbuild/connect-web
[demo]: https://github.com/bufbuild/connect-demo
[ci]: https://github.com/connectrpc/conformance/actions/workflows/ci.yaml
[connect-go]: https://github.com/connectrpc/connect-go
[connect-es]: https://github.com/connectrpc/connect-es
[demo]: https://github.com/connectrpc/examples-go
[docker-compose-v2]: https://www.docker.com/blog/announcing-compose-v2-general-availability/#still-using-compose-v1
[docs]: https://connect.build
[github-action-go]: https://github.com/bufbuild/connect-crosstest/actions/workflows/crosstest-go.yaml
[github-action-web]: https://github.com/bufbuild/connect-crosstest/actions/workflows/crosstest-web.yaml
[github-action-go]: https://github.com/connectrpc/conformance/actions/workflows/conformance-go.yaml
[github-action-web]: https://github.com/connectrpc/conformance/actions/workflows/conformance-web.yaml
[go-support-policy]: https://golang.org/doc/devel/release#policy
[grpc-go]: https://github.com/grpc/grpc-go
[grpc-interop]: https://github.com/grpc/grpc/blob/master/doc/interop-test-descriptions.md
[grpc-web-interop]: https://github.com/grpc/grpc-web/blob/master/doc/interop-test-descriptions.md
[grpc-web]: https://github.com/grpc/grpc-web
[license]: https://github.com/bufbuild/connect-crosstest/blob/main/LICENSE
[license]: https://github.com/connectrpc/conformance/blob/main/LICENSE
[protobuf-es]: https://github.com/bufbuild/protobuf-es
[test.proto]: https://github.com/bufbuild/connect-crosstest/blob/main/internal/proto/grpc/testing/test.proto
[test.proto]: https://github.com/connectrpc/conformance/blob/main/internal/proto/grpc/testing/test.proto
2 changes: 1 addition & 1 deletion WORKSPACE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

workspace(name = "com_github_bufbuild_connect_crosstest")
workspace(name = "com_github_connectrpc_conformance")

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

Expand Down
4 changes: 2 additions & 2 deletions buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: v1
managed:
enabled: true
go_package_prefix:
default: github.com/bufbuild/connect-crosstest/internal/gen/proto/go
default: github.com/connectrpc/conformance/internal/gen/proto/go
plugins:
- name: go
out: internal/gen/proto/go
Expand All @@ -16,7 +16,7 @@ plugins:
- plugin: buf.build/bufbuild/es:v1.2.1
out: web/gen/proto/connect-web
opt: target=ts
- plugin: buf.build/bufbuild/connect-es:v0.10.0
- plugin: buf.build/connectrpc/es:v0.13.2
out: web/gen/proto/connect-web
opt: target=ts
- plugin: buf.build/protocolbuffers/js:v3.21.2
Expand Down
Loading
Loading