Skip to content

Commit

Permalink
Remove C code (#47)
Browse files Browse the repository at this point in the history
* Upgrade testing suite to testthat 3

* Add testing for previous issues

#45

* Add tests for standard bibtex entries

As defined in BibTEX version 0.99b
https://ctan.javinator9889.com/biblio/bibtex/base/btxdoc.pdf

* Update actions

* Add testing for examples

* Add snapshots for examples read.bib This may fail on some platforms

* Skip on non windows

Possibly a character problem related with
#20 and
#43

* Not test on R 3.4

Some changes in default  parsing (snapshot), but results are still ok

* Add more tests

* Try to increase coverage

* One more tests for do_read_bib

* Fix test for do_read_bib

* Revert actions

* Add devtools for testing

* Add more tests

* Add test for multiline string

* Add non standard field names

* Add myself as author

* Move issues to inst/bib files

* Refactor tests for avoiding cluttering

* Modify do_read_bib()

Also bump version

* Remove C code :)

* Recreate snapshots on Linux

* Check reverse dependencies

* Add backports

* Deprecate arguments

* Use seq_along

Co-authored-by: James J Balamuta <[email protected]>

* Use seq_along again

Co-authored-by: James J Balamuta <[email protected]>

* Remove completely header and footer

* Document internal functions

* Rename internal params

* Use vapply and new tests

* Rerun revdeps

* Update docs and snapshots

* Update revdep and check action

Some snapshots changes due to changes on toBibTex() on later versions of R, not related with the package

* Fix action and snapshots

Co-authored-by: James J Balamuta <[email protected]>
  • Loading branch information
dieghernan and coatless authored Sep 23, 2022
1 parent 05a401c commit e6f9720
Show file tree
Hide file tree
Showing 38 changed files with 1,031 additions and 12,958 deletions.
40 changes: 8 additions & 32 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,54 +22,30 @@ jobs:
- {os: windows-latest, r: 'release'}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel/1'}
- {os: ubuntu-latest, r: 'oldrel/2'}
# Use 3.6 to trigger usage of RTools35
- {os: windows-latest, r: '3.6'}
# Use older ubuntu to maximise backward compatibility
- {os: ubuntu-18.04, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-18.04, r: 'release'}
- {os: ubuntu-18.04, r: 'oldrel-1'}
- {os: ubuntu-18.04, r: 'oldrel-2'}



env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v2

- uses: r-lib/actions/setup-pandoc@v1
- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v1
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v1
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: |
rcmdcheck
devtools
- name: Check
env:
_R_CHECK_CRAN_INCOMING_: false
run: |
options(crayon.enabled = TRUE)
rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
shell: Rscript {0}
extra-packages: any::rcmdcheck
needs: check

- name: Show testthat output
if: always()
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash

- name: Upload check results
if: failure()
uses: actions/upload-artifact@main
with:
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
path: check
- uses: r-lib/actions/check-r-package@v2
5 changes: 3 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Package: bibtex
Version: 0.4.3
Version: 0.5.0
Title: Bibtex Parser
Authors@R: c(
person(given = "Romain",
Expand Down Expand Up @@ -50,10 +50,11 @@ License: GPL (>= 2)
Depends:
R (>= 3.0.2)
Imports:
backports (>= 1.4.0),
utils
Suggests:
testthat (>= 3.0.0)
LazyLoad: yes
Encoding: UTF-8
RoxygenNote: 7.1.2
RoxygenNote: 7.2.1
Config/testthat/edition: 3
1 change: 0 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,3 @@ importFrom(utils,citation)
importFrom(utils,installed.packages)
importFrom(utils,person)
importFrom(utils,toBibtex)
useDynLib(bibtex)
1 change: 0 additions & 1 deletion R/bibtex-package.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#' @keywords internal
#' @useDynLib bibtex
"_PACKAGE"

# The following block is used by usethis to automatically manage
Expand Down
Loading

0 comments on commit e6f9720

Please sign in to comment.