Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using externally stored data within tests #21

Open
eseiler opened this issue Sep 29, 2020 · 3 comments
Open

Using externally stored data within tests #21

eseiler opened this issue Sep 29, 2020 · 3 comments

Comments

@eseiler
Copy link
Member

eseiler commented Sep 29, 2020

I currently use an archive of the structure:

example_data/
├── 1024
│   ├── bins
│   └── reads
└── 64
    ├── bins
    └── reads

where the bins and reads directory contain 64 1024 files each, respectively.

It doesn't seem easily possible to extract that archive.tar.gz to provide, say, 1024/bins/... etc. in the data directory.
To do so, I need to hard-code the steps in the app_datasources.cmake

${CMAKE_COMMAND} -E create_symlink <DOWNLOADED_FILE> ${CMAKE_CURRENT_BINARY_DIR}/data/${ARG_FILE}

Maybe there is a more elegant solution?

@joergi-w
Copy link
Member

Maybe try DOWNLOAD_NO_EXTRACT FALSE in

DOWNLOAD_NO_EXTRACT TRUE # don't extract archive files like .tar.gz.
?

@eseiler
Copy link
Member Author

eseiler commented Sep 29, 2020

Doesn't work, in fact it does nothing at all - at least when I tried it.

https://ftp.imp.fu-berlin.de/pub/seiler/raptor/example_data.tar.gz is the data and I specify

            INSTALL_COMMAND
                tar -C ${CMAKE_CURRENT_BINARY_DIR}/data/ -zxf <DOWNLOADED_FILE>

(which is a lot less than I did in the beginning where I also moved the files around, now I just extract them)

@eseiler
Copy link
Member Author

eseiler commented Sep 29, 2020

I noticed that on my CI it actually tries to extract with DOWNLOAD_NO_EXTRACT FALSE, but not on the server where I develop or my local machine.
CMake version on server: 3.16.2
CMake version on local machine: 3.16.3
CMake version on CI: 3.18.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants