Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
7 changes: 4 additions & 3 deletions linux/build-aux/debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ Recommends:
Suggests:
krb5-user,
Description: database client for GNOME
TablePro connects to PostgreSQL, MySQL, SQLite, DuckDB, SQL Server and
ClickHouse. Browse tables, edit rows in place, run SQL with syntax
highlighting, and reach servers behind an SSH bastion.
TablePro connects to PostgreSQL, MySQL, SQLite, DuckDB, SQL Server,
ClickHouse, Cassandra, ScyllaDB, Redis and MongoDB. Browse tables, edit
rows in place, run SQL with syntax highlighting, and reach servers behind
an SSH bastion.
7 changes: 4 additions & 3 deletions linux/build-aux/rpm/tablepro.spec
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,10 @@ Recommends: (gnome-keyring or kf6-kwallet or keepassxc)
Suggests: krb5-workstation

%description
TablePro connects to PostgreSQL, MySQL, SQLite, DuckDB, SQL Server and
ClickHouse. Browse tables, edit rows in place, run SQL with syntax
highlighting, and reach servers behind an SSH bastion.
TablePro connects to PostgreSQL, MySQL, SQLite, DuckDB, SQL Server,
ClickHouse, Cassandra, ScyllaDB, Redis and MongoDB. Browse tables, edit
rows in place, run SQL with syntax highlighting, and reach servers behind
an SSH bastion.

%prep
%autosetup -n %{name}-%{version_no_tilde} -a1
Expand Down
43 changes: 43 additions & 0 deletions linux/crates/app/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,49 @@ mod tests {
}
}

/// Software centres, apt, dnf and the man page describe the app by
/// the engines it connects to.
#[test]
fn package_descriptions_name_every_engine() {
fn section(path: &str, start: &str, end: Option<&str>) -> String {
let root = std::path::Path::new(env!("CARGO_MANIFEST_DIR")).join("../..");
let text = std::fs::read_to_string(root.join(path)).unwrap_or_else(|error| panic!("{path}: {error}"));
let Some((_, rest)) = text.split_once(start) else {
panic!("{path} has no {start}");
};
let words = match end {
Some(end) => match rest.split_once(end) {
Some((words, _)) => words,
None => panic!("{path} has no {end} after {start}"),
},
None => rest,
};
words.split_whitespace().collect::<Vec<_>>().join(" ")
}

let desktop = "data/app.tablepro.TablePro.desktop.in.in";
let metainfo = "data/app.tablepro.TablePro.metainfo.xml.in.in";
let control = "build-aux/debian/control";
let spec = "build-aux/rpm/tablepro.spec";
let descriptions = [
("desktop Comment", section(desktop, "\nComment=", Some("\n"))),
("desktop Keywords", section(desktop, "\nKeywords=", Some("\n"))),
("metainfo", section(metainfo, "<description>", Some("</description>"))),
("man page", section("data/tablepro.1", ".SH DESCRIPTION", Some(".SH "))),
// The binary package's stanza ends the file.
("debian/control", section(control, "\nDescription:", None)),
("rpm spec", section(spec, "\n%description", Some("\n%prep"))),
];

for driver in build_registry().iter() {
for engine in driver.display_name().split(" / ") {
for (place, text) in &descriptions {
assert!(text.contains(engine), "{place} does not name {engine}: {text}");
}
}
}
}

#[test]
fn resources_contain_style_css() {
register_test_resources();
Expand Down
Loading