Skip to content

Consolidate test validation #6

Closed
@stuebingerb

Description

@stuebingerb

Currently, validations in test functions are implemented in different ways:

  • Using kluent, e.g.
    invoking {
        deserialize(schema.executeBlocking("{b{id, name, age}}"))
    } shouldThrow GraphQLError::class withMessage "Property id on B does not exist"
    
  • Using custom implementations, e.g.
    expect<IllegalAccessException>("ILLEGAL ACCESS") {
        schema.executeBlocking("{black_mamba {item}}", context = context { +"LAKERS" }).also(::println)
    }
    
  • Using hamcrest, e.g.
    assertThat(scenarioType["author"], nullValue())
    

This makes it unnecessarily complex and hard to maintain and should be consolidated, ideally towards a single, kotlin-native test library.

Ideas for alternatives:

Metadata

Metadata

Assignees

Labels

input wantedTarget solution is not yet clear or more input is wanted on an issue

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions