gnu: ruby-activerecord: Update to 7.0.4.3 and enable tests.
* gnu/packages/rails.scm (ruby-activerecord): Update to 7.0.4.3. [source]: Use ruby-rails-monorepo. [arguments]: Remove #:tests? argument. Add #:phases argument. [native-inputs]: New field. [propagated-inputs]: Remove ruby-arel. Add ruby-sqlite3.
This commit is contained in:
parent
7c461b2ee9
commit
39f41cf93a
@ -287,27 +287,42 @@ serialization, internationalization, and testing.")
|
|||||||
|
|
||||||
(define-public ruby-activerecord
|
(define-public ruby-activerecord
|
||||||
(package
|
(package
|
||||||
(name "ruby-activerecord")
|
(name "ruby-activerecord")
|
||||||
(version "6.1.3")
|
(version %ruby-rails-version)
|
||||||
(source
|
(source ruby-rails-monorepo)
|
||||||
(origin
|
(build-system ruby-build-system)
|
||||||
(method url-fetch)
|
(arguments
|
||||||
(uri (rubygems-uri "activerecord" version))
|
(list
|
||||||
(sha256
|
#:phases
|
||||||
(base32
|
#~(modify-phases %standard-phases
|
||||||
"03kr6vslwd9iw89jidjpjlp7prr2rf7kpsfa4fz03g9by0kliivs"))))
|
(add-after 'extract-gemspec 'chdir
|
||||||
(build-system ruby-build-system)
|
(lambda _
|
||||||
(arguments
|
(chdir "activerecord")))
|
||||||
'(;; No included tests
|
(delete 'check)
|
||||||
#:tests? #f))
|
(add-after 'install 'check
|
||||||
(propagated-inputs
|
(lambda* (#:key tests? #:allow-other-keys)
|
||||||
(list ruby-activemodel ruby-activesupport ruby-arel))
|
(when tests?
|
||||||
(synopsis "Ruby library to connect to relational databases")
|
;; Avoid running the database tests, which require railties
|
||||||
(description
|
;; and/or database servers.
|
||||||
"Active Record connects classes to relational database table to establish
|
(invoke "ruby" "-Itest" "test/cases/base_test.rb"))))
|
||||||
|
(add-before 'check 'set-GEM_PATH
|
||||||
|
(lambda _
|
||||||
|
(setenv "GEM_PATH" (string-append
|
||||||
|
(getenv "GEM_PATH") ":"
|
||||||
|
#$output "/lib/ruby/vendor_ruby"))))
|
||||||
|
(add-before 'check 'check-setup
|
||||||
|
(lambda* (#:key native-inputs inputs #:allow-other-keys)
|
||||||
|
;; A few tests require to set the timezone.
|
||||||
|
(setenv "TZDIR" (search-input-directory (or native-inputs inputs)
|
||||||
|
"share/zoneinfo")))))))
|
||||||
|
(native-inputs (list tzdata-for-tests))
|
||||||
|
(propagated-inputs (list ruby-activemodel ruby-activesupport ruby-sqlite3))
|
||||||
|
(synopsis "Ruby library to connect to relational databases")
|
||||||
|
(description
|
||||||
|
"Active Record connects classes to relational database table to establish
|
||||||
an almost zero-configuration persistence layer for applications.")
|
an almost zero-configuration persistence layer for applications.")
|
||||||
(home-page "https://rubyonrails.org")
|
(home-page "https://rubyonrails.org")
|
||||||
(license license:expat)))
|
(license license:expat)))
|
||||||
|
|
||||||
(define-public ruby-rspec-rails
|
(define-public ruby-rspec-rails
|
||||||
(package
|
(package
|
||||||
|
Loading…
Reference in New Issue
Block a user