Message ID | 20241016051210.9729-1-ngraves@ngraves.fr |
---|---|
State | New |
Headers | show |
Series | [bug#73692,v2] gnu: timescaledb: Ignore failing tests. | expand |
Nicolas Graves via Guix-patches via <guix-patches@gnu.org> writes: > * gnu/packages/databases.scm (timescaledb): > [arguments]<#:phases>: Add phase 'patch-failing-tests. > --- > gnu/packages/databases.scm | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) > > diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm > index 43ec0641a0..80163cfdc0 100644 > --- a/gnu/packages/databases.scm > +++ b/gnu/packages/databases.scm > @@ -1502,6 +1502,21 @@ (define-public timescaledb > "-o" (string-append "-k " pg-data) > "-l" (string-append pg-data "/db.log") > "start")))) > + #$@(if (not (target-x86-64?)) > + #~((add-after 'unpack 'patch-failing-tests > + (lambda _ > + (substitute* "test/CMakeLists.txt" > + (((format > + #f "(~{~a|~})" I think it's best to keep it simple and not use overly complex features. > + (cons* > + "histogram_test\\.sql\\.in" > + #$@(if (target-aarch64?) > + #~((list "append\\.sql\\.in" > + "chunk_adaptative\\.sql")) > + #~((list))))) > + all) > + (string-append "#" all)))))) > + #~()) > (add-after 'prepare-tests 'check > (assoc-ref %standard-phases 'check))))) > (inputs (list openssl postgresql))
On 2024-10-16 20:28, Z572 wrote: > Nicolas Graves via Guix-patches via <guix-patches@gnu.org> writes: > >> * gnu/packages/databases.scm (timescaledb): >> [arguments]<#:phases>: Add phase 'patch-failing-tests. >> --- >> gnu/packages/databases.scm | 15 +++++++++++++++ >> 1 file changed, 15 insertions(+) >> >> diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm >> index 43ec0641a0..80163cfdc0 100644 >> --- a/gnu/packages/databases.scm >> +++ b/gnu/packages/databases.scm >> @@ -1502,6 +1502,21 @@ (define-public timescaledb >> "-o" (string-append "-k " pg-data) >> "-l" (string-append pg-data "/db.log") >> "start")))) >> + #$@(if (not (target-x86-64?)) >> + #~((add-after 'unpack 'patch-failing-tests >> + (lambda _ >> + (substitute* "test/CMakeLists.txt" >> + (((format >> + #f "(~{~a|~})" > > I think it's best to keep it simple and not use overly complex > features. I agree but this bit is indeed particularly tricky. I can move from complex format to string-append + string-join, from cons* to append list, and drop the not, but ultimately I feel selectively ignoring tests by system is complex in itself. Let's see what QA says, then simplify that, but if you have a better solution, don't hesitate to put it forward ;) > >> + (cons* >> + "histogram_test\\.sql\\.in" >> + #$@(if (target-aarch64?) >> + #~((list "append\\.sql\\.in" >> + "chunk_adaptative\\.sql")) >> + #~((list))))) >> + all) >> + (string-append "#" all)))))) >> + #~()) >> (add-after 'prepare-tests 'check >> (assoc-ref %standard-phases 'check))))) >> (inputs (list openssl postgresql))
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 43ec0641a0..80163cfdc0 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -1502,6 +1502,21 @@ (define-public timescaledb "-o" (string-append "-k " pg-data) "-l" (string-append pg-data "/db.log") "start")))) + #$@(if (not (target-x86-64?)) + #~((add-after 'unpack 'patch-failing-tests + (lambda _ + (substitute* "test/CMakeLists.txt" + (((format + #f "(~{~a|~})" + (cons* + "histogram_test\\.sql\\.in" + #$@(if (target-aarch64?) + #~((list "append\\.sql\\.in" + "chunk_adaptative\\.sql")) + #~((list))))) + all) + (string-append "#" all)))))) + #~()) (add-after 'prepare-tests 'check (assoc-ref %standard-phases 'check))))) (inputs (list openssl postgresql))