apache / apache/datafusion-sqlparser-rs
Seemingly pointless test
- Lenguaje dominante
- Rust
- Estrellas
- 3.5k
- Forks
- 772
- Merge medio
- 4 d 9 h
- PR fusionados (30 d)
- 17
Descripción
While implementing the support for [`INHERITS`](https://www.postgresql.org/docs/current/ddl-inherit.html), I happened to find [this test](https://github.com/jmhain/sqlparser-rs/blob/7723ea56c5119c7d1a15233c18eb2aaf48b60dc0/tests/sqlparser_postgres.rs#L505-L515) which contains in its name the word `inherit` and I suppose may reference the [CREATE ROLE INHERIT](https://www.postgresql.org/docs/current/sql-createrole.html), but it not present in the actual test.
If this test is actually pointless, it may be best to remove it. Do let me know how to proceed.
```rust
#[test]
fn parse_create_table_with_inherit() {
let sql = "\
CREATE TABLE bazaar.settings (\
settings_id UUID PRIMARY KEY DEFAULT uuid_generate_v4() NOT NULL, \
user_id UUID UNIQUE, \
value TEXT[], \
use_metric BOOLEAN DEFAULT true\
)";
pg().verified_stmt(sql);
}
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Línea de trabajo
Comienza con las líneas 505-515 de tests/sqlparser_postgres.rs y compara el nombre de la prueba con el SQL que analiza, especialmente las referencias de PostgreSQL INHERITS y CREATE ROLE INHERIT en el issue. Confirma si la prueba cubre el comportamiento previsto; se considera terminado cuando la prueba se elimina o se renombra de forma coherente y las pruebas relevantes de Rust pasan.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- rust
- Área
- testing-qa
- Tipo de issue
- Refactorización
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 45/100