mirror of
https://github.com/Unidata/netcdf-c.git
synced 2024-12-27 08:49:16 +08:00
6b69b9c52c
## S3 Related Fixes * Add comprehensive support for specifying AWS profiles to provide access credentials. * Parse the files "~/.aws/config" and "~/.aws/credentials to provide credentials for the HDF5 ROS3 driver and to locate default region. * Add a function to obtain the currently active S3 credentials. The search rules are defined in docs/nczarr.md. * Provide documentation for the new features. * Modify the struct NCauth (in include/ncauth.h) to replace specific S3 credentials with a profile name. * Add a unit test to test the operation of profile and credentials management. * Add support for URLS of the form "s3://<bucket>/<key>"; this requires obtaining a default region. * Allows the specification of profile and/or region in a URL of the form "#mode=nczarr,...&aws.region=...&aws.profile=..." ## Misc. Fixes * Move the ezxml code to libdispatch so that it can be used both by DAP4 and nczarr. * Modify nclist to provide a deep clone operation. * Modify ncuri to provide a deep clone operation. * Modify the .rc file format to allow the specification of a path to be tested when looking for an entry in the .rc file. * Ensure that the NC_rcload function is called. * Modify nchttp to support setting request headers.
45 lines
1.2 KiB
Bash
Executable File
45 lines
1.2 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
if test "x$srcdir" = x ; then srcdir=`pwd`; fi
|
|
. ../test_common.sh
|
|
|
|
. "$srcdir/test_nczarr.sh"
|
|
|
|
# This shell script tests support for:
|
|
# 1. pure zarr (noxarray) read/write
|
|
# 2. xarray read/write
|
|
|
|
set -e
|
|
|
|
testcase() {
|
|
zext=$1
|
|
|
|
echo "*** Test: pure zarr write then read; format=$zext"
|
|
fileargs tmp_purezarr "mode=noxarray,$zext"
|
|
deletemap $zext $file
|
|
${NCGEN} -4 -b -o "$fileurl" $srcdir/ref_purezarr_base.cdl
|
|
${NCDUMP} $fileurl > tmp_purezarr_${zext}.cdl
|
|
diff -b ${srcdir}/ref_purezarr.cdl tmp_purezarr_${zext}.cdl
|
|
|
|
echo "*** Test: xarray zarr write then read; format=$zext"
|
|
fileargs tmp_xarray "mode=zarr,$zext"
|
|
#deletemap $zext $file
|
|
${NCGEN} -4 -b -o "$fileurl" $srcdir/ref_purezarr_base.cdl
|
|
${NCDUMP} $fileurl > tmp_xarray_${zext}.cdl
|
|
diff -b ${srcdir}/ref_xarray.cdl tmp_xarray_${zext}.cdl
|
|
echo "*** Test: pure zarr reading nczarr; format=$zext"
|
|
fileargs tmp_nczarr "mode=nczarr,$zext"
|
|
|
|
deletemap $zext $file
|
|
${NCGEN} -4 -b -o "$fileurl" $srcdir/ref_whole.cdl
|
|
fileargs tmp_nczarr "mode=zarr,$zext"
|
|
${NCDUMP} -n nczarr2zarr $fileurl > tmp_nczarr_${zext}.cdl
|
|
diff -b ${srcdir}/ref_nczarr2zarr.cdl tmp_nczarr_${zext}.cdl
|
|
}
|
|
|
|
testcase file
|
|
if test "x$FEATURE_NCZARR_ZIP" = xyes ; then testcase zip; fi
|
|
if test "x$FEATURE_S3TESTS" = xyes ; then testcase s3; fi
|
|
|
|
exit 0
|