typedb / typedb-studio

TypeDB Studio (IDE)
https://typedb.com
Mozilla Public License 2.0
191 stars 44 forks source link

Test suite for Studio #605

Closed jamesreprise closed 2 years ago

jamesreprise commented 2 years ago

What is the goal of this PR?

In the course of fulfilling https://github.com/vaticle/typedb-studio/issues/392 we have developed a suite of tests concerning the integration of discrete sections of Studio.

Automated testing brings benefits to the future development of Studio: We can be sure before releasing new versions that changes have not broken previous functionality without anyone having to test each of the components and confirm that they work, giving users more confidence in the application.

Developers can now easily add tests to the suite when fixing bugs so that regressions in functionality and error-free use do not arise between releases.

What are the changes implemented in this PR?

We introduce tests for the Project Browser, the Text Editor, the Type Browser and update Quickstart to make use of the interactive methods of writing schemas and data that we've identified during the course of development.

In the course of testing we sometimes manipulate the state directly to bridge small gaps that are left by incomplete parts in the provided test framework from compose-jb. This is seen in our addition of //test/integration:__pkg__ to various BUILD files. It has been agreed that this is acceptable as long as it is the minimum necessary to test.

grabl commented 2 years ago

PR Review Checklist

Do not edit the content of this comment. The PR reviewer should simply update this comment by ticking each review item below, as they get completed.


Code

Architecture

jamesreprise commented 2 years ago

Haven't been able to get this to pass integration tests on CI - marking this as a draft until it passes.

jamesreprise commented 2 years ago

@alexjpwalker I'm marking this as ready for review as I'd like to go through the review checklist and justify my reasons for believing the code is in line with the checklist (with you challenging my decisions). Let me know if you have time for this.

jamesreprise commented 2 years ago

Putting a note here about the test behaviour being flaky - particularly the type browser tests timing out. This doesn't always happen, and it never happens locally.

jamesreprise commented 2 years ago

Based on a discussion Alex and I have had, I don't think we should merge this until the integration tests are more stable in grabl.