Skip to content
New issue

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

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

Already on GitHub? # to your account

Add E2E testing framework MVP #1368

Closed
wants to merge 33 commits into from
Closed

Conversation

cmichi
Copy link
Collaborator

@cmichi cmichi commented Aug 29, 2022

MVP for #1234.

Contains only E2E tests for examples/contract-transfer. Once we've nailed down the API I'll migrate the rest in follow-up PRs. The best way to look at this PR is, I think, to look at the tests for that example.

I've annotated a couple of TODO(#xxx) comments ‒ I'll create the issues + add the number before merging, I'm just waiting for approvals beforehand.

@cmichi cmichi requested review from a team, ascjones and HCastano as code owners August 29, 2022 15:44
@cmichi cmichi requested a review from athei August 29, 2022 15:45
@cmichi cmichi force-pushed the cmichi-add-e2e-testing-mvp branch from 1f30d9c to 6bdfa9a Compare August 29, 2022 15:51
@cmichi cmichi marked this pull request as draft August 29, 2022 15:59
cmichi and others added 20 commits August 29, 2022 18:07
* pin gha versions

* pin gha version

* fix hash
* Add `version` field to `InkProject`

* Use `InkProject` directly in metadata codegen

* Remove old metadata versions from version enum

These versions can't be constructed using this version of the crate
anyways, so it doesn't really make sense to keep them.

* Manually implement `Default`

We should change to using the derive macros once
our CI's nightly compiler version gets updated.

* Add metadata `V4` version option

* Use my branch of `cargo-contract` in CI

* Remove deprecated `V3` metadata

We're never able to construct this variant with this
crate anymore, so it doesn't make sense to keep it.
* Rename `RELEASES` to `CHANGELOG`

We're following the [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
conventions anyways, so the name makes more sense.

* Reduce header sizes by one level
* Move linting into ink repo

* Fix CI

* Apply suggestions from code review

Co-authored-by: Alexander Samusev <41779041+alvicsam@users.noreply.github.com>

* Update .gitlab-ci.yml

Co-authored-by: Alexander Samusev <41779041+alvicsam@users.noreply.github.com>

* Update linting/Cargo.toml

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>

* Update linting/Cargo.toml

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>

Co-authored-by: Alexander Samusev <41779041+alvicsam@users.noreply.github.com>
Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>
HCastano and others added 9 commits August 31, 2022 08:09
* Add release notes for `v4.0.0-alpha.1`

* Mention breaking changes in changelog

* Bump version to `4.0.0-alpha.1`

* Fix header levels after merge

* Fix some formatting

* Add some notes about the breaking changes

* Add links to PRs

* Add note about linting move

* Bump `ink_linting` crate to `4.0.0-alpha.1`

* Remove `nightly` usage from delegator build script

* Use dashes instead of minus signs

Co-authored-by: Michael Müller <mich@elmueller.net>

* Beef up description of linter PR

Co-authored-by: Michael Müller <mich@elmueller.net>

* Move compatibility section to top of release notes

* Explicitly use `stable` channel

Our Docker images still default to `nightly`

* Build contracts with `stable` toolchain

* Install `rust-src` component before building examples

* Run the rest of the CI stages again

Co-authored-by: Michael Müller <mich@elmueller.net>
* Mention that a new `cargo-contract` release needs to be used

* Update CI to use released `cargo-contract` version
* Remove `version` from dev-dependencies

Looks like Cargo decides to either use a local or published package
depending on the context (i.e `path` vs. `version`) Since we never
publish `dev-dependencies` we can stick to always using a local version
(`path`).

Cargo book reference:
- https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#multiple-locations

* Sort `dev-dependencies` alphabetically
* Update the release checklist

This simplies the release checklist a bit by using both `cargo-unleash`
and `cargo-release`. `cargo-release` has been way more reliable for
publishing the ink! workspace than `cargo-unleash`, but we still use
`cargo-unleash` to clean up our `dev-dependencies`.

In the future it would be cool to automate more of the release process,
such as tag creation and publishing, through `cargo-release`.

* Remove steps related to `dev-dependencies`

With #1367 these shouldn't be required anymore.

* Add missing punctuation

Co-authored-by: Michael Müller <mich@elmueller.net>

Co-authored-by: Michael Müller <mich@elmueller.net>
@cmichi cmichi closed this Aug 31, 2022
@cmichi cmichi deleted the cmichi-add-e2e-testing-mvp branch August 31, 2022 06:28
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants